public interface Acceptor
The primary PEPt server-side plug-in point and enabler for altenate encodings, protocols and transports.
Acceptor is a factory for client-side
artifacts used to receive a message (and possibly send a response).
| Modifier and Type | Method and Description |
|---|---|
void |
accept()
Accept a connection request.
|
void |
close()
Close the
Acceptor. |
InputObject |
createInputObject(Broker broker,
MessageMediator messageMediator)
Used to get a
InputObject
for the specific encoding represented by this
Acceptor. |
MessageMediator |
createMessageMediator(Broker xbroker,
Connection xconnection)
Used to get a
MessageMediator
to hold internal data for a message received using the specific
encoding, protocol, transport combination represented by this
Acceptor. |
OutputObject |
createOutputObject(Broker broker,
MessageMediator messageMediator)
Used to get a
OutputObject
for the specific encoding represented by this
Acceptor. |
MessageMediator |
finishCreatingMessageMediator(Broker broker,
Connection xconnection,
MessageMediator messageMediator)
Used to finish creating a
MessageMediator
to with internal data for a message received using the specific
encoding, protocol, transport combination represented by this
Acceptor. |
InboundConnectionCache |
getConnectionCache()
Get the
InboundConnectionCache
used by this Acceptor
PEPt uses separate caches for each type of Acceptor
as given by getConnectionCacheType(). |
String |
getConnectionCacheType()
PEPt uses separate caches for each type of
Acceptor
as given by getConnectionCacheType. |
EventHandler |
getEventHandler()
Get the
EventHandler
associated with this Acceptor. |
boolean |
initialize()
Used to initialize an
Acceptor. |
boolean |
initialized()
Used to determine if an
Acceptor has been initialized. |
void |
setConnectionCache(InboundConnectionCache connectionCache)
Set the
InboundConnectionCache
to be used by this Acceptor. |
boolean |
shouldRegisterAcceptEvent()
Used to determine if the
Acceptor should register
with
Selector
to handle accept events. |
boolean initialize()
Acceptor.
For example, initialization may mean to create a
ServerSocketChannel.
Note: this must be prepared to be be called multiple times.true when it performs initializatin
actions (typically the first call.boolean initialized()
Acceptor has been initialized.trueAcceptor has been
initialized.String getConnectionCacheType()
Acceptor
as given by getConnectionCacheType.Stringvoid setConnectionCache(InboundConnectionCache connectionCache)
InboundConnectionCache
to be used by this Acceptor.
PEPt uses separate caches for each type of Acceptor
as given by getConnectionCacheType().
setConnectionCache(com.sun.corba.se.pept.transport.InboundConnectionCache) and getConnectionCache() support
an optimzation to avoid hashing to find that cache.connectionCache. - InboundConnectionCache getConnectionCache()
InboundConnectionCache
used by this Acceptor
PEPt uses separate caches for each type of Acceptor
as given by getConnectionCacheType().
setConnectionCache(com.sun.corba.se.pept.transport.InboundConnectionCache) and getConnectionCache() support
an optimzation to avoid hashing to find that cache.ConnectionCacheboolean shouldRegisterAcceptEvent()
Acceptor should register
with
Selector
to handle accept events.
For example, this may be false in the case of Solaris Doors
which do not actively listen.true if the Acceptor should be
registered with
Selectorvoid accept()
Acceptor or by a
ListenerThread.
It results in a
Connection
being created.void close()
Acceptor.EventHandler getEventHandler()
EventHandler
associated with this Acceptor.EventHandlerMessageMediator createMessageMediator(Broker xbroker, Connection xconnection)
MessageMediator
to hold internal data for a message received using the specific
encoding, protocol, transport combination represented by this
Acceptor.MessageMediatorMessageMediator finishCreatingMessageMediator(Broker broker, Connection xconnection, MessageMediator messageMediator)
MessageMediator
to with internal data for a message received using the specific
encoding, protocol, transport combination represented by this
Acceptor.MessageMediatorInputObject createInputObject(Broker broker, MessageMediator messageMediator)
InputObject
for the specific encoding represented by this
Acceptor.InputObjectOutputObject createOutputObject(Broker broker, MessageMediator messageMediator)
OutputObject
for the specific encoding represented by this
Acceptor.OutputObjectCopyright © 2018 JBoss by Red Hat. All rights reserved.