util/queue/PublishQueueEntry.h

Go to the documentation of this file.
00001 /*------------------------------------------------------------------------------
00002 Name:      PublishQueueEntry.h
00003 Project:   xmlBlaster.org
00004 Copyright: xmlBlaster.org, see xmlBlaster-LICENSE file
00005 ------------------------------------------------------------------------------*/
00006 #ifndef _UTIL_QUEUE_PUBLISHQUEUEENRY_H
00007 #define _UTIL_QUEUE_PUBLISHQUEUEENRY_H
00008 
00009 #include <util/MethodName.h>
00010 #include <util/queue/MsgQueueEntry.h>
00011 
00021 namespace org { namespace xmlBlaster { namespace util { namespace queue {
00022 
00023 class Dll_Export PublishQueueEntry : public org::xmlBlaster::util::queue::MsgQueueEntry
00024 {
00025 public:
00026 
00034    PublishQueueEntry(org::xmlBlaster::util::Global& global,
00035                      const org::xmlBlaster::util::MessageUnit& msgUnit,
00036                      int priority=NORM_PRIORITY,
00037                      org::xmlBlaster::util::Timestamp uniqueId = TimestampFactory::getInstance().getTimestamp());
00038 
00039    ~PublishQueueEntry();
00040 
00044    PublishQueueEntry(const PublishQueueEntry& entry);
00045 
00049    PublishQueueEntry& operator =(const PublishQueueEntry& entry);
00050 
00051    MsgQueueEntry *getClone() const;
00052    
00053    virtual bool isPublish() const;
00054 
00060    // this should actually be in another interface but since it is an only method we put it here.
00061    const org::xmlBlaster::util::queue::MsgQueueEntry& send(org::xmlBlaster::util::dispatch::I_ConnectionsHandler& connectionsHandler) const;
00062 
00063    size_t getSizeInBytes() const;
00064 
00065    const org::xmlBlaster::client::qos::PublishReturnQos* getPublishReturnQos() const;
00066 
00067    std::string toXml(const std::string& indent="") const;
00068 
00069 };
00070 
00071 }}}} // namespace
00072 
00073 #endif
00074