Proton DotNet
|
Base API for all AMQP Sender and Receiver links. More...
Public Member Functions | |
T | Detach () |
Detaches the local end of the link if not already closed or detached. | |
T | LocalDetachHandler (Action< T > localDetachHandler) |
Sets a Action for when an this endpoint is closed locally via a call to Close. This is a convenience event that supplements the normal locally closed event point if set. If no local detached event handler is set the endpoint will route the detached event to the local closed event handler if set and allow it to process the event in one location. Typically used by clients for logging or other state update event processing. Clients should not perform any blocking calls within this context. It is an error for the handler to throw an exception and the outcome of doing so is undefined. | |
T | DetachHandler (Action< T > detachHandler) |
Sets a EventHandler for when an AMQP detach frame is received from the remote peer. This is a convenience event that supplements the normal link closed event point if set. If no detached event handler is set the endpoint will route the detached event to the closed event handler if set and allow it to process the event in one location. | |
T | CreditStateUpdateHandler (Action< T > handler) |
Handler for link credit updates that occur after a remote flow frame arrives. | |
T | ParentEndpointClosedHandler (Action< T > handler) |
Sets a Action delegate for when the parent Session or Connection of this link is locally closed. Typically used by clients for logging or other state update event processing. Clients should not perform any blocking calls within this context. It is an error for the handler to throw an exception and the outcome of doing so is undefined. | |
![]() | |
T | Open () |
Open the end point locally, sending the Open performative immediately if possible or holding it until SASL negotiations or the AMQP header exchange and other required performative exchanges has completed. The endpoint will signal any registered handler of the remote opening the endpoint once the remote performative that signals open completion arrives. | |
T | Close () |
Close the end point locally and send the closing performative immediately if possible or holds it until the Connection / Engine state allows it. If the engine encounters an error writing the performative or the engine is in a failed state from a previous error then this method will throw an exception. If the engine has been shutdown then this method will close out the local end of the endpoint and clean up any local resources before returning normally. | |
T | LocalOpenHandler (Action< T > localOpenHandler) |
Sets a Action for when an this endpoint is opened locally via a call to Open. Typically used by clients for logging or other state update event processing. Clients should not perform any blocking calls within this context. It is an error for the handler to throw an exception and the outcome of doing so is undefined. Typically used by clients as servers will typically listen to some parent resource event handler to determine if the remote is initiating a resource open. | |
T | LocalCloseHandler (Action< T > localCloseHandler) |
Sets a Action for when an this endpoint is closed locally via a call to Close. Typically used by clients for logging or other state update event processing. Clients should not perform any blocking calls within this context. It is an error for the handler to throw an exception and the outcome of doing so is undefined. | |
T | OpenHandler (Action< T > localOpenHandler) |
Sets a Action for when an AMQP Open frame is received from the remote peer. Used to process remotely initiated Connections. Locally initiated sessions have their own Action invoked instead. This method is typically used by servers to listen for the remote peer to open its endpoint, while a client would listen for the server to open its end of the endpoint once a local open has been performed. Typically used by clients as servers will typically listen to some parent resource event handler to determine if the remote is initiating a resource open. | |
T | CloseHandler (Action< T > localCloseHandler) |
Sets a EventHandler for when an AMQP closing frame is received from the remote peer. | |
T | EngineShutdownHandler (Action< IEngine > shutdownHandler) |
Sets an Action that is invoked when the engine that supports this endpoint is shutdown which indicates a desire to terminate all engine operations. Any endpoint that has been both locally and remotely closed will not receive this event as it will no longer be tracked by the parent its parent endpoint. A typical use of this event would be from a locally closed endpoint that is awaiting response from the remote. If this event fires then there will never be a remote response to any pending operations and the client or server instance should react accordingly to clean up any related resources etc. | |
Properties | |
bool | IsLocallyDetached [get] |
Returns true if the endpoint having been previously locally opened is now detached due to a call the the detach method. This does not reflect the state of the remote endpoint and that should be checked separately. | |
bool | IsLocallyClosedOrDetached [get] |
Returns true if the endpoint having been previously locally opened is now detached or closed due to a call to either the close method or the detach method. This does not reflect the state of the remote endpoint and that should be checked separately. | |
LinkState | LinkState [get] |
Gets the current state of the local end of the link object. | |
uint | Credit [get] |
Reads the credit that is currently available on or assigned to this link object. | |
bool | IsDraining [get] |
Indicates if the link is draining. For a sender link this indicates that the remote has requested that the sender transmit deliveries up to the currently available credit or indicate that it has no more to send. For a receiver this indicates that the Receiver has requested that the remote sender consume its outstanding credit. | |
Role | Role [get] |
Reads the role assigned to the local end of the link. | |
bool | IsSender [get] |
Returns if this link is a sender link. | |
bool | IsReceiver [get] |
Returns if this link is a receiver link. | |
IConnection | Connection [get] |
Provides access to the connection that owns this sender endpoint. | |
ISession | Session [get] |
Provides access to the session that owns this sender endpoint. | |
string | Name [get] |
Access the name that was given to the link on creation. | |
SenderSettleMode | SenderSettleMode [get, set] |
Access the sender settle mode. Should only be called during link set-up, i.e. before calling open. If this endpoint is the initiator of the link, this method can be used to set a value other than the default. If this endpoint is not the initiator, this method should be used to set a local value. According to the AMQP spec, the application may choose to accept the sender's suggestion (accessed by calling the remote sender settle mode API) or choose another value. The value has no effect on Proton, but may be useful to the application at a later point. In order to be AMQP compliant the application is responsible for honoring the settlement mode. | |
ReceiverSettleMode | ReceiverSettleMode [get, set] |
Access the receiver settle mode. Should only be called during link set-up, i.e. before calling open. If this endpoint is the initiator of the link, this method can be used to set a value other than the default. | |
Source | Source [get, set] |
Sets the Source value to assign to the local end of this link. Must be called during link setup, i.e. before calling the open method. | |
Source | RemoteSource [get] |
Gets the Source value that was assigned by the remote end of the link. | |
ITerminus | Terminus [get, set] |
Gets the local Target terminus value as a generic terminus instance which the user can then interrogate to determine if it is a Target or a Coordinator instance. When set the value must be one of Target or Coordinator. | |
ITerminus | RemoteTerminus [get] |
Get the remote set Terminus either Target or Coordinator that is set once the remote sends its attach frame. | |
Coordinator | Coordinator [get, set] |
Attempt to access the local target terminus value as a Coordinator value. When reading if the target terminus is not a Coordinator the result is null. Must be called during link setup, i.e. before calling the open method. | |
Target | Target [get, set] |
Attempt to access the local target terminus value as a Target value. When reading if the target terminus is not a Target the result is null. Must be called during link setup, i.e. before calling the open method. | |
ulong | MaxMessageSize [get, set] |
Sets the local link max message size, to be conveyed to the peer via the Attach frame when attaching the link to the session. Null or 0 means no limit. Must be called during link setup, i.e. before calling the open method. | |
bool | IsRemotelyDetached [get] |
Returns true if this link is currently remotely detached meaning the state returned from the remote state accessor is equal to detached. A link is remotely detached after an Detach performative has been received from the remote with the close flag equal to false. | |
bool | IsRemotelyClosedOrDetached [get] |
Returns true if this link is currently remotely detached or closed meaning the state returned from the remote state accessor is equal to detached or to closed. A link is remotely detached after an Detach performative has been received from the remote with the close flag equal to false otherwise is considered closed.. | |
SenderSettleMode | RemoteSenderSettleMode [get] |
Gets the remote link sender settlement mode, as conveyed from the peer via the Attach frame when attaching the link to the session. | |
ReceiverSettleMode | RemoteReceiverSettleMode [get] |
Gets the remote link receiver settlement mode, as conveyed from the peer via the Attach frame when attaching the link to the session. | |
LinkState | RemoteState [get] |
Gets the current remote link state. | |
![]() | |
IEngine | Engine [get] |
Provides access to the engine instance that owns the resources of this endpoint and its parent. | |
IAttachments | Attachments [get] |
Access the attachments instance that is associated with this resource where the application can store data relevant to the endpoint for later use. | |
object | LinkedResource [get, set] |
Allows the endpoint to have some user defined resource linked to it which can be used to store application state data or other associated object instances with this endpoint. | |
ErrorCondition | ErrorCondition [get, set] |
Provides access to the error condition that should be applied to the AMQP frame that closes or ends this endpoint when the close method is called be the user. Setting this value after closing the endpoint has no effect. | |
ErrorCondition | RemoteErrorCondition [get] |
If the remote has closed this endpoint and provided an ErrorCondition as part of the closing AMQP performative then this method will return it. | |
bool | IsLocallyOpen [get] |
Returns true if the endpoint open was previously called and the close method has not yet been invoked. This only reflects the state on the local end and the user should also check the remote state. | |
bool | IsLocallyClosed [get] |
Returns true if the endpoint having been previously locally opened is now closed due to a call the the close method. This does not reflect the state of the remote endpoint and that should be checked separately. | |
bool | IsRemotelyOpen [get] |
Returns true if this endpoint is currently remotely open meaning that the AMQP performative that completes the open phase of this endpoint's lifetime has arrived but the performative that closes it has not. | |
bool | IsRemotelyClosed [get] |
Returns true if this endpoint is currently remotely closed meaning that the AMQP performative that completes the close phase of this endpoint's lifetime has arrived. | |
Symbol[] | OfferedCapabilities [get, set] |
Access the capabilities to be offered on to the remote when this endpoint is opened. The offered capabilities value can only be modified prior to a call to open, once the endpoint has been opened locally an error will be thrown if this method is called. | |
Symbol[] | DesiredCapabilities [get, set] |
Access the capabilities that are desired on to the remote when this endpoint is opened. The desired capabilities value can only be modified prior to a call to open, once the endpoint has been opened locally an error will be thrown if this method is called. | |
IReadOnlyDictionary< Symbol, object > | Properties [get, set] |
Access the properties that are conveyed to the remote when this endpoint is opened. The properties value can only be modified prior to a call to open, once the endpoint has been opened locally an error will be thrown if this method is called. | |
Symbol[] | RemoteOfferedCapabilities [get] |
The capabilities offered by the remote when it opened its end of the endpoint. | |
Symbol[] | RemoteDesiredCapabilities [get] |
The capabilities desired by the remote when it opened its end of the endpoint. | |
IReadOnlyDictionary< Symbol, object > | RemoteProperties [get] |
The properties sent by the remote when it opened its end of this endpoint. | |
Base API for all AMQP Sender and Receiver links.
T | The type of the class that implements the link |
T | : | ILink<T> |
T Apache.Qpid.Proton.Engine.ILink< T >.CreditStateUpdateHandler | ( | Action< T > | handler | ) |
Handler for link credit updates that occur after a remote flow frame arrives.
handler | The handler to invoke when the event occurs |
Implemented in Apache.Qpid.Proton.Engine.Implementation.ProtonLink< T >.
T Apache.Qpid.Proton.Engine.ILink< T >.Detach | ( | ) |
Detaches the local end of the link if not already closed or detached.
EngineStateException | If the engine state is already failed or shutdown |
Implemented in Apache.Qpid.Proton.Engine.Implementation.ProtonLink< T >.
T Apache.Qpid.Proton.Engine.ILink< T >.DetachHandler | ( | Action< T > | detachHandler | ) |
Sets a EventHandler for when an AMQP detach frame is received from the remote peer. This is a convenience event that supplements the normal link closed event point if set. If no detached event handler is set the endpoint will route the detached event to the closed event handler if set and allow it to process the event in one location.
detachHandler | The handler to invoke when the event occurs |
Implemented in Apache.Qpid.Proton.Engine.Implementation.ProtonLink< T >.
T Apache.Qpid.Proton.Engine.ILink< T >.LocalDetachHandler | ( | Action< T > | localDetachHandler | ) |
Sets a Action for when an this endpoint is closed locally via a call to Close. This is a convenience event that supplements the normal locally closed event point if set. If no local detached event handler is set the endpoint will route the detached event to the local closed event handler if set and allow it to process the event in one location. Typically used by clients for logging or other state update event processing. Clients should not perform any blocking calls within this context. It is an error for the handler to throw an exception and the outcome of doing so is undefined.
localCloseHandler | The handler to invoke when the event occurs |
Implemented in Apache.Qpid.Proton.Engine.Implementation.ProtonLink< T >.
T Apache.Qpid.Proton.Engine.ILink< T >.ParentEndpointClosedHandler | ( | Action< T > | handler | ) |
Sets a Action delegate for when the parent Session or Connection of this link is locally closed. Typically used by clients for logging or other state update event processing. Clients should not perform any blocking calls within this context. It is an error for the handler to throw an exception and the outcome of doing so is undefined.
handler | The handler to invoke when the event occurs |
Implemented in Apache.Qpid.Proton.Engine.Implementation.ProtonLink< T >.
|
get |
Provides access to the connection that owns this sender endpoint.
Implemented in Apache.Qpid.Proton.Engine.Implementation.ProtonLink< T >.
|
getset |
Attempt to access the local target terminus value as a Coordinator value. When reading if the target terminus is not a Coordinator the result is null. Must be called during link setup, i.e. before calling the open method.
Implemented in Apache.Qpid.Proton.Engine.Implementation.ProtonLink< T >.
|
get |
Reads the credit that is currently available on or assigned to this link object.
Implemented in Apache.Qpid.Proton.Engine.Implementation.ProtonLink< T >, Apache.Qpid.Proton.Engine.Implementation.ProtonReceiver, and Apache.Qpid.Proton.Engine.Implementation.ProtonSender.
|
get |
Indicates if the link is draining. For a sender link this indicates that the remote has requested that the sender transmit deliveries up to the currently available credit or indicate that it has no more to send. For a receiver this indicates that the Receiver has requested that the remote sender consume its outstanding credit.
Implemented in Apache.Qpid.Proton.Engine.Implementation.ProtonLink< T >, Apache.Qpid.Proton.Engine.Implementation.ProtonReceiver, and Apache.Qpid.Proton.Engine.Implementation.ProtonSender.
|
get |
Returns true if the endpoint having been previously locally opened is now detached or closed due to a call to either the close method or the detach method. This does not reflect the state of the remote endpoint and that should be checked separately.
Implemented in Apache.Qpid.Proton.Engine.Implementation.ProtonLink< T >.
|
get |
Returns true if the endpoint having been previously locally opened is now detached due to a call the the detach method. This does not reflect the state of the remote endpoint and that should be checked separately.
Implemented in Apache.Qpid.Proton.Engine.Implementation.ProtonLink< T >.
|
get |
Returns if this link is a receiver link.
Implemented in Apache.Qpid.Proton.Engine.Implementation.ProtonLink< T >.
|
get |
Returns true if this link is currently remotely detached or closed meaning the state returned from the remote state accessor is equal to detached or to closed. A link is remotely detached after an Detach performative has been received from the remote with the close flag equal to false otherwise is considered closed..
Implemented in Apache.Qpid.Proton.Engine.Implementation.ProtonLink< T >.
|
get |
Returns true if this link is currently remotely detached meaning the state returned from the remote state accessor is equal to detached. A link is remotely detached after an Detach performative has been received from the remote with the close flag equal to false.
Implemented in Apache.Qpid.Proton.Engine.Implementation.ProtonLink< T >.
|
get |
Returns if this link is a sender link.
Implemented in Apache.Qpid.Proton.Engine.Implementation.ProtonLink< T >.
Gets the current state of the local end of the link object.
Implemented in Apache.Qpid.Proton.Engine.Implementation.ProtonLink< T >.
|
getset |
Sets the local link max message size, to be conveyed to the peer via the Attach frame when attaching the link to the session. Null or 0 means no limit. Must be called during link setup, i.e. before calling the open method.
Implemented in Apache.Qpid.Proton.Engine.Implementation.ProtonLink< T >.
|
get |
Access the name that was given to the link on creation.
Implemented in Apache.Qpid.Proton.Engine.Implementation.ProtonLink< T >.
|
getset |
Access the receiver settle mode. Should only be called during link set-up, i.e. before calling open. If this endpoint is the initiator of the link, this method can be used to set a value other than the default.
Implemented in Apache.Qpid.Proton.Engine.Implementation.ProtonLink< T >.
|
get |
Gets the remote link receiver settlement mode, as conveyed from the peer via the Attach frame when attaching the link to the session.
Implemented in Apache.Qpid.Proton.Engine.Implementation.ProtonLink< T >.
|
get |
Gets the remote link sender settlement mode, as conveyed from the peer via the Attach frame when attaching the link to the session.
Implemented in Apache.Qpid.Proton.Engine.Implementation.ProtonLink< T >.
|
get |
Gets the Source value that was assigned by the remote end of the link.
Implemented in Apache.Qpid.Proton.Engine.Implementation.ProtonLink< T >.
|
get |
Gets the current remote link state.
Implemented in Apache.Qpid.Proton.Engine.Implementation.ProtonLink< T >.
|
get |
Get the remote set Terminus either Target or Coordinator that is set once the remote sends its attach frame.
Implemented in Apache.Qpid.Proton.Engine.Implementation.ProtonLink< T >.
|
get |
Reads the role assigned to the local end of the link.
Implemented in Apache.Qpid.Proton.Engine.Implementation.ProtonLink< T >, Apache.Qpid.Proton.Engine.Implementation.ProtonReceiver, and Apache.Qpid.Proton.Engine.Implementation.ProtonSender.
|
getset |
Access the sender settle mode. Should only be called during link set-up, i.e. before calling open. If this endpoint is the initiator of the link, this method can be used to set a value other than the default. If this endpoint is not the initiator, this method should be used to set a local value. According to the AMQP spec, the application may choose to accept the sender's suggestion (accessed by calling the remote sender settle mode API) or choose another value. The value has no effect on Proton, but may be useful to the application at a later point. In order to be AMQP compliant the application is responsible for honoring the settlement mode.
Implemented in Apache.Qpid.Proton.Engine.Implementation.ProtonLink< T >.
|
get |
Provides access to the session that owns this sender endpoint.
Implemented in Apache.Qpid.Proton.Engine.Implementation.ProtonLink< T >.
|
getset |
Sets the Source value to assign to the local end of this link. Must be called during link setup, i.e. before calling the open method.
Implemented in Apache.Qpid.Proton.Engine.Implementation.ProtonLink< T >.
|
getset |
Attempt to access the local target terminus value as a Target value. When reading if the target terminus is not a Target the result is null. Must be called during link setup, i.e. before calling the open method.
Implemented in Apache.Qpid.Proton.Engine.Implementation.ProtonLink< T >.
|
getset |
Gets the local Target terminus value as a generic terminus instance which the user can then interrogate to determine if it is a Target or a Coordinator instance. When set the value must be one of Target or Coordinator.
Implemented in Apache.Qpid.Proton.Engine.Implementation.ProtonLink< T >.