Apache Qpid - AMQP Messaging for Java JMS, C++, Python, Ruby, and .NET Apache Qpid Documentation
qmf/Agent.h
Go to the documentation of this file.
00001 #ifndef QMF_AGENT_H
00002 #define QMF_AGENT_H
00003 /*
00004  *
00005  * Licensed to the Apache Software Foundation (ASF) under one
00006  * or more contributor license agreements.  See the NOTICE file
00007  * distributed with this work for additional information
00008  * regarding copyright ownership.  The ASF licenses this file
00009  * to you under the Apache License, Version 2.0 (the
00010  * "License"); you may not use this file except in compliance
00011  * with the License.  You may obtain a copy of the License at
00012  * 
00013  *   http://www.apache.org/licenses/LICENSE-2.0
00014  * 
00015  * Unless required by applicable law or agreed to in writing,
00016  * software distributed under the License is distributed on an
00017  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
00018  * KIND, either express or implied.  See the License for the
00019  * specific language governing permissions and limitations
00020  * under the License.
00021  *
00022  */
00023 
00024 #include <qmf/ImportExport.h>
00025 #include "qmf/Handle.h"
00026 //#include "qmf/Subscription.h"
00027 #include "qmf/exceptions.h"
00028 #include "qpid/messaging/Duration.h"
00029 #include "qpid/types/Variant.h"
00030 #include <string>
00031 
00032 namespace qmf {
00033 
00034 #ifndef SWIG
00035     template <class> class PrivateImplRef;
00036 #endif
00037 
00038     class AgentImpl;
00039     class ConsoleEvent;
00040     class Query;
00041     class DataAddr;
00042     class SchemaId;
00043     class Schema;
00044 
00045     class QMF_CLASS_EXTERN Agent : public qmf::Handle<AgentImpl> {
00046     public:
00047         QMF_EXTERN Agent(AgentImpl* impl = 0);
00048         QMF_EXTERN Agent(const Agent&);
00049         QMF_EXTERN Agent& operator=(const Agent&);
00050         QMF_EXTERN ~Agent();
00051 
00052         QMF_EXTERN std::string getName() const;
00053         QMF_EXTERN uint32_t getEpoch() const;
00054         QMF_EXTERN std::string getVendor() const;
00055         QMF_EXTERN std::string getProduct() const;
00056         QMF_EXTERN std::string getInstance() const;
00057         QMF_EXTERN const qpid::types::Variant& getAttribute(const std::string&) const;
00058         QMF_EXTERN const qpid::types::Variant::Map& getAttributes() const;
00059 
00060         QMF_EXTERN ConsoleEvent query(const Query&, qpid::messaging::Duration timeout=qpid::messaging::Duration::MINUTE);
00061         QMF_EXTERN ConsoleEvent query(const std::string&, qpid::messaging::Duration timeout=qpid::messaging::Duration::MINUTE);
00062         QMF_EXTERN uint32_t queryAsync(const Query&);
00063         QMF_EXTERN uint32_t queryAsync(const std::string&);
00064 
00068         //QMF_EXTERN Subscription subscribe(const Query&, const std::string& options = "");
00069         //QMF_EXTERN Subscription subscribe(const std::string&, const std::string& options = "");
00070 
00071         QMF_EXTERN ConsoleEvent callMethod(const std::string&, const qpid::types::Variant::Map&, const DataAddr&,
00072                                            qpid::messaging::Duration timeout=qpid::messaging::Duration::MINUTE);
00073         QMF_EXTERN uint32_t callMethodAsync(const std::string&, const qpid::types::Variant::Map&, const DataAddr&);
00074 
00085         QMF_EXTERN ConsoleEvent querySchema(qpid::messaging::Duration timeout=qpid::messaging::Duration::MINUTE);
00086         QMF_EXTERN uint32_t querySchemaAsync();
00087 
00098         QMF_EXTERN uint32_t getPackageCount() const;
00099         QMF_EXTERN const std::string& getPackage(uint32_t) const;
00100 
00111         QMF_EXTERN uint32_t getSchemaIdCount(const std::string&) const;
00112         QMF_EXTERN SchemaId getSchemaId(const std::string&, uint32_t) const;
00113 
00121         QMF_EXTERN Schema getSchema(const SchemaId&, qpid::messaging::Duration timeout=qpid::messaging::Duration::MINUTE);
00122 
00123 
00124 #ifndef SWIG
00125     private:
00126         friend class qmf::PrivateImplRef<Agent>;
00127         friend struct AgentImplAccess;
00128 #endif
00129     };
00130 
00131 }
00132 
00133 #endif

Qpid C++ API Reference
Generated on Mon Aug 22 2011 for Qpid C++ Client API by doxygen 1.7.4