Return-Path: Delivered-To: apmail-geronimo-activemq-commits-archive@www.apache.org Received: (qmail 68037 invoked from network); 17 Oct 2006 22:38:52 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 17 Oct 2006 22:38:52 -0000 Received: (qmail 97821 invoked by uid 500); 17 Oct 2006 22:38:52 -0000 Delivered-To: apmail-geronimo-activemq-commits-archive@geronimo.apache.org Received: (qmail 97777 invoked by uid 500); 17 Oct 2006 22:38:52 -0000 Mailing-List: contact activemq-commits-help@geronimo.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: activemq-dev@geronimo.apache.org Delivered-To: mailing list activemq-commits@geronimo.apache.org Received: (qmail 97600 invoked by uid 99); 17 Oct 2006 22:38:51 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 17 Oct 2006 15:38:51 -0700 X-ASF-Spam-Status: No, hits=-9.4 required=10.0 tests=ALL_TRUSTED,NO_REAL_NAME X-Spam-Check-By: apache.org Received-SPF: pass (asf.osuosl.org: local policy) Received: from [140.211.166.113] (HELO eris.apache.org) (140.211.166.113) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 17 Oct 2006 15:38:44 -0700 Received: by eris.apache.org (Postfix, from userid 65534) id 93F4C1A9822; Tue, 17 Oct 2006 15:38:24 -0700 (PDT) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r465087 [3/9] - /incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ Date: Tue, 17 Oct 2006 22:38:20 -0000 To: activemq-commits@geronimo.apache.org From: tabish@apache.org X-Mailer: svnmailer-1.1.0 Message-Id: <20061017223824.93F4C1A9822@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N Added: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/BrokerInfoMarshaller.cpp URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/BrokerInfoMarshaller.cpp?view=auto&rev=465087 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/BrokerInfoMarshaller.cpp (added) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/BrokerInfoMarshaller.cpp Tue Oct 17 15:38:16 2006 @@ -0,0 +1,160 @@ +/* + * 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 + +#include + +// +// NOTE!: This file is autogenerated - do not modify! +// if you need to make a change, please see the Java Classes in the +// activemq-core module +// + +using namespace std; +using namespace activemq; +using namespace activemq::io; +using namespace activemq::connector; +using namespace activemq::connector::openwire; +using namespace activemq::connector::openwire::commands; +using namespace activemq::connector::openwire::marshal; +using namespace activemq::connector::openwire::util; +using namespace activemq::connector::openwire::marshal::v2; + +/////////////////////////////////////////////////////////////////////////////// +DataStructure* BrokerInfoMarshaller::createObject() const { + return new BrokerInfo(); +} + +/////////////////////////////////////////////////////////////////////////////// +unsigned char BrokerInfoMarshaller::getDataStructureType() const { + return BrokerInfo::ID_BROKERINFO; +} + +/////////////////////////////////////////////////////////////////////////////// +void BrokerInfoMarshaller::tightUnmarshal( OpenWireFormat* wireFormat, DataStructure* dataStructure, DataInputStream* dataIn, BooleanStream* bs ) { + BaseCommandMarshaller::tightUnmarshal( wireFormat, dataStructure, dataIn, bs ); + + BrokerInfo* info = + dynamic_cast( dataStructure ); + info->setBrokerId( dynamic_cast< BrokerId* >( + tightUnmarsalCachedObject( wireFormat, dataIn, bs ) ); + info->setBrokerURL( TightUnmarshalString( dataIn, bs ) ); + + if( bs->readBoolean() ) { + short size = dataIn->readShort(); + BrokerInfo* value = new BrokerInfo[size]; + for( int i = 0; i < size; i++ ) { + value[i] = dynamic_cast< BrokerInfo* >( + tightUnmarsalNestedObject( wireFormat, dataIn, bs ) ); + } + info->setPeerBrokerInfos( value ); + } + else { + info->setPeerBrokerInfos( NULL ); + } + info->setBrokerName( TightUnmarshalString( dataIn, bs ) ); + info->setSlaveBroker( bs->readBoolean() ); + info->setMasterBroker( bs->readBoolean() ); + info->setFaultTolerantConfiguration( bs->readBoolean() ); +} + +/////////////////////////////////////////////////////////////////////////////// +int BrokerInfoMarshaller::tightMarshal1( OpenWireFormat& wireFormat, DataStructure* dataStructure, BooleanStream& bs ) { + + BrokerInfo* info = + dynamic_cast( dataStructure ); + + int rc = BaseCommandMarshaller::tightMarshal1( wireFormat, dataStructure, bs ); + DataStructure* data = + dynamic_cast< DataStructure* >( info->getBrokerId() ); + + rc += tightMarshalCachedObject1( wireFormat, data, bs ); + rc += tightMarshalString1( info->getBrokerURL(), bs ); + rc += tightMarshalObjectArray1( wireFormat, info->getPeerBrokerInfos(), bs ); + rc += tightMarshalString1( info->getBrokerName(), bs ); + bs->writeBoolean( info->isSlaveBroker() ); + bs->writeBoolean( info->isMasterBroker() ); + bs->writeBoolean( info->isFaultTolerantConfiguration() ); + + return rc + 0; +} + +/////////////////////////////////////////////////////////////////////////////// +void BrokerInfoMarshaller::tightMarshal2( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataOutputStream& dataOut, BooleanStream& bs ) { + + BaseCommandMarshaller::tightMarshal2( wireFormat, dataStructure, dataOut, bs ); + + BrokerInfo* info = + dynamic_cast( dataStructure ); + DataStructure* data = + dynamic_cast< DataStructure* >( info->getBrokerId() ); + + tightMarshalCachedObject2( wireFormat, data, dataOut, bs ); + tightMarshalString2( info->getBrokerURL(), dataOut, bs ); + tightMarshalObjectArray2( wireFormat, info->getPeerBrokerInfos(), dataOut, bs ); + tightMarshalString2( info->getBrokerName(), dataOut, bs ); + bs->readBoolean(); + bs->readBoolean(); + bs->readBoolean(); +} + +/////////////////////////////////////////////////////////////////////////////// +void BrokerInfoMarshaller::looseUnmarshal( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataInputStream& dataIn ) { + BaseCommandMarshaller::looseUnmarshal( wireFormat, dataStructure, dataIn ); + BrokerInfo* info = + dynamic_cast( dataStructure ); + info->setBrokerId( dynamic_cast( + looseUnmarshalCachedObject( wireFormat, dataIn ) ) ); + info->setBrokerURL( looseUnmarshalString( dataIn ) ); + + if( dataIn->readBoolean() ) { + short size = dataIn->readShort(); + BrokerInfo* value = new BrokerInfo[size]; + for( int i = 0; i < size; i++ ) { + value[i] = dynamic_cast( + looseUnmarshalNestedObject( wireFormat,dataIn ) ); + } + info->setPeerBrokerInfos( value ); + } + else { + info->setPeerBrokerInfos( NULL ); + } + info->setBrokerName( looseUnmarshalString( dataIn ) ); + info->setSlaveBroker( dataIn->readBoolean() ); + info->setMasterBroker( dataIn->readBoolean() ); + info->setFaultTolerantConfiguration( dataIn->readBoolean() ); +} + +/////////////////////////////////////////////////////////////////////////////// +void BrokerInfoMarshaller::looseMarshal( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataOutputStream& dataOut ) { + BrokerInfo* info = + dynamic_cast( dataStructure ); + BaseCommandMarshaller::looseMarshal( wireFormat, dataStructure, dataOut ); + + DataStructure* data = + dynamic_cast< DataStructure* >( info->getBrokerId() ); + + looseMarshalCachedObject( wireFormat, data, dataOut ); + looseMarshalString( info->getBrokerURL(), dataOut ); + looseMarshalObjectArray( wireFormat, info->getPeerBrokerInfos(), dataOut ); + looseMarshalString( info->getBrokerName(), dataOut ); + dataOut->write( info->isSlaveBroker() ); + dataOut->write( info->isMasterBroker() ); + dataOut->write( info->isFaultTolerantConfiguration() ); +} + Propchange: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/BrokerInfoMarshaller.cpp ------------------------------------------------------------------------------ svn:eol-style = native Added: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/BrokerInfoMarshaller.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/BrokerInfoMarshaller.h?view=auto&rev=465087 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/BrokerInfoMarshaller.h (added) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/BrokerInfoMarshaller.h Tue Oct 17 15:38:16 2006 @@ -0,0 +1,126 @@ +/* + * 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. + */ + +#ifndef _ACTIVEMQ_CONNECTOR_OPENWIRE_MARSAHAL_V2_BROKERINFOMARSHALLER_H_ +#define _ACTIVEMQ_CONNECTOR_OPENWIRE_MARSAHAL_V2_BROKERINFOMARSHALLER_H_ + +// Turn off warning message for ignored exception specification +#ifdef _MSC_VER +#pragma warning( disable : 4290 ) +#endif + +#include + +#include +#include +#include +#include +#include + +namespace activemq{ +namespace connector{ +namespace openwire{ +namespace marshal{ +namespace v2{ + + /** + * Marshalling code for Open Wire Format for BrokerInfoMarshaller + * + * NOTE!: This file is autogenerated - do not modify! + * if you need to make a change, please see the Java Classes + * in the activemq-openwire-generator module + */ + class BrokerInfoMarshaller : public BaseCommandMarshaller + { + public: + + BrokerInfoMarshaller() {}; + virtual ~BrokerInfoMarshaller() {}; + + /** + * Creates a new instance of this marshalable type. + * @return new DataStructure object pointer caller owns it. + */ + virtual DataStructure* createObject() const; + + /** + * Get the Data Structure Type that identifies this Marshaller + * @return byte holding the data structure type value + */ + virtual unsigned char getDataStructureType() const; + + /** + * Un-marshal an object instance from the data input stream + * @param wireFormat - describs the wire format of the broker + * @param o - Object to be un-marshaled + * @param dataIn - BinaryReader that provides that data + * @param bs - BooleanStream + */ + virtual void tightUnmarshal( OpenWireFormat* wireFormat, + commands::DataStructure* dataStructure, + io::DataInputStream* dataIn, + util::BooleanStream* bs ) throws( io::IOException ); + + /** + * Write the booleans that this object uses to a BooleanStream + * @param wireFormat - describis the wire format of the broker + * @param o - Object to be marshaled + * @param bs - BooleanStream + * @returns int + */ + virtual int tightMarshal1( OpenWireFormat* wireFormat, + commands::DataStructure* dataStructure, + BooleanStream* bs ) throws( io::IOException ); + + /** + * Write a object instance to data output stream + * @param wireFormat - describs the wire format of the broker + * @param o - Object to be marshaled + * @param dataOut - BinaryReader that provides that data sink + * @param bs - BooleanStream + */ + virtual void tightMarshal2( OpenWireFormat* wireFormat, + commands::DataStructure* dataStructure, + io::DataOutputStream* dataOut, + BooleanStream* bs ) throws( io::IOException ); + + /** + * Un-marshal an object instance from the data input stream + * @param wireFormat - describs the wire format of the broker + * @param o - Object to be marshaled + * @param dataIn - BinaryReader that provides that data source + */ + virtual void looseUnmarshal( OpenWireFormat* wireFormat, + commands::DataStructure* dataStructure, + io::DataInputStream* dataIn ) throws( io::IOException ); + + /** + * Write a object instance to data output stream + * @param wireFormat - describs the wire format of the broker + * @param o - Object to be marshaled + * @param dataOut - BinaryWriter that provides that data sink + */ + virtual void looseMarshal( OpenWireFormat* wireFormat, + commands::DataStructure* dataStructure, + io::DataOutputStream* dataOut ) throws( io::IOException ); + + }; + +}}}}} + +#endif /*_ACTIVEMQ_CONNECTOR_OPENWIRE_MARSAHAL_V2_BROKERINFOMARSHALLER_H_*/ + Propchange: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/BrokerInfoMarshaller.h ------------------------------------------------------------------------------ svn:eol-style = native Added: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionControlMarshaller.cpp URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionControlMarshaller.cpp?view=auto&rev=465087 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionControlMarshaller.cpp (added) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionControlMarshaller.cpp Tue Oct 17 15:38:16 2006 @@ -0,0 +1,115 @@ +/* + * 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 + +#include + +// +// NOTE!: This file is autogenerated - do not modify! +// if you need to make a change, please see the Java Classes in the +// activemq-core module +// + +using namespace std; +using namespace activemq; +using namespace activemq::io; +using namespace activemq::connector; +using namespace activemq::connector::openwire; +using namespace activemq::connector::openwire::commands; +using namespace activemq::connector::openwire::marshal; +using namespace activemq::connector::openwire::util; +using namespace activemq::connector::openwire::marshal::v2; + +/////////////////////////////////////////////////////////////////////////////// +DataStructure* ConnectionControlMarshaller::createObject() const { + return new ConnectionControl(); +} + +/////////////////////////////////////////////////////////////////////////////// +unsigned char ConnectionControlMarshaller::getDataStructureType() const { + return ConnectionControl::ID_CONNECTIONCONTROL; +} + +/////////////////////////////////////////////////////////////////////////////// +void ConnectionControlMarshaller::tightUnmarshal( OpenWireFormat* wireFormat, DataStructure* dataStructure, DataInputStream* dataIn, BooleanStream* bs ) { + BaseCommandMarshaller::tightUnmarshal( wireFormat, dataStructure, dataIn, bs ); + + ConnectionControl* info = + dynamic_cast( dataStructure ); + info->setClose( bs->readBoolean() ); + info->setExit( bs->readBoolean() ); + info->setFaultTolerant( bs->readBoolean() ); + info->setResume( bs->readBoolean() ); + info->setSuspend( bs->readBoolean() ); +} + +/////////////////////////////////////////////////////////////////////////////// +int ConnectionControlMarshaller::tightMarshal1( OpenWireFormat& wireFormat, DataStructure* dataStructure, BooleanStream& bs ) { + + ConnectionControl* info = + dynamic_cast( dataStructure ); + + int rc = BaseCommandMarshaller::tightMarshal1( wireFormat, dataStructure, bs ); + bs->writeBoolean( info->isClose() ); + bs->writeBoolean( info->isExit() ); + bs->writeBoolean( info->isFaultTolerant() ); + bs->writeBoolean( info->isResume() ); + bs->writeBoolean( info->isSuspend() ); + + return rc + 0; +} + +/////////////////////////////////////////////////////////////////////////////// +void ConnectionControlMarshaller::tightMarshal2( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataOutputStream& dataOut, BooleanStream& bs ) { + + BaseCommandMarshaller::tightMarshal2( wireFormat, dataStructure, dataOut, bs ); + + ConnectionControl* info = + dynamic_cast( dataStructure ); + bs->readBoolean(); + bs->readBoolean(); + bs->readBoolean(); + bs->readBoolean(); + bs->readBoolean(); +} + +/////////////////////////////////////////////////////////////////////////////// +void ConnectionControlMarshaller::looseUnmarshal( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataInputStream& dataIn ) { + BaseCommandMarshaller::looseUnmarshal( wireFormat, dataStructure, dataIn ); + ConnectionControl* info = + dynamic_cast( dataStructure ); + info->setClose( dataIn->readBoolean() ); + info->setExit( dataIn->readBoolean() ); + info->setFaultTolerant( dataIn->readBoolean() ); + info->setResume( dataIn->readBoolean() ); + info->setSuspend( dataIn->readBoolean() ); +} + +/////////////////////////////////////////////////////////////////////////////// +void ConnectionControlMarshaller::looseMarshal( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataOutputStream& dataOut ) { + ConnectionControl* info = + dynamic_cast( dataStructure ); + BaseCommandMarshaller::looseMarshal( wireFormat, dataStructure, dataOut ); + + dataOut->write( info->isClose() ); + dataOut->write( info->isExit() ); + dataOut->write( info->isFaultTolerant() ); + dataOut->write( info->isResume() ); + dataOut->write( info->isSuspend() ); +} + Propchange: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionControlMarshaller.cpp ------------------------------------------------------------------------------ svn:eol-style = native Added: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionControlMarshaller.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionControlMarshaller.h?view=auto&rev=465087 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionControlMarshaller.h (added) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionControlMarshaller.h Tue Oct 17 15:38:16 2006 @@ -0,0 +1,126 @@ +/* + * 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. + */ + +#ifndef _ACTIVEMQ_CONNECTOR_OPENWIRE_MARSAHAL_V2_CONNECTIONCONTROLMARSHALLER_H_ +#define _ACTIVEMQ_CONNECTOR_OPENWIRE_MARSAHAL_V2_CONNECTIONCONTROLMARSHALLER_H_ + +// Turn off warning message for ignored exception specification +#ifdef _MSC_VER +#pragma warning( disable : 4290 ) +#endif + +#include + +#include +#include +#include +#include +#include + +namespace activemq{ +namespace connector{ +namespace openwire{ +namespace marshal{ +namespace v2{ + + /** + * Marshalling code for Open Wire Format for ConnectionControlMarshaller + * + * NOTE!: This file is autogenerated - do not modify! + * if you need to make a change, please see the Java Classes + * in the activemq-openwire-generator module + */ + class ConnectionControlMarshaller : public BaseCommandMarshaller + { + public: + + ConnectionControlMarshaller() {}; + virtual ~ConnectionControlMarshaller() {}; + + /** + * Creates a new instance of this marshalable type. + * @return new DataStructure object pointer caller owns it. + */ + virtual DataStructure* createObject() const; + + /** + * Get the Data Structure Type that identifies this Marshaller + * @return byte holding the data structure type value + */ + virtual unsigned char getDataStructureType() const; + + /** + * Un-marshal an object instance from the data input stream + * @param wireFormat - describs the wire format of the broker + * @param o - Object to be un-marshaled + * @param dataIn - BinaryReader that provides that data + * @param bs - BooleanStream + */ + virtual void tightUnmarshal( OpenWireFormat* wireFormat, + commands::DataStructure* dataStructure, + io::DataInputStream* dataIn, + util::BooleanStream* bs ) throws( io::IOException ); + + /** + * Write the booleans that this object uses to a BooleanStream + * @param wireFormat - describis the wire format of the broker + * @param o - Object to be marshaled + * @param bs - BooleanStream + * @returns int + */ + virtual int tightMarshal1( OpenWireFormat* wireFormat, + commands::DataStructure* dataStructure, + BooleanStream* bs ) throws( io::IOException ); + + /** + * Write a object instance to data output stream + * @param wireFormat - describs the wire format of the broker + * @param o - Object to be marshaled + * @param dataOut - BinaryReader that provides that data sink + * @param bs - BooleanStream + */ + virtual void tightMarshal2( OpenWireFormat* wireFormat, + commands::DataStructure* dataStructure, + io::DataOutputStream* dataOut, + BooleanStream* bs ) throws( io::IOException ); + + /** + * Un-marshal an object instance from the data input stream + * @param wireFormat - describs the wire format of the broker + * @param o - Object to be marshaled + * @param dataIn - BinaryReader that provides that data source + */ + virtual void looseUnmarshal( OpenWireFormat* wireFormat, + commands::DataStructure* dataStructure, + io::DataInputStream* dataIn ) throws( io::IOException ); + + /** + * Write a object instance to data output stream + * @param wireFormat - describs the wire format of the broker + * @param o - Object to be marshaled + * @param dataOut - BinaryWriter that provides that data sink + */ + virtual void looseMarshal( OpenWireFormat* wireFormat, + commands::DataStructure* dataStructure, + io::DataOutputStream* dataOut ) throws( io::IOException ); + + }; + +}}}}} + +#endif /*_ACTIVEMQ_CONNECTOR_OPENWIRE_MARSAHAL_V2_CONNECTIONCONTROLMARSHALLER_H_*/ + Propchange: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionControlMarshaller.h ------------------------------------------------------------------------------ svn:eol-style = native Added: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionErrorMarshaller.cpp URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionErrorMarshaller.cpp?view=auto&rev=465087 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionErrorMarshaller.cpp (added) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionErrorMarshaller.cpp Tue Oct 17 15:38:16 2006 @@ -0,0 +1,112 @@ +/* + * 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 + +#include + +// +// NOTE!: This file is autogenerated - do not modify! +// if you need to make a change, please see the Java Classes in the +// activemq-core module +// + +using namespace std; +using namespace activemq; +using namespace activemq::io; +using namespace activemq::connector; +using namespace activemq::connector::openwire; +using namespace activemq::connector::openwire::commands; +using namespace activemq::connector::openwire::marshal; +using namespace activemq::connector::openwire::util; +using namespace activemq::connector::openwire::marshal::v2; + +/////////////////////////////////////////////////////////////////////////////// +DataStructure* ConnectionErrorMarshaller::createObject() const { + return new ConnectionError(); +} + +/////////////////////////////////////////////////////////////////////////////// +unsigned char ConnectionErrorMarshaller::getDataStructureType() const { + return ConnectionError::ID_CONNECTIONERROR; +} + +/////////////////////////////////////////////////////////////////////////////// +void ConnectionErrorMarshaller::tightUnmarshal( OpenWireFormat* wireFormat, DataStructure* dataStructure, DataInputStream* dataIn, BooleanStream* bs ) { + BaseCommandMarshaller::tightUnmarshal( wireFormat, dataStructure, dataIn, bs ); + + ConnectionError* info = + dynamic_cast( dataStructure ); + info->setException( dynamic_cast< Throwable* >( + tightUnmarsalThrowable( wireFormat, dataIn, bs ) ); + info->setConnectionId( dynamic_cast< ConnectionId* >( + tightUnmarsalNestedObject( wireFormat, dataIn, bs ) ); +} + +/////////////////////////////////////////////////////////////////////////////// +int ConnectionErrorMarshaller::tightMarshal1( OpenWireFormat& wireFormat, DataStructure* dataStructure, BooleanStream& bs ) { + + ConnectionError* info = + dynamic_cast( dataStructure ); + + int rc = BaseCommandMarshaller::tightMarshal1( wireFormat, dataStructure, bs ); + rc += tightMarshalBrokerError1( wireFormat, info->getException(), bs ); + DataStructure* data = + dynamic_cast< DataStructure* >( info->getConnectionId() ); + + rc += tightMarshalNestedObject1( wireFormat, data, bs ); + + return rc + 0; +} + +/////////////////////////////////////////////////////////////////////////////// +void ConnectionErrorMarshaller::tightMarshal2( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataOutputStream& dataOut, BooleanStream& bs ) { + + BaseCommandMarshaller::tightMarshal2( wireFormat, dataStructure, dataOut, bs ); + + ConnectionError* info = + dynamic_cast( dataStructure ); + tightMarshalBrokerError2( wireFormat, info->getException(), dataOut, bs ); + DataStructure* data = + dynamic_cast< DataStructure* >( info->getConnectionId() ); + + tightMarshalNestedObject2( wireFormat, data, dataOut, bs ); +} + +/////////////////////////////////////////////////////////////////////////////// +void ConnectionErrorMarshaller::looseUnmarshal( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataInputStream& dataIn ) { + BaseCommandMarshaller::looseUnmarshal( wireFormat, dataStructure, dataIn ); + ConnectionError* info = + dynamic_cast( dataStructure ); + info->setException( looseUnmarshalBrokerError( wireFormat, dataIn ) ); + info->setConnectionId( dynamic_cast( + looseUnmarshalNestedObject( wireFormat, dataIn ) ) ); +} + +/////////////////////////////////////////////////////////////////////////////// +void ConnectionErrorMarshaller::looseMarshal( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataOutputStream& dataOut ) { + ConnectionError* info = + dynamic_cast( dataStructure ); + BaseCommandMarshaller::looseMarshal( wireFormat, dataStructure, dataOut ); + + looseMarshalBrokerError( wireFormat, info->getException(), dataOut ); + DataStructure* data = + dynamic_cast< DataStructure* >( info->getConnectionId() ); + + looseMarshalNestedObject( wireFormat, data, dataOut ); +} + Propchange: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionErrorMarshaller.cpp ------------------------------------------------------------------------------ svn:eol-style = native Added: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionErrorMarshaller.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionErrorMarshaller.h?view=auto&rev=465087 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionErrorMarshaller.h (added) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionErrorMarshaller.h Tue Oct 17 15:38:16 2006 @@ -0,0 +1,126 @@ +/* + * 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. + */ + +#ifndef _ACTIVEMQ_CONNECTOR_OPENWIRE_MARSAHAL_V2_CONNECTIONERRORMARSHALLER_H_ +#define _ACTIVEMQ_CONNECTOR_OPENWIRE_MARSAHAL_V2_CONNECTIONERRORMARSHALLER_H_ + +// Turn off warning message for ignored exception specification +#ifdef _MSC_VER +#pragma warning( disable : 4290 ) +#endif + +#include + +#include +#include +#include +#include +#include + +namespace activemq{ +namespace connector{ +namespace openwire{ +namespace marshal{ +namespace v2{ + + /** + * Marshalling code for Open Wire Format for ConnectionErrorMarshaller + * + * NOTE!: This file is autogenerated - do not modify! + * if you need to make a change, please see the Java Classes + * in the activemq-openwire-generator module + */ + class ConnectionErrorMarshaller : public BaseCommandMarshaller + { + public: + + ConnectionErrorMarshaller() {}; + virtual ~ConnectionErrorMarshaller() {}; + + /** + * Creates a new instance of this marshalable type. + * @return new DataStructure object pointer caller owns it. + */ + virtual DataStructure* createObject() const; + + /** + * Get the Data Structure Type that identifies this Marshaller + * @return byte holding the data structure type value + */ + virtual unsigned char getDataStructureType() const; + + /** + * Un-marshal an object instance from the data input stream + * @param wireFormat - describs the wire format of the broker + * @param o - Object to be un-marshaled + * @param dataIn - BinaryReader that provides that data + * @param bs - BooleanStream + */ + virtual void tightUnmarshal( OpenWireFormat* wireFormat, + commands::DataStructure* dataStructure, + io::DataInputStream* dataIn, + util::BooleanStream* bs ) throws( io::IOException ); + + /** + * Write the booleans that this object uses to a BooleanStream + * @param wireFormat - describis the wire format of the broker + * @param o - Object to be marshaled + * @param bs - BooleanStream + * @returns int + */ + virtual int tightMarshal1( OpenWireFormat* wireFormat, + commands::DataStructure* dataStructure, + BooleanStream* bs ) throws( io::IOException ); + + /** + * Write a object instance to data output stream + * @param wireFormat - describs the wire format of the broker + * @param o - Object to be marshaled + * @param dataOut - BinaryReader that provides that data sink + * @param bs - BooleanStream + */ + virtual void tightMarshal2( OpenWireFormat* wireFormat, + commands::DataStructure* dataStructure, + io::DataOutputStream* dataOut, + BooleanStream* bs ) throws( io::IOException ); + + /** + * Un-marshal an object instance from the data input stream + * @param wireFormat - describs the wire format of the broker + * @param o - Object to be marshaled + * @param dataIn - BinaryReader that provides that data source + */ + virtual void looseUnmarshal( OpenWireFormat* wireFormat, + commands::DataStructure* dataStructure, + io::DataInputStream* dataIn ) throws( io::IOException ); + + /** + * Write a object instance to data output stream + * @param wireFormat - describs the wire format of the broker + * @param o - Object to be marshaled + * @param dataOut - BinaryWriter that provides that data sink + */ + virtual void looseMarshal( OpenWireFormat* wireFormat, + commands::DataStructure* dataStructure, + io::DataOutputStream* dataOut ) throws( io::IOException ); + + }; + +}}}}} + +#endif /*_ACTIVEMQ_CONNECTOR_OPENWIRE_MARSAHAL_V2_CONNECTIONERRORMARSHALLER_H_*/ + Propchange: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionErrorMarshaller.h ------------------------------------------------------------------------------ svn:eol-style = native Added: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionIdMarshaller.cpp URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionIdMarshaller.cpp?view=auto&rev=465087 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionIdMarshaller.cpp (added) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionIdMarshaller.cpp Tue Oct 17 15:38:16 2006 @@ -0,0 +1,95 @@ +/* + * 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 + +#include + +// +// NOTE!: This file is autogenerated - do not modify! +// if you need to make a change, please see the Java Classes in the +// activemq-core module +// + +using namespace std; +using namespace activemq; +using namespace activemq::io; +using namespace activemq::connector; +using namespace activemq::connector::openwire; +using namespace activemq::connector::openwire::commands; +using namespace activemq::connector::openwire::marshal; +using namespace activemq::connector::openwire::util; +using namespace activemq::connector::openwire::marshal::v2; + +/////////////////////////////////////////////////////////////////////////////// +DataStructure* ConnectionIdMarshaller::createObject() const { + return new ConnectionId(); +} + +/////////////////////////////////////////////////////////////////////////////// +unsigned char ConnectionIdMarshaller::getDataStructureType() const { + return ConnectionId::ID_CONNECTIONID; +} + +/////////////////////////////////////////////////////////////////////////////// +void ConnectionIdMarshaller::tightUnmarshal( OpenWireFormat* wireFormat, DataStructure* dataStructure, DataInputStream* dataIn, BooleanStream* bs ) { + BaseDataStreamMarshaller::tightUnmarshal( wireFormat, dataStructure, dataIn, bs ); + + ConnectionId* info = + dynamic_cast( dataStructure ); + info->setValue( TightUnmarshalString( dataIn, bs ) ); +} + +/////////////////////////////////////////////////////////////////////////////// +int ConnectionIdMarshaller::tightMarshal1( OpenWireFormat& wireFormat, DataStructure* dataStructure, BooleanStream& bs ) { + + ConnectionId* info = + dynamic_cast( dataStructure ); + + int rc = BaseDataStreamMarshaller::tightMarshal1( wireFormat, dataStructure, bs ); + rc += tightMarshalString1( info->getValue(), bs ); + + return rc + 0; +} + +/////////////////////////////////////////////////////////////////////////////// +void ConnectionIdMarshaller::tightMarshal2( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataOutputStream& dataOut, BooleanStream& bs ) { + + BaseDataStreamMarshaller::tightMarshal2( wireFormat, dataStructure, dataOut, bs ); + + ConnectionId* info = + dynamic_cast( dataStructure ); + tightMarshalString2( info->getValue(), dataOut, bs ); +} + +/////////////////////////////////////////////////////////////////////////////// +void ConnectionIdMarshaller::looseUnmarshal( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataInputStream& dataIn ) { + BaseDataStreamMarshaller::looseUnmarshal( wireFormat, dataStructure, dataIn ); + ConnectionId* info = + dynamic_cast( dataStructure ); + info->setValue( looseUnmarshalString( dataIn ) ); +} + +/////////////////////////////////////////////////////////////////////////////// +void ConnectionIdMarshaller::looseMarshal( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataOutputStream& dataOut ) { + ConnectionId* info = + dynamic_cast( dataStructure ); + BaseDataStreamMarshaller::looseMarshal( wireFormat, dataStructure, dataOut ); + + looseMarshalString( info->getValue(), dataOut ); +} + Propchange: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionIdMarshaller.cpp ------------------------------------------------------------------------------ svn:eol-style = native Added: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionIdMarshaller.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionIdMarshaller.h?view=auto&rev=465087 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionIdMarshaller.h (added) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionIdMarshaller.h Tue Oct 17 15:38:16 2006 @@ -0,0 +1,126 @@ +/* + * 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. + */ + +#ifndef _ACTIVEMQ_CONNECTOR_OPENWIRE_MARSAHAL_V2_CONNECTIONIDMARSHALLER_H_ +#define _ACTIVEMQ_CONNECTOR_OPENWIRE_MARSAHAL_V2_CONNECTIONIDMARSHALLER_H_ + +// Turn off warning message for ignored exception specification +#ifdef _MSC_VER +#pragma warning( disable : 4290 ) +#endif + +#include + +#include +#include +#include +#include +#include + +namespace activemq{ +namespace connector{ +namespace openwire{ +namespace marshal{ +namespace v2{ + + /** + * Marshalling code for Open Wire Format for ConnectionIdMarshaller + * + * NOTE!: This file is autogenerated - do not modify! + * if you need to make a change, please see the Java Classes + * in the activemq-openwire-generator module + */ + class ConnectionIdMarshaller : public BaseDataStreamMarshaller + { + public: + + ConnectionIdMarshaller() {}; + virtual ~ConnectionIdMarshaller() {}; + + /** + * Creates a new instance of this marshalable type. + * @return new DataStructure object pointer caller owns it. + */ + virtual DataStructure* createObject() const; + + /** + * Get the Data Structure Type that identifies this Marshaller + * @return byte holding the data structure type value + */ + virtual unsigned char getDataStructureType() const; + + /** + * Un-marshal an object instance from the data input stream + * @param wireFormat - describs the wire format of the broker + * @param o - Object to be un-marshaled + * @param dataIn - BinaryReader that provides that data + * @param bs - BooleanStream + */ + virtual void tightUnmarshal( OpenWireFormat* wireFormat, + commands::DataStructure* dataStructure, + io::DataInputStream* dataIn, + util::BooleanStream* bs ) throws( io::IOException ); + + /** + * Write the booleans that this object uses to a BooleanStream + * @param wireFormat - describis the wire format of the broker + * @param o - Object to be marshaled + * @param bs - BooleanStream + * @returns int + */ + virtual int tightMarshal1( OpenWireFormat* wireFormat, + commands::DataStructure* dataStructure, + BooleanStream* bs ) throws( io::IOException ); + + /** + * Write a object instance to data output stream + * @param wireFormat - describs the wire format of the broker + * @param o - Object to be marshaled + * @param dataOut - BinaryReader that provides that data sink + * @param bs - BooleanStream + */ + virtual void tightMarshal2( OpenWireFormat* wireFormat, + commands::DataStructure* dataStructure, + io::DataOutputStream* dataOut, + BooleanStream* bs ) throws( io::IOException ); + + /** + * Un-marshal an object instance from the data input stream + * @param wireFormat - describs the wire format of the broker + * @param o - Object to be marshaled + * @param dataIn - BinaryReader that provides that data source + */ + virtual void looseUnmarshal( OpenWireFormat* wireFormat, + commands::DataStructure* dataStructure, + io::DataInputStream* dataIn ) throws( io::IOException ); + + /** + * Write a object instance to data output stream + * @param wireFormat - describs the wire format of the broker + * @param o - Object to be marshaled + * @param dataOut - BinaryWriter that provides that data sink + */ + virtual void looseMarshal( OpenWireFormat* wireFormat, + commands::DataStructure* dataStructure, + io::DataOutputStream* dataOut ) throws( io::IOException ); + + }; + +}}}}} + +#endif /*_ACTIVEMQ_CONNECTOR_OPENWIRE_MARSAHAL_V2_CONNECTIONIDMARSHALLER_H_*/ + Propchange: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionIdMarshaller.h ------------------------------------------------------------------------------ svn:eol-style = native Added: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionInfoMarshaller.cpp URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionInfoMarshaller.cpp?view=auto&rev=465087 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionInfoMarshaller.cpp (added) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionInfoMarshaller.cpp Tue Oct 17 15:38:16 2006 @@ -0,0 +1,160 @@ +/* + * 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 + +#include + +// +// NOTE!: This file is autogenerated - do not modify! +// if you need to make a change, please see the Java Classes in the +// activemq-core module +// + +using namespace std; +using namespace activemq; +using namespace activemq::io; +using namespace activemq::connector; +using namespace activemq::connector::openwire; +using namespace activemq::connector::openwire::commands; +using namespace activemq::connector::openwire::marshal; +using namespace activemq::connector::openwire::util; +using namespace activemq::connector::openwire::marshal::v2; + +/////////////////////////////////////////////////////////////////////////////// +DataStructure* ConnectionInfoMarshaller::createObject() const { + return new ConnectionInfo(); +} + +/////////////////////////////////////////////////////////////////////////////// +unsigned char ConnectionInfoMarshaller::getDataStructureType() const { + return ConnectionInfo::ID_CONNECTIONINFO; +} + +/////////////////////////////////////////////////////////////////////////////// +void ConnectionInfoMarshaller::tightUnmarshal( OpenWireFormat* wireFormat, DataStructure* dataStructure, DataInputStream* dataIn, BooleanStream* bs ) { + BaseCommandMarshaller::tightUnmarshal( wireFormat, dataStructure, dataIn, bs ); + + ConnectionInfo* info = + dynamic_cast( dataStructure ); + info->setConnectionId( dynamic_cast< ConnectionId* >( + tightUnmarsalCachedObject( wireFormat, dataIn, bs ) ); + info->setClientId( TightUnmarshalString( dataIn, bs ) ); + info->setPassword( TightUnmarshalString( dataIn, bs ) ); + info->setUserName( TightUnmarshalString( dataIn, bs ) ); + + if( bs->readBoolean() ) { + short size = dataIn->readShort(); + BrokerId* value = new BrokerId[size]; + for( int i = 0; i < size; i++ ) { + value[i] = dynamic_cast< BrokerId* >( + tightUnmarsalNestedObject( wireFormat, dataIn, bs ) ); + } + info->setBrokerPath( value ); + } + else { + info->setBrokerPath( NULL ); + } + info->setBrokerMasterConnector( bs->readBoolean() ); + info->setManageable( bs->readBoolean() ); +} + +/////////////////////////////////////////////////////////////////////////////// +int ConnectionInfoMarshaller::tightMarshal1( OpenWireFormat& wireFormat, DataStructure* dataStructure, BooleanStream& bs ) { + + ConnectionInfo* info = + dynamic_cast( dataStructure ); + + int rc = BaseCommandMarshaller::tightMarshal1( wireFormat, dataStructure, bs ); + DataStructure* data = + dynamic_cast< DataStructure* >( info->getConnectionId() ); + + rc += tightMarshalCachedObject1( wireFormat, data, bs ); + rc += tightMarshalString1( info->getClientId(), bs ); + rc += tightMarshalString1( info->getPassword(), bs ); + rc += tightMarshalString1( info->getUserName(), bs ); + rc += tightMarshalObjectArray1( wireFormat, info->getBrokerPath(), bs ); + bs->writeBoolean( info->isBrokerMasterConnector() ); + bs->writeBoolean( info->isManageable() ); + + return rc + 0; +} + +/////////////////////////////////////////////////////////////////////////////// +void ConnectionInfoMarshaller::tightMarshal2( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataOutputStream& dataOut, BooleanStream& bs ) { + + BaseCommandMarshaller::tightMarshal2( wireFormat, dataStructure, dataOut, bs ); + + ConnectionInfo* info = + dynamic_cast( dataStructure ); + DataStructure* data = + dynamic_cast< DataStructure* >( info->getConnectionId() ); + + tightMarshalCachedObject2( wireFormat, data, dataOut, bs ); + tightMarshalString2( info->getClientId(), dataOut, bs ); + tightMarshalString2( info->getPassword(), dataOut, bs ); + tightMarshalString2( info->getUserName(), dataOut, bs ); + tightMarshalObjectArray2( wireFormat, info->getBrokerPath(), dataOut, bs ); + bs->readBoolean(); + bs->readBoolean(); +} + +/////////////////////////////////////////////////////////////////////////////// +void ConnectionInfoMarshaller::looseUnmarshal( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataInputStream& dataIn ) { + BaseCommandMarshaller::looseUnmarshal( wireFormat, dataStructure, dataIn ); + ConnectionInfo* info = + dynamic_cast( dataStructure ); + info->setConnectionId( dynamic_cast( + looseUnmarshalCachedObject( wireFormat, dataIn ) ) ); + info->setClientId( looseUnmarshalString( dataIn ) ); + info->setPassword( looseUnmarshalString( dataIn ) ); + info->setUserName( looseUnmarshalString( dataIn ) ); + + if( dataIn->readBoolean() ) { + short size = dataIn->readShort(); + BrokerId* value = new BrokerId[size]; + for( int i = 0; i < size; i++ ) { + value[i] = dynamic_cast( + looseUnmarshalNestedObject( wireFormat,dataIn ) ); + } + info->setBrokerPath( value ); + } + else { + info->setBrokerPath( NULL ); + } + info->setBrokerMasterConnector( dataIn->readBoolean() ); + info->setManageable( dataIn->readBoolean() ); +} + +/////////////////////////////////////////////////////////////////////////////// +void ConnectionInfoMarshaller::looseMarshal( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataOutputStream& dataOut ) { + ConnectionInfo* info = + dynamic_cast( dataStructure ); + BaseCommandMarshaller::looseMarshal( wireFormat, dataStructure, dataOut ); + + DataStructure* data = + dynamic_cast< DataStructure* >( info->getConnectionId() ); + + looseMarshalCachedObject( wireFormat, data, dataOut ); + looseMarshalString( info->getClientId(), dataOut ); + looseMarshalString( info->getPassword(), dataOut ); + looseMarshalString( info->getUserName(), dataOut ); + looseMarshalObjectArray( wireFormat, info->getBrokerPath(), dataOut ); + dataOut->write( info->isBrokerMasterConnector() ); + dataOut->write( info->isManageable() ); +} + Propchange: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionInfoMarshaller.cpp ------------------------------------------------------------------------------ svn:eol-style = native Added: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionInfoMarshaller.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionInfoMarshaller.h?view=auto&rev=465087 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionInfoMarshaller.h (added) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionInfoMarshaller.h Tue Oct 17 15:38:16 2006 @@ -0,0 +1,126 @@ +/* + * 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. + */ + +#ifndef _ACTIVEMQ_CONNECTOR_OPENWIRE_MARSAHAL_V2_CONNECTIONINFOMARSHALLER_H_ +#define _ACTIVEMQ_CONNECTOR_OPENWIRE_MARSAHAL_V2_CONNECTIONINFOMARSHALLER_H_ + +// Turn off warning message for ignored exception specification +#ifdef _MSC_VER +#pragma warning( disable : 4290 ) +#endif + +#include + +#include +#include +#include +#include +#include + +namespace activemq{ +namespace connector{ +namespace openwire{ +namespace marshal{ +namespace v2{ + + /** + * Marshalling code for Open Wire Format for ConnectionInfoMarshaller + * + * NOTE!: This file is autogenerated - do not modify! + * if you need to make a change, please see the Java Classes + * in the activemq-openwire-generator module + */ + class ConnectionInfoMarshaller : public BaseCommandMarshaller + { + public: + + ConnectionInfoMarshaller() {}; + virtual ~ConnectionInfoMarshaller() {}; + + /** + * Creates a new instance of this marshalable type. + * @return new DataStructure object pointer caller owns it. + */ + virtual DataStructure* createObject() const; + + /** + * Get the Data Structure Type that identifies this Marshaller + * @return byte holding the data structure type value + */ + virtual unsigned char getDataStructureType() const; + + /** + * Un-marshal an object instance from the data input stream + * @param wireFormat - describs the wire format of the broker + * @param o - Object to be un-marshaled + * @param dataIn - BinaryReader that provides that data + * @param bs - BooleanStream + */ + virtual void tightUnmarshal( OpenWireFormat* wireFormat, + commands::DataStructure* dataStructure, + io::DataInputStream* dataIn, + util::BooleanStream* bs ) throws( io::IOException ); + + /** + * Write the booleans that this object uses to a BooleanStream + * @param wireFormat - describis the wire format of the broker + * @param o - Object to be marshaled + * @param bs - BooleanStream + * @returns int + */ + virtual int tightMarshal1( OpenWireFormat* wireFormat, + commands::DataStructure* dataStructure, + BooleanStream* bs ) throws( io::IOException ); + + /** + * Write a object instance to data output stream + * @param wireFormat - describs the wire format of the broker + * @param o - Object to be marshaled + * @param dataOut - BinaryReader that provides that data sink + * @param bs - BooleanStream + */ + virtual void tightMarshal2( OpenWireFormat* wireFormat, + commands::DataStructure* dataStructure, + io::DataOutputStream* dataOut, + BooleanStream* bs ) throws( io::IOException ); + + /** + * Un-marshal an object instance from the data input stream + * @param wireFormat - describs the wire format of the broker + * @param o - Object to be marshaled + * @param dataIn - BinaryReader that provides that data source + */ + virtual void looseUnmarshal( OpenWireFormat* wireFormat, + commands::DataStructure* dataStructure, + io::DataInputStream* dataIn ) throws( io::IOException ); + + /** + * Write a object instance to data output stream + * @param wireFormat - describs the wire format of the broker + * @param o - Object to be marshaled + * @param dataOut - BinaryWriter that provides that data sink + */ + virtual void looseMarshal( OpenWireFormat* wireFormat, + commands::DataStructure* dataStructure, + io::DataOutputStream* dataOut ) throws( io::IOException ); + + }; + +}}}}} + +#endif /*_ACTIVEMQ_CONNECTOR_OPENWIRE_MARSAHAL_V2_CONNECTIONINFOMARSHALLER_H_*/ + Propchange: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionInfoMarshaller.h ------------------------------------------------------------------------------ svn:eol-style = native Added: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConsumerControlMarshaller.cpp URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConsumerControlMarshaller.cpp?view=auto&rev=465087 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConsumerControlMarshaller.cpp (added) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConsumerControlMarshaller.cpp Tue Oct 17 15:38:16 2006 @@ -0,0 +1,115 @@ +/* + * 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 + +#include + +// +// NOTE!: This file is autogenerated - do not modify! +// if you need to make a change, please see the Java Classes in the +// activemq-core module +// + +using namespace std; +using namespace activemq; +using namespace activemq::io; +using namespace activemq::connector; +using namespace activemq::connector::openwire; +using namespace activemq::connector::openwire::commands; +using namespace activemq::connector::openwire::marshal; +using namespace activemq::connector::openwire::util; +using namespace activemq::connector::openwire::marshal::v2; + +/////////////////////////////////////////////////////////////////////////////// +DataStructure* ConsumerControlMarshaller::createObject() const { + return new ConsumerControl(); +} + +/////////////////////////////////////////////////////////////////////////////// +unsigned char ConsumerControlMarshaller::getDataStructureType() const { + return ConsumerControl::ID_CONSUMERCONTROL; +} + +/////////////////////////////////////////////////////////////////////////////// +void ConsumerControlMarshaller::tightUnmarshal( OpenWireFormat* wireFormat, DataStructure* dataStructure, DataInputStream* dataIn, BooleanStream* bs ) { + BaseCommandMarshaller::tightUnmarshal( wireFormat, dataStructure, dataIn, bs ); + + ConsumerControl* info = + dynamic_cast( dataStructure ); + info->setClose( bs->readBoolean() ); + info->setConsumerId( dynamic_cast< ConsumerId* >( + tightUnmarsalNestedObject( wireFormat, dataIn, bs ) ); + info->setPrefetch( dataIn->readInt() ); +} + +/////////////////////////////////////////////////////////////////////////////// +int ConsumerControlMarshaller::tightMarshal1( OpenWireFormat& wireFormat, DataStructure* dataStructure, BooleanStream& bs ) { + + ConsumerControl* info = + dynamic_cast( dataStructure ); + + int rc = BaseCommandMarshaller::tightMarshal1( wireFormat, dataStructure, bs ); + bs->writeBoolean( info->isClose() ); + DataStructure* data = + dynamic_cast< DataStructure* >( info->getConsumerId() ); + + rc += tightMarshalNestedObject1( wireFormat, data, bs ); + + return rc + 4; +} + +/////////////////////////////////////////////////////////////////////////////// +void ConsumerControlMarshaller::tightMarshal2( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataOutputStream& dataOut, BooleanStream& bs ) { + + BaseCommandMarshaller::tightMarshal2( wireFormat, dataStructure, dataOut, bs ); + + ConsumerControl* info = + dynamic_cast( dataStructure ); + bs->readBoolean(); + DataStructure* data = + dynamic_cast< DataStructure* >( info->getConsumerId() ); + + tightMarshalNestedObject2( wireFormat, data, dataOut, bs ); + dataOut->write( info->getPrefetch() ); +} + +/////////////////////////////////////////////////////////////////////////////// +void ConsumerControlMarshaller::looseUnmarshal( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataInputStream& dataIn ) { + BaseCommandMarshaller::looseUnmarshal( wireFormat, dataStructure, dataIn ); + ConsumerControl* info = + dynamic_cast( dataStructure ); + info->setClose( dataIn->readBoolean() ); + info->setConsumerId( dynamic_cast( + looseUnmarshalNestedObject( wireFormat, dataIn ) ) ); + info->setPrefetch( dataIn->readInt() ); +} + +/////////////////////////////////////////////////////////////////////////////// +void ConsumerControlMarshaller::looseMarshal( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataOutputStream& dataOut ) { + ConsumerControl* info = + dynamic_cast( dataStructure ); + BaseCommandMarshaller::looseMarshal( wireFormat, dataStructure, dataOut ); + + dataOut->write( info->isClose() ); + DataStructure* data = + dynamic_cast< DataStructure* >( info->getConsumerId() ); + + looseMarshalNestedObject( wireFormat, data, dataOut ); + dataOut->write( info->getPrefetch() ); +} + Propchange: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConsumerControlMarshaller.cpp ------------------------------------------------------------------------------ svn:eol-style = native Added: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConsumerControlMarshaller.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConsumerControlMarshaller.h?view=auto&rev=465087 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConsumerControlMarshaller.h (added) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConsumerControlMarshaller.h Tue Oct 17 15:38:16 2006 @@ -0,0 +1,126 @@ +/* + * 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. + */ + +#ifndef _ACTIVEMQ_CONNECTOR_OPENWIRE_MARSAHAL_V2_CONSUMERCONTROLMARSHALLER_H_ +#define _ACTIVEMQ_CONNECTOR_OPENWIRE_MARSAHAL_V2_CONSUMERCONTROLMARSHALLER_H_ + +// Turn off warning message for ignored exception specification +#ifdef _MSC_VER +#pragma warning( disable : 4290 ) +#endif + +#include + +#include +#include +#include +#include +#include + +namespace activemq{ +namespace connector{ +namespace openwire{ +namespace marshal{ +namespace v2{ + + /** + * Marshalling code for Open Wire Format for ConsumerControlMarshaller + * + * NOTE!: This file is autogenerated - do not modify! + * if you need to make a change, please see the Java Classes + * in the activemq-openwire-generator module + */ + class ConsumerControlMarshaller : public BaseCommandMarshaller + { + public: + + ConsumerControlMarshaller() {}; + virtual ~ConsumerControlMarshaller() {}; + + /** + * Creates a new instance of this marshalable type. + * @return new DataStructure object pointer caller owns it. + */ + virtual DataStructure* createObject() const; + + /** + * Get the Data Structure Type that identifies this Marshaller + * @return byte holding the data structure type value + */ + virtual unsigned char getDataStructureType() const; + + /** + * Un-marshal an object instance from the data input stream + * @param wireFormat - describs the wire format of the broker + * @param o - Object to be un-marshaled + * @param dataIn - BinaryReader that provides that data + * @param bs - BooleanStream + */ + virtual void tightUnmarshal( OpenWireFormat* wireFormat, + commands::DataStructure* dataStructure, + io::DataInputStream* dataIn, + util::BooleanStream* bs ) throws( io::IOException ); + + /** + * Write the booleans that this object uses to a BooleanStream + * @param wireFormat - describis the wire format of the broker + * @param o - Object to be marshaled + * @param bs - BooleanStream + * @returns int + */ + virtual int tightMarshal1( OpenWireFormat* wireFormat, + commands::DataStructure* dataStructure, + BooleanStream* bs ) throws( io::IOException ); + + /** + * Write a object instance to data output stream + * @param wireFormat - describs the wire format of the broker + * @param o - Object to be marshaled + * @param dataOut - BinaryReader that provides that data sink + * @param bs - BooleanStream + */ + virtual void tightMarshal2( OpenWireFormat* wireFormat, + commands::DataStructure* dataStructure, + io::DataOutputStream* dataOut, + BooleanStream* bs ) throws( io::IOException ); + + /** + * Un-marshal an object instance from the data input stream + * @param wireFormat - describs the wire format of the broker + * @param o - Object to be marshaled + * @param dataIn - BinaryReader that provides that data source + */ + virtual void looseUnmarshal( OpenWireFormat* wireFormat, + commands::DataStructure* dataStructure, + io::DataInputStream* dataIn ) throws( io::IOException ); + + /** + * Write a object instance to data output stream + * @param wireFormat - describs the wire format of the broker + * @param o - Object to be marshaled + * @param dataOut - BinaryWriter that provides that data sink + */ + virtual void looseMarshal( OpenWireFormat* wireFormat, + commands::DataStructure* dataStructure, + io::DataOutputStream* dataOut ) throws( io::IOException ); + + }; + +}}}}} + +#endif /*_ACTIVEMQ_CONNECTOR_OPENWIRE_MARSAHAL_V2_CONSUMERCONTROLMARSHALLER_H_*/ + Propchange: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConsumerControlMarshaller.h ------------------------------------------------------------------------------ svn:eol-style = native Added: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConsumerIdMarshaller.cpp URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConsumerIdMarshaller.cpp?view=auto&rev=465087 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConsumerIdMarshaller.cpp (added) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConsumerIdMarshaller.cpp Tue Oct 17 15:38:16 2006 @@ -0,0 +1,105 @@ +/* + * 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 + +#include + +// +// NOTE!: This file is autogenerated - do not modify! +// if you need to make a change, please see the Java Classes in the +// activemq-core module +// + +using namespace std; +using namespace activemq; +using namespace activemq::io; +using namespace activemq::connector; +using namespace activemq::connector::openwire; +using namespace activemq::connector::openwire::commands; +using namespace activemq::connector::openwire::marshal; +using namespace activemq::connector::openwire::util; +using namespace activemq::connector::openwire::marshal::v2; + +/////////////////////////////////////////////////////////////////////////////// +DataStructure* ConsumerIdMarshaller::createObject() const { + return new ConsumerId(); +} + +/////////////////////////////////////////////////////////////////////////////// +unsigned char ConsumerIdMarshaller::getDataStructureType() const { + return ConsumerId::ID_CONSUMERID; +} + +/////////////////////////////////////////////////////////////////////////////// +void ConsumerIdMarshaller::tightUnmarshal( OpenWireFormat* wireFormat, DataStructure* dataStructure, DataInputStream* dataIn, BooleanStream* bs ) { + BaseDataStreamMarshaller::tightUnmarshal( wireFormat, dataStructure, dataIn, bs ); + + ConsumerId* info = + dynamic_cast( dataStructure ); + info->setConnectionId( TightUnmarshalString( dataIn, bs ) ); + info->setSessionId( TightUnmarshalLong( wireFormat, dataIn, bs ) ); + info->setValue( TightUnmarshalLong( wireFormat, dataIn, bs ) ); +} + +/////////////////////////////////////////////////////////////////////////////// +int ConsumerIdMarshaller::tightMarshal1( OpenWireFormat& wireFormat, DataStructure* dataStructure, BooleanStream& bs ) { + + ConsumerId* info = + dynamic_cast( dataStructure ); + + int rc = BaseDataStreamMarshaller::tightMarshal1( wireFormat, dataStructure, bs ); + rc += tightMarshalString1( info->getConnectionId(), bs ); + rc += tightMarshalLong1( wireFormat, info->getSessionId(), bs ); + rc += tightMarshalLong1( wireFormat, info->getValue(), bs ); + + return rc + 0; +} + +/////////////////////////////////////////////////////////////////////////////// +void ConsumerIdMarshaller::tightMarshal2( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataOutputStream& dataOut, BooleanStream& bs ) { + + BaseDataStreamMarshaller::tightMarshal2( wireFormat, dataStructure, dataOut, bs ); + + ConsumerId* info = + dynamic_cast( dataStructure ); + tightMarshalString2( info->getConnectionId(), dataOut, bs ); + tightMarshalLong2( wireFormat, info->getSessionId(), dataOut, bs ); + tightMarshalLong2( wireFormat, info->getValue(), dataOut, bs ); +} + +/////////////////////////////////////////////////////////////////////////////// +void ConsumerIdMarshaller::looseUnmarshal( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataInputStream& dataIn ) { + BaseDataStreamMarshaller::looseUnmarshal( wireFormat, dataStructure, dataIn ); + ConsumerId* info = + dynamic_cast( dataStructure ); + info->setConnectionId( looseUnmarshalString( dataIn ) ); + info->setSessionId( looseUnmarshalLong( wireFormat, dataIn ) ); + info->setValue( looseUnmarshalLong( wireFormat, dataIn ) ); +} + +/////////////////////////////////////////////////////////////////////////////// +void ConsumerIdMarshaller::looseMarshal( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataOutputStream& dataOut ) { + ConsumerId* info = + dynamic_cast( dataStructure ); + BaseDataStreamMarshaller::looseMarshal( wireFormat, dataStructure, dataOut ); + + looseMarshalString( info->getConnectionId(), dataOut ); + looseMarshalLong( wireFormat, info->getSessionId(), dataOut ); + looseMarshalLong( wireFormat, info->getValue(), dataOut ); +} + Propchange: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConsumerIdMarshaller.cpp ------------------------------------------------------------------------------ svn:eol-style = native Added: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConsumerIdMarshaller.h URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConsumerIdMarshaller.h?view=auto&rev=465087 ============================================================================== --- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConsumerIdMarshaller.h (added) +++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConsumerIdMarshaller.h Tue Oct 17 15:38:16 2006 @@ -0,0 +1,126 @@ +/* + * 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. + */ + +#ifndef _ACTIVEMQ_CONNECTOR_OPENWIRE_MARSAHAL_V2_CONSUMERIDMARSHALLER_H_ +#define _ACTIVEMQ_CONNECTOR_OPENWIRE_MARSAHAL_V2_CONSUMERIDMARSHALLER_H_ + +// Turn off warning message for ignored exception specification +#ifdef _MSC_VER +#pragma warning( disable : 4290 ) +#endif + +#include + +#include +#include +#include +#include +#include + +namespace activemq{ +namespace connector{ +namespace openwire{ +namespace marshal{ +namespace v2{ + + /** + * Marshalling code for Open Wire Format for ConsumerIdMarshaller + * + * NOTE!: This file is autogenerated - do not modify! + * if you need to make a change, please see the Java Classes + * in the activemq-openwire-generator module + */ + class ConsumerIdMarshaller : public BaseDataStreamMarshaller + { + public: + + ConsumerIdMarshaller() {}; + virtual ~ConsumerIdMarshaller() {}; + + /** + * Creates a new instance of this marshalable type. + * @return new DataStructure object pointer caller owns it. + */ + virtual DataStructure* createObject() const; + + /** + * Get the Data Structure Type that identifies this Marshaller + * @return byte holding the data structure type value + */ + virtual unsigned char getDataStructureType() const; + + /** + * Un-marshal an object instance from the data input stream + * @param wireFormat - describs the wire format of the broker + * @param o - Object to be un-marshaled + * @param dataIn - BinaryReader that provides that data + * @param bs - BooleanStream + */ + virtual void tightUnmarshal( OpenWireFormat* wireFormat, + commands::DataStructure* dataStructure, + io::DataInputStream* dataIn, + util::BooleanStream* bs ) throws( io::IOException ); + + /** + * Write the booleans that this object uses to a BooleanStream + * @param wireFormat - describis the wire format of the broker + * @param o - Object to be marshaled + * @param bs - BooleanStream + * @returns int + */ + virtual int tightMarshal1( OpenWireFormat* wireFormat, + commands::DataStructure* dataStructure, + BooleanStream* bs ) throws( io::IOException ); + + /** + * Write a object instance to data output stream + * @param wireFormat - describs the wire format of the broker + * @param o - Object to be marshaled + * @param dataOut - BinaryReader that provides that data sink + * @param bs - BooleanStream + */ + virtual void tightMarshal2( OpenWireFormat* wireFormat, + commands::DataStructure* dataStructure, + io::DataOutputStream* dataOut, + BooleanStream* bs ) throws( io::IOException ); + + /** + * Un-marshal an object instance from the data input stream + * @param wireFormat - describs the wire format of the broker + * @param o - Object to be marshaled + * @param dataIn - BinaryReader that provides that data source + */ + virtual void looseUnmarshal( OpenWireFormat* wireFormat, + commands::DataStructure* dataStructure, + io::DataInputStream* dataIn ) throws( io::IOException ); + + /** + * Write a object instance to data output stream + * @param wireFormat - describs the wire format of the broker + * @param o - Object to be marshaled + * @param dataOut - BinaryWriter that provides that data sink + */ + virtual void looseMarshal( OpenWireFormat* wireFormat, + commands::DataStructure* dataStructure, + io::DataOutputStream* dataOut ) throws( io::IOException ); + + }; + +}}}}} + +#endif /*_ACTIVEMQ_CONNECTOR_OPENWIRE_MARSAHAL_V2_CONSUMERIDMARSHALLER_H_*/ + Propchange: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConsumerIdMarshaller.h ------------------------------------------------------------------------------ svn:eol-style = native