From e72e25abd1272c4e9489f7efd5bc02c4ecf0b5cd Mon Sep 17 00:00:00 2001 From: Alan Conway Date: Tue, 8 Apr 2008 19:53:07 +0000 Subject: Summary: added 0-10 Array encoding and decoding. rubygen/0-10/allsegmenttypes.rb: test header,body and each command and control type. rubygen/0-10/specification.rb: enable packed encoding. src/qpid/amqp_0_10/Array.h: Implemented array and array domains. src/qpid/amqp_0_10/Codec.h: enable litte-endian encoding for pack bits src/qpid/amqp_0_10/Packer.h: use litte-endian encoding for pack bits src/qpid/amqp_0_10/Unit.cpp, .h: setting flags, fix op <<. src/qpid/amqp_0_10/complex_types.cpp, .h: added op << src/qpid/framing/Blob.h: copy-object template constructor. src/tests/amqp_0_10/serialize.cpp: - test Array Minor adjustments for new Array.h: src/qpid/amqp_0_10/Map.cpp src/qpid/amqp_0_10/Map.h src/qpid/amqp_0_10/UnknownType.h src/qpid/amqp_0_10/built_in_types.h src/qpid/amqp_0_10/Body.h git-svn-id: https://svn.apache.org/repos/asf/incubator/qpid/trunk/qpid@646054 13f79535-47bb-0310-9956-ffa450edef68 --- cpp/src/qpid/amqp_0_10/Array.cpp | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 cpp/src/qpid/amqp_0_10/Array.cpp (limited to 'cpp/src/qpid/amqp_0_10/Array.cpp') diff --git a/cpp/src/qpid/amqp_0_10/Array.cpp b/cpp/src/qpid/amqp_0_10/Array.cpp new file mode 100644 index 0000000000..380e0f1f36 --- /dev/null +++ b/cpp/src/qpid/amqp_0_10/Array.cpp @@ -0,0 +1,34 @@ +/* + * + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + * + */ +#include "Array.h" + +namespace qpid { +namespace amqp_0_10 { + +std::ostream& operator<<(std::ostream& o, const Array& a) { + std::ostream_iterator i(o, " "); + o << "Array<" << typeName(a.getType()) << "["; + std::copy(a.begin(), a.end(), i); + o << "]"; + return o; +} + +}} // namespace qpid::amqp_0_10 -- cgit v1.2.1