public class ProtonSessionImpl extends Object implements ProtonSession
| Modifier and Type | Method and Description |
|---|---|
org.apache.qpid.proton.engine.Record |
attachments()
Retrieves the attachments record, upon which application items can be set/retrieved.
|
ProtonSessionImpl |
close()
Closed the AMQP session, i.e.
|
ProtonSessionImpl |
closeHandler(Handler<AsyncResult<ProtonSession>> closeHandler)
Sets a handler for when an AMQP End frame is received from the remote peer.
|
ProtonReceiver |
createReceiver(String address)
Creates a receiver used to consumer messages from the given node address.
|
ProtonReceiver |
createReceiver(String address,
ProtonLinkOptions receiverOptions)
Creates a receiver used to consumer messages from the given node address.
|
ProtonSender |
createSender(String address)
Creates a sender used to send messages to the given node address.
|
ProtonSender |
createSender(String address,
ProtonLinkOptions senderOptions)
Creates a sender used to send messages to the given node address.
|
void |
free()
Tidies up related session resources when complete with use.
|
org.apache.qpid.proton.amqp.transport.ErrorCondition |
getCondition()
Gets the local ErrorCondition object.
|
ProtonConnection |
getConnection()
Gets the connection this session is on.
|
ProtonConnectionImpl |
getConnectionImpl() |
int |
getIncomingBytes() |
int |
getIncomingCapacity()
Gets the incoming capacity in bytes, used to govern session-level flow control.
|
org.apache.qpid.proton.engine.EndpointState |
getLocalState() |
int |
getOutgoingBytes() |
long |
getOutgoingWindow() |
org.apache.qpid.proton.amqp.transport.ErrorCondition |
getRemoteCondition()
Gets the remote ErrorCondition object.
|
org.apache.qpid.proton.engine.EndpointState |
getRemoteState() |
ProtonSessionImpl |
open()
Opens the AMQP session, i.e.
|
ProtonSessionImpl |
openHandler(Handler<AsyncResult<ProtonSession>> openHandler)
Sets a handler for when an AMQP Begin frame is received from the remote peer.
|
ProtonSession |
setCondition(org.apache.qpid.proton.amqp.transport.ErrorCondition condition)
Sets the local ErrorCondition object.
|
ProtonSession |
setIncomingCapacity(int bytes)
Sets the incoming capacity in bytes, used to govern session-level flow control.
|
void |
setOutgoingWindow(long outgoingWindowSize) |
public ProtonConnection getConnection()
ProtonSessiongetConnection in interface ProtonSessionpublic ProtonConnectionImpl getConnectionImpl()
public long getOutgoingWindow()
public ProtonSession setIncomingCapacity(int bytes)
ProtonSessionsetIncomingCapacity in interface ProtonSessionbytes - capacity in bytespublic int getOutgoingBytes()
public org.apache.qpid.proton.engine.EndpointState getRemoteState()
public int getIncomingBytes()
public org.apache.qpid.proton.amqp.transport.ErrorCondition getRemoteCondition()
ProtonSessiongetRemoteCondition in interface ProtonSessionpublic int getIncomingCapacity()
ProtonSessiongetIncomingCapacity in interface ProtonSessionpublic org.apache.qpid.proton.engine.EndpointState getLocalState()
public ProtonSession setCondition(org.apache.qpid.proton.amqp.transport.ErrorCondition condition)
ProtonSessionsetCondition in interface ProtonSessioncondition - the condition to setpublic org.apache.qpid.proton.amqp.transport.ErrorCondition getCondition()
ProtonSessiongetCondition in interface ProtonSessionpublic void setOutgoingWindow(long outgoingWindowSize)
public ProtonSessionImpl open()
ProtonSessionProtonSession.openHandler(Handler) may be used to handle the peer sending their
Begin frame.open in interface ProtonSessionpublic ProtonSessionImpl close()
ProtonSessionProtonSession.closeHandler(Handler) may be used to handle the peer
sending their End frame. When use of the session is complete, i.e it is locally and
remotely closed, ProtonSession.free() must be called to ensure related resources can be tidied up.close in interface ProtonSessionpublic ProtonSessionImpl openHandler(Handler<AsyncResult<ProtonSession>> openHandler)
ProtonSessionProtonConnection.sessionOpenHandler(Handler).openHandler in interface ProtonSessionopenHandler - the handlerpublic ProtonSessionImpl closeHandler(Handler<AsyncResult<ProtonSession>> closeHandler)
ProtonSessioncloseHandler in interface ProtonSessioncloseHandler - the handlerpublic ProtonReceiver createReceiver(String address)
ProtonSessioncreateReceiver in interface ProtonSessionaddress - The source address to attach the consumer to.public ProtonReceiver createReceiver(String address, ProtonLinkOptions receiverOptions)
ProtonSessioncreateReceiver in interface ProtonSessionaddress - The source address to attach the consumer to.receiverOptions - The options for this receiver.public ProtonSender createSender(String address)
ProtonSessioncreateSender in interface ProtonSessionaddress - The target address to attach to, or null to attach to the anonymous relay.public ProtonSender createSender(String address, ProtonLinkOptions senderOptions)
ProtonSessioncreateSender in interface ProtonSessionaddress - The target address to attach to, or null to attach to the anonymous relay.senderOptions - The options for this sender.public org.apache.qpid.proton.engine.Record attachments()
ProtonSessionattachments in interface ProtonSessionpublic void free()
ProtonSessionfree in interface ProtonSessionCopyright © 2020. All rights reserved.