Qpid Proton C++ API
0.32.0
|
|
Go to the documentation of this file. 1 #ifndef PROTON_SESSION_HPP
2 #define PROTON_SESSION_HPP
26 #include "./internal/export.hpp"
42 PN_CPP_CLASS_EXTERN
session :
public internal::object<pn_session_t>,
public endpoint {
45 PN_CPP_EXTERN
session(pn_session_t* s) : internal::object<pn_session_t>(s) {}
50 session() : internal::object<pn_session_t>(0) {}
56 PN_CPP_EXTERN
bool closed()
const;
97 PN_CPP_EXTERN sender_range
senders()
const;
103 friend class internal::factory<
session>;
104 friend class session_iterator;
111 class session_iterator :
public internal::iter_base<session, session_iterator> {
113 explicit session_iterator(
session s = 0) : internal::iter_base<
session, session_iterator>(s) {}
116 PN_CPP_EXTERN session_iterator operator++();
120 typedef internal::iter_range<session_iterator> session_range;
126 #endif // PROTON_SESSION_HPP
size_t outgoing_bytes() const
The number of outgoing bytes currently buffered.
Describes an endpoint error state.
Definition: error_condition.hpp:40
receiver open_receiver(const std::string &addr, const receiver_options &opts)
Open a receiver for addr.
The base Proton error.
Definition: error.hpp:41
A top-level container of connections, sessions, and links.
Definition: container.hpp:50
The base class for session, connection, and link.
Definition: endpoint.hpp:37
sender open_sender(const std::string &addr)
Open a sender for addr.
Options for creating a receiver.
Definition: receiver_options.hpp:56
A connection to a remote AMQP peer.
Definition: connection.hpp:45
A channel for receiving messages.
Definition: receiver.hpp:41
receiver_range receivers() const
Return the receivers on this session.
void open(const session_options &opts)
Open the session.
A channel for receiving messages.
The base class for session, connection, and link.
sender open_sender(const std::string &addr, const sender_options &opts)
Open a sender for addr.
Options for creating a sender.
Definition: sender_options.hpp:57
A channel for sending messages.
void close()
Close the endpoint.
void open()
Open the session.
Options for creating a session.
Definition: session_options.hpp:40
receiver open_receiver(const std::string &addr)
Open a receiver for addr.
A channel for sending messages.
Definition: sender.hpp:40
class container & container() const
Get the container for this session.
bool active() const
True if the local end is active.
bool uninitialized() const
True if the local end is uninitialized.
sender_range senders() const
Return the senders on this session.
The main Proton namespace.
Definition: annotation_key.hpp:33
A container of senders and receivers.
Definition: session.hpp:42
void close(const error_condition &)
Close the endpoint with an error condition.
class work_queue & work_queue() const
Get the work_queue for the session.
size_t incoming_bytes() const
The number of incoming bytes currently buffered.
session()
Create an empty session.
Definition: session.hpp:50
Unsettled API - A context for thread-safe execution of work.
Definition: work_queue.hpp:339