|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.sun.grizzly.SingleProtocolChainInstanceHandler
public class SingleProtocolChainInstanceHandler
Implementation of an ProtocolChainInstanceHandler
.
Contains single ProtocolChain
instance, which will be returned all
the time ProtocolChainInstanceHandler.poll()
will be called.
Field Summary | |
---|---|
protected ProtocolChain |
protocolChain
Single ProtocolChain instance. |
Constructor Summary | |
---|---|
SingleProtocolChainInstanceHandler()
|
|
SingleProtocolChainInstanceHandler(ProtocolChain protocolChain)
|
Method Summary | |
---|---|
ProtocolChain |
getProtocolChain()
Get the stateless ProtocolChain instance, which is always
returned via StatelessProtocolChainInstanceHandler#poll() . |
boolean |
offer(ProtocolChain protocolChain)
Offer (add) an instance of ProtocolChain to this instance pool. |
ProtocolChain |
poll()
Return a ProtocolChain instance. |
void |
setProtocolChain(ProtocolChain protocolChain)
Set the stateless ProtocolChain instance, which will be always
returned via StatelessProtocolChainInstanceHandler#poll() . |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected volatile ProtocolChain protocolChain
ProtocolChain
instance.
Constructor Detail |
---|
public SingleProtocolChainInstanceHandler()
public SingleProtocolChainInstanceHandler(ProtocolChain protocolChain)
Method Detail |
---|
public ProtocolChain poll()
ProtocolChain
instance. If no ProtocolChain
was
set before, then new instance of DefaultProtocolChain
will be returned.
poll
in interface ProtocolChainInstanceHandler
public boolean offer(ProtocolChain protocolChain)
StatelessProtocolChainInstanceHandler
has empty implementation
of the method.
offer
in interface ProtocolChainInstanceHandler
protocolChain
- - ProtocolChain to offer / add to the pool
public ProtocolChain getProtocolChain()
ProtocolChain
instance, which is always
returned via StatelessProtocolChainInstanceHandler#poll()
.
ProtocolChain
instance, which is always
returned via StatelessProtocolChainInstanceHandler#poll()
.public void setProtocolChain(ProtocolChain protocolChain)
ProtocolChain
instance, which will be always
returned via StatelessProtocolChainInstanceHandler#poll()
.
protocolChain
- the stateless ProtocolChain
instance,
which will be always returned via
StatelessProtocolChainInstanceHandler#poll()
.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |