summaryrefslogtreecommitdiff
path: root/cpp/src/qpid/client/LocalQueue.h
diff options
context:
space:
mode:
Diffstat (limited to 'cpp/src/qpid/client/LocalQueue.h')
-rw-r--r--cpp/src/qpid/client/LocalQueue.h22
1 files changed, 13 insertions, 9 deletions
diff --git a/cpp/src/qpid/client/LocalQueue.h b/cpp/src/qpid/client/LocalQueue.h
index 5b739d4303..4aa14ce004 100644
--- a/cpp/src/qpid/client/LocalQueue.h
+++ b/cpp/src/qpid/client/LocalQueue.h
@@ -23,14 +23,16 @@
*/
#include "ClientImportExport.h"
-#include "qpid/client/Message.h"
-#include "qpid/client/Subscription.h"
-#include "qpid/client/Demux.h"
+#include "Handle.h"
+#include "Message.h"
#include "qpid/sys/Time.h"
namespace qpid {
namespace client {
+class LocalQueueImpl;
+template <class T> class PrivateImplRef;
+
/**
* A local queue to collect messages retrieved from a remote broker
* queue. Create a queue and subscribe it using the SubscriptionManager.
@@ -69,7 +71,7 @@ namespace client {
* </ul>
*/
-class LocalQueue {
+class LocalQueue : public Handle<LocalQueueImpl> {
public:
/** Create a local queue. Subscribe the local queue to a remote broker
* queue with a SubscriptionManager.
@@ -77,8 +79,9 @@ class LocalQueue {
* LocalQueue is an alternative to implementing a MessageListener.
*/
QPID_CLIENT_EXTERN LocalQueue();
-
+ QPID_CLIENT_EXTERN LocalQueue(const LocalQueue&);
QPID_CLIENT_EXTERN ~LocalQueue();
+ QPID_CLIENT_EXTERN LocalQueue& operator=(const LocalQueue&);
/** Wait up to timeout for the next message from the local queue.
*@param result Set to the message from the queue.
@@ -104,11 +107,12 @@ class LocalQueue {
/** Number of messages on the local queue */
QPID_CLIENT_EXTERN size_t size() const;
- private:
- Demux::QueuePtr queue;
- Subscription subscription;
+ QPID_CLIENT_EXTERN LocalQueue(LocalQueueImpl*); ///<@internal
- friend class SubscriptionManager;
+
+ private:
+ typedef LocalQueueImpl Impl;
+ friend class PrivateImplRef<LocalQueue>;
};
}} // namespace qpid::client