diff options
Diffstat (limited to 'qpid/cpp/src')
-rw-r--r-- | qpid/cpp/src/qmf.mk | 22 | ||||
-rw-r--r-- | qpid/cpp/src/qmf/AgentEngine.cpp (renamed from qpid/cpp/src/qmf/Agent.cpp) | 154 | ||||
-rw-r--r-- | qpid/cpp/src/qmf/AgentEngine.h (renamed from qpid/cpp/src/qmf/Agent.h) | 25 | ||||
-rw-r--r-- | qpid/cpp/src/qmf/ConsoleEngine.h (renamed from qpid/cpp/src/qmf/Console.h) | 13 | ||||
-rw-r--r-- | qpid/cpp/src/qmf/Object.h | 2 |
5 files changed, 110 insertions, 106 deletions
diff --git a/qpid/cpp/src/qmf.mk b/qpid/cpp/src/qmf.mk index 62393cdcfb..8ccc1f4a95 100644 --- a/qpid/cpp/src/qmf.mk +++ b/qpid/cpp/src/qmf.mk @@ -18,7 +18,7 @@ # # -# qmf agent library makefile fragment, to be included in Makefile.am +# qmf library makefile fragment, to be included in Makefile.am # lib_LTLIBRARIES += \ libqmfcommon.la \ @@ -27,13 +27,15 @@ lib_LTLIBRARIES += \ # Public header files nobase_include_HEADERS += \ ../include/qpid/agent/ManagementAgent.h \ - ../include/qpid/agent/QmfAgentImportExport.h - + ../include/qpid/agent/QmfAgentImportExport.h \ + ../include/qmf/Agent.h \ + ../include/qmf/Connection.h \ + ../include/qmf/QmfImportExport.h \ + ../include/qmf/ConnectionSettings.h \ + ../include/qmf/AgentObject.h libqmfcommon_la_SOURCES = \ - qmf/Agent.cpp \ - qmf/Agent.h \ - qmf/Console.h \ + qmf/ConsoleEngine.h \ qmf/Event.h \ qmf/Message.h \ qmf/MessageImpl.cpp \ @@ -58,9 +60,9 @@ libqmfcommon_la_SOURCES = \ qmf/ValueImpl.h libqmfagent_la_SOURCES = \ - ../include/qpid/agent/ManagementAgent.h \ + qmf/AgentEngine.cpp \ + qmf/AgentEngine.h \ qpid/agent/ManagementAgentImpl.cpp \ - qpid/agent/ManagementAgentImpl.h \ - qmf/Agent.cpp + qpid/agent/ManagementAgentImpl.h -libqmfagent_la_LIBADD = libqpidclient.la +libqmfagent_la_LIBADD = libqpidclient.la libqmfcommon.la diff --git a/qpid/cpp/src/qmf/Agent.cpp b/qpid/cpp/src/qmf/AgentEngine.cpp index 6d59ae2750..bef8b3d102 100644 --- a/qpid/cpp/src/qmf/Agent.cpp +++ b/qpid/cpp/src/qmf/AgentEngine.cpp @@ -17,7 +17,7 @@ * under the License. */ -#include "qmf/Agent.h" +#include "qmf/AgentEngine.h" #include "qmf/MessageImpl.h" #include "qmf/SchemaImpl.h" #include "qmf/Typecode.h" @@ -77,13 +77,13 @@ namespace qmf { AgentQueryContext() : schemaMethod(0) {} }; - class AgentImpl { + class AgentEngineImpl { public: - AgentImpl(char* label, bool internalStore); - ~AgentImpl(); + AgentEngineImpl(char* label, bool internalStore); + ~AgentEngineImpl(); - void setStoreDir(char* path); - void setTransferDir(char* path); + void setStoreDir(const char* path); + void setTransferDir(const char* path); void handleRcvMessage(Message& message); bool getXmtMessage(Message& item); void popXmt(); @@ -200,9 +200,9 @@ namespace qmf { }; } -const char* AgentImpl::QMF_EXCHANGE = "qpid.management"; -const char* AgentImpl::DIR_EXCHANGE = "amq.direct"; -const char* AgentImpl::BROKER_KEY = "broker"; +const char* AgentEngineImpl::QMF_EXCHANGE = "qpid.management"; +const char* AgentEngineImpl::DIR_EXCHANGE = "amq.direct"; +const char* AgentEngineImpl::BROKER_KEY = "broker"; #define STRING_REF(s) {if (!s.empty()) item.s = const_cast<char*>(s.c_str());} @@ -228,7 +228,7 @@ AgentEvent AgentEventImpl::copy() return item; } -AgentImpl::AgentImpl(char* _label, bool i) : +AgentEngineImpl::AgentEngineImpl(char* _label, bool i) : label(_label), queueName("qmfa-"), internalStore(i), nextTransientId(1), requestedBrokerBank(0), requestedAgentBank(0), assignedBrokerBank(0), assignedAgentBank(0), @@ -237,11 +237,11 @@ AgentImpl::AgentImpl(char* _label, bool i) : queueName += label; } -AgentImpl::~AgentImpl() +AgentEngineImpl::~AgentEngineImpl() { } -void AgentImpl::setStoreDir(char* path) +void AgentEngineImpl::setStoreDir(const char* path) { Mutex::ScopedLock _lock(lock); if (path) @@ -250,7 +250,7 @@ void AgentImpl::setStoreDir(char* path) storeDir.clear(); } -void AgentImpl::setTransferDir(char* path) +void AgentEngineImpl::setTransferDir(const char* path) { Mutex::ScopedLock _lock(lock); if (path) @@ -259,7 +259,7 @@ void AgentImpl::setTransferDir(char* path) transferDir.clear(); } -void AgentImpl::handleRcvMessage(Message& message) +void AgentEngineImpl::handleRcvMessage(Message& message) { Buffer inBuffer(message.body, message.length); uint8_t opcode; @@ -277,7 +277,7 @@ void AgentImpl::handleRcvMessage(Message& message) } } -bool AgentImpl::getXmtMessage(Message& item) +bool AgentEngineImpl::getXmtMessage(Message& item) { Mutex::ScopedLock _lock(lock); if (xmtQueue.empty()) @@ -286,14 +286,14 @@ bool AgentImpl::getXmtMessage(Message& item) return true; } -void AgentImpl::popXmt() +void AgentEngineImpl::popXmt() { Mutex::ScopedLock _lock(lock); if (!xmtQueue.empty()) xmtQueue.pop_front(); } -bool AgentImpl::getEvent(AgentEvent& event) +bool AgentEngineImpl::getEvent(AgentEvent& event) { Mutex::ScopedLock _lock(lock); if (eventQueue.empty()) @@ -302,14 +302,14 @@ bool AgentImpl::getEvent(AgentEvent& event) return true; } -void AgentImpl::popEvent() +void AgentEngineImpl::popEvent() { Mutex::ScopedLock _lock(lock); if (!eventQueue.empty()) eventQueue.pop_front(); } -void AgentImpl::newSession() +void AgentEngineImpl::newSession() { Mutex::ScopedLock _lock(lock); eventQueue.clear(); @@ -319,7 +319,7 @@ void AgentImpl::newSession() eventQueue.push_back(eventSetupComplete()); } -void AgentImpl::startProtocol() +void AgentEngineImpl::startProtocol() { Mutex::ScopedLock _lock(lock); char rawbuffer[512]; @@ -335,7 +335,7 @@ void AgentImpl::startProtocol() " reqAgent=" << requestedAgentBank); } -void AgentImpl::heartbeat() +void AgentEngineImpl::heartbeat() { Mutex::ScopedLock _lock(lock); Buffer buffer(outputBuffer, MA_BUFFER_SIZE); @@ -348,7 +348,7 @@ void AgentImpl::heartbeat() QPID_LOG(trace, "SENT HeartbeatIndication"); } -void AgentImpl::methodResponse(uint32_t sequence, uint32_t status, char* text, +void AgentEngineImpl::methodResponse(uint32_t sequence, uint32_t status, char* text, const Value& argMap) { Mutex::ScopedLock _lock(lock); @@ -381,7 +381,7 @@ void AgentImpl::methodResponse(uint32_t sequence, uint32_t status, char* text, QPID_LOG(trace, "SENT MethodResponse"); } -void AgentImpl::queryResponse(uint32_t sequence, Object& object, bool prop, bool stat) +void AgentEngineImpl::queryResponse(uint32_t sequence, Object& object, bool prop, bool stat) { Mutex::ScopedLock _lock(lock); map<uint32_t, AgentQueryContext::Ptr>::iterator iter = contextMap.find(sequence); @@ -403,7 +403,7 @@ void AgentImpl::queryResponse(uint32_t sequence, Object& object, bool prop, bool QPID_LOG(trace, "SENT ContentIndication"); } -void AgentImpl::queryComplete(uint32_t sequence) +void AgentEngineImpl::queryComplete(uint32_t sequence) { Mutex::ScopedLock _lock(lock); map<uint32_t, AgentQueryContext::Ptr>::iterator iter = contextMap.find(sequence); @@ -415,7 +415,7 @@ void AgentImpl::queryComplete(uint32_t sequence) sendCommandCompleteLH(context->exchange, context->key, context->sequence, 0, "OK"); } -void AgentImpl::registerClass(SchemaObjectClass* cls) +void AgentEngineImpl::registerClass(SchemaObjectClass* cls) { Mutex::ScopedLock _lock(lock); SchemaObjectClassImpl* impl = cls->impl; @@ -433,7 +433,7 @@ void AgentImpl::registerClass(SchemaObjectClass* cls) // TODO: Indicate this schema if connected. } -void AgentImpl::registerClass(SchemaEventClass* cls) +void AgentEngineImpl::registerClass(SchemaEventClass* cls) { Mutex::ScopedLock _lock(lock); SchemaEventClassImpl* impl = cls->impl; @@ -451,13 +451,13 @@ void AgentImpl::registerClass(SchemaEventClass* cls) // TODO: Indicate this schema if connected. } -const ObjectId* AgentImpl::addObject(Object&, uint64_t) +const ObjectId* AgentEngineImpl::addObject(Object&, uint64_t) { Mutex::ScopedLock _lock(lock); return 0; } -const ObjectId* AgentImpl::allocObjectId(uint64_t persistId) +const ObjectId* AgentEngineImpl::allocObjectId(uint64_t persistId) { Mutex::ScopedLock _lock(lock); uint16_t sequence = persistId ? 0 : bootSequence; @@ -467,17 +467,17 @@ const ObjectId* AgentImpl::allocObjectId(uint64_t persistId) return oid->envelope; } -const ObjectId* AgentImpl::allocObjectId(uint32_t persistIdLo, uint32_t persistIdHi) +const ObjectId* AgentEngineImpl::allocObjectId(uint32_t persistIdLo, uint32_t persistIdHi) { return allocObjectId(((uint64_t) persistIdHi) << 32 | (uint64_t) persistIdLo); } -void AgentImpl::raiseEvent(Event&) +void AgentEngineImpl::raiseEvent(Event&) { Mutex::ScopedLock _lock(lock); } -void AgentImpl::encodeHeader(Buffer& buf, uint8_t opcode, uint32_t seq) +void AgentEngineImpl::encodeHeader(Buffer& buf, uint8_t opcode, uint32_t seq) { buf.putOctet('A'); buf.putOctet('M'); @@ -486,7 +486,7 @@ void AgentImpl::encodeHeader(Buffer& buf, uint8_t opcode, uint32_t seq) buf.putLong (seq); } -bool AgentImpl::checkHeader(Buffer& buf, uint8_t *opcode, uint32_t *seq) +bool AgentEngineImpl::checkHeader(Buffer& buf, uint8_t *opcode, uint32_t *seq) { if (buf.getSize() < 8) return false; @@ -501,7 +501,7 @@ bool AgentImpl::checkHeader(Buffer& buf, uint8_t *opcode, uint32_t *seq) return h1 == 'A' && h2 == 'M' && h3 == '3'; } -AgentEventImpl::Ptr AgentImpl::eventDeclareQueue(const string& name) +AgentEventImpl::Ptr AgentEngineImpl::eventDeclareQueue(const string& name) { AgentEventImpl::Ptr event(new AgentEventImpl(AgentEvent::DECLARE_QUEUE)); event->name = name; @@ -509,8 +509,8 @@ AgentEventImpl::Ptr AgentImpl::eventDeclareQueue(const string& name) return event; } -AgentEventImpl::Ptr AgentImpl::eventBind(const string& exchange, const string& queue, - const string& key) +AgentEventImpl::Ptr AgentEngineImpl::eventBind(const string& exchange, const string& queue, + const string& key) { AgentEventImpl::Ptr event(new AgentEventImpl(AgentEvent::BIND)); event->name = queue; @@ -520,14 +520,14 @@ AgentEventImpl::Ptr AgentImpl::eventBind(const string& exchange, const string& q return event; } -AgentEventImpl::Ptr AgentImpl::eventSetupComplete() +AgentEventImpl::Ptr AgentEngineImpl::eventSetupComplete() { AgentEventImpl::Ptr event(new AgentEventImpl(AgentEvent::SETUP_COMPLETE)); return event; } -AgentEventImpl::Ptr AgentImpl::eventQuery(uint32_t num, const string& userId, const string& package, - const string& cls, boost::shared_ptr<ObjectId> oid) +AgentEventImpl::Ptr AgentEngineImpl::eventQuery(uint32_t num, const string& userId, const string& package, + const string& cls, boost::shared_ptr<ObjectId> oid) { AgentEventImpl::Ptr event(new AgentEventImpl(AgentEvent::GET_QUERY)); event->sequence = num; @@ -538,9 +538,9 @@ AgentEventImpl::Ptr AgentImpl::eventQuery(uint32_t num, const string& userId, co return event; } -AgentEventImpl::Ptr AgentImpl::eventMethod(uint32_t num, const string& userId, const string& method, - boost::shared_ptr<ObjectId> oid, boost::shared_ptr<Value> argMap, - SchemaObjectClass* objectClass) +AgentEventImpl::Ptr AgentEngineImpl::eventMethod(uint32_t num, const string& userId, const string& method, + boost::shared_ptr<ObjectId> oid, boost::shared_ptr<Value> argMap, + SchemaObjectClass* objectClass) { AgentEventImpl::Ptr event(new AgentEventImpl(AgentEvent::METHOD_CALL)); event->sequence = num; @@ -552,7 +552,7 @@ AgentEventImpl::Ptr AgentImpl::eventMethod(uint32_t num, const string& userId, c return event; } -void AgentImpl::sendBufferLH(Buffer& buf, const string& destination, const string& routingKey) +void AgentEngineImpl::sendBufferLH(Buffer& buf, const string& destination, const string& routingKey) { uint32_t length = buf.getPosition(); MessageImpl::Ptr message(new MessageImpl); @@ -567,7 +567,7 @@ void AgentImpl::sendBufferLH(Buffer& buf, const string& destination, const strin xmtQueue.push_back(message); } -void AgentImpl::sendPackageIndicationLH(const string& packageName) +void AgentEngineImpl::sendPackageIndicationLH(const string& packageName) { Buffer buffer(outputBuffer, MA_BUFFER_SIZE); encodeHeader(buffer, 'p'); @@ -576,7 +576,7 @@ void AgentImpl::sendPackageIndicationLH(const string& packageName) QPID_LOG(trace, "SENT PackageIndication: package_name=" << packageName); } -void AgentImpl::sendClassIndicationLH(ClassKind kind, const string& packageName, const SchemaClassKey& key) +void AgentEngineImpl::sendClassIndicationLH(ClassKind kind, const string& packageName, const SchemaClassKey& key) { Buffer buffer(outputBuffer, MA_BUFFER_SIZE); encodeHeader(buffer, 'q'); @@ -588,8 +588,8 @@ void AgentImpl::sendClassIndicationLH(ClassKind kind, const string& packageName, QPID_LOG(trace, "SENT ClassIndication: package_name=" << packageName << " class_name=" << key.name); } -void AgentImpl::sendCommandCompleteLH(const string& exchange, const string& replyToKey, - uint32_t sequence, uint32_t code, const string& text) +void AgentEngineImpl::sendCommandCompleteLH(const string& exchange, const string& replyToKey, + uint32_t sequence, uint32_t code, const string& text) { Buffer buffer(outputBuffer, MA_BUFFER_SIZE); encodeHeader(buffer, 'z', sequence); @@ -599,7 +599,7 @@ void AgentImpl::sendCommandCompleteLH(const string& exchange, const string& repl QPID_LOG(trace, "SENT CommandComplete: seq=" << sequence << " code=" << code << " text=" << text); } -void AgentImpl::sendMethodErrorLH(uint32_t sequence, const string& key, uint32_t code, const string& text) +void AgentEngineImpl::sendMethodErrorLH(uint32_t sequence, const string& key, uint32_t code, const string& text) { Buffer buffer(outputBuffer, MA_BUFFER_SIZE); encodeHeader(buffer, 'm', sequence); @@ -625,7 +625,7 @@ void AgentImpl::sendMethodErrorLH(uint32_t sequence, const string& key, uint32_t QPID_LOG(trace, "SENT MethodResponse: errorCode=" << code << " text=" << fulltext); } -void AgentImpl::handleAttachResponse(Buffer& inBuffer) +void AgentEngineImpl::handleAttachResponse(Buffer& inBuffer) { Mutex::ScopedLock _lock(lock); @@ -672,18 +672,18 @@ void AgentImpl::handleAttachResponse(Buffer& inBuffer) } } -void AgentImpl::handlePackageRequest(Buffer&) +void AgentEngineImpl::handlePackageRequest(Buffer&) { Mutex::ScopedLock _lock(lock); } -void AgentImpl::handleClassQuery(Buffer&) +void AgentEngineImpl::handleClassQuery(Buffer&) { Mutex::ScopedLock _lock(lock); } -void AgentImpl::handleSchemaRequest(Buffer& inBuffer, uint32_t sequence, - const string& replyExchange, const string& replyKey) +void AgentEngineImpl::handleSchemaRequest(Buffer& inBuffer, uint32_t sequence, + const string& replyExchange, const string& replyKey) { Mutex::ScopedLock _lock(lock); string rExchange(replyExchange); @@ -731,7 +731,7 @@ void AgentImpl::handleSchemaRequest(Buffer& inBuffer, uint32_t sequence, sendCommandCompleteLH(rExchange, rKey, sequence, 1, "class not found"); } -void AgentImpl::handleGetQuery(Buffer& inBuffer, uint32_t sequence, const string& replyTo, const string& userId) +void AgentEngineImpl::handleGetQuery(Buffer& inBuffer, uint32_t sequence, const string& replyTo, const string& userId) { Mutex::ScopedLock _lock(lock); FieldTable ft; @@ -783,7 +783,7 @@ void AgentImpl::handleGetQuery(Buffer& inBuffer, uint32_t sequence, const string eventQueue.push_back(eventQuery(contextNum, userId, pname, cname, oid)); } -void AgentImpl::handleMethodRequest(Buffer& buffer, uint32_t sequence, const string& replyTo, const string& userId) +void AgentEngineImpl::handleMethodRequest(Buffer& buffer, uint32_t sequence, const string& replyTo, const string& userId) { Mutex::ScopedLock _lock(lock); string pname; @@ -842,7 +842,7 @@ void AgentImpl::handleMethodRequest(Buffer& buffer, uint32_t sequence, const str eventQueue.push_back(eventMethod(contextNum, userId, method, oid, argMap, schema->envelope)); } -void AgentImpl::handleConsoleAddedIndication() +void AgentEngineImpl::handleConsoleAddedIndication() { Mutex::ScopedLock _lock(lock); } @@ -851,107 +851,107 @@ void AgentImpl::handleConsoleAddedIndication() // Wrappers //================================================================== -Agent::Agent(char* label, bool internalStore) +AgentEngine::AgentEngine(char* label, bool internalStore) { - impl = new AgentImpl(label, internalStore); + impl = new AgentEngineImpl(label, internalStore); } -Agent::~Agent() +AgentEngine::~AgentEngine() { delete impl; } -void Agent::setStoreDir(char* path) +void AgentEngine::setStoreDir(const char* path) { impl->setStoreDir(path); } -void Agent::setTransferDir(char* path) +void AgentEngine::setTransferDir(const char* path) { impl->setTransferDir(path); } -void Agent::handleRcvMessage(Message& message) +void AgentEngine::handleRcvMessage(Message& message) { impl->handleRcvMessage(message); } -bool Agent::getXmtMessage(Message& item) +bool AgentEngine::getXmtMessage(Message& item) { return impl->getXmtMessage(item); } -void Agent::popXmt() +void AgentEngine::popXmt() { impl->popXmt(); } -bool Agent::getEvent(AgentEvent& event) +bool AgentEngine::getEvent(AgentEvent& event) { return impl->getEvent(event); } -void Agent::popEvent() +void AgentEngine::popEvent() { impl->popEvent(); } -void Agent::newSession() +void AgentEngine::newSession() { impl->newSession(); } -void Agent::startProtocol() +void AgentEngine::startProtocol() { impl->startProtocol(); } -void Agent::heartbeat() +void AgentEngine::heartbeat() { impl->heartbeat(); } -void Agent::methodResponse(uint32_t sequence, uint32_t status, char* text, const Value& arguments) +void AgentEngine::methodResponse(uint32_t sequence, uint32_t status, char* text, const Value& arguments) { impl->methodResponse(sequence, status, text, arguments); } -void Agent::queryResponse(uint32_t sequence, Object& object, bool prop, bool stat) +void AgentEngine::queryResponse(uint32_t sequence, Object& object, bool prop, bool stat) { impl->queryResponse(sequence, object, prop, stat); } -void Agent::queryComplete(uint32_t sequence) +void AgentEngine::queryComplete(uint32_t sequence) { impl->queryComplete(sequence); } -void Agent::registerClass(SchemaObjectClass* cls) +void AgentEngine::registerClass(SchemaObjectClass* cls) { impl->registerClass(cls); } -void Agent::registerClass(SchemaEventClass* cls) +void AgentEngine::registerClass(SchemaEventClass* cls) { impl->registerClass(cls); } -const ObjectId* Agent::addObject(Object& obj, uint64_t persistId) +const ObjectId* AgentEngine::addObject(Object& obj, uint64_t persistId) { return impl->addObject(obj, persistId); } -const ObjectId* Agent::allocObjectId(uint64_t persistId) +const ObjectId* AgentEngine::allocObjectId(uint64_t persistId) { return impl->allocObjectId(persistId); } -const ObjectId* Agent::allocObjectId(uint32_t persistIdLo, uint32_t persistIdHi) +const ObjectId* AgentEngine::allocObjectId(uint32_t persistIdLo, uint32_t persistIdHi) { return impl->allocObjectId(persistIdLo, persistIdHi); } -void Agent::raiseEvent(Event& event) +void AgentEngine::raiseEvent(Event& event) { impl->raiseEvent(event); } diff --git a/qpid/cpp/src/qmf/Agent.h b/qpid/cpp/src/qmf/AgentEngine.h index d8f784e9d8..d18a104e96 100644 --- a/qpid/cpp/src/qmf/Agent.h +++ b/qpid/cpp/src/qmf/AgentEngine.h @@ -1,5 +1,5 @@ -#ifndef _QmfAgent_ -#define _QmfAgent_ +#ifndef _QmfAgentEngine_ +#define _QmfAgentEngine_ /* * Licensed to the Apache Software Foundation (ASF) under one @@ -64,15 +64,15 @@ namespace qmf { SchemaObjectClass* objectClass; // (METHOD_CALL) }; - class AgentImpl; + class AgentEngineImpl; /** - * Agent - Protocol engine for the QMF agent + * AgentEngine - Protocol engine for the QMF agent */ - class Agent { + class AgentEngine { public: - Agent(char* label, bool internalStore=true); - ~Agent(); + AgentEngine(char* label, bool internalStore=true); + ~AgentEngine(); /** * Configure the directory path for storing persistent data. @@ -80,7 +80,7 @@ namespace qmf { * created, written, and read. If NULL, no persistent storage will be * attempted. */ - void setStoreDir(char* path); + void setStoreDir(const char* path); /** * Configure the directory path for files transferred over QMF. @@ -88,7 +88,7 @@ namespace qmf { * created, deleted, written, and read. If NULL, file transfers shall not * be permitted. */ - void setTransferDir(char* path); + void setTransferDir(const char* path); /** * Pass messages received from the AMQP session to the Agent engine. @@ -182,11 +182,12 @@ namespace qmf { *@return The objectId of the managed object. */ const ObjectId* addObject(Object& obj, uint64_t persistId); + const ObjectId* addObject(Object& obj, uint32_t persistIdLo, uint32_t persistIdHi); /** - * Allocate an objecc-id for an object that will be managed by the application. + * Allocate an object-id for an object that will be managed by the application. *@param persistId A unique non-zero value if the object-id is to be persistent. - @return The objectId structure for the allocated ID. + *@return The objectId structure for the allocated ID. */ const ObjectId* allocObjectId(uint64_t persistId); const ObjectId* allocObjectId(uint32_t persistIdLo, uint32_t persistIdHi); @@ -198,7 +199,7 @@ namespace qmf { void raiseEvent(Event& event); private: - AgentImpl* impl; + AgentEngineImpl* impl; }; } diff --git a/qpid/cpp/src/qmf/Console.h b/qpid/cpp/src/qmf/ConsoleEngine.h index de7949e1de..823e281b14 100644 --- a/qpid/cpp/src/qmf/Console.h +++ b/qpid/cpp/src/qmf/ConsoleEngine.h @@ -1,5 +1,5 @@ -#ifndef _QmfConsole_ -#define _QmfConsole_ +#ifndef _QmfConsoleEngine_ +#define _QmfConsoleEngine_ /* * Licensed to the Apache Software Foundation (ASF) under one @@ -21,7 +21,6 @@ */ #include <qmf/ManagedConnection.h> -#include <qmf/Agent.h> #include <qmf/Broker.h> #include <qmf/Package.h> #include <qmf/SchemaClassTable.h> @@ -50,10 +49,10 @@ namespace qmf { getTimeout(20) {} }; - class Console { + class ConsoleEngine { public: - Console(ConsoleHandler* handler = 0, ConsoleSettings settings = ConsoleSettings()); - ~Console(); + ConsoleEngine(ConsoleHandler* handler = 0, ConsoleSettings settings = ConsoleSettings()); + ~ConsoleEngine(); Broker* addConnection(ManagedConnection& connection); void delConnection(Broker* broker); @@ -66,6 +65,7 @@ namespace qmf { void bindClass(const SchemaClass& otype); void bindClass(const std::string& packageName, const std::string& className); + /* void getAgents(std::set<Agent>& agents, Broker* = 0); void getObjects(std::vector<Object>& objects, const std::string& typeName, const std::string& packageName = "", @@ -75,6 +75,7 @@ namespace qmf { const std::map<std::string, std::string>& query, Broker* broker = 0, Agent* agent = 0); + */ }; } diff --git a/qpid/cpp/src/qmf/Object.h b/qpid/cpp/src/qmf/Object.h index 8caab8d6dc..eb92cbbe45 100644 --- a/qpid/cpp/src/qmf/Object.h +++ b/qpid/cpp/src/qmf/Object.h @@ -31,7 +31,7 @@ namespace qmf { public: Object(const SchemaObjectClass* type); Object(ObjectImpl* impl); - ~Object(); + virtual ~Object(); void destroy(); const ObjectId* getObjectId() const; |