You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@activemq.apache.org by ta...@apache.org on 2006/10/02 16:30:22 UTC
svn commit: r452053 [16/17] - in
/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src:
main/activemq/connector/openwire/ main/activemq/connector/openwire/commands/
main/activemq/connector/openwire/marshal/
main/activemq/connector/openwire/marshal/V2...
Added: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/SessionInfoMarshaller.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/SessionInfoMarshaller.h?view=auto&rev=452053
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/SessionInfoMarshaller.h (added)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/SessionInfoMarshaller.h Mon Oct 2 07:30:10 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_SESSIONINFOMARSHALLER_H_
+#define _ACTIVEMQ_CONNECTOR_OPENWIRE_MARSAHAL_V2_SESSIONINFOMARSHALLER_H_
+
+// Turn off warning message for ignored exception specification
+#ifdef _MSC_VER
+#pragma warning( disable : 4290 )
+#endif
+
+#include <activemq/connector/openwire/marshal/V2/BaseCommandMarshaller.h>
+
+#include <activemq/io/DataInputStream.h>
+#include <activemq/io/DataOutputStream.h>
+#include <activemq/io/IOException.h>
+#include <activemq/connector/openwire/commands/DataStructure.h>
+#include <activemq/connector/openwire/util/BooleanStream.h>
+
+namespace activemq{
+namespace connector{
+namespace openwire{
+namespace marshal{
+namespace v2{
+
+ /**
+ * Marshalling code for Open Wire Format for SessionInfoMarshaller
+ *
+ * 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 SessionInfoMarshaller : public BaseCommandMarshaller
+ {
+ public:
+
+ SessionInfoMarshaller() {};
+ virtual ~SessionInfoMarshaller() {};
+
+ /**
+ * 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_SESSIONINFOMARSHALLER_H_*/
+
Propchange: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/SessionInfoMarshaller.h
------------------------------------------------------------------------------
svn:eol-style = native
Added: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/ShutdownInfoMarshaller.cpp
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/ShutdownInfoMarshaller.cpp?view=auto&rev=452053
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/ShutdownInfoMarshaller.cpp (added)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/ShutdownInfoMarshaller.cpp Mon Oct 2 07:30:10 2006
@@ -0,0 +1,79 @@
+/*
+ * 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 <activemq/connector/openwire/marshal/v2/ShutdownInfoMarshaller.h>
+
+#include <activemq/connector/openwire/commands/ShutdownInfo.h>
+
+//
+// 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* ShutdownInfoMarshaller::createObject() const {
+ return new ShutdownInfo();
+}
+
+///////////////////////////////////////////////////////////////////////////////
+unsigned char ShutdownInfoMarshaller::getDataStructureType() const {
+ return ShutdownInfo::ID_SHUTDOWNINFO;
+}
+
+///////////////////////////////////////////////////////////////////////////////
+void ShutdownInfoMarshaller::tightUnmarshal( OpenWireFormat* wireFormat, DataStructure* dataStructure, DataInputStream* dataIn, BooleanStream* bs ) {
+ BaseCommandMarshaller::tightUnmarshal( wireFormat, dataStructure, dataIn, bs );
+
+}
+
+///////////////////////////////////////////////////////////////////////////////
+int ShutdownInfoMarshaller::tightMarshal1( OpenWireFormat& wireFormat, DataStructure* dataStructure, BooleanStream& bs ) {
+
+ int rc = BaseCommandMarshaller::tightMarshal1( wireFormat, dataStructure, bs );
+
+ return rc + 0;
+}
+
+///////////////////////////////////////////////////////////////////////////////
+void ShutdownInfoMarshaller::tightMarshal2( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataOutputStream& dataOut, BooleanStream& bs ) {
+
+ BaseCommandMarshaller::tightMarshal2( wireFormat, dataStructure, dataOut, bs );
+
+}
+
+///////////////////////////////////////////////////////////////////////////////
+void ShutdownInfoMarshaller::looseUnmarshal( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataInputStream& dataIn ) {
+ BaseCommandMarshaller::looseUnmarshal( wireFormat, dataStructure, dataIn );
+}
+
+///////////////////////////////////////////////////////////////////////////////
+void ShutdownInfoMarshaller::looseMarshal( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataOutputStream& dataOut ) {
+ BaseCommandMarshaller::looseMarshal( wireFormat, dataStructure, dataOut );
+
+}
+
Propchange: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/ShutdownInfoMarshaller.cpp
------------------------------------------------------------------------------
svn:eol-style = native
Added: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/ShutdownInfoMarshaller.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/ShutdownInfoMarshaller.h?view=auto&rev=452053
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/ShutdownInfoMarshaller.h (added)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/ShutdownInfoMarshaller.h Mon Oct 2 07:30:10 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_SHUTDOWNINFOMARSHALLER_H_
+#define _ACTIVEMQ_CONNECTOR_OPENWIRE_MARSAHAL_V2_SHUTDOWNINFOMARSHALLER_H_
+
+// Turn off warning message for ignored exception specification
+#ifdef _MSC_VER
+#pragma warning( disable : 4290 )
+#endif
+
+#include <activemq/connector/openwire/marshal/V2/BaseCommandMarshaller.h>
+
+#include <activemq/io/DataInputStream.h>
+#include <activemq/io/DataOutputStream.h>
+#include <activemq/io/IOException.h>
+#include <activemq/connector/openwire/commands/DataStructure.h>
+#include <activemq/connector/openwire/util/BooleanStream.h>
+
+namespace activemq{
+namespace connector{
+namespace openwire{
+namespace marshal{
+namespace v2{
+
+ /**
+ * Marshalling code for Open Wire Format for ShutdownInfoMarshaller
+ *
+ * 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 ShutdownInfoMarshaller : public BaseCommandMarshaller
+ {
+ public:
+
+ ShutdownInfoMarshaller() {};
+ virtual ~ShutdownInfoMarshaller() {};
+
+ /**
+ * 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_SHUTDOWNINFOMARSHALLER_H_*/
+
Propchange: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/ShutdownInfoMarshaller.h
------------------------------------------------------------------------------
svn:eol-style = native
Added: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/SubscriptionInfoMarshaller.cpp
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/SubscriptionInfoMarshaller.cpp?view=auto&rev=452053
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/SubscriptionInfoMarshaller.cpp (added)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/SubscriptionInfoMarshaller.cpp Mon Oct 2 07:30:10 2006
@@ -0,0 +1,121 @@
+/*
+ * 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 <activemq/connector/openwire/marshal/v2/SubscriptionInfoMarshaller.h>
+
+#include <activemq/connector/openwire/commands/SubscriptionInfo.h>
+
+//
+// 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* SubscriptionInfoMarshaller::createObject() const {
+ return new SubscriptionInfo();
+}
+
+///////////////////////////////////////////////////////////////////////////////
+unsigned char SubscriptionInfoMarshaller::getDataStructureType() const {
+ return SubscriptionInfo::ID_SUBSCRIPTIONINFO;
+}
+
+///////////////////////////////////////////////////////////////////////////////
+void SubscriptionInfoMarshaller::tightUnmarshal( OpenWireFormat* wireFormat, DataStructure* dataStructure, DataInputStream* dataIn, BooleanStream* bs ) {
+ BaseDataStreamMarshaller::tightUnmarshal( wireFormat, dataStructure, dataIn, bs );
+
+ SubscriptionInfo* info =
+ dynamic_cast<SubscriptionInfo*>( dataStructure );
+ info->setClientId( TightUnmarshalString( dataIn, bs ) );
+ info->setDestination( dynamic_cast< ActiveMQDestination* >(
+ tightUnmarsalCachedObject( wireFormat, dataIn, bs ) );
+ info->setSelector( TightUnmarshalString( dataIn, bs ) );
+ info->setSubcriptionName( TightUnmarshalString( dataIn, bs ) );
+}
+
+///////////////////////////////////////////////////////////////////////////////
+int SubscriptionInfoMarshaller::tightMarshal1( OpenWireFormat& wireFormat, DataStructure* dataStructure, BooleanStream& bs ) {
+
+ SubscriptionInfo* info =
+ dynamic_cast<SubscriptionInfo*>( dataStructure );
+
+ int rc = BaseDataStreamMarshaller::tightMarshal1( wireFormat, dataStructure, bs );
+ rc += tightMarshalString1( info->getClientId(), bs );
+ DataStructure* data =
+ dynamic_cast< DataStructure* >( info->getDestination() );
+
+ rc += tightMarshalCachedObject1( wireFormat, data, bs );
+ rc += tightMarshalString1( info->getSelector(), bs );
+ rc += tightMarshalString1( info->getSubcriptionName(), bs );
+
+ return rc + 0;
+}
+
+///////////////////////////////////////////////////////////////////////////////
+void SubscriptionInfoMarshaller::tightMarshal2( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataOutputStream& dataOut, BooleanStream& bs ) {
+
+ BaseDataStreamMarshaller::tightMarshal2( wireFormat, dataStructure, dataOut, bs );
+
+ SubscriptionInfo* info =
+ dynamic_cast<SubscriptionInfo*>( dataStructure );
+ tightMarshalString2( info->getClientId(), dataOut, bs );
+ DataStructure* data =
+ dynamic_cast< DataStructure* >( info->getDestination() );
+
+ tightMarshalCachedObject2( wireFormat, data, dataOut, bs );
+ tightMarshalString2( info->getSelector(), dataOut, bs );
+ tightMarshalString2( info->getSubcriptionName(), dataOut, bs );
+}
+
+///////////////////////////////////////////////////////////////////////////////
+void SubscriptionInfoMarshaller::looseUnmarshal( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataInputStream& dataIn ) {
+ BaseDataStreamMarshaller::looseUnmarshal( wireFormat, dataStructure, dataIn );
+ SubscriptionInfo* info =
+ dynamic_cast<SubscriptionInfo*>( dataStructure );
+ info->setClientId( looseUnmarshalString( dataIn ) );
+ info->setDestination( dynamic_cast<ActiveMQDestination* >(
+ looseUnmarshalCachedObject( wireFormat, dataIn ) ) );
+ info->setSelector( looseUnmarshalString( dataIn ) );
+ info->setSubcriptionName( looseUnmarshalString( dataIn ) );
+}
+
+///////////////////////////////////////////////////////////////////////////////
+void SubscriptionInfoMarshaller::looseMarshal( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataOutputStream& dataOut ) {
+ SubscriptionInfo* info =
+ dynamic_cast<SubscriptionInfo*>( dataStructure );
+ BaseDataStreamMarshaller::looseMarshal( wireFormat, dataStructure, dataOut );
+
+ looseMarshalString( info->getClientId(), dataOut );
+ DataStructure* data =
+ dynamic_cast< DataStructure* >( info->getDestination() );
+
+ looseMarshalCachedObject( wireFormat, data, dataOut );
+ looseMarshalString( info->getSelector(), dataOut );
+ looseMarshalString( info->getSubcriptionName(), dataOut );
+}
+
Propchange: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/SubscriptionInfoMarshaller.cpp
------------------------------------------------------------------------------
svn:eol-style = native
Added: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/SubscriptionInfoMarshaller.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/SubscriptionInfoMarshaller.h?view=auto&rev=452053
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/SubscriptionInfoMarshaller.h (added)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/SubscriptionInfoMarshaller.h Mon Oct 2 07:30:10 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_SUBSCRIPTIONINFOMARSHALLER_H_
+#define _ACTIVEMQ_CONNECTOR_OPENWIRE_MARSAHAL_V2_SUBSCRIPTIONINFOMARSHALLER_H_
+
+// Turn off warning message for ignored exception specification
+#ifdef _MSC_VER
+#pragma warning( disable : 4290 )
+#endif
+
+#include <activemq/connector/openwire/marshal/V2/BaseDataStreamMarshaller.h>
+
+#include <activemq/io/DataInputStream.h>
+#include <activemq/io/DataOutputStream.h>
+#include <activemq/io/IOException.h>
+#include <activemq/connector/openwire/commands/DataStructure.h>
+#include <activemq/connector/openwire/util/BooleanStream.h>
+
+namespace activemq{
+namespace connector{
+namespace openwire{
+namespace marshal{
+namespace v2{
+
+ /**
+ * Marshalling code for Open Wire Format for SubscriptionInfoMarshaller
+ *
+ * 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 SubscriptionInfoMarshaller : public BaseDataStreamMarshaller
+ {
+ public:
+
+ SubscriptionInfoMarshaller() {};
+ virtual ~SubscriptionInfoMarshaller() {};
+
+ /**
+ * 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_SUBSCRIPTIONINFOMARSHALLER_H_*/
+
Propchange: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/SubscriptionInfoMarshaller.h
------------------------------------------------------------------------------
svn:eol-style = native
Added: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/TransactionIdMarshaller.cpp
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/TransactionIdMarshaller.cpp?view=auto&rev=452053
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/TransactionIdMarshaller.cpp (added)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/TransactionIdMarshaller.cpp Mon Oct 2 07:30:10 2006
@@ -0,0 +1,69 @@
+/*
+ * 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 <activemq/connector/openwire/marshal/v2/TransactionIdMarshaller.h>
+
+#include <activemq/connector/openwire/commands/TransactionId.h>
+
+//
+// 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;
+
+///////////////////////////////////////////////////////////////////////////////
+void TransactionIdMarshaller::tightUnmarshal( OpenWireFormat* wireFormat, DataStructure* dataStructure, DataInputStream* dataIn, BooleanStream* bs ) {
+ BaseDataStreamMarshaller::tightUnmarshal( wireFormat, dataStructure, dataIn, bs );
+
+}
+
+///////////////////////////////////////////////////////////////////////////////
+int TransactionIdMarshaller::tightMarshal1( OpenWireFormat& wireFormat, DataStructure* dataStructure, BooleanStream& bs ) {
+
+ int rc = BaseDataStreamMarshaller::tightMarshal1( wireFormat, dataStructure, bs );
+
+ return rc + 0;
+}
+
+///////////////////////////////////////////////////////////////////////////////
+void TransactionIdMarshaller::tightMarshal2( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataOutputStream& dataOut, BooleanStream& bs ) {
+
+ BaseDataStreamMarshaller::tightMarshal2( wireFormat, dataStructure, dataOut, bs );
+
+}
+
+///////////////////////////////////////////////////////////////////////////////
+void TransactionIdMarshaller::looseUnmarshal( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataInputStream& dataIn ) {
+ BaseDataStreamMarshaller::looseUnmarshal( wireFormat, dataStructure, dataIn );
+}
+
+///////////////////////////////////////////////////////////////////////////////
+void TransactionIdMarshaller::looseMarshal( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataOutputStream& dataOut ) {
+ BaseDataStreamMarshaller::looseMarshal( wireFormat, dataStructure, dataOut );
+
+}
+
Propchange: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/TransactionIdMarshaller.cpp
------------------------------------------------------------------------------
svn:eol-style = native
Added: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/TransactionIdMarshaller.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/TransactionIdMarshaller.h?view=auto&rev=452053
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/TransactionIdMarshaller.h (added)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/TransactionIdMarshaller.h Mon Oct 2 07:30:10 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_TRANSACTIONIDMARSHALLER_H_
+#define _ACTIVEMQ_CONNECTOR_OPENWIRE_MARSAHAL_V2_TRANSACTIONIDMARSHALLER_H_
+
+// Turn off warning message for ignored exception specification
+#ifdef _MSC_VER
+#pragma warning( disable : 4290 )
+#endif
+
+#include <activemq/connector/openwire/marshal/V2/BaseDataStreamMarshaller.h>
+
+#include <activemq/io/DataInputStream.h>
+#include <activemq/io/DataOutputStream.h>
+#include <activemq/io/IOException.h>
+#include <activemq/connector/openwire/commands/DataStructure.h>
+#include <activemq/connector/openwire/util/BooleanStream.h>
+
+namespace activemq{
+namespace connector{
+namespace openwire{
+namespace marshal{
+namespace v2{
+
+ /**
+ * Marshalling code for Open Wire Format for TransactionIdMarshaller
+ *
+ * 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 TransactionIdMarshaller : public BaseDataStreamMarshaller
+ {
+ public:
+
+ TransactionIdMarshaller() {};
+ virtual ~TransactionIdMarshaller() {};
+
+ /**
+ * 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_TRANSACTIONIDMARSHALLER_H_*/
+
Propchange: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/TransactionIdMarshaller.h
------------------------------------------------------------------------------
svn:eol-style = native
Added: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/TransactionInfoMarshaller.cpp
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/TransactionInfoMarshaller.cpp?view=auto&rev=452053
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/TransactionInfoMarshaller.cpp (added)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/TransactionInfoMarshaller.cpp Mon Oct 2 07:30:10 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.
+ */
+
+#include <activemq/connector/openwire/marshal/v2/TransactionInfoMarshaller.h>
+
+#include <activemq/connector/openwire/commands/TransactionInfo.h>
+
+//
+// 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* TransactionInfoMarshaller::createObject() const {
+ return new TransactionInfo();
+}
+
+///////////////////////////////////////////////////////////////////////////////
+unsigned char TransactionInfoMarshaller::getDataStructureType() const {
+ return TransactionInfo::ID_TRANSACTIONINFO;
+}
+
+///////////////////////////////////////////////////////////////////////////////
+void TransactionInfoMarshaller::tightUnmarshal( OpenWireFormat* wireFormat, DataStructure* dataStructure, DataInputStream* dataIn, BooleanStream* bs ) {
+ BaseCommandMarshaller::tightUnmarshal( wireFormat, dataStructure, dataIn, bs );
+
+ TransactionInfo* info =
+ dynamic_cast<TransactionInfo*>( dataStructure );
+ info->setConnectionId( dynamic_cast< ConnectionId* >(
+ tightUnmarsalCachedObject( wireFormat, dataIn, bs ) );
+ info->setTransactionId( dynamic_cast< TransactionId* >(
+ tightUnmarsalCachedObject( wireFormat, dataIn, bs ) );
+ info->setType( dataIn->readByte() );
+}
+
+///////////////////////////////////////////////////////////////////////////////
+int TransactionInfoMarshaller::tightMarshal1( OpenWireFormat& wireFormat, DataStructure* dataStructure, BooleanStream& bs ) {
+
+ TransactionInfo* info =
+ dynamic_cast<TransactionInfo*>( dataStructure );
+
+ int rc = BaseCommandMarshaller::tightMarshal1( wireFormat, dataStructure, bs );
+ DataStructure* data =
+ dynamic_cast< DataStructure* >( info->getConnectionId() );
+
+ rc += tightMarshalCachedObject1( wireFormat, data, bs );
+ DataStructure* data =
+ dynamic_cast< DataStructure* >( info->getTransactionId() );
+
+ rc += tightMarshalCachedObject1( wireFormat, data, bs );
+
+ return rc + 1;
+}
+
+///////////////////////////////////////////////////////////////////////////////
+void TransactionInfoMarshaller::tightMarshal2( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataOutputStream& dataOut, BooleanStream& bs ) {
+
+ BaseCommandMarshaller::tightMarshal2( wireFormat, dataStructure, dataOut, bs );
+
+ TransactionInfo* info =
+ dynamic_cast<TransactionInfo*>( dataStructure );
+ DataStructure* data =
+ dynamic_cast< DataStructure* >( info->getConnectionId() );
+
+ tightMarshalCachedObject2( wireFormat, data, dataOut, bs );
+ DataStructure* data =
+ dynamic_cast< DataStructure* >( info->getTransactionId() );
+
+ tightMarshalCachedObject2( wireFormat, data, dataOut, bs );
+ dataOut->write( info->getType() );
+}
+
+///////////////////////////////////////////////////////////////////////////////
+void TransactionInfoMarshaller::looseUnmarshal( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataInputStream& dataIn ) {
+ BaseCommandMarshaller::looseUnmarshal( wireFormat, dataStructure, dataIn );
+ TransactionInfo* info =
+ dynamic_cast<TransactionInfo*>( dataStructure );
+ info->setConnectionId( dynamic_cast<ConnectionId* >(
+ looseUnmarshalCachedObject( wireFormat, dataIn ) ) );
+ info->setTransactionId( dynamic_cast<TransactionId* >(
+ looseUnmarshalCachedObject( wireFormat, dataIn ) ) );
+ info->setType( dataIn->readByte() );
+}
+
+///////////////////////////////////////////////////////////////////////////////
+void TransactionInfoMarshaller::looseMarshal( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataOutputStream& dataOut ) {
+ TransactionInfo* info =
+ dynamic_cast<TransactionInfo*>( dataStructure );
+ BaseCommandMarshaller::looseMarshal( wireFormat, dataStructure, dataOut );
+
+ DataStructure* data =
+ dynamic_cast< DataStructure* >( info->getConnectionId() );
+
+ looseMarshalCachedObject( wireFormat, data, dataOut );
+ DataStructure* data =
+ dynamic_cast< DataStructure* >( info->getTransactionId() );
+
+ looseMarshalCachedObject( wireFormat, data, dataOut );
+ dataOut->write( info->getType() );
+}
+
Propchange: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/TransactionInfoMarshaller.cpp
------------------------------------------------------------------------------
svn:eol-style = native
Added: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/TransactionInfoMarshaller.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/TransactionInfoMarshaller.h?view=auto&rev=452053
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/TransactionInfoMarshaller.h (added)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/TransactionInfoMarshaller.h Mon Oct 2 07:30:10 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_TRANSACTIONINFOMARSHALLER_H_
+#define _ACTIVEMQ_CONNECTOR_OPENWIRE_MARSAHAL_V2_TRANSACTIONINFOMARSHALLER_H_
+
+// Turn off warning message for ignored exception specification
+#ifdef _MSC_VER
+#pragma warning( disable : 4290 )
+#endif
+
+#include <activemq/connector/openwire/marshal/V2/BaseCommandMarshaller.h>
+
+#include <activemq/io/DataInputStream.h>
+#include <activemq/io/DataOutputStream.h>
+#include <activemq/io/IOException.h>
+#include <activemq/connector/openwire/commands/DataStructure.h>
+#include <activemq/connector/openwire/util/BooleanStream.h>
+
+namespace activemq{
+namespace connector{
+namespace openwire{
+namespace marshal{
+namespace v2{
+
+ /**
+ * Marshalling code for Open Wire Format for TransactionInfoMarshaller
+ *
+ * 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 TransactionInfoMarshaller : public BaseCommandMarshaller
+ {
+ public:
+
+ TransactionInfoMarshaller() {};
+ virtual ~TransactionInfoMarshaller() {};
+
+ /**
+ * 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_TRANSACTIONINFOMARSHALLER_H_*/
+
Propchange: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/TransactionInfoMarshaller.h
------------------------------------------------------------------------------
svn:eol-style = native
Added: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/WireFormatInfoMarshaller.cpp
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/WireFormatInfoMarshaller.cpp?view=auto&rev=452053
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/WireFormatInfoMarshaller.cpp (added)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/WireFormatInfoMarshaller.cpp Mon Oct 2 07:30:10 2006
@@ -0,0 +1,121 @@
+/*
+ * 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 <activemq/connector/openwire/marshal/v2/WireFormatInfoMarshaller.h>
+
+#include <activemq/connector/openwire/commands/WireFormatInfo.h>
+
+//
+// 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* WireFormatInfoMarshaller::createObject() const {
+ return new WireFormatInfo();
+}
+
+///////////////////////////////////////////////////////////////////////////////
+unsigned char WireFormatInfoMarshaller::getDataStructureType() const {
+ return WireFormatInfo::ID_WIREFORMATINFO;
+}
+
+///////////////////////////////////////////////////////////////////////////////
+void WireFormatInfoMarshaller::tightUnmarshal( OpenWireFormat* wireFormat, DataStructure* dataStructure, DataInputStream* dataIn, BooleanStream* bs ) {
+ BaseDataStreamMarshaller::tightUnmarshal( wireFormat, dataStructure, dataIn, bs );
+
+ WireFormatInfo* info =
+ dynamic_cast<WireFormatInfo*>( dataStructure );
+ info->beforeUnmarshall( wireFormat );
+
+ info->setMagic( tightUnmarshalConstByteArray( dataIn, bs, 8 ) );
+ info->setVersion( dataIn->readInt() );
+ info->setMarshalledProperties( tightUnmarshalByteArray( dataIn, bs ) );
+
+ info->afterUnmarshall( wireFormat );
+}
+
+///////////////////////////////////////////////////////////////////////////////
+int WireFormatInfoMarshaller::tightMarshal1( OpenWireFormat& wireFormat, DataStructure* dataStructure, BooleanStream& bs ) {
+
+ WireFormatInfo* info =
+ dynamic_cast<WireFormatInfo*>( dataStructure );
+
+ info->beforeMarshall( wireFormat );
+ int rc = BaseDataStreamMarshaller::tightMarshal1( wireFormat, dataStructure, bs );
+ bs->writeBoolean( info->getMarshalledProperties() != NULL );
+ rc += info->getMarshalledProperties()() == NULL ? 0 : info->getMarshalledProperties().Length + 4;
+
+ return rc + 12;
+}
+
+///////////////////////////////////////////////////////////////////////////////
+void WireFormatInfoMarshaller::tightMarshal2( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataOutputStream& dataOut, BooleanStream& bs ) {
+
+ BaseDataStreamMarshaller::tightMarshal2( wireFormat, dataStructure, dataOut, bs );
+
+ WireFormatInfo* info =
+ dynamic_cast<WireFormatInfo*>( dataStructure );
+ dataOut->write( info->getMagic(), 0, 8 );
+ dataOut->write( info->getVersion() );
+ if( bs->readBoolean() ) {
+ dataOut->write( info->getMarshalledProperties().Length );
+ dataOut->write( info->getMarshalledProperties() );
+ }
+ info->afterMarshall( wireFormat );
+}
+
+///////////////////////////////////////////////////////////////////////////////
+void WireFormatInfoMarshaller::looseUnmarshal( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataInputStream& dataIn ) {
+ BaseDataStreamMarshaller::looseUnmarshal( wireFormat, dataStructure, dataIn );
+ WireFormatInfo* info =
+ dynamic_cast<WireFormatInfo*>( dataStructure );
+ info->beforeUnmarshall( wireFormat );
+ info->setMagic( looseUnmarshalConstByteArray( dataIn, 8 ) );
+ info->setVersion( dataIn->readInt() );
+ info->setMarshalledProperties( looseUnmarshalByteArray( dataIn ) );
+ info->afterUnmarshall( wireFormat );
+}
+
+///////////////////////////////////////////////////////////////////////////////
+void WireFormatInfoMarshaller::looseMarshal( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataOutputStream& dataOut ) {
+ WireFormatInfo* info =
+ dynamic_cast<WireFormatInfo*>( dataStructure );
+ info->beforeMarshall( wireFormat );
+ BaseDataStreamMarshaller::looseMarshal( wireFormat, dataStructure, dataOut );
+
+ dataOut->write( info->getMagic(), 0, 8 );
+ dataOut->write( info->getVersion() );
+ dataOut->write( info->getMarshalledProperties() != NULL );
+ if( info->getMarshalledProperties() != NULL ) {
+ dataOut->write( info->getMarshalledProperties().Length );
+ dataOut->write( info->getMarshalledProperties() );
+ }
+ info->afterMarshall( wireFormat );
+}
+
Propchange: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/WireFormatInfoMarshaller.cpp
------------------------------------------------------------------------------
svn:eol-style = native
Added: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/WireFormatInfoMarshaller.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/WireFormatInfoMarshaller.h?view=auto&rev=452053
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/WireFormatInfoMarshaller.h (added)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/WireFormatInfoMarshaller.h Mon Oct 2 07:30:10 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_WIREFORMATINFOMARSHALLER_H_
+#define _ACTIVEMQ_CONNECTOR_OPENWIRE_MARSAHAL_V2_WIREFORMATINFOMARSHALLER_H_
+
+// Turn off warning message for ignored exception specification
+#ifdef _MSC_VER
+#pragma warning( disable : 4290 )
+#endif
+
+#include <activemq/connector/openwire/marshal/V2/BaseDataStreamMarshaller.h>
+
+#include <activemq/io/DataInputStream.h>
+#include <activemq/io/DataOutputStream.h>
+#include <activemq/io/IOException.h>
+#include <activemq/connector/openwire/commands/DataStructure.h>
+#include <activemq/connector/openwire/util/BooleanStream.h>
+
+namespace activemq{
+namespace connector{
+namespace openwire{
+namespace marshal{
+namespace v2{
+
+ /**
+ * Marshalling code for Open Wire Format for WireFormatInfoMarshaller
+ *
+ * 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 WireFormatInfoMarshaller : public BaseDataStreamMarshaller
+ {
+ public:
+
+ WireFormatInfoMarshaller() {};
+ virtual ~WireFormatInfoMarshaller() {};
+
+ /**
+ * 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_WIREFORMATINFOMARSHALLER_H_*/
+
Propchange: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/WireFormatInfoMarshaller.h
------------------------------------------------------------------------------
svn:eol-style = native
Added: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/XATransactionIdMarshaller.cpp
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/XATransactionIdMarshaller.cpp?view=auto&rev=452053
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/XATransactionIdMarshaller.cpp (added)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/XATransactionIdMarshaller.cpp Mon Oct 2 07:30:10 2006
@@ -0,0 +1,120 @@
+/*
+ * 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 <activemq/connector/openwire/marshal/v2/XATransactionIdMarshaller.h>
+
+#include <activemq/connector/openwire/commands/XATransactionId.h>
+
+//
+// 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* XATransactionIdMarshaller::createObject() const {
+ return new XATransactionId();
+}
+
+///////////////////////////////////////////////////////////////////////////////
+unsigned char XATransactionIdMarshaller::getDataStructureType() const {
+ return XATransactionId::ID_XATRANSACTIONID;
+}
+
+///////////////////////////////////////////////////////////////////////////////
+void XATransactionIdMarshaller::tightUnmarshal( OpenWireFormat* wireFormat, DataStructure* dataStructure, DataInputStream* dataIn, BooleanStream* bs ) {
+ TransactionIdMarshaller::tightUnmarshal( wireFormat, dataStructure, dataIn, bs );
+
+ XATransactionId* info =
+ dynamic_cast<XATransactionId*>( dataStructure );
+ info->setFormatId( dataIn->readInt() );
+ info->setGlobalTransactionId( tightUnmarshalByteArray( dataIn, bs ) );
+ info->setBranchQualifier( tightUnmarshalByteArray( dataIn, bs ) );
+}
+
+///////////////////////////////////////////////////////////////////////////////
+int XATransactionIdMarshaller::tightMarshal1( OpenWireFormat& wireFormat, DataStructure* dataStructure, BooleanStream& bs ) {
+
+ XATransactionId* info =
+ dynamic_cast<XATransactionId*>( dataStructure );
+
+ int rc = TransactionIdMarshaller::tightMarshal1( wireFormat, dataStructure, bs );
+ bs->writeBoolean( info->getGlobalTransactionId() != NULL );
+ rc += info->getGlobalTransactionId()() == NULL ? 0 : info->getGlobalTransactionId().Length + 4;
+ bs->writeBoolean( info->getBranchQualifier() != NULL );
+ rc += info->getBranchQualifier()() == NULL ? 0 : info->getBranchQualifier().Length + 4;
+
+ return rc + 4;
+}
+
+///////////////////////////////////////////////////////////////////////////////
+void XATransactionIdMarshaller::tightMarshal2( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataOutputStream& dataOut, BooleanStream& bs ) {
+
+ TransactionIdMarshaller::tightMarshal2( wireFormat, dataStructure, dataOut, bs );
+
+ XATransactionId* info =
+ dynamic_cast<XATransactionId*>( dataStructure );
+ dataOut->write( info->getFormatId() );
+ if( bs->readBoolean() ) {
+ dataOut->write( info->getGlobalTransactionId().Length );
+ dataOut->write( info->getGlobalTransactionId() );
+ }
+ if( bs->readBoolean() ) {
+ dataOut->write( info->getBranchQualifier().Length );
+ dataOut->write( info->getBranchQualifier() );
+ }
+}
+
+///////////////////////////////////////////////////////////////////////////////
+void XATransactionIdMarshaller::looseUnmarshal( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataInputStream& dataIn ) {
+ TransactionIdMarshaller::looseUnmarshal( wireFormat, dataStructure, dataIn );
+ XATransactionId* info =
+ dynamic_cast<XATransactionId*>( dataStructure );
+ info->setFormatId( dataIn->readInt() );
+ info->setGlobalTransactionId( looseUnmarshalByteArray( dataIn ) );
+ info->setBranchQualifier( looseUnmarshalByteArray( dataIn ) );
+}
+
+///////////////////////////////////////////////////////////////////////////////
+void XATransactionIdMarshaller::looseMarshal( OpenWireFormat& wireFormat, DataStructure* dataStructure, DataOutputStream& dataOut ) {
+ XATransactionId* info =
+ dynamic_cast<XATransactionId*>( dataStructure );
+ TransactionIdMarshaller::looseMarshal( wireFormat, dataStructure, dataOut );
+
+ dataOut->write( info->getFormatId() );
+ dataOut->write( info->getGlobalTransactionId() != NULL );
+ if( info->getGlobalTransactionId() != NULL ) {
+ dataOut->write( info->getGlobalTransactionId().Length );
+ dataOut->write( info->getGlobalTransactionId() );
+ }
+ dataOut->write( info->getBranchQualifier() != NULL );
+ if( info->getBranchQualifier() != NULL ) {
+ dataOut->write( info->getBranchQualifier().Length );
+ dataOut->write( info->getBranchQualifier() );
+ }
+}
+
Propchange: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/XATransactionIdMarshaller.cpp
------------------------------------------------------------------------------
svn:eol-style = native
Added: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/XATransactionIdMarshaller.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/XATransactionIdMarshaller.h?view=auto&rev=452053
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/XATransactionIdMarshaller.h (added)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/XATransactionIdMarshaller.h Mon Oct 2 07:30:10 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_XATRANSACTIONIDMARSHALLER_H_
+#define _ACTIVEMQ_CONNECTOR_OPENWIRE_MARSAHAL_V2_XATRANSACTIONIDMARSHALLER_H_
+
+// Turn off warning message for ignored exception specification
+#ifdef _MSC_VER
+#pragma warning( disable : 4290 )
+#endif
+
+#include <activemq/connector/openwire/marshal/V2/TransactionIdMarshaller.h>
+
+#include <activemq/io/DataInputStream.h>
+#include <activemq/io/DataOutputStream.h>
+#include <activemq/io/IOException.h>
+#include <activemq/connector/openwire/commands/DataStructure.h>
+#include <activemq/connector/openwire/util/BooleanStream.h>
+
+namespace activemq{
+namespace connector{
+namespace openwire{
+namespace marshal{
+namespace v2{
+
+ /**
+ * Marshalling code for Open Wire Format for XATransactionIdMarshaller
+ *
+ * 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 XATransactionIdMarshaller : public TransactionIdMarshaller
+ {
+ public:
+
+ XATransactionIdMarshaller() {};
+ virtual ~XATransactionIdMarshaller() {};
+
+ /**
+ * 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_XATRANSACTIONIDMARSHALLER_H_*/
+
Propchange: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/V2/XATransactionIdMarshaller.h
------------------------------------------------------------------------------
svn:eol-style = native
Added: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/utils/BooleanStream.cpp
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/utils/BooleanStream.cpp?view=auto&rev=452053
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/utils/BooleanStream.cpp (added)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/utils/BooleanStream.cpp Mon Oct 2 07:30:10 2006
@@ -0,0 +1,153 @@
+/**
+ * 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 <activemq/connector/openwire/utils/BooleanStream.h>
+
+using namespace std;
+using namespace activemq;
+using namespace activemq::io;
+using namespace activemq::connector;
+using namespace activemq::connector::openwire;
+using namespace activemq::connector::openwire::utils;
+
+///////////////////////////////////////////////////////////////////////////////
+BooleanStream::BooleanStream()
+{
+ this->arrayLimit = 0;
+ this->arrayPos = 0;
+ this->bytePos = 0;
+
+ // Reserve 1K
+ this->data.resize( 1000, 0 );
+}
+
+///////////////////////////////////////////////////////////////////////////////
+BooleanStream::~BooleanStream()
+{}
+
+///////////////////////////////////////////////////////////////////////////////
+bool BooleanStream::readBoolean() throw ( IOException ) {
+ //assert arrayPos <= arrayLimit;
+ unsigned char b = data[arrayPos];
+ bool rc = ( ( b >> bytePos ) & 0x01 ) != 0;
+ bytePos++;
+ if( bytePos >= 8 ) {
+ bytePos = 0;
+ arrayPos++;
+ }
+ return rc;
+}
+
+///////////////////////////////////////////////////////////////////////////////
+void BooleanStream::writeBoolean( bool value ) throw ( IOException ) {
+ if( bytePos == 0 ) {
+ arrayLimit++;
+
+ if( (size_t)arrayLimit >= data.capacity() ) {
+ // re-grow the array if necessary
+ data.resize( data.size() * 2 );
+ }
+ }
+
+ if( value ) {
+ data[arrayPos] |= ( 0x01 << bytePos );
+ }
+
+ bytePos++;
+
+ // Wrap around when we hit the next byte
+ if( bytePos >= 8 ) {
+ bytePos=0;
+ arrayPos++;
+ }
+}
+
+///////////////////////////////////////////////////////////////////////////////
+void BooleanStream::marshal( DataOutputStream* dataOut ) throw ( IOException ) {
+ if( arrayLimit < 64 ) {
+ dataOut->writeByte( arrayLimit );
+ } else if( arrayLimit < 256 ) { // max value of unsigned char
+ dataOut->writeByte( 0xC0 );
+ dataOut->writeByte( arrayLimit );
+ } else {
+ dataOut->writeByte( 0x80 );
+ dataOut->writeShort( arrayLimit );
+ }
+
+ // Dump the payload
+ dataOut->write( &data[0], arrayLimit );
+ clear();
+}
+
+///////////////////////////////////////////////////////////////////////////////
+void BooleanStream::marshal( std::vector< unsigned char >& dataOut ) {
+ if( arrayLimit < 64 ) {
+ dataOut.push_back( ( unsigned char ) arrayLimit );
+ } else if( arrayLimit < 256 ) { // max value of unsigned byte
+ dataOut.push_back( ( unsigned char ) 0xC0 );
+ dataOut.push_back( ( unsigned char ) arrayLimit );
+ } else {
+ dataOut.push_back( ( unsigned char ) 0x80 );
+ dataOut.push_back( arrayLimit >> 8 ); // High Byte
+ dataOut.push_back( arrayLimit & 0xFF ); // Low Byte
+ }
+
+ // Insert all data from data into the passed buffer
+ dataOut.insert( dataOut.end(), &data[0], &data[arrayLimit] );
+}
+
+///////////////////////////////////////////////////////////////////////////////
+void BooleanStream::unmarshal( DataInputStream* dataIn ) throw ( IOException ) {
+
+ arrayLimit = (short)( dataIn->readByte() & 0xFF );
+
+ if ( arrayLimit == 0xC0 ) {
+ arrayLimit = (short)( dataIn->readByte() & 0xFF );
+ } else if( arrayLimit == 0x80 ) {
+ arrayLimit = dataIn->readShort();
+ }
+
+ // Reserve space all at once if needed.
+ if( data.capacity() < (size_t)arrayLimit ) {
+ data.reserve( arrayLimit );
+ }
+
+ // Make sure we can accomodate all the data.
+ data.resize( arrayLimit );
+
+ // Make sure we get all the data we are expecting
+ dataIn->readFully( &data[0], 0, arrayLimit );
+
+ clear();
+}
+
+///////////////////////////////////////////////////////////////////////////////
+void BooleanStream::clear() {
+ arrayPos = 0;
+ bytePos = 0;
+}
+
+///////////////////////////////////////////////////////////////////////////////
+int BooleanStream::marshalledSize() {
+ if( arrayLimit < 64 ) {
+ return 1 + arrayLimit;
+ } else if( arrayLimit < 256 ) {
+ return 2 + arrayLimit;
+ } else {
+ return 3 + arrayLimit;
+ }
+}
Propchange: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/utils/BooleanStream.cpp
------------------------------------------------------------------------------
svn:eol-style = native
Added: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/utils/BooleanStream.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/utils/BooleanStream.h?view=auto&rev=452053
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/utils/BooleanStream.h (added)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/utils/BooleanStream.h Mon Oct 2 07:30:10 2006
@@ -0,0 +1,102 @@
+/**
+ * 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_UTILS_BOOLEANSTREAM_H_
+#define _ACTIVEMQ_CONNECTOR_OPENWIRE_UTILS_BOOLEANSTREAM_H_
+
+#include <activemq/io/DataInputStream.h>
+#include <activemq/io/DataOutputStream.h>
+
+namespace activemq{
+namespace connector{
+namespace openwire{
+namespace utils{
+
+ /**
+ * class to manage the writing and reading of boolean data streams
+ * to and from a data source such as a DataInputStream or
+ * DataOutputStream. The booleans are stored as single bits in the
+ * stream, with the stream size pre-pended to the stream when the
+ * data is marshalled.
+ */
+ class BooleanStream
+ {
+ public:
+
+ BooleanStream();
+ virtual ~BooleanStream();
+
+ /**
+ * Read a boolean data element from the internal data buffer
+ * @returns boolean from the stream
+ */
+ bool readBoolean() throw ( io::IOException );
+
+ /**
+ * Writes a Boolean value to the internal data buffer
+ * @param value - boolean data to write.
+ */
+ void writeBoolean( bool value ) throw ( io::IOException );
+
+ /**
+ * Marshal the data to a DataOutputStream
+ * @param dataOut - Stream to write the data to.
+ */
+ void marshal( io::DataOutputStream* dataOut ) throw ( io::IOException );
+
+ /**
+ * Marshal the data to a STL vector of unsigned chars
+ * @param dataOut - reference to a vector to write the data to.
+ */
+ void marshal( std::vector< unsigned char >& dataOut );
+
+ /**
+ * Unmarshal a Boolean data stream from the Input Stream
+ * @param dataIn - Input Stream to read data from.
+ */
+ void unmarshal( io::DataInputStream* dataIn ) throw ( io::IOException );
+
+ /**
+ * Clears to old position markers, data starts at the beginning
+ */
+ void clear();
+
+ /**
+ * Calc the size that data is marshalled to
+ * @returns int size of marshalled data.
+ */
+ int marshalledSize();
+
+ private:
+
+ // Internal Buffer of data
+ std::vector<unsigned char> data;
+
+ // Limit on buffer size
+ short arrayLimit;
+
+ // Byte we are on from the buffer
+ short arrayPos;
+
+ // Bit we are on in the byte we are on from the buffer
+ unsigned char bytePos;
+
+ };
+
+}}}}
+
+#endif /*_ACTIVEMQ_CONNECTOR_OPENWIRE_UTILS_BOOLEANSTREAM_H_*/
Propchange: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/utils/BooleanStream.h
------------------------------------------------------------------------------
svn:eol-style = native