Apache Qpid - AMQP Messaging for Java JMS, C++, Python, Ruby, and .NET Apache Qpid Documentation
qpid/amqp_0_10/Codecs.h
Go to the documentation of this file.
00001 #ifndef QPID_AMQP_0_10_CODECS_H
00002 #define QPID_AMQP_0_10_CODECS_H
00003 
00004 /*
00005  *
00006  * Licensed to the Apache Software Foundation (ASF) under one
00007  * or more contributor license agreements.  See the NOTICE file
00008  * distributed with this work for additional information
00009  * regarding copyright ownership.  The ASF licenses this file
00010  * to you under the Apache License, Version 2.0 (the
00011  * "License"); you may not use this file except in compliance
00012  * with the License.  You may obtain a copy of the License at
00013  * 
00014  *   http://www.apache.org/licenses/LICENSE-2.0
00015  * 
00016  * Unless required by applicable law or agreed to in writing,
00017  * software distributed under the License is distributed on an
00018  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
00019  * KIND, either express or implied.  See the License for the
00020  * specific language governing permissions and limitations
00021  * under the License.
00022  *
00023  */
00024 
00025 #include "qpid/CommonImportExport.h"
00026 #include "qpid/types/Variant.h"
00027 
00028 namespace qpid {
00029 namespace framing {
00030 class FieldTable;
00031 }
00032 namespace amqp_0_10 {
00037 class QPID_COMMON_CLASS_EXTERN MapCodec
00038 {
00039   public:
00040     typedef qpid::types::Variant::Map ObjectType;
00041     static void   QPID_COMMON_EXTERN encode(const ObjectType&, std::string&);
00042     static void   QPID_COMMON_EXTERN decode(const std::string&, ObjectType&);
00043     static size_t QPID_COMMON_EXTERN encodedSize(const ObjectType&);
00044     static const  QPID_COMMON_EXTERN std::string contentType;
00045   private:
00046 };
00047 
00052 class QPID_COMMON_CLASS_EXTERN ListCodec
00053 {
00054   public:
00055     typedef qpid::types::Variant::List ObjectType;
00056     static void   QPID_COMMON_EXTERN encode(const ObjectType&, std::string&);
00057     static void   QPID_COMMON_EXTERN decode(const std::string&, ObjectType&);
00058     static size_t QPID_COMMON_EXTERN encodedSize(const ObjectType&);
00059     static const  QPID_COMMON_EXTERN std::string contentType;
00060   private:
00061 };
00062 
00070 QPID_COMMON_EXTERN void translate(const qpid::types::Variant::Map& from,
00071                                   qpid::framing::FieldTable& to);
00072 QPID_COMMON_EXTERN void translate(const qpid::types::Variant::Map& from, const std::string& efield, const qpid::types::Variant& evalue,
00073                                   qpid::framing::FieldTable& to);
00074 QPID_COMMON_EXTERN void translate(const qpid::framing::FieldTable& from,
00075                                   qpid::types::Variant::Map& to);
00076 
00077 }} // namespace qpid::amqp_0_10
00078 
00079 #endif  

Qpid C++ API Reference
Generated on Thu Aug 23 2012 for Qpid C++ Client API by doxygen 1.7.5