diff options
| author | Alan Conway <aconway@apache.org> | 2009-05-01 14:53:05 +0000 |
|---|---|---|
| committer | Alan Conway <aconway@apache.org> | 2009-05-01 14:53:05 +0000 |
| commit | dd79366789a749856de0e41633146340c2b79f9a (patch) | |
| tree | 69e792e992a3071a19c112d6bd9d715f4ce1d27e /cpp/src/qpid/client/Subscription.h | |
| parent | db687f6ce97fe987936711f9c46966d45cf24834 (diff) | |
| download | qpid-python-dd79366789a749856de0e41633146340c2b79f9a.tar.gz | |
Cleaned up PIMPL pattern for public API
- Separated PrivateImplRef helper classs from Handler base class.
- Consistent impl of ctor, dtor, copy, assign for all PIMPL classes.
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@770702 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/src/qpid/client/Subscription.h')
| -rw-r--r-- | cpp/src/qpid/client/Subscription.h | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/cpp/src/qpid/client/Subscription.h b/cpp/src/qpid/client/Subscription.h index 43c6100254..f39cdd50ac 100644 --- a/cpp/src/qpid/client/Subscription.h +++ b/cpp/src/qpid/client/Subscription.h @@ -22,15 +22,16 @@ * */ +#include "qpid/client/Handle.h" #include "qpid/client/Session.h" #include "qpid/client/SubscriptionSettings.h" -#include "qpid/client/Handle.h" #include "qpid/client/Message.h" #include "qpid/client/ClientImportExport.h" namespace qpid { namespace client { +template <class> class PrivateImplRef; class SubscriptionImpl; class SubscriptionManager; @@ -40,7 +41,11 @@ class SubscriptionManager; */ class Subscription : public Handle<SubscriptionImpl> { public: - QPID_CLIENT_EXTERN Subscription(SubscriptionImpl* si=0) : Handle<SubscriptionImpl>(si) {} + QPID_CLIENT_EXTERN Subscription(SubscriptionImpl* = 0); + QPID_CLIENT_EXTERN Subscription(const Subscription&); + QPID_CLIENT_EXTERN ~Subscription(); + QPID_CLIENT_EXTERN Subscription& operator=(const Subscription&); + /** The name of the subscription, used as the "destination" for messages from the broker. * Usually the same as the queue name but can be set differently. @@ -109,6 +114,8 @@ class Subscription : public Handle<SubscriptionImpl> { /** Grant the specified amount of byte credit */ QPID_CLIENT_EXTERN void grantByteCredit(uint32_t); + private: + friend class PrivateImplRef<Subscription>; friend class SubscriptionManager; }; }} // namespace qpid::client |
