|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.neeve.root.RootObject
com.neeve.link.LnkObject
com.neeve.link.LnkSynchronousAcceptor
public final class LnkSynchronousAcceptor
Synchronously accepts a link connection.
This class is a helper class that enables the user to synchronously
accept incoming link requests. The user invokes run(com.neeve.link.ILnkServerEndpoint, int)
with a
server endpoint and a maximum timeout that the method should block
and wait for an incoming link connection request. The method will
block and wait for an incoming connection and will return when either
a link is successfully accepted or the timeout expires.
Method Summary | |
---|---|
static LnkSynchronousAcceptor |
create()
Create a synchronous acceptor. |
ILnkPeerEndpoint |
run(ILnkServerEndpoint sep,
int timeout)
Synchronously accept an incoming link connection. |
Methods inherited from class com.neeve.root.RootObject |
---|
getChecked, getThreaded, getTracer, setChecked, setTracer |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static LnkSynchronousAcceptor create()
public final ILnkPeerEndpoint run(ILnkServerEndpoint sep, int timeout) throws ELnkInvalidStateException, ELnkOpFailedException
sep
- The server endpoint through which to execute the accept.timeout
- The maximum amount of time (in millseconds) to wait for a
link connection to be accepted. This parameter must be a positive
number.
ELnkInvalidStateException
- Thrown in case the supplied endpoint
is in a state that does not permit a connect to be posted on it.
ELnkOpFailedException
- Thrown in case the link connection could
not be successfully established.
ELnkOpTimeoutException
- Thrown in case the timeout expired before
the link connection could be established.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |