Qpid Proton C++  0.14.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Pages
sender_options.hpp
1 #ifndef PROTON_SENDER_OPTIONS_HPP
2 #define PROTON_SENDER_OPTIONS_HPP
3 
4 /*
5  *
6  * Licensed to the Apache Software Foundation (ASF) under one
7  * or more contributor license agreements. See the NOTICE file
8  * distributed with this work for additional information
9  * regarding copyright ownership. The ASF licenses this file
10  * to you under the Apache License, Version 2.0 (the
11  * "License"); you may not use this file except in compliance
12  * with the License. You may obtain a copy of the License at
13  *
14  * http://www.apache.org/licenses/LICENSE-2.0
15  *
16  * Unless required by applicable law or agreed to in writing,
17  * software distributed under the License is distributed on an
18  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
19  * KIND, either express or implied. See the License for the
20  * specific language governing permissions and limitations
21  * under the License.
22  *
23  */
24 
25 #include "./internal/config.hpp"
26 #include "./internal/export.hpp"
27 #include "./internal/pn_unique_ptr.hpp"
28 #include "./types.hpp"
29 #include "./delivery_mode.hpp"
30 #include "./terminus.hpp"
31 
32 #include <vector>
33 #include <string>
34 
35 namespace proton {
36 
37 class proton_handler;
38 class sender;
39 class source_options;
40 class target_options;
41 
63 // XXX opts.browsing is not a good example here
65  public:
67  PN_CPP_EXTERN sender_options();
68 
70  PN_CPP_EXTERN sender_options(const sender_options&);
71 
72  PN_CPP_EXTERN ~sender_options();
73 
75  PN_CPP_EXTERN sender_options& operator=(const sender_options&);
76 
78  PN_CPP_EXTERN void update(const sender_options& other);
79 
84  PN_CPP_EXTERN sender_options& handler(class messaging_handler&);
85 
87  PN_CPP_EXTERN sender_options& delivery_mode(delivery_mode);
88 
90  PN_CPP_EXTERN sender_options& auto_settle(bool);
91 
93  PN_CPP_EXTERN sender_options& source(source_options &);
94 
96  PN_CPP_EXTERN sender_options& target(target_options &);
97 
99  private:
100  void apply(sender&) const;
101 
102  class impl;
103  internal::pn_unique_ptr<impl> impl_;
104 
105  friend class sender;
107 };
108 
109 } // proton
110 
111 #endif // PROTON_SENDER_OPTIONS_HPP
void update(const sender_options &other)
Merge with another option set.
sender_options & handler(class messaging_handler &)
Set a messaging_handler for sender events only.
sender_options()
Create an empty set of options.
A channel for sending messages.
Definition: sender.hpp:40
Options for creating a sender.
Definition: sender_options.hpp:64
sender_options & delivery_mode(delivery_mode)
Set the delivery mode on the sender.
Include the definitions of all proton types used to represent AMQP types.
sender_options & operator=(const sender_options &)
Copy options.
The message delivery policy to establish when opening a link.
Definition: delivery_mode.hpp:30
Options for creating a source node for a sender or receiver.
Definition: source_options.hpp:45
sender_options & target(target_options &)
Options for the receiver node of the receiver.
A handler for Proton messaging events.
Definition: messaging_handler.hpp:74
sender_options & auto_settle(bool)
Automatically settle messages (default is true).
sender_options & source(source_options &)
Options for the source node of the sender.
Options for creating a target node for a sender or receiver.
Definition: target_options.hpp:47