activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jstrac...@apache.org
Subject svn commit: r379827 [2/5] - in /incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client: Commands/ Core/ IO/
Date Wed, 22 Feb 2006 17:45:20 GMT
Modified: incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/ProducerInfo.cs
URL: http://svn.apache.org/viewcvs/incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/ProducerInfo.cs?rev=379827&r1=379826&r2=379827&view=diff
==============================================================================
--- incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/ProducerInfo.cs (original)
+++ incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/ProducerInfo.cs Wed Feb 22 09:45:12 2006
@@ -1,11 +1,19 @@
-//
-// Marshalling code for Open Wire Format for ProducerInfo
-//
-//
-// NOTE!: This file is autogenerated - do not modify!
-//        if you need to make a change, please see the Groovy scripts in the
-//        activemq-openwire module
-//
+/*
+* Copyright 2006 The Apache Software Foundation or its licensors, as
+* applicable.
+*
+* Licensed 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.
+*/
 
 using System;
 using System.Collections;
@@ -15,22 +23,29 @@
 
 namespace OpenWire.Client.Commands
 {
+    //
+    //  Marshalling code for Open Wire Format for ProducerInfo
+    //
+    //
+    //  NOTE!: This file is autogenerated - do not modify!
+    //         if you need to make a change, please see the Groovy scripts in the
+    //         activemq-core module
+    //
     public class ProducerInfo : BaseCommand
     {
-    			public const byte ID_ProducerInfo = 6;
+        public const byte ID_ProducerInfo = 6;
     			
         ProducerId producerId;
         ActiveMQDestination destination;
         BrokerId[] brokerPath;
 
 
-
         // TODO generate Equals method
         // TODO generate GetHashCode method
         // TODO generate ToString method
 
 
-        public override byte GetCommandType() {
+        public override byte GetDataStructureType() {
             return ID_ProducerInfo;
         }
 

Modified: incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/RemoveInfo.cs
URL: http://svn.apache.org/viewcvs/incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/RemoveInfo.cs?rev=379827&r1=379826&r2=379827&view=diff
==============================================================================
--- incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/RemoveInfo.cs (original)
+++ incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/RemoveInfo.cs Wed Feb 22 09:45:12 2006
@@ -1,11 +1,19 @@
-//
-// Marshalling code for Open Wire Format for RemoveInfo
-//
-//
-// NOTE!: This file is autogenerated - do not modify!
-//        if you need to make a change, please see the Groovy scripts in the
-//        activemq-openwire module
-//
+/*
+* Copyright 2006 The Apache Software Foundation or its licensors, as
+* applicable.
+*
+* Licensed 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.
+*/
 
 using System;
 using System.Collections;
@@ -15,20 +23,27 @@
 
 namespace OpenWire.Client.Commands
 {
+    //
+    //  Marshalling code for Open Wire Format for RemoveInfo
+    //
+    //
+    //  NOTE!: This file is autogenerated - do not modify!
+    //         if you need to make a change, please see the Groovy scripts in the
+    //         activemq-core module
+    //
     public class RemoveInfo : BaseCommand
     {
-    			public const byte ID_RemoveInfo = 12;
+        public const byte ID_RemoveInfo = 12;
     			
         DataStructure objectId;
 
 
-
         // TODO generate Equals method
         // TODO generate GetHashCode method
         // TODO generate ToString method
 
 
-        public override byte GetCommandType() {
+        public override byte GetDataStructureType() {
             return ID_RemoveInfo;
         }
 

Modified: incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/RemoveSubscriptionInfo.cs
URL: http://svn.apache.org/viewcvs/incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/RemoveSubscriptionInfo.cs?rev=379827&r1=379826&r2=379827&view=diff
==============================================================================
--- incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/RemoveSubscriptionInfo.cs (original)
+++ incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/RemoveSubscriptionInfo.cs Wed Feb 22 09:45:12 2006
@@ -1,11 +1,19 @@
-//
-// Marshalling code for Open Wire Format for RemoveSubscriptionInfo
-//
-//
-// NOTE!: This file is autogenerated - do not modify!
-//        if you need to make a change, please see the Groovy scripts in the
-//        activemq-openwire module
-//
+/*
+* Copyright 2006 The Apache Software Foundation or its licensors, as
+* applicable.
+*
+* Licensed 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.
+*/
 
 using System;
 using System.Collections;
@@ -15,22 +23,29 @@
 
 namespace OpenWire.Client.Commands
 {
+    //
+    //  Marshalling code for Open Wire Format for RemoveSubscriptionInfo
+    //
+    //
+    //  NOTE!: This file is autogenerated - do not modify!
+    //         if you need to make a change, please see the Groovy scripts in the
+    //         activemq-core module
+    //
     public class RemoveSubscriptionInfo : BaseCommand
     {
-    			public const byte ID_RemoveSubscriptionInfo = 0;
+        public const byte ID_RemoveSubscriptionInfo = 0;
     			
         ConnectionId connectionId;
         string subcriptionName;
         string clientId;
 
 
-
         // TODO generate Equals method
         // TODO generate GetHashCode method
         // TODO generate ToString method
 
 
-        public override byte GetCommandType() {
+        public override byte GetDataStructureType() {
             return ID_RemoveSubscriptionInfo;
         }
 

Modified: incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/Response.cs
URL: http://svn.apache.org/viewcvs/incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/Response.cs?rev=379827&r1=379826&r2=379827&view=diff
==============================================================================
--- incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/Response.cs (original)
+++ incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/Response.cs Wed Feb 22 09:45:12 2006
@@ -1,11 +1,19 @@
-//
-// Marshalling code for Open Wire Format for Response
-//
-//
-// NOTE!: This file is autogenerated - do not modify!
-//        if you need to make a change, please see the Groovy scripts in the
-//        activemq-openwire module
-//
+/*
+* Copyright 2006 The Apache Software Foundation or its licensors, as
+* applicable.
+*
+* Licensed 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.
+*/
 
 using System;
 using System.Collections;
@@ -15,20 +23,27 @@
 
 namespace OpenWire.Client.Commands
 {
+    //
+    //  Marshalling code for Open Wire Format for Response
+    //
+    //
+    //  NOTE!: This file is autogenerated - do not modify!
+    //         if you need to make a change, please see the Groovy scripts in the
+    //         activemq-core module
+    //
     public class Response : BaseCommand
     {
-    			public const byte ID_Response = 30;
+        public const byte ID_Response = 30;
     			
         short correlationId;
 
 
-
         // TODO generate Equals method
         // TODO generate GetHashCode method
         // TODO generate ToString method
 
 
-        public override byte GetCommandType() {
+        public override byte GetDataStructureType() {
             return ID_Response;
         }
 

Modified: incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/SessionId.cs
URL: http://svn.apache.org/viewcvs/incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/SessionId.cs?rev=379827&r1=379826&r2=379827&view=diff
==============================================================================
--- incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/SessionId.cs (original)
+++ incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/SessionId.cs Wed Feb 22 09:45:12 2006
@@ -1,11 +1,19 @@
-//
-// Marshalling code for Open Wire Format for SessionId
-//
-//
-// NOTE!: This file is autogenerated - do not modify!
-//        if you need to make a change, please see the Groovy scripts in the
-//        activemq-openwire module
-//
+/*
+* Copyright 2006 The Apache Software Foundation or its licensors, as
+* applicable.
+*
+* Licensed 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.
+*/
 
 using System;
 using System.Collections;
@@ -15,21 +23,28 @@
 
 namespace OpenWire.Client.Commands
 {
+    //
+    //  Marshalling code for Open Wire Format for SessionId
+    //
+    //
+    //  NOTE!: This file is autogenerated - do not modify!
+    //         if you need to make a change, please see the Groovy scripts in the
+    //         activemq-core module
+    //
     public class SessionId : AbstractCommand
     {
-    			public const byte ID_SessionId = 121;
+        public const byte ID_SessionId = 121;
     			
         string connectionId;
         long value;
 
 
-
         // TODO generate Equals method
         // TODO generate GetHashCode method
         // TODO generate ToString method
 
 
-        public override byte GetCommandType() {
+        public override byte GetDataStructureType() {
             return ID_SessionId;
         }
 

Modified: incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/SessionInfo.cs
URL: http://svn.apache.org/viewcvs/incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/SessionInfo.cs?rev=379827&r1=379826&r2=379827&view=diff
==============================================================================
--- incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/SessionInfo.cs (original)
+++ incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/SessionInfo.cs Wed Feb 22 09:45:12 2006
@@ -1,11 +1,19 @@
-//
-// Marshalling code for Open Wire Format for SessionInfo
-//
-//
-// NOTE!: This file is autogenerated - do not modify!
-//        if you need to make a change, please see the Groovy scripts in the
-//        activemq-openwire module
-//
+/*
+* Copyright 2006 The Apache Software Foundation or its licensors, as
+* applicable.
+*
+* Licensed 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.
+*/
 
 using System;
 using System.Collections;
@@ -15,20 +23,27 @@
 
 namespace OpenWire.Client.Commands
 {
+    //
+    //  Marshalling code for Open Wire Format for SessionInfo
+    //
+    //
+    //  NOTE!: This file is autogenerated - do not modify!
+    //         if you need to make a change, please see the Groovy scripts in the
+    //         activemq-core module
+    //
     public class SessionInfo : BaseCommand
     {
-    			public const byte ID_SessionInfo = 4;
+        public const byte ID_SessionInfo = 4;
     			
         SessionId sessionId;
 
 
-
         // TODO generate Equals method
         // TODO generate GetHashCode method
         // TODO generate ToString method
 
 
-        public override byte GetCommandType() {
+        public override byte GetDataStructureType() {
             return ID_SessionInfo;
         }
 

Modified: incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/ShutdownInfo.cs
URL: http://svn.apache.org/viewcvs/incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/ShutdownInfo.cs?rev=379827&r1=379826&r2=379827&view=diff
==============================================================================
--- incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/ShutdownInfo.cs (original)
+++ incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/ShutdownInfo.cs Wed Feb 22 09:45:12 2006
@@ -1,11 +1,19 @@
-//
-// Marshalling code for Open Wire Format for ShutdownInfo
-//
-//
-// NOTE!: This file is autogenerated - do not modify!
-//        if you need to make a change, please see the Groovy scripts in the
-//        activemq-openwire module
-//
+/*
+* Copyright 2006 The Apache Software Foundation or its licensors, as
+* applicable.
+*
+* Licensed 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.
+*/
 
 using System;
 using System.Collections;
@@ -15,19 +23,26 @@
 
 namespace OpenWire.Client.Commands
 {
+    //
+    //  Marshalling code for Open Wire Format for ShutdownInfo
+    //
+    //
+    //  NOTE!: This file is autogenerated - do not modify!
+    //         if you need to make a change, please see the Groovy scripts in the
+    //         activemq-core module
+    //
     public class ShutdownInfo : BaseCommand
     {
-    			public const byte ID_ShutdownInfo = 11;
+        public const byte ID_ShutdownInfo = 11;
     			
 
 
-
         // TODO generate Equals method
         // TODO generate GetHashCode method
         // TODO generate ToString method
 
 
-        public override byte GetCommandType() {
+        public override byte GetDataStructureType() {
             return ID_ShutdownInfo;
         }
 

Modified: incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/SubscriptionInfo.cs
URL: http://svn.apache.org/viewcvs/incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/SubscriptionInfo.cs?rev=379827&r1=379826&r2=379827&view=diff
==============================================================================
--- incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/SubscriptionInfo.cs (original)
+++ incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/SubscriptionInfo.cs Wed Feb 22 09:45:12 2006
@@ -1,11 +1,19 @@
-//
-// Marshalling code for Open Wire Format for SubscriptionInfo
-//
-//
-// NOTE!: This file is autogenerated - do not modify!
-//        if you need to make a change, please see the Groovy scripts in the
-//        activemq-openwire module
-//
+/*
+* Copyright 2006 The Apache Software Foundation or its licensors, as
+* applicable.
+*
+* Licensed 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.
+*/
 
 using System;
 using System.Collections;
@@ -15,9 +23,17 @@
 
 namespace OpenWire.Client.Commands
 {
+    //
+    //  Marshalling code for Open Wire Format for SubscriptionInfo
+    //
+    //
+    //  NOTE!: This file is autogenerated - do not modify!
+    //         if you need to make a change, please see the Groovy scripts in the
+    //         activemq-core module
+    //
     public class SubscriptionInfo : AbstractCommand
     {
-    			public const byte ID_SubscriptionInfo = 55;
+        public const byte ID_SubscriptionInfo = 55;
     			
         string clientId;
         ActiveMQDestination destination;
@@ -25,13 +41,12 @@
         string subcriptionName;
 
 
-
         // TODO generate Equals method
         // TODO generate GetHashCode method
         // TODO generate ToString method
 
 
-        public override byte GetCommandType() {
+        public override byte GetDataStructureType() {
             return ID_SubscriptionInfo;
         }
 

Modified: incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/TransactionId.cs
URL: http://svn.apache.org/viewcvs/incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/TransactionId.cs?rev=379827&r1=379826&r2=379827&view=diff
==============================================================================
--- incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/TransactionId.cs (original)
+++ incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/TransactionId.cs Wed Feb 22 09:45:12 2006
@@ -1,11 +1,19 @@
-//
-// Marshalling code for Open Wire Format for TransactionId
-//
-//
-// NOTE!: This file is autogenerated - do not modify!
-//        if you need to make a change, please see the Groovy scripts in the
-//        activemq-openwire module
-//
+/*
+* Copyright 2006 The Apache Software Foundation or its licensors, as
+* applicable.
+*
+* Licensed 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.
+*/
 
 using System;
 using System.Collections;
@@ -15,19 +23,26 @@
 
 namespace OpenWire.Client.Commands
 {
+    //
+    //  Marshalling code for Open Wire Format for TransactionId
+    //
+    //
+    //  NOTE!: This file is autogenerated - do not modify!
+    //         if you need to make a change, please see the Groovy scripts in the
+    //         activemq-core module
+    //
     public class TransactionId : AbstractCommand
     {
-    			public const byte ID_TransactionId = 0;
+        public const byte ID_TransactionId = 0;
     			
 
 
-
         // TODO generate Equals method
         // TODO generate GetHashCode method
         // TODO generate ToString method
 
 
-        public override byte GetCommandType() {
+        public override byte GetDataStructureType() {
             return ID_TransactionId;
         }
 

Modified: incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/TransactionInfo.cs
URL: http://svn.apache.org/viewcvs/incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/TransactionInfo.cs?rev=379827&r1=379826&r2=379827&view=diff
==============================================================================
--- incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/TransactionInfo.cs (original)
+++ incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/TransactionInfo.cs Wed Feb 22 09:45:12 2006
@@ -1,11 +1,19 @@
-//
-// Marshalling code for Open Wire Format for TransactionInfo
-//
-//
-// NOTE!: This file is autogenerated - do not modify!
-//        if you need to make a change, please see the Groovy scripts in the
-//        activemq-openwire module
-//
+/*
+* Copyright 2006 The Apache Software Foundation or its licensors, as
+* applicable.
+*
+* Licensed 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.
+*/
 
 using System;
 using System.Collections;
@@ -15,22 +23,29 @@
 
 namespace OpenWire.Client.Commands
 {
+    //
+    //  Marshalling code for Open Wire Format for TransactionInfo
+    //
+    //
+    //  NOTE!: This file is autogenerated - do not modify!
+    //         if you need to make a change, please see the Groovy scripts in the
+    //         activemq-core module
+    //
     public class TransactionInfo : BaseCommand
     {
-    			public const byte ID_TransactionInfo = 7;
+        public const byte ID_TransactionInfo = 7;
     			
         ConnectionId connectionId;
         TransactionId transactionId;
         byte type;
 
 
-
         // TODO generate Equals method
         // TODO generate GetHashCode method
         // TODO generate ToString method
 
 
-        public override byte GetCommandType() {
+        public override byte GetDataStructureType() {
             return ID_TransactionInfo;
         }
 

Modified: incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/WireFormatInfo.cs
URL: http://svn.apache.org/viewcvs/incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/WireFormatInfo.cs?rev=379827&r1=379826&r2=379827&view=diff
==============================================================================
--- incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/WireFormatInfo.cs (original)
+++ incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/WireFormatInfo.cs Wed Feb 22 09:45:12 2006
@@ -1,11 +1,19 @@
-//
-// Marshalling code for Open Wire Format for WireFormatInfo
-//
-//
-// NOTE!: This file is autogenerated - do not modify!
-//        if you need to make a change, please see the Groovy scripts in the
-//        activemq-openwire module
-//
+/*
+* Copyright 2006 The Apache Software Foundation or its licensors, as
+* applicable.
+*
+* Licensed 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.
+*/
 
 using System;
 using System.Collections;
@@ -15,22 +23,29 @@
 
 namespace OpenWire.Client.Commands
 {
+    //
+    //  Marshalling code for Open Wire Format for WireFormatInfo
+    //
+    //
+    //  NOTE!: This file is autogenerated - do not modify!
+    //         if you need to make a change, please see the Groovy scripts in the
+    //         activemq-core module
+    //
     public class WireFormatInfo : AbstractCommand
     {
-    			public const byte ID_WireFormatInfo = 1;
+        public const byte ID_WireFormatInfo = 1;
     			
         byte[] magic;
         int version;
         int options;
 
 
-
         // TODO generate Equals method
         // TODO generate GetHashCode method
         // TODO generate ToString method
 
 
-        public override byte GetCommandType() {
+        public override byte GetDataStructureType() {
             return ID_WireFormatInfo;
         }
 

Modified: incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/XATransactionId.cs
URL: http://svn.apache.org/viewcvs/incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/XATransactionId.cs?rev=379827&r1=379826&r2=379827&view=diff
==============================================================================
--- incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/XATransactionId.cs (original)
+++ incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Commands/XATransactionId.cs Wed Feb 22 09:45:12 2006
@@ -1,11 +1,19 @@
-//
-// Marshalling code for Open Wire Format for XATransactionId
-//
-//
-// NOTE!: This file is autogenerated - do not modify!
-//        if you need to make a change, please see the Groovy scripts in the
-//        activemq-openwire module
-//
+/*
+* Copyright 2006 The Apache Software Foundation or its licensors, as
+* applicable.
+*
+* Licensed 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.
+*/
 
 using System;
 using System.Collections;
@@ -15,22 +23,29 @@
 
 namespace OpenWire.Client.Commands
 {
+    //
+    //  Marshalling code for Open Wire Format for XATransactionId
+    //
+    //
+    //  NOTE!: This file is autogenerated - do not modify!
+    //         if you need to make a change, please see the Groovy scripts in the
+    //         activemq-core module
+    //
     public class XATransactionId : TransactionId
     {
-    			public const byte ID_XATransactionId = 112;
+        public const byte ID_XATransactionId = 112;
     			
         int formatId;
         byte[] globalTransactionId;
         byte[] branchQualifier;
 
 
-
         // TODO generate Equals method
         // TODO generate GetHashCode method
         // TODO generate ToString method
 
 
-        public override byte GetCommandType() {
+        public override byte GetDataStructureType() {
             return ID_XATransactionId;
         }
 

Modified: incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/AbstractCommand.cs
URL: http://svn.apache.org/viewcvs/incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/AbstractCommand.cs?rev=379827&r1=379826&r2=379827&view=diff
==============================================================================
--- incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/AbstractCommand.cs (original)
+++ incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/AbstractCommand.cs Wed Feb 22 09:45:12 2006
@@ -12,11 +12,15 @@
                 protected AbstractCommand() {
                 }
 
-                public virtual byte GetCommandType() {
+                public virtual byte GetDataStructureType() {
                         return 0; 
-                }
-
-                public static String GetCommandTypeAsString(int type) {
+                }             
+                
+                public virtual bool IsMarshallAware() {
+                        return false; 
+                }             
+                
+                public static String GetDataStructureTypeAsString(int type) {
                         String packetTypeStr = "";
                         switch (type) {
                                 case ActiveMQMessage.ID_ActiveMQMessage :

Added: incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/BooleanStream.cs
URL: http://svn.apache.org/viewcvs/incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/BooleanStream.cs?rev=379827&view=auto
==============================================================================
--- incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/BooleanStream.cs (added)
+++ incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/BooleanStream.cs Wed Feb 22 09:45:12 2006
@@ -0,0 +1,93 @@
+using System;
+using System.IO;
+
+using OpenWire.Client.Commands;
+using OpenWire.Client.Core;
+using OpenWire.Client.IO;
+
+namespace OpenWire.Client.Core {
+        /// <summary>
+        /// Represents a stream of boolean flags
+        /// </summary>
+        public class BooleanStream {
+                byte[] data = new byte[48];
+                short arrayLimit;
+                short arrayPos;
+                byte bytePos;
+
+                public bool ReadBoolean() {
+                        byte b = data[arrayPos];
+                        bool rc = ((b >> bytePos) & 0x01) != 0;
+                        bytePos++;
+                        if (bytePos >= 8) {
+                                bytePos = 0;
+                                arrayPos++;
+                        }
+                        return rc;
+                }
+
+                public void WriteBoolean(bool value) {
+                        if (bytePos == 0) {
+                                arrayLimit++;
+                                if (arrayLimit >= data.Length) {
+                                        // re-grow the array.
+                                        byte[] d = new byte[data.Length * 2];
+                                        for (int i = 0; i < data.Length; i++) {
+                                                d[i] = data[i];
+                                        }
+                                        data = d;
+                                }
+                        }
+                        if (value) {
+                                data[arrayPos] |= (byte) (0x01 << bytePos);
+                        }
+                        bytePos++;
+                        if (bytePos >= 8) {
+                                bytePos = 0;
+                                arrayPos++;
+                        }
+                }
+
+                public void Marshal(BinaryWriter dataOut) {
+                        if (arrayLimit < 64) {
+                                dataOut.Write((byte) arrayLimit);
+                        } else if (arrayLimit < 256) { // max value of unsigned byte
+                                dataOut.Write((byte) 0xC0);
+                                dataOut.Write((byte) arrayLimit);
+                        } else {
+                                dataOut.Write((byte) 0xE0);
+                                dataOut.Write((short) arrayLimit);
+                        }
+
+                        dataOut.Write(data, 0, arrayLimit);
+                        Clear();
+                }
+
+                public void Unmarshal(BinaryReader dataIn) {
+                        arrayLimit = dataIn.ReadByte();
+                        if ((arrayLimit & 0xE0) != 0) {
+                                arrayLimit = dataIn.ReadInt16();
+                        } else if ((arrayLimit & 0xC0) != 0) {
+                                arrayLimit = (short) (dataIn.ReadByte() & 0xFF);
+                        }
+                        if (data.Length < arrayLimit) {
+                                data = new byte[arrayLimit];
+                        }
+                        dataIn.Read(data, 0, arrayLimit);
+                        Clear();
+                }
+
+                public void Clear() {
+                        arrayPos = 0;
+                        bytePos = 0;
+                }
+
+                public int MarshalledSize() {
+                        if (arrayLimit < 64) {
+                                return 1 + arrayLimit;
+                        } else {
+                                return 2 + arrayLimit;
+                        }
+                }
+        }
+}

Propchange: incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/BooleanStream.cs
------------------------------------------------------------------------------
    svn:executable = *

Modified: incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/BrokerError.cs
URL: http://svn.apache.org/viewcvs/incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/BrokerError.cs?rev=379827&r1=379826&r2=379827&view=diff
==============================================================================
--- incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/BrokerError.cs (original)
+++ incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/BrokerError.cs Wed Feb 22 09:45:12 2006
@@ -6,9 +6,15 @@
         /// Represents an exception on the broker
         /// </summary>
         public class BrokerError : AbstractCommand {
+                private string message;
                 private string exceptionClass;
                 private string stackTrace;
 
+                public string Message {
+                        get { return message; }
+                        set { message = value; } 
+                } 
+                
                 public string ExceptionClass {
                         get { return exceptionClass; }
                         set { exceptionClass = value; } 

Added: incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/DataStreamMarshaller.cs
URL: http://svn.apache.org/viewcvs/incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/DataStreamMarshaller.cs?rev=379827&view=auto
==============================================================================
--- incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/DataStreamMarshaller.cs (added)
+++ incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/DataStreamMarshaller.cs Wed Feb 22 09:45:12 2006
@@ -0,0 +1,401 @@
+using System;
+using System.IO;
+
+using OpenWire.Client.Commands;
+using OpenWire.Client.Core;
+using OpenWire.Client.IO;
+
+namespace OpenWire.Client.Core {
+        /// <summary>
+        /// A base class with useful implementation inheritence methods
+        /// for creating marshallers of the OpenWire protocol
+        /// </summary>
+        public abstract class DataStreamMarshaller {
+
+                public abstract DataStructure CreateObject();
+                public abstract byte GetDataStructureType();
+
+                public virtual int Marshal1(OpenWireFormat wireFormat, Object o, BooleanStream bs) {
+                        return 0;
+                }
+                public virtual void Marshal2(
+                        OpenWireFormat wireFormat,
+                        Object o,
+                        BinaryWriter dataOut,
+                        BooleanStream bs) {
+                }
+
+                public virtual void Unmarshal(
+                        OpenWireFormat wireFormat,
+                        Object o,
+                        BinaryReader dataIn,
+                        BooleanStream bs) {
+                }
+
+                public virtual int Marshal1Long(OpenWireFormat wireFormat, long o, BooleanStream bs) {
+                        if (o == 0L) {
+                                bs.WriteBoolean(false);
+                                bs.WriteBoolean(false);
+                                return 0;
+                        } else {
+                                ulong ul = (ulong) o;
+                                if ((ul & 0xFFFFFFFFFFFF0000ul) == 0L) {
+                                        bs.WriteBoolean(false);
+                                        bs.WriteBoolean(true);
+                                        return 2;
+                                } else if ((ul & 0xFFFFFFFF00000000ul) == 0L) {
+                                        bs.WriteBoolean(true);
+                                        bs.WriteBoolean(false);
+                                        return 4;
+                                } else {
+                                        bs.WriteBoolean(true);
+                                        bs.WriteBoolean(true);
+                                        return 8;
+                                }
+                        }
+                }
+
+                public virtual void Marshal2Long(
+                        OpenWireFormat wireFormat,
+                        long o,
+                        BinaryWriter dataOut,
+                        BooleanStream bs) {
+                        if (bs.ReadBoolean()) {
+                                if (bs.ReadBoolean()) {
+                                        dataOut.Write(o);
+                                } else {
+                                        dataOut.Write((int) o);
+                                }
+                        } else {
+                                if (bs.ReadBoolean()) {
+                                        dataOut.Write((short) o);
+                                }
+                        }
+                }
+                public virtual long UnmarshalLong(OpenWireFormat wireFormat, BinaryReader dataIn, BooleanStream bs) {
+                        if (bs.ReadBoolean()) {
+                                if (bs.ReadBoolean()) {
+                                        return dataIn.ReadInt64();
+                                } else {
+                                        return dataIn.ReadInt32();
+                                }
+                        } else {
+                                if (bs.ReadBoolean()) {
+                                        return dataIn.ReadInt16();
+                                } else {
+                                        return 0;
+                                }
+                        }
+                }
+
+                protected virtual DataStructure UnmarshalNestedObject(
+                        OpenWireFormat wireFormat,
+                        BinaryReader dataIn,
+                        BooleanStream bs) {
+                        return wireFormat.UnmarshalNestedObject(dataIn, bs);
+                }
+
+                protected virtual int Marshal1NestedObject(
+                        OpenWireFormat wireFormat,
+                        DataStructure o,
+                        BooleanStream bs) {
+                        return wireFormat.Marshal1NestedObject(o, bs);
+                }
+
+                protected virtual void Marshal2NestedObject(
+                        OpenWireFormat wireFormat,
+                        DataStructure o,
+                        BinaryWriter dataOut,
+                        BooleanStream bs) {
+                        wireFormat.Marshal2NestedObject(o, dataOut, bs);
+                }
+
+                protected virtual DataStructure UnmarshalCachedObject(
+                        OpenWireFormat wireFormat,
+                        BinaryReader dataIn,
+                        BooleanStream bs) {
+                        /*
+                        if (wireFormat.isCacheEnabled()) {
+                                if (bs.ReadBoolean()) {
+                                        short index = dataIn.ReadInt16();
+                                        DataStructure value = wireFormat.UnmarshalNestedObject(dataIn, bs);
+                                        wireFormat.setInUnmarshallCache(index, value);
+                                        return value;
+                                } else {
+                                        short index = dataIn.ReadInt16();
+                                        return wireFormat.getFromUnmarshallCache(index);
+                                }
+                        } else {
+                                return wireFormat.UnmarshalNestedObject(dataIn, bs);
+                        }
+                         */
+                        return wireFormat.UnmarshalNestedObject(dataIn, bs);
+                }
+
+                protected virtual int Marshal1CachedObject(
+                        OpenWireFormat wireFormat,
+                        DataStructure o,
+                        BooleanStream bs) {
+                        /*
+                        if (wireFormat.isCacheEnabled()) {
+                                Short index = wireFormat.getMarshallCacheIndex(o);
+                                bs.WriteBoolean(index == null);
+                                if (index == null) {
+                                        int rc = wireFormat.Marshal1NestedObject(o, bs);
+                                        wireFormat.addToMarshallCache(o);
+                                        return 2 + rc;
+                                } else {
+                                        return 2;
+                                }
+                        } else {
+                                return wireFormat.Marshal1NestedObject(o, bs);
+                        }
+                         */
+                        return wireFormat.Marshal1NestedObject(o, bs);
+                }
+
+                protected virtual void Marshal2CachedObject(
+                        OpenWireFormat wireFormat,
+                        DataStructure o,
+                        BinaryWriter dataOut,
+                        BooleanStream bs) {
+                        /*
+                        if (wireFormat.isCacheEnabled()) {
+                                Short index = wireFormat.getMarshallCacheIndex(o);
+                                if (bs.ReadBoolean()) {
+                                        dataOut.Write((short)index.shortValue());
+                                        wireFormat.Marshal2NestedObject(o, dataOut, bs);
+                                } else {
+                                        dataOut.Write((short)index.shortValue());
+                                }
+                        } else {
+                                wireFormat.Marshal2NestedObject(o, dataOut, bs);
+                        }
+                         */
+                        wireFormat.Marshal2NestedObject(o, dataOut, bs);
+                }
+
+
+
+                protected virtual String ReadString(BinaryReader dataIn, BooleanStream bs) {
+                        if (bs.ReadBoolean()) {
+                                if (bs.ReadBoolean()) {
+                                        int size = dataIn.ReadInt16();
+                                        byte[] data = new byte[size];
+                                        dataIn.Read(data, 0, size);
+                                        char[] text = new char[size];
+                                        for (int i = 0; i < size; i++) {
+                                                text[i] = (char) data[i];
+                                        }
+                                        return new String(text);
+                                } else {
+                                        return dataIn.ReadString();
+                                }
+                        } else {
+                                return null;
+                        }
+                }
+
+                protected virtual int WriteString(String value, BooleanStream bs) {
+                        bs.WriteBoolean(value != null);
+                        if (value != null) {
+                                int strlen = value.Length;
+                                int utflen = 0;
+                                int c = 0;
+                                bool isOnlyAscii = true;
+                                char[] charr = value.ToCharArray();
+                                for (int i = 0; i < strlen; i++) {
+                                        c = charr[i];
+                                        if ((c >= 0x0001) && (c <= 0x007F)) {
+                                                utflen++;
+                                        } else if (c > 0x07FF) {
+                                                utflen += 3;
+                                                isOnlyAscii = false;
+                                        } else {
+                                                isOnlyAscii = false;
+                                                utflen += 2;
+                                        }
+                                }
+
+                                if (utflen >= Int16.MaxValue)
+                                        throw new IOException("Encountered a String value that is too long to encode.");
+
+                                bs.WriteBoolean(isOnlyAscii);
+                                return utflen + 2;
+                        } else {
+                                return 0;
+                        }
+                }
+
+                protected virtual void WriteString(String value, BinaryWriter dataOut, BooleanStream bs) {
+                        if (bs.ReadBoolean()) {
+                                // If we verified it only holds ascii values
+                                if (bs.ReadBoolean()) {
+                                        dataOut.Write((short) value.Length);
+                                        dataOut.Write(value);
+                                } else {
+                                        dataOut.Write(value);
+                                }
+                        }
+                }
+
+                protected virtual int MarshalObjectArray(
+                        OpenWireFormat wireFormat,
+                        DataStructure[] objects,
+                        BooleanStream bs) {
+                        if (objects != null) {
+                                int rc = 0;
+                                bs.WriteBoolean(true);
+                                rc += 2;
+                                for (int i = 0; i < objects.Length; i++) {
+                                        rc += Marshal1NestedObject(wireFormat, objects[i], bs);
+                                }
+                                return rc;
+                        } else {
+                                bs.WriteBoolean(false);
+                                return 0;
+                        }
+                }
+
+                protected virtual void MarshalObjectArray(
+                        OpenWireFormat wireFormat,
+                        DataStructure[] objects,
+                        BinaryWriter dataOut,
+                        BooleanStream bs) {
+                        if (bs.ReadBoolean()) {
+                                dataOut.Write((short) objects.Length);
+                                for (int i = 0; i < objects.Length; i++) {
+                                        Marshal2NestedObject(wireFormat, objects[i], dataOut, bs);
+                                }
+                        }
+                }
+
+                protected virtual byte[] ReadBytes(BinaryReader dataIn, bool flag) {
+                        if (flag) {
+                                int size = dataIn.ReadInt32();
+                                return dataIn.ReadBytes(size);
+                        } else {
+                                return null;
+                        }
+                }
+
+                protected virtual byte[] ReadBytes(BinaryReader dataIn) {
+                        int size = dataIn.ReadInt32();
+                        return dataIn.ReadBytes(size);
+                }
+
+                protected virtual byte[] ReadBytes(BinaryReader dataIn, int size) {
+                        return dataIn.ReadBytes(size);
+                }
+
+                protected virtual void WriteBytes(byte[] command, BinaryWriter dataOut) {
+                        dataOut.Write(command.Length);
+                        dataOut.Write(command);
+                }
+
+                protected virtual BrokerError UnmarshalBrokerError(
+                        OpenWireFormat wireFormat,
+                        BinaryReader dataIn,
+                        BooleanStream bs) {
+                        if (bs.ReadBoolean()) {
+                                String clazz = ReadString(dataIn, bs);
+                                String message = ReadString(dataIn, bs);
+                                
+                                BrokerError answer = new BrokerError();
+                                answer.ExceptionClass = clazz;
+                                answer.Message = message;
+                                return answer;
+                        } else {
+                                return null;
+                        }
+                }
+
+                protected int MarshalBrokerError(OpenWireFormat wireFormat, BrokerError o, BooleanStream bs) {
+                        if (o == null) {
+                                bs.WriteBoolean(false);
+                                return 0;
+                        } else {
+                                int rc = 0;
+                                bs.WriteBoolean(true);
+                                rc += WriteString(o.ExceptionClass, bs);
+                                rc += WriteString(o.Message, bs);
+                                return rc;
+                        }
+                }
+
+                protected void MarshalBrokerError(
+                        OpenWireFormat wireFormat,
+                        BrokerError o,
+                        BinaryWriter dataOut,
+                        BooleanStream bs) {
+                        if (bs.ReadBoolean()) {
+                                WriteString(o.ExceptionClass, dataOut, bs);
+                                WriteString(o.Message, dataOut, bs);
+                        }
+                }
+                /*
+                protected virtual ActiveMQDestination ReadDestination(BinaryReader dataIn) {
+                        return (ActiveMQDestination) CommandMarshallerRegistry.ReadCommand(dataIn);
+                }
+
+                protected virtual void WriteDestination(ActiveMQDestination command, BinaryWriter dataOut) {
+                        CommandMarshallerRegistry.WriteCommand(command, dataOut);
+                }
+
+                protected virtual BrokerId[] ReadBrokerIds(BinaryReader dataIn) {
+                        int size = dataIn.ReadInt32();
+                        BrokerId[] answer = new BrokerId[size];
+                        for (int i = 0; i < size; i++) {
+                                answer[i] = (BrokerId) CommandMarshallerRegistry.BrokerIdMarshaller.ReadCommand(dataIn);
+                        }
+                        return answer;
+                }
+
+                protected virtual void WriteBrokerIds(BrokerId[] commands, BinaryWriter dataOut) {
+                        int size = commands.Length;
+                        dataOut.Write(size);
+                        for (int i = 0; i < size; i++) {
+                                CommandMarshallerRegistry.BrokerIdMarshaller.WriteCommand(commands[i], dataOut);
+                        }
+                }
+
+
+                protected virtual BrokerInfo[] ReadBrokerInfos(BinaryReader dataIn) {
+                        int size = dataIn.ReadInt32();
+                        BrokerInfo[] answer = new BrokerInfo[size];
+                        for (int i = 0; i < size; i++) {
+                                answer[i] = (BrokerInfo) CommandMarshallerRegistry
+                                        .BrokerInfoMarshaller
+                                        .ReadCommand(dataIn);
+                        }
+                        return answer;
+                }
+
+                protected virtual void WriteBrokerInfos(BrokerInfo[] commands, BinaryWriter dataOut) {
+                        int size = commands.Length;
+                        dataOut.Write(size);
+                        for (int i = 0; i < size; i++) {
+                                CommandMarshallerRegistry.BrokerInfoMarshaller.WriteCommand(commands[i], dataOut);
+                        }
+                }
+
+
+                protected virtual DataStructure[] ReadDataStructures(BinaryReader dataIn) {
+                        int size = dataIn.ReadInt32();
+                        DataStructure[] answer = new DataStructure[size];
+                        for (int i = 0; i < size; i++) {
+                                answer[i] = (DataStructure) CommandMarshallerRegistry.ReadCommand(dataIn);
+                        }
+                        return answer;
+                }
+
+                protected virtual void WriteDataStructures(DataStructure[] commands, BinaryWriter dataOut) {
+                        int size = commands.Length;
+                        dataOut.Write(size);
+                        for (int i = 0; i < size; i++) {
+                                CommandMarshallerRegistry.WriteCommand((Command) commands[i], dataOut);
+                        }
+                }
+                 */
+        }
+}

Propchange: incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/DataStreamMarshaller.cs
------------------------------------------------------------------------------
    svn:executable = *

Modified: incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/DataStructure.cs
URL: http://svn.apache.org/viewcvs/incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/DataStructure.cs?rev=379827&r1=379826&r2=379827&view=diff
==============================================================================
--- incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/DataStructure.cs (original)
+++ incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/DataStructure.cs Wed Feb 22 09:45:12 2006
@@ -7,6 +7,7 @@
         /// </summary>
         public interface DataStructure {
 
-                byte GetCommandType(); 
-        } 
+                byte GetDataStructureType();
+                bool IsMarshallAware();
+        }
 }

Added: incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/DataStructureSupport.cs
URL: http://svn.apache.org/viewcvs/incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/DataStructureSupport.cs?rev=379827&view=auto
==============================================================================
--- incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/DataStructureSupport.cs (added)
+++ incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/DataStructureSupport.cs Wed Feb 22 09:45:12 2006
@@ -0,0 +1,23 @@
+using System;
+using OpenWire.Client;
+using OpenWire.Client.Commands;
+using OpenWire.Client.Core;
+
+namespace OpenWire.Client.Core {
+        /// <summary>
+        /// Summary description for DataStructureSupport.
+        /// </summary>
+        public abstract class DataStructureSupport : DataStructure {
+
+                protected DataStructureSupport() {
+                }
+
+                public virtual byte GetDataStructureType() {
+                        return 0; 
+                }             
+                
+                public virtual bool IsMarshallAware() {
+                        return false; 
+                }     
+        }
+}

Propchange: incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/DataStructureSupport.cs
------------------------------------------------------------------------------
    svn:executable = *

Added: incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/MarshallAware.cs
URL: http://svn.apache.org/viewcvs/incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/MarshallAware.cs?rev=379827&view=auto
==============================================================================
--- incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/MarshallAware.cs (added)
+++ incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/MarshallAware.cs Wed Feb 22 09:45:12 2006
@@ -0,0 +1,23 @@
+using System;
+using System.IO;
+
+using OpenWire.Client.Commands;
+using OpenWire.Client.Core;
+using OpenWire.Client.IO;
+
+namespace OpenWire.Client.Core {
+        /// <summary>
+        /// Represents a marshallable entity
+        /// </summary>
+        public interface MarshallAware {
+
+                void BeforeMarshall(OpenWireFormat wireFormat);
+                void AfterMarshall(OpenWireFormat wireFormat);
+
+                void BeforeUnmarshall(OpenWireFormat wireFormat);
+                void AfterUnmarshall(OpenWireFormat wireFormat);
+
+                void SetMarshalledForm(OpenWireFormat wireFormat, byte[] data);
+                byte[] GetMarshalledForm(OpenWireFormat wireFormat);
+        }
+}

Added: incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/OpenWireFormat.cs
URL: http://svn.apache.org/viewcvs/incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/OpenWireFormat.cs?rev=379827&view=auto
==============================================================================
--- incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/OpenWireFormat.cs (added)
+++ incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/OpenWireFormat.cs Wed Feb 22 09:45:12 2006
@@ -0,0 +1,133 @@
+using System;
+using System.IO;
+
+using OpenWire.Client.Commands;
+using OpenWire.Client.Core;
+using OpenWire.Client.IO;
+
+namespace OpenWire.Client.Core {
+        /// <summary>
+        /// Represents the wire format
+        /// </summary>
+        public class OpenWireFormat {
+                private DataStreamMarshaller[] dataMarshallers;
+                private const byte NULL_TYPE = 0;
+
+
+                public void addMarshaller(DataStreamMarshaller marshaller) 
+                {
+                        dataMarshallers[marshaller.GetDataStructureType()] = marshaller;
+                }
+                
+                public void Marshal(Object o, BinaryWriter ds) {
+                        int size = 1;
+                        if (o != null) {
+                                DataStructure c = (DataStructure) o;
+                                byte type = c.GetDataStructureType();
+                                DataStreamMarshaller dsm = (DataStreamMarshaller) dataMarshallers[type & 0xFF];
+                                if (dsm == null)
+                                        throw new IOException("Unknown data type: " + type);
+
+                                BooleanStream bs = new BooleanStream();
+                                size += dsm.Marshal1(this, c, bs);
+                                size += bs.MarshalledSize();
+
+                                ds.Write(size);
+                                ds.Write(type);
+                                bs.Marshal(ds);
+                                dsm.Marshal2(this, c, ds, bs);
+                        } else {
+                                ds.Write(size);
+                                ds.Write(NULL_TYPE);
+                        }
+                }
+
+                public Object Unmarshal(BinaryReader dis) {
+                        byte dataType = dis.ReadByte();
+                        if (dataType != NULL_TYPE) {
+                                DataStreamMarshaller dsm = (DataStreamMarshaller) dataMarshallers[dataType & 0xFF];
+                                if (dsm == null)
+                                        throw new IOException("Unknown data type: " + dataType);
+                                Object data = dsm.CreateObject();
+                                BooleanStream bs = new BooleanStream();
+                                bs.Unmarshal(dis);
+                                dsm.Unmarshal(this, data, dis, bs);
+                                return data;
+                        } else {
+                                return null;
+                        }
+                }
+
+                public int Marshal1NestedObject(DataStructure o, BooleanStream bs) {
+                        bs.WriteBoolean(o != null);
+                        if (o == null)
+                                return 0;
+
+                        if (o.IsMarshallAware()) {
+                                MarshallAware ma = (MarshallAware) o;
+                                byte[] sequence = ma.GetMarshalledForm(this);
+                                bs.WriteBoolean(sequence != null);
+                                if (sequence != null) {
+                                        return 1 + sequence.Length;
+                                }
+                        }
+
+                        byte type = o.GetDataStructureType();
+                        DataStreamMarshaller dsm = (DataStreamMarshaller) dataMarshallers[type & 0xFF];
+                        if (dsm == null)
+                                throw new IOException("Unknown data type: " + type);
+                        return 1 + dsm.Marshal1(this, o, bs);
+                }
+
+                public void Marshal2NestedObject(DataStructure o, BinaryWriter ds, BooleanStream bs) {
+                        if (!bs.ReadBoolean())
+                                return ;
+
+                        byte type = o.GetDataStructureType();
+                        ds.Write(type);
+
+                        if (o.IsMarshallAware() && bs.ReadBoolean()) {
+                                MarshallAware ma = (MarshallAware) o;
+                                byte[] sequence = ma.GetMarshalledForm(this);
+                                ds.Write(sequence, 0, sequence.Length);
+                        } else {
+
+                                DataStreamMarshaller dsm = (DataStreamMarshaller) dataMarshallers[type & 0xFF];
+                                if (dsm == null)
+                                        throw new IOException("Unknown data type: " + type);
+                                dsm.Marshal2(this, o, ds, bs);
+                        }
+                }
+
+                public DataStructure UnmarshalNestedObject(BinaryReader dis, BooleanStream bs) {
+                        if (bs.ReadBoolean()) {
+
+                                byte dataType = dis.ReadByte();
+                                DataStreamMarshaller dsm = (DataStreamMarshaller) dataMarshallers[dataType & 0xFF];
+                                if (dsm == null)
+                                        throw new IOException("Unknown data type: " + dataType);
+                                DataStructure data = dsm.CreateObject();
+
+                                if (data.IsMarshallAware() && bs.ReadBoolean()) {
+
+                                        dis.ReadInt32();
+                                        dis.ReadByte();
+
+                                        BooleanStream bs2 = new BooleanStream();
+                                        bs2.Unmarshal(dis);
+                                        dsm.Unmarshal(this, data, dis, bs2);
+
+                                        // TODO: extract the sequence from the dis and associate it.
+                                        //                MarshallAware ma = (MarshallAware)data
+                                        //                ma.setCachedMarshalledForm(this, sequence);
+                                } else {
+                                        dsm.Unmarshal(this, data, dis, bs);
+                                }
+
+                                return data;
+                        } else {
+                                return null;
+                        }
+                }
+        }
+}

Propchange: incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/OpenWireFormat.cs
------------------------------------------------------------------------------
    svn:executable = *

Modified: incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/SocketTransport.cs
URL: http://svn.apache.org/viewcvs/incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/SocketTransport.cs?rev=379827&r1=379826&r2=379827&view=diff
==============================================================================
--- incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/SocketTransport.cs (original)
+++ incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/Core/SocketTransport.cs Wed Feb 22 09:45:12 2006
@@ -29,6 +29,7 @@
 
                 public event CommandHandler Command;
                 public event ExceptionHandler Exception;
+                private OpenWireFormat wireformat = new OpenWireFormat();
 
                 public SocketTransport(string host, int port) {
                         Console.WriteLine("Opening socket to: " + host + " on port: " + port);
@@ -78,7 +79,7 @@
                         while (!closed) {
                                 BaseCommand command = null;
                                 try {
-                                        command = (BaseCommand) CommandMarshallerRegistry.ReadCommand(socketReader); 
+                                        command = (BaseCommand) wireformat.Unmarshal(socketReader); 
                                 } catch (ObjectDisposedException e) {
                                         // stream closed
                                         break; 
@@ -113,7 +114,7 @@
 
                 protected void Send(Command command) {
                         lock (transmissionLock) {
-                                CommandMarshallerRegistry.WriteCommand(command, socketWriter);
+                                wireformat.Marshal(command, socketWriter);
                                 socketWriter.Flush(); 
                         } 
                 }

Modified: incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/IO/ActiveMQBytesMessageMarshaller.cs
URL: http://svn.apache.org/viewcvs/incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/IO/ActiveMQBytesMessageMarshaller.cs?rev=379827&r1=379826&r2=379827&view=diff
==============================================================================
--- incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/IO/ActiveMQBytesMessageMarshaller.cs (original)
+++ incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/IO/ActiveMQBytesMessageMarshaller.cs Wed Feb 22 09:45:12 2006
@@ -1,10 +1,18 @@
 //
-// Marshalling code for Open Wire Format for ActiveMQBytesMessage
 //
+// Copyright 2005-2006 The Apache Software Foundation
 //
-// NOTE!: This file is autogenerated - do not modify!
-//        if you need to make a change, please see the Groovy scripts in the
-//        activemq-openwire module
+// Licensed 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.
 //
 
 using System;
@@ -18,22 +26,55 @@
 
 namespace OpenWire.Client.IO
 {
-    public class ActiveMQBytesMessageMarshaller : ActiveMQMessageMarshaller
+  //
+  //  Marshalling code for Open Wire Format for ActiveMQBytesMessage
+  //
+  //
+  //  NOTE!: This file is autogenerated - do not modify!
+  //        if you need to make a change, please see the Groovy scripts in the
+  //        activemq-core module
+  //
+  public class ActiveMQBytesMessageMarshaller : ActiveMQMessageMarshaller
+  {
+
+
+    public override DataStructure CreateObject() 
     {
+        return new ActiveMQBytesMessage();
+    }
 
+    public override byte GetDataStructureType() 
+    {
+        return ActiveMQBytesMessage.ID_ActiveMQBytesMessage;
+    }
 
-        public override Command CreateCommand() {
-            return new ActiveMQBytesMessage();
-        }
+    // 
+    // Un-marshal an object instance from the data input stream
+    // 
+    public override void Unmarshal(OpenWireFormat wireFormat, Object o, BinaryReader dataIn, BooleanStream bs) 
+    {
+        base.Unmarshal(wireFormat, o, dataIn, bs);
+
+    }
 
-        public override void BuildCommand(Command command, BinaryReader dataIn) {
-            base.BuildCommand(command, dataIn);
 
-        }
+    //
+    // Write the booleans that this object uses to a BooleanStream
+    //
+    public override int Marshal1(OpenWireFormat wireFormat, Object o, BooleanStream bs) {
+        ActiveMQBytesMessage info = (ActiveMQBytesMessage)o;
+
+        int rc = base.Marshal1(wireFormat, info, bs);
+
+        return rc + 0;
+    }
 
-        public override void WriteCommand(Command command, BinaryWriter dataOut) {
-            base.WriteCommand(command, dataOut);
+    // 
+    // Write a object instance to data output stream
+    //
+    public override void Marshal2(OpenWireFormat wireFormat, Object o, BinaryWriter dataOut, BooleanStream bs) {
+        base.Marshal2(wireFormat, o, dataOut, bs);
 
-        }
     }
+  }
 }

Modified: incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/IO/ActiveMQDestinationMarshaller.cs
URL: http://svn.apache.org/viewcvs/incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/IO/ActiveMQDestinationMarshaller.cs?rev=379827&r1=379826&r2=379827&view=diff
==============================================================================
--- incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/IO/ActiveMQDestinationMarshaller.cs (original)
+++ incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/IO/ActiveMQDestinationMarshaller.cs Wed Feb 22 09:45:12 2006
@@ -1,10 +1,18 @@
 //
-// Marshalling code for Open Wire Format for ActiveMQDestination
 //
+// Copyright 2005-2006 The Apache Software Foundation
 //
-// NOTE!: This file is autogenerated - do not modify!
-//        if you need to make a change, please see the Groovy scripts in the
-//        activemq-openwire module
+// Licensed 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.
 //
 
 using System;
@@ -18,24 +26,51 @@
 
 namespace OpenWire.Client.IO
 {
-    public abstract class ActiveMQDestinationMarshaller : AbstractCommandMarshaller
+  //
+  //  Marshalling code for Open Wire Format for ActiveMQDestination
+  //
+  //
+  //  NOTE!: This file is autogenerated - do not modify!
+  //        if you need to make a change, please see the Groovy scripts in the
+  //        activemq-core module
+  //
+  public abstract class ActiveMQDestinationMarshaller : DataStreamMarshaller
+  {
+
+    // 
+    // Un-marshal an object instance from the data input stream
+    // 
+    public override void Unmarshal(OpenWireFormat wireFormat, Object o, BinaryReader dataIn, BooleanStream bs) 
     {
+        base.Unmarshal(wireFormat, o, dataIn, bs);
+
+        ActiveMQDestination info = (ActiveMQDestination)o;
+        info.PhysicalName = ReadString(dataIn, bs);
+
+    }
 
 
-        public override void BuildCommand(Command command, BinaryReader dataIn) {
-            base.BuildCommand(command, dataIn);
+    //
+    // Write the booleans that this object uses to a BooleanStream
+    //
+    public override int Marshal1(OpenWireFormat wireFormat, Object o, BooleanStream bs) {
+        ActiveMQDestination info = (ActiveMQDestination)o;
 
-            ActiveMQDestination info = (ActiveMQDestination) command;
-            info.PhysicalName = dataIn.ReadString();
+        int rc = base.Marshal1(wireFormat, info, bs);
+        rc += WriteString(info.PhysicalName, bs);
 
-        }
+        return rc + 0;
+    }
 
-        public override void WriteCommand(Command command, BinaryWriter dataOut) {
-            base.WriteCommand(command, dataOut);
+    // 
+    // Write a object instance to data output stream
+    //
+    public override void Marshal2(OpenWireFormat wireFormat, Object o, BinaryWriter dataOut, BooleanStream bs) {
+        base.Marshal2(wireFormat, o, dataOut, bs);
 
-            ActiveMQDestination info = (ActiveMQDestination) command;
-            dataOut.Write(info.PhysicalName);
+        ActiveMQDestination info = (ActiveMQDestination)o;
+        WriteString(info.PhysicalName, dataOut, bs);
 
-        }
     }
+  }
 }

Modified: incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/IO/ActiveMQMapMessageMarshaller.cs
URL: http://svn.apache.org/viewcvs/incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/IO/ActiveMQMapMessageMarshaller.cs?rev=379827&r1=379826&r2=379827&view=diff
==============================================================================
--- incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/IO/ActiveMQMapMessageMarshaller.cs (original)
+++ incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/IO/ActiveMQMapMessageMarshaller.cs Wed Feb 22 09:45:12 2006
@@ -1,10 +1,18 @@
 //
-// Marshalling code for Open Wire Format for ActiveMQMapMessage
 //
+// Copyright 2005-2006 The Apache Software Foundation
 //
-// NOTE!: This file is autogenerated - do not modify!
-//        if you need to make a change, please see the Groovy scripts in the
-//        activemq-openwire module
+// Licensed 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.
 //
 
 using System;
@@ -18,22 +26,55 @@
 
 namespace OpenWire.Client.IO
 {
-    public class ActiveMQMapMessageMarshaller : ActiveMQMessageMarshaller
+  //
+  //  Marshalling code for Open Wire Format for ActiveMQMapMessage
+  //
+  //
+  //  NOTE!: This file is autogenerated - do not modify!
+  //        if you need to make a change, please see the Groovy scripts in the
+  //        activemq-core module
+  //
+  public class ActiveMQMapMessageMarshaller : ActiveMQMessageMarshaller
+  {
+
+
+    public override DataStructure CreateObject() 
     {
+        return new ActiveMQMapMessage();
+    }
 
+    public override byte GetDataStructureType() 
+    {
+        return ActiveMQMapMessage.ID_ActiveMQMapMessage;
+    }
 
-        public override Command CreateCommand() {
-            return new ActiveMQMapMessage();
-        }
+    // 
+    // Un-marshal an object instance from the data input stream
+    // 
+    public override void Unmarshal(OpenWireFormat wireFormat, Object o, BinaryReader dataIn, BooleanStream bs) 
+    {
+        base.Unmarshal(wireFormat, o, dataIn, bs);
+
+    }
 
-        public override void BuildCommand(Command command, BinaryReader dataIn) {
-            base.BuildCommand(command, dataIn);
 
-        }
+    //
+    // Write the booleans that this object uses to a BooleanStream
+    //
+    public override int Marshal1(OpenWireFormat wireFormat, Object o, BooleanStream bs) {
+        ActiveMQMapMessage info = (ActiveMQMapMessage)o;
+
+        int rc = base.Marshal1(wireFormat, info, bs);
+
+        return rc + 0;
+    }
 
-        public override void WriteCommand(Command command, BinaryWriter dataOut) {
-            base.WriteCommand(command, dataOut);
+    // 
+    // Write a object instance to data output stream
+    //
+    public override void Marshal2(OpenWireFormat wireFormat, Object o, BinaryWriter dataOut, BooleanStream bs) {
+        base.Marshal2(wireFormat, o, dataOut, bs);
 
-        }
     }
+  }
 }

Modified: incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/IO/ActiveMQMessageMarshaller.cs
URL: http://svn.apache.org/viewcvs/incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/IO/ActiveMQMessageMarshaller.cs?rev=379827&r1=379826&r2=379827&view=diff
==============================================================================
--- incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/IO/ActiveMQMessageMarshaller.cs (original)
+++ incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/IO/ActiveMQMessageMarshaller.cs Wed Feb 22 09:45:12 2006
@@ -1,10 +1,18 @@
 //
-// Marshalling code for Open Wire Format for ActiveMQMessage
 //
+// Copyright 2005-2006 The Apache Software Foundation
 //
-// NOTE!: This file is autogenerated - do not modify!
-//        if you need to make a change, please see the Groovy scripts in the
-//        activemq-openwire module
+// Licensed 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.
 //
 
 using System;
@@ -18,22 +26,68 @@
 
 namespace OpenWire.Client.IO
 {
-    public class ActiveMQMessageMarshaller : AbstractCommandMarshaller
+  //
+  //  Marshalling code for Open Wire Format for ActiveMQMessage
+  //
+  //
+  //  NOTE!: This file is autogenerated - do not modify!
+  //        if you need to make a change, please see the Groovy scripts in the
+  //        activemq-core module
+  //
+  public class ActiveMQMessageMarshaller : MessageMarshaller
+  {
+
+
+    public override DataStructure CreateObject() 
+    {
+        return new ActiveMQMessage();
+    }
+
+    public override byte GetDataStructureType() 
+    {
+        return ActiveMQMessage.ID_ActiveMQMessage;
+    }
+
+    // 
+    // Un-marshal an object instance from the data input stream
+    // 
+    public override void Unmarshal(OpenWireFormat wireFormat, Object o, BinaryReader dataIn, BooleanStream bs) 
     {
+        base.Unmarshal(wireFormat, o, dataIn, bs);
 
+        ActiveMQMessage info = (ActiveMQMessage)o;
 
-        public override Command CreateCommand() {
-            return new ActiveMQMessage();
-        }
+        info.BeforeUnmarshall(wireFormat);
+        
+
+        info.AfterUnmarshall(wireFormat);
+
+    }
+
+
+    //
+    // Write the booleans that this object uses to a BooleanStream
+    //
+    public override int Marshal1(OpenWireFormat wireFormat, Object o, BooleanStream bs) {
+        ActiveMQMessage info = (ActiveMQMessage)o;
+
+        info.BeforeMarshall(wireFormat);
+
+        int rc = base.Marshal1(wireFormat, info, bs);
+
+        return rc + 0;
+    }
 
-        public override void BuildCommand(Command command, BinaryReader dataIn) {
-            base.BuildCommand(command, dataIn);
+    // 
+    // Write a object instance to data output stream
+    //
+    public override void Marshal2(OpenWireFormat wireFormat, Object o, BinaryWriter dataOut, BooleanStream bs) {
+        base.Marshal2(wireFormat, o, dataOut, bs);
 
-        }
+        ActiveMQMessage info = (ActiveMQMessage)o;
 
-        public override void WriteCommand(Command command, BinaryWriter dataOut) {
-            base.WriteCommand(command, dataOut);
+        info.AfterMarshall(wireFormat);
 
-        }
     }
+  }
 }

Modified: incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/IO/ActiveMQObjectMessageMarshaller.cs
URL: http://svn.apache.org/viewcvs/incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/IO/ActiveMQObjectMessageMarshaller.cs?rev=379827&r1=379826&r2=379827&view=diff
==============================================================================
--- incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/IO/ActiveMQObjectMessageMarshaller.cs (original)
+++ incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/IO/ActiveMQObjectMessageMarshaller.cs Wed Feb 22 09:45:12 2006
@@ -1,10 +1,18 @@
 //
-// Marshalling code for Open Wire Format for ActiveMQObjectMessage
 //
+// Copyright 2005-2006 The Apache Software Foundation
 //
-// NOTE!: This file is autogenerated - do not modify!
-//        if you need to make a change, please see the Groovy scripts in the
-//        activemq-openwire module
+// Licensed 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.
 //
 
 using System;
@@ -18,22 +26,55 @@
 
 namespace OpenWire.Client.IO
 {
-    public class ActiveMQObjectMessageMarshaller : ActiveMQMessageMarshaller
+  //
+  //  Marshalling code for Open Wire Format for ActiveMQObjectMessage
+  //
+  //
+  //  NOTE!: This file is autogenerated - do not modify!
+  //        if you need to make a change, please see the Groovy scripts in the
+  //        activemq-core module
+  //
+  public class ActiveMQObjectMessageMarshaller : ActiveMQMessageMarshaller
+  {
+
+
+    public override DataStructure CreateObject() 
     {
+        return new ActiveMQObjectMessage();
+    }
 
+    public override byte GetDataStructureType() 
+    {
+        return ActiveMQObjectMessage.ID_ActiveMQObjectMessage;
+    }
 
-        public override Command CreateCommand() {
-            return new ActiveMQObjectMessage();
-        }
+    // 
+    // Un-marshal an object instance from the data input stream
+    // 
+    public override void Unmarshal(OpenWireFormat wireFormat, Object o, BinaryReader dataIn, BooleanStream bs) 
+    {
+        base.Unmarshal(wireFormat, o, dataIn, bs);
+
+    }
 
-        public override void BuildCommand(Command command, BinaryReader dataIn) {
-            base.BuildCommand(command, dataIn);
 
-        }
+    //
+    // Write the booleans that this object uses to a BooleanStream
+    //
+    public override int Marshal1(OpenWireFormat wireFormat, Object o, BooleanStream bs) {
+        ActiveMQObjectMessage info = (ActiveMQObjectMessage)o;
+
+        int rc = base.Marshal1(wireFormat, info, bs);
+
+        return rc + 0;
+    }
 
-        public override void WriteCommand(Command command, BinaryWriter dataOut) {
-            base.WriteCommand(command, dataOut);
+    // 
+    // Write a object instance to data output stream
+    //
+    public override void Marshal2(OpenWireFormat wireFormat, Object o, BinaryWriter dataOut, BooleanStream bs) {
+        base.Marshal2(wireFormat, o, dataOut, bs);
 
-        }
     }
+  }
 }

Modified: incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/IO/ActiveMQQueueMarshaller.cs
URL: http://svn.apache.org/viewcvs/incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/IO/ActiveMQQueueMarshaller.cs?rev=379827&r1=379826&r2=379827&view=diff
==============================================================================
--- incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/IO/ActiveMQQueueMarshaller.cs (original)
+++ incubator/activemq/trunk/openwire-dotnet/src/OpenWire.Client/IO/ActiveMQQueueMarshaller.cs Wed Feb 22 09:45:12 2006
@@ -1,10 +1,18 @@
 //
-// Marshalling code for Open Wire Format for ActiveMQQueue
 //
+// Copyright 2005-2006 The Apache Software Foundation
 //
-// NOTE!: This file is autogenerated - do not modify!
-//        if you need to make a change, please see the Groovy scripts in the
-//        activemq-openwire module
+// Licensed 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.
 //
 
 using System;
@@ -18,22 +26,55 @@
 
 namespace OpenWire.Client.IO
 {
-    public class ActiveMQQueueMarshaller : AbstractCommandMarshaller
+  //
+  //  Marshalling code for Open Wire Format for ActiveMQQueue
+  //
+  //
+  //  NOTE!: This file is autogenerated - do not modify!
+  //        if you need to make a change, please see the Groovy scripts in the
+  //        activemq-core module
+  //
+  public class ActiveMQQueueMarshaller : ActiveMQDestinationMarshaller
+  {
+
+
+    public override DataStructure CreateObject() 
     {
+        return new ActiveMQQueue();
+    }
 
+    public override byte GetDataStructureType() 
+    {
+        return ActiveMQQueue.ID_ActiveMQQueue;
+    }
 
-        public override Command CreateCommand() {
-            return new ActiveMQQueue();
-        }
+    // 
+    // Un-marshal an object instance from the data input stream
+    // 
+    public override void Unmarshal(OpenWireFormat wireFormat, Object o, BinaryReader dataIn, BooleanStream bs) 
+    {
+        base.Unmarshal(wireFormat, o, dataIn, bs);
+
+    }
 
-        public override void BuildCommand(Command command, BinaryReader dataIn) {
-            base.BuildCommand(command, dataIn);
 
-        }
+    //
+    // Write the booleans that this object uses to a BooleanStream
+    //
+    public override int Marshal1(OpenWireFormat wireFormat, Object o, BooleanStream bs) {
+        ActiveMQQueue info = (ActiveMQQueue)o;
+
+        int rc = base.Marshal1(wireFormat, info, bs);
+
+        return rc + 0;
+    }
 
-        public override void WriteCommand(Command command, BinaryWriter dataOut) {
-            base.WriteCommand(command, dataOut);
+    // 
+    // Write a object instance to data output stream
+    //
+    public override void Marshal2(OpenWireFormat wireFormat, Object o, BinaryWriter dataOut, BooleanStream bs) {
+        base.Marshal2(wireFormat, o, dataOut, bs);
 
-        }
     }
+  }
 }



Mime
View raw message