00001 #ifndef _broker_MessageHandlerImpl_h
00002 #define _broker_MessageHandlerImpl_h
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022 #include <memory>
00023
00024 #include "qpid/framing/AMQP_ServerOperations.h"
00025 #include "qpid/framing/AMQP_ClientProxy.h"
00026 #include "HandlerImpl.h"
00027
00028 #include <boost/function.hpp>
00029
00030 namespace qpid {
00031 namespace broker {
00032
00033 class Connection;
00034 class Broker;
00035 class MessageMessage;
00036
00037 class MessageHandlerImpl :
00038 public framing::AMQP_ServerOperations::MessageHandler,
00039 public HandlerImpl
00040 {
00041 typedef boost::function<void(DeliveryId, DeliveryId)> RangedOperation;
00042 RangedOperation releaseOp;
00043 RangedOperation rejectOp;
00044
00045 public:
00046 MessageHandlerImpl(SemanticState&);
00047
00048 void append(const std::string& reference, const std::string& bytes);
00049
00050 void cancel(const std::string& destination );
00051
00052 void checkpoint(const std::string& reference,
00053 const std::string& identifier );
00054
00055 void close(const std::string& reference );
00056
00057 void empty();
00058
00059 void get(uint16_t ticket,
00060 const std::string& queue,
00061 const std::string& destination,
00062 bool noAck );
00063
00064 void offset(uint64_t value);
00065
00066 void ok();
00067
00068 void open(const std::string& reference );
00069
00070 void qos(uint32_t prefetchSize,
00071 uint16_t prefetchCount,
00072 bool global );
00073
00074 void recover(bool requeue );
00075
00076 void reject(const framing::SequenceNumberSet& transfers,
00077 uint16_t code,
00078 const std::string& text );
00079
00080 void resume(const std::string& reference,
00081 const std::string& identifier );
00082
00083 void flow(const std::string& destination, u_int8_t unit, u_int32_t value);
00084
00085 void flowMode(const std::string& destination, u_int8_t mode);
00086
00087 void flush(const std::string& destination);
00088
00089 void stop(const std::string& destination);
00090
00091 void acquire(const framing::SequenceNumberSet& transfers, u_int8_t mode);
00092
00093 void release(const framing::SequenceNumberSet& transfers);
00094
00095 void subscribe(u_int16_t ticket,
00096 const std::string& queue,
00097 const std::string& destination,
00098 bool noLocal,
00099 u_int8_t confirmMode,
00100 u_int8_t acquireMode,
00101 bool exclusive,
00102 const framing::FieldTable& filter);
00103
00104 };
00105
00106 }}
00107
00108
00109
00110 #endif