|
JXTA | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface PipeService
Pipes are the core mechanism for exchanging messages between JXTA applications or services.
Pipes are uniquely identified by aPipeAdvertisement
which is associated with each
pipe.
Several types of Pipe can currently be used:
PipeAdvertisement
.
PipeAdvertisement
,
InputPipe
,
OutputPipe
,
Message
,
JXTA Protocols Specification : Pipes,
JXTA Protocols Specification : Pipe Binding ProtocolField Summary | |
---|---|
static String |
PropagateType
Propagated, unsecured and unreliable type of Pipe |
static String |
UnicastSecureType
End-to-end secured unicast pipe of Pipe |
static String |
UnicastType
Unicast, unreliable and unsecured type of Pipe |
Fields inherited from interface net.jxta.platform.Module |
---|
START_AGAIN_PROGRESS, START_AGAIN_STALLED, START_DISABLED, START_OK |
Method Summary | |
---|---|
InputPipe |
createInputPipe(PipeAdvertisement adv)
Create an InputPipe from a pipe Advertisement |
InputPipe |
createInputPipe(PipeAdvertisement adv,
PipeMsgListener listener)
Create an InputPipe from a pipe Advertisement |
OutputPipe |
createOutputPipe(PipeAdvertisement pipeAdv,
long timeout)
Attempt to create an OutputPipe using the specified Pipe Advertisement. |
void |
createOutputPipe(PipeAdvertisement pipeAdv,
OutputPipeListener listener)
Attempt to create an OutputPipe using the specified Pipe Advertisement. |
OutputPipe |
createOutputPipe(PipeAdvertisement pipeAdv,
Set<? extends ID> resolvablePeers,
long timeout)
Attempt to create an OutputPipe using the specified Pipe Advertisement. |
void |
createOutputPipe(PipeAdvertisement pipeAdv,
Set<? extends ID> resolvablePeers,
OutputPipeListener listener)
Attempt to create an OutputPipe using the specified Pipe Advertisement. |
OutputPipeListener |
removeOutputPipeListener(ID pipeID,
OutputPipeListener listener)
Remove an OutputPipeListener previously registered with createOuputputPipe . |
OutputPipeListener |
removeOutputPipeListener(String pipeID,
OutputPipeListener listener)
Deprecated. This method is being replaced by removeOutputPipeListener(ID,OutputPipeListener) . |
Methods inherited from interface net.jxta.service.Service |
---|
getImplAdvertisement, getInterface |
Methods inherited from interface net.jxta.platform.Module |
---|
init, startApp, stopApp |
Field Detail |
---|
static final String UnicastType
static final String PropagateType
static final String UnicastSecureType
Method Detail |
---|
InputPipe createInputPipe(PipeAdvertisement adv) throws IOException
adv
- The advertisement of the Pipe.
IOException
- error creating input pipeInputPipe createInputPipe(PipeAdvertisement adv, PipeMsgListener listener) throws IOException
adv
- is the advertisement of the Pipe.listener
- PipeMsgListener to receive msgs.
IOException
- Error creating input pipeOutputPipe createOutputPipe(PipeAdvertisement pipeAdv, long timeout) throws IOException
pipeAdv
- The advertisement of the pipe being resolved.timeout
- Time duration in milliseconds to wait for a successful
pipe resolution. 0 will wait indefinitely.
IOException
- If the pipe cannot be created or failed to resolve
within the specified time.OutputPipe createOutputPipe(PipeAdvertisement pipeAdv, Set<? extends ID> resolvablePeers, long timeout) throws IOException
pipeAdv
- The advertisement of the pipe being resolved.resolvablePeers
- The peers on which the pipe may be resolved.
If the Set is empty then the pipe may be resolved to any
destination peer.timeout
- Time duration in milliseconds to wait for a successful
pipe resolution. 0 will wait indefinitely.
IOException
- If the pipe cannot be created or failed to resolve
within the specified time.void createOutputPipe(PipeAdvertisement pipeAdv, OutputPipeListener listener) throws IOException
pipeAdv
- The advertisement of the pipe being resolved.listener
- The listener to be called when the pipe is resolved.
IOException
- If the pipe cannot be created.void createOutputPipe(PipeAdvertisement pipeAdv, Set<? extends ID> resolvablePeers, OutputPipeListener listener) throws IOException
pipeAdv
- The advertisement of the pipe being resolved.resolvablePeers
- The set of peers on which the pipe may be resolved.
If the Set is empty then the pipe may be resolved to any
destination peer.listener
- the listener to be called when the pipe is resolved.
IOException
- If the pipe cannot be created.@Deprecated OutputPipeListener removeOutputPipeListener(String pipeID, OutputPipeListener listener)
removeOutputPipeListener(ID,OutputPipeListener)
.
createOuputputPipe
.
pipeID
- The pipe who's listener is to be removed.listener
- The listener to remove.
OutputPipeListener removeOutputPipeListener(ID pipeID, OutputPipeListener listener)
createOuputputPipe
.
pipeID
- The pipe who's listener is to be removed.listener
- The listener to remove.
|
JXSE | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |