Qpid Proton C++
0.12.1
|
Options for creating a link. More...
#include <link_options.hpp>
Public Types | |
enum | delivery_mode { DELIVERY_MODE_NONE, AT_MOST_ONCE, AT_LEAST_ONCE } |
The message delivery policy to establish when opening a link. | |
enum | sender_settle_mode { UNSETTLED, SETTLED, MIXED } |
Sender settlement behaviour for a link. | |
enum | lifetime_policy { LIFETIME_UNSPECIFIED, DELETE_ON_CLOSE, DELETE_ON_NO_LINKS, DELETE_ON_NO_MESSAGES, DELETE_ON_NO_LINKS_OR_MESSAGES } |
The lifetime of dynamically created nodes. | |
Public Member Functions | |
link_options () | |
Create an empty set of options. | |
link_options (const link_options &) | |
Copy options. | |
link_options & | operator= (const link_options &) |
Copy options. | |
void | override (const link_options &other) |
Override with options from other. | |
link_options & | handler (class handler *) |
Set a handler for events scoped to the link. More... | |
link_options & | browsing (bool) |
Receiver-only option to specify whether messages are browsed or consumed. More... | |
link_options & | distribution_mode (enum terminus::distribution_mode) |
Set the distribution mode for message transfer. | |
link_options & | durable_subscription (bool) |
Receiver-only option to create a durable subsription on the receiver. More... | |
link_options & | delivery_mode (delivery_mode) |
Set the delivery mode on the link. | |
link_options & | dynamic_address (bool) |
Request a dynamically generated node at the peer. | |
link_options & | lifetime_policy (lifetime_policy) |
Set the lifetime policy for a receiver to a dynamically created node. More... | |
link_options & | local_address (const std::string &addr) |
Set the local address for the link. | |
Options for creating a link.
Options can be "chained" like this:
You can also create an options object with common settings and use it as a base for different connections that have mostly the same settings:
Normal value semantics: copy or assign creates a separate copy of the options.
link_options& browsing | ( | bool | ) |
Receiver-only option to specify whether messages are browsed or consumed.
Setting browsing to true is equivalent to setting distribution_mode(COPY). Setting browsing to false is equivalent to setting distribution_mode(MOVE).
link_options& durable_subscription | ( | bool | ) |
Receiver-only option to create a durable subsription on the receiver.
Equivalent to setting the terminus durability to terminus::DELIVERIES and the expiry policy to terminus::EXPIRE_NEVER.
link_options& handler | ( | class handler * | ) |
Set a handler for events scoped to the link.
If NULL, link-scoped events on the link are discarded.
Set the lifetime policy for a receiver to a dynamically created node.