[jboss-cvs] JBoss Messaging SVN: r5827 - in trunk: dotnet and 13 other directories.

jboss-cvs-commits at lists.jboss.org jboss-cvs-commits at lists.jboss.org
Thu Feb 5 15:23:48 EST 2009


Author: clebert.suconic at jboss.com
Date: 2009-02-05 15:23:48 -0500 (Thu, 05 Feb 2009)
New Revision: 5827

Added:
   trunk/dotnet/
   trunk/dotnet/JBMClient/
   trunk/dotnet/JBMClient/JBM.Client.csproj
   trunk/dotnet/JBMClient/Properties/
   trunk/dotnet/JBMClient/Properties/AssemblyInfo.cs
   trunk/dotnet/JBMClient/exception/
   trunk/dotnet/JBMClient/exception/MessagingException.cs
   trunk/dotnet/JBMClient/remoting/
   trunk/dotnet/JBMClient/remoting/Acceptor.java
   trunk/dotnet/JBMClient/remoting/AcceptorFactory.java
   trunk/dotnet/JBMClient/remoting/BufferHandler.java
   trunk/dotnet/JBMClient/remoting/Channel.cs
   trunk/dotnet/JBMClient/remoting/ChannelHandler.cs
   trunk/dotnet/JBMClient/remoting/Connection.java
   trunk/dotnet/JBMClient/remoting/ConnectionLifeCycleListener.java
   trunk/dotnet/JBMClient/remoting/Connector.java
   trunk/dotnet/JBMClient/remoting/ConnectorFactory.java
   trunk/dotnet/JBMClient/remoting/FailureListener.cs
   trunk/dotnet/JBMClient/remoting/Interceptor.cs
   trunk/dotnet/JBMClient/remoting/MessagingBuffer.java
   trunk/dotnet/JBMClient/remoting/Packet.cs
   trunk/dotnet/JBMClient/remoting/RemotingConnection.cs
   trunk/dotnet/JBMClient/remoting/impl/
   trunk/dotnet/JBMClient/remoting/impl/AbstractBufferHandler.java
   trunk/dotnet/JBMClient/remoting/impl/ByteBufferWrapper.java
   trunk/dotnet/JBMClient/remoting/impl/ExpandingMessagingBuffer.java
   trunk/dotnet/JBMClient/remoting/impl/RemotingConnectionImpl.java
   trunk/dotnet/JBMClient/remoting/impl/RemotingServiceImpl.java
   trunk/dotnet/JBMClient/remoting/impl/invm/
   trunk/dotnet/JBMClient/remoting/impl/invm/InVMAcceptor.java
   trunk/dotnet/JBMClient/remoting/impl/invm/InVMAcceptorFactory.java
   trunk/dotnet/JBMClient/remoting/impl/invm/InVMConnection.java
   trunk/dotnet/JBMClient/remoting/impl/invm/InVMConnector.java
   trunk/dotnet/JBMClient/remoting/impl/invm/InVMConnectorFactory.java
   trunk/dotnet/JBMClient/remoting/impl/invm/InVMRegistry.java
   trunk/dotnet/JBMClient/remoting/impl/invm/TransportConstants.java
   trunk/dotnet/JBMClient/remoting/impl/ssl/
   trunk/dotnet/JBMClient/remoting/impl/ssl/SSLSupport.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/
   trunk/dotnet/JBMClient/remoting/impl/wireformat/CreateSessionMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/CreateSessionResponseMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/MessagingExceptionMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/NullResponseMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/PacketImpl.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/PacketsConfirmedMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/Ping.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/Pong.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/ReattachSessionMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/ReattachSessionResponseMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/ReplicateCreateSessionMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionAcknowledgeMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionAddDestinationMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionBindingQueryMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionBindingQueryResponseMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionCloseMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionConsumerCloseMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionConsumerFlowCreditMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionContinuationMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionCreateConsumerMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionCreateQueueMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionDeleteQueueMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionExpiredMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionFailoverCompleteMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionQueueQueryMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionQueueQueryResponseMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionReceiveContinuationMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionReceiveMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionRemoveDestinationMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionReplicateDeliveryMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionSendContinuationMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionSendMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXACommitMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAEndMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAForgetMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAGetInDoubtXidsResponseMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAGetTimeoutResponseMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAJoinMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAPrepareMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAResponseMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAResumeMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXARollbackMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXASetTimeoutMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXASetTimeoutResponseMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAStartMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/XidCodecSupport.java
   trunk/dotnet/JBMClient/remoting/spi/
   trunk/dotnet/JBMClient/remoting/spi/Acceptor.java
   trunk/dotnet/JBMClient/remoting/spi/AcceptorFactory.java
   trunk/dotnet/JBMClient/remoting/spi/BufferHandler.cs
   trunk/dotnet/JBMClient/remoting/spi/Connection.java
   trunk/dotnet/JBMClient/remoting/spi/ConnectionLifeCycleListener.java
   trunk/dotnet/JBMClient/remoting/spi/Connector.java
   trunk/dotnet/JBMClient/remoting/spi/ConnectorFactory.java
   trunk/dotnet/JBMClient/remoting/spi/MessagingBuffer.cs
   trunk/dotnet/JBMClient/util/
   trunk/dotnet/JBMClient/util/DataConstants.cs
   trunk/dotnet/JBMClient/util/SimpleString.cs
   trunk/dotnet/JBMClientSolution.sln
   trunk/dotnet/JBMClientSolution.vsmdi
   trunk/dotnet/JBMClientTest/
   trunk/dotnet/JBMClientTest/AuthoringTests.txt
   trunk/dotnet/JBMClientTest/JBM.Client.Test.csproj
   trunk/dotnet/JBMClientTest/JBMClientTest.userprefs
   trunk/dotnet/JBMClientTest/Properties/
   trunk/dotnet/JBMClientTest/Properties/AssemblyInfo.cs
   trunk/dotnet/JBMClientTest/util/
   trunk/dotnet/JBMClientTest/util/JBMTest.cs
   trunk/dotnet/JBMClientTest/util/SimpleStringTest.cs
   trunk/dotnet/JSMClient.vsmdi
   trunk/dotnet/LocalTestRun.testrunconfig
   trunk/dotnet/README.txt
Removed:
   trunk/dotnet/JBMClient/
   trunk/dotnet/JBMClient/JBM.Client.csproj
   trunk/dotnet/JBMClient/Properties/
   trunk/dotnet/JBMClient/Properties/AssemblyInfo.cs
   trunk/dotnet/JBMClient/exception/
   trunk/dotnet/JBMClient/exception/MessagingException.cs
   trunk/dotnet/JBMClient/remoting/
   trunk/dotnet/JBMClient/remoting/Acceptor.java
   trunk/dotnet/JBMClient/remoting/AcceptorFactory.java
   trunk/dotnet/JBMClient/remoting/BufferHandler.java
   trunk/dotnet/JBMClient/remoting/Channel.cs
   trunk/dotnet/JBMClient/remoting/ChannelHandler.cs
   trunk/dotnet/JBMClient/remoting/Connection.java
   trunk/dotnet/JBMClient/remoting/ConnectionLifeCycleListener.java
   trunk/dotnet/JBMClient/remoting/Connector.java
   trunk/dotnet/JBMClient/remoting/ConnectorFactory.java
   trunk/dotnet/JBMClient/remoting/FailureListener.cs
   trunk/dotnet/JBMClient/remoting/Interceptor.cs
   trunk/dotnet/JBMClient/remoting/MessagingBuffer.java
   trunk/dotnet/JBMClient/remoting/Packet.cs
   trunk/dotnet/JBMClient/remoting/RemotingConnection.cs
   trunk/dotnet/JBMClient/remoting/impl/
   trunk/dotnet/JBMClient/remoting/impl/AbstractBufferHandler.java
   trunk/dotnet/JBMClient/remoting/impl/ByteBufferWrapper.java
   trunk/dotnet/JBMClient/remoting/impl/ExpandingMessagingBuffer.java
   trunk/dotnet/JBMClient/remoting/impl/RemotingConnectionImpl.java
   trunk/dotnet/JBMClient/remoting/impl/RemotingServiceImpl.java
   trunk/dotnet/JBMClient/remoting/impl/invm/
   trunk/dotnet/JBMClient/remoting/impl/invm/InVMAcceptor.java
   trunk/dotnet/JBMClient/remoting/impl/invm/InVMAcceptorFactory.java
   trunk/dotnet/JBMClient/remoting/impl/invm/InVMConnection.java
   trunk/dotnet/JBMClient/remoting/impl/invm/InVMConnector.java
   trunk/dotnet/JBMClient/remoting/impl/invm/InVMConnectorFactory.java
   trunk/dotnet/JBMClient/remoting/impl/invm/InVMRegistry.java
   trunk/dotnet/JBMClient/remoting/impl/invm/TransportConstants.java
   trunk/dotnet/JBMClient/remoting/impl/ssl/
   trunk/dotnet/JBMClient/remoting/impl/ssl/SSLSupport.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/
   trunk/dotnet/JBMClient/remoting/impl/wireformat/CreateSessionMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/CreateSessionResponseMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/MessagingExceptionMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/NullResponseMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/PacketImpl.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/PacketsConfirmedMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/Ping.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/Pong.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/ReattachSessionMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/ReattachSessionResponseMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/ReplicateCreateSessionMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionAcknowledgeMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionAddDestinationMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionBindingQueryMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionBindingQueryResponseMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionCloseMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionConsumerCloseMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionConsumerFlowCreditMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionContinuationMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionCreateConsumerMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionCreateQueueMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionDeleteQueueMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionExpiredMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionFailoverCompleteMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionQueueQueryMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionQueueQueryResponseMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionReceiveContinuationMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionReceiveMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionRemoveDestinationMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionReplicateDeliveryMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionSendContinuationMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionSendMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXACommitMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAEndMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAForgetMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAGetInDoubtXidsResponseMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAGetTimeoutResponseMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAJoinMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAPrepareMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAResponseMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAResumeMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXARollbackMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXASetTimeoutMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXASetTimeoutResponseMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAStartMessage.java
   trunk/dotnet/JBMClient/remoting/impl/wireformat/XidCodecSupport.java
   trunk/dotnet/JBMClient/remoting/spi/
   trunk/dotnet/JBMClient/remoting/spi/Acceptor.java
   trunk/dotnet/JBMClient/remoting/spi/AcceptorFactory.java
   trunk/dotnet/JBMClient/remoting/spi/BufferHandler.cs
   trunk/dotnet/JBMClient/remoting/spi/Connection.java
   trunk/dotnet/JBMClient/remoting/spi/ConnectionLifeCycleListener.java
   trunk/dotnet/JBMClient/remoting/spi/Connector.java
   trunk/dotnet/JBMClient/remoting/spi/ConnectorFactory.java
   trunk/dotnet/JBMClient/remoting/spi/MessagingBuffer.cs
   trunk/dotnet/JBMClient/util/
   trunk/dotnet/JBMClient/util/DataConstants.cs
   trunk/dotnet/JBMClient/util/SimpleString.cs
   trunk/dotnet/JBMClientSolution.sln
   trunk/dotnet/JBMClientSolution.vsmdi
   trunk/dotnet/JBMClientTest/
   trunk/dotnet/JBMClientTest/AuthoringTests.txt
   trunk/dotnet/JBMClientTest/JBM.Client.Test.csproj
   trunk/dotnet/JBMClientTest/JBMClientTest.userprefs
   trunk/dotnet/JBMClientTest/Properties/
   trunk/dotnet/JBMClientTest/Properties/AssemblyInfo.cs
   trunk/dotnet/JBMClientTest/util/
   trunk/dotnet/JBMClientTest/util/JBMTest.cs
   trunk/dotnet/JBMClientTest/util/SimpleStringTest.cs
   trunk/dotnet/JSMClient.vsmdi
   trunk/dotnet/LocalTestRun.testrunconfig
   trunk/dotnet/README.txt
Log:
reverting commit from 5825 (Placing .NET back)

Copied: trunk/dotnet (from rev 5824, trunk/dotnet)

Copied: trunk/dotnet/JBMClient (from rev 5824, trunk/dotnet/JBMClient)


Property changes on: trunk/dotnet/JBMClient
___________________________________________________________________
Name: svn:ignore
   + bin
obj


Deleted: trunk/dotnet/JBMClient/JBM.Client.csproj
===================================================================
--- trunk/dotnet/JBMClient/JBM.Client.csproj	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/JBM.Client.csproj	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,90 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<Project ToolsVersion="3.5" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
-  <PropertyGroup>
-    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
-    <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
-    <ProductVersion>9.0.21022</ProductVersion>
-    <SchemaVersion>2.0</SchemaVersion>
-    <ProjectGuid>{675AD929-BF42-4930-AC39-603D5EC52D58}</ProjectGuid>
-    <OutputType>Library</OutputType>
-    <AppDesignerFolder>Properties</AppDesignerFolder>
-    <RootNamespace>JBM.Client</RootNamespace>
-    <AssemblyName>JBM.Client</AssemblyName>
-    <TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
-    <FileAlignment>512</FileAlignment>
-  </PropertyGroup>
-  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
-    <DebugSymbols>true</DebugSymbols>
-    <DebugType>full</DebugType>
-    <Optimize>false</Optimize>
-    <OutputPath>bin\Debug\</OutputPath>
-    <DefineConstants>DEBUG;TRACE</DefineConstants>
-    <ErrorReport>prompt</ErrorReport>
-    <WarningLevel>4</WarningLevel>
-    <OutputType>Library</OutputType>
-    <AssemblyName>JBMClient</AssemblyName>
-    <RootNamespace>JBMClient</RootNamespace>
-    <AllowUnsafeBlocks>false</AllowUnsafeBlocks>
-    <CheckForOverflowUnderflow>true</CheckForOverflowUnderflow>
-  </PropertyGroup>
-  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
-    <DebugType>pdbonly</DebugType>
-    <Optimize>true</Optimize>
-    <OutputPath>bin\Release\</OutputPath>
-    <DefineConstants>TRACE</DefineConstants>
-    <ErrorReport>prompt</ErrorReport>
-    <WarningLevel>4</WarningLevel>
-    <OutputType>Library</OutputType>
-    <AssemblyName>JBMClient</AssemblyName>
-    <DebugSymbols>true</DebugSymbols>
-    <RootNamespace>JBMClient</RootNamespace>
-    <AllowUnsafeBlocks>false</AllowUnsafeBlocks>
-    <CheckForOverflowUnderflow>true</CheckForOverflowUnderflow>
-  </PropertyGroup>
-  <ItemGroup>
-    <Reference Include="System" />
-    <Reference Include="System.Core">
-      <RequiredTargetFramework>3.5</RequiredTargetFramework>
-    </Reference>
-    <Reference Include="System.Xml.Linq">
-      <RequiredTargetFramework>3.5</RequiredTargetFramework>
-    </Reference>
-    <Reference Include="System.Data.DataSetExtensions">
-      <RequiredTargetFramework>3.5</RequiredTargetFramework>
-    </Reference>
-    <Reference Include="System.Data" />
-    <Reference Include="System.Xml" />
-  </ItemGroup>
-  <ItemGroup>
-    <Compile Include="exception\MessagingException.cs" />
-    <Compile Include="Properties\AssemblyInfo.cs" />
-    <Compile Include="remoting\Channel.cs" />
-    <Compile Include="remoting\ChannelHandler.cs" />
-    <Compile Include="util\DataConstants.cs" />
-    <Compile Include="util\SimpleString.cs" />
-  </ItemGroup>
-  <ItemGroup>
-    <Compile Include="remoting\FailureListener.cs" />
-    <Compile Include="remoting\Interceptor.cs" />
-    <Compile Include="remoting\Packet.cs" />
-  </ItemGroup>
-  <ItemGroup>
-    <Compile Include="remoting\RemotingConnection.cs" />
-    <Content Include="remoting\spi\Acceptor.java" />
-    <Content Include="remoting\spi\AcceptorFactory.java" />
-    <Compile Include="remoting\spi\BufferHandler.cs" />
-    <Content Include="remoting\spi\Connection.java" />
-    <Content Include="remoting\spi\ConnectionLifeCycleListener.java" />
-    <Content Include="remoting\spi\Connector.java" />
-    <Content Include="remoting\spi\ConnectorFactory.java" />
-    <Compile Include="remoting\spi\MessagingBuffer.cs" />
-  </ItemGroup>
-  <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
-  <!-- To modify your build process, add your task inside one of the targets below and uncomment it. 
-       Other similar extension points exist, see Microsoft.Common.targets.
-  <Target Name="BeforeBuild">
-  </Target>
-  <Target Name="AfterBuild">
-  </Target>
-  -->
-</Project>
\ No newline at end of file

Copied: trunk/dotnet/JBMClient/JBM.Client.csproj (from rev 5824, trunk/dotnet/JBMClient/JBM.Client.csproj)
===================================================================
--- trunk/dotnet/JBMClient/JBM.Client.csproj	                        (rev 0)
+++ trunk/dotnet/JBMClient/JBM.Client.csproj	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,90 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="3.5" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <PropertyGroup>
+    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
+    <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
+    <ProductVersion>9.0.21022</ProductVersion>
+    <SchemaVersion>2.0</SchemaVersion>
+    <ProjectGuid>{675AD929-BF42-4930-AC39-603D5EC52D58}</ProjectGuid>
+    <OutputType>Library</OutputType>
+    <AppDesignerFolder>Properties</AppDesignerFolder>
+    <RootNamespace>JBM.Client</RootNamespace>
+    <AssemblyName>JBM.Client</AssemblyName>
+    <TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
+    <FileAlignment>512</FileAlignment>
+  </PropertyGroup>
+  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
+    <DebugSymbols>true</DebugSymbols>
+    <DebugType>full</DebugType>
+    <Optimize>false</Optimize>
+    <OutputPath>bin\Debug\</OutputPath>
+    <DefineConstants>DEBUG;TRACE</DefineConstants>
+    <ErrorReport>prompt</ErrorReport>
+    <WarningLevel>4</WarningLevel>
+    <OutputType>Library</OutputType>
+    <AssemblyName>JBMClient</AssemblyName>
+    <RootNamespace>JBMClient</RootNamespace>
+    <AllowUnsafeBlocks>false</AllowUnsafeBlocks>
+    <CheckForOverflowUnderflow>true</CheckForOverflowUnderflow>
+  </PropertyGroup>
+  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
+    <DebugType>pdbonly</DebugType>
+    <Optimize>true</Optimize>
+    <OutputPath>bin\Release\</OutputPath>
+    <DefineConstants>TRACE</DefineConstants>
+    <ErrorReport>prompt</ErrorReport>
+    <WarningLevel>4</WarningLevel>
+    <OutputType>Library</OutputType>
+    <AssemblyName>JBMClient</AssemblyName>
+    <DebugSymbols>true</DebugSymbols>
+    <RootNamespace>JBMClient</RootNamespace>
+    <AllowUnsafeBlocks>false</AllowUnsafeBlocks>
+    <CheckForOverflowUnderflow>true</CheckForOverflowUnderflow>
+  </PropertyGroup>
+  <ItemGroup>
+    <Reference Include="System" />
+    <Reference Include="System.Core">
+      <RequiredTargetFramework>3.5</RequiredTargetFramework>
+    </Reference>
+    <Reference Include="System.Xml.Linq">
+      <RequiredTargetFramework>3.5</RequiredTargetFramework>
+    </Reference>
+    <Reference Include="System.Data.DataSetExtensions">
+      <RequiredTargetFramework>3.5</RequiredTargetFramework>
+    </Reference>
+    <Reference Include="System.Data" />
+    <Reference Include="System.Xml" />
+  </ItemGroup>
+  <ItemGroup>
+    <Compile Include="exception\MessagingException.cs" />
+    <Compile Include="Properties\AssemblyInfo.cs" />
+    <Compile Include="remoting\Channel.cs" />
+    <Compile Include="remoting\ChannelHandler.cs" />
+    <Compile Include="util\DataConstants.cs" />
+    <Compile Include="util\SimpleString.cs" />
+  </ItemGroup>
+  <ItemGroup>
+    <Compile Include="remoting\FailureListener.cs" />
+    <Compile Include="remoting\Interceptor.cs" />
+    <Compile Include="remoting\Packet.cs" />
+  </ItemGroup>
+  <ItemGroup>
+    <Compile Include="remoting\RemotingConnection.cs" />
+    <Content Include="remoting\spi\Acceptor.java" />
+    <Content Include="remoting\spi\AcceptorFactory.java" />
+    <Compile Include="remoting\spi\BufferHandler.cs" />
+    <Content Include="remoting\spi\Connection.java" />
+    <Content Include="remoting\spi\ConnectionLifeCycleListener.java" />
+    <Content Include="remoting\spi\Connector.java" />
+    <Content Include="remoting\spi\ConnectorFactory.java" />
+    <Compile Include="remoting\spi\MessagingBuffer.cs" />
+  </ItemGroup>
+  <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
+  <!-- To modify your build process, add your task inside one of the targets below and uncomment it. 
+       Other similar extension points exist, see Microsoft.Common.targets.
+  <Target Name="BeforeBuild">
+  </Target>
+  <Target Name="AfterBuild">
+  </Target>
+  -->
+</Project>
\ No newline at end of file

Copied: trunk/dotnet/JBMClient/Properties (from rev 5824, trunk/dotnet/JBMClient/Properties)

Deleted: trunk/dotnet/JBMClient/Properties/AssemblyInfo.cs
===================================================================
--- trunk/dotnet/JBMClient/Properties/AssemblyInfo.cs	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/Properties/AssemblyInfo.cs	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,36 +0,0 @@
-using System.Reflection;
-using System.Runtime.CompilerServices;
-using System.Runtime.InteropServices;
-
-// General Information about an assembly is controlled through the following 
-// set of attributes. Change these attribute values to modify the information
-// associated with an assembly.
-[assembly: AssemblyTitle("JSMClient")]
-[assembly: AssemblyDescription("")]
-[assembly: AssemblyConfiguration("")]
-[assembly: AssemblyCompany("")]
-[assembly: AssemblyProduct("JSMClient")]
-[assembly: AssemblyCopyright("Copyright ©  2009")]
-[assembly: AssemblyTrademark("")]
-[assembly: AssemblyCulture("")]
-
-// Setting ComVisible to false makes the types in this assembly not visible 
-// to COM components.  If you need to access a type in this assembly from 
-// COM, set the ComVisible attribute to true on that type.
-[assembly: ComVisible(false)]
-
-// The following GUID is for the ID of the typelib if this project is exposed to COM
-[assembly: Guid("e865a084-f8a8-4d0d-b286-2c023ce93e80")]
-
-// Version information for an assembly consists of the following four values:
-//
-//      Major Version
-//      Minor Version 
-//      Build Number
-//      Revision
-//
-// You can specify all the values or you can default the Build and Revision Numbers 
-// by using the '*' as shown below:
-// [assembly: AssemblyVersion("1.0.*")]
-[assembly: AssemblyVersion("1.0.0.0")]
-[assembly: AssemblyFileVersion("1.0.0.0")]

Copied: trunk/dotnet/JBMClient/Properties/AssemblyInfo.cs (from rev 5824, trunk/dotnet/JBMClient/Properties/AssemblyInfo.cs)
===================================================================
--- trunk/dotnet/JBMClient/Properties/AssemblyInfo.cs	                        (rev 0)
+++ trunk/dotnet/JBMClient/Properties/AssemblyInfo.cs	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,36 @@
+using System.Reflection;
+using System.Runtime.CompilerServices;
+using System.Runtime.InteropServices;
+
+// General Information about an assembly is controlled through the following 
+// set of attributes. Change these attribute values to modify the information
+// associated with an assembly.
+[assembly: AssemblyTitle("JSMClient")]
+[assembly: AssemblyDescription("")]
+[assembly: AssemblyConfiguration("")]
+[assembly: AssemblyCompany("")]
+[assembly: AssemblyProduct("JSMClient")]
+[assembly: AssemblyCopyright("Copyright ©  2009")]
+[assembly: AssemblyTrademark("")]
+[assembly: AssemblyCulture("")]
+
+// Setting ComVisible to false makes the types in this assembly not visible 
+// to COM components.  If you need to access a type in this assembly from 
+// COM, set the ComVisible attribute to true on that type.
+[assembly: ComVisible(false)]
+
+// The following GUID is for the ID of the typelib if this project is exposed to COM
+[assembly: Guid("e865a084-f8a8-4d0d-b286-2c023ce93e80")]
+
+// Version information for an assembly consists of the following four values:
+//
+//      Major Version
+//      Minor Version 
+//      Build Number
+//      Revision
+//
+// You can specify all the values or you can default the Build and Revision Numbers 
+// by using the '*' as shown below:
+// [assembly: AssemblyVersion("1.0.*")]
+[assembly: AssemblyVersion("1.0.0.0")]
+[assembly: AssemblyFileVersion("1.0.0.0")]

Copied: trunk/dotnet/JBMClient/exception (from rev 5824, trunk/dotnet/JBMClient/exception)

Deleted: trunk/dotnet/JBMClient/exception/MessagingException.cs
===================================================================
--- trunk/dotnet/JBMClient/exception/MessagingException.cs	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/exception/MessagingException.cs	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,77 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-
-namespace JBoss.JBM.Client.exception
-{
-    public class MessagingException : Exception
-    {
-        // Error codes -------------------------------------------------
-
-        public const int INTERNAL_ERROR = 000;
-
-        public const int UNSUPPORTED_PACKET = 001;
-
-        public const int NOT_CONNECTED = 002;
-
-        public const int CONNECTION_TIMEDOUT = 003;
-
-        public const int INTERRUPTED = 004;
-
-
-        public const int QUEUE_DOES_NOT_EXIST = 100;
-
-        public const int QUEUE_EXISTS = 101;
-
-        public const int OBJECT_CLOSED = 102;
-
-        public const int INVALID_FILTER_EXPRESSION = 103;
-
-        public const int ILLEGAL_STATE = 104;
-
-        public const int SECURITY_EXCEPTION = 105;
-
-        public const int ADDRESS_DOES_NOT_EXIST = 106;
-
-        public const int ADDRESS_EXISTS = 107;
-
-        public const int INCOMPATIBLE_CLIENT_SERVER_VERSIONS = 108;
-
-        public const int SESSION_EXISTS = 109;
-
-        private int code;
-
-        public MessagingException()
-        {
-        }
-
-        public MessagingException(int code)
-        {
-            this.code = code;
-        }
-
-        public MessagingException(int code, String msg)
-            : base(msg)
-        {
-            this.code = code;
-        }
-
-        public MessagingException(int code, String msg, Exception cause)
-            : base(msg, cause)
-        {
-            this.code = code;
-        }
-
-        public int getCode()
-        {
-            return code;
-        }
-
-        public String toString()
-        {
-            return "MessagingException[errorCode=" + code + " message=" + this.Message + "]";
-        }
-
-    }
-}

Copied: trunk/dotnet/JBMClient/exception/MessagingException.cs (from rev 5824, trunk/dotnet/JBMClient/exception/MessagingException.cs)
===================================================================
--- trunk/dotnet/JBMClient/exception/MessagingException.cs	                        (rev 0)
+++ trunk/dotnet/JBMClient/exception/MessagingException.cs	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,77 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+
+namespace JBoss.JBM.Client.exception
+{
+    public class MessagingException : Exception
+    {
+        // Error codes -------------------------------------------------
+
+        public const int INTERNAL_ERROR = 000;
+
+        public const int UNSUPPORTED_PACKET = 001;
+
+        public const int NOT_CONNECTED = 002;
+
+        public const int CONNECTION_TIMEDOUT = 003;
+
+        public const int INTERRUPTED = 004;
+
+
+        public const int QUEUE_DOES_NOT_EXIST = 100;
+
+        public const int QUEUE_EXISTS = 101;
+
+        public const int OBJECT_CLOSED = 102;
+
+        public const int INVALID_FILTER_EXPRESSION = 103;
+
+        public const int ILLEGAL_STATE = 104;
+
+        public const int SECURITY_EXCEPTION = 105;
+
+        public const int ADDRESS_DOES_NOT_EXIST = 106;
+
+        public const int ADDRESS_EXISTS = 107;
+
+        public const int INCOMPATIBLE_CLIENT_SERVER_VERSIONS = 108;
+
+        public const int SESSION_EXISTS = 109;
+
+        private int code;
+
+        public MessagingException()
+        {
+        }
+
+        public MessagingException(int code)
+        {
+            this.code = code;
+        }
+
+        public MessagingException(int code, String msg)
+            : base(msg)
+        {
+            this.code = code;
+        }
+
+        public MessagingException(int code, String msg, Exception cause)
+            : base(msg, cause)
+        {
+            this.code = code;
+        }
+
+        public int getCode()
+        {
+            return code;
+        }
+
+        public String toString()
+        {
+            return "MessagingException[errorCode=" + code + " message=" + this.Message + "]";
+        }
+
+    }
+}

Copied: trunk/dotnet/JBMClient/remoting (from rev 5824, trunk/dotnet/JBMClient/remoting)

Deleted: trunk/dotnet/JBMClient/remoting/Acceptor.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/Acceptor.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/Acceptor.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,37 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.spi;
-
-import org.jboss.messaging.core.server.MessagingComponent;
-
-/**
- * An Acceptor is used tby the Remoting Service to allow clients to connect. It should take care of dispatchin client requests
- * to the Remoting Service's Dispatcher.
- *
- * @author <a href="ataylor at redhat.com">Andy Taylor</a>
- * @author <a href="tim.fox at jboss.com">Tim Fox</a>
- */
-public interface Acceptor extends MessagingComponent
-{
-   void stop();
-}

Copied: trunk/dotnet/JBMClient/remoting/Acceptor.java (from rev 5824, trunk/dotnet/JBMClient/remoting/Acceptor.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/Acceptor.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/Acceptor.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,37 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.spi;
+
+import org.jboss.messaging.core.server.MessagingComponent;
+
+/**
+ * An Acceptor is used tby the Remoting Service to allow clients to connect. It should take care of dispatchin client requests
+ * to the Remoting Service's Dispatcher.
+ *
+ * @author <a href="ataylor at redhat.com">Andy Taylor</a>
+ * @author <a href="tim.fox at jboss.com">Tim Fox</a>
+ */
+public interface Acceptor extends MessagingComponent
+{
+   void stop();
+}

Deleted: trunk/dotnet/JBMClient/remoting/AcceptorFactory.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/AcceptorFactory.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/AcceptorFactory.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,36 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.spi;
-
-import java.util.Map;
-
-/**
- * @author <a href="ataylor at redhat.com">Andy Taylor</a>
- * @author <a href="tim.fox at jboss.com">Tim Fox</a>
- */
-public interface AcceptorFactory
-{
-   Acceptor createAcceptor(final Map<String, Object> configuration,
-                           BufferHandler handler,                        
-                           ConnectionLifeCycleListener listener);
-}

Copied: trunk/dotnet/JBMClient/remoting/AcceptorFactory.java (from rev 5824, trunk/dotnet/JBMClient/remoting/AcceptorFactory.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/AcceptorFactory.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/AcceptorFactory.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,36 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.spi;
+
+import java.util.Map;
+
+/**
+ * @author <a href="ataylor at redhat.com">Andy Taylor</a>
+ * @author <a href="tim.fox at jboss.com">Tim Fox</a>
+ */
+public interface AcceptorFactory
+{
+   Acceptor createAcceptor(final Map<String, Object> configuration,
+                           BufferHandler handler,                        
+                           ConnectionLifeCycleListener listener);
+}

Deleted: trunk/dotnet/JBMClient/remoting/BufferHandler.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/BufferHandler.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/BufferHandler.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,35 +0,0 @@
-/*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt in the distribution for a
-  * full listing of individual contributors.
-  *
-  * This is free software; you can redistribute it and/or modify it
-  * under the terms of the GNU Lesser General Public License as
-  * published by the Free Software Foundation; either version 2.1 of
-  * the License, or (at your option) any later version.
-  *
-  * This software is distributed in the hope that it will be useful,
-  * but WITHOUT ANY WARRANTY; without even the implied warranty of
-  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-  * Lesser General Public License for more details.
-  *
-  * You should have received a copy of the GNU Lesser General Public
-  * License along with this software; if not, write to the Free
-  * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-  * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-  */
-package org.jboss.messaging.core.remoting.spi;
-
-/**
- * A BufferHandler
- * 
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- *
- */
-public interface BufferHandler
-{
-   void bufferReceived(Object connectionID, MessagingBuffer buffer);
-   
-   int isReadyToHandle(MessagingBuffer buffer);
-}

Copied: trunk/dotnet/JBMClient/remoting/BufferHandler.java (from rev 5824, trunk/dotnet/JBMClient/remoting/BufferHandler.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/BufferHandler.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/BufferHandler.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,35 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt in the distribution for a
+  * full listing of individual contributors.
+  *
+  * This is free software; you can redistribute it and/or modify it
+  * under the terms of the GNU Lesser General Public License as
+  * published by the Free Software Foundation; either version 2.1 of
+  * the License, or (at your option) any later version.
+  *
+  * This software is distributed in the hope that it will be useful,
+  * but WITHOUT ANY WARRANTY; without even the implied warranty of
+  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+  * Lesser General Public License for more details.
+  *
+  * You should have received a copy of the GNU Lesser General Public
+  * License along with this software; if not, write to the Free
+  * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+  * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+  */
+package org.jboss.messaging.core.remoting.spi;
+
+/**
+ * A BufferHandler
+ * 
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ *
+ */
+public interface BufferHandler
+{
+   void bufferReceived(Object connectionID, MessagingBuffer buffer);
+   
+   int isReadyToHandle(MessagingBuffer buffer);
+}

Deleted: trunk/dotnet/JBMClient/remoting/Channel.cs
===================================================================
--- trunk/dotnet/JBMClient/remoting/Channel.cs	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/Channel.cs	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,78 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source Copyright 2005, JBoss Inc., and individual contributors as indicated by the
- * @authors tag. See the copyright.txt in the distribution for a full listing of individual contributors. This is free
- * software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version.
- * This software is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
- * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
- * details. You should have received a copy of the GNU Lesser General Public License along with this software; if not,
- * write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA, or see the FSF
- * site: http://www.fsf.org.
- */
-namespace JBoss.JBM.Client.remoting
-{
-
-
-    /**
-     * A Channel A Channel *does not* support concurrent access by more than one thread!
-     * 
-     * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
-     */
-    public interface Channel
-    {
-        long ID
-        {
-            get;
-        }
-
-        object Lock
-        {
-            get;
-        }
-
-        ChannelHandler Handler
-        {
-            set;
-        }
-
-
-        Channel ReplicatingChannel
-        {
-            get;
-        }
-
-        int LastReceivedCommandID
-        {
-            get;
-        }
-
-
-        void Send(Packet packet);
-
-        Packet SendBlocking(Packet packet);
-
-        // This is only used on server.
-        // Verify if there are possible future use for this
-        //DelayedResult PeplicatePacket(Packet packet);
-
-        //void ReplicateComplete();
-
-        void Close();
-
-        void TransferConnection(RemotingConnection newConnection);
-
-        void ReplayCommands(int lastReceivedCommandID);
-
-        void DoLock();
-
-        void DoUnlock();
-
-        void ReturnBlocking();
-
-        RemotingConnection getConnection();
-
-        void ReplicatingChannelDead();
-
-        void Confirm(Packet packet);
-    }
-}
\ No newline at end of file

Copied: trunk/dotnet/JBMClient/remoting/Channel.cs (from rev 5824, trunk/dotnet/JBMClient/remoting/Channel.cs)
===================================================================
--- trunk/dotnet/JBMClient/remoting/Channel.cs	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/Channel.cs	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,78 @@
+/*
+ * JBoss, Home of Professional Open Source Copyright 2005, JBoss Inc., and individual contributors as indicated by the
+ * @authors tag. See the copyright.txt in the distribution for a full listing of individual contributors. This is free
+ * software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version.
+ * This software is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
+ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
+ * details. You should have received a copy of the GNU Lesser General Public License along with this software; if not,
+ * write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA, or see the FSF
+ * site: http://www.fsf.org.
+ */
+namespace JBoss.JBM.Client.remoting
+{
+
+
+    /**
+     * A Channel A Channel *does not* support concurrent access by more than one thread!
+     * 
+     * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+     */
+    public interface Channel
+    {
+        long ID
+        {
+            get;
+        }
+
+        object Lock
+        {
+            get;
+        }
+
+        ChannelHandler Handler
+        {
+            set;
+        }
+
+
+        Channel ReplicatingChannel
+        {
+            get;
+        }
+
+        int LastReceivedCommandID
+        {
+            get;
+        }
+
+
+        void Send(Packet packet);
+
+        Packet SendBlocking(Packet packet);
+
+        // This is only used on server.
+        // Verify if there are possible future use for this
+        //DelayedResult PeplicatePacket(Packet packet);
+
+        //void ReplicateComplete();
+
+        void Close();
+
+        void TransferConnection(RemotingConnection newConnection);
+
+        void ReplayCommands(int lastReceivedCommandID);
+
+        void DoLock();
+
+        void DoUnlock();
+
+        void ReturnBlocking();
+
+        RemotingConnection getConnection();
+
+        void ReplicatingChannelDead();
+
+        void Confirm(Packet packet);
+    }
+}
\ No newline at end of file

Deleted: trunk/dotnet/JBMClient/remoting/ChannelHandler.cs
===================================================================
--- trunk/dotnet/JBMClient/remoting/ChannelHandler.cs	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/ChannelHandler.cs	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,34 +0,0 @@
-/*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt in the distribution for a
-  * full listing of individual contributors.
-  *
-  * This is free software; you can redistribute it and/or modify it
-  * under the terms of the GNU Lesser General Public License as
-  * published by the Free Software Foundation; either version 2.1 of
-  * the License, or (at your option) any later version.
-  *
-  * This software is distributed in the hope that it will be useful,
-  * but WITHOUT ANY WARRANTY; without even the implied warranty of
-  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-  * Lesser General Public License for more details.
-  *
-  * You should have received a copy of the GNU Lesser General Public
-  * License along with this software; if not, write to the Free
-  * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-  * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-  */
-namespace JBoss.JBM.Client.remoting
-{
-    /**
-     * A ChannelHandler
-     * 
-     * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
-     *
-     */
-    public interface ChannelHandler
-    {
-        void HandlePacket(Packet packet);
-    }
-}
\ No newline at end of file

Copied: trunk/dotnet/JBMClient/remoting/ChannelHandler.cs (from rev 5824, trunk/dotnet/JBMClient/remoting/ChannelHandler.cs)
===================================================================
--- trunk/dotnet/JBMClient/remoting/ChannelHandler.cs	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/ChannelHandler.cs	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,34 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt in the distribution for a
+  * full listing of individual contributors.
+  *
+  * This is free software; you can redistribute it and/or modify it
+  * under the terms of the GNU Lesser General Public License as
+  * published by the Free Software Foundation; either version 2.1 of
+  * the License, or (at your option) any later version.
+  *
+  * This software is distributed in the hope that it will be useful,
+  * but WITHOUT ANY WARRANTY; without even the implied warranty of
+  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+  * Lesser General Public License for more details.
+  *
+  * You should have received a copy of the GNU Lesser General Public
+  * License along with this software; if not, write to the Free
+  * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+  * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+  */
+namespace JBoss.JBM.Client.remoting
+{
+    /**
+     * A ChannelHandler
+     * 
+     * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+     *
+     */
+    public interface ChannelHandler
+    {
+        void HandlePacket(Packet packet);
+    }
+}
\ No newline at end of file

Deleted: trunk/dotnet/JBMClient/remoting/Connection.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/Connection.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/Connection.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,45 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-
-package org.jboss.messaging.core.remoting.spi;
-
-
-
-/**
- *
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- *
- * @version <tt>$Revision$</tt>
- *
- */
-public interface Connection
-{
-   MessagingBuffer createBuffer(int size);
-
-   Object getID();
-
-   void write(MessagingBuffer buffer);
-
-   void close();
-
-   String getRemoteAddress();
-}
\ No newline at end of file

Copied: trunk/dotnet/JBMClient/remoting/Connection.java (from rev 5824, trunk/dotnet/JBMClient/remoting/Connection.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/Connection.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/Connection.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,45 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+
+package org.jboss.messaging.core.remoting.spi;
+
+
+
+/**
+ *
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ *
+ * @version <tt>$Revision$</tt>
+ *
+ */
+public interface Connection
+{
+   MessagingBuffer createBuffer(int size);
+
+   Object getID();
+
+   void write(MessagingBuffer buffer);
+
+   void close();
+
+   String getRemoteAddress();
+}
\ No newline at end of file

Deleted: trunk/dotnet/JBMClient/remoting/ConnectionLifeCycleListener.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/ConnectionLifeCycleListener.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/ConnectionLifeCycleListener.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,40 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.messaging.core.remoting.spi;
-
-import org.jboss.messaging.core.exception.MessagingException;
-
-/**
- *
- * A ConnectionLifeCycleListener
- *
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- *
- */
-public interface ConnectionLifeCycleListener
-{
-   void connectionCreated(Connection connection);
-
-   void connectionDestroyed(Object connectionID);
-
-   void connectionException(Object connectionID, MessagingException me);
-}

Copied: trunk/dotnet/JBMClient/remoting/ConnectionLifeCycleListener.java (from rev 5824, trunk/dotnet/JBMClient/remoting/ConnectionLifeCycleListener.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/ConnectionLifeCycleListener.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/ConnectionLifeCycleListener.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,40 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.messaging.core.remoting.spi;
+
+import org.jboss.messaging.core.exception.MessagingException;
+
+/**
+ *
+ * A ConnectionLifeCycleListener
+ *
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ *
+ */
+public interface ConnectionLifeCycleListener
+{
+   void connectionCreated(Connection connection);
+
+   void connectionDestroyed(Object connectionID);
+
+   void connectionException(Object connectionID, MessagingException me);
+}

Deleted: trunk/dotnet/JBMClient/remoting/Connector.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/Connector.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/Connector.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,48 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.messaging.core.remoting.spi;
-
-/**
- * 
- * A Connector
- * 
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- *
- */
-public interface Connector
-{
-   void start();
-   
-   void close();
-   
-   boolean isStarted();
-   
-   /**
-    * Create and return a connection from this connector.
-    * 
-    * This method must NOT throw an exception if it fails to create the connection
-    * (e.g. network is not available), in this case it MUST return null
-    * 
-    * @return The connection, or null if unable to create a connection (e.g. network is unavailable)
-    */
-   Connection createConnection();   
-}

Copied: trunk/dotnet/JBMClient/remoting/Connector.java (from rev 5824, trunk/dotnet/JBMClient/remoting/Connector.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/Connector.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/Connector.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,48 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.messaging.core.remoting.spi;
+
+/**
+ * 
+ * A Connector
+ * 
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ *
+ */
+public interface Connector
+{
+   void start();
+   
+   void close();
+   
+   boolean isStarted();
+   
+   /**
+    * Create and return a connection from this connector.
+    * 
+    * This method must NOT throw an exception if it fails to create the connection
+    * (e.g. network is not available), in this case it MUST return null
+    * 
+    * @return The connection, or null if unable to create a connection (e.g. network is unavailable)
+    */
+   Connection createConnection();   
+}

Deleted: trunk/dotnet/JBMClient/remoting/ConnectorFactory.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/ConnectorFactory.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/ConnectorFactory.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,16 +0,0 @@
-package org.jboss.messaging.core.remoting.spi;
-
-import java.util.Map;
-
-/**
- * 
- * A ConnectorFactory
- * 
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- *
- */
-public interface ConnectorFactory
-{
-   Connector createConnector(Map<String, Object> configuration, BufferHandler handler,                           
-                             ConnectionLifeCycleListener listener);
-}

Copied: trunk/dotnet/JBMClient/remoting/ConnectorFactory.java (from rev 5824, trunk/dotnet/JBMClient/remoting/ConnectorFactory.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/ConnectorFactory.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/ConnectorFactory.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,16 @@
+package org.jboss.messaging.core.remoting.spi;
+
+import java.util.Map;
+
+/**
+ * 
+ * A ConnectorFactory
+ * 
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ *
+ */
+public interface ConnectorFactory
+{
+   Connector createConnector(Map<String, Object> configuration, BufferHandler handler,                           
+                             ConnectionLifeCycleListener listener);
+}

Deleted: trunk/dotnet/JBMClient/remoting/FailureListener.cs
===================================================================
--- trunk/dotnet/JBMClient/remoting/FailureListener.cs	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/FailureListener.cs	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,40 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-
-
-namespace JBoss.JBM.Client.remoting
-{
-    using JBoss.JBM.Client.exception;
-
-    /**
-     * 
-     * A FailureListener
-     * 
-     * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
-     * @author <a href="mailto:jmesnil at redhat.com">Jeff Mesnil</a>
-     * 
-     */
-    public interface FailureListener
-    {
-        bool connectionFailed(MessagingException me);
-    }
-}
\ No newline at end of file

Copied: trunk/dotnet/JBMClient/remoting/FailureListener.cs (from rev 5824, trunk/dotnet/JBMClient/remoting/FailureListener.cs)
===================================================================
--- trunk/dotnet/JBMClient/remoting/FailureListener.cs	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/FailureListener.cs	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,40 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+
+
+namespace JBoss.JBM.Client.remoting
+{
+    using JBoss.JBM.Client.exception;
+
+    /**
+     * 
+     * A FailureListener
+     * 
+     * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+     * @author <a href="mailto:jmesnil at redhat.com">Jeff Mesnil</a>
+     * 
+     */
+    public interface FailureListener
+    {
+        bool connectionFailed(MessagingException me);
+    }
+}
\ No newline at end of file

Deleted: trunk/dotnet/JBMClient/remoting/Interceptor.cs
===================================================================
--- trunk/dotnet/JBMClient/remoting/Interceptor.cs	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/Interceptor.cs	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,46 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-
-namespace JBoss.JBM.Client.remoting
-{
-    /**
-     *
-     * This is class is a simple way to intercepting server calls on JBoss Messaging.
-     * 
-     * To Add this interceptor, you have to modify jbm-configuration.xml
-     * 
-     * @author clebert.suconic at jboss.com
-     * @author tim.fox at jboss.com
-     */
-    public interface Interceptor
-    {
-        /**
-         * 
-         * @param packet
-         * @param connection
-         * @return true to process the next interceptor and handle the packet,
-         *         false to abort processing of the packet
-         * @throws MessagingException
-         */
-        bool intercept(Packet packet, RemotingConnection connection);
-    }
-}
\ No newline at end of file

Copied: trunk/dotnet/JBMClient/remoting/Interceptor.cs (from rev 5824, trunk/dotnet/JBMClient/remoting/Interceptor.cs)
===================================================================
--- trunk/dotnet/JBMClient/remoting/Interceptor.cs	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/Interceptor.cs	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,46 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+
+namespace JBoss.JBM.Client.remoting
+{
+    /**
+     *
+     * This is class is a simple way to intercepting server calls on JBoss Messaging.
+     * 
+     * To Add this interceptor, you have to modify jbm-configuration.xml
+     * 
+     * @author clebert.suconic at jboss.com
+     * @author tim.fox at jboss.com
+     */
+    public interface Interceptor
+    {
+        /**
+         * 
+         * @param packet
+         * @param connection
+         * @return true to process the next interceptor and handle the packet,
+         *         false to abort processing of the packet
+         * @throws MessagingException
+         */
+        bool intercept(Packet packet, RemotingConnection connection);
+    }
+}
\ No newline at end of file

Deleted: trunk/dotnet/JBMClient/remoting/MessagingBuffer.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/MessagingBuffer.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/MessagingBuffer.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,125 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-
-package org.jboss.messaging.core.remoting.spi;
-
-import org.jboss.messaging.util.SimpleString;
-
-/**
- *
- * A MessagingBuffer
- *
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- *
- */
-public interface MessagingBuffer
-{
-   void putByte(byte val);
-
-   void putBytes(byte[] bytes);
-
-   void putBytes(byte[] bytes, int offset, int length);
-
-   void putInt(int val);
-
-   void putInt(int pos, int val);
-
-   void putLong(long val);
-
-   void putShort(short val);
-
-   void putDouble(double val);
-
-   void putFloat(float val);
-
-   void putBoolean(boolean val);
-
-   void putChar(char val);
-
-   void putNullableString(String val);
-
-   void putString(String val);
-
-   void putSimpleString(SimpleString val);
-
-   void putNullableSimpleString(SimpleString val);
-
-   void putUTF(String utf) throws Exception;
-
-   byte getByte();
-
-   short getUnsignedByte();
-
-   void getBytes(byte[] bytes);
-
-   void getBytes(byte[] bytes, int offset, int length);
-
-   int getInt();
-
-   long getLong();
-
-   short getShort();
-
-   int getUnsignedShort();
-
-   double getDouble();
-
-   float getFloat();
-
-   boolean getBoolean();
-
-   char getChar();
-
-   String getString();
-
-   String getNullableString();
-
-   SimpleString getSimpleString();
-
-   SimpleString getNullableSimpleString();
-
-   String getUTF() throws Exception;
-
-   byte[] array();
-
-   int remaining();
-
-   int capacity();
-
-   int limit();
-
-   void limit(int limit);
-
-   void flip();
-
-   void position(int position);
-
-   int position();
-
-   void rewind();
-
-   MessagingBuffer slice();
-
-   MessagingBuffer createNewBuffer(int len);
-
-   Object getUnderlyingBuffer();
-}

Copied: trunk/dotnet/JBMClient/remoting/MessagingBuffer.java (from rev 5824, trunk/dotnet/JBMClient/remoting/MessagingBuffer.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/MessagingBuffer.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/MessagingBuffer.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,125 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+
+package org.jboss.messaging.core.remoting.spi;
+
+import org.jboss.messaging.util.SimpleString;
+
+/**
+ *
+ * A MessagingBuffer
+ *
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ *
+ */
+public interface MessagingBuffer
+{
+   void putByte(byte val);
+
+   void putBytes(byte[] bytes);
+
+   void putBytes(byte[] bytes, int offset, int length);
+
+   void putInt(int val);
+
+   void putInt(int pos, int val);
+
+   void putLong(long val);
+
+   void putShort(short val);
+
+   void putDouble(double val);
+
+   void putFloat(float val);
+
+   void putBoolean(boolean val);
+
+   void putChar(char val);
+
+   void putNullableString(String val);
+
+   void putString(String val);
+
+   void putSimpleString(SimpleString val);
+
+   void putNullableSimpleString(SimpleString val);
+
+   void putUTF(String utf) throws Exception;
+
+   byte getByte();
+
+   short getUnsignedByte();
+
+   void getBytes(byte[] bytes);
+
+   void getBytes(byte[] bytes, int offset, int length);
+
+   int getInt();
+
+   long getLong();
+
+   short getShort();
+
+   int getUnsignedShort();
+
+   double getDouble();
+
+   float getFloat();
+
+   boolean getBoolean();
+
+   char getChar();
+
+   String getString();
+
+   String getNullableString();
+
+   SimpleString getSimpleString();
+
+   SimpleString getNullableSimpleString();
+
+   String getUTF() throws Exception;
+
+   byte[] array();
+
+   int remaining();
+
+   int capacity();
+
+   int limit();
+
+   void limit(int limit);
+
+   void flip();
+
+   void position(int position);
+
+   int position();
+
+   void rewind();
+
+   MessagingBuffer slice();
+
+   MessagingBuffer createNewBuffer(int len);
+
+   Object getUnderlyingBuffer();
+}

Deleted: trunk/dotnet/JBMClient/remoting/Packet.cs
===================================================================
--- trunk/dotnet/JBMClient/remoting/Packet.cs	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/Packet.cs	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,78 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-
-namespace JBoss.JBM.Client.remoting
-{
-    using JBoss.JBM.Client.remoting.spi;
-
-    /**
-     * 
-     * A Packet
-     * 
-     * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
-     *
-     */
-    public interface Packet
-    {
-        long ChannelID
-        {
-            get;
-            set;
-        }
-
-        bool Response
-        {
-            set;
-            get;
-        }
-
-
-        byte Type
-        {
-            get;
-        }
-
-        int Encode(MessagingBuffer buffer);
-
-        void Decode(MessagingBuffer buffer);
-
-        int PacketSize
-        {
-            get;
-        }
-
-        int RequiredBufferSize
-        {
-            get;
-        }
-
-        bool RequiresConfirmations
-        {
-            get;
-        }
-
-        bool WriteAways
-        {
-            get;
-        }
-    }
-}
\ No newline at end of file

Copied: trunk/dotnet/JBMClient/remoting/Packet.cs (from rev 5824, trunk/dotnet/JBMClient/remoting/Packet.cs)
===================================================================
--- trunk/dotnet/JBMClient/remoting/Packet.cs	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/Packet.cs	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,78 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+
+namespace JBoss.JBM.Client.remoting
+{
+    using JBoss.JBM.Client.remoting.spi;
+
+    /**
+     * 
+     * A Packet
+     * 
+     * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+     *
+     */
+    public interface Packet
+    {
+        long ChannelID
+        {
+            get;
+            set;
+        }
+
+        bool Response
+        {
+            set;
+            get;
+        }
+
+
+        byte Type
+        {
+            get;
+        }
+
+        int Encode(MessagingBuffer buffer);
+
+        void Decode(MessagingBuffer buffer);
+
+        int PacketSize
+        {
+            get;
+        }
+
+        int RequiredBufferSize
+        {
+            get;
+        }
+
+        bool RequiresConfirmations
+        {
+            get;
+        }
+
+        bool WriteAways
+        {
+            get;
+        }
+    }
+}
\ No newline at end of file

Deleted: trunk/dotnet/JBMClient/remoting/RemotingConnection.cs
===================================================================
--- trunk/dotnet/JBMClient/remoting/RemotingConnection.cs	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/RemotingConnection.cs	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,70 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors by
- * the @authors tag. See the copyright.txt in the distribution for a full listing of individual contributors. This is
- * free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version.
- * This software is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
- * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
- * details. You should have received a copy of the GNU Lesser General Public License along with this software; if not,
- * write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA, or see the FSF
- * site: http://www.fsf.org.
- */
-
-namespace JBoss.JBM.Client.remoting
-{
-    using JBoss.JBM.Client.remoting.spi;
-
-    using System.Collections.Generic;
-
-    using JBoss.JBM.Client.exception;
-
-    /**
-     * A RemotingConnection
-     * 
-     * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
-     * @author <a href="mailto:jmesnil at redhat.com">Jeff Mesnil</a>
-     */
-    public interface RemotingConnection : BufferHandler
-    {
-        object getID();
-
-        string RemoteAddress
-        {
-            get;
-        }
-
-        Channel GetChannel(long channelID, int windowSize, bool block);
-
-        long GenerateChannelID();
-
-        void AddFailureListener(FailureListener listener);
-
-        bool RemoveFailureListener(FailureListener listener);
-
-        List<FailureListener> GetFailureListeners();
-
-        void GetFailureListeners(List<FailureListener> listeners);
-
-        MessagingBuffer CreateBuffer(int size);
-
-        void Fail(MessagingException me);
-
-        void Destroy();
-
-        bool IsExpired(long now);
-
-        void StartPinger();
-
-        void SyncIDGeneratorSequence(long id);
-
-        long GetIDGeneratorSequence();
-
-        void Activate();
-
-        void Freeze();
-
-        RemotingConnection GetReplicatingConnection();
-
-        void SetReplicatingConnection(RemotingConnection connection);
-    }
-}
\ No newline at end of file

Copied: trunk/dotnet/JBMClient/remoting/RemotingConnection.cs (from rev 5824, trunk/dotnet/JBMClient/remoting/RemotingConnection.cs)
===================================================================
--- trunk/dotnet/JBMClient/remoting/RemotingConnection.cs	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/RemotingConnection.cs	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,70 @@
+/*
+ * JBoss, Home of Professional Open Source Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors by
+ * the @authors tag. See the copyright.txt in the distribution for a full listing of individual contributors. This is
+ * free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version.
+ * This software is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
+ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
+ * details. You should have received a copy of the GNU Lesser General Public License along with this software; if not,
+ * write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA, or see the FSF
+ * site: http://www.fsf.org.
+ */
+
+namespace JBoss.JBM.Client.remoting
+{
+    using JBoss.JBM.Client.remoting.spi;
+
+    using System.Collections.Generic;
+
+    using JBoss.JBM.Client.exception;
+
+    /**
+     * A RemotingConnection
+     * 
+     * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+     * @author <a href="mailto:jmesnil at redhat.com">Jeff Mesnil</a>
+     */
+    public interface RemotingConnection : BufferHandler
+    {
+        object getID();
+
+        string RemoteAddress
+        {
+            get;
+        }
+
+        Channel GetChannel(long channelID, int windowSize, bool block);
+
+        long GenerateChannelID();
+
+        void AddFailureListener(FailureListener listener);
+
+        bool RemoveFailureListener(FailureListener listener);
+
+        List<FailureListener> GetFailureListeners();
+
+        void GetFailureListeners(List<FailureListener> listeners);
+
+        MessagingBuffer CreateBuffer(int size);
+
+        void Fail(MessagingException me);
+
+        void Destroy();
+
+        bool IsExpired(long now);
+
+        void StartPinger();
+
+        void SyncIDGeneratorSequence(long id);
+
+        long GetIDGeneratorSequence();
+
+        void Activate();
+
+        void Freeze();
+
+        RemotingConnection GetReplicatingConnection();
+
+        void SetReplicatingConnection(RemotingConnection connection);
+    }
+}
\ No newline at end of file

Copied: trunk/dotnet/JBMClient/remoting/impl (from rev 5824, trunk/dotnet/JBMClient/remoting/impl)

Deleted: trunk/dotnet/JBMClient/remoting/impl/AbstractBufferHandler.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/AbstractBufferHandler.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/AbstractBufferHandler.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,53 +0,0 @@
-/*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt in the distribution for a
-  * full listing of individual contributors.
-  *
-  * This is free software; you can redistribute it and/or modify it
-  * under the terms of the GNU Lesser General Public License as
-  * published by the Free Software Foundation; either version 2.1 of
-  * the License, or (at your option) any later version.
-  *
-  * This software is distributed in the hope that it will be useful,
-  * but WITHOUT ANY WARRANTY; without even the implied warranty of
-  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-  * Lesser General Public License for more details.
-  *
-  * You should have received a copy of the GNU Lesser General Public
-  * License along with this software; if not, write to the Free
-  * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-  * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-  */
-package org.jboss.messaging.core.remoting.impl;
-
-import static org.jboss.messaging.util.DataConstants.SIZE_INT;
-
-import org.jboss.messaging.core.remoting.spi.BufferHandler;
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-
-/**
- * A AbstractBufferHandler
- * 
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- *
- */
-public abstract class AbstractBufferHandler implements BufferHandler
-{
-   public int isReadyToHandle(final MessagingBuffer buffer)
-   {
-      if (buffer.remaining() <= SIZE_INT)
-      {
-         return -1;
-      }
-
-      int length = buffer.getInt();
-
-      if (buffer.remaining() < length)
-      {
-         return -1;
-      }
-
-      return length;
-   }
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/AbstractBufferHandler.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/AbstractBufferHandler.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/AbstractBufferHandler.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/AbstractBufferHandler.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,53 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt in the distribution for a
+  * full listing of individual contributors.
+  *
+  * This is free software; you can redistribute it and/or modify it
+  * under the terms of the GNU Lesser General Public License as
+  * published by the Free Software Foundation; either version 2.1 of
+  * the License, or (at your option) any later version.
+  *
+  * This software is distributed in the hope that it will be useful,
+  * but WITHOUT ANY WARRANTY; without even the implied warranty of
+  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+  * Lesser General Public License for more details.
+  *
+  * You should have received a copy of the GNU Lesser General Public
+  * License along with this software; if not, write to the Free
+  * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+  * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+  */
+package org.jboss.messaging.core.remoting.impl;
+
+import static org.jboss.messaging.util.DataConstants.SIZE_INT;
+
+import org.jboss.messaging.core.remoting.spi.BufferHandler;
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+
+/**
+ * A AbstractBufferHandler
+ * 
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ *
+ */
+public abstract class AbstractBufferHandler implements BufferHandler
+{
+   public int isReadyToHandle(final MessagingBuffer buffer)
+   {
+      if (buffer.remaining() <= SIZE_INT)
+      {
+         return -1;
+      }
+
+      int length = buffer.getInt();
+
+      if (buffer.remaining() < length)
+      {
+         return -1;
+      }
+
+      return length;
+   }
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/ByteBufferWrapper.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/ByteBufferWrapper.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/ByteBufferWrapper.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,370 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.impl;
-
-import static org.jboss.messaging.util.DataConstants.FALSE;
-import static org.jboss.messaging.util.DataConstants.NOT_NULL;
-import static org.jboss.messaging.util.DataConstants.NULL;
-import static org.jboss.messaging.util.DataConstants.TRUE;
-
-import java.nio.ByteBuffer;
-import java.nio.CharBuffer;
-import java.nio.charset.Charset;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-import org.jboss.messaging.util.SimpleString;
-
-/**
- * 
- * A ByteBufferWrapper
- * 
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * @author <a href="mailto:ataylor at redhat.com">Andy Taylor</a>
- *
- */
-public class ByteBufferWrapper implements MessagingBuffer
-{
-   private static final Charset utf8 = Charset.forName("UTF-8");
-   	
-	private ByteBuffer buffer;
-	
-	public ByteBufferWrapper(final ByteBuffer buffer)
-	{
-		this.buffer = buffer;
-	}
-	
-	public ByteBuffer getBuffer()
-	{
-	   return buffer;
-	}
-	
-	public byte[] array()
-   {
-      if(buffer.hasArray())
-      {
-         return buffer.array();
-      }
-      else
-      {
-         byte[] b = new byte[buffer.limit()];
-         buffer.get(b);
-         return b;
-      }
-   }
-    
-	public int position()
-	{
-		return buffer.position();
-	}
-	
-	public void position(final int position)
-   {
-   	buffer.position(position);
-   }
-
-	public int capacity()
-	{
-		return buffer.capacity();
-	}
-
-	public void flip()
-	{
-		buffer.flip();
-	}
-	
-	public MessagingBuffer slice()
-   {
-   	return new ByteBufferWrapper(buffer.slice());
-   }
-
-   public MessagingBuffer createNewBuffer(int len)
-   {
-      return new ByteBufferWrapper(ByteBuffer.allocate(len));
-   }
-
-   public void rewind()
-	{
-		buffer.rewind();
-	}
-
-	public boolean getBoolean()
-	{
-		byte b = buffer.get();
-      return (b == TRUE);
-	}
-
-	public byte getByte()
-	{
-		return buffer.get();
-	}
-	
-	public short getUnsignedByte()
-	{
-	   return (short)(buffer.get() & 0xFF);
-	}
-
-	public void getBytes(byte[] bytes)
-	{
-		buffer.get(bytes);
-	}
-	
-	public void getBytes(byte[] bytes, int offset, int length)
-	{
-		buffer.get(bytes, offset, length);
-	}
-
-	public double getDouble()
-	{
-		return buffer.getDouble();
-	}
-
-	public float getFloat()
-	{
-		return buffer.getFloat();
-	}
-
-	public int getInt()
-	{
-		return buffer.getInt();
-	}
-	
-	public long getLong()
-	{
-		return buffer.getLong();
-	}
-
-	public void putNullableString(final String nullableString)
-	{
-		if (nullableString == null)
-		{
-			buffer.put(NULL);
-		}
-		else
-		{
-			buffer.put(NOT_NULL);
-
-			putString(nullableString);
-		}
-	}
-
-	public String getNullableString()
-	{
-		byte check = buffer.get();
-
-		if (check == NULL)
-		{
-			return null;
-		}
-		else
-		{
-			return getString();
-		}
-	}
-
-	public void putString(final String nullableString)
-	{
-		//We don't encode
-
-		buffer.putInt(nullableString.length());
-
-		for (int i = 0; i < nullableString.length(); i++)
-		{
-			buffer.putChar(nullableString.charAt(i));
-		}      
-	}
-	
-	public void putUTF(final String str) throws Exception
-   {
-		//TODO This is quite inefficient - can be improved using a method similar to what MINA IOBuffer does
-		//(putPrefixedString)
-		ByteBuffer bb = utf8.encode(str);
-   	buffer.putInt(bb.limit() - bb.position());
-   	buffer.put(bb);
-   }
-
-	public short getShort()
-	{
-		return buffer.getShort();
-	}
-	
-	public int getUnsignedShort()
-	{
-	   return buffer.getShort() & 0xFFFF;
-	}
-	
-	public char getChar()
-	{
-		return buffer.getChar();
-	}
-
-	public String getString()
-   {
-      int len = buffer.getInt();
-      	
-   	char[] chars = new char[len];
-   	
-      for (int i = 0; i < len; i++)
-      {
-      	chars[i] = buffer.getChar();
-      }
-      
-      return new String(chars);               
-   }
-	
-   public void putSimpleString(final SimpleString string)
-   {
-   	byte[] data = string.getData();
-   	
-   	buffer.putInt(data.length);
-   	buffer.put(data);
-   }
-   
-   public SimpleString getNullableSimpleString()
-   {
-   	int b = buffer.get();
-   	if (b == NULL)
-   	{
-   	   return null;
-   	}
-   	else
-   	{
-         return getSimpleString();
-   	}
-   }
-   
-   public void putNullableSimpleString(final SimpleString string)
-   {
-   	if (string == null)
-   	{
-   		buffer.put(NULL);
-   	}
-   	else
-   	{
-   	   buffer.put(NOT_NULL);
-   		putSimpleString(string);
-   	}
-   }
-   
-   public SimpleString getSimpleString()
-   {
-   	int len = buffer.getInt();
-   	
-   	byte[] data = new byte[len];
-   	buffer.get(data);
-   	
-   	return new SimpleString(data);
-   }
-   
-   public String getUTF() throws Exception
-   {
-   	int len = buffer.getInt();
-   	byte[] data = new byte[len];
-   	buffer.get(data);
-   	ByteBuffer bb = ByteBuffer.wrap(data); 
-   	CharBuffer cb = utf8.newDecoder().decode(bb);
-   	return cb.toString();
-   }
-
-	public int limit()
-	{
-		return buffer.limit();
-	}
-	
-	public void limit(final int limit)
-   {
-   	buffer.limit(limit);
-   }
-
-	public void putBoolean(boolean val)
-	{
-		if (val)
-      {
-         buffer.put(TRUE);
-      }
-		else
-      {
-         buffer.put(FALSE);
-      }
-	}
-
-	public void putByte(byte val)
-	{
-		buffer.put(val);
-	}
-
-	public void putBytes(byte[] bytes)
-	{
-		buffer.put(bytes);
-	}
-	
-	public void putBytes(byte[] bytes, int offset, int len)
-	{
-		buffer.put(bytes, offset, len);
-	}
-
-	public void putDouble(double val)
-	{
-		buffer.putDouble(val);
-	}
-
-	public void putFloat(float val)
-	{
-		buffer.putFloat(val);
-	}
-
-	public void putInt(int val)
-	{
-		buffer.putInt(val);
-	}
-	
-	public void putInt(int pos, int val)
-   {
-      buffer.putInt(pos, val);
-   }
-
-	public void putLong(long val)
-	{
-		buffer.putLong(val);
-	}
-
-	public void putShort(short val)
-	{
-		buffer.putShort(val);
-	}
-	
-	public void putChar(char chr)
-	{
-		buffer.putChar(chr);
-	}
-	
-	public int remaining()
-	{
-		return buffer.remaining();
-	}
-
-	public Object getUnderlyingBuffer()
-	{
-	   return buffer;
-	}
-
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/ByteBufferWrapper.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/ByteBufferWrapper.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/ByteBufferWrapper.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/ByteBufferWrapper.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,370 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.impl;
+
+import static org.jboss.messaging.util.DataConstants.FALSE;
+import static org.jboss.messaging.util.DataConstants.NOT_NULL;
+import static org.jboss.messaging.util.DataConstants.NULL;
+import static org.jboss.messaging.util.DataConstants.TRUE;
+
+import java.nio.ByteBuffer;
+import java.nio.CharBuffer;
+import java.nio.charset.Charset;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+import org.jboss.messaging.util.SimpleString;
+
+/**
+ * 
+ * A ByteBufferWrapper
+ * 
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:ataylor at redhat.com">Andy Taylor</a>
+ *
+ */
+public class ByteBufferWrapper implements MessagingBuffer
+{
+   private static final Charset utf8 = Charset.forName("UTF-8");
+   	
+	private ByteBuffer buffer;
+	
+	public ByteBufferWrapper(final ByteBuffer buffer)
+	{
+		this.buffer = buffer;
+	}
+	
+	public ByteBuffer getBuffer()
+	{
+	   return buffer;
+	}
+	
+	public byte[] array()
+   {
+      if(buffer.hasArray())
+      {
+         return buffer.array();
+      }
+      else
+      {
+         byte[] b = new byte[buffer.limit()];
+         buffer.get(b);
+         return b;
+      }
+   }
+    
+	public int position()
+	{
+		return buffer.position();
+	}
+	
+	public void position(final int position)
+   {
+   	buffer.position(position);
+   }
+
+	public int capacity()
+	{
+		return buffer.capacity();
+	}
+
+	public void flip()
+	{
+		buffer.flip();
+	}
+	
+	public MessagingBuffer slice()
+   {
+   	return new ByteBufferWrapper(buffer.slice());
+   }
+
+   public MessagingBuffer createNewBuffer(int len)
+   {
+      return new ByteBufferWrapper(ByteBuffer.allocate(len));
+   }
+
+   public void rewind()
+	{
+		buffer.rewind();
+	}
+
+	public boolean getBoolean()
+	{
+		byte b = buffer.get();
+      return (b == TRUE);
+	}
+
+	public byte getByte()
+	{
+		return buffer.get();
+	}
+	
+	public short getUnsignedByte()
+	{
+	   return (short)(buffer.get() & 0xFF);
+	}
+
+	public void getBytes(byte[] bytes)
+	{
+		buffer.get(bytes);
+	}
+	
+	public void getBytes(byte[] bytes, int offset, int length)
+	{
+		buffer.get(bytes, offset, length);
+	}
+
+	public double getDouble()
+	{
+		return buffer.getDouble();
+	}
+
+	public float getFloat()
+	{
+		return buffer.getFloat();
+	}
+
+	public int getInt()
+	{
+		return buffer.getInt();
+	}
+	
+	public long getLong()
+	{
+		return buffer.getLong();
+	}
+
+	public void putNullableString(final String nullableString)
+	{
+		if (nullableString == null)
+		{
+			buffer.put(NULL);
+		}
+		else
+		{
+			buffer.put(NOT_NULL);
+
+			putString(nullableString);
+		}
+	}
+
+	public String getNullableString()
+	{
+		byte check = buffer.get();
+
+		if (check == NULL)
+		{
+			return null;
+		}
+		else
+		{
+			return getString();
+		}
+	}
+
+	public void putString(final String nullableString)
+	{
+		//We don't encode
+
+		buffer.putInt(nullableString.length());
+
+		for (int i = 0; i < nullableString.length(); i++)
+		{
+			buffer.putChar(nullableString.charAt(i));
+		}      
+	}
+	
+	public void putUTF(final String str) throws Exception
+   {
+		//TODO This is quite inefficient - can be improved using a method similar to what MINA IOBuffer does
+		//(putPrefixedString)
+		ByteBuffer bb = utf8.encode(str);
+   	buffer.putInt(bb.limit() - bb.position());
+   	buffer.put(bb);
+   }
+
+	public short getShort()
+	{
+		return buffer.getShort();
+	}
+	
+	public int getUnsignedShort()
+	{
+	   return buffer.getShort() & 0xFFFF;
+	}
+	
+	public char getChar()
+	{
+		return buffer.getChar();
+	}
+
+	public String getString()
+   {
+      int len = buffer.getInt();
+      	
+   	char[] chars = new char[len];
+   	
+      for (int i = 0; i < len; i++)
+      {
+      	chars[i] = buffer.getChar();
+      }
+      
+      return new String(chars);               
+   }
+	
+   public void putSimpleString(final SimpleString string)
+   {
+   	byte[] data = string.getData();
+   	
+   	buffer.putInt(data.length);
+   	buffer.put(data);
+   }
+   
+   public SimpleString getNullableSimpleString()
+   {
+   	int b = buffer.get();
+   	if (b == NULL)
+   	{
+   	   return null;
+   	}
+   	else
+   	{
+         return getSimpleString();
+   	}
+   }
+   
+   public void putNullableSimpleString(final SimpleString string)
+   {
+   	if (string == null)
+   	{
+   		buffer.put(NULL);
+   	}
+   	else
+   	{
+   	   buffer.put(NOT_NULL);
+   		putSimpleString(string);
+   	}
+   }
+   
+   public SimpleString getSimpleString()
+   {
+   	int len = buffer.getInt();
+   	
+   	byte[] data = new byte[len];
+   	buffer.get(data);
+   	
+   	return new SimpleString(data);
+   }
+   
+   public String getUTF() throws Exception
+   {
+   	int len = buffer.getInt();
+   	byte[] data = new byte[len];
+   	buffer.get(data);
+   	ByteBuffer bb = ByteBuffer.wrap(data); 
+   	CharBuffer cb = utf8.newDecoder().decode(bb);
+   	return cb.toString();
+   }
+
+	public int limit()
+	{
+		return buffer.limit();
+	}
+	
+	public void limit(final int limit)
+   {
+   	buffer.limit(limit);
+   }
+
+	public void putBoolean(boolean val)
+	{
+		if (val)
+      {
+         buffer.put(TRUE);
+      }
+		else
+      {
+         buffer.put(FALSE);
+      }
+	}
+
+	public void putByte(byte val)
+	{
+		buffer.put(val);
+	}
+
+	public void putBytes(byte[] bytes)
+	{
+		buffer.put(bytes);
+	}
+	
+	public void putBytes(byte[] bytes, int offset, int len)
+	{
+		buffer.put(bytes, offset, len);
+	}
+
+	public void putDouble(double val)
+	{
+		buffer.putDouble(val);
+	}
+
+	public void putFloat(float val)
+	{
+		buffer.putFloat(val);
+	}
+
+	public void putInt(int val)
+	{
+		buffer.putInt(val);
+	}
+	
+	public void putInt(int pos, int val)
+   {
+      buffer.putInt(pos, val);
+   }
+
+	public void putLong(long val)
+	{
+		buffer.putLong(val);
+	}
+
+	public void putShort(short val)
+	{
+		buffer.putShort(val);
+	}
+	
+	public void putChar(char chr)
+	{
+		buffer.putChar(chr);
+	}
+	
+	public int remaining()
+	{
+		return buffer.remaining();
+	}
+
+	public Object getUnderlyingBuffer()
+	{
+	   return buffer;
+	}
+
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/ExpandingMessagingBuffer.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/ExpandingMessagingBuffer.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/ExpandingMessagingBuffer.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,388 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- *
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.messaging.core.remoting.impl;
-
-import static org.jboss.messaging.util.DataConstants.NOT_NULL;
-import static org.jboss.messaging.util.DataConstants.NULL;
-
-import java.nio.ByteBuffer;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-import org.jboss.messaging.util.SimpleString;
-
-/**
- * A {@link MessagingBuffer} which increases its capacity and length by itself
- * when there's not enough space for a {@code put} operation.
- *
- * @author <a href="mailto:tlee at redhat.com">Trustin Lee</a>
- * @version $Rev: 4857 $, $Date: 2008-08-21 06:32:30 -0700 (Thu, 21 Aug 2008) $
- */
-public class ExpandingMessagingBuffer implements MessagingBuffer
-{
-   private ByteBuffer buf;
-
-   public ExpandingMessagingBuffer(ByteBuffer buf) {
-      this.buf = buf;
-   }
-
-   public ExpandingMessagingBuffer(int size) {
-      this(ByteBuffer.allocate(size));
-   }
-
-   public byte[] array()
-   {
-      if(buf.hasArray() && buf.arrayOffset() == 0 && buf.capacity() == buf.array().length)
-      {
-         return buf.array();
-      }
-      else
-      {
-         byte[] b = new byte[remaining()];
-         getBytes(b);
-         return b;
-      }
-   }
-
-   public int capacity()
-   {
-      return buf.capacity();
-   }
-
-   public MessagingBuffer createNewBuffer(int len)
-   {
-      return new ExpandingMessagingBuffer(len);
-   }
-
-   public void flip()
-   {
-      buf.flip();
-   }
-
-   public boolean getBoolean()
-   {
-      return getByte() != 0;
-   }
-
-   public byte getByte()
-   {
-      return buf.get();
-   }
-
-   public void getBytes(byte[] bytes)
-   {
-      buf.get(bytes);
-   }
-
-   public void getBytes(byte[] bytes, int offset, int length)
-   {
-      buf.get(bytes, offset, length);
-   }
-
-   public char getChar()
-   {
-      return buf.getChar();
-   }
-
-   public double getDouble()
-   {
-      return buf.getDouble();
-   }
-
-   public float getFloat()
-   {
-      return buf.getFloat();
-   }
-
-   public int getInt()
-   {
-      return buf.getInt();
-   }
-
-   public long getLong()
-   {
-      return buf.getLong();
-   }
-
-   public SimpleString getNullableSimpleString()
-   {
-      if (getByte() == NULL)
-      {
-         return null;
-      }
-      else
-      {
-         return getSimpleString();
-      }
-   }
-
-   public String getNullableString()
-   {
-      if (getByte() == NULL)
-      {
-         return null;
-      }
-      else
-      {
-         return getString();
-      }
-   }
-
-   public short getShort()
-   {
-      return buf.getShort();
-   }
-
-   public SimpleString getSimpleString()
-   {
-      int len = getInt();
-      byte[] data = new byte[len];
-      getBytes(data);
-      return new SimpleString(data);
-   }
-
-   public String getString()
-   {
-      int len = getInt();
-      char[] chars = new char[len];
-      for (int i = 0; i < len; i++)
-      {
-         chars[i] = getChar();
-      }
-      return new String(chars);
-   }
-
-   public String getUTF() throws Exception
-   {
-      int length = getUnsignedShort();
-      byte[] data = new byte[length];
-      getBytes(data);
-      return new String(data, "UTF-8");
-   }
-
-   public short getUnsignedByte()
-   {
-      return (short) (getByte() & 0xFF);
-   }
-
-   public int getUnsignedShort()
-   {
-      return getShort() & 0xFFFF;
-   }
-
-   public int limit()
-   {
-      return buf.limit();
-   }
-
-   public void limit(int limit)
-   {
-      buf.limit(limit);
-   }
-
-   public void position(int position)
-   {
-      buf.position(position);
-   }
-
-   public int position()
-   {
-      return buf.position();
-   }
-
-   public void putBoolean(boolean val)
-   {
-      putByte((byte) (val ? -1 : 0));
-   }
-
-   public void putByte(byte val)
-   {
-      ensureRemaining(1).put(val);
-   }
-
-   public void putBytes(byte[] bytes)
-   {
-      ensureRemaining(bytes.length).put(bytes);
-   }
-
-   public void putBytes(byte[] bytes, int offset, int length)
-   {
-      ensureRemaining(length).put(bytes, offset, length);
-   }
-
-   public void putChar(char val)
-   {
-      ensureRemaining(2).putChar(val);
-   }
-
-   public void putDouble(double val)
-   {
-      ensureRemaining(8).putDouble(val);
-   }
-
-   public void putFloat(float val)
-   {
-      ensureRemaining(4).putFloat(val);
-   }
-
-   public void putInt(int val)
-   {
-      ensureRemaining(4).putInt(val);
-   }
-
-   public void putInt(int pos, int val)
-   {
-      buf.putInt(pos, val);
-   }
-
-   public void putLong(long val)
-   {
-      ensureRemaining(8).putLong(val);
-   }
-
-   public void putNullableSimpleString(SimpleString val)
-   {
-      if (val == null)
-      {
-         ensureRemaining(1).put(NULL);
-      }
-      else
-      {
-         ensureRemaining(5 + (val.length() << 1));
-         buf.put(NOT_NULL);
-         byte[] data = val.getData();
-         ensureRemaining(data.length + 4);
-         buf.putInt(data.length);
-         buf.put(data);
-      }
-   }
-
-   public void putNullableString(String val)
-   {
-      if (val == null)
-      {
-         ensureRemaining(1).put(NULL);
-      }
-      else
-      {
-         ensureRemaining(5 + (val.length() << 1));
-         buf.put(NOT_NULL);
-         buf.putInt(val.length());
-         for (int i = 0; i < val.length(); i++)
-         {
-            buf.putChar(val.charAt(i));
-         }
-      }
-   }
-
-   public void putShort(short val)
-   {
-      ensureRemaining(2).putShort(val);
-   }
-
-   public void putSimpleString(SimpleString val)
-   {
-      byte[] data = val.getData();
-      ensureRemaining(4 + data.length);
-      buf.putInt(data.length);
-      buf.put(data);
-   }
-
-   public void putString(String val)
-   {
-      ensureRemaining(4 + (val.length() << 1));
-      buf.putInt(val.length());
-      for (int i = 0; i < val.length(); i++)
-      {
-         buf.putChar(val.charAt(i));
-      }
-   }
-
-   public void putUTF(String utf) throws Exception
-   {
-      byte[] data = utf.getBytes("UTF-8");
-      if (data.length > 65535) {
-         throw new IllegalArgumentException("String is too long: " + data.length);
-      }
-      ensureRemaining(2 + data.length);
-      buf.putShort((short) data.length);
-      buf.put(data);
-   }
-
-   public int remaining()
-   {
-      return buf.remaining();
-   }
-
-   public void rewind()
-   {
-      buf.rewind();
-   }
-
-   public MessagingBuffer slice()
-   {
-      return new ExpandingMessagingBuffer(buf.slice());
-   }
-   
-   public Object getUnderlyingBuffer()
-   {
-      return buf;
-   }
-
-   private ByteBuffer ensureRemaining(int minRemaining)
-   {
-      int remaining = remaining();
-      if (remaining >= minRemaining)
-      {
-         return buf;
-      }
-
-      int capacity = capacity();
-      int limit = limit();
-      if (capacity - limit >= minRemaining - remaining) {
-         buf.limit(limit + minRemaining - remaining);
-         return buf;
-      }
-
-      int position = position();
-      int minCapacityDifference = minRemaining - remaining;
-      int oldCapacity = capacity();
-      int newCapacity = oldCapacity;
-      for (;;)
-      {
-         newCapacity <<= 1;
-         if (newCapacity - oldCapacity >= minCapacityDifference)
-         {
-            break;
-         }
-      }
-
-      ByteBuffer newBuf = ByteBuffer.allocate(newCapacity);
-      buf.clear();
-      newBuf.put(buf);
-      newBuf.limit(position + minRemaining);
-      newBuf.position(position);
-      buf = newBuf;
-
-      return newBuf;
-   }
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/ExpandingMessagingBuffer.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/ExpandingMessagingBuffer.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/ExpandingMessagingBuffer.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/ExpandingMessagingBuffer.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,388 @@
+/*
+ * JBoss, Home of Professional Open Source
+ *
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.messaging.core.remoting.impl;
+
+import static org.jboss.messaging.util.DataConstants.NOT_NULL;
+import static org.jboss.messaging.util.DataConstants.NULL;
+
+import java.nio.ByteBuffer;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+import org.jboss.messaging.util.SimpleString;
+
+/**
+ * A {@link MessagingBuffer} which increases its capacity and length by itself
+ * when there's not enough space for a {@code put} operation.
+ *
+ * @author <a href="mailto:tlee at redhat.com">Trustin Lee</a>
+ * @version $Rev: 4857 $, $Date: 2008-08-21 06:32:30 -0700 (Thu, 21 Aug 2008) $
+ */
+public class ExpandingMessagingBuffer implements MessagingBuffer
+{
+   private ByteBuffer buf;
+
+   public ExpandingMessagingBuffer(ByteBuffer buf) {
+      this.buf = buf;
+   }
+
+   public ExpandingMessagingBuffer(int size) {
+      this(ByteBuffer.allocate(size));
+   }
+
+   public byte[] array()
+   {
+      if(buf.hasArray() && buf.arrayOffset() == 0 && buf.capacity() == buf.array().length)
+      {
+         return buf.array();
+      }
+      else
+      {
+         byte[] b = new byte[remaining()];
+         getBytes(b);
+         return b;
+      }
+   }
+
+   public int capacity()
+   {
+      return buf.capacity();
+   }
+
+   public MessagingBuffer createNewBuffer(int len)
+   {
+      return new ExpandingMessagingBuffer(len);
+   }
+
+   public void flip()
+   {
+      buf.flip();
+   }
+
+   public boolean getBoolean()
+   {
+      return getByte() != 0;
+   }
+
+   public byte getByte()
+   {
+      return buf.get();
+   }
+
+   public void getBytes(byte[] bytes)
+   {
+      buf.get(bytes);
+   }
+
+   public void getBytes(byte[] bytes, int offset, int length)
+   {
+      buf.get(bytes, offset, length);
+   }
+
+   public char getChar()
+   {
+      return buf.getChar();
+   }
+
+   public double getDouble()
+   {
+      return buf.getDouble();
+   }
+
+   public float getFloat()
+   {
+      return buf.getFloat();
+   }
+
+   public int getInt()
+   {
+      return buf.getInt();
+   }
+
+   public long getLong()
+   {
+      return buf.getLong();
+   }
+
+   public SimpleString getNullableSimpleString()
+   {
+      if (getByte() == NULL)
+      {
+         return null;
+      }
+      else
+      {
+         return getSimpleString();
+      }
+   }
+
+   public String getNullableString()
+   {
+      if (getByte() == NULL)
+      {
+         return null;
+      }
+      else
+      {
+         return getString();
+      }
+   }
+
+   public short getShort()
+   {
+      return buf.getShort();
+   }
+
+   public SimpleString getSimpleString()
+   {
+      int len = getInt();
+      byte[] data = new byte[len];
+      getBytes(data);
+      return new SimpleString(data);
+   }
+
+   public String getString()
+   {
+      int len = getInt();
+      char[] chars = new char[len];
+      for (int i = 0; i < len; i++)
+      {
+         chars[i] = getChar();
+      }
+      return new String(chars);
+   }
+
+   public String getUTF() throws Exception
+   {
+      int length = getUnsignedShort();
+      byte[] data = new byte[length];
+      getBytes(data);
+      return new String(data, "UTF-8");
+   }
+
+   public short getUnsignedByte()
+   {
+      return (short) (getByte() & 0xFF);
+   }
+
+   public int getUnsignedShort()
+   {
+      return getShort() & 0xFFFF;
+   }
+
+   public int limit()
+   {
+      return buf.limit();
+   }
+
+   public void limit(int limit)
+   {
+      buf.limit(limit);
+   }
+
+   public void position(int position)
+   {
+      buf.position(position);
+   }
+
+   public int position()
+   {
+      return buf.position();
+   }
+
+   public void putBoolean(boolean val)
+   {
+      putByte((byte) (val ? -1 : 0));
+   }
+
+   public void putByte(byte val)
+   {
+      ensureRemaining(1).put(val);
+   }
+
+   public void putBytes(byte[] bytes)
+   {
+      ensureRemaining(bytes.length).put(bytes);
+   }
+
+   public void putBytes(byte[] bytes, int offset, int length)
+   {
+      ensureRemaining(length).put(bytes, offset, length);
+   }
+
+   public void putChar(char val)
+   {
+      ensureRemaining(2).putChar(val);
+   }
+
+   public void putDouble(double val)
+   {
+      ensureRemaining(8).putDouble(val);
+   }
+
+   public void putFloat(float val)
+   {
+      ensureRemaining(4).putFloat(val);
+   }
+
+   public void putInt(int val)
+   {
+      ensureRemaining(4).putInt(val);
+   }
+
+   public void putInt(int pos, int val)
+   {
+      buf.putInt(pos, val);
+   }
+
+   public void putLong(long val)
+   {
+      ensureRemaining(8).putLong(val);
+   }
+
+   public void putNullableSimpleString(SimpleString val)
+   {
+      if (val == null)
+      {
+         ensureRemaining(1).put(NULL);
+      }
+      else
+      {
+         ensureRemaining(5 + (val.length() << 1));
+         buf.put(NOT_NULL);
+         byte[] data = val.getData();
+         ensureRemaining(data.length + 4);
+         buf.putInt(data.length);
+         buf.put(data);
+      }
+   }
+
+   public void putNullableString(String val)
+   {
+      if (val == null)
+      {
+         ensureRemaining(1).put(NULL);
+      }
+      else
+      {
+         ensureRemaining(5 + (val.length() << 1));
+         buf.put(NOT_NULL);
+         buf.putInt(val.length());
+         for (int i = 0; i < val.length(); i++)
+         {
+            buf.putChar(val.charAt(i));
+         }
+      }
+   }
+
+   public void putShort(short val)
+   {
+      ensureRemaining(2).putShort(val);
+   }
+
+   public void putSimpleString(SimpleString val)
+   {
+      byte[] data = val.getData();
+      ensureRemaining(4 + data.length);
+      buf.putInt(data.length);
+      buf.put(data);
+   }
+
+   public void putString(String val)
+   {
+      ensureRemaining(4 + (val.length() << 1));
+      buf.putInt(val.length());
+      for (int i = 0; i < val.length(); i++)
+      {
+         buf.putChar(val.charAt(i));
+      }
+   }
+
+   public void putUTF(String utf) throws Exception
+   {
+      byte[] data = utf.getBytes("UTF-8");
+      if (data.length > 65535) {
+         throw new IllegalArgumentException("String is too long: " + data.length);
+      }
+      ensureRemaining(2 + data.length);
+      buf.putShort((short) data.length);
+      buf.put(data);
+   }
+
+   public int remaining()
+   {
+      return buf.remaining();
+   }
+
+   public void rewind()
+   {
+      buf.rewind();
+   }
+
+   public MessagingBuffer slice()
+   {
+      return new ExpandingMessagingBuffer(buf.slice());
+   }
+   
+   public Object getUnderlyingBuffer()
+   {
+      return buf;
+   }
+
+   private ByteBuffer ensureRemaining(int minRemaining)
+   {
+      int remaining = remaining();
+      if (remaining >= minRemaining)
+      {
+         return buf;
+      }
+
+      int capacity = capacity();
+      int limit = limit();
+      if (capacity - limit >= minRemaining - remaining) {
+         buf.limit(limit + minRemaining - remaining);
+         return buf;
+      }
+
+      int position = position();
+      int minCapacityDifference = minRemaining - remaining;
+      int oldCapacity = capacity();
+      int newCapacity = oldCapacity;
+      for (;;)
+      {
+         newCapacity <<= 1;
+         if (newCapacity - oldCapacity >= minCapacityDifference)
+         {
+            break;
+         }
+      }
+
+      ByteBuffer newBuf = ByteBuffer.allocate(newCapacity);
+      buf.clear();
+      newBuf.put(buf);
+      newBuf.limit(position + minRemaining);
+      newBuf.position(position);
+      buf = newBuf;
+
+      return newBuf;
+   }
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/RemotingConnectionImpl.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/RemotingConnectionImpl.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/RemotingConnectionImpl.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,1635 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors by
- * the @authors tag. See the copyright.txt in the distribution for a full listing of individual contributors. This is
- * free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version.
- * This software is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
- * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
- * details. You should have received a copy of the GNU Lesser General Public License along with this software; if not,
- * write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA, or see the FSF
- * site: http://www.fsf.org.
- */
-
-package org.jboss.messaging.core.remoting.impl;
-
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.CREATESESSION;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.CREATESESSION_RESP;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.EARLY_RESPONSE;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.EXCEPTION;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.NULL_RESPONSE;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.PACKETS_CONFIRMED;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.PING;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.PONG;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.REATTACH_SESSION;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.REATTACH_SESSION_RESP;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.REPLICATE_CREATESESSION;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.REPLICATION_RESPONSE;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_ACKNOWLEDGE;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_ADD_DESTINATION;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_BINDINGQUERY;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_BINDINGQUERY_RESP;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_CLOSE;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_COMMIT;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_CONSUMER_CLOSE;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_CREATECONSUMER;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_CREATEQUEUE;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_DELETE_QUEUE;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_EXPIRED;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_FAILOVER_COMPLETE;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_FLOWTOKEN;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_QUEUEQUERY;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_QUEUEQUERY_RESP;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_RECEIVE_CONTINUATION;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_RECEIVE_MSG;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_REMOVE_DESTINATION;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_REPLICATE_DELIVERY;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_ROLLBACK;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_SEND;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_SEND_CONTINUATION;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_START;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_STOP;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_XA_COMMIT;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_XA_END;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_XA_FORGET;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_XA_GET_TIMEOUT;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_XA_GET_TIMEOUT_RESP;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_XA_INDOUBT_XIDS;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_XA_INDOUBT_XIDS_RESP;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_XA_JOIN;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_XA_PREPARE;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_XA_RESP;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_XA_RESUME;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_XA_ROLLBACK;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_XA_SET_TIMEOUT;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_XA_SET_TIMEOUT_RESP;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_XA_START;
-import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_XA_SUSPEND;
-
-import java.util.ArrayList;
-import java.util.List;
-import java.util.Map;
-import java.util.Queue;
-import java.util.concurrent.ConcurrentHashMap;
-import java.util.concurrent.ConcurrentLinkedQueue;
-import java.util.concurrent.CopyOnWriteArrayList;
-import java.util.concurrent.ScheduledExecutorService;
-import java.util.concurrent.ScheduledFuture;
-import java.util.concurrent.Semaphore;
-import java.util.concurrent.TimeUnit;
-import java.util.concurrent.locks.Condition;
-import java.util.concurrent.locks.Lock;
-import java.util.concurrent.locks.ReentrantLock;
-
-import org.jboss.messaging.core.exception.MessagingException;
-import org.jboss.messaging.core.logging.Logger;
-import org.jboss.messaging.core.remoting.Channel;
-import org.jboss.messaging.core.remoting.ChannelHandler;
-import org.jboss.messaging.core.remoting.DelayedResult;
-import org.jboss.messaging.core.remoting.FailureListener;
-import org.jboss.messaging.core.remoting.Interceptor;
-import org.jboss.messaging.core.remoting.Packet;
-import org.jboss.messaging.core.remoting.RemotingConnection;
-import org.jboss.messaging.core.remoting.impl.wireformat.CreateSessionMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.CreateSessionResponseMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.MessagingExceptionMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.NullResponseMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl;
-import org.jboss.messaging.core.remoting.impl.wireformat.PacketsConfirmedMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.Ping;
-import org.jboss.messaging.core.remoting.impl.wireformat.Pong;
-import org.jboss.messaging.core.remoting.impl.wireformat.ReattachSessionMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.ReattachSessionResponseMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.ReplicateCreateSessionMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.SessionAcknowledgeMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.SessionAddDestinationMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.SessionBindingQueryMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.SessionBindingQueryResponseMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.SessionCloseMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.SessionConsumerCloseMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.SessionConsumerFlowCreditMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.SessionCreateConsumerMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.SessionCreateQueueMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.SessionDeleteQueueMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.SessionExpiredMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.SessionFailoverCompleteMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.SessionQueueQueryMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.SessionQueueQueryResponseMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.SessionReceiveContinuationMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.SessionReceiveMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.SessionRemoveDestinationMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.SessionReplicateDeliveryMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.SessionSendContinuationMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.SessionSendMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.SessionXACommitMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.SessionXAEndMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.SessionXAForgetMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.SessionXAGetInDoubtXidsResponseMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.SessionXAGetTimeoutResponseMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.SessionXAJoinMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.SessionXAPrepareMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.SessionXAResponseMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.SessionXAResumeMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.SessionXARollbackMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.SessionXASetTimeoutMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.SessionXASetTimeoutResponseMessage;
-import org.jboss.messaging.core.remoting.impl.wireformat.SessionXAStartMessage;
-import org.jboss.messaging.core.remoting.spi.Connection;
-import org.jboss.messaging.core.remoting.spi.ConnectionLifeCycleListener;
-import org.jboss.messaging.core.remoting.spi.Connector;
-import org.jboss.messaging.core.remoting.spi.ConnectorFactory;
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-import org.jboss.messaging.util.SimpleIDGenerator;
-
-/**
- * @author <a href="tim.fox at jboss.com">Tim Fox</a>
- * @author <a href="mailto:jmesnil at redhat.com">Jeff Mesnil</a>
- * @version <tt>$Revision: 5792 $</tt> $Id: RemotingConnectionImpl.java 5792 2009-02-03 09:07:23Z timfox $
- */
-public class RemotingConnectionImpl extends AbstractBufferHandler implements RemotingConnection
-{
-   // Constants
-   // ------------------------------------------------------------------------------------
-
-   private static final Logger log = Logger.getLogger(RemotingConnectionImpl.class);
-
-   // Static
-   // ---------------------------------------------------------------------------------------
-
-   public static RemotingConnection createConnection(final ConnectorFactory connectorFactory,
-                                                     final Map<String, Object> params,
-                                                     final long callTimeout,
-                                                     final long pingInterval,
-                                                     final long connectionTTL,
-                                                     final ScheduledExecutorService pingExecutor,
-                                                     final ConnectionLifeCycleListener listener)
-   {
-      DelegatingBufferHandler handler = new DelegatingBufferHandler();
-
-      Connector connector = connectorFactory.createConnector(params, handler, listener);
-
-      connector.start();
-
-      Connection tc = connector.createConnection();
-
-      if (tc == null)
-      {
-         throw new IllegalStateException("Failed to connect");
-      }
-
-      RemotingConnection connection = new RemotingConnectionImpl(tc,
-                                                                 callTimeout,
-                                                                 pingInterval,
-                                                                 connectionTTL,
-                                                                 pingExecutor,
-                                                                 null);
-
-      handler.conn = connection;
-
-      return connection;
-   }
-
-   private static class DelegatingBufferHandler extends AbstractBufferHandler
-   {
-      RemotingConnection conn;
-
-      public void bufferReceived(final Object connectionID, final MessagingBuffer buffer)
-      {
-         conn.bufferReceived(connectionID, buffer);
-      }
-   }
-
-   // Attributes
-   // -----------------------------------------------------------------------------------
-
-   private final Connection transportConnection;
-
-   private final Map<Long, ChannelImpl> channels = new ConcurrentHashMap<Long, ChannelImpl>();
-
-   private final List<FailureListener> failureListeners = new CopyOnWriteArrayList<FailureListener>();
-
-   private final long blockingCallTimeout;
-
-   private Runnable pinger;
-
-   private final List<Interceptor> interceptors;
-
-   private ScheduledFuture<?> future;
-
-   private boolean firstTime = true;
-
-   private volatile boolean gotPong;
-
-   private volatile boolean destroyed;
-
-   private volatile boolean stopPinging;
-
-   private volatile long expireTime = -1;
-
-   private final Channel pingChannel;
-
-   private volatile RemotingConnection replicatingConnection;
-
-   private volatile boolean active;
-
-   private final boolean client;
-
-   private final long pingPeriod;
-
-   // How long without a ping before the connection times out
-   private final long connectionTTL;
-
-   private final ScheduledExecutorService pingExecutor;
-
-   // Channels 0-9 are reserved for the system
-   // 0 is for pinging
-   // 1 is for session creation and attachment
-   private volatile SimpleIDGenerator idGenerator = new SimpleIDGenerator(10);
-
-   private boolean idGeneratorSynced = false;
-
-   private final Object transferLock = new Object();
-
-   private final ChannelHandler ppHandler = new PingPongHandler();
-
-   private boolean frozen;
-
-   private final Object failLock = new Object();
-
-   // debug only stuff
-
-   private boolean createdActive;
-
-   // Constructors
-   // ---------------------------------------------------------------------------------
-
-   /*
-    * Create a client side connection
-    */
-   public RemotingConnectionImpl(final Connection transportConnection,
-                                 final long blockingCallTimeout,
-                                 final long pingPeriod,
-                                 final long connectionTTL,
-                                 final ScheduledExecutorService pingExecutor,
-                                 final List<Interceptor> interceptors)
-   {
-      this(transportConnection,
-           blockingCallTimeout,
-           pingPeriod,
-           connectionTTL,
-           pingExecutor,
-           interceptors,
-           null,
-           true,
-           true);
-   }
-
-   /*
-    * Create a server side connection
-    */
-   public RemotingConnectionImpl(final Connection transportConnection,
-                                 final List<Interceptor> interceptors,
-                                 final RemotingConnection replicatingConnection,
-                                 final boolean active,
-                                 final long connectionTTL)
-
-   {
-      this(transportConnection, -1, -1, connectionTTL, null, interceptors, replicatingConnection, active, false);
-   }
-
-   private RemotingConnectionImpl(final Connection transportConnection,
-                                  final long blockingCallTimeout,
-                                  final long pingPeriod,
-                                  final long connectionTTL,
-                                  final ScheduledExecutorService pingExecutor,
-                                  final List<Interceptor> interceptors,
-                                  final RemotingConnection replicatingConnection,
-                                  final boolean active,
-                                  final boolean client)
-
-   {      
-      this.transportConnection = transportConnection;
-
-      this.blockingCallTimeout = blockingCallTimeout;
-
-      this.interceptors = interceptors;
-
-      this.replicatingConnection = replicatingConnection;
-
-      if (replicatingConnection != null)
-      {
-         replicatingConnection.addFailureListener(new ReplicatingConnectionFailureListener());
-      }
-
-      this.active = active;
-
-      this.pingPeriod = pingPeriod;
-
-      this.connectionTTL = connectionTTL;
-
-      this.pingExecutor = pingExecutor;
-
-      // Channel zero is reserved for pinging
-      pingChannel = getChannel(0, -1, false);
-
-      pingChannel.setHandler(ppHandler);
-
-      this.client = client;
-
-      this.createdActive = active;
-   }
-
-   public void startPinger()
-   {
-      if (pingPeriod != -1)
-      {
-         pinger = new Pinger();
-
-         future = pingExecutor.scheduleWithFixedDelay(pinger, 0, pingPeriod, TimeUnit.MILLISECONDS);
-      }
-      else
-      {
-         pinger = null;
-      }
-   }
-
-   // RemotingConnection implementation
-   // ------------------------------------------------------------
-
-   public List<FailureListener> getFailureListeners()
-   {
-      return new ArrayList<FailureListener>(failureListeners);
-   }
-
-   public void setFailureListeners(final List<FailureListener> listeners)
-   {
-      this.failureListeners.clear();
-
-      this.failureListeners.addAll(listeners);
-   }
-
-   public Object getID()
-   {
-      return transportConnection.getID();
-   }
-
-   public String getRemoteAddress()
-   {
-      return transportConnection.getRemoteAddress();
-   }
-
-   public synchronized Channel getChannel(final long channelID, final int windowSize, final boolean block)
-   {
-      ChannelImpl channel = channels.get(channelID);
-
-      if (channel == null)
-      {
-         channel = new ChannelImpl(this, channelID, windowSize, block);
-
-         channels.put(channelID, channel);
-      }
-
-      return channel;
-   }
-
-   public void addFailureListener(final FailureListener listener)
-   {
-      if (listener == null)
-      {
-         throw new IllegalStateException("FailureListener cannot be null");
-      }
-
-      failureListeners.add(listener);
-   }
-
-   public boolean removeFailureListener(final FailureListener listener)
-   {
-      if (listener == null)
-      {
-         throw new IllegalStateException("FailureListener cannot be null");
-      }
-
-      return failureListeners.remove(listener);
-   }
-
-   public MessagingBuffer createBuffer(final int size)
-   {
-      return transportConnection.createBuffer(size);
-   }
-
-   public RemotingConnection getReplicatingConnection()
-   {
-      return replicatingConnection;
-   }
-
-   public void setReplicatingConnection(final RemotingConnection connection)
-   {
-      this.replicatingConnection = connection;
-   }
-
-   /*
-    * This can be called concurrently by more than one thread so needs to be locked
-    */
-   public void fail(final MessagingException me)
-   {
-      synchronized (failLock)
-      {
-         if (destroyed)
-         {
-            return;
-         }
-         
-         destroyed = true;
-      }
-
-      log.warn("Connection failed " + System.identityHashCode(this) + " " + me.getMessage());
-
-      // Then call the listeners
-      callListeners(me);
-
-      internalClose();   
-   }
-
-   public void destroy()
-   {
-      synchronized (failLock)
-      {
-         if (destroyed)
-         {
-            return;
-         }
-         
-         destroyed = true;
-      }
-
-      internalClose();
-
-      // TODO: https://jira.jboss.org/jira/browse/JBMESSAGING-1421
-      // This affects clustering, so I'm keeping this out for now
-      // We need to inform Listeners about the connection being closed
-      // callListeners(null);      
-   }
-
-   public boolean isExpired(final long now)
-   {
-      return expireTime != -1 && now >= expireTime;
-   }
-
-   public long generateChannelID()
-   {
-      return idGenerator.generateID();
-   }
-
-   /* For testing only */
-   public void stopPingingAfterOne()
-   {
-      stopPinging = true;
-   }
-
-   public synchronized void syncIDGeneratorSequence(final long id)
-   {
-      if (!idGeneratorSynced)
-      {
-         idGenerator = new SimpleIDGenerator(id);
-
-         idGeneratorSynced = true;
-      }
-   }
-
-   public long getIDGeneratorSequence()
-   {
-      return idGenerator.getCurrentID();
-   }
-
-   // Buffer Handler implementation
-   // ----------------------------------------------------
-
-   public void bufferReceived(final Object connectionID, final MessagingBuffer buffer)
-   {
-      final Packet packet = decode(buffer);
-      
-      synchronized (transferLock)
-      {
-         if (!frozen)
-         {
-            final ChannelImpl channel = channels.get(packet.getChannelID());
-
-            if (channel != null)
-            {
-               channel.handlePacket(packet);
-            }
-         }
-      }
-   }
-
-   public void activate()
-   {
-      active = true;
-   }
-
-   public void freeze()
-   {
-      // Prevent any more packets being handled on this connection
-
-      synchronized (transferLock)
-      {
-         frozen = true;
-      }
-   }
-
-   // Package protected
-   // ----------------------------------------------------------------------------
-
-   // Protected
-   // ------------------------------------------------------------------------------------
-
-   // Private
-   // --------------------------------------------------------------------------------------
-
-   private void callListeners(final MessagingException me)
-   {
-      final List<FailureListener> listenersClone = new ArrayList<FailureListener>(failureListeners);
-
-      for (final FailureListener listener : listenersClone)
-      {
-         try
-         {
-            boolean callNext = listener.connectionFailed(me);
-
-            if (!callNext)
-            {
-               break;
-            }
-         }
-         catch (final Throwable t)
-         {
-            // Failure of one listener to execute shouldn't prevent others
-            // from
-            // executing
-            log.error("Failed to execute failure listener", t);
-         }
-      }
-   }
-
-   private void internalClose()
-   {
-      if (future != null)
-      {
-         future.cancel(false);
-      }
-
-      pingChannel.close();
-
-      // We close the underlying transport connection
-      transportConnection.close();
-
-      if (replicatingConnection != null)
-      {
-         replicatingConnection.destroy();
-      }
-
-      for (Channel channel : channels.values())
-      {
-         channel.close();
-      }
-   }
-
-   private Packet decode(final MessagingBuffer in)
-   {
-      final byte packetType = in.getByte();
-
-      Packet packet;
-
-      switch (packetType)
-      {
-         case PING:
-         {
-            packet = new Ping();
-            break;
-         }
-         case PONG:
-         {
-            packet = new PacketImpl(PacketImpl.PONG);
-            break;
-         }
-         case EXCEPTION:
-         {
-            packet = new MessagingExceptionMessage();
-            break;
-         }
-         case PACKETS_CONFIRMED:
-         {
-            packet = new PacketsConfirmedMessage();
-            break;
-         }
-         case REPLICATION_RESPONSE:
-         {
-            packet = new PacketImpl(REPLICATION_RESPONSE);
-            break;
-         }
-         case CREATESESSION:
-         {
-            packet = new CreateSessionMessage();
-            break;
-         }
-         case REPLICATE_CREATESESSION:
-         {
-            packet = new ReplicateCreateSessionMessage();
-            break;
-         }
-         case CREATESESSION_RESP:
-         {
-            packet = new CreateSessionResponseMessage();
-            break;
-         }
-         case REATTACH_SESSION:
-         {
-            packet = new ReattachSessionMessage();
-            break;
-         }
-         case REATTACH_SESSION_RESP:
-         {
-            packet = new ReattachSessionResponseMessage();
-            break;
-         }
-         case SESS_FAILOVER_COMPLETE:
-         {
-            packet = new SessionFailoverCompleteMessage();
-            break;
-         }
-         case SESS_CLOSE:
-         {
-            packet = new SessionCloseMessage();
-            break;
-         }
-         case SESS_CREATECONSUMER:
-         {
-            packet = new SessionCreateConsumerMessage();
-            break;
-         }
-         case SESS_ACKNOWLEDGE:
-         {
-            packet = new SessionAcknowledgeMessage();
-            break;
-         }
-         case SESS_EXPIRED:
-         {
-            packet = new SessionExpiredMessage();
-            break;
-         }
-         case SESS_COMMIT:
-         {
-            packet = new PacketImpl(PacketImpl.SESS_COMMIT);
-            break;
-         }
-         case SESS_ROLLBACK:
-         {
-            packet = new PacketImpl(PacketImpl.SESS_ROLLBACK);
-            break;
-         }
-         case SESS_QUEUEQUERY:
-         {
-            packet = new SessionQueueQueryMessage();
-            break;
-         }
-         case SESS_QUEUEQUERY_RESP:
-         {
-            packet = new SessionQueueQueryResponseMessage();
-            break;
-         }
-         case SESS_CREATEQUEUE:
-         {
-            packet = new SessionCreateQueueMessage();
-            break;
-         }
-         case SESS_DELETE_QUEUE:
-         {
-            packet = new SessionDeleteQueueMessage();
-            break;
-         }
-         case SESS_ADD_DESTINATION:
-         {
-            packet = new SessionAddDestinationMessage();
-            break;
-         }
-         case SESS_REMOVE_DESTINATION:
-         {
-            packet = new SessionRemoveDestinationMessage();
-            break;
-         }
-         case SESS_BINDINGQUERY:
-         {
-            packet = new SessionBindingQueryMessage();
-            break;
-         }
-         case SESS_BINDINGQUERY_RESP:
-         {
-            packet = new SessionBindingQueryResponseMessage();
-            break;
-         }
-         case SESS_XA_START:
-         {
-            packet = new SessionXAStartMessage();
-            break;
-         }
-         case SESS_XA_END:
-         {
-            packet = new SessionXAEndMessage();
-            break;
-         }
-         case SESS_XA_COMMIT:
-         {
-            packet = new SessionXACommitMessage();
-            break;
-         }
-         case SESS_XA_PREPARE:
-         {
-            packet = new SessionXAPrepareMessage();
-            break;
-         }
-         case SESS_XA_RESP:
-         {
-            packet = new SessionXAResponseMessage();
-            break;
-         }
-         case SESS_XA_ROLLBACK:
-         {
-            packet = new SessionXARollbackMessage();
-            break;
-         }
-         case SESS_XA_JOIN:
-         {
-            packet = new SessionXAJoinMessage();
-            break;
-         }
-         case SESS_XA_SUSPEND:
-         {
-            packet = new PacketImpl(PacketImpl.SESS_XA_SUSPEND);
-            break;
-         }
-         case SESS_XA_RESUME:
-         {
-            packet = new SessionXAResumeMessage();
-            break;
-         }
-         case SESS_XA_FORGET:
-         {
-            packet = new SessionXAForgetMessage();
-            break;
-         }
-         case SESS_XA_INDOUBT_XIDS:
-         {
-            packet = new PacketImpl(PacketImpl.SESS_XA_INDOUBT_XIDS);
-            break;
-         }
-         case SESS_XA_INDOUBT_XIDS_RESP:
-         {
-            packet = new SessionXAGetInDoubtXidsResponseMessage();
-            break;
-         }
-         case SESS_XA_SET_TIMEOUT:
-         {
-            packet = new SessionXASetTimeoutMessage();
-            break;
-         }
-         case SESS_XA_SET_TIMEOUT_RESP:
-         {
-            packet = new SessionXASetTimeoutResponseMessage();
-            break;
-         }
-         case SESS_XA_GET_TIMEOUT:
-         {
-            packet = new PacketImpl(PacketImpl.SESS_XA_GET_TIMEOUT);
-            break;
-         }
-         case SESS_XA_GET_TIMEOUT_RESP:
-         {
-            packet = new SessionXAGetTimeoutResponseMessage();
-            break;
-         }
-         case SESS_START:
-         {
-            packet = new PacketImpl(PacketImpl.SESS_START);
-            break;
-         }
-         case SESS_STOP:
-         {
-            packet = new PacketImpl(PacketImpl.SESS_STOP);
-            break;
-         }
-         case SESS_FLOWTOKEN:
-         {
-            packet = new SessionConsumerFlowCreditMessage();
-            break;
-         }
-         case SESS_SEND:
-         {
-            packet = new SessionSendMessage();
-            break;
-         }
-         case SESS_RECEIVE_MSG:
-         {
-            packet = new SessionReceiveMessage();
-            break;
-         }
-         case SESS_CONSUMER_CLOSE:
-         {
-            packet = new SessionConsumerCloseMessage();
-            break;
-         }
-         case NULL_RESPONSE:
-         {
-            packet = new NullResponseMessage();
-            break;
-         }
-         case SESS_RECEIVE_CONTINUATION:
-         {
-            packet = new SessionReceiveContinuationMessage();
-            break;
-         }
-         case SESS_SEND_CONTINUATION:
-         {
-            packet = new SessionSendContinuationMessage();
-            break;
-         }
-         case SESS_REPLICATE_DELIVERY:
-         {
-            packet = new SessionReplicateDeliveryMessage();
-            break;
-         }
-         default:
-         {
-            throw new IllegalArgumentException("Invalid type: " + packetType);
-         }
-      }
-
-      packet.decode(in);
-
-      return packet;
-   }
-
-   // Inner classes
-   // --------------------------------------------------------------------------------
-
-   // Needs to be static so we can re-assign it to another remotingconnection
-   private static class ChannelImpl implements Channel
-   {
-      private final long id;
-
-      private ChannelHandler handler;
-
-      private Packet response;
-
-      private final java.util.Queue<Packet> resendCache;
-
-      private volatile int firstStoredCommandID;
-
-      private volatile int lastReceivedCommandID = -1;
-
-      private Channel replicatingChannel;
-
-      private volatile RemotingConnectionImpl connection;
-
-      private volatile boolean closed;
-
-      private final Lock lock = new ReentrantLock();
-
-      private final Condition sendCondition = lock.newCondition();
-
-      private final Condition failoverCondition = lock.newCondition();
-
-      private final Object sendLock = new Object();
-
-      private final Object sendBlockingLock = new Object();
-
-      private final Object replicationLock = new Object();
-
-      private boolean failingOver;
-
-      private final Queue<DelayedResult> responseActions = new ConcurrentLinkedQueue<DelayedResult>();
-
-      private final int windowSize;
-
-      private final int confWindowSize;
-
-      private final Semaphore sendSemaphore;
-
-      private int receivedBytes;
-
-      private ChannelImpl(final RemotingConnectionImpl connection,
-                          final long id,
-                          final int windowSize,
-                          final boolean block)
-      {
-         this.connection = connection;
-
-         this.id = id;
-
-         if (connection.replicatingConnection != null && id != 0)
-         {
-            // We don't redirect the ping channel
-
-            replicatingChannel = connection.replicatingConnection.getChannel(id, -1, false);
-
-            replicatingChannel.setHandler(new ReplicatedPacketsConfirmedChannelHandler());
-         }
-         this.windowSize = windowSize;
-
-         this.confWindowSize = (int)(0.75 * windowSize);
-
-         if (this.windowSize != -1)
-         {
-            resendCache = new ConcurrentLinkedQueue<Packet>();
-
-            if (block)
-            {
-               sendSemaphore = new Semaphore(windowSize, true);
-            }
-            else
-            {
-               sendSemaphore = null;
-            }
-         }
-         else
-         {
-            resendCache = null;
-
-            sendSemaphore = null;
-         }
-      }
-
-      public long getID()
-      {
-         return id;
-      }
-
-      public int getLastReceivedCommandID()
-      {
-         return lastReceivedCommandID;
-      }
-
-      public Lock getLock()
-      {
-         return lock;
-      }
-
-      public void returnBlocking()
-      {
-         lock.lock();
-
-         try
-         {
-            response = new PacketImpl(EARLY_RESPONSE);
-
-            sendCondition.signal();
-         }
-         finally
-         {
-            lock.unlock();
-         }
-      }
-
-      // This must never called by more than one thread concurrently
-      public void send(final Packet packet)
-      {
-         synchronized (sendLock)
-         {
-            packet.setChannelID(id);
-
-            final MessagingBuffer buffer = connection.transportConnection.createBuffer(packet.getRequiredBufferSize());
-
-            int size = packet.encode(buffer);
-
-            // Must block on semaphore outside the main lock or this can prevent failover from occurring
-            if (sendSemaphore != null && packet.getType() != PACKETS_CONFIRMED)
-            {
-               try
-               {
-                  sendSemaphore.acquire(size);
-               }
-               catch (InterruptedException e)
-               {
-                  throw new IllegalStateException("Semaphore interrupted");
-               }
-            }
-
-            lock.lock();
-
-            try
-            {
-               while (failingOver)
-               {
-                  // TODO - don't hardcode this timeout
-                  try
-                  {
-                     failoverCondition.await(10000, TimeUnit.MILLISECONDS);
-                  }
-                  catch (InterruptedException e)
-                  {
-                  }
-               }
-
-               if (resendCache != null && packet.isRequiresConfirmations())
-               {
-                  resendCache.add(packet);
-               }
-
-               if (connection.active || packet.isWriteAlways())
-               {              
-                  connection.transportConnection.write(buffer);
-               }
-            }
-            finally
-            {
-               lock.unlock();
-            }
-         }
-      }
-
-      public Packet sendBlocking(final Packet packet) throws MessagingException
-      {
-         if (closed)
-         {
-            throw new MessagingException(MessagingException.NOT_CONNECTED, "Connection is destroyed");
-         }
-
-         if (connection.blockingCallTimeout == -1)
-         {
-            throw new IllegalStateException("Cannot do a blocking call timeout on a server side connection");
-         }
-
-         // Synchronized since can't be called concurrently by more than one thread and this can occur
-         // E.g. blocking acknowledge() from inside a message handler at some time as other operation on main thread
-         synchronized (sendBlockingLock)
-         {
-            packet.setChannelID(id);
-
-            final MessagingBuffer buffer = connection.transportConnection.createBuffer(packet.getRequiredBufferSize());
-
-            int size = packet.encode(buffer);
-
-            // Must block on semaphore outside the main lock or this can prevent failover from occurring
-            if (sendSemaphore != null)
-            {
-               try
-               {
-                  sendSemaphore.acquire(size);
-               }
-               catch (InterruptedException e)
-               {
-                  throw new IllegalStateException("Semaphore interrupted");
-               }
-            }
-
-            lock.lock();
-
-            try
-            {
-               while (failingOver)
-               {
-                  // TODO - don't hardcode this timeout
-                  try
-                  {
-                     failoverCondition.await(10000, TimeUnit.MILLISECONDS);
-                  }
-                  catch (InterruptedException e)
-                  {
-                  }
-               }
-
-               response = null;
-
-               if (resendCache != null && packet.isRequiresConfirmations())
-               {
-                  resendCache.add(packet);
-               }
-
-               connection.transportConnection.write(buffer);
-
-               long toWait = connection.blockingCallTimeout;
-
-               long start = System.currentTimeMillis();
-
-               while (response == null && toWait > 0)
-               {
-                  try
-                  {
-                     sendCondition.await(toWait, TimeUnit.MILLISECONDS);
-                  }
-                  catch (InterruptedException e)
-                  {
-                  }
-
-                  final long now = System.currentTimeMillis();
-
-                  toWait -= now - start;
-
-                  start = now;
-               }
-
-               if (response == null)
-               {
-                  throw new MessagingException(MessagingException.CONNECTION_TIMEDOUT,
-                                               "Timed out waiting for response when sending packet " + packet.getType());
-               }
-
-               if (response.getType() == PacketImpl.EXCEPTION)
-               {
-                  final MessagingExceptionMessage mem = (MessagingExceptionMessage)response;
-
-                  throw mem.getException();
-               }
-               else
-               {
-                  return response;
-               }
-            }
-            finally
-            {
-               lock.unlock();
-            }
-         }
-      }
-
-      // Must be synchronized since can be called by incoming session commands but also by deliveries
-      // Also needs to be synchronized with respect to replicatingChannelDead
-      public DelayedResult replicatePacket(final Packet packet)
-      {
-         synchronized (replicationLock)
-         {
-            if (replicatingChannel != null)
-            {
-               DelayedResult result = new DelayedResult();
-
-               responseActions.add(result);
-
-               responseActionCount++;
-
-               replicatingChannel.send(packet);
-
-               return result;
-            }
-            else
-            {
-               return null;
-            }
-         }
-      }
-
-      // The replicating connection has died (backup has died)
-      public void replicatingChannelDead()
-      {
-         synchronized (replicationLock)
-         {
-            replicatingChannel = null;
-
-            // Execute all the response actions now
-
-            while (true)
-            {
-               DelayedResult result = responseActions.poll();
-
-               if (result != null)
-               {
-                  result.replicated();
-               }
-               else
-               {
-                  break;
-               }
-            }
-
-            responseActionCount = 0;
-         }
-      }
-
-      public void replicateComplete()
-      {      
-         if (!connection.active)
-         {
-            // We're on backup so send back a replication response
-
-            Packet packet = new PacketImpl(REPLICATION_RESPONSE);
-
-            packet.setChannelID(id);
-
-            doWrite(packet);
-         }
-      }
-
-      // This will never get called concurrently by more than one thread
-
-      private int responseActionCount;
-
-      // TODO it's not ideal synchronizing this since it forms a contention point with replication
-      // but we need to do this to protect it w.r.t. the check on replicatingChannel
-      public void replicateResponseReceived()
-      {
-         DelayedResult result = null;
-
-         synchronized (replicationLock)
-         {
-            if (replicatingChannel != null)
-            {
-               result = responseActions.poll();
-
-               if (result == null)
-               {
-                  throw new IllegalStateException("Cannot find response action");
-               }
-            }
-         }
-
-         // Must execute outside of lock
-         if (result != null)
-         {
-            result.replicated();
-
-            // TODO - we can optimise this not to lock every time - only if waiting for all replications to return
-            synchronized (replicationLock)
-            {
-               responseActionCount--;
-
-               if (responseActionCount == 0)
-               {
-                  replicationLock.notify();
-               }
-            }
-         }
-      }
-
-      private void waitForAllReplicationResponse()
-      {
-         synchronized (replicationLock)
-         {
-            if (replicatingChannel != null)
-            {
-               long toWait = 10000; // TODO don't hardcode timeout
-
-               long start = System.currentTimeMillis();
-
-               while (responseActionCount > 0 && toWait > 0)
-               {
-                  try
-                  {
-                     replicationLock.wait();
-                  }
-                  catch (InterruptedException e)
-                  {
-                  }
-
-                  long now = System.currentTimeMillis();
-
-                  toWait -= now - start;
-
-                  start = now;
-               }
-
-               if (toWait <= 0)
-               {
-                  log.warn("Timed out waiting for replication responses to return");
-               }
-            }
-         }
-      }
-
-      public void setHandler(final ChannelHandler handler)
-      {
-         this.handler = handler;
-      }
-
-      public void close()
-      {
-         if (closed)
-         {
-            return;
-         }
-
-         if (!connection.destroyed && connection.channels.remove(id) == null)
-         {
-            throw new IllegalArgumentException("Cannot find channel with id " + id + " to close");
-         }
-
-         if (replicatingChannel != null)
-         {
-            replicatingChannel.close();
-         }
-
-         closed = true;
-      }
-
-      public Channel getReplicatingChannel()
-      {
-         return replicatingChannel;
-      }
-
-      public void transferConnection(final RemotingConnection newConnection)
-      {
-         // Needs to synchronize on the connection to make sure no packets from
-         // the old connection get processed after transfer has occurred
-         synchronized (connection.transferLock)
-         {
-            connection.channels.remove(id);
-
-            // If we're reconnecting to a live node which is replicated then there will be a replicating channel
-            // too. We need to then make sure that all replication responses come back since packets aren't
-            // considered confirmed until response comes back and is processed. Otherwise responses to previous
-            // message sends could come back after reconnection resulting in clients resending same message
-            // since it wasn't confirmed yet.
-            waitForAllReplicationResponse();
-
-            // And switch it
-
-            final RemotingConnectionImpl rnewConnection = (RemotingConnectionImpl)newConnection;
-
-            if (rnewConnection.channels.containsKey(id))
-            {
-               throw new IllegalStateException("Backup connection already has channel with id " + id);
-            }
-
-            rnewConnection.channels.put(id, this);
-
-            connection = rnewConnection;
-         }
-      }
-
-      public void replayCommands(final int otherLastReceivedCommandID)
-      {
-         clearUpTo(otherLastReceivedCommandID);
-
-         for (final Packet packet : resendCache)
-         {
-            doWrite(packet);
-         }
-      }
-
-      public void lock()
-      {
-         lock.lock();
-
-         failingOver = true;
-
-         lock.unlock();
-      }
-
-      public void unlock()
-      {
-         lock.lock();
-
-         failingOver = false;
-
-         failoverCondition.signalAll();
-
-         lock.unlock();
-      }
-
-      public RemotingConnection getConnection()
-      {
-         return connection;
-      }
-
-      private void handlePacket(final Packet packet)
-      {     
-         if (packet.getType() == PACKETS_CONFIRMED)
-         {
-            if (resendCache != null)
-            {
-               final PacketsConfirmedMessage msg = (PacketsConfirmedMessage)packet;
-
-               clearUpTo(msg.getCommandID());
-            }
-            else if (replicatingChannel != null)
-            {
-               replicatingChannel.send(packet);
-            }
-            else
-            {
-               handler.handlePacket(packet);
-            }
-
-            return;
-         }
-         else
-         {
-            if (connection.interceptors != null)
-            {
-               for (final Interceptor interceptor : connection.interceptors)
-               {
-                  try
-                  {
-                     boolean callNext = interceptor.intercept(packet, connection);
-
-                     if (!callNext)
-                     {
-                        // abort
-
-                        return;
-                     }
-                  }
-                  catch (final Throwable e)
-                  {
-                     log.warn("Failure in calling interceptor: " + interceptor, e);
-                  }
-               }
-            }
-
-            if (packet.isResponse())
-            {           
-               response = packet;
-
-               confirm(packet);
-
-               lock.lock();
-
-               try
-               {
-                  sendCondition.signal();
-               }
-               finally
-               {
-                  lock.unlock();
-               }
-            }
-            else if (handler != null)
-            {
-               handler.handlePacket(packet);
-            }
-         }
-      }
-
-      private void doWrite(final Packet packet)
-      {
-         final MessagingBuffer buffer = connection.transportConnection.createBuffer(packet.getRequiredBufferSize());
-
-         packet.encode(buffer);
-
-         connection.transportConnection.write(buffer);
-      }
-
-      public void confirm(final Packet packet)
-      {
-         if (resendCache != null && packet.isRequiresConfirmations())
-         {
-            lastReceivedCommandID++;
-
-            receivedBytes += packet.getPacketSize();
-
-            if (receivedBytes >= confWindowSize)
-            {
-               receivedBytes = 0;
-
-               if (connection.active)
-               {
-                  final Packet confirmed = new PacketsConfirmedMessage(lastReceivedCommandID);
-
-                  confirmed.setChannelID(id);
-
-                  doWrite(confirmed);
-               }
-            }
-         }
-      }
-
-      private void clearUpTo(final int lastReceivedCommandID)
-      {
-         final int numberToClear = 1 + lastReceivedCommandID - firstStoredCommandID;
-
-         if (numberToClear == -1)
-         {
-            throw new IllegalArgumentException("Invalid lastReceivedCommandID: " + lastReceivedCommandID);
-         }
-
-         int sizeToFree = 0;
-
-         for (int i = 0; i < numberToClear; i++)
-         {
-            final Packet packet = resendCache.poll();
-
-            if (packet == null)
-            {
-               throw new IllegalStateException(System.identityHashCode(this) + " Can't find packet to clear: " +
-                                               " last received command id " +
-                                               lastReceivedCommandID +
-                                               " first stored command id " +
-                                               firstStoredCommandID +
-                                               " cache size " +
-                                               this.resendCache.size() +
-                                               " channel id " +
-                                               id +
-                                               " client " +
-                                               connection.client +
-                                               " created active " +
-                                               connection.createdActive);
-            }
-
-            if (packet.getType() != PACKETS_CONFIRMED)
-            {
-               sizeToFree += packet.getPacketSize();
-            }
-         }
-
-         firstStoredCommandID += numberToClear;
-
-         if (sendSemaphore != null)
-         {
-            sendSemaphore.release(sizeToFree);
-         }
-      }
-
-      private class ReplicatedPacketsConfirmedChannelHandler implements ChannelHandler
-      {
-         public void handlePacket(final Packet packet)
-         {
-            switch (packet.getType())
-            {
-               case REPLICATION_RESPONSE:
-               {
-                  replicateResponseReceived();
-
-                  break;
-               }
-               default:
-               {
-                  throw new IllegalArgumentException("Invalid packet " + packet);
-               }
-            }
-         }
-      }
-   }
-
-   private class Pinger implements Runnable
-   {
-      public synchronized void run()
-      {
-         if (!firstTime && !gotPong)
-         {
-            // Error - didn't get pong back
-            final MessagingException me = new MessagingException(MessagingException.NOT_CONNECTED,
-                                                                 "Did not receive pong from server, active " + createdActive +
-                                                                          " client " +
-                                                                          client);
-
-            fail(me);
-         }
-
-         gotPong = false;
-
-         firstTime = false;
-
-         // Send ping
-         final Packet ping = new Ping(connectionTTL);
-
-         pingChannel.send(ping);
-      }
-   }
-
-   private class PingPongHandler implements ChannelHandler
-   {
-      public void handlePacket(final Packet packet)
-      {
-         final byte type = packet.getType();
-
-         if (type == PONG)
-         {
-            gotPong = true;
-
-            if (stopPinging)
-            {
-               future.cancel(true);
-            }
-         }
-         else if (type == PING)
-         {
-            // connectionTTL if specified on the server overrides any value specified in the ping.
-
-            long connectionTTLToUse = connectionTTL != -1 ? connectionTTL : ((Ping)packet).getExpirePeriod();
-
-            expireTime = System.currentTimeMillis() + connectionTTLToUse;
-
-            // Parameter is placeholder for future
-            final Packet pong = new Pong(-1);
-
-            pingChannel.send(pong);
-         }
-         else
-         {
-            throw new IllegalArgumentException("Invalid packet: " + packet);
-         }
-      }
-   }
-
-   private class ReplicatingConnectionFailureListener implements FailureListener
-   {
-      public boolean connectionFailed(final MessagingException me)
-      {
-         synchronized (RemotingConnectionImpl.this)
-         {
-            for (Channel channel : channels.values())
-            {
-               channel.replicatingChannelDead();
-            }
-         }
-
-         return true;
-      }
-   }
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/RemotingConnectionImpl.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/RemotingConnectionImpl.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/RemotingConnectionImpl.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/RemotingConnectionImpl.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,1635 @@
+/*
+ * JBoss, Home of Professional Open Source Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors by
+ * the @authors tag. See the copyright.txt in the distribution for a full listing of individual contributors. This is
+ * free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version.
+ * This software is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
+ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
+ * details. You should have received a copy of the GNU Lesser General Public License along with this software; if not,
+ * write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA, or see the FSF
+ * site: http://www.fsf.org.
+ */
+
+package org.jboss.messaging.core.remoting.impl;
+
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.CREATESESSION;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.CREATESESSION_RESP;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.EARLY_RESPONSE;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.EXCEPTION;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.NULL_RESPONSE;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.PACKETS_CONFIRMED;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.PING;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.PONG;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.REATTACH_SESSION;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.REATTACH_SESSION_RESP;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.REPLICATE_CREATESESSION;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.REPLICATION_RESPONSE;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_ACKNOWLEDGE;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_ADD_DESTINATION;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_BINDINGQUERY;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_BINDINGQUERY_RESP;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_CLOSE;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_COMMIT;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_CONSUMER_CLOSE;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_CREATECONSUMER;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_CREATEQUEUE;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_DELETE_QUEUE;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_EXPIRED;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_FAILOVER_COMPLETE;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_FLOWTOKEN;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_QUEUEQUERY;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_QUEUEQUERY_RESP;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_RECEIVE_CONTINUATION;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_RECEIVE_MSG;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_REMOVE_DESTINATION;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_REPLICATE_DELIVERY;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_ROLLBACK;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_SEND;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_SEND_CONTINUATION;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_START;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_STOP;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_XA_COMMIT;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_XA_END;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_XA_FORGET;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_XA_GET_TIMEOUT;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_XA_GET_TIMEOUT_RESP;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_XA_INDOUBT_XIDS;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_XA_INDOUBT_XIDS_RESP;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_XA_JOIN;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_XA_PREPARE;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_XA_RESP;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_XA_RESUME;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_XA_ROLLBACK;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_XA_SET_TIMEOUT;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_XA_SET_TIMEOUT_RESP;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_XA_START;
+import static org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl.SESS_XA_SUSPEND;
+
+import java.util.ArrayList;
+import java.util.List;
+import java.util.Map;
+import java.util.Queue;
+import java.util.concurrent.ConcurrentHashMap;
+import java.util.concurrent.ConcurrentLinkedQueue;
+import java.util.concurrent.CopyOnWriteArrayList;
+import java.util.concurrent.ScheduledExecutorService;
+import java.util.concurrent.ScheduledFuture;
+import java.util.concurrent.Semaphore;
+import java.util.concurrent.TimeUnit;
+import java.util.concurrent.locks.Condition;
+import java.util.concurrent.locks.Lock;
+import java.util.concurrent.locks.ReentrantLock;
+
+import org.jboss.messaging.core.exception.MessagingException;
+import org.jboss.messaging.core.logging.Logger;
+import org.jboss.messaging.core.remoting.Channel;
+import org.jboss.messaging.core.remoting.ChannelHandler;
+import org.jboss.messaging.core.remoting.DelayedResult;
+import org.jboss.messaging.core.remoting.FailureListener;
+import org.jboss.messaging.core.remoting.Interceptor;
+import org.jboss.messaging.core.remoting.Packet;
+import org.jboss.messaging.core.remoting.RemotingConnection;
+import org.jboss.messaging.core.remoting.impl.wireformat.CreateSessionMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.CreateSessionResponseMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.MessagingExceptionMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.NullResponseMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.PacketImpl;
+import org.jboss.messaging.core.remoting.impl.wireformat.PacketsConfirmedMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.Ping;
+import org.jboss.messaging.core.remoting.impl.wireformat.Pong;
+import org.jboss.messaging.core.remoting.impl.wireformat.ReattachSessionMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.ReattachSessionResponseMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.ReplicateCreateSessionMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.SessionAcknowledgeMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.SessionAddDestinationMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.SessionBindingQueryMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.SessionBindingQueryResponseMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.SessionCloseMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.SessionConsumerCloseMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.SessionConsumerFlowCreditMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.SessionCreateConsumerMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.SessionCreateQueueMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.SessionDeleteQueueMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.SessionExpiredMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.SessionFailoverCompleteMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.SessionQueueQueryMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.SessionQueueQueryResponseMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.SessionReceiveContinuationMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.SessionReceiveMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.SessionRemoveDestinationMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.SessionReplicateDeliveryMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.SessionSendContinuationMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.SessionSendMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.SessionXACommitMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.SessionXAEndMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.SessionXAForgetMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.SessionXAGetInDoubtXidsResponseMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.SessionXAGetTimeoutResponseMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.SessionXAJoinMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.SessionXAPrepareMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.SessionXAResponseMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.SessionXAResumeMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.SessionXARollbackMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.SessionXASetTimeoutMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.SessionXASetTimeoutResponseMessage;
+import org.jboss.messaging.core.remoting.impl.wireformat.SessionXAStartMessage;
+import org.jboss.messaging.core.remoting.spi.Connection;
+import org.jboss.messaging.core.remoting.spi.ConnectionLifeCycleListener;
+import org.jboss.messaging.core.remoting.spi.Connector;
+import org.jboss.messaging.core.remoting.spi.ConnectorFactory;
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+import org.jboss.messaging.util.SimpleIDGenerator;
+
+/**
+ * @author <a href="tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:jmesnil at redhat.com">Jeff Mesnil</a>
+ * @version <tt>$Revision: 5792 $</tt> $Id: RemotingConnectionImpl.java 5792 2009-02-03 09:07:23Z timfox $
+ */
+public class RemotingConnectionImpl extends AbstractBufferHandler implements RemotingConnection
+{
+   // Constants
+   // ------------------------------------------------------------------------------------
+
+   private static final Logger log = Logger.getLogger(RemotingConnectionImpl.class);
+
+   // Static
+   // ---------------------------------------------------------------------------------------
+
+   public static RemotingConnection createConnection(final ConnectorFactory connectorFactory,
+                                                     final Map<String, Object> params,
+                                                     final long callTimeout,
+                                                     final long pingInterval,
+                                                     final long connectionTTL,
+                                                     final ScheduledExecutorService pingExecutor,
+                                                     final ConnectionLifeCycleListener listener)
+   {
+      DelegatingBufferHandler handler = new DelegatingBufferHandler();
+
+      Connector connector = connectorFactory.createConnector(params, handler, listener);
+
+      connector.start();
+
+      Connection tc = connector.createConnection();
+
+      if (tc == null)
+      {
+         throw new IllegalStateException("Failed to connect");
+      }
+
+      RemotingConnection connection = new RemotingConnectionImpl(tc,
+                                                                 callTimeout,
+                                                                 pingInterval,
+                                                                 connectionTTL,
+                                                                 pingExecutor,
+                                                                 null);
+
+      handler.conn = connection;
+
+      return connection;
+   }
+
+   private static class DelegatingBufferHandler extends AbstractBufferHandler
+   {
+      RemotingConnection conn;
+
+      public void bufferReceived(final Object connectionID, final MessagingBuffer buffer)
+      {
+         conn.bufferReceived(connectionID, buffer);
+      }
+   }
+
+   // Attributes
+   // -----------------------------------------------------------------------------------
+
+   private final Connection transportConnection;
+
+   private final Map<Long, ChannelImpl> channels = new ConcurrentHashMap<Long, ChannelImpl>();
+
+   private final List<FailureListener> failureListeners = new CopyOnWriteArrayList<FailureListener>();
+
+   private final long blockingCallTimeout;
+
+   private Runnable pinger;
+
+   private final List<Interceptor> interceptors;
+
+   private ScheduledFuture<?> future;
+
+   private boolean firstTime = true;
+
+   private volatile boolean gotPong;
+
+   private volatile boolean destroyed;
+
+   private volatile boolean stopPinging;
+
+   private volatile long expireTime = -1;
+
+   private final Channel pingChannel;
+
+   private volatile RemotingConnection replicatingConnection;
+
+   private volatile boolean active;
+
+   private final boolean client;
+
+   private final long pingPeriod;
+
+   // How long without a ping before the connection times out
+   private final long connectionTTL;
+
+   private final ScheduledExecutorService pingExecutor;
+
+   // Channels 0-9 are reserved for the system
+   // 0 is for pinging
+   // 1 is for session creation and attachment
+   private volatile SimpleIDGenerator idGenerator = new SimpleIDGenerator(10);
+
+   private boolean idGeneratorSynced = false;
+
+   private final Object transferLock = new Object();
+
+   private final ChannelHandler ppHandler = new PingPongHandler();
+
+   private boolean frozen;
+
+   private final Object failLock = new Object();
+
+   // debug only stuff
+
+   private boolean createdActive;
+
+   // Constructors
+   // ---------------------------------------------------------------------------------
+
+   /*
+    * Create a client side connection
+    */
+   public RemotingConnectionImpl(final Connection transportConnection,
+                                 final long blockingCallTimeout,
+                                 final long pingPeriod,
+                                 final long connectionTTL,
+                                 final ScheduledExecutorService pingExecutor,
+                                 final List<Interceptor> interceptors)
+   {
+      this(transportConnection,
+           blockingCallTimeout,
+           pingPeriod,
+           connectionTTL,
+           pingExecutor,
+           interceptors,
+           null,
+           true,
+           true);
+   }
+
+   /*
+    * Create a server side connection
+    */
+   public RemotingConnectionImpl(final Connection transportConnection,
+                                 final List<Interceptor> interceptors,
+                                 final RemotingConnection replicatingConnection,
+                                 final boolean active,
+                                 final long connectionTTL)
+
+   {
+      this(transportConnection, -1, -1, connectionTTL, null, interceptors, replicatingConnection, active, false);
+   }
+
+   private RemotingConnectionImpl(final Connection transportConnection,
+                                  final long blockingCallTimeout,
+                                  final long pingPeriod,
+                                  final long connectionTTL,
+                                  final ScheduledExecutorService pingExecutor,
+                                  final List<Interceptor> interceptors,
+                                  final RemotingConnection replicatingConnection,
+                                  final boolean active,
+                                  final boolean client)
+
+   {      
+      this.transportConnection = transportConnection;
+
+      this.blockingCallTimeout = blockingCallTimeout;
+
+      this.interceptors = interceptors;
+
+      this.replicatingConnection = replicatingConnection;
+
+      if (replicatingConnection != null)
+      {
+         replicatingConnection.addFailureListener(new ReplicatingConnectionFailureListener());
+      }
+
+      this.active = active;
+
+      this.pingPeriod = pingPeriod;
+
+      this.connectionTTL = connectionTTL;
+
+      this.pingExecutor = pingExecutor;
+
+      // Channel zero is reserved for pinging
+      pingChannel = getChannel(0, -1, false);
+
+      pingChannel.setHandler(ppHandler);
+
+      this.client = client;
+
+      this.createdActive = active;
+   }
+
+   public void startPinger()
+   {
+      if (pingPeriod != -1)
+      {
+         pinger = new Pinger();
+
+         future = pingExecutor.scheduleWithFixedDelay(pinger, 0, pingPeriod, TimeUnit.MILLISECONDS);
+      }
+      else
+      {
+         pinger = null;
+      }
+   }
+
+   // RemotingConnection implementation
+   // ------------------------------------------------------------
+
+   public List<FailureListener> getFailureListeners()
+   {
+      return new ArrayList<FailureListener>(failureListeners);
+   }
+
+   public void setFailureListeners(final List<FailureListener> listeners)
+   {
+      this.failureListeners.clear();
+
+      this.failureListeners.addAll(listeners);
+   }
+
+   public Object getID()
+   {
+      return transportConnection.getID();
+   }
+
+   public String getRemoteAddress()
+   {
+      return transportConnection.getRemoteAddress();
+   }
+
+   public synchronized Channel getChannel(final long channelID, final int windowSize, final boolean block)
+   {
+      ChannelImpl channel = channels.get(channelID);
+
+      if (channel == null)
+      {
+         channel = new ChannelImpl(this, channelID, windowSize, block);
+
+         channels.put(channelID, channel);
+      }
+
+      return channel;
+   }
+
+   public void addFailureListener(final FailureListener listener)
+   {
+      if (listener == null)
+      {
+         throw new IllegalStateException("FailureListener cannot be null");
+      }
+
+      failureListeners.add(listener);
+   }
+
+   public boolean removeFailureListener(final FailureListener listener)
+   {
+      if (listener == null)
+      {
+         throw new IllegalStateException("FailureListener cannot be null");
+      }
+
+      return failureListeners.remove(listener);
+   }
+
+   public MessagingBuffer createBuffer(final int size)
+   {
+      return transportConnection.createBuffer(size);
+   }
+
+   public RemotingConnection getReplicatingConnection()
+   {
+      return replicatingConnection;
+   }
+
+   public void setReplicatingConnection(final RemotingConnection connection)
+   {
+      this.replicatingConnection = connection;
+   }
+
+   /*
+    * This can be called concurrently by more than one thread so needs to be locked
+    */
+   public void fail(final MessagingException me)
+   {
+      synchronized (failLock)
+      {
+         if (destroyed)
+         {
+            return;
+         }
+         
+         destroyed = true;
+      }
+
+      log.warn("Connection failed " + System.identityHashCode(this) + " " + me.getMessage());
+
+      // Then call the listeners
+      callListeners(me);
+
+      internalClose();   
+   }
+
+   public void destroy()
+   {
+      synchronized (failLock)
+      {
+         if (destroyed)
+         {
+            return;
+         }
+         
+         destroyed = true;
+      }
+
+      internalClose();
+
+      // TODO: https://jira.jboss.org/jira/browse/JBMESSAGING-1421
+      // This affects clustering, so I'm keeping this out for now
+      // We need to inform Listeners about the connection being closed
+      // callListeners(null);      
+   }
+
+   public boolean isExpired(final long now)
+   {
+      return expireTime != -1 && now >= expireTime;
+   }
+
+   public long generateChannelID()
+   {
+      return idGenerator.generateID();
+   }
+
+   /* For testing only */
+   public void stopPingingAfterOne()
+   {
+      stopPinging = true;
+   }
+
+   public synchronized void syncIDGeneratorSequence(final long id)
+   {
+      if (!idGeneratorSynced)
+      {
+         idGenerator = new SimpleIDGenerator(id);
+
+         idGeneratorSynced = true;
+      }
+   }
+
+   public long getIDGeneratorSequence()
+   {
+      return idGenerator.getCurrentID();
+   }
+
+   // Buffer Handler implementation
+   // ----------------------------------------------------
+
+   public void bufferReceived(final Object connectionID, final MessagingBuffer buffer)
+   {
+      final Packet packet = decode(buffer);
+      
+      synchronized (transferLock)
+      {
+         if (!frozen)
+         {
+            final ChannelImpl channel = channels.get(packet.getChannelID());
+
+            if (channel != null)
+            {
+               channel.handlePacket(packet);
+            }
+         }
+      }
+   }
+
+   public void activate()
+   {
+      active = true;
+   }
+
+   public void freeze()
+   {
+      // Prevent any more packets being handled on this connection
+
+      synchronized (transferLock)
+      {
+         frozen = true;
+      }
+   }
+
+   // Package protected
+   // ----------------------------------------------------------------------------
+
+   // Protected
+   // ------------------------------------------------------------------------------------
+
+   // Private
+   // --------------------------------------------------------------------------------------
+
+   private void callListeners(final MessagingException me)
+   {
+      final List<FailureListener> listenersClone = new ArrayList<FailureListener>(failureListeners);
+
+      for (final FailureListener listener : listenersClone)
+      {
+         try
+         {
+            boolean callNext = listener.connectionFailed(me);
+
+            if (!callNext)
+            {
+               break;
+            }
+         }
+         catch (final Throwable t)
+         {
+            // Failure of one listener to execute shouldn't prevent others
+            // from
+            // executing
+            log.error("Failed to execute failure listener", t);
+         }
+      }
+   }
+
+   private void internalClose()
+   {
+      if (future != null)
+      {
+         future.cancel(false);
+      }
+
+      pingChannel.close();
+
+      // We close the underlying transport connection
+      transportConnection.close();
+
+      if (replicatingConnection != null)
+      {
+         replicatingConnection.destroy();
+      }
+
+      for (Channel channel : channels.values())
+      {
+         channel.close();
+      }
+   }
+
+   private Packet decode(final MessagingBuffer in)
+   {
+      final byte packetType = in.getByte();
+
+      Packet packet;
+
+      switch (packetType)
+      {
+         case PING:
+         {
+            packet = new Ping();
+            break;
+         }
+         case PONG:
+         {
+            packet = new PacketImpl(PacketImpl.PONG);
+            break;
+         }
+         case EXCEPTION:
+         {
+            packet = new MessagingExceptionMessage();
+            break;
+         }
+         case PACKETS_CONFIRMED:
+         {
+            packet = new PacketsConfirmedMessage();
+            break;
+         }
+         case REPLICATION_RESPONSE:
+         {
+            packet = new PacketImpl(REPLICATION_RESPONSE);
+            break;
+         }
+         case CREATESESSION:
+         {
+            packet = new CreateSessionMessage();
+            break;
+         }
+         case REPLICATE_CREATESESSION:
+         {
+            packet = new ReplicateCreateSessionMessage();
+            break;
+         }
+         case CREATESESSION_RESP:
+         {
+            packet = new CreateSessionResponseMessage();
+            break;
+         }
+         case REATTACH_SESSION:
+         {
+            packet = new ReattachSessionMessage();
+            break;
+         }
+         case REATTACH_SESSION_RESP:
+         {
+            packet = new ReattachSessionResponseMessage();
+            break;
+         }
+         case SESS_FAILOVER_COMPLETE:
+         {
+            packet = new SessionFailoverCompleteMessage();
+            break;
+         }
+         case SESS_CLOSE:
+         {
+            packet = new SessionCloseMessage();
+            break;
+         }
+         case SESS_CREATECONSUMER:
+         {
+            packet = new SessionCreateConsumerMessage();
+            break;
+         }
+         case SESS_ACKNOWLEDGE:
+         {
+            packet = new SessionAcknowledgeMessage();
+            break;
+         }
+         case SESS_EXPIRED:
+         {
+            packet = new SessionExpiredMessage();
+            break;
+         }
+         case SESS_COMMIT:
+         {
+            packet = new PacketImpl(PacketImpl.SESS_COMMIT);
+            break;
+         }
+         case SESS_ROLLBACK:
+         {
+            packet = new PacketImpl(PacketImpl.SESS_ROLLBACK);
+            break;
+         }
+         case SESS_QUEUEQUERY:
+         {
+            packet = new SessionQueueQueryMessage();
+            break;
+         }
+         case SESS_QUEUEQUERY_RESP:
+         {
+            packet = new SessionQueueQueryResponseMessage();
+            break;
+         }
+         case SESS_CREATEQUEUE:
+         {
+            packet = new SessionCreateQueueMessage();
+            break;
+         }
+         case SESS_DELETE_QUEUE:
+         {
+            packet = new SessionDeleteQueueMessage();
+            break;
+         }
+         case SESS_ADD_DESTINATION:
+         {
+            packet = new SessionAddDestinationMessage();
+            break;
+         }
+         case SESS_REMOVE_DESTINATION:
+         {
+            packet = new SessionRemoveDestinationMessage();
+            break;
+         }
+         case SESS_BINDINGQUERY:
+         {
+            packet = new SessionBindingQueryMessage();
+            break;
+         }
+         case SESS_BINDINGQUERY_RESP:
+         {
+            packet = new SessionBindingQueryResponseMessage();
+            break;
+         }
+         case SESS_XA_START:
+         {
+            packet = new SessionXAStartMessage();
+            break;
+         }
+         case SESS_XA_END:
+         {
+            packet = new SessionXAEndMessage();
+            break;
+         }
+         case SESS_XA_COMMIT:
+         {
+            packet = new SessionXACommitMessage();
+            break;
+         }
+         case SESS_XA_PREPARE:
+         {
+            packet = new SessionXAPrepareMessage();
+            break;
+         }
+         case SESS_XA_RESP:
+         {
+            packet = new SessionXAResponseMessage();
+            break;
+         }
+         case SESS_XA_ROLLBACK:
+         {
+            packet = new SessionXARollbackMessage();
+            break;
+         }
+         case SESS_XA_JOIN:
+         {
+            packet = new SessionXAJoinMessage();
+            break;
+         }
+         case SESS_XA_SUSPEND:
+         {
+            packet = new PacketImpl(PacketImpl.SESS_XA_SUSPEND);
+            break;
+         }
+         case SESS_XA_RESUME:
+         {
+            packet = new SessionXAResumeMessage();
+            break;
+         }
+         case SESS_XA_FORGET:
+         {
+            packet = new SessionXAForgetMessage();
+            break;
+         }
+         case SESS_XA_INDOUBT_XIDS:
+         {
+            packet = new PacketImpl(PacketImpl.SESS_XA_INDOUBT_XIDS);
+            break;
+         }
+         case SESS_XA_INDOUBT_XIDS_RESP:
+         {
+            packet = new SessionXAGetInDoubtXidsResponseMessage();
+            break;
+         }
+         case SESS_XA_SET_TIMEOUT:
+         {
+            packet = new SessionXASetTimeoutMessage();
+            break;
+         }
+         case SESS_XA_SET_TIMEOUT_RESP:
+         {
+            packet = new SessionXASetTimeoutResponseMessage();
+            break;
+         }
+         case SESS_XA_GET_TIMEOUT:
+         {
+            packet = new PacketImpl(PacketImpl.SESS_XA_GET_TIMEOUT);
+            break;
+         }
+         case SESS_XA_GET_TIMEOUT_RESP:
+         {
+            packet = new SessionXAGetTimeoutResponseMessage();
+            break;
+         }
+         case SESS_START:
+         {
+            packet = new PacketImpl(PacketImpl.SESS_START);
+            break;
+         }
+         case SESS_STOP:
+         {
+            packet = new PacketImpl(PacketImpl.SESS_STOP);
+            break;
+         }
+         case SESS_FLOWTOKEN:
+         {
+            packet = new SessionConsumerFlowCreditMessage();
+            break;
+         }
+         case SESS_SEND:
+         {
+            packet = new SessionSendMessage();
+            break;
+         }
+         case SESS_RECEIVE_MSG:
+         {
+            packet = new SessionReceiveMessage();
+            break;
+         }
+         case SESS_CONSUMER_CLOSE:
+         {
+            packet = new SessionConsumerCloseMessage();
+            break;
+         }
+         case NULL_RESPONSE:
+         {
+            packet = new NullResponseMessage();
+            break;
+         }
+         case SESS_RECEIVE_CONTINUATION:
+         {
+            packet = new SessionReceiveContinuationMessage();
+            break;
+         }
+         case SESS_SEND_CONTINUATION:
+         {
+            packet = new SessionSendContinuationMessage();
+            break;
+         }
+         case SESS_REPLICATE_DELIVERY:
+         {
+            packet = new SessionReplicateDeliveryMessage();
+            break;
+         }
+         default:
+         {
+            throw new IllegalArgumentException("Invalid type: " + packetType);
+         }
+      }
+
+      packet.decode(in);
+
+      return packet;
+   }
+
+   // Inner classes
+   // --------------------------------------------------------------------------------
+
+   // Needs to be static so we can re-assign it to another remotingconnection
+   private static class ChannelImpl implements Channel
+   {
+      private final long id;
+
+      private ChannelHandler handler;
+
+      private Packet response;
+
+      private final java.util.Queue<Packet> resendCache;
+
+      private volatile int firstStoredCommandID;
+
+      private volatile int lastReceivedCommandID = -1;
+
+      private Channel replicatingChannel;
+
+      private volatile RemotingConnectionImpl connection;
+
+      private volatile boolean closed;
+
+      private final Lock lock = new ReentrantLock();
+
+      private final Condition sendCondition = lock.newCondition();
+
+      private final Condition failoverCondition = lock.newCondition();
+
+      private final Object sendLock = new Object();
+
+      private final Object sendBlockingLock = new Object();
+
+      private final Object replicationLock = new Object();
+
+      private boolean failingOver;
+
+      private final Queue<DelayedResult> responseActions = new ConcurrentLinkedQueue<DelayedResult>();
+
+      private final int windowSize;
+
+      private final int confWindowSize;
+
+      private final Semaphore sendSemaphore;
+
+      private int receivedBytes;
+
+      private ChannelImpl(final RemotingConnectionImpl connection,
+                          final long id,
+                          final int windowSize,
+                          final boolean block)
+      {
+         this.connection = connection;
+
+         this.id = id;
+
+         if (connection.replicatingConnection != null && id != 0)
+         {
+            // We don't redirect the ping channel
+
+            replicatingChannel = connection.replicatingConnection.getChannel(id, -1, false);
+
+            replicatingChannel.setHandler(new ReplicatedPacketsConfirmedChannelHandler());
+         }
+         this.windowSize = windowSize;
+
+         this.confWindowSize = (int)(0.75 * windowSize);
+
+         if (this.windowSize != -1)
+         {
+            resendCache = new ConcurrentLinkedQueue<Packet>();
+
+            if (block)
+            {
+               sendSemaphore = new Semaphore(windowSize, true);
+            }
+            else
+            {
+               sendSemaphore = null;
+            }
+         }
+         else
+         {
+            resendCache = null;
+
+            sendSemaphore = null;
+         }
+      }
+
+      public long getID()
+      {
+         return id;
+      }
+
+      public int getLastReceivedCommandID()
+      {
+         return lastReceivedCommandID;
+      }
+
+      public Lock getLock()
+      {
+         return lock;
+      }
+
+      public void returnBlocking()
+      {
+         lock.lock();
+
+         try
+         {
+            response = new PacketImpl(EARLY_RESPONSE);
+
+            sendCondition.signal();
+         }
+         finally
+         {
+            lock.unlock();
+         }
+      }
+
+      // This must never called by more than one thread concurrently
+      public void send(final Packet packet)
+      {
+         synchronized (sendLock)
+         {
+            packet.setChannelID(id);
+
+            final MessagingBuffer buffer = connection.transportConnection.createBuffer(packet.getRequiredBufferSize());
+
+            int size = packet.encode(buffer);
+
+            // Must block on semaphore outside the main lock or this can prevent failover from occurring
+            if (sendSemaphore != null && packet.getType() != PACKETS_CONFIRMED)
+            {
+               try
+               {
+                  sendSemaphore.acquire(size);
+               }
+               catch (InterruptedException e)
+               {
+                  throw new IllegalStateException("Semaphore interrupted");
+               }
+            }
+
+            lock.lock();
+
+            try
+            {
+               while (failingOver)
+               {
+                  // TODO - don't hardcode this timeout
+                  try
+                  {
+                     failoverCondition.await(10000, TimeUnit.MILLISECONDS);
+                  }
+                  catch (InterruptedException e)
+                  {
+                  }
+               }
+
+               if (resendCache != null && packet.isRequiresConfirmations())
+               {
+                  resendCache.add(packet);
+               }
+
+               if (connection.active || packet.isWriteAlways())
+               {              
+                  connection.transportConnection.write(buffer);
+               }
+            }
+            finally
+            {
+               lock.unlock();
+            }
+         }
+      }
+
+      public Packet sendBlocking(final Packet packet) throws MessagingException
+      {
+         if (closed)
+         {
+            throw new MessagingException(MessagingException.NOT_CONNECTED, "Connection is destroyed");
+         }
+
+         if (connection.blockingCallTimeout == -1)
+         {
+            throw new IllegalStateException("Cannot do a blocking call timeout on a server side connection");
+         }
+
+         // Synchronized since can't be called concurrently by more than one thread and this can occur
+         // E.g. blocking acknowledge() from inside a message handler at some time as other operation on main thread
+         synchronized (sendBlockingLock)
+         {
+            packet.setChannelID(id);
+
+            final MessagingBuffer buffer = connection.transportConnection.createBuffer(packet.getRequiredBufferSize());
+
+            int size = packet.encode(buffer);
+
+            // Must block on semaphore outside the main lock or this can prevent failover from occurring
+            if (sendSemaphore != null)
+            {
+               try
+               {
+                  sendSemaphore.acquire(size);
+               }
+               catch (InterruptedException e)
+               {
+                  throw new IllegalStateException("Semaphore interrupted");
+               }
+            }
+
+            lock.lock();
+
+            try
+            {
+               while (failingOver)
+               {
+                  // TODO - don't hardcode this timeout
+                  try
+                  {
+                     failoverCondition.await(10000, TimeUnit.MILLISECONDS);
+                  }
+                  catch (InterruptedException e)
+                  {
+                  }
+               }
+
+               response = null;
+
+               if (resendCache != null && packet.isRequiresConfirmations())
+               {
+                  resendCache.add(packet);
+               }
+
+               connection.transportConnection.write(buffer);
+
+               long toWait = connection.blockingCallTimeout;
+
+               long start = System.currentTimeMillis();
+
+               while (response == null && toWait > 0)
+               {
+                  try
+                  {
+                     sendCondition.await(toWait, TimeUnit.MILLISECONDS);
+                  }
+                  catch (InterruptedException e)
+                  {
+                  }
+
+                  final long now = System.currentTimeMillis();
+
+                  toWait -= now - start;
+
+                  start = now;
+               }
+
+               if (response == null)
+               {
+                  throw new MessagingException(MessagingException.CONNECTION_TIMEDOUT,
+                                               "Timed out waiting for response when sending packet " + packet.getType());
+               }
+
+               if (response.getType() == PacketImpl.EXCEPTION)
+               {
+                  final MessagingExceptionMessage mem = (MessagingExceptionMessage)response;
+
+                  throw mem.getException();
+               }
+               else
+               {
+                  return response;
+               }
+            }
+            finally
+            {
+               lock.unlock();
+            }
+         }
+      }
+
+      // Must be synchronized since can be called by incoming session commands but also by deliveries
+      // Also needs to be synchronized with respect to replicatingChannelDead
+      public DelayedResult replicatePacket(final Packet packet)
+      {
+         synchronized (replicationLock)
+         {
+            if (replicatingChannel != null)
+            {
+               DelayedResult result = new DelayedResult();
+
+               responseActions.add(result);
+
+               responseActionCount++;
+
+               replicatingChannel.send(packet);
+
+               return result;
+            }
+            else
+            {
+               return null;
+            }
+         }
+      }
+
+      // The replicating connection has died (backup has died)
+      public void replicatingChannelDead()
+      {
+         synchronized (replicationLock)
+         {
+            replicatingChannel = null;
+
+            // Execute all the response actions now
+
+            while (true)
+            {
+               DelayedResult result = responseActions.poll();
+
+               if (result != null)
+               {
+                  result.replicated();
+               }
+               else
+               {
+                  break;
+               }
+            }
+
+            responseActionCount = 0;
+         }
+      }
+
+      public void replicateComplete()
+      {      
+         if (!connection.active)
+         {
+            // We're on backup so send back a replication response
+
+            Packet packet = new PacketImpl(REPLICATION_RESPONSE);
+
+            packet.setChannelID(id);
+
+            doWrite(packet);
+         }
+      }
+
+      // This will never get called concurrently by more than one thread
+
+      private int responseActionCount;
+
+      // TODO it's not ideal synchronizing this since it forms a contention point with replication
+      // but we need to do this to protect it w.r.t. the check on replicatingChannel
+      public void replicateResponseReceived()
+      {
+         DelayedResult result = null;
+
+         synchronized (replicationLock)
+         {
+            if (replicatingChannel != null)
+            {
+               result = responseActions.poll();
+
+               if (result == null)
+               {
+                  throw new IllegalStateException("Cannot find response action");
+               }
+            }
+         }
+
+         // Must execute outside of lock
+         if (result != null)
+         {
+            result.replicated();
+
+            // TODO - we can optimise this not to lock every time - only if waiting for all replications to return
+            synchronized (replicationLock)
+            {
+               responseActionCount--;
+
+               if (responseActionCount == 0)
+               {
+                  replicationLock.notify();
+               }
+            }
+         }
+      }
+
+      private void waitForAllReplicationResponse()
+      {
+         synchronized (replicationLock)
+         {
+            if (replicatingChannel != null)
+            {
+               long toWait = 10000; // TODO don't hardcode timeout
+
+               long start = System.currentTimeMillis();
+
+               while (responseActionCount > 0 && toWait > 0)
+               {
+                  try
+                  {
+                     replicationLock.wait();
+                  }
+                  catch (InterruptedException e)
+                  {
+                  }
+
+                  long now = System.currentTimeMillis();
+
+                  toWait -= now - start;
+
+                  start = now;
+               }
+
+               if (toWait <= 0)
+               {
+                  log.warn("Timed out waiting for replication responses to return");
+               }
+            }
+         }
+      }
+
+      public void setHandler(final ChannelHandler handler)
+      {
+         this.handler = handler;
+      }
+
+      public void close()
+      {
+         if (closed)
+         {
+            return;
+         }
+
+         if (!connection.destroyed && connection.channels.remove(id) == null)
+         {
+            throw new IllegalArgumentException("Cannot find channel with id " + id + " to close");
+         }
+
+         if (replicatingChannel != null)
+         {
+            replicatingChannel.close();
+         }
+
+         closed = true;
+      }
+
+      public Channel getReplicatingChannel()
+      {
+         return replicatingChannel;
+      }
+
+      public void transferConnection(final RemotingConnection newConnection)
+      {
+         // Needs to synchronize on the connection to make sure no packets from
+         // the old connection get processed after transfer has occurred
+         synchronized (connection.transferLock)
+         {
+            connection.channels.remove(id);
+
+            // If we're reconnecting to a live node which is replicated then there will be a replicating channel
+            // too. We need to then make sure that all replication responses come back since packets aren't
+            // considered confirmed until response comes back and is processed. Otherwise responses to previous
+            // message sends could come back after reconnection resulting in clients resending same message
+            // since it wasn't confirmed yet.
+            waitForAllReplicationResponse();
+
+            // And switch it
+
+            final RemotingConnectionImpl rnewConnection = (RemotingConnectionImpl)newConnection;
+
+            if (rnewConnection.channels.containsKey(id))
+            {
+               throw new IllegalStateException("Backup connection already has channel with id " + id);
+            }
+
+            rnewConnection.channels.put(id, this);
+
+            connection = rnewConnection;
+         }
+      }
+
+      public void replayCommands(final int otherLastReceivedCommandID)
+      {
+         clearUpTo(otherLastReceivedCommandID);
+
+         for (final Packet packet : resendCache)
+         {
+            doWrite(packet);
+         }
+      }
+
+      public void lock()
+      {
+         lock.lock();
+
+         failingOver = true;
+
+         lock.unlock();
+      }
+
+      public void unlock()
+      {
+         lock.lock();
+
+         failingOver = false;
+
+         failoverCondition.signalAll();
+
+         lock.unlock();
+      }
+
+      public RemotingConnection getConnection()
+      {
+         return connection;
+      }
+
+      private void handlePacket(final Packet packet)
+      {     
+         if (packet.getType() == PACKETS_CONFIRMED)
+         {
+            if (resendCache != null)
+            {
+               final PacketsConfirmedMessage msg = (PacketsConfirmedMessage)packet;
+
+               clearUpTo(msg.getCommandID());
+            }
+            else if (replicatingChannel != null)
+            {
+               replicatingChannel.send(packet);
+            }
+            else
+            {
+               handler.handlePacket(packet);
+            }
+
+            return;
+         }
+         else
+         {
+            if (connection.interceptors != null)
+            {
+               for (final Interceptor interceptor : connection.interceptors)
+               {
+                  try
+                  {
+                     boolean callNext = interceptor.intercept(packet, connection);
+
+                     if (!callNext)
+                     {
+                        // abort
+
+                        return;
+                     }
+                  }
+                  catch (final Throwable e)
+                  {
+                     log.warn("Failure in calling interceptor: " + interceptor, e);
+                  }
+               }
+            }
+
+            if (packet.isResponse())
+            {           
+               response = packet;
+
+               confirm(packet);
+
+               lock.lock();
+
+               try
+               {
+                  sendCondition.signal();
+               }
+               finally
+               {
+                  lock.unlock();
+               }
+            }
+            else if (handler != null)
+            {
+               handler.handlePacket(packet);
+            }
+         }
+      }
+
+      private void doWrite(final Packet packet)
+      {
+         final MessagingBuffer buffer = connection.transportConnection.createBuffer(packet.getRequiredBufferSize());
+
+         packet.encode(buffer);
+
+         connection.transportConnection.write(buffer);
+      }
+
+      public void confirm(final Packet packet)
+      {
+         if (resendCache != null && packet.isRequiresConfirmations())
+         {
+            lastReceivedCommandID++;
+
+            receivedBytes += packet.getPacketSize();
+
+            if (receivedBytes >= confWindowSize)
+            {
+               receivedBytes = 0;
+
+               if (connection.active)
+               {
+                  final Packet confirmed = new PacketsConfirmedMessage(lastReceivedCommandID);
+
+                  confirmed.setChannelID(id);
+
+                  doWrite(confirmed);
+               }
+            }
+         }
+      }
+
+      private void clearUpTo(final int lastReceivedCommandID)
+      {
+         final int numberToClear = 1 + lastReceivedCommandID - firstStoredCommandID;
+
+         if (numberToClear == -1)
+         {
+            throw new IllegalArgumentException("Invalid lastReceivedCommandID: " + lastReceivedCommandID);
+         }
+
+         int sizeToFree = 0;
+
+         for (int i = 0; i < numberToClear; i++)
+         {
+            final Packet packet = resendCache.poll();
+
+            if (packet == null)
+            {
+               throw new IllegalStateException(System.identityHashCode(this) + " Can't find packet to clear: " +
+                                               " last received command id " +
+                                               lastReceivedCommandID +
+                                               " first stored command id " +
+                                               firstStoredCommandID +
+                                               " cache size " +
+                                               this.resendCache.size() +
+                                               " channel id " +
+                                               id +
+                                               " client " +
+                                               connection.client +
+                                               " created active " +
+                                               connection.createdActive);
+            }
+
+            if (packet.getType() != PACKETS_CONFIRMED)
+            {
+               sizeToFree += packet.getPacketSize();
+            }
+         }
+
+         firstStoredCommandID += numberToClear;
+
+         if (sendSemaphore != null)
+         {
+            sendSemaphore.release(sizeToFree);
+         }
+      }
+
+      private class ReplicatedPacketsConfirmedChannelHandler implements ChannelHandler
+      {
+         public void handlePacket(final Packet packet)
+         {
+            switch (packet.getType())
+            {
+               case REPLICATION_RESPONSE:
+               {
+                  replicateResponseReceived();
+
+                  break;
+               }
+               default:
+               {
+                  throw new IllegalArgumentException("Invalid packet " + packet);
+               }
+            }
+         }
+      }
+   }
+
+   private class Pinger implements Runnable
+   {
+      public synchronized void run()
+      {
+         if (!firstTime && !gotPong)
+         {
+            // Error - didn't get pong back
+            final MessagingException me = new MessagingException(MessagingException.NOT_CONNECTED,
+                                                                 "Did not receive pong from server, active " + createdActive +
+                                                                          " client " +
+                                                                          client);
+
+            fail(me);
+         }
+
+         gotPong = false;
+
+         firstTime = false;
+
+         // Send ping
+         final Packet ping = new Ping(connectionTTL);
+
+         pingChannel.send(ping);
+      }
+   }
+
+   private class PingPongHandler implements ChannelHandler
+   {
+      public void handlePacket(final Packet packet)
+      {
+         final byte type = packet.getType();
+
+         if (type == PONG)
+         {
+            gotPong = true;
+
+            if (stopPinging)
+            {
+               future.cancel(true);
+            }
+         }
+         else if (type == PING)
+         {
+            // connectionTTL if specified on the server overrides any value specified in the ping.
+
+            long connectionTTLToUse = connectionTTL != -1 ? connectionTTL : ((Ping)packet).getExpirePeriod();
+
+            expireTime = System.currentTimeMillis() + connectionTTLToUse;
+
+            // Parameter is placeholder for future
+            final Packet pong = new Pong(-1);
+
+            pingChannel.send(pong);
+         }
+         else
+         {
+            throw new IllegalArgumentException("Invalid packet: " + packet);
+         }
+      }
+   }
+
+   private class ReplicatingConnectionFailureListener implements FailureListener
+   {
+      public boolean connectionFailed(final MessagingException me)
+      {
+         synchronized (RemotingConnectionImpl.this)
+         {
+            for (Channel channel : channels.values())
+            {
+               channel.replicatingChannelDead();
+            }
+         }
+
+         return true;
+      }
+   }
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/RemotingServiceImpl.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/RemotingServiceImpl.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/RemotingServiceImpl.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,370 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors by
- * the @authors tag. See the copyright.txt in the distribution for a full listing of individual contributors. This is
- * free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version.
- * This software is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
- * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
- * details. You should have received a copy of the GNU Lesser General Public License along with this software; if not,
- * write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA, or see the FSF
- * site: http://www.fsf.org.
- */
-
-package org.jboss.messaging.core.remoting.impl;
-
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.HashSet;
-import java.util.List;
-import java.util.Map;
-import java.util.Set;
-import java.util.Timer;
-import java.util.TimerTask;
-import java.util.concurrent.ConcurrentHashMap;
-
-import org.jboss.messaging.core.config.Configuration;
-import org.jboss.messaging.core.config.TransportConfiguration;
-import org.jboss.messaging.core.exception.MessagingException;
-import org.jboss.messaging.core.logging.Logger;
-import org.jboss.messaging.core.management.ManagementService;
-import org.jboss.messaging.core.remoting.Channel;
-import org.jboss.messaging.core.remoting.ChannelHandler;
-import org.jboss.messaging.core.remoting.Interceptor;
-import org.jboss.messaging.core.remoting.RemotingConnection;
-import org.jboss.messaging.core.remoting.RemotingService;
-import org.jboss.messaging.core.remoting.impl.invm.InVMAcceptorFactory;
-import org.jboss.messaging.core.remoting.spi.Acceptor;
-import org.jboss.messaging.core.remoting.spi.AcceptorFactory;
-import org.jboss.messaging.core.remoting.spi.BufferHandler;
-import org.jboss.messaging.core.remoting.spi.Connection;
-import org.jboss.messaging.core.remoting.spi.ConnectionLifeCycleListener;
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-import org.jboss.messaging.core.server.MessagingServer;
-import org.jboss.messaging.core.server.impl.MessagingServerPacketHandler;
-
-/**
- * @author <a href="mailto:jmesnil at redhat.com">Jeff Mesnil</a>
- * @author <a href="mailto:ataylor at redhat.com">Andy Taylor</a>
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * @version <tt>$Revision$</tt>
- */
-public class RemotingServiceImpl implements RemotingService, ConnectionLifeCycleListener
-{
-   // Constants -----------------------------------------------------
-
-   private static final Logger log = Logger.getLogger(RemotingServiceImpl.class);
-
-   // Attributes ----------------------------------------------------
-
-   private volatile boolean started = false;
-
-   private final Set<TransportConfiguration> transportConfigs;
-
-   private final List<Interceptor> interceptors = new ArrayList<Interceptor>();
-
-   private final Set<Acceptor> acceptors = new HashSet<Acceptor>();
-
-   private final Map<Object, RemotingConnection> connections = new ConcurrentHashMap<Object, RemotingConnection>();
-
-   private Timer failedConnectionTimer;
-
-   private TimerTask failedConnectionsTask;
-
-   private final long connectionScanPeriod;
-   
-   private final long connectionTTL;
-
-   private final boolean jmxEnabled;
-
-   private final BufferHandler bufferHandler = new DelegatingBufferHandler();
-
-   private volatile boolean backup;
-
-   private volatile MessagingServer server;
-
-   private ManagementService managementService;
-
-   
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public RemotingServiceImpl(final Configuration config)
-   {
-      transportConfigs = config.getAcceptorConfigurations();
-
-      ClassLoader loader = Thread.currentThread().getContextClassLoader();
-      for (String interceptorClass : config.getInterceptorClassNames())
-      {
-         try
-         {
-            Class<?> clazz = loader.loadClass(interceptorClass);
-            interceptors.add((Interceptor)clazz.newInstance());
-         }
-         catch (Exception e)
-         {
-            log.warn("Error instantiating interceptor \"" + interceptorClass + "\"", e);
-         }
-      }
-
-      connectionScanPeriod = config.getConnectionScanPeriod();
-      
-      connectionTTL = config.getConnectionTTLOverride();
-
-      backup = config.isBackup();  
-      
-      jmxEnabled= config.isJMXManagementEnabled();
-   }
-
-   // RemotingService implementation -------------------------------
-
-   public void setManagementService(final ManagementService managementService)
-   {
-      this.managementService = managementService;
-   }
-   
-   public synchronized void start() throws Exception
-   {
-      if (started)
-      {
-         return;
-      }
-      
-
-      // when JMX is enabled, it requires a INVM acceptor to send the core messages
-      // corresponding to the JMX management operations (@see ReplicationAwareStandardMBeanWrapper)
-      if (jmxEnabled)
-      {
-         boolean invmAcceptorConfigured = false;
-         for (TransportConfiguration config : transportConfigs)
-         {
-            if (InVMAcceptorFactory.class.getName().equals(config.getFactoryClassName()))
-            {
-               invmAcceptorConfigured = true;
-            }
-         }
-         if (!invmAcceptorConfigured)
-         {
-            transportConfigs.add(new TransportConfiguration(InVMAcceptorFactory.class.getName(), new HashMap<String, Object>(), "in-vm"));
-         }
-      }
-
-      ClassLoader loader = Thread.currentThread().getContextClassLoader();
-
-      for (TransportConfiguration info : transportConfigs)
-      {
-         try
-         {
-            Class<?> clazz = loader.loadClass(info.getFactoryClassName());
-
-            AcceptorFactory factory = (AcceptorFactory)clazz.newInstance();
-
-            Acceptor acceptor = factory.createAcceptor(info.getParams(), bufferHandler, this);
-
-            acceptors.add(acceptor);
-
-            if (managementService != null)
-            {
-               managementService.registerAcceptor(acceptor, info);
-            }
-         }
-         catch (Exception e)
-         {
-            log.warn("Error instantiating acceptor \"" + info.getFactoryClassName() + "\"", e);
-         }
-      }
-
-      for (Acceptor a : acceptors)
-      {
-         a.start();
-      }
-      
-      failedConnectionTimer = new Timer(true);
-
-      failedConnectionsTask = new FailedConnectionsTask();
-   
-      failedConnectionTimer.schedule(failedConnectionsTask, connectionScanPeriod, connectionScanPeriod);
-
-      started = true;
-   }
-
-   public synchronized void stop()
-   {
-      if (!started)
-      {
-         return;
-      }
-
-      if (failedConnectionTimer != null)
-      {
-         failedConnectionsTask.cancel();
-
-         failedConnectionsTask = null;
-         
-         failedConnectionTimer.cancel();
-         
-         failedConnectionTimer = null;
-      }
-
-      for (Acceptor acceptor : acceptors)
-      {
-         acceptor.stop();
-      }
-      
-      acceptors.clear();
-      
-      connections.clear();
-
-      started = false;
-   }
-   
-   public boolean isStarted()
-   {
-      return started;
-   }
-
-   public RemotingConnection getConnection(final Object remotingConnectionID)
-   {
-      return connections.get(remotingConnectionID);
-   }
-
-   public synchronized Set<RemotingConnection> getConnections()
-   {
-      return new HashSet<RemotingConnection>(connections.values());
-   }
-
-   public void setMessagingServer(final MessagingServer server)
-   {
-      this.server = server;
-   }
-
-   public void setBackup(final boolean backup)
-   {
-      this.backup = backup;
-   }
-
-   // ConnectionLifeCycleListener implementation -----------------------------------
-
-   public void connectionCreated(final Connection connection)
-   {
-      if (server == null)
-      {
-         throw new IllegalStateException("Unable to create connection, server hasn't finished starting up");
-      }
-      
-      RemotingConnection replicatingConnection = server.getReplicatingConnection();
-
-      RemotingConnection rc = new RemotingConnectionImpl(connection,                                                                                             
-                                                         interceptors,
-                                                         replicatingConnection,
-                                                         !backup,
-                                                         connectionTTL);
-
-      Channel channel1 = rc.getChannel(1,  -1, false);
-
-      ChannelHandler handler = new MessagingServerPacketHandler(server, channel1, rc);
-
-      channel1.setHandler(handler);
-
-      Object id = connection.getID();
-
-      connections.put(id, rc);
-   }
-
-   public void connectionDestroyed(final Object connectionID)
-   {
-      RemotingConnection conn = connections.remove(connectionID);
-      
-      if (conn != null)
-      {
-         conn.destroy();
-      }      
-   }
-
-   public void connectionException(final Object connectionID, final MessagingException me)
-   {
-      RemotingConnection rc = connections.remove(connectionID);
-
-      if (rc != null)
-      {
-         rc.fail(me);
-      }     
-   }
-
-   public void addInterceptor(final Interceptor interceptor)
-   {
-      interceptors.add(interceptor);
-   }
-
-   public boolean removeInterceptor(final Interceptor interceptor)
-   {
-      return interceptors.remove(interceptor);
-   }
-
-   // Public --------------------------------------------------------
-
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-
-   private class FailedConnectionsTask extends TimerTask
-   {
-      private boolean cancelled;
-
-      @Override
-      public synchronized void run()
-      {
-         if (cancelled)
-         {
-            return;
-         }
-
-         Set<RemotingConnection> failedConnections = new HashSet<RemotingConnection>();
-
-         long now = System.currentTimeMillis();
-
-         for (RemotingConnection conn : connections.values())
-         {
-            if (conn.isExpired(now))
-            {
-               failedConnections.add(conn);
-            }
-         }
-
-         for (RemotingConnection conn : failedConnections)
-         {
-            MessagingException me = new MessagingException(MessagingException.CONNECTION_TIMEDOUT,
-                                                           "Did not receive ping on connection. It is likely a client has exited or crashed without " + "closing its connection, or the network between the server and client has failed. The connection will now be closed.");
-
-            conn.fail(me);
-         }
-      }
-
-      @Override
-      public synchronized boolean cancel()
-      {
-         cancelled = true;
-
-         return super.cancel();
-      }
-
-   }
-
-   private class DelegatingBufferHandler extends AbstractBufferHandler
-   {
-      public void bufferReceived(final Object connectionID, final MessagingBuffer buffer)
-      {
-         RemotingConnection conn = connections.get(connectionID);
-
-         if (conn != null)
-         {
-            conn.bufferReceived(connectionID, buffer);
-         }
-      }
-   }
-
-}
\ No newline at end of file

Copied: trunk/dotnet/JBMClient/remoting/impl/RemotingServiceImpl.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/RemotingServiceImpl.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/RemotingServiceImpl.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/RemotingServiceImpl.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,370 @@
+/*
+ * JBoss, Home of Professional Open Source Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors by
+ * the @authors tag. See the copyright.txt in the distribution for a full listing of individual contributors. This is
+ * free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version.
+ * This software is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
+ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
+ * details. You should have received a copy of the GNU Lesser General Public License along with this software; if not,
+ * write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA, or see the FSF
+ * site: http://www.fsf.org.
+ */
+
+package org.jboss.messaging.core.remoting.impl;
+
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.HashSet;
+import java.util.List;
+import java.util.Map;
+import java.util.Set;
+import java.util.Timer;
+import java.util.TimerTask;
+import java.util.concurrent.ConcurrentHashMap;
+
+import org.jboss.messaging.core.config.Configuration;
+import org.jboss.messaging.core.config.TransportConfiguration;
+import org.jboss.messaging.core.exception.MessagingException;
+import org.jboss.messaging.core.logging.Logger;
+import org.jboss.messaging.core.management.ManagementService;
+import org.jboss.messaging.core.remoting.Channel;
+import org.jboss.messaging.core.remoting.ChannelHandler;
+import org.jboss.messaging.core.remoting.Interceptor;
+import org.jboss.messaging.core.remoting.RemotingConnection;
+import org.jboss.messaging.core.remoting.RemotingService;
+import org.jboss.messaging.core.remoting.impl.invm.InVMAcceptorFactory;
+import org.jboss.messaging.core.remoting.spi.Acceptor;
+import org.jboss.messaging.core.remoting.spi.AcceptorFactory;
+import org.jboss.messaging.core.remoting.spi.BufferHandler;
+import org.jboss.messaging.core.remoting.spi.Connection;
+import org.jboss.messaging.core.remoting.spi.ConnectionLifeCycleListener;
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+import org.jboss.messaging.core.server.MessagingServer;
+import org.jboss.messaging.core.server.impl.MessagingServerPacketHandler;
+
+/**
+ * @author <a href="mailto:jmesnil at redhat.com">Jeff Mesnil</a>
+ * @author <a href="mailto:ataylor at redhat.com">Andy Taylor</a>
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @version <tt>$Revision$</tt>
+ */
+public class RemotingServiceImpl implements RemotingService, ConnectionLifeCycleListener
+{
+   // Constants -----------------------------------------------------
+
+   private static final Logger log = Logger.getLogger(RemotingServiceImpl.class);
+
+   // Attributes ----------------------------------------------------
+
+   private volatile boolean started = false;
+
+   private final Set<TransportConfiguration> transportConfigs;
+
+   private final List<Interceptor> interceptors = new ArrayList<Interceptor>();
+
+   private final Set<Acceptor> acceptors = new HashSet<Acceptor>();
+
+   private final Map<Object, RemotingConnection> connections = new ConcurrentHashMap<Object, RemotingConnection>();
+
+   private Timer failedConnectionTimer;
+
+   private TimerTask failedConnectionsTask;
+
+   private final long connectionScanPeriod;
+   
+   private final long connectionTTL;
+
+   private final boolean jmxEnabled;
+
+   private final BufferHandler bufferHandler = new DelegatingBufferHandler();
+
+   private volatile boolean backup;
+
+   private volatile MessagingServer server;
+
+   private ManagementService managementService;
+
+   
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public RemotingServiceImpl(final Configuration config)
+   {
+      transportConfigs = config.getAcceptorConfigurations();
+
+      ClassLoader loader = Thread.currentThread().getContextClassLoader();
+      for (String interceptorClass : config.getInterceptorClassNames())
+      {
+         try
+         {
+            Class<?> clazz = loader.loadClass(interceptorClass);
+            interceptors.add((Interceptor)clazz.newInstance());
+         }
+         catch (Exception e)
+         {
+            log.warn("Error instantiating interceptor \"" + interceptorClass + "\"", e);
+         }
+      }
+
+      connectionScanPeriod = config.getConnectionScanPeriod();
+      
+      connectionTTL = config.getConnectionTTLOverride();
+
+      backup = config.isBackup();  
+      
+      jmxEnabled= config.isJMXManagementEnabled();
+   }
+
+   // RemotingService implementation -------------------------------
+
+   public void setManagementService(final ManagementService managementService)
+   {
+      this.managementService = managementService;
+   }
+   
+   public synchronized void start() throws Exception
+   {
+      if (started)
+      {
+         return;
+      }
+      
+
+      // when JMX is enabled, it requires a INVM acceptor to send the core messages
+      // corresponding to the JMX management operations (@see ReplicationAwareStandardMBeanWrapper)
+      if (jmxEnabled)
+      {
+         boolean invmAcceptorConfigured = false;
+         for (TransportConfiguration config : transportConfigs)
+         {
+            if (InVMAcceptorFactory.class.getName().equals(config.getFactoryClassName()))
+            {
+               invmAcceptorConfigured = true;
+            }
+         }
+         if (!invmAcceptorConfigured)
+         {
+            transportConfigs.add(new TransportConfiguration(InVMAcceptorFactory.class.getName(), new HashMap<String, Object>(), "in-vm"));
+         }
+      }
+
+      ClassLoader loader = Thread.currentThread().getContextClassLoader();
+
+      for (TransportConfiguration info : transportConfigs)
+      {
+         try
+         {
+            Class<?> clazz = loader.loadClass(info.getFactoryClassName());
+
+            AcceptorFactory factory = (AcceptorFactory)clazz.newInstance();
+
+            Acceptor acceptor = factory.createAcceptor(info.getParams(), bufferHandler, this);
+
+            acceptors.add(acceptor);
+
+            if (managementService != null)
+            {
+               managementService.registerAcceptor(acceptor, info);
+            }
+         }
+         catch (Exception e)
+         {
+            log.warn("Error instantiating acceptor \"" + info.getFactoryClassName() + "\"", e);
+         }
+      }
+
+      for (Acceptor a : acceptors)
+      {
+         a.start();
+      }
+      
+      failedConnectionTimer = new Timer(true);
+
+      failedConnectionsTask = new FailedConnectionsTask();
+   
+      failedConnectionTimer.schedule(failedConnectionsTask, connectionScanPeriod, connectionScanPeriod);
+
+      started = true;
+   }
+
+   public synchronized void stop()
+   {
+      if (!started)
+      {
+         return;
+      }
+
+      if (failedConnectionTimer != null)
+      {
+         failedConnectionsTask.cancel();
+
+         failedConnectionsTask = null;
+         
+         failedConnectionTimer.cancel();
+         
+         failedConnectionTimer = null;
+      }
+
+      for (Acceptor acceptor : acceptors)
+      {
+         acceptor.stop();
+      }
+      
+      acceptors.clear();
+      
+      connections.clear();
+
+      started = false;
+   }
+   
+   public boolean isStarted()
+   {
+      return started;
+   }
+
+   public RemotingConnection getConnection(final Object remotingConnectionID)
+   {
+      return connections.get(remotingConnectionID);
+   }
+
+   public synchronized Set<RemotingConnection> getConnections()
+   {
+      return new HashSet<RemotingConnection>(connections.values());
+   }
+
+   public void setMessagingServer(final MessagingServer server)
+   {
+      this.server = server;
+   }
+
+   public void setBackup(final boolean backup)
+   {
+      this.backup = backup;
+   }
+
+   // ConnectionLifeCycleListener implementation -----------------------------------
+
+   public void connectionCreated(final Connection connection)
+   {
+      if (server == null)
+      {
+         throw new IllegalStateException("Unable to create connection, server hasn't finished starting up");
+      }
+      
+      RemotingConnection replicatingConnection = server.getReplicatingConnection();
+
+      RemotingConnection rc = new RemotingConnectionImpl(connection,                                                                                             
+                                                         interceptors,
+                                                         replicatingConnection,
+                                                         !backup,
+                                                         connectionTTL);
+
+      Channel channel1 = rc.getChannel(1,  -1, false);
+
+      ChannelHandler handler = new MessagingServerPacketHandler(server, channel1, rc);
+
+      channel1.setHandler(handler);
+
+      Object id = connection.getID();
+
+      connections.put(id, rc);
+   }
+
+   public void connectionDestroyed(final Object connectionID)
+   {
+      RemotingConnection conn = connections.remove(connectionID);
+      
+      if (conn != null)
+      {
+         conn.destroy();
+      }      
+   }
+
+   public void connectionException(final Object connectionID, final MessagingException me)
+   {
+      RemotingConnection rc = connections.remove(connectionID);
+
+      if (rc != null)
+      {
+         rc.fail(me);
+      }     
+   }
+
+   public void addInterceptor(final Interceptor interceptor)
+   {
+      interceptors.add(interceptor);
+   }
+
+   public boolean removeInterceptor(final Interceptor interceptor)
+   {
+      return interceptors.remove(interceptor);
+   }
+
+   // Public --------------------------------------------------------
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+
+   private class FailedConnectionsTask extends TimerTask
+   {
+      private boolean cancelled;
+
+      @Override
+      public synchronized void run()
+      {
+         if (cancelled)
+         {
+            return;
+         }
+
+         Set<RemotingConnection> failedConnections = new HashSet<RemotingConnection>();
+
+         long now = System.currentTimeMillis();
+
+         for (RemotingConnection conn : connections.values())
+         {
+            if (conn.isExpired(now))
+            {
+               failedConnections.add(conn);
+            }
+         }
+
+         for (RemotingConnection conn : failedConnections)
+         {
+            MessagingException me = new MessagingException(MessagingException.CONNECTION_TIMEDOUT,
+                                                           "Did not receive ping on connection. It is likely a client has exited or crashed without " + "closing its connection, or the network between the server and client has failed. The connection will now be closed.");
+
+            conn.fail(me);
+         }
+      }
+
+      @Override
+      public synchronized boolean cancel()
+      {
+         cancelled = true;
+
+         return super.cancel();
+      }
+
+   }
+
+   private class DelegatingBufferHandler extends AbstractBufferHandler
+   {
+      public void bufferReceived(final Object connectionID, final MessagingBuffer buffer)
+      {
+         RemotingConnection conn = connections.get(connectionID);
+
+         if (conn != null)
+         {
+            conn.bufferReceived(connectionID, buffer);
+         }
+      }
+   }
+
+}
\ No newline at end of file

Copied: trunk/dotnet/JBMClient/remoting/impl/invm (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/invm)

Deleted: trunk/dotnet/JBMClient/remoting/impl/invm/InVMAcceptor.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/invm/InVMAcceptor.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/invm/InVMAcceptor.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,174 +0,0 @@
-/*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt in the distribution for a
-  * full listing of individual contributors.
-  *
-  * This is free software; you can redistribute it and/or modify it
-  * under the terms of the GNU Lesser General Public License as
-  * published by the Free Software Foundation; either version 2.1 of
-  * the License, or (at your option) any later version.
-  *
-  * This software is distributed in the hope that it will be useful,
-  * but WITHOUT ANY WARRANTY; without even the implied warranty of
-  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-  * Lesser General Public License for more details.
-  *
-  * You should have received a copy of the GNU Lesser General Public
-  * License along with this software; if not, write to the Free
-  * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-  * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-  */
-package org.jboss.messaging.core.remoting.impl.invm;
-
-import java.util.Map;
-import java.util.concurrent.ConcurrentHashMap;
-import java.util.concurrent.ConcurrentMap;
-
-import org.jboss.messaging.core.exception.MessagingException;
-import org.jboss.messaging.core.remoting.spi.Acceptor;
-import org.jboss.messaging.core.remoting.spi.BufferHandler;
-import org.jboss.messaging.core.remoting.spi.Connection;
-import org.jboss.messaging.core.remoting.spi.ConnectionLifeCycleListener;
-import org.jboss.messaging.util.ConfigurationHelper;
-
-/**
- * A InVMAcceptor
- * 
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- *
- */
-public class InVMAcceptor implements Acceptor
-{   
-   private final int id;
-   
-   private final BufferHandler handler;
-   
-   private final ConnectionLifeCycleListener listener;
-   
-   private ConcurrentMap<String, Connection> connections = new ConcurrentHashMap<String, Connection>();
-   
-   private volatile boolean started;
-   
-   public InVMAcceptor(final Map<String, Object> configuration, final BufferHandler handler,
-                       final ConnectionLifeCycleListener listener)
-   {
-      this.handler = handler;
-      
-      this.listener = listener;   
-      
-      this.id = ConfigurationHelper.getIntProperty(TransportConstants.SERVER_ID_PROP_NAME, 0, configuration);
-   }
-   
-   public synchronized void start() throws Exception
-   {      
-      if (started)
-      {
-         return;
-      }
-      
-      InVMRegistry registry = InVMRegistry.instance;
-      
-      registry.registerAcceptor(id, this);
-      
-      started = true;
-   }
-
-   public synchronized void stop()
-   {   
-      if (!started)
-      {
-         return;
-      }
-      
-      for (Connection connection: connections.values())
-      {
-         listener.connectionDestroyed(connection.getID());
-      }
-      
-      connections.clear();
-      
-      InVMRegistry.instance.unregisterAcceptor(id);
-      
-      started = true;
-   }
-   
-   public boolean isStarted()
-   {
-      return started;
-   }
-
-   public BufferHandler getHandler()
-   {
-      if (!started)
-      {
-         throw new IllegalStateException("Acceptor is not started");
-      }
-      
-      return handler;
-   }
-   
-   public void connect(final String connectionID, final BufferHandler remoteHandler,
-                       final InVMConnector connector)
-   {
-      if (!started)
-      {
-         throw new IllegalStateException("Acceptor is not started");
-      }
-      
-      new InVMConnection(id, connectionID, remoteHandler, new Listener(connector));               
-   }
-   
-   public void disconnect(final String connectionID)
-   {
-      if (!started)
-      {
-         throw new IllegalStateException("Acceptor is not started");
-      }
-      
-      Connection conn = connections.get(connectionID);
-      
-      if (conn != null)
-      {
-         conn.close();
-      }            
-   }
-   
-   private class Listener implements ConnectionLifeCycleListener
-   {
-      private final InVMConnector connector;
-      
-      Listener(final InVMConnector connector)
-      {
-         this.connector = connector;
-      }
-      
-      public void connectionCreated(final Connection connection)
-      {
-         if (connections.putIfAbsent((String)connection.getID(), connection) != null)
-         {
-            throw new IllegalArgumentException("Connection already exists with id " + connection.getID());
-         }
-         
-         listener.connectionCreated(connection);
-      }
-
-      public void connectionDestroyed(final Object connectionID)
-      {
-         if (connections.remove(connectionID) != null)
-         {                    
-            //Remove on the other side too
-            connector.disconnect((String)connectionID);
-            
-            listener.connectionDestroyed(connectionID);
-         }
-      }
-
-      public void connectionException(final Object connectionID, final MessagingException me)
-      {
-         listener.connectionException(connectionID, me);
-      }
-      
-   }
-   
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/invm/InVMAcceptor.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/invm/InVMAcceptor.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/invm/InVMAcceptor.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/invm/InVMAcceptor.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,174 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt in the distribution for a
+  * full listing of individual contributors.
+  *
+  * This is free software; you can redistribute it and/or modify it
+  * under the terms of the GNU Lesser General Public License as
+  * published by the Free Software Foundation; either version 2.1 of
+  * the License, or (at your option) any later version.
+  *
+  * This software is distributed in the hope that it will be useful,
+  * but WITHOUT ANY WARRANTY; without even the implied warranty of
+  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+  * Lesser General Public License for more details.
+  *
+  * You should have received a copy of the GNU Lesser General Public
+  * License along with this software; if not, write to the Free
+  * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+  * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+  */
+package org.jboss.messaging.core.remoting.impl.invm;
+
+import java.util.Map;
+import java.util.concurrent.ConcurrentHashMap;
+import java.util.concurrent.ConcurrentMap;
+
+import org.jboss.messaging.core.exception.MessagingException;
+import org.jboss.messaging.core.remoting.spi.Acceptor;
+import org.jboss.messaging.core.remoting.spi.BufferHandler;
+import org.jboss.messaging.core.remoting.spi.Connection;
+import org.jboss.messaging.core.remoting.spi.ConnectionLifeCycleListener;
+import org.jboss.messaging.util.ConfigurationHelper;
+
+/**
+ * A InVMAcceptor
+ * 
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ *
+ */
+public class InVMAcceptor implements Acceptor
+{   
+   private final int id;
+   
+   private final BufferHandler handler;
+   
+   private final ConnectionLifeCycleListener listener;
+   
+   private ConcurrentMap<String, Connection> connections = new ConcurrentHashMap<String, Connection>();
+   
+   private volatile boolean started;
+   
+   public InVMAcceptor(final Map<String, Object> configuration, final BufferHandler handler,
+                       final ConnectionLifeCycleListener listener)
+   {
+      this.handler = handler;
+      
+      this.listener = listener;   
+      
+      this.id = ConfigurationHelper.getIntProperty(TransportConstants.SERVER_ID_PROP_NAME, 0, configuration);
+   }
+   
+   public synchronized void start() throws Exception
+   {      
+      if (started)
+      {
+         return;
+      }
+      
+      InVMRegistry registry = InVMRegistry.instance;
+      
+      registry.registerAcceptor(id, this);
+      
+      started = true;
+   }
+
+   public synchronized void stop()
+   {   
+      if (!started)
+      {
+         return;
+      }
+      
+      for (Connection connection: connections.values())
+      {
+         listener.connectionDestroyed(connection.getID());
+      }
+      
+      connections.clear();
+      
+      InVMRegistry.instance.unregisterAcceptor(id);
+      
+      started = true;
+   }
+   
+   public boolean isStarted()
+   {
+      return started;
+   }
+
+   public BufferHandler getHandler()
+   {
+      if (!started)
+      {
+         throw new IllegalStateException("Acceptor is not started");
+      }
+      
+      return handler;
+   }
+   
+   public void connect(final String connectionID, final BufferHandler remoteHandler,
+                       final InVMConnector connector)
+   {
+      if (!started)
+      {
+         throw new IllegalStateException("Acceptor is not started");
+      }
+      
+      new InVMConnection(id, connectionID, remoteHandler, new Listener(connector));               
+   }
+   
+   public void disconnect(final String connectionID)
+   {
+      if (!started)
+      {
+         throw new IllegalStateException("Acceptor is not started");
+      }
+      
+      Connection conn = connections.get(connectionID);
+      
+      if (conn != null)
+      {
+         conn.close();
+      }            
+   }
+   
+   private class Listener implements ConnectionLifeCycleListener
+   {
+      private final InVMConnector connector;
+      
+      Listener(final InVMConnector connector)
+      {
+         this.connector = connector;
+      }
+      
+      public void connectionCreated(final Connection connection)
+      {
+         if (connections.putIfAbsent((String)connection.getID(), connection) != null)
+         {
+            throw new IllegalArgumentException("Connection already exists with id " + connection.getID());
+         }
+         
+         listener.connectionCreated(connection);
+      }
+
+      public void connectionDestroyed(final Object connectionID)
+      {
+         if (connections.remove(connectionID) != null)
+         {                    
+            //Remove on the other side too
+            connector.disconnect((String)connectionID);
+            
+            listener.connectionDestroyed(connectionID);
+         }
+      }
+
+      public void connectionException(final Object connectionID, final MessagingException me)
+      {
+         listener.connectionException(connectionID, me);
+      }
+      
+   }
+   
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/invm/InVMAcceptorFactory.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/invm/InVMAcceptorFactory.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/invm/InVMAcceptorFactory.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,46 +0,0 @@
-/*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt in the distribution for a
-  * full listing of individual contributors.
-  *
-  * This is free software; you can redistribute it and/or modify it
-  * under the terms of the GNU Lesser General Public License as
-  * published by the Free Software Foundation; either version 2.1 of
-  * the License, or (at your option) any later version.
-  *
-  * This software is distributed in the hope that it will be useful,
-  * but WITHOUT ANY WARRANTY; without even the implied warranty of
-  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-  * Lesser General Public License for more details.
-  *
-  * You should have received a copy of the GNU Lesser General Public
-  * License along with this software; if not, write to the Free
-  * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-  * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-  */
-package org.jboss.messaging.core.remoting.impl.invm;
-
-import java.util.Map;
-
-import org.jboss.messaging.core.remoting.spi.Acceptor;
-import org.jboss.messaging.core.remoting.spi.AcceptorFactory;
-import org.jboss.messaging.core.remoting.spi.BufferHandler;
-import org.jboss.messaging.core.remoting.spi.ConnectionLifeCycleListener;
-
-/**
- * A InVMAcceptorFactory
- * 
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- *
- */
-public class InVMAcceptorFactory implements AcceptorFactory
-{
-
-   public Acceptor createAcceptor(final Map<String, Object> configuration,
-            final BufferHandler handler, final ConnectionLifeCycleListener listener)
-   {
-      return new InVMAcceptor(configuration, handler, listener);
-   }
-
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/invm/InVMAcceptorFactory.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/invm/InVMAcceptorFactory.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/invm/InVMAcceptorFactory.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/invm/InVMAcceptorFactory.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,46 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt in the distribution for a
+  * full listing of individual contributors.
+  *
+  * This is free software; you can redistribute it and/or modify it
+  * under the terms of the GNU Lesser General Public License as
+  * published by the Free Software Foundation; either version 2.1 of
+  * the License, or (at your option) any later version.
+  *
+  * This software is distributed in the hope that it will be useful,
+  * but WITHOUT ANY WARRANTY; without even the implied warranty of
+  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+  * Lesser General Public License for more details.
+  *
+  * You should have received a copy of the GNU Lesser General Public
+  * License along with this software; if not, write to the Free
+  * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+  * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+  */
+package org.jboss.messaging.core.remoting.impl.invm;
+
+import java.util.Map;
+
+import org.jboss.messaging.core.remoting.spi.Acceptor;
+import org.jboss.messaging.core.remoting.spi.AcceptorFactory;
+import org.jboss.messaging.core.remoting.spi.BufferHandler;
+import org.jboss.messaging.core.remoting.spi.ConnectionLifeCycleListener;
+
+/**
+ * A InVMAcceptorFactory
+ * 
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ *
+ */
+public class InVMAcceptorFactory implements AcceptorFactory
+{
+
+   public Acceptor createAcceptor(final Map<String, Object> configuration,
+            final BufferHandler handler, final ConnectionLifeCycleListener listener)
+   {
+      return new InVMAcceptor(configuration, handler, listener);
+   }
+
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/invm/InVMConnection.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/invm/InVMConnection.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/invm/InVMConnection.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,143 +0,0 @@
-/*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt in the distribution for a
-  * full listing of individual contributors.
-  *
-  * This is free software; you can redistribute it and/or modify it
-  * under the terms of the GNU Lesser General Public License as
-  * published by the Free Software Foundation; either version 2.1 of
-  * the License, or (at your option) any later version.
-  *
-  * This software is distributed in the hope that it will be useful,
-  * but WITHOUT ANY WARRANTY; without even the implied warranty of
-  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-  * Lesser General Public License for more details.
-  *
-  * You should have received a copy of the GNU Lesser General Public
-  * License along with this software; if not, write to the Free
-  * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-  * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-  */
-package org.jboss.messaging.core.remoting.impl.invm;
-
-import java.nio.ByteBuffer;
-import java.util.concurrent.Executor;
-import java.util.concurrent.Executors;
-
-import org.jboss.messaging.core.logging.Logger;
-import org.jboss.messaging.core.remoting.impl.ByteBufferWrapper;
-import org.jboss.messaging.core.remoting.spi.BufferHandler;
-import org.jboss.messaging.core.remoting.spi.Connection;
-import org.jboss.messaging.core.remoting.spi.ConnectionLifeCycleListener;
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-import org.jboss.messaging.util.ExecutorFactory;
-import org.jboss.messaging.util.JBMThreadFactory;
-import org.jboss.messaging.util.OrderedExecutorFactory;
-import org.jboss.messaging.util.UUIDGenerator;
-
-/**
- * A InVMConnection
- * 
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- *
- */
-public class InVMConnection implements Connection
-{
-   private static final Logger log = Logger.getLogger(InVMConnection.class);
-
-   private final BufferHandler handler;
-
-   private final ConnectionLifeCycleListener listener;
-
-   private final String id;
-
-   private boolean closed;
-   
-   private final int serverID;
-
-   private static final ExecutorFactory factory =
-      new OrderedExecutorFactory(Executors.newCachedThreadPool(new JBMThreadFactory("JBM-InVM-Transport-Threads")));
-
-   private final Executor executor;
-
-   public InVMConnection(final int serverID, final BufferHandler handler, final ConnectionLifeCycleListener listener)
-   {      
-      this(serverID, UUIDGenerator.getInstance().generateSimpleStringUUID().toString(), handler, listener);
-   }
-
-   public InVMConnection(final int serverID, final String id, final BufferHandler handler, final ConnectionLifeCycleListener listener)
-   {
-      this.serverID = serverID;
-      
-      this.handler = handler;
-
-      this.listener = listener;
-
-      this.id = id;
-
-      executor = factory.getExecutor();
-
-      listener.connectionCreated(this);
-   }
-
-   public synchronized void close()
-   {
-      if (closed)
-      {
-         return;
-      }
-      
-      //We can't wait for the executor to finish processing, since if the connection is closed on failover on the server
-      //and there are other replication requests still in progress and blocked because of the failover
-      //then it will time out waiting for close.
-      //Instead we let the executor complete after close but ignore the actions
-
-      listener.connectionDestroyed(id);
-
-      closed = true;
-   }
-
-   public MessagingBuffer createBuffer(final int size)
-   {
-      return new ByteBufferWrapper(ByteBuffer.allocate(size));
-   }
-
-   public Object getID()
-   {
-      return id;
-   }
-
-   public void write(final MessagingBuffer buffer)
-   {
-      executor.execute(new Runnable()
-      {
-         public void run()
-         {
-            try
-            {
-               if (!closed)
-               {
-                  buffer.getInt(); // read and discard
-                  handler.bufferReceived(id, buffer);
-               }
-               else
-               {
-                  //Ignore - buffer came in after connection is closed
-               }               
-            }
-            catch (Exception e)
-            {
-               final String msg = "Failed to write to handler";
-               log.error(msg, e);
-               throw new IllegalStateException(msg, e);
-            }
-         }
-      });
-   }
-
-   public String getRemoteAddress()
-   {
-      return "invm:" + serverID;
-   }
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/invm/InVMConnection.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/invm/InVMConnection.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/invm/InVMConnection.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/invm/InVMConnection.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,143 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt in the distribution for a
+  * full listing of individual contributors.
+  *
+  * This is free software; you can redistribute it and/or modify it
+  * under the terms of the GNU Lesser General Public License as
+  * published by the Free Software Foundation; either version 2.1 of
+  * the License, or (at your option) any later version.
+  *
+  * This software is distributed in the hope that it will be useful,
+  * but WITHOUT ANY WARRANTY; without even the implied warranty of
+  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+  * Lesser General Public License for more details.
+  *
+  * You should have received a copy of the GNU Lesser General Public
+  * License along with this software; if not, write to the Free
+  * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+  * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+  */
+package org.jboss.messaging.core.remoting.impl.invm;
+
+import java.nio.ByteBuffer;
+import java.util.concurrent.Executor;
+import java.util.concurrent.Executors;
+
+import org.jboss.messaging.core.logging.Logger;
+import org.jboss.messaging.core.remoting.impl.ByteBufferWrapper;
+import org.jboss.messaging.core.remoting.spi.BufferHandler;
+import org.jboss.messaging.core.remoting.spi.Connection;
+import org.jboss.messaging.core.remoting.spi.ConnectionLifeCycleListener;
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+import org.jboss.messaging.util.ExecutorFactory;
+import org.jboss.messaging.util.JBMThreadFactory;
+import org.jboss.messaging.util.OrderedExecutorFactory;
+import org.jboss.messaging.util.UUIDGenerator;
+
+/**
+ * A InVMConnection
+ * 
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ *
+ */
+public class InVMConnection implements Connection
+{
+   private static final Logger log = Logger.getLogger(InVMConnection.class);
+
+   private final BufferHandler handler;
+
+   private final ConnectionLifeCycleListener listener;
+
+   private final String id;
+
+   private boolean closed;
+   
+   private final int serverID;
+
+   private static final ExecutorFactory factory =
+      new OrderedExecutorFactory(Executors.newCachedThreadPool(new JBMThreadFactory("JBM-InVM-Transport-Threads")));
+
+   private final Executor executor;
+
+   public InVMConnection(final int serverID, final BufferHandler handler, final ConnectionLifeCycleListener listener)
+   {      
+      this(serverID, UUIDGenerator.getInstance().generateSimpleStringUUID().toString(), handler, listener);
+   }
+
+   public InVMConnection(final int serverID, final String id, final BufferHandler handler, final ConnectionLifeCycleListener listener)
+   {
+      this.serverID = serverID;
+      
+      this.handler = handler;
+
+      this.listener = listener;
+
+      this.id = id;
+
+      executor = factory.getExecutor();
+
+      listener.connectionCreated(this);
+   }
+
+   public synchronized void close()
+   {
+      if (closed)
+      {
+         return;
+      }
+      
+      //We can't wait for the executor to finish processing, since if the connection is closed on failover on the server
+      //and there are other replication requests still in progress and blocked because of the failover
+      //then it will time out waiting for close.
+      //Instead we let the executor complete after close but ignore the actions
+
+      listener.connectionDestroyed(id);
+
+      closed = true;
+   }
+
+   public MessagingBuffer createBuffer(final int size)
+   {
+      return new ByteBufferWrapper(ByteBuffer.allocate(size));
+   }
+
+   public Object getID()
+   {
+      return id;
+   }
+
+   public void write(final MessagingBuffer buffer)
+   {
+      executor.execute(new Runnable()
+      {
+         public void run()
+         {
+            try
+            {
+               if (!closed)
+               {
+                  buffer.getInt(); // read and discard
+                  handler.bufferReceived(id, buffer);
+               }
+               else
+               {
+                  //Ignore - buffer came in after connection is closed
+               }               
+            }
+            catch (Exception e)
+            {
+               final String msg = "Failed to write to handler";
+               log.error(msg, e);
+               throw new IllegalStateException(msg, e);
+            }
+         }
+      });
+   }
+
+   public String getRemoteAddress()
+   {
+      return "invm:" + serverID;
+   }
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/invm/InVMConnector.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/invm/InVMConnector.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/invm/InVMConnector.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,195 +0,0 @@
-/*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt in the distribution for a
-  * full listing of individual contributors.
-  *
-  * This is free software; you can redistribute it and/or modify it
-  * under the terms of the GNU Lesser General Public License as
-  * published by the Free Software Foundation; either version 2.1 of
-  * the License, or (at your option) any later version.
-  *
-  * This software is distributed in the hope that it will be useful,
-  * but WITHOUT ANY WARRANTY; without even the implied warranty of
-  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-  * Lesser General Public License for more details.
-  *
-  * You should have received a copy of the GNU Lesser General Public
-  * License along with this software; if not, write to the Free
-  * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-  * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-  */
-package org.jboss.messaging.core.remoting.impl.invm;
-
-import java.util.Map;
-import java.util.concurrent.ConcurrentHashMap;
-import java.util.concurrent.ConcurrentMap;
-
-import org.jboss.messaging.core.exception.MessagingException;
-import org.jboss.messaging.core.logging.Logger;
-import org.jboss.messaging.core.remoting.spi.BufferHandler;
-import org.jboss.messaging.core.remoting.spi.Connection;
-import org.jboss.messaging.core.remoting.spi.ConnectionLifeCycleListener;
-import org.jboss.messaging.core.remoting.spi.Connector;
-import org.jboss.messaging.util.ConfigurationHelper;
-
-/**
- * A InVMConnector
- * 
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- *
- */
-public class InVMConnector implements Connector
-{
-   public static final Logger log = Logger.getLogger(InVMConnector.class);
-   
-   //Used for testing failure only
-   public static volatile boolean failOnCreateConnection;
-   public static volatile int numberOfFailures = -1;
-   private static volatile int failures;
-   public static synchronized void resetFailures()
-   {
-      failures = 0;
-      failOnCreateConnection = false;
-      numberOfFailures = -1;
-   }
-   private static synchronized void incFailures()
-   {
-      failures++;
-      if (failures == numberOfFailures)
-      {
-         resetFailures();
-      }
-   }
-
-   protected final int id;
-   
-   private final BufferHandler handler;
-   
-   private final ConnectionLifeCycleListener listener;
-   
-   private final InVMAcceptor acceptor;
-   
-   private ConcurrentMap<String, Connection> connections = new ConcurrentHashMap<String, Connection>();
-   
-   private volatile boolean started;
-   
-   public InVMConnector(final Map<String, Object> configuration,
-                        final BufferHandler handler,
-                        final ConnectionLifeCycleListener listener)
-   {
-      this.listener = listener;
-      
-      this.id = ConfigurationHelper.getIntProperty(TransportConstants.SERVER_ID_PROP_NAME, 0, configuration);
-      
-      this.handler = handler;
-      
-      InVMRegistry registry = InVMRegistry.instance;
-      
-      acceptor = registry.getAcceptor(id);
-      
-      if (acceptor == null)
-      {
-         throw new IllegalStateException("Cannot connect to invm acceptor with id " + id + " has it been started?");
-      }
-   }
-
-   public synchronized void close()
-   {      
-      if (!started)
-      {
-         return;
-      }
-      
-      for (Connection connection: connections.values())
-      {
-         listener.connectionDestroyed(connection.getID());
-      }
-      
-      connections.clear();
-      
-      started = false;
-   }
-   
-   public boolean isStarted()
-   {
-      return started;
-   }
-
-   public Connection createConnection()
-   {
-      if (failOnCreateConnection)
-      {
-         incFailures();
-         //For testing only
-         return null;
-      }
-      
-      Connection conn = internalCreateConnection(acceptor.getHandler(), new Listener());
-      
-      acceptor.connect((String)conn.getID(), handler, this);
-           
-      return conn;
-   }
-   public synchronized void start()
-   {          
-      started = true;
-   }
-   
-   public BufferHandler getHandler()
-   {
-      return handler;
-   }
-   
-   public void disconnect(final String connectionID)
-   {
-      if (!started)
-      {
-         throw new IllegalStateException("Acceptor is not started");
-      }
-      
-      Connection conn = connections.get(connectionID);
-      
-      if (conn != null)
-      {
-         conn.close();
-      }
-   }
-
-   // This may be an injection point for mocks on tests
-   protected Connection internalCreateConnection(final BufferHandler handler, final ConnectionLifeCycleListener listener)
-   {
-      return new InVMConnection(id, handler, listener);
-   }
-      
-   private class Listener implements ConnectionLifeCycleListener
-   {
-      public void connectionCreated(final Connection connection)
-      {         
-         if (connections.putIfAbsent((String)connection.getID(), connection) != null)
-         {
-            throw new IllegalArgumentException("Connection already exists with id " + connection.getID());
-         }
-           
-         listener.connectionCreated(connection);
-      }
-
-      public void connectionDestroyed(final Object connectionID)
-      {         
-         if (connections.remove(connectionID) != null)
-         {                     
-            //Close the correspond connection on the other side
-            acceptor.disconnect((String)connectionID);
-            
-            listener.connectionDestroyed(connectionID);
-         }
-      }
-
-      public void connectionException(final Object connectionID, final MessagingException me)
-      {
-         listener.connectionException(connectionID, me);
-      }
-      
-   }
-
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/invm/InVMConnector.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/invm/InVMConnector.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/invm/InVMConnector.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/invm/InVMConnector.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,195 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt in the distribution for a
+  * full listing of individual contributors.
+  *
+  * This is free software; you can redistribute it and/or modify it
+  * under the terms of the GNU Lesser General Public License as
+  * published by the Free Software Foundation; either version 2.1 of
+  * the License, or (at your option) any later version.
+  *
+  * This software is distributed in the hope that it will be useful,
+  * but WITHOUT ANY WARRANTY; without even the implied warranty of
+  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+  * Lesser General Public License for more details.
+  *
+  * You should have received a copy of the GNU Lesser General Public
+  * License along with this software; if not, write to the Free
+  * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+  * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+  */
+package org.jboss.messaging.core.remoting.impl.invm;
+
+import java.util.Map;
+import java.util.concurrent.ConcurrentHashMap;
+import java.util.concurrent.ConcurrentMap;
+
+import org.jboss.messaging.core.exception.MessagingException;
+import org.jboss.messaging.core.logging.Logger;
+import org.jboss.messaging.core.remoting.spi.BufferHandler;
+import org.jboss.messaging.core.remoting.spi.Connection;
+import org.jboss.messaging.core.remoting.spi.ConnectionLifeCycleListener;
+import org.jboss.messaging.core.remoting.spi.Connector;
+import org.jboss.messaging.util.ConfigurationHelper;
+
+/**
+ * A InVMConnector
+ * 
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ *
+ */
+public class InVMConnector implements Connector
+{
+   public static final Logger log = Logger.getLogger(InVMConnector.class);
+   
+   //Used for testing failure only
+   public static volatile boolean failOnCreateConnection;
+   public static volatile int numberOfFailures = -1;
+   private static volatile int failures;
+   public static synchronized void resetFailures()
+   {
+      failures = 0;
+      failOnCreateConnection = false;
+      numberOfFailures = -1;
+   }
+   private static synchronized void incFailures()
+   {
+      failures++;
+      if (failures == numberOfFailures)
+      {
+         resetFailures();
+      }
+   }
+
+   protected final int id;
+   
+   private final BufferHandler handler;
+   
+   private final ConnectionLifeCycleListener listener;
+   
+   private final InVMAcceptor acceptor;
+   
+   private ConcurrentMap<String, Connection> connections = new ConcurrentHashMap<String, Connection>();
+   
+   private volatile boolean started;
+   
+   public InVMConnector(final Map<String, Object> configuration,
+                        final BufferHandler handler,
+                        final ConnectionLifeCycleListener listener)
+   {
+      this.listener = listener;
+      
+      this.id = ConfigurationHelper.getIntProperty(TransportConstants.SERVER_ID_PROP_NAME, 0, configuration);
+      
+      this.handler = handler;
+      
+      InVMRegistry registry = InVMRegistry.instance;
+      
+      acceptor = registry.getAcceptor(id);
+      
+      if (acceptor == null)
+      {
+         throw new IllegalStateException("Cannot connect to invm acceptor with id " + id + " has it been started?");
+      }
+   }
+
+   public synchronized void close()
+   {      
+      if (!started)
+      {
+         return;
+      }
+      
+      for (Connection connection: connections.values())
+      {
+         listener.connectionDestroyed(connection.getID());
+      }
+      
+      connections.clear();
+      
+      started = false;
+   }
+   
+   public boolean isStarted()
+   {
+      return started;
+   }
+
+   public Connection createConnection()
+   {
+      if (failOnCreateConnection)
+      {
+         incFailures();
+         //For testing only
+         return null;
+      }
+      
+      Connection conn = internalCreateConnection(acceptor.getHandler(), new Listener());
+      
+      acceptor.connect((String)conn.getID(), handler, this);
+           
+      return conn;
+   }
+   public synchronized void start()
+   {          
+      started = true;
+   }
+   
+   public BufferHandler getHandler()
+   {
+      return handler;
+   }
+   
+   public void disconnect(final String connectionID)
+   {
+      if (!started)
+      {
+         throw new IllegalStateException("Acceptor is not started");
+      }
+      
+      Connection conn = connections.get(connectionID);
+      
+      if (conn != null)
+      {
+         conn.close();
+      }
+   }
+
+   // This may be an injection point for mocks on tests
+   protected Connection internalCreateConnection(final BufferHandler handler, final ConnectionLifeCycleListener listener)
+   {
+      return new InVMConnection(id, handler, listener);
+   }
+      
+   private class Listener implements ConnectionLifeCycleListener
+   {
+      public void connectionCreated(final Connection connection)
+      {         
+         if (connections.putIfAbsent((String)connection.getID(), connection) != null)
+         {
+            throw new IllegalArgumentException("Connection already exists with id " + connection.getID());
+         }
+           
+         listener.connectionCreated(connection);
+      }
+
+      public void connectionDestroyed(final Object connectionID)
+      {         
+         if (connections.remove(connectionID) != null)
+         {                     
+            //Close the correspond connection on the other side
+            acceptor.disconnect((String)connectionID);
+            
+            listener.connectionDestroyed(connectionID);
+         }
+      }
+
+      public void connectionException(final Object connectionID, final MessagingException me)
+      {
+         listener.connectionException(connectionID, me);
+      }
+      
+   }
+
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/invm/InVMConnectorFactory.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/invm/InVMConnectorFactory.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/invm/InVMConnectorFactory.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,46 +0,0 @@
-/*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt in the distribution for a
-  * full listing of individual contributors.
-  *
-  * This is free software; you can redistribute it and/or modify it
-  * under the terms of the GNU Lesser General Public License as
-  * published by the Free Software Foundation; either version 2.1 of
-  * the License, or (at your option) any later version.
-  *
-  * This software is distributed in the hope that it will be useful,
-  * but WITHOUT ANY WARRANTY; without even the implied warranty of
-  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-  * Lesser General Public License for more details.
-  *
-  * You should have received a copy of the GNU Lesser General Public
-  * License along with this software; if not, write to the Free
-  * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-  * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-  */
-package org.jboss.messaging.core.remoting.impl.invm;
-
-import java.util.Map;
-
-import org.jboss.messaging.core.remoting.spi.BufferHandler;
-import org.jboss.messaging.core.remoting.spi.ConnectionLifeCycleListener;
-import org.jboss.messaging.core.remoting.spi.Connector;
-import org.jboss.messaging.core.remoting.spi.ConnectorFactory;
-
-/**
- * A InVMConnectorFactory
- * 
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- *
- */
-public class InVMConnectorFactory implements ConnectorFactory
-{
-   public Connector createConnector(final Map<String, Object> configuration,
-                                    final BufferHandler handler,
-                                    final ConnectionLifeCycleListener listener)
-   {      
-      return new InVMConnector(configuration, handler, listener);
-   }
-
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/invm/InVMConnectorFactory.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/invm/InVMConnectorFactory.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/invm/InVMConnectorFactory.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/invm/InVMConnectorFactory.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,46 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt in the distribution for a
+  * full listing of individual contributors.
+  *
+  * This is free software; you can redistribute it and/or modify it
+  * under the terms of the GNU Lesser General Public License as
+  * published by the Free Software Foundation; either version 2.1 of
+  * the License, or (at your option) any later version.
+  *
+  * This software is distributed in the hope that it will be useful,
+  * but WITHOUT ANY WARRANTY; without even the implied warranty of
+  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+  * Lesser General Public License for more details.
+  *
+  * You should have received a copy of the GNU Lesser General Public
+  * License along with this software; if not, write to the Free
+  * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+  * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+  */
+package org.jboss.messaging.core.remoting.impl.invm;
+
+import java.util.Map;
+
+import org.jboss.messaging.core.remoting.spi.BufferHandler;
+import org.jboss.messaging.core.remoting.spi.ConnectionLifeCycleListener;
+import org.jboss.messaging.core.remoting.spi.Connector;
+import org.jboss.messaging.core.remoting.spi.ConnectorFactory;
+
+/**
+ * A InVMConnectorFactory
+ * 
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ *
+ */
+public class InVMConnectorFactory implements ConnectorFactory
+{
+   public Connector createConnector(final Map<String, Object> configuration,
+                                    final BufferHandler handler,
+                                    final ConnectionLifeCycleListener listener)
+   {      
+      return new InVMConnector(configuration, handler, listener);
+   }
+
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/invm/InVMRegistry.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/invm/InVMRegistry.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/invm/InVMRegistry.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,73 +0,0 @@
-/*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt in the distribution for a
-  * full listing of individual contributors.
-  *
-  * This is free software; you can redistribute it and/or modify it
-  * under the terms of the GNU Lesser General Public License as
-  * published by the Free Software Foundation; either version 2.1 of
-  * the License, or (at your option) any later version.
-  *
-  * This software is distributed in the hope that it will be useful,
-  * but WITHOUT ANY WARRANTY; without even the implied warranty of
-  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-  * Lesser General Public License for more details.
-  *
-  * You should have received a copy of the GNU Lesser General Public
-  * License along with this software; if not, write to the Free
-  * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-  * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-  */
-package org.jboss.messaging.core.remoting.impl.invm;
-
-import java.util.concurrent.ConcurrentHashMap;
-import java.util.concurrent.ConcurrentMap;
-
-import org.jboss.messaging.core.logging.Logger;
-
-/**
- * A InVMRegistry
- * 
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- *
- */
-public class InVMRegistry
-{
-   private static final Logger log = Logger.getLogger(InVMRegistry.class);
-
-   public static final InVMRegistry instance = new InVMRegistry();
-
-   private ConcurrentMap<Integer, InVMAcceptor> acceptors = new ConcurrentHashMap<Integer, InVMAcceptor>();
-
-   public void registerAcceptor(final int id, final InVMAcceptor acceptor)
-   {     
-      if (acceptors.putIfAbsent(id, acceptor) != null)
-      {
-         throw new IllegalArgumentException("Acceptor with id " + id + " already registered");
-      }
-   }
-
-   public void unregisterAcceptor(final int id)
-   {      
-      if (acceptors.remove(id) == null)
-      {
-         throw new IllegalArgumentException("Acceptor with id " + id + " not registered");
-      }
-   }
-
-   public InVMAcceptor getAcceptor(final int id)
-   {
-      return acceptors.get(id);
-   }
-
-   public void clear()
-   {
-      this.acceptors.clear();
-   }
-
-   public int size()
-   {
-      return this.acceptors.size();
-   }
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/invm/InVMRegistry.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/invm/InVMRegistry.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/invm/InVMRegistry.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/invm/InVMRegistry.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,73 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt in the distribution for a
+  * full listing of individual contributors.
+  *
+  * This is free software; you can redistribute it and/or modify it
+  * under the terms of the GNU Lesser General Public License as
+  * published by the Free Software Foundation; either version 2.1 of
+  * the License, or (at your option) any later version.
+  *
+  * This software is distributed in the hope that it will be useful,
+  * but WITHOUT ANY WARRANTY; without even the implied warranty of
+  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+  * Lesser General Public License for more details.
+  *
+  * You should have received a copy of the GNU Lesser General Public
+  * License along with this software; if not, write to the Free
+  * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+  * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+  */
+package org.jboss.messaging.core.remoting.impl.invm;
+
+import java.util.concurrent.ConcurrentHashMap;
+import java.util.concurrent.ConcurrentMap;
+
+import org.jboss.messaging.core.logging.Logger;
+
+/**
+ * A InVMRegistry
+ * 
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ *
+ */
+public class InVMRegistry
+{
+   private static final Logger log = Logger.getLogger(InVMRegistry.class);
+
+   public static final InVMRegistry instance = new InVMRegistry();
+
+   private ConcurrentMap<Integer, InVMAcceptor> acceptors = new ConcurrentHashMap<Integer, InVMAcceptor>();
+
+   public void registerAcceptor(final int id, final InVMAcceptor acceptor)
+   {     
+      if (acceptors.putIfAbsent(id, acceptor) != null)
+      {
+         throw new IllegalArgumentException("Acceptor with id " + id + " already registered");
+      }
+   }
+
+   public void unregisterAcceptor(final int id)
+   {      
+      if (acceptors.remove(id) == null)
+      {
+         throw new IllegalArgumentException("Acceptor with id " + id + " not registered");
+      }
+   }
+
+   public InVMAcceptor getAcceptor(final int id)
+   {
+      return acceptors.get(id);
+   }
+
+   public void clear()
+   {
+      this.acceptors.clear();
+   }
+
+   public int size()
+   {
+      return this.acceptors.size();
+   }
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/invm/TransportConstants.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/invm/TransportConstants.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/invm/TransportConstants.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,33 +0,0 @@
-/*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt in the distribution for a
-  * full listing of individual contributors.
-  *
-  * This is free software; you can redistribute it and/or modify it
-  * under the terms of the GNU Lesser General Public License as
-  * published by the Free Software Foundation; either version 2.1 of
-  * the License, or (at your option) any later version.
-  *
-  * This software is distributed in the hope that it will be useful,
-  * but WITHOUT ANY WARRANTY; without even the implied warranty of
-  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-  * Lesser General Public License for more details.
-  *
-  * You should have received a copy of the GNU Lesser General Public
-  * License along with this software; if not, write to the Free
-  * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-  * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-  */
-package org.jboss.messaging.core.remoting.impl.invm;
-
-/**
- * A TransportConstants
- * 
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- *
- */
-public class TransportConstants
-{
-   public static final String SERVER_ID_PROP_NAME = "jbm.remoting.invm.serverid";
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/invm/TransportConstants.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/invm/TransportConstants.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/invm/TransportConstants.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/invm/TransportConstants.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,33 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt in the distribution for a
+  * full listing of individual contributors.
+  *
+  * This is free software; you can redistribute it and/or modify it
+  * under the terms of the GNU Lesser General Public License as
+  * published by the Free Software Foundation; either version 2.1 of
+  * the License, or (at your option) any later version.
+  *
+  * This software is distributed in the hope that it will be useful,
+  * but WITHOUT ANY WARRANTY; without even the implied warranty of
+  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+  * Lesser General Public License for more details.
+  *
+  * You should have received a copy of the GNU Lesser General Public
+  * License along with this software; if not, write to the Free
+  * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+  * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+  */
+package org.jboss.messaging.core.remoting.impl.invm;
+
+/**
+ * A TransportConstants
+ * 
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ *
+ */
+public class TransportConstants
+{
+   public static final String SERVER_ID_PROP_NAME = "jbm.remoting.invm.serverid";
+}

Copied: trunk/dotnet/JBMClient/remoting/impl/ssl (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/ssl)

Deleted: trunk/dotnet/JBMClient/remoting/impl/ssl/SSLSupport.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/ssl/SSLSupport.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/ssl/SSLSupport.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,207 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.impl.ssl;
-
-import java.io.File;
-import java.io.IOException;
-import java.io.InputStream;
-import java.net.MalformedURLException;
-import java.net.URL;
-import java.security.GeneralSecurityException;
-import java.security.KeyStore;
-import java.security.SecureRandom;
-import java.security.cert.X509Certificate;
-
-import javax.net.ssl.KeyManager;
-import javax.net.ssl.KeyManagerFactory;
-import javax.net.ssl.SSLContext;
-import javax.net.ssl.TrustManager;
-import javax.net.ssl.TrustManagerFactory;
-import javax.net.ssl.X509TrustManager;
-
-/**
- * @author <a href="mailto:jmesnil at redhat.com">Jeff Mesnil</a>
- * 
- * @version <tt>$Revision$</tt>
- * 
- */
-public class SSLSupport
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   // Public --------------------------------------------------------
-
-   public static SSLContext createServerContext(String keystorePath,
-         String keystorePassword, String trustStorePath,
-         String trustStorePassword) throws Exception
-   {
-
-      // Initialize the SSLContext to work with our key managers.
-      SSLContext sslContext = SSLContext.getInstance("TLS");
-      KeyManager[] keyManagers = loadKeyManagers(keystorePath, keystorePassword);
-      TrustManager[] trustManagers = loadTrustManager(false, trustStorePath,
-            trustStorePassword);
-      sslContext.init(keyManagers, trustManagers, new SecureRandom());
-
-      return sslContext;
-   }
-
-   public static SSLContext createClientContext(String keystorePath,
-         String keystorePassword) throws Exception
-   {
-      SSLContext context = SSLContext.getInstance("TLS");
-      KeyManager[] keyManagers = loadKeyManagers(keystorePath, keystorePassword);
-      TrustManager[] trustManagers = loadTrustManager(true,  null, null);
-      context.init(keyManagers, trustManagers, new SecureRandom());
-      return context;
-   }
-
-   public static SSLContext getInstance(boolean client, String keystorePath,
-         String keystorePassword, String trustStorePath,
-         String trustStorePassword) throws GeneralSecurityException, Exception
-   {
-      if (client)
-      {
-         return createClientContext(keystorePath, keystorePassword);
-      } else
-      {
-         return createServerContext(keystorePath, keystorePassword,
-               trustStorePath, trustStorePassword);
-      }
-   }
-
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   private static TrustManager[] loadTrustManager(boolean clientMode,
-         String trustStorePath, String trustStorePassword) throws Exception
-   {
-      if (clientMode)
-      {
-         // we are in client mode and do not want to perform server cert
-         // authentication
-         // return a trust manager that trusts all certs
-         return new TrustManager[] { new X509TrustManager()
-         {
-            public void checkClientTrusted(X509Certificate[] chain,
-                  String authType)
-            {
-            }
-
-            public void checkServerTrusted(X509Certificate[] chain,
-                  String authType)
-            {
-            }
-
-            public X509Certificate[] getAcceptedIssuers()
-            {
-               return null;
-            }
-         } };
-      } else
-      {
-         TrustManagerFactory trustMgrFactory;
-         KeyStore trustStore = SSLSupport.loadKeystore(trustStorePath,
-               trustStorePassword);
-         trustMgrFactory = TrustManagerFactory.getInstance(TrustManagerFactory
-               .getDefaultAlgorithm());
-         trustMgrFactory.init(trustStore);
-         return trustMgrFactory.getTrustManagers();
-      }
-   }
-
-   private static KeyStore loadKeystore(String keystorePath,
-         String keystorePassword) throws Exception
-   {
-      assert keystorePath != null;
-      assert keystorePassword != null;
-      
-      KeyStore ks = KeyStore.getInstance("JKS");
-      InputStream in = null;
-      try
-      {
-         URL keystoreURL = validateStoreURL(keystorePath);
-         ks.load(keystoreURL.openStream(), keystorePassword.toCharArray());
-      } finally
-      {
-         if (in != null)
-         {
-            try
-            {
-               in.close();
-            } catch (IOException ignored)
-            {
-            }
-         }
-      }
-      return ks;
-   }
-
-   private static KeyManager[] loadKeyManagers(String keystorePath,
-         String keystorePassword) throws Exception
-   {
-      KeyManagerFactory kmf = KeyManagerFactory.getInstance(KeyManagerFactory
-            .getDefaultAlgorithm());
-      KeyStore ks = loadKeystore(keystorePath, keystorePassword);
-      kmf.init(ks, keystorePassword.toCharArray());
-
-      return kmf.getKeyManagers();
-   }
-
-   private static URL validateStoreURL(String storePath) throws Exception
-   {
-      assert storePath != null;
-      
-      // First see if this is a URL
-      try
-      {
-         return new URL(storePath);
-      } catch (MalformedURLException e)
-      {
-         File file = new File(storePath);
-         if (file.exists() == true && file.isFile())
-         {
-            return file.toURL();
-         } else
-         {
-            URL url = Thread.currentThread().getContextClassLoader()
-                  .getResource(storePath);
-            if (url != null)
-               return url;
-         }
-      }
-
-      throw new Exception("Failed to find a store at " + storePath);
-   }
-
-   // Inner classes -------------------------------------------------
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/ssl/SSLSupport.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/ssl/SSLSupport.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/ssl/SSLSupport.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/ssl/SSLSupport.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,207 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.impl.ssl;
+
+import java.io.File;
+import java.io.IOException;
+import java.io.InputStream;
+import java.net.MalformedURLException;
+import java.net.URL;
+import java.security.GeneralSecurityException;
+import java.security.KeyStore;
+import java.security.SecureRandom;
+import java.security.cert.X509Certificate;
+
+import javax.net.ssl.KeyManager;
+import javax.net.ssl.KeyManagerFactory;
+import javax.net.ssl.SSLContext;
+import javax.net.ssl.TrustManager;
+import javax.net.ssl.TrustManagerFactory;
+import javax.net.ssl.X509TrustManager;
+
+/**
+ * @author <a href="mailto:jmesnil at redhat.com">Jeff Mesnil</a>
+ * 
+ * @version <tt>$Revision$</tt>
+ * 
+ */
+public class SSLSupport
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   // Public --------------------------------------------------------
+
+   public static SSLContext createServerContext(String keystorePath,
+         String keystorePassword, String trustStorePath,
+         String trustStorePassword) throws Exception
+   {
+
+      // Initialize the SSLContext to work with our key managers.
+      SSLContext sslContext = SSLContext.getInstance("TLS");
+      KeyManager[] keyManagers = loadKeyManagers(keystorePath, keystorePassword);
+      TrustManager[] trustManagers = loadTrustManager(false, trustStorePath,
+            trustStorePassword);
+      sslContext.init(keyManagers, trustManagers, new SecureRandom());
+
+      return sslContext;
+   }
+
+   public static SSLContext createClientContext(String keystorePath,
+         String keystorePassword) throws Exception
+   {
+      SSLContext context = SSLContext.getInstance("TLS");
+      KeyManager[] keyManagers = loadKeyManagers(keystorePath, keystorePassword);
+      TrustManager[] trustManagers = loadTrustManager(true,  null, null);
+      context.init(keyManagers, trustManagers, new SecureRandom());
+      return context;
+   }
+
+   public static SSLContext getInstance(boolean client, String keystorePath,
+         String keystorePassword, String trustStorePath,
+         String trustStorePassword) throws GeneralSecurityException, Exception
+   {
+      if (client)
+      {
+         return createClientContext(keystorePath, keystorePassword);
+      } else
+      {
+         return createServerContext(keystorePath, keystorePassword,
+               trustStorePath, trustStorePassword);
+      }
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   private static TrustManager[] loadTrustManager(boolean clientMode,
+         String trustStorePath, String trustStorePassword) throws Exception
+   {
+      if (clientMode)
+      {
+         // we are in client mode and do not want to perform server cert
+         // authentication
+         // return a trust manager that trusts all certs
+         return new TrustManager[] { new X509TrustManager()
+         {
+            public void checkClientTrusted(X509Certificate[] chain,
+                  String authType)
+            {
+            }
+
+            public void checkServerTrusted(X509Certificate[] chain,
+                  String authType)
+            {
+            }
+
+            public X509Certificate[] getAcceptedIssuers()
+            {
+               return null;
+            }
+         } };
+      } else
+      {
+         TrustManagerFactory trustMgrFactory;
+         KeyStore trustStore = SSLSupport.loadKeystore(trustStorePath,
+               trustStorePassword);
+         trustMgrFactory = TrustManagerFactory.getInstance(TrustManagerFactory
+               .getDefaultAlgorithm());
+         trustMgrFactory.init(trustStore);
+         return trustMgrFactory.getTrustManagers();
+      }
+   }
+
+   private static KeyStore loadKeystore(String keystorePath,
+         String keystorePassword) throws Exception
+   {
+      assert keystorePath != null;
+      assert keystorePassword != null;
+      
+      KeyStore ks = KeyStore.getInstance("JKS");
+      InputStream in = null;
+      try
+      {
+         URL keystoreURL = validateStoreURL(keystorePath);
+         ks.load(keystoreURL.openStream(), keystorePassword.toCharArray());
+      } finally
+      {
+         if (in != null)
+         {
+            try
+            {
+               in.close();
+            } catch (IOException ignored)
+            {
+            }
+         }
+      }
+      return ks;
+   }
+
+   private static KeyManager[] loadKeyManagers(String keystorePath,
+         String keystorePassword) throws Exception
+   {
+      KeyManagerFactory kmf = KeyManagerFactory.getInstance(KeyManagerFactory
+            .getDefaultAlgorithm());
+      KeyStore ks = loadKeystore(keystorePath, keystorePassword);
+      kmf.init(ks, keystorePassword.toCharArray());
+
+      return kmf.getKeyManagers();
+   }
+
+   private static URL validateStoreURL(String storePath) throws Exception
+   {
+      assert storePath != null;
+      
+      // First see if this is a URL
+      try
+      {
+         return new URL(storePath);
+      } catch (MalformedURLException e)
+      {
+         File file = new File(storePath);
+         if (file.exists() == true && file.isFile())
+         {
+            return file.toURL();
+         } else
+         {
+            URL url = Thread.currentThread().getContextClassLoader()
+                  .getResource(storePath);
+            if (url != null)
+               return url;
+         }
+      }
+
+      throw new Exception("Failed to find a store at " + storePath);
+   }
+
+   // Inner classes -------------------------------------------------
+}

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat)

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/CreateSessionMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/CreateSessionMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/CreateSessionMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,225 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-
-/**
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * @author <a href="mailto:jmesnil at redhat.com">Jeff Mesnil</a>.
- * 
- * @version <tt>$Revision$</tt>
- */
-public class CreateSessionMessage extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-   
-   private String name;
-   
-   private long sessionChannelID;
-   
-   private int version;
-   
-   private String username;
-   
-   private String password;
-   
-   private int minLargeMessageSize;
-   
-   private boolean xa;
-   
-   private boolean autoCommitSends;
-   
-   private boolean autoCommitAcks;
-
-   private boolean preAcknowledge;
-   
-   private int windowSize;
-
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public CreateSessionMessage(final String name, final long sessionChannelID,
-                               final int version, final String username, final String password,
-                               final int minLargeMessageSize, 
-                               final boolean xa, final boolean autoCommitSends,
-                               final boolean autoCommitAcks, final boolean preAcknowledge, final int windowSize)
-   {
-      super(CREATESESSION);
-      
-      this.name = name;
-      
-      this.sessionChannelID = sessionChannelID;
-      
-      this.version = version;
-
-      this.username = username;
-      
-      this.password = password;
-      
-      this.minLargeMessageSize = minLargeMessageSize;
-      
-      this.xa = xa;
-      
-      this.autoCommitSends = autoCommitSends;
-      
-      this.autoCommitAcks = autoCommitAcks;
-      
-      this.windowSize = windowSize;
-
-      this.preAcknowledge = preAcknowledge;
-   }
-   
-   public CreateSessionMessage()
-   {
-      super(CREATESESSION);
-   }
-
-   // Public --------------------------------------------------------
-
-   public String getName()
-   {
-      return name;
-   }
-   
-   public long getSessionChannelID()
-   {      
-      return sessionChannelID;
-   }
-   
-   public int getVersion()
-   {
-      return version;
-   }
-   
-   public String getUsername()
-   {
-      return username;
-   }
-   
-   public String getPassword()
-   {
-      return password;
-   }
-   
-   public boolean isXA()
-   {
-      return xa;
-   }
-
-   public boolean isAutoCommitSends()
-   {
-      return this.autoCommitSends;
-   }
-   
-   public boolean isAutoCommitAcks()
-   {
-      return this.autoCommitAcks;
-   }
-
-   public boolean isPreAcknowledge()
-   {
-      return preAcknowledge;
-   }
-
-   public int getWindowSize()
-   {
-      return this.windowSize;
-   }
-   
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      buffer.putString(name);
-      buffer.putLong(sessionChannelID);
-      buffer.putInt(version);
-      buffer.putNullableString(username);
-      buffer.putNullableString(password);
-      buffer.putInt(minLargeMessageSize);
-      buffer.putBoolean(xa);
-      buffer.putBoolean(autoCommitSends);
-      buffer.putBoolean(autoCommitAcks);
-      buffer.putInt(windowSize);
-      buffer.putBoolean(preAcknowledge);
-   }
-   
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      name = buffer.getString();
-      sessionChannelID = buffer.getLong();
-      version = buffer.getInt();
-      username = buffer.getNullableString();
-      password = buffer.getNullableString();
-      minLargeMessageSize = buffer.getInt();
-      xa = buffer.getBoolean();
-      autoCommitSends = buffer.getBoolean();
-      autoCommitAcks = buffer.getBoolean();
-      windowSize = buffer.getInt();
-      preAcknowledge = buffer.getBoolean();
-   }
-   
-   public boolean equals(Object other)
-   {
-      if (other instanceof CreateSessionMessage == false)
-      {
-         return false;
-      }
-            
-      CreateSessionMessage r = (CreateSessionMessage)other;
-      
-      boolean matches = super.equals(other) &&
-                        this.name.equals(r.name) &&
-                        this.sessionChannelID == r.sessionChannelID &&
-                        this.version == r.version &&
-                        this.xa == r.xa &&
-                        this.autoCommitSends == r.autoCommitSends &&
-                        this.autoCommitAcks == r.autoCommitAcks &&
-                        (this.username == null ? r.username == null : this.username.equals(r.username)) &&
-                        (this.password == null ? r.password == null : this.password.equals(r.password));
-         
-      return matches;
-   }
-   
-   public final boolean isRequiresConfirmations()
-   {
-      return false;
-   }
-
-   /**
-    * @return
-    */
-   public int getMinLargeMessageSize()
-   {
-      return minLargeMessageSize;
-   }
-   
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/CreateSessionMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/CreateSessionMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/CreateSessionMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/CreateSessionMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,225 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+
+/**
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:jmesnil at redhat.com">Jeff Mesnil</a>.
+ * 
+ * @version <tt>$Revision$</tt>
+ */
+public class CreateSessionMessage extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+   
+   private String name;
+   
+   private long sessionChannelID;
+   
+   private int version;
+   
+   private String username;
+   
+   private String password;
+   
+   private int minLargeMessageSize;
+   
+   private boolean xa;
+   
+   private boolean autoCommitSends;
+   
+   private boolean autoCommitAcks;
+
+   private boolean preAcknowledge;
+   
+   private int windowSize;
+
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public CreateSessionMessage(final String name, final long sessionChannelID,
+                               final int version, final String username, final String password,
+                               final int minLargeMessageSize, 
+                               final boolean xa, final boolean autoCommitSends,
+                               final boolean autoCommitAcks, final boolean preAcknowledge, final int windowSize)
+   {
+      super(CREATESESSION);
+      
+      this.name = name;
+      
+      this.sessionChannelID = sessionChannelID;
+      
+      this.version = version;
+
+      this.username = username;
+      
+      this.password = password;
+      
+      this.minLargeMessageSize = minLargeMessageSize;
+      
+      this.xa = xa;
+      
+      this.autoCommitSends = autoCommitSends;
+      
+      this.autoCommitAcks = autoCommitAcks;
+      
+      this.windowSize = windowSize;
+
+      this.preAcknowledge = preAcknowledge;
+   }
+   
+   public CreateSessionMessage()
+   {
+      super(CREATESESSION);
+   }
+
+   // Public --------------------------------------------------------
+
+   public String getName()
+   {
+      return name;
+   }
+   
+   public long getSessionChannelID()
+   {      
+      return sessionChannelID;
+   }
+   
+   public int getVersion()
+   {
+      return version;
+   }
+   
+   public String getUsername()
+   {
+      return username;
+   }
+   
+   public String getPassword()
+   {
+      return password;
+   }
+   
+   public boolean isXA()
+   {
+      return xa;
+   }
+
+   public boolean isAutoCommitSends()
+   {
+      return this.autoCommitSends;
+   }
+   
+   public boolean isAutoCommitAcks()
+   {
+      return this.autoCommitAcks;
+   }
+
+   public boolean isPreAcknowledge()
+   {
+      return preAcknowledge;
+   }
+
+   public int getWindowSize()
+   {
+      return this.windowSize;
+   }
+   
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      buffer.putString(name);
+      buffer.putLong(sessionChannelID);
+      buffer.putInt(version);
+      buffer.putNullableString(username);
+      buffer.putNullableString(password);
+      buffer.putInt(minLargeMessageSize);
+      buffer.putBoolean(xa);
+      buffer.putBoolean(autoCommitSends);
+      buffer.putBoolean(autoCommitAcks);
+      buffer.putInt(windowSize);
+      buffer.putBoolean(preAcknowledge);
+   }
+   
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      name = buffer.getString();
+      sessionChannelID = buffer.getLong();
+      version = buffer.getInt();
+      username = buffer.getNullableString();
+      password = buffer.getNullableString();
+      minLargeMessageSize = buffer.getInt();
+      xa = buffer.getBoolean();
+      autoCommitSends = buffer.getBoolean();
+      autoCommitAcks = buffer.getBoolean();
+      windowSize = buffer.getInt();
+      preAcknowledge = buffer.getBoolean();
+   }
+   
+   public boolean equals(Object other)
+   {
+      if (other instanceof CreateSessionMessage == false)
+      {
+         return false;
+      }
+            
+      CreateSessionMessage r = (CreateSessionMessage)other;
+      
+      boolean matches = super.equals(other) &&
+                        this.name.equals(r.name) &&
+                        this.sessionChannelID == r.sessionChannelID &&
+                        this.version == r.version &&
+                        this.xa == r.xa &&
+                        this.autoCommitSends == r.autoCommitSends &&
+                        this.autoCommitAcks == r.autoCommitAcks &&
+                        (this.username == null ? r.username == null : this.username.equals(r.username)) &&
+                        (this.password == null ? r.password == null : this.password.equals(r.password));
+         
+      return matches;
+   }
+   
+   public final boolean isRequiresConfirmations()
+   {
+      return false;
+   }
+
+   /**
+    * @return
+    */
+   public int getMinLargeMessageSize()
+   {
+      return minLargeMessageSize;
+   }
+   
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/CreateSessionResponseMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/CreateSessionResponseMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/CreateSessionResponseMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,106 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-
-/**
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * @author <a href="mailto:jmesnil at redhat.com">Jeff Mesnil</a>.
- * 
- * @version <tt>$Revision$</tt>
- */
-public class CreateSessionResponseMessage extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-
-   private int serverVersion;
-   
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public CreateSessionResponseMessage(final int serverVersion)
-   {
-      super(CREATESESSION_RESP);
-
-      this.serverVersion = serverVersion;
-   }
-   
-   public CreateSessionResponseMessage()
-   {
-      super(CREATESESSION_RESP);
-   }
-
-   // Public --------------------------------------------------------
-   
-   public boolean isResponse()
-   {
-      return true;
-   }
-   
-   public int getServerVersion()
-   {
-      return serverVersion;
-   }
-   
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      buffer.putInt(serverVersion);      
-   }
-   
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      serverVersion = buffer.getInt();
-   }
-
-   public boolean equals(Object other)
-   {
-      if (other instanceof CreateSessionResponseMessage == false)
-      {
-         return false;
-      }
-            
-      CreateSessionResponseMessage r = (CreateSessionResponseMessage)other;
-      
-      boolean matches = super.equals(other) &&     
-                        this.serverVersion == r.serverVersion;
-      
-      return matches;
-   }
-   
-   public final boolean isRequiresConfirmations()
-   {
-      return false;
-   }
-
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/CreateSessionResponseMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/CreateSessionResponseMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/CreateSessionResponseMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/CreateSessionResponseMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,106 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+
+/**
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:jmesnil at redhat.com">Jeff Mesnil</a>.
+ * 
+ * @version <tt>$Revision$</tt>
+ */
+public class CreateSessionResponseMessage extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   private int serverVersion;
+   
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public CreateSessionResponseMessage(final int serverVersion)
+   {
+      super(CREATESESSION_RESP);
+
+      this.serverVersion = serverVersion;
+   }
+   
+   public CreateSessionResponseMessage()
+   {
+      super(CREATESESSION_RESP);
+   }
+
+   // Public --------------------------------------------------------
+   
+   public boolean isResponse()
+   {
+      return true;
+   }
+   
+   public int getServerVersion()
+   {
+      return serverVersion;
+   }
+   
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      buffer.putInt(serverVersion);      
+   }
+   
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      serverVersion = buffer.getInt();
+   }
+
+   public boolean equals(Object other)
+   {
+      if (other instanceof CreateSessionResponseMessage == false)
+      {
+         return false;
+      }
+            
+      CreateSessionResponseMessage r = (CreateSessionResponseMessage)other;
+      
+      boolean matches = super.equals(other) &&     
+                        this.serverVersion == r.serverVersion;
+      
+      return matches;
+   }
+   
+   public final boolean isRequiresConfirmations()
+   {
+      return false;
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/MessagingExceptionMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/MessagingExceptionMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/MessagingExceptionMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,109 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import org.jboss.messaging.core.exception.MessagingException;
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-
-/**
- * @author <a href="mailto:jmesnil at redhat.com">Jeff Mesnil</a>
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * 
- * @version <tt>$Revision$</tt>
- * 
- */
-public class MessagingExceptionMessage extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-
-   private MessagingException exception;
-
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public MessagingExceptionMessage(final MessagingException exception)
-   {
-      super(EXCEPTION);
-
-      this.exception = exception;
-   }
-
-   public MessagingExceptionMessage()
-   {
-      super(EXCEPTION);
-   }
-
-   // Public --------------------------------------------------------
-
-   public boolean isResponse()
-   {
-      return true;
-   }
-
-   public MessagingException getException()
-   {
-      return exception;
-   }
-
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      buffer.putInt(exception.getCode());
-      buffer.putNullableString(exception.getMessage());
-   }
-
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      int code = buffer.getInt();
-      String msg = buffer.getNullableString();
-      exception = new MessagingException(code, msg);
-   }
-
-   @Override
-   public String toString()
-   {
-      return getParentString() + ", exception= " + exception + "]";
-   }
-
-   public boolean equals(Object other)
-   {
-      if (other instanceof MessagingExceptionMessage == false)
-      {
-         return false;
-      }
-
-      MessagingExceptionMessage r = (MessagingExceptionMessage)other;
-
-      return super.equals(other) && this.exception.equals(r.exception);
-   }
-
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/MessagingExceptionMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/MessagingExceptionMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/MessagingExceptionMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/MessagingExceptionMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,109 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import org.jboss.messaging.core.exception.MessagingException;
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+
+/**
+ * @author <a href="mailto:jmesnil at redhat.com">Jeff Mesnil</a>
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * 
+ * @version <tt>$Revision$</tt>
+ * 
+ */
+public class MessagingExceptionMessage extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   private MessagingException exception;
+
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public MessagingExceptionMessage(final MessagingException exception)
+   {
+      super(EXCEPTION);
+
+      this.exception = exception;
+   }
+
+   public MessagingExceptionMessage()
+   {
+      super(EXCEPTION);
+   }
+
+   // Public --------------------------------------------------------
+
+   public boolean isResponse()
+   {
+      return true;
+   }
+
+   public MessagingException getException()
+   {
+      return exception;
+   }
+
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      buffer.putInt(exception.getCode());
+      buffer.putNullableString(exception.getMessage());
+   }
+
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      int code = buffer.getInt();
+      String msg = buffer.getNullableString();
+      exception = new MessagingException(code, msg);
+   }
+
+   @Override
+   public String toString()
+   {
+      return getParentString() + ", exception= " + exception + "]";
+   }
+
+   public boolean equals(Object other)
+   {
+      if (other instanceof MessagingExceptionMessage == false)
+      {
+         return false;
+      }
+
+      MessagingExceptionMessage r = (MessagingExceptionMessage)other;
+
+      return super.equals(other) && this.exception.equals(r.exception);
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/NullResponseMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/NullResponseMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/NullResponseMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,50 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors by
- * the @authors tag. See the copyright.txt in the distribution for a full listing of individual contributors. This is
- * free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version.
- * This software is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
- * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
- * details. You should have received a copy of the GNU Lesser General Public License along with this software; if not,
- * write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA, or see the FSF
- * site: http://www.fsf.org.
- */
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-
-/**
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * @version <tt>$Revision$</tt>
- */
-public class NullResponseMessage extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public NullResponseMessage()
-   {
-      super(NULL_RESPONSE);
-   }
-   
-   // Public --------------------------------------------------------
-
-   @Override
-   public boolean isResponse()
-   {
-      return true;
-   }
-
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/NullResponseMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/NullResponseMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/NullResponseMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/NullResponseMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,50 @@
+/*
+ * JBoss, Home of Professional Open Source Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors by
+ * the @authors tag. See the copyright.txt in the distribution for a full listing of individual contributors. This is
+ * free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version.
+ * This software is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
+ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
+ * details. You should have received a copy of the GNU Lesser General Public License along with this software; if not,
+ * write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA, or see the FSF
+ * site: http://www.fsf.org.
+ */
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+
+/**
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @version <tt>$Revision$</tt>
+ */
+public class NullResponseMessage extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public NullResponseMessage()
+   {
+      super(NULL_RESPONSE);
+   }
+   
+   // Public --------------------------------------------------------
+
+   @Override
+   public boolean isResponse()
+   {
+      return true;
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/PacketImpl.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/PacketImpl.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/PacketImpl.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,271 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors by
- * the @authors tag. See the copyright.txt in the distribution for a full listing of individual contributors. This is
- * free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version.
- * This software is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
- * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
- * details. You should have received a copy of the GNU Lesser General Public License along with this software; if not,
- * write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA, or see the FSF
- * site: http://www.fsf.org.
- */
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import org.jboss.messaging.core.logging.Logger;
-import org.jboss.messaging.core.remoting.Packet;
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-import org.jboss.messaging.util.DataConstants;
-
-/**
- * @author <a href="mailto:jmesnil at redhat.com">Jeff Mesnil</a>
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * @version <tt>$Revision$</tt>
- */
-public class PacketImpl implements Packet
-{
-   // Constants -------------------------------------------------------------------------
-
-   private static final Logger log = Logger.getLogger(PacketImpl.class);
-
-   public static final int DEFAULT_PACKET_SIZE = 1024;
-   
-   // The minimal size for all the packets, Common data for all the packets (look at PacketImpl.encode)
-   protected static final int BASIC_PACKET_SIZE = DataConstants.SIZE_INT + DataConstants.SIZE_BYTE + DataConstants.SIZE_LONG;
-
-   private long channelID;
-
-   private final byte type;
-   
-   private int size;
-
-   // The packet types
-   // -----------------------------------------------------------------------------------
-
-   public static final byte PING = 10;
-
-   public static final byte PONG = 11;
-
-   // Miscellaneous
-   public static final byte EXCEPTION = 20;
-
-   public static final byte NULL_RESPONSE = 21;
-
-   public static final byte PACKETS_CONFIRMED = 22;
-
-   public static final byte REPLICATION_RESPONSE = 23;
-
-   public static final byte EARLY_RESPONSE = 24;
-
-   // Server
-   public static final byte CREATESESSION = 30;
-
-   public static final byte CREATESESSION_RESP = 31;
-
-   public static final byte REATTACH_SESSION = 32;
-
-   public static final byte REATTACH_SESSION_RESP = 33;
-
-   public static final byte REPLICATE_CREATESESSION = 34;
-
-   // Session
-   public static final byte SESS_CREATECONSUMER = 40;
-
-   public static final byte SESS_ACKNOWLEDGE = 44;
-   
-   public static final byte SESS_EXPIRED = 45;
-
-   public static final byte SESS_COMMIT = 46;
-
-   public static final byte SESS_ROLLBACK = 47;
-
-   public static final byte SESS_QUEUEQUERY = 48;
-
-   public static final byte SESS_QUEUEQUERY_RESP = 49;
-
-   public static final byte SESS_CREATEQUEUE = 50;
-
-   public static final byte SESS_DELETE_QUEUE = 51;
-
-   public static final byte SESS_ADD_DESTINATION = 52;
-
-   public static final byte SESS_REMOVE_DESTINATION = 53;
-
-   public static final byte SESS_BINDINGQUERY = 54;
-
-   public static final byte SESS_BINDINGQUERY_RESP = 55;
-
-   public static final byte SESS_XA_START = 56;
-
-   public static final byte SESS_XA_END = 57;
-
-   public static final byte SESS_XA_COMMIT = 58;
-
-   public static final byte SESS_XA_PREPARE = 59;
-
-   public static final byte SESS_XA_RESP = 60;
-
-   public static final byte SESS_XA_ROLLBACK = 61;
-
-   public static final byte SESS_XA_JOIN = 62;
-
-   public static final byte SESS_XA_SUSPEND = 63;
-
-   public static final byte SESS_XA_RESUME = 64;
-
-   public static final byte SESS_XA_FORGET = 65;
-
-   public static final byte SESS_XA_INDOUBT_XIDS = 66;
-
-   public static final byte SESS_XA_INDOUBT_XIDS_RESP = 67;
-
-   public static final byte SESS_XA_SET_TIMEOUT = 68;
-
-   public static final byte SESS_XA_SET_TIMEOUT_RESP = 69;
-
-   public static final byte SESS_XA_GET_TIMEOUT = 70;
-
-   public static final byte SESS_XA_GET_TIMEOUT_RESP = 71;
-
-   public static final byte SESS_START = 72;
-
-   public static final byte SESS_STOP = 73;
-
-   public static final byte SESS_CLOSE = 74;
-
-   public static final byte SESS_FLOWTOKEN = 75;
-
-   public static final byte SESS_SEND = 76;
-
-   public static final byte SESS_SEND_CONTINUATION = 77;
-
-   public static final byte SESS_CONSUMER_CLOSE = 78;
-
-   public static final byte SESS_RECEIVE_MSG = 79;
-
-   public static final byte SESS_RECEIVE_CONTINUATION = 80;
-
-   public static final byte SESS_FAILOVER_COMPLETE = 81;
-
-   public static final byte SESS_REPLICATE_DELIVERY = 82;
-
-   // Static --------------------------------------------------------
-
-   public PacketImpl(final byte type)
-   {
-      this.type = type;
-   }
-
-   // Public --------------------------------------------------------
-
-   
-   public byte getType()
-   {
-      return type;
-   }
-
-   public long getChannelID()
-   {
-      return channelID;
-   }
-
-   public void setChannelID(final long channelID)
-   {
-      this.channelID = channelID;
-   }
-   
-   public int encode(final MessagingBuffer buffer)
-   {
-      // The standard header fields
-      buffer.putInt(0); // The length gets filled in at the end
-      buffer.putByte(type);
-      buffer.putLong(channelID);
-
-      encodeBody(buffer);
-
-      size = buffer.position();
-      
-      // The length doesn't include the actual length byte
-      int len = size - DataConstants.SIZE_INT;
-
-      buffer.putInt(0, len);
-
-      buffer.flip();
-      
-      return size;
-   }
-
-   public void decode(final MessagingBuffer buffer)
-   {
-      channelID = buffer.getLong();
-
-      decodeBody(buffer);
-      
-      size = buffer.position();
-   }
-   
-   public final int getPacketSize()
-   {
-      return size;
-   }
-   
-   public int getRequiredBufferSize()
-   {
-      return DEFAULT_PACKET_SIZE;
-   }
-
-   public boolean isResponse()
-   {
-      return false;
-   }
-
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-   }
-
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-   }
-
-   public boolean isRequiresConfirmations()
-   {
-      return true;
-   }
-
-   public boolean isWriteAlways()
-   {
-      return false;
-   }
-
-   @Override
-   public String toString()
-   {
-      return getParentString() + "]";
-   }
-
-   @Override
-   public boolean equals(final Object other)
-   {
-      if (other instanceof PacketImpl == false)
-      {
-         return false;
-      }
-
-      PacketImpl r = (PacketImpl)other;
-
-      return r.type == type && r.channelID == channelID;
-   }
-
-   // Package protected ---------------------------------------------
-
-   protected String getParentString()
-   {
-      return "PACKET[type=" + type + ", channelID=" + channelID + "]";
-   }
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/PacketImpl.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/PacketImpl.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/PacketImpl.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/PacketImpl.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,271 @@
+/*
+ * JBoss, Home of Professional Open Source Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors by
+ * the @authors tag. See the copyright.txt in the distribution for a full listing of individual contributors. This is
+ * free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version.
+ * This software is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
+ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
+ * details. You should have received a copy of the GNU Lesser General Public License along with this software; if not,
+ * write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA, or see the FSF
+ * site: http://www.fsf.org.
+ */
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import org.jboss.messaging.core.logging.Logger;
+import org.jboss.messaging.core.remoting.Packet;
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+import org.jboss.messaging.util.DataConstants;
+
+/**
+ * @author <a href="mailto:jmesnil at redhat.com">Jeff Mesnil</a>
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @version <tt>$Revision$</tt>
+ */
+public class PacketImpl implements Packet
+{
+   // Constants -------------------------------------------------------------------------
+
+   private static final Logger log = Logger.getLogger(PacketImpl.class);
+
+   public static final int DEFAULT_PACKET_SIZE = 1024;
+   
+   // The minimal size for all the packets, Common data for all the packets (look at PacketImpl.encode)
+   protected static final int BASIC_PACKET_SIZE = DataConstants.SIZE_INT + DataConstants.SIZE_BYTE + DataConstants.SIZE_LONG;
+
+   private long channelID;
+
+   private final byte type;
+   
+   private int size;
+
+   // The packet types
+   // -----------------------------------------------------------------------------------
+
+   public static final byte PING = 10;
+
+   public static final byte PONG = 11;
+
+   // Miscellaneous
+   public static final byte EXCEPTION = 20;
+
+   public static final byte NULL_RESPONSE = 21;
+
+   public static final byte PACKETS_CONFIRMED = 22;
+
+   public static final byte REPLICATION_RESPONSE = 23;
+
+   public static final byte EARLY_RESPONSE = 24;
+
+   // Server
+   public static final byte CREATESESSION = 30;
+
+   public static final byte CREATESESSION_RESP = 31;
+
+   public static final byte REATTACH_SESSION = 32;
+
+   public static final byte REATTACH_SESSION_RESP = 33;
+
+   public static final byte REPLICATE_CREATESESSION = 34;
+
+   // Session
+   public static final byte SESS_CREATECONSUMER = 40;
+
+   public static final byte SESS_ACKNOWLEDGE = 44;
+   
+   public static final byte SESS_EXPIRED = 45;
+
+   public static final byte SESS_COMMIT = 46;
+
+   public static final byte SESS_ROLLBACK = 47;
+
+   public static final byte SESS_QUEUEQUERY = 48;
+
+   public static final byte SESS_QUEUEQUERY_RESP = 49;
+
+   public static final byte SESS_CREATEQUEUE = 50;
+
+   public static final byte SESS_DELETE_QUEUE = 51;
+
+   public static final byte SESS_ADD_DESTINATION = 52;
+
+   public static final byte SESS_REMOVE_DESTINATION = 53;
+
+   public static final byte SESS_BINDINGQUERY = 54;
+
+   public static final byte SESS_BINDINGQUERY_RESP = 55;
+
+   public static final byte SESS_XA_START = 56;
+
+   public static final byte SESS_XA_END = 57;
+
+   public static final byte SESS_XA_COMMIT = 58;
+
+   public static final byte SESS_XA_PREPARE = 59;
+
+   public static final byte SESS_XA_RESP = 60;
+
+   public static final byte SESS_XA_ROLLBACK = 61;
+
+   public static final byte SESS_XA_JOIN = 62;
+
+   public static final byte SESS_XA_SUSPEND = 63;
+
+   public static final byte SESS_XA_RESUME = 64;
+
+   public static final byte SESS_XA_FORGET = 65;
+
+   public static final byte SESS_XA_INDOUBT_XIDS = 66;
+
+   public static final byte SESS_XA_INDOUBT_XIDS_RESP = 67;
+
+   public static final byte SESS_XA_SET_TIMEOUT = 68;
+
+   public static final byte SESS_XA_SET_TIMEOUT_RESP = 69;
+
+   public static final byte SESS_XA_GET_TIMEOUT = 70;
+
+   public static final byte SESS_XA_GET_TIMEOUT_RESP = 71;
+
+   public static final byte SESS_START = 72;
+
+   public static final byte SESS_STOP = 73;
+
+   public static final byte SESS_CLOSE = 74;
+
+   public static final byte SESS_FLOWTOKEN = 75;
+
+   public static final byte SESS_SEND = 76;
+
+   public static final byte SESS_SEND_CONTINUATION = 77;
+
+   public static final byte SESS_CONSUMER_CLOSE = 78;
+
+   public static final byte SESS_RECEIVE_MSG = 79;
+
+   public static final byte SESS_RECEIVE_CONTINUATION = 80;
+
+   public static final byte SESS_FAILOVER_COMPLETE = 81;
+
+   public static final byte SESS_REPLICATE_DELIVERY = 82;
+
+   // Static --------------------------------------------------------
+
+   public PacketImpl(final byte type)
+   {
+      this.type = type;
+   }
+
+   // Public --------------------------------------------------------
+
+   
+   public byte getType()
+   {
+      return type;
+   }
+
+   public long getChannelID()
+   {
+      return channelID;
+   }
+
+   public void setChannelID(final long channelID)
+   {
+      this.channelID = channelID;
+   }
+   
+   public int encode(final MessagingBuffer buffer)
+   {
+      // The standard header fields
+      buffer.putInt(0); // The length gets filled in at the end
+      buffer.putByte(type);
+      buffer.putLong(channelID);
+
+      encodeBody(buffer);
+
+      size = buffer.position();
+      
+      // The length doesn't include the actual length byte
+      int len = size - DataConstants.SIZE_INT;
+
+      buffer.putInt(0, len);
+
+      buffer.flip();
+      
+      return size;
+   }
+
+   public void decode(final MessagingBuffer buffer)
+   {
+      channelID = buffer.getLong();
+
+      decodeBody(buffer);
+      
+      size = buffer.position();
+   }
+   
+   public final int getPacketSize()
+   {
+      return size;
+   }
+   
+   public int getRequiredBufferSize()
+   {
+      return DEFAULT_PACKET_SIZE;
+   }
+
+   public boolean isResponse()
+   {
+      return false;
+   }
+
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+   }
+
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+   }
+
+   public boolean isRequiresConfirmations()
+   {
+      return true;
+   }
+
+   public boolean isWriteAlways()
+   {
+      return false;
+   }
+
+   @Override
+   public String toString()
+   {
+      return getParentString() + "]";
+   }
+
+   @Override
+   public boolean equals(final Object other)
+   {
+      if (other instanceof PacketImpl == false)
+      {
+         return false;
+      }
+
+      PacketImpl r = (PacketImpl)other;
+
+      return r.type == type && r.channelID == channelID;
+   }
+
+   // Package protected ---------------------------------------------
+
+   protected String getParentString()
+   {
+      return "PACKET[type=" + type + ", channelID=" + channelID + "]";
+   }
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/PacketsConfirmedMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/PacketsConfirmedMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/PacketsConfirmedMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,106 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-
-/**
- * 
- * A PacketsConfirmedMessage
- * 
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- *
- */
-public class PacketsConfirmedMessage extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-
-   private int commandID;
-         
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public PacketsConfirmedMessage(final int commandID)
-   {
-      super(PACKETS_CONFIRMED);
-
-      this.commandID = commandID;
-   }
-   
-   public PacketsConfirmedMessage()
-   {
-      super(PACKETS_CONFIRMED);
-   }
-
-   // Public --------------------------------------------------------
-
-   public int getCommandID()
-   {
-      return this.commandID;
-   }
-   
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      buffer.putInt(commandID);
-   }
-   
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      commandID = buffer.getInt();
-   }
-   
-   @Override
-   public String toString()
-   {
-      return getParentString() + ", commandID=" + commandID + "]";
-   }
-   
-   public boolean equals(Object other)
-   {
-      if (other instanceof PacketsConfirmedMessage == false)
-      {
-         return false;
-      }
-            
-      PacketsConfirmedMessage r = (PacketsConfirmedMessage)other;
-      
-      return super.equals(other) && this.commandID == r.commandID;
-   }
-   
-   public final boolean isRequiresConfirmations()
-   {
-      return false;
-   }
-   
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}
-

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/PacketsConfirmedMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/PacketsConfirmedMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/PacketsConfirmedMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/PacketsConfirmedMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,106 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+
+/**
+ * 
+ * A PacketsConfirmedMessage
+ * 
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ *
+ */
+public class PacketsConfirmedMessage extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   private int commandID;
+         
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public PacketsConfirmedMessage(final int commandID)
+   {
+      super(PACKETS_CONFIRMED);
+
+      this.commandID = commandID;
+   }
+   
+   public PacketsConfirmedMessage()
+   {
+      super(PACKETS_CONFIRMED);
+   }
+
+   // Public --------------------------------------------------------
+
+   public int getCommandID()
+   {
+      return this.commandID;
+   }
+   
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      buffer.putInt(commandID);
+   }
+   
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      commandID = buffer.getInt();
+   }
+   
+   @Override
+   public String toString()
+   {
+      return getParentString() + ", commandID=" + commandID + "]";
+   }
+   
+   public boolean equals(Object other)
+   {
+      if (other instanceof PacketsConfirmedMessage == false)
+      {
+         return false;
+      }
+            
+      PacketsConfirmedMessage r = (PacketsConfirmedMessage)other;
+      
+      return super.equals(other) && this.commandID == r.commandID;
+   }
+   
+   public final boolean isRequiresConfirmations()
+   {
+      return false;
+   }
+   
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}
+

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/Ping.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/Ping.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/Ping.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,108 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-
-/**
- * 
- * A Ping
- * 
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- *
- */
-public class Ping extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-
-   private long expirePeriod;
-
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public Ping(final long expirePeriod)
-   {
-      super(PING);
-
-      this.expirePeriod = expirePeriod;
-   }
-   
-   public Ping()
-   {
-      super(PING);
-   }
-
-   // Public --------------------------------------------------------
-
-   public long getExpirePeriod()
-   {
-      return expirePeriod;
-   }
-   
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      buffer.putLong(expirePeriod);
-   }
-   
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      expirePeriod = buffer.getLong();
-   }
-
-   @Override
-   public String toString()
-   {
-      StringBuffer buf = new StringBuffer(getParentString());
-      buf.append(", expirePeriod=" + expirePeriod);
-      buf.append("]");
-      return buf.toString();
-   }
-   
-   public boolean equals(Object other)
-   {
-      if (other instanceof Ping == false)
-      {
-         return false;
-      }
-            
-      Ping r = (Ping)other;
-      
-      return super.equals(other) && this.expirePeriod == r.expirePeriod;
-   }
-   
-   public final boolean isRequiresConfirmations()
-   {
-      return false;
-   }
-
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/Ping.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/Ping.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/Ping.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/Ping.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,108 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+
+/**
+ * 
+ * A Ping
+ * 
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ *
+ */
+public class Ping extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   private long expirePeriod;
+
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public Ping(final long expirePeriod)
+   {
+      super(PING);
+
+      this.expirePeriod = expirePeriod;
+   }
+   
+   public Ping()
+   {
+      super(PING);
+   }
+
+   // Public --------------------------------------------------------
+
+   public long getExpirePeriod()
+   {
+      return expirePeriod;
+   }
+   
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      buffer.putLong(expirePeriod);
+   }
+   
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      expirePeriod = buffer.getLong();
+   }
+
+   @Override
+   public String toString()
+   {
+      StringBuffer buf = new StringBuffer(getParentString());
+      buf.append(", expirePeriod=" + expirePeriod);
+      buf.append("]");
+      return buf.toString();
+   }
+   
+   public boolean equals(Object other)
+   {
+      if (other instanceof Ping == false)
+      {
+         return false;
+      }
+            
+      Ping r = (Ping)other;
+      
+      return super.equals(other) && this.expirePeriod == r.expirePeriod;
+   }
+   
+   public final boolean isRequiresConfirmations()
+   {
+      return false;
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/Pong.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/Pong.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/Pong.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,120 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-
-/**
- * 
- * A Pong
- * 
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- *
- */
-public class Pong extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-
-   //This is reserved for future use - for now we also pass back -1 - meaning "don't change period"
-   private long newPeriod;
-
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public Pong(final long newPeriod)
-   {
-      super(PONG);
-
-      this.newPeriod = newPeriod;
-   }
-   
-   public Pong()
-   {
-      super(PONG);
-   }
-
-   // Public --------------------------------------------------------
-
-   public boolean isResponse()
-   {
-      return true;
-   }
-   
-   public long getNewPeriod()
-   {
-      return newPeriod;
-   }
-   
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      buffer.putLong(newPeriod);
-   }
-   
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      newPeriod = buffer.getLong();
-   }
-   
-   public boolean isWriteAlways()
-   {
-      return true;
-   }
-
-   @Override
-   public String toString()
-   {
-      StringBuffer buf = new StringBuffer(getParentString());
-      buf.append(", newPeriod=" + newPeriod);
-      buf.append("]");
-      return buf.toString();
-   }
-   
-   public boolean equals(Object other)
-   {
-      if (other instanceof Pong == false)
-      {
-         return false;
-      }
-            
-      Pong r = (Pong)other;
-      
-      return super.equals(other) && this.newPeriod == r.newPeriod;
-   }
-   
-   public final boolean isRequiresConfirmations()
-   {
-      return false;
-   }
-
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}
-

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/Pong.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/Pong.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/Pong.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/Pong.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,120 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+
+/**
+ * 
+ * A Pong
+ * 
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ *
+ */
+public class Pong extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   //This is reserved for future use - for now we also pass back -1 - meaning "don't change period"
+   private long newPeriod;
+
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public Pong(final long newPeriod)
+   {
+      super(PONG);
+
+      this.newPeriod = newPeriod;
+   }
+   
+   public Pong()
+   {
+      super(PONG);
+   }
+
+   // Public --------------------------------------------------------
+
+   public boolean isResponse()
+   {
+      return true;
+   }
+   
+   public long getNewPeriod()
+   {
+      return newPeriod;
+   }
+   
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      buffer.putLong(newPeriod);
+   }
+   
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      newPeriod = buffer.getLong();
+   }
+   
+   public boolean isWriteAlways()
+   {
+      return true;
+   }
+
+   @Override
+   public String toString()
+   {
+      StringBuffer buf = new StringBuffer(getParentString());
+      buf.append(", newPeriod=" + newPeriod);
+      buf.append("]");
+      return buf.toString();
+   }
+   
+   public boolean equals(Object other)
+   {
+      if (other instanceof Pong == false)
+      {
+         return false;
+      }
+            
+      Pong r = (Pong)other;
+      
+      return super.equals(other) && this.newPeriod == r.newPeriod;
+   }
+   
+   public final boolean isRequiresConfirmations()
+   {
+      return false;
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}
+

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/ReattachSessionMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/ReattachSessionMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/ReattachSessionMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,111 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-
-/**
- * 
- * A ReattachSessionMessage
- * 
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- *
- */
-public class ReattachSessionMessage extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-
-   private String name;
-   
-   private int lastReceivedCommandID;
-   
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public ReattachSessionMessage(final String name, final int lastReceivedCommandID)
-   {
-      super(REATTACH_SESSION);
-
-      this.name = name;
-      
-      this.lastReceivedCommandID = lastReceivedCommandID;
-   }
-   
-   public ReattachSessionMessage()
-   {
-      super(REATTACH_SESSION);
-   }
-
-   // Public --------------------------------------------------------
-
-   public String getName()
-   {
-      return name;
-   }
-   
-   public int getLastReceivedCommandID()
-   {
-      return lastReceivedCommandID;
-   }
-   
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      buffer.putString(name);
-      buffer.putInt(lastReceivedCommandID);
-   }
-   
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      name = buffer.getString();
-      lastReceivedCommandID = buffer.getInt();
-   }
-
-   public boolean equals(Object other)
-   {
-      if (other instanceof ReattachSessionMessage == false)
-      {
-         return false;
-      }
-            
-      ReattachSessionMessage r = (ReattachSessionMessage)other;
-      
-      return super.equals(other) && this.name.equals(r.name);
-   }
-   
-   public final boolean isRequiresConfirmations()
-   {
-      return false;
-   }
-
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}
-

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/ReattachSessionMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/ReattachSessionMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/ReattachSessionMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/ReattachSessionMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,111 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+
+/**
+ * 
+ * A ReattachSessionMessage
+ * 
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ *
+ */
+public class ReattachSessionMessage extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   private String name;
+   
+   private int lastReceivedCommandID;
+   
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public ReattachSessionMessage(final String name, final int lastReceivedCommandID)
+   {
+      super(REATTACH_SESSION);
+
+      this.name = name;
+      
+      this.lastReceivedCommandID = lastReceivedCommandID;
+   }
+   
+   public ReattachSessionMessage()
+   {
+      super(REATTACH_SESSION);
+   }
+
+   // Public --------------------------------------------------------
+
+   public String getName()
+   {
+      return name;
+   }
+   
+   public int getLastReceivedCommandID()
+   {
+      return lastReceivedCommandID;
+   }
+   
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      buffer.putString(name);
+      buffer.putInt(lastReceivedCommandID);
+   }
+   
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      name = buffer.getString();
+      lastReceivedCommandID = buffer.getInt();
+   }
+
+   public boolean equals(Object other)
+   {
+      if (other instanceof ReattachSessionMessage == false)
+      {
+         return false;
+      }
+            
+      ReattachSessionMessage r = (ReattachSessionMessage)other;
+      
+      return super.equals(other) && this.name.equals(r.name);
+   }
+   
+   public final boolean isRequiresConfirmations()
+   {
+      return false;
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}
+

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/ReattachSessionResponseMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/ReattachSessionResponseMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/ReattachSessionResponseMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,117 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-
-/**
- * 
- * A ReattachSessionResponseMessage
- * 
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- *
- */
-public class ReattachSessionResponseMessage extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-
-   private int lastReceivedCommandID;
-   
-   //Is this flag really necessary - try removing it
-   private boolean removed;
-   
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public ReattachSessionResponseMessage(final int lastReceivedCommandID, final boolean removed)
-   {
-      super(REATTACH_SESSION_RESP);
-
-      this.lastReceivedCommandID = lastReceivedCommandID;
-      
-      this.removed = removed;
-   }
-   
-   public ReattachSessionResponseMessage()
-   {
-      super(REATTACH_SESSION_RESP);
-   }
-
-   // Public --------------------------------------------------------
-
-   public int getLastReceivedCommandID()
-   {
-      return lastReceivedCommandID;
-   }
-   
-   public boolean isRemoved()
-   {
-      return removed;
-   }
-   
-   public void encodeBody(final MessagingBuffer buffer)
-   { 
-      buffer.putInt(lastReceivedCommandID);
-      buffer.putBoolean(removed);
-   }
-   
-   public void decodeBody(final MessagingBuffer buffer)
-   { 
-      lastReceivedCommandID = buffer.getInt();
-      removed = buffer.getBoolean();
-   }
-   
-   public boolean isResponse()
-   {      
-      return true;
-   }
-
-   public boolean equals(Object other)
-   {
-      if (other instanceof ReattachSessionResponseMessage == false)
-      {
-         return false;
-      }
-            
-      ReattachSessionResponseMessage r = (ReattachSessionResponseMessage)other;
-      
-      return super.equals(other) && this.lastReceivedCommandID == r.lastReceivedCommandID;
-   }
-   
-   public final boolean isRequiresConfirmations()
-   {
-      return false;
-   }
-
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}
-

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/ReattachSessionResponseMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/ReattachSessionResponseMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/ReattachSessionResponseMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/ReattachSessionResponseMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,117 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+
+/**
+ * 
+ * A ReattachSessionResponseMessage
+ * 
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ *
+ */
+public class ReattachSessionResponseMessage extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   private int lastReceivedCommandID;
+   
+   //Is this flag really necessary - try removing it
+   private boolean removed;
+   
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public ReattachSessionResponseMessage(final int lastReceivedCommandID, final boolean removed)
+   {
+      super(REATTACH_SESSION_RESP);
+
+      this.lastReceivedCommandID = lastReceivedCommandID;
+      
+      this.removed = removed;
+   }
+   
+   public ReattachSessionResponseMessage()
+   {
+      super(REATTACH_SESSION_RESP);
+   }
+
+   // Public --------------------------------------------------------
+
+   public int getLastReceivedCommandID()
+   {
+      return lastReceivedCommandID;
+   }
+   
+   public boolean isRemoved()
+   {
+      return removed;
+   }
+   
+   public void encodeBody(final MessagingBuffer buffer)
+   { 
+      buffer.putInt(lastReceivedCommandID);
+      buffer.putBoolean(removed);
+   }
+   
+   public void decodeBody(final MessagingBuffer buffer)
+   { 
+      lastReceivedCommandID = buffer.getInt();
+      removed = buffer.getBoolean();
+   }
+   
+   public boolean isResponse()
+   {      
+      return true;
+   }
+
+   public boolean equals(Object other)
+   {
+      if (other instanceof ReattachSessionResponseMessage == false)
+      {
+         return false;
+      }
+            
+      ReattachSessionResponseMessage r = (ReattachSessionResponseMessage)other;
+      
+      return super.equals(other) && this.lastReceivedCommandID == r.lastReceivedCommandID;
+   }
+   
+   public final boolean isRequiresConfirmations()
+   {
+      return false;
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}
+

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/ReplicateCreateSessionMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/ReplicateCreateSessionMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/ReplicateCreateSessionMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,229 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-
-/**
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * @author <a href="mailto:jmesnil at redhat.com">Jeff Mesnil</a>.
- * 
- * @version <tt>$Revision$</tt>
- */
-public class ReplicateCreateSessionMessage extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-
-   private String name;
-
-   private long sessionChannelID;
-
-   private int version;
-
-   private String username;
-
-   private String password;
-   
-   private int minLargeMessageSize;
-
-   private boolean xa;
-
-   private boolean autoCommitSends;
-
-   private boolean autoCommitAcks;
-
-   private boolean preAcknowledge;
-   
-   private int windowSize;
-
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public ReplicateCreateSessionMessage(final String name,
-                                        final long sessionChannelID,
-                                        final int version,
-                                        final String username,
-                                        final String password,
-                                        final int minLargeMessageSize,
-                                        final boolean xa,
-                                        final boolean autoCommitSends,
-                                        final boolean autoCommitAcks,
-                                        final boolean preAcknowledge,
-                                        final int windowSize)
-   {
-      super(REPLICATE_CREATESESSION);
-
-      this.name = name;
-
-      this.sessionChannelID = sessionChannelID;
-
-      this.version = version;
-
-      this.username = username;
-
-      this.password = password;
-      
-      this.minLargeMessageSize = minLargeMessageSize;
-
-      this.xa = xa;
-
-      this.autoCommitSends = autoCommitSends;
-
-      this.autoCommitAcks = autoCommitAcks;
-
-      this.preAcknowledge = preAcknowledge;
-
-      this.windowSize = windowSize;
-   }
-
-   public ReplicateCreateSessionMessage()
-   {
-      super(REPLICATE_CREATESESSION);
-   }
-
-   // Public --------------------------------------------------------
-
-   public String getName()
-   {
-      return name;
-   }
-
-   public long getSessionChannelID()
-   {
-      return sessionChannelID;
-   }
-
-   public int getVersion()
-   {
-      return version;
-   }
-
-   public String getUsername()
-   {
-      return username;
-   }
-
-   public String getPassword()
-   {
-      return password;
-   }
-   
-   public int getMinLargeMessageSize()
-   {
-      return minLargeMessageSize;
-   }
-
-   public boolean isXA()
-   {
-      return xa;
-   }
-
-   public boolean isAutoCommitSends()
-   {
-      return this.autoCommitSends;
-   }
-
-   public boolean isAutoCommitAcks()
-   {
-      return this.autoCommitAcks;
-   }
-
-   public boolean isPreAcknowledge()
-   {
-      return preAcknowledge;
-   }
-
-   public int getWindowSize()
-   {
-      return this.windowSize;
-   }
-
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      buffer.putString(name);
-      buffer.putLong(sessionChannelID);
-      buffer.putInt(version);
-      buffer.putNullableString(username);
-      buffer.putNullableString(password);
-      buffer.putInt(minLargeMessageSize);
-      buffer.putBoolean(xa);
-      buffer.putBoolean(autoCommitSends);
-      buffer.putBoolean(autoCommitAcks);
-      buffer.putInt(windowSize);
-      buffer.putBoolean(preAcknowledge);
-   }
-
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      name = buffer.getString();
-      sessionChannelID = buffer.getLong();
-      version = buffer.getInt();
-      username = buffer.getNullableString();
-      password = buffer.getNullableString();
-      minLargeMessageSize = buffer.getInt();
-      xa = buffer.getBoolean();
-      autoCommitSends = buffer.getBoolean();
-      autoCommitAcks = buffer.getBoolean();
-      windowSize = buffer.getInt();
-      preAcknowledge = buffer.getBoolean();
-   }
-
-   public boolean equals(Object other)
-   {
-      if (other instanceof ReplicateCreateSessionMessage == false)
-      {
-         return false;
-      }
-
-      ReplicateCreateSessionMessage r = (ReplicateCreateSessionMessage)other;
-
-      boolean matches = super.equals(other) && this.name.equals(r.name) &&
-                        this.sessionChannelID == r.sessionChannelID &&
-                        this.version == r.version &&
-                        this.xa == r.xa &&
-                        this.autoCommitSends == r.autoCommitSends &&
-                        this.autoCommitAcks == r.autoCommitAcks &&
-                        (this.username == null ? r.username == null : this.username.equals(r.username)) &&
-                        (this.password == null ? r.password == null : this.password.equals(r.password)) &&
-                        this.minLargeMessageSize == r.minLargeMessageSize &&
-                        this.windowSize == r.windowSize;
-
-      return matches;
-   }
-
-   public final boolean isRequiresConfirmations()
-   {
-      return false;
-   }
-
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/ReplicateCreateSessionMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/ReplicateCreateSessionMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/ReplicateCreateSessionMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/ReplicateCreateSessionMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,229 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+
+/**
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:jmesnil at redhat.com">Jeff Mesnil</a>.
+ * 
+ * @version <tt>$Revision$</tt>
+ */
+public class ReplicateCreateSessionMessage extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   private String name;
+
+   private long sessionChannelID;
+
+   private int version;
+
+   private String username;
+
+   private String password;
+   
+   private int minLargeMessageSize;
+
+   private boolean xa;
+
+   private boolean autoCommitSends;
+
+   private boolean autoCommitAcks;
+
+   private boolean preAcknowledge;
+   
+   private int windowSize;
+
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public ReplicateCreateSessionMessage(final String name,
+                                        final long sessionChannelID,
+                                        final int version,
+                                        final String username,
+                                        final String password,
+                                        final int minLargeMessageSize,
+                                        final boolean xa,
+                                        final boolean autoCommitSends,
+                                        final boolean autoCommitAcks,
+                                        final boolean preAcknowledge,
+                                        final int windowSize)
+   {
+      super(REPLICATE_CREATESESSION);
+
+      this.name = name;
+
+      this.sessionChannelID = sessionChannelID;
+
+      this.version = version;
+
+      this.username = username;
+
+      this.password = password;
+      
+      this.minLargeMessageSize = minLargeMessageSize;
+
+      this.xa = xa;
+
+      this.autoCommitSends = autoCommitSends;
+
+      this.autoCommitAcks = autoCommitAcks;
+
+      this.preAcknowledge = preAcknowledge;
+
+      this.windowSize = windowSize;
+   }
+
+   public ReplicateCreateSessionMessage()
+   {
+      super(REPLICATE_CREATESESSION);
+   }
+
+   // Public --------------------------------------------------------
+
+   public String getName()
+   {
+      return name;
+   }
+
+   public long getSessionChannelID()
+   {
+      return sessionChannelID;
+   }
+
+   public int getVersion()
+   {
+      return version;
+   }
+
+   public String getUsername()
+   {
+      return username;
+   }
+
+   public String getPassword()
+   {
+      return password;
+   }
+   
+   public int getMinLargeMessageSize()
+   {
+      return minLargeMessageSize;
+   }
+
+   public boolean isXA()
+   {
+      return xa;
+   }
+
+   public boolean isAutoCommitSends()
+   {
+      return this.autoCommitSends;
+   }
+
+   public boolean isAutoCommitAcks()
+   {
+      return this.autoCommitAcks;
+   }
+
+   public boolean isPreAcknowledge()
+   {
+      return preAcknowledge;
+   }
+
+   public int getWindowSize()
+   {
+      return this.windowSize;
+   }
+
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      buffer.putString(name);
+      buffer.putLong(sessionChannelID);
+      buffer.putInt(version);
+      buffer.putNullableString(username);
+      buffer.putNullableString(password);
+      buffer.putInt(minLargeMessageSize);
+      buffer.putBoolean(xa);
+      buffer.putBoolean(autoCommitSends);
+      buffer.putBoolean(autoCommitAcks);
+      buffer.putInt(windowSize);
+      buffer.putBoolean(preAcknowledge);
+   }
+
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      name = buffer.getString();
+      sessionChannelID = buffer.getLong();
+      version = buffer.getInt();
+      username = buffer.getNullableString();
+      password = buffer.getNullableString();
+      minLargeMessageSize = buffer.getInt();
+      xa = buffer.getBoolean();
+      autoCommitSends = buffer.getBoolean();
+      autoCommitAcks = buffer.getBoolean();
+      windowSize = buffer.getInt();
+      preAcknowledge = buffer.getBoolean();
+   }
+
+   public boolean equals(Object other)
+   {
+      if (other instanceof ReplicateCreateSessionMessage == false)
+      {
+         return false;
+      }
+
+      ReplicateCreateSessionMessage r = (ReplicateCreateSessionMessage)other;
+
+      boolean matches = super.equals(other) && this.name.equals(r.name) &&
+                        this.sessionChannelID == r.sessionChannelID &&
+                        this.version == r.version &&
+                        this.xa == r.xa &&
+                        this.autoCommitSends == r.autoCommitSends &&
+                        this.autoCommitAcks == r.autoCommitAcks &&
+                        (this.username == null ? r.username == null : this.username.equals(r.username)) &&
+                        (this.password == null ? r.password == null : this.password.equals(r.password)) &&
+                        this.minLargeMessageSize == r.minLargeMessageSize &&
+                        this.windowSize == r.windowSize;
+
+      return matches;
+   }
+
+   public final boolean isRequiresConfirmations()
+   {
+      return false;
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionAcknowledgeMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionAcknowledgeMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionAcknowledgeMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,108 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors by
- * the @authors tag. See the copyright.txt in the distribution for a full listing of individual contributors. This is
- * free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version.
- * This software is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
- * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
- * details. You should have received a copy of the GNU Lesser General Public License along with this software; if not,
- * write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA, or see the FSF
- * site: http://www.fsf.org.
- */
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-
-/**
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * @version <tt>$Revision$</tt>
- */
-public class SessionAcknowledgeMessage extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-
-   private long consumerID;
-
-   private long messageID;
-
-   private boolean requiresResponse;
-   
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public SessionAcknowledgeMessage(final long consumerID, final long messageID, final boolean requiresResponse)
-   {
-      super(SESS_ACKNOWLEDGE);
-
-      this.consumerID = consumerID;
-
-      this.messageID = messageID;
-
-      this.requiresResponse = requiresResponse;
-   }
-
-   public SessionAcknowledgeMessage()
-   {
-      super(SESS_ACKNOWLEDGE);
-   }
-
-   // Public --------------------------------------------------------
-
-   public long getConsumerID()
-   {
-      return consumerID;
-   }
-
-   public long getMessageID()
-   {
-      return messageID;
-   }
-
-   public boolean isRequiresResponse()
-   {
-      return requiresResponse;
-   }
-
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      buffer.putLong(consumerID);
-
-      buffer.putLong(messageID);
-
-      buffer.putBoolean(requiresResponse);
-   }
-
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      consumerID = buffer.getLong();
-
-      messageID = buffer.getLong();
-
-      requiresResponse = buffer.getBoolean();
-   }
-
-   public boolean equals(Object other)
-   {
-      if (other instanceof SessionAcknowledgeMessage == false)
-      {
-         return false;
-      }
-
-      SessionAcknowledgeMessage r = (SessionAcknowledgeMessage)other;
-
-      return super.equals(other) && this.consumerID == r.consumerID &&
-             this.messageID == r.messageID &&
-             this.requiresResponse == r.requiresResponse;
-   }
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionAcknowledgeMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionAcknowledgeMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionAcknowledgeMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionAcknowledgeMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,108 @@
+/*
+ * JBoss, Home of Professional Open Source Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors by
+ * the @authors tag. See the copyright.txt in the distribution for a full listing of individual contributors. This is
+ * free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version.
+ * This software is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
+ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
+ * details. You should have received a copy of the GNU Lesser General Public License along with this software; if not,
+ * write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA, or see the FSF
+ * site: http://www.fsf.org.
+ */
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+
+/**
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @version <tt>$Revision$</tt>
+ */
+public class SessionAcknowledgeMessage extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   private long consumerID;
+
+   private long messageID;
+
+   private boolean requiresResponse;
+   
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public SessionAcknowledgeMessage(final long consumerID, final long messageID, final boolean requiresResponse)
+   {
+      super(SESS_ACKNOWLEDGE);
+
+      this.consumerID = consumerID;
+
+      this.messageID = messageID;
+
+      this.requiresResponse = requiresResponse;
+   }
+
+   public SessionAcknowledgeMessage()
+   {
+      super(SESS_ACKNOWLEDGE);
+   }
+
+   // Public --------------------------------------------------------
+
+   public long getConsumerID()
+   {
+      return consumerID;
+   }
+
+   public long getMessageID()
+   {
+      return messageID;
+   }
+
+   public boolean isRequiresResponse()
+   {
+      return requiresResponse;
+   }
+
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      buffer.putLong(consumerID);
+
+      buffer.putLong(messageID);
+
+      buffer.putBoolean(requiresResponse);
+   }
+
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      consumerID = buffer.getLong();
+
+      messageID = buffer.getLong();
+
+      requiresResponse = buffer.getBoolean();
+   }
+
+   public boolean equals(Object other)
+   {
+      if (other instanceof SessionAcknowledgeMessage == false)
+      {
+         return false;
+      }
+
+      SessionAcknowledgeMessage r = (SessionAcknowledgeMessage)other;
+
+      return super.equals(other) && this.consumerID == r.consumerID &&
+             this.messageID == r.messageID &&
+             this.requiresResponse == r.requiresResponse;
+   }
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionAddDestinationMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionAddDestinationMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionAddDestinationMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,127 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-import org.jboss.messaging.util.SimpleString;
-
-
-/**
- * 
- * A SessionAddDestinationMessage
- * 
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- *
- */
-public class SessionAddDestinationMessage extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-   
-   private SimpleString address;
-   
-   private boolean durable;
-   
-   private boolean temporary;
-   
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public SessionAddDestinationMessage(final SimpleString address, final boolean durable, final boolean temp)
-   {
-      super(SESS_ADD_DESTINATION);
-      
-      this.address = address;
-      
-      this.durable = durable;
-      
-      this.temporary = temp;
-   }
-   
-   public SessionAddDestinationMessage()
-   {
-      super(SESS_ADD_DESTINATION);
-   }
-
-   // Public --------------------------------------------------------
-   
-   public SimpleString getAddress()
-   {
-      return address;
-   }
-   
-   public boolean isDurable()
-   {
-   	return durable;
-   }
-   
-   public boolean isTemporary()
-   {
-      return temporary;
-   }
-   
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      buffer.putSimpleString(address);
-      buffer.putBoolean(durable);
-      buffer.putBoolean(temporary);
-   }
-   
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      address = buffer.getSimpleString();
-      durable = buffer.getBoolean();
-      temporary = buffer.getBoolean();
-   }
-   
-   @Override
-   public String toString()
-   {
-      return getParentString() + ", address=" + address + ", temp=" + durable +"]";
-   }
-   
-   public boolean equals(Object other)
-   {
-      if (other instanceof SessionAddDestinationMessage == false)
-      {
-         return false;
-      }
-            
-      SessionAddDestinationMessage r = (SessionAddDestinationMessage)other;
-      
-      return super.equals(other) && this.address.equals(r.address) &&
-             this.durable == r.durable &&
-             this.temporary == r.temporary;
-   }
-   
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}
-

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionAddDestinationMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionAddDestinationMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionAddDestinationMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionAddDestinationMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,127 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+import org.jboss.messaging.util.SimpleString;
+
+
+/**
+ * 
+ * A SessionAddDestinationMessage
+ * 
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ *
+ */
+public class SessionAddDestinationMessage extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+   
+   private SimpleString address;
+   
+   private boolean durable;
+   
+   private boolean temporary;
+   
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public SessionAddDestinationMessage(final SimpleString address, final boolean durable, final boolean temp)
+   {
+      super(SESS_ADD_DESTINATION);
+      
+      this.address = address;
+      
+      this.durable = durable;
+      
+      this.temporary = temp;
+   }
+   
+   public SessionAddDestinationMessage()
+   {
+      super(SESS_ADD_DESTINATION);
+   }
+
+   // Public --------------------------------------------------------
+   
+   public SimpleString getAddress()
+   {
+      return address;
+   }
+   
+   public boolean isDurable()
+   {
+   	return durable;
+   }
+   
+   public boolean isTemporary()
+   {
+      return temporary;
+   }
+   
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      buffer.putSimpleString(address);
+      buffer.putBoolean(durable);
+      buffer.putBoolean(temporary);
+   }
+   
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      address = buffer.getSimpleString();
+      durable = buffer.getBoolean();
+      temporary = buffer.getBoolean();
+   }
+   
+   @Override
+   public String toString()
+   {
+      return getParentString() + ", address=" + address + ", temp=" + durable +"]";
+   }
+   
+   public boolean equals(Object other)
+   {
+      if (other instanceof SessionAddDestinationMessage == false)
+      {
+         return false;
+      }
+            
+      SessionAddDestinationMessage r = (SessionAddDestinationMessage)other;
+      
+      return super.equals(other) && this.address.equals(r.address) &&
+             this.durable == r.durable &&
+             this.temporary == r.temporary;
+   }
+   
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}
+

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionBindingQueryMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionBindingQueryMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionBindingQueryMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,79 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-import org.jboss.messaging.util.SimpleString;
-
-
-/**
- * 
- * A SessionQueueQueryMessage
- * 
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- *
- */
-public class SessionBindingQueryMessage extends PacketImpl
-{
-   private SimpleString address;
-
-   public SessionBindingQueryMessage(final SimpleString address)
-   {
-      super(SESS_BINDINGQUERY);
-
-      this.address = address;            
-   }
-   
-   public SessionBindingQueryMessage()
-   {
-      super(SESS_BINDINGQUERY);          
-   }
-
-   public SimpleString getAddress()
-   {
-      return address;
-   }
-   
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      buffer.putSimpleString(address);
-   }
-   
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      address = buffer.getSimpleString();
-   }
-   
-   public boolean equals(Object other)
-   {
-      if (other instanceof SessionBindingQueryMessage == false)
-      {
-         return false;
-      }
-            
-      SessionBindingQueryMessage r = (SessionBindingQueryMessage)other;
-      
-      return super.equals(other) && this.address.equals(r.address);
-   }
-   
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionBindingQueryMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionBindingQueryMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionBindingQueryMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionBindingQueryMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,79 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+import org.jboss.messaging.util.SimpleString;
+
+
+/**
+ * 
+ * A SessionQueueQueryMessage
+ * 
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ *
+ */
+public class SessionBindingQueryMessage extends PacketImpl
+{
+   private SimpleString address;
+
+   public SessionBindingQueryMessage(final SimpleString address)
+   {
+      super(SESS_BINDINGQUERY);
+
+      this.address = address;            
+   }
+   
+   public SessionBindingQueryMessage()
+   {
+      super(SESS_BINDINGQUERY);          
+   }
+
+   public SimpleString getAddress()
+   {
+      return address;
+   }
+   
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      buffer.putSimpleString(address);
+   }
+   
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      address = buffer.getSimpleString();
+   }
+   
+   public boolean equals(Object other)
+   {
+      if (other instanceof SessionBindingQueryMessage == false)
+      {
+         return false;
+      }
+            
+      SessionBindingQueryMessage r = (SessionBindingQueryMessage)other;
+      
+      return super.equals(other) && this.address.equals(r.address);
+   }
+   
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionBindingQueryResponseMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionBindingQueryResponseMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionBindingQueryResponseMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,128 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-import org.jboss.messaging.util.SimpleString;
-
-/**
- * 
- * A SessionBindingQueryResponseMessage
- * 
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- *
- */
-public class SessionBindingQueryResponseMessage extends PacketImpl
-{
-   private boolean exists;
-   
-   private List<SimpleString> queueNames;
-   
-   public SessionBindingQueryResponseMessage(final boolean exists, final List<SimpleString> queueNames)
-   {
-      super(SESS_BINDINGQUERY_RESP);
-
-      this.exists = exists;
-
-      this.queueNames = queueNames;
-   }
-   
-   public SessionBindingQueryResponseMessage()
-   {
-      super(SESS_BINDINGQUERY_RESP);
-   }
-   
-   public boolean isResponse()
-   {
-      return true;
-   }
-
-   public boolean isExists()
-   {
-      return exists;
-   }
-
-   public List<SimpleString> getQueueNames()
-   {
-      return this.queueNames;
-   }
-   
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      buffer.putBoolean(exists);
-      buffer.putInt(queueNames.size());      
-      for (SimpleString queueName: queueNames)
-      {
-         buffer.putSimpleString(queueName);
-      }      
-   }
-   
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      exists = buffer.getBoolean();      
-      int numQueues = buffer.getInt();      
-      queueNames = new ArrayList<SimpleString>(numQueues);      
-      for (int i = 0; i < numQueues; i++)
-      {
-         queueNames.add(buffer.getSimpleString());
-      }          
-   }
-   
-   public boolean equals(Object other)
-   {
-      if (other instanceof SessionBindingQueryResponseMessage == false)
-      {
-         return false;
-      }
-            
-      SessionBindingQueryResponseMessage r = (SessionBindingQueryResponseMessage)other;
-      
-      if (super.equals(other) && this.exists == r.exists)
-      {
-         if (this.queueNames.size() == r.queueNames.size())
-         {
-            for (int i = 0; i < queueNames.size(); i++)
-            {
-               if (!this.queueNames.get(i).equals(r.queueNames.get(i)))
-               {
-                  return false;
-               }
-            }
-         }
-         else
-         {
-            return false;
-         }
-      }
-      else
-      {
-         return false;
-      }
-      
-      return true;
-   }
-   
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionBindingQueryResponseMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionBindingQueryResponseMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionBindingQueryResponseMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionBindingQueryResponseMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,128 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+import org.jboss.messaging.util.SimpleString;
+
+/**
+ * 
+ * A SessionBindingQueryResponseMessage
+ * 
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ *
+ */
+public class SessionBindingQueryResponseMessage extends PacketImpl
+{
+   private boolean exists;
+   
+   private List<SimpleString> queueNames;
+   
+   public SessionBindingQueryResponseMessage(final boolean exists, final List<SimpleString> queueNames)
+   {
+      super(SESS_BINDINGQUERY_RESP);
+
+      this.exists = exists;
+
+      this.queueNames = queueNames;
+   }
+   
+   public SessionBindingQueryResponseMessage()
+   {
+      super(SESS_BINDINGQUERY_RESP);
+   }
+   
+   public boolean isResponse()
+   {
+      return true;
+   }
+
+   public boolean isExists()
+   {
+      return exists;
+   }
+
+   public List<SimpleString> getQueueNames()
+   {
+      return this.queueNames;
+   }
+   
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      buffer.putBoolean(exists);
+      buffer.putInt(queueNames.size());      
+      for (SimpleString queueName: queueNames)
+      {
+         buffer.putSimpleString(queueName);
+      }      
+   }
+   
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      exists = buffer.getBoolean();      
+      int numQueues = buffer.getInt();      
+      queueNames = new ArrayList<SimpleString>(numQueues);      
+      for (int i = 0; i < numQueues; i++)
+      {
+         queueNames.add(buffer.getSimpleString());
+      }          
+   }
+   
+   public boolean equals(Object other)
+   {
+      if (other instanceof SessionBindingQueryResponseMessage == false)
+      {
+         return false;
+      }
+            
+      SessionBindingQueryResponseMessage r = (SessionBindingQueryResponseMessage)other;
+      
+      if (super.equals(other) && this.exists == r.exists)
+      {
+         if (this.queueNames.size() == r.queueNames.size())
+         {
+            for (int i = 0; i < queueNames.size(); i++)
+            {
+               if (!this.queueNames.get(i).equals(r.queueNames.get(i)))
+               {
+                  return false;
+               }
+            }
+         }
+         else
+         {
+            return false;
+         }
+      }
+      else
+      {
+         return false;
+      }
+      
+      return true;
+   }
+   
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionCloseMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionCloseMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionCloseMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,57 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors by
- * the @authors tag. See the copyright.txt in the distribution for a full listing of individual contributors. This is
- * free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version.
- * This software is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
- * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
- * details. You should have received a copy of the GNU Lesser General Public License along with this software; if not,
- * write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA, or see the FSF
- * site: http://www.fsf.org.
- */
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-
-/**
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * @version <tt>$Revision$</tt>
- */
-public class SessionCloseMessage extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public SessionCloseMessage()
-   {
-      super(SESS_CLOSE);
-   }
-
-   // Public --------------------------------------------------------
- 
-   @Override
-   public boolean equals(final Object other)
-   {
-      if (other instanceof SessionCloseMessage == false)
-      {
-         return false;
-      }
-
-      SessionCloseMessage r = (SessionCloseMessage)other;
-
-      return super.equals(other);
-   }     
-   
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionCloseMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionCloseMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionCloseMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionCloseMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,57 @@
+/*
+ * JBoss, Home of Professional Open Source Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors by
+ * the @authors tag. See the copyright.txt in the distribution for a full listing of individual contributors. This is
+ * free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version.
+ * This software is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
+ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
+ * details. You should have received a copy of the GNU Lesser General Public License along with this software; if not,
+ * write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA, or see the FSF
+ * site: http://www.fsf.org.
+ */
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+
+/**
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @version <tt>$Revision$</tt>
+ */
+public class SessionCloseMessage extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public SessionCloseMessage()
+   {
+      super(SESS_CLOSE);
+   }
+
+   // Public --------------------------------------------------------
+ 
+   @Override
+   public boolean equals(final Object other)
+   {
+      if (other instanceof SessionCloseMessage == false)
+      {
+         return false;
+      }
+
+      SessionCloseMessage r = (SessionCloseMessage)other;
+
+      return super.equals(other);
+   }     
+   
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionConsumerCloseMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionConsumerCloseMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionConsumerCloseMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,97 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-
-/**
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * 
- * @version <tt>$Revision$</tt>
- */
-public class SessionConsumerCloseMessage extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-
-   private long consumerID;
-   
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public SessionConsumerCloseMessage(final long objectID)
-   {
-      super(SESS_CONSUMER_CLOSE);
-
-      this.consumerID = objectID;
-   }
-   
-   public SessionConsumerCloseMessage()
-   {
-      super(SESS_CONSUMER_CLOSE);
-   }
-
-   // Public --------------------------------------------------------
-
-   public long getConsumerID()
-   {
-      return consumerID;
-   }
-   
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      buffer.putLong(consumerID);
-   }
-   
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      consumerID = buffer.getLong();
-   }
-   
-   @Override
-   public String toString()
-   {
-      return getParentString() + ", consumerID=" + consumerID + "]";
-   }
-   
-   public boolean equals(Object other)
-   {
-      if (other instanceof SessionConsumerCloseMessage == false)
-      {
-         return false;
-      }
-            
-      SessionConsumerCloseMessage r = (SessionConsumerCloseMessage)other;
-      
-      return super.equals(other) && this.consumerID == r.consumerID;
-   }
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionConsumerCloseMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionConsumerCloseMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionConsumerCloseMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionConsumerCloseMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,97 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+
+/**
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * 
+ * @version <tt>$Revision$</tt>
+ */
+public class SessionConsumerCloseMessage extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   private long consumerID;
+   
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public SessionConsumerCloseMessage(final long objectID)
+   {
+      super(SESS_CONSUMER_CLOSE);
+
+      this.consumerID = objectID;
+   }
+   
+   public SessionConsumerCloseMessage()
+   {
+      super(SESS_CONSUMER_CLOSE);
+   }
+
+   // Public --------------------------------------------------------
+
+   public long getConsumerID()
+   {
+      return consumerID;
+   }
+   
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      buffer.putLong(consumerID);
+   }
+   
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      consumerID = buffer.getLong();
+   }
+   
+   @Override
+   public String toString()
+   {
+      return getParentString() + ", consumerID=" + consumerID + "]";
+   }
+   
+   public boolean equals(Object other)
+   {
+      if (other instanceof SessionConsumerCloseMessage == false)
+      {
+         return false;
+      }
+            
+      SessionConsumerCloseMessage r = (SessionConsumerCloseMessage)other;
+      
+      return super.equals(other) && this.consumerID == r.consumerID;
+   }
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionConsumerFlowCreditMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionConsumerFlowCreditMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionConsumerFlowCreditMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,110 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-
-/**
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * @author <a href="mailto:jmesnil at redhat.com">Jeff Mesnil</a>.
- * 
- * @version <tt>$Revision$</tt>
- */
-public class SessionConsumerFlowCreditMessage extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-
-   private long consumerID;
-   
-   private int credits;
-   
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public SessionConsumerFlowCreditMessage(final long consumerID, final int credits)
-   {
-      super(SESS_FLOWTOKEN);
-
-      this.consumerID = consumerID;
-      
-      this.credits = credits;
-   }
-   
-   public SessionConsumerFlowCreditMessage()
-   {
-      super(SESS_FLOWTOKEN);
-   }
-
-   // Public --------------------------------------------------------
-
-   public long getConsumerID()
-   {
-      return consumerID;
-   }
-   
-   public int getCredits()
-   {
-      return credits;
-   }
-   
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      buffer.putLong(consumerID);
-      buffer.putInt(credits);
-   }
-   
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      consumerID = buffer.getLong();
-      credits = buffer.getInt();
-   }
-
-   @Override
-   public String toString()
-   {
-      return getParentString() + ", consumerID=" + consumerID + ", credits=" + credits + "]";
-   }
-   
-   public boolean equals(Object other)
-   {
-      if (other instanceof SessionConsumerFlowCreditMessage == false)
-      {
-         return false;
-      }
-            
-      SessionConsumerFlowCreditMessage r = (SessionConsumerFlowCreditMessage)other;
-      
-      return super.equals(other) && this.credits == r.credits
-       && this.consumerID == r.consumerID;
-   }
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionConsumerFlowCreditMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionConsumerFlowCreditMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionConsumerFlowCreditMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionConsumerFlowCreditMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,110 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+
+/**
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:jmesnil at redhat.com">Jeff Mesnil</a>.
+ * 
+ * @version <tt>$Revision$</tt>
+ */
+public class SessionConsumerFlowCreditMessage extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   private long consumerID;
+   
+   private int credits;
+   
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public SessionConsumerFlowCreditMessage(final long consumerID, final int credits)
+   {
+      super(SESS_FLOWTOKEN);
+
+      this.consumerID = consumerID;
+      
+      this.credits = credits;
+   }
+   
+   public SessionConsumerFlowCreditMessage()
+   {
+      super(SESS_FLOWTOKEN);
+   }
+
+   // Public --------------------------------------------------------
+
+   public long getConsumerID()
+   {
+      return consumerID;
+   }
+   
+   public int getCredits()
+   {
+      return credits;
+   }
+   
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      buffer.putLong(consumerID);
+      buffer.putInt(credits);
+   }
+   
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      consumerID = buffer.getLong();
+      credits = buffer.getInt();
+   }
+
+   @Override
+   public String toString()
+   {
+      return getParentString() + ", consumerID=" + consumerID + ", credits=" + credits + "]";
+   }
+   
+   public boolean equals(Object other)
+   {
+      if (other instanceof SessionConsumerFlowCreditMessage == false)
+      {
+         return false;
+      }
+            
+      SessionConsumerFlowCreditMessage r = (SessionConsumerFlowCreditMessage)other;
+      
+      return super.equals(other) && this.credits == r.credits
+       && this.consumerID == r.consumerID;
+   }
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionContinuationMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionContinuationMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionContinuationMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,116 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-import org.jboss.messaging.util.DataConstants;
-
-/**
- * A SessionContinuationMessage
- *
- * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
- * 
- * Created Dec 5, 2008 10:08:40 AM
- *
- *
- */
-public abstract class SessionContinuationMessage extends PacketImpl
-{
-
-   // Constants -----------------------------------------------------
-
-   public static final int SESSION_CONTINUATION_BASE_SIZE = BASIC_PACKET_SIZE + DataConstants.SIZE_INT +
-                                                            DataConstants.SIZE_BOOLEAN;
-
-   // Attributes ----------------------------------------------------
-
-   protected byte[] body;
-
-   protected boolean continues;
-
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public SessionContinuationMessage(byte type, final byte[] body, final boolean continues)
-   {
-      super(type);
-      this.body = body;
-      this.continues = continues;
-   }
-
-   public SessionContinuationMessage(byte type)
-   {
-      super(type);
-   }
-
-   // Public --------------------------------------------------------
-
-   /**
-    * @return the body
-    */
-   public byte[] getBody()
-   {
-      return body;
-   }
-
-   /**
-    * @return the continues
-    */
-   public boolean isContinues()
-   {
-      return continues;
-   }
-
-   @Override
-   public int getRequiredBufferSize()
-   {
-      return SESSION_CONTINUATION_BASE_SIZE + body.length; 
-   }
-
-   @Override
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      buffer.putInt(body.length);
-      buffer.putBytes(body);
-      buffer.putBoolean(continues);
-   }
-
-   @Override
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      int size = buffer.getInt();
-      body = new byte[size];
-      buffer.getBytes(body);
-      continues = buffer.getBoolean();
-   }
-
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionContinuationMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionContinuationMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionContinuationMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionContinuationMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,116 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+import org.jboss.messaging.util.DataConstants;
+
+/**
+ * A SessionContinuationMessage
+ *
+ * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
+ * 
+ * Created Dec 5, 2008 10:08:40 AM
+ *
+ *
+ */
+public abstract class SessionContinuationMessage extends PacketImpl
+{
+
+   // Constants -----------------------------------------------------
+
+   public static final int SESSION_CONTINUATION_BASE_SIZE = BASIC_PACKET_SIZE + DataConstants.SIZE_INT +
+                                                            DataConstants.SIZE_BOOLEAN;
+
+   // Attributes ----------------------------------------------------
+
+   protected byte[] body;
+
+   protected boolean continues;
+
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public SessionContinuationMessage(byte type, final byte[] body, final boolean continues)
+   {
+      super(type);
+      this.body = body;
+      this.continues = continues;
+   }
+
+   public SessionContinuationMessage(byte type)
+   {
+      super(type);
+   }
+
+   // Public --------------------------------------------------------
+
+   /**
+    * @return the body
+    */
+   public byte[] getBody()
+   {
+      return body;
+   }
+
+   /**
+    * @return the continues
+    */
+   public boolean isContinues()
+   {
+      return continues;
+   }
+
+   @Override
+   public int getRequiredBufferSize()
+   {
+      return SESSION_CONTINUATION_BASE_SIZE + body.length; 
+   }
+
+   @Override
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      buffer.putInt(body.length);
+      buffer.putBytes(body);
+      buffer.putBoolean(continues);
+   }
+
+   @Override
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      int size = buffer.getInt();
+      body = new byte[size];
+      buffer.getBytes(body);
+      continues = buffer.getBoolean();
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionCreateConsumerMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionCreateConsumerMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionCreateConsumerMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,128 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-import org.jboss.messaging.util.SimpleString;
-
-
-/**
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- *
- * @version <tt>$Revision$</tt>
- */
-public class SessionCreateConsumerMessage extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-
-   private SimpleString queueName;
-
-   private SimpleString filterString;
-
-   private boolean browseOnly;
-
-
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public SessionCreateConsumerMessage(final SimpleString queueName, final SimpleString filterString,
-   		                              final boolean browseOnly)
-   {
-      super(SESS_CREATECONSUMER);
-
-      this.queueName = queueName;
-      this.filterString = filterString;
-      this.browseOnly = browseOnly;
-   }
-
-   public SessionCreateConsumerMessage()
-   {
-      super(SESS_CREATECONSUMER);
-   }
-
-   // Public --------------------------------------------------------
-
-   @Override
-   public String toString()
-   {
-      StringBuffer buff = new StringBuffer(getParentString());
-      buff.append(", queueName=" + queueName);
-      buff.append(", filterString=" + filterString);
-      buff.append("]");
-      return buff.toString();
-   }
-
-   public SimpleString getQueueName()
-   {
-      return queueName;
-   }
-
-   public SimpleString getFilterString()
-   {
-      return filterString;
-   }
-
-   public boolean isBrowseOnly()
-   {
-      return browseOnly;
-   }
-
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      buffer.putSimpleString(queueName);
-      buffer.putNullableSimpleString(filterString);
-      buffer.putBoolean(browseOnly);
-   }
-
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      queueName = buffer.getSimpleString();
-      filterString = buffer.getNullableSimpleString();
-      browseOnly = buffer.getBoolean();
-   }
-
-   public boolean equals(Object other)
-   {
-      if (other instanceof SessionCreateConsumerMessage == false)
-      {
-         return false;
-      }
-            
-      SessionCreateConsumerMessage r = (SessionCreateConsumerMessage)other;
-      
-      return super.equals(other) && 
-             this.queueName.equals(r.queueName) &&
-             this.filterString == null ? r.filterString == null : this.filterString.equals(r.filterString);                           
-   }
-   
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionCreateConsumerMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionCreateConsumerMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionCreateConsumerMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionCreateConsumerMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,128 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+import org.jboss.messaging.util.SimpleString;
+
+
+/**
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ *
+ * @version <tt>$Revision$</tt>
+ */
+public class SessionCreateConsumerMessage extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   private SimpleString queueName;
+
+   private SimpleString filterString;
+
+   private boolean browseOnly;
+
+
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public SessionCreateConsumerMessage(final SimpleString queueName, final SimpleString filterString,
+   		                              final boolean browseOnly)
+   {
+      super(SESS_CREATECONSUMER);
+
+      this.queueName = queueName;
+      this.filterString = filterString;
+      this.browseOnly = browseOnly;
+   }
+
+   public SessionCreateConsumerMessage()
+   {
+      super(SESS_CREATECONSUMER);
+   }
+
+   // Public --------------------------------------------------------
+
+   @Override
+   public String toString()
+   {
+      StringBuffer buff = new StringBuffer(getParentString());
+      buff.append(", queueName=" + queueName);
+      buff.append(", filterString=" + filterString);
+      buff.append("]");
+      return buff.toString();
+   }
+
+   public SimpleString getQueueName()
+   {
+      return queueName;
+   }
+
+   public SimpleString getFilterString()
+   {
+      return filterString;
+   }
+
+   public boolean isBrowseOnly()
+   {
+      return browseOnly;
+   }
+
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      buffer.putSimpleString(queueName);
+      buffer.putNullableSimpleString(filterString);
+      buffer.putBoolean(browseOnly);
+   }
+
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      queueName = buffer.getSimpleString();
+      filterString = buffer.getNullableSimpleString();
+      browseOnly = buffer.getBoolean();
+   }
+
+   public boolean equals(Object other)
+   {
+      if (other instanceof SessionCreateConsumerMessage == false)
+      {
+         return false;
+      }
+            
+      SessionCreateConsumerMessage r = (SessionCreateConsumerMessage)other;
+      
+      return super.equals(other) && 
+             this.queueName.equals(r.queueName) &&
+             this.filterString == null ? r.filterString == null : this.filterString.equals(r.filterString);                           
+   }
+   
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionCreateQueueMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionCreateQueueMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionCreateQueueMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,147 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-import org.jboss.messaging.util.SimpleString;
-
-/**
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
-
- * @version <tt>$Revision$</tt>
- */
-public class SessionCreateQueueMessage extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-
-   private SimpleString address;
-   private SimpleString queueName;
-   private SimpleString filterString;
-   private boolean durable;
-   private boolean temporary;
-
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public SessionCreateQueueMessage(final SimpleString address, final SimpleString queueName,
-   		final SimpleString filterString, final boolean durable, final boolean temporary)
-   {
-      super(SESS_CREATEQUEUE);
-
-      this.address = address;
-      this.queueName = queueName;
-      this.filterString = filterString;
-      this.durable = durable;
-      this.temporary = temporary;
-   }
-   
-   public SessionCreateQueueMessage()
-   {
-      super(SESS_CREATEQUEUE);
-   }
-
-   // Public --------------------------------------------------------
-
-   @Override
-   public String toString()
-   {
-      StringBuffer buff = new StringBuffer(getParentString());
-      buff.append(", address=" + address);
-      buff.append(", queueName=" + queueName);
-      buff.append(", filterString=" + filterString);
-      buff.append(", durable=" + durable);
-      buff.append(", temporary=" + temporary);
-      buff.append("]");
-      return buff.toString();
-   }
-   
-   public SimpleString getAddress()
-   {
-      return address;
-   }
-
-   public SimpleString getQueueName()
-   {
-      return queueName;
-   }
-
-   public SimpleString getFilterString()
-   {
-      return filterString;
-   }
-
-   public boolean isDurable()
-   {
-      return durable;
-   }
-   
-   public boolean isTemporary()
-   {
-      return temporary;
-   }
-    
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      buffer.putSimpleString(address);
-      buffer.putSimpleString(queueName);
-      buffer.putNullableSimpleString(filterString);
-      buffer.putBoolean(durable);
-      buffer.putBoolean(temporary);
-   }
-   
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      address = buffer.getSimpleString();
-      queueName = buffer.getSimpleString();
-      filterString = buffer.getNullableSimpleString();
-      durable = buffer.getBoolean();
-      temporary = buffer.getBoolean();
-   }
-   
-   public boolean equals(Object other)
-   {
-      if (other instanceof SessionCreateQueueMessage == false)
-      {
-         return false;
-      }
-            
-      SessionCreateQueueMessage r = (SessionCreateQueueMessage)other;
-      
-      return super.equals(other) && r.address.equals(this.address) && 
-             r.queueName.equals(this.queueName) &&
-             (r.filterString == null ? this.filterString == null : r.filterString.equals(this.filterString)) &&
-             r.durable == this.durable &&
-             r.temporary == this.temporary;
-   }
-
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionCreateQueueMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionCreateQueueMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionCreateQueueMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionCreateQueueMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,147 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+import org.jboss.messaging.util.SimpleString;
+
+/**
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+
+ * @version <tt>$Revision$</tt>
+ */
+public class SessionCreateQueueMessage extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   private SimpleString address;
+   private SimpleString queueName;
+   private SimpleString filterString;
+   private boolean durable;
+   private boolean temporary;
+
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public SessionCreateQueueMessage(final SimpleString address, final SimpleString queueName,
+   		final SimpleString filterString, final boolean durable, final boolean temporary)
+   {
+      super(SESS_CREATEQUEUE);
+
+      this.address = address;
+      this.queueName = queueName;
+      this.filterString = filterString;
+      this.durable = durable;
+      this.temporary = temporary;
+   }
+   
+   public SessionCreateQueueMessage()
+   {
+      super(SESS_CREATEQUEUE);
+   }
+
+   // Public --------------------------------------------------------
+
+   @Override
+   public String toString()
+   {
+      StringBuffer buff = new StringBuffer(getParentString());
+      buff.append(", address=" + address);
+      buff.append(", queueName=" + queueName);
+      buff.append(", filterString=" + filterString);
+      buff.append(", durable=" + durable);
+      buff.append(", temporary=" + temporary);
+      buff.append("]");
+      return buff.toString();
+   }
+   
+   public SimpleString getAddress()
+   {
+      return address;
+   }
+
+   public SimpleString getQueueName()
+   {
+      return queueName;
+   }
+
+   public SimpleString getFilterString()
+   {
+      return filterString;
+   }
+
+   public boolean isDurable()
+   {
+      return durable;
+   }
+   
+   public boolean isTemporary()
+   {
+      return temporary;
+   }
+    
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      buffer.putSimpleString(address);
+      buffer.putSimpleString(queueName);
+      buffer.putNullableSimpleString(filterString);
+      buffer.putBoolean(durable);
+      buffer.putBoolean(temporary);
+   }
+   
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      address = buffer.getSimpleString();
+      queueName = buffer.getSimpleString();
+      filterString = buffer.getNullableSimpleString();
+      durable = buffer.getBoolean();
+      temporary = buffer.getBoolean();
+   }
+   
+   public boolean equals(Object other)
+   {
+      if (other instanceof SessionCreateQueueMessage == false)
+      {
+         return false;
+      }
+            
+      SessionCreateQueueMessage r = (SessionCreateQueueMessage)other;
+      
+      return super.equals(other) && r.address.equals(this.address) && 
+             r.queueName.equals(this.queueName) &&
+             (r.filterString == null ? this.filterString == null : r.filterString.equals(this.filterString)) &&
+             r.durable == this.durable &&
+             r.temporary == this.temporary;
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionDeleteQueueMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionDeleteQueueMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionDeleteQueueMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,102 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-import org.jboss.messaging.util.SimpleString;
-
-/**
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
-
- * @version <tt>$Revision$</tt>
- */
-public class SessionDeleteQueueMessage extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-
-   private SimpleString queueName;
-
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public SessionDeleteQueueMessage(final SimpleString queueName)
-   {
-      super(SESS_DELETE_QUEUE);
-
-      this.queueName = queueName;
-   }
-   
-   public SessionDeleteQueueMessage()
-   {
-      super(SESS_DELETE_QUEUE);
-   }
-
-   // Public --------------------------------------------------------
-
-   @Override
-   public String toString()
-   {
-      StringBuffer buff = new StringBuffer(getParentString());
-      buff.append(", queueName=" + queueName);
-      buff.append("]");
-      return buff.toString();
-   }
-   
-   public SimpleString getQueueName()
-   {
-      return queueName;
-   }
-      
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      buffer.putSimpleString(queueName);
-   }
-   
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      queueName = buffer.getSimpleString();
-   }
-
-   public boolean equals(Object other)
-   {
-      if (other instanceof SessionDeleteQueueMessage == false)
-      {
-         return false;
-      }
-            
-      SessionDeleteQueueMessage r = (SessionDeleteQueueMessage)other;
-      
-      return super.equals(other) && r.queueName.equals(this.queueName);
-   }
-
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionDeleteQueueMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionDeleteQueueMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionDeleteQueueMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionDeleteQueueMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,102 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+import org.jboss.messaging.util.SimpleString;
+
+/**
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+
+ * @version <tt>$Revision$</tt>
+ */
+public class SessionDeleteQueueMessage extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   private SimpleString queueName;
+
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public SessionDeleteQueueMessage(final SimpleString queueName)
+   {
+      super(SESS_DELETE_QUEUE);
+
+      this.queueName = queueName;
+   }
+   
+   public SessionDeleteQueueMessage()
+   {
+      super(SESS_DELETE_QUEUE);
+   }
+
+   // Public --------------------------------------------------------
+
+   @Override
+   public String toString()
+   {
+      StringBuffer buff = new StringBuffer(getParentString());
+      buff.append(", queueName=" + queueName);
+      buff.append("]");
+      return buff.toString();
+   }
+   
+   public SimpleString getQueueName()
+   {
+      return queueName;
+   }
+      
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      buffer.putSimpleString(queueName);
+   }
+   
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      queueName = buffer.getSimpleString();
+   }
+
+   public boolean equals(Object other)
+   {
+      if (other instanceof SessionDeleteQueueMessage == false)
+      {
+         return false;
+      }
+            
+      SessionDeleteQueueMessage r = (SessionDeleteQueueMessage)other;
+      
+      return super.equals(other) && r.queueName.equals(this.queueName);
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionExpiredMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionExpiredMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionExpiredMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,93 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors by
- * the @authors tag. See the copyright.txt in the distribution for a full listing of individual contributors. This is
- * free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version.
- * This software is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
- * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
- * details. You should have received a copy of the GNU Lesser General Public License along with this software; if not,
- * write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA, or see the FSF
- * site: http://www.fsf.org.
- */
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-
-/**
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * @version <tt>$Revision$</tt>
- */
-public class SessionExpiredMessage extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-
-   private long consumerID;
-
-   private long messageID;
-
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public SessionExpiredMessage(final long consumerID, final long messageID)
-   {
-      super(SESS_EXPIRED);
-
-      this.consumerID = consumerID;
-
-      this.messageID = messageID;
-   }
-
-   public SessionExpiredMessage()
-   {
-      super(SESS_EXPIRED);
-   }
-
-   // Public --------------------------------------------------------
-
-   public long getConsumerID()
-   {
-      return consumerID;
-   }
-
-   public long getMessageID()
-   {
-      return messageID;
-   }
-
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      buffer.putLong(consumerID);
-
-      buffer.putLong(messageID);
-   }
-
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      consumerID = buffer.getLong();
-
-      messageID = buffer.getLong();
-   }
-
-   public boolean equals(Object other)
-   {
-      if (other instanceof SessionExpiredMessage == false)
-      {
-         return false;
-      }
-
-      SessionExpiredMessage r = (SessionExpiredMessage)other;
-
-      return super.equals(other) && this.consumerID == r.consumerID && this.messageID == r.messageID;
-   }
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionExpiredMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionExpiredMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionExpiredMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionExpiredMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,93 @@
+/*
+ * JBoss, Home of Professional Open Source Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors by
+ * the @authors tag. See the copyright.txt in the distribution for a full listing of individual contributors. This is
+ * free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version.
+ * This software is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
+ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
+ * details. You should have received a copy of the GNU Lesser General Public License along with this software; if not,
+ * write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA, or see the FSF
+ * site: http://www.fsf.org.
+ */
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+
+/**
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @version <tt>$Revision$</tt>
+ */
+public class SessionExpiredMessage extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   private long consumerID;
+
+   private long messageID;
+
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public SessionExpiredMessage(final long consumerID, final long messageID)
+   {
+      super(SESS_EXPIRED);
+
+      this.consumerID = consumerID;
+
+      this.messageID = messageID;
+   }
+
+   public SessionExpiredMessage()
+   {
+      super(SESS_EXPIRED);
+   }
+
+   // Public --------------------------------------------------------
+
+   public long getConsumerID()
+   {
+      return consumerID;
+   }
+
+   public long getMessageID()
+   {
+      return messageID;
+   }
+
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      buffer.putLong(consumerID);
+
+      buffer.putLong(messageID);
+   }
+
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      consumerID = buffer.getLong();
+
+      messageID = buffer.getLong();
+   }
+
+   public boolean equals(Object other)
+   {
+      if (other instanceof SessionExpiredMessage == false)
+      {
+         return false;
+      }
+
+      SessionExpiredMessage r = (SessionExpiredMessage)other;
+
+      return super.equals(other) && this.consumerID == r.consumerID && this.messageID == r.messageID;
+   }
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionFailoverCompleteMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionFailoverCompleteMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionFailoverCompleteMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,100 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-
-/**
- * 
- * A SessionFailoverCompleteMessage
- * 
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- *
- */
-public class SessionFailoverCompleteMessage extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-
-   private String name;
-   
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public SessionFailoverCompleteMessage(final String name)
-   {
-      super(SESS_FAILOVER_COMPLETE);
-
-      this.name = name;
-   }
-   
-   public SessionFailoverCompleteMessage()
-   {
-      super(SESS_FAILOVER_COMPLETE);
-   }
-
-   // Public --------------------------------------------------------
-
-   public String getName()
-   {
-      return name;
-   }
-   
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      buffer.putString(name);
-   }
-   
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      name = buffer.getString();
-   }
-   
-   public boolean isRequiresConfirmations()
-   {
-      return false;
-   }
-
-   public boolean equals(Object other)
-   {
-      if (other instanceof SessionFailoverCompleteMessage == false)
-      {
-         return false;
-      }
-            
-      SessionFailoverCompleteMessage r = (SessionFailoverCompleteMessage)other;
-      
-      return super.equals(other) && this.name.equals(r.name);
-   }
-   
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}
-

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionFailoverCompleteMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionFailoverCompleteMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionFailoverCompleteMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionFailoverCompleteMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,100 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+
+/**
+ * 
+ * A SessionFailoverCompleteMessage
+ * 
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ *
+ */
+public class SessionFailoverCompleteMessage extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   private String name;
+   
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public SessionFailoverCompleteMessage(final String name)
+   {
+      super(SESS_FAILOVER_COMPLETE);
+
+      this.name = name;
+   }
+   
+   public SessionFailoverCompleteMessage()
+   {
+      super(SESS_FAILOVER_COMPLETE);
+   }
+
+   // Public --------------------------------------------------------
+
+   public String getName()
+   {
+      return name;
+   }
+   
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      buffer.putString(name);
+   }
+   
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      name = buffer.getString();
+   }
+   
+   public boolean isRequiresConfirmations()
+   {
+      return false;
+   }
+
+   public boolean equals(Object other)
+   {
+      if (other instanceof SessionFailoverCompleteMessage == false)
+      {
+         return false;
+      }
+            
+      SessionFailoverCompleteMessage r = (SessionFailoverCompleteMessage)other;
+      
+      return super.equals(other) && this.name.equals(r.name);
+   }
+   
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}
+

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionQueueQueryMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionQueueQueryMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionQueueQueryMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,79 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-import org.jboss.messaging.util.SimpleString;
-
-
-/**
- * 
- * A SessionQueueQueryMessage
- * 
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- *
- */
-public class SessionQueueQueryMessage extends PacketImpl
-{
-   private SimpleString queueName;
-
-   public SessionQueueQueryMessage(final SimpleString queueName)
-   {
-      super(SESS_QUEUEQUERY);
-
-      this.queueName = queueName;            
-   }
-   
-   public SessionQueueQueryMessage()
-   {
-      super(SESS_QUEUEQUERY);        
-   }
-
-   public SimpleString getQueueName()
-   {
-      return queueName;
-   }
-   
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      buffer.putSimpleString(queueName);
-   }
-   
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      queueName = buffer.getSimpleString();
-   }
-   
-   public boolean equals(Object other)
-   {
-      if (other instanceof SessionQueueQueryMessage == false)
-      {
-         return false;
-      }
-            
-      SessionQueueQueryMessage r = (SessionQueueQueryMessage)other;
-      
-      return super.equals(other) && r.queueName.equals(this.queueName);
-   }
-   
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionQueueQueryMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionQueueQueryMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionQueueQueryMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionQueueQueryMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,79 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+import org.jboss.messaging.util.SimpleString;
+
+
+/**
+ * 
+ * A SessionQueueQueryMessage
+ * 
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ *
+ */
+public class SessionQueueQueryMessage extends PacketImpl
+{
+   private SimpleString queueName;
+
+   public SessionQueueQueryMessage(final SimpleString queueName)
+   {
+      super(SESS_QUEUEQUERY);
+
+      this.queueName = queueName;            
+   }
+   
+   public SessionQueueQueryMessage()
+   {
+      super(SESS_QUEUEQUERY);        
+   }
+
+   public SimpleString getQueueName()
+   {
+      return queueName;
+   }
+   
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      buffer.putSimpleString(queueName);
+   }
+   
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      queueName = buffer.getSimpleString();
+   }
+   
+   public boolean equals(Object other)
+   {
+      if (other instanceof SessionQueueQueryMessage == false)
+      {
+         return false;
+      }
+            
+      SessionQueueQueryMessage r = (SessionQueueQueryMessage)other;
+      
+      return super.equals(other) && r.queueName.equals(this.queueName);
+   }
+   
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionQueueQueryResponseMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionQueueQueryResponseMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionQueueQueryResponseMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,158 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-import org.jboss.messaging.util.SimpleString;
-
-/**
- * 
- * A SessionQueueQueryResponseMessage
- * 
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- *
- */
-public class SessionQueueQueryResponseMessage extends PacketImpl
-{
-   private boolean exists;
-
-   private boolean durable;
-
-   private int consumerCount;
-
-   private int messageCount;
-
-   private SimpleString filterString;
-
-   private SimpleString address;
-
-   public SessionQueueQueryResponseMessage(final boolean durable,
-                                           final int consumerCount,
-                                           final int messageCount,
-                                           final SimpleString filterString,
-                                           final SimpleString address)
-   {
-      this(durable, consumerCount, messageCount, filterString, address, true);
-   }
-
-   public SessionQueueQueryResponseMessage()
-   {
-      this(false, 0, 0, null, null, false);
-   }
-
-   private SessionQueueQueryResponseMessage(final boolean durable,
-                                            final int consumerCount,
-                                            final int messageCount,
-                                            final SimpleString filterString,
-                                            final SimpleString address,
-                                            final boolean exists)
-   {
-      super(SESS_QUEUEQUERY_RESP);
-
-      this.durable = durable;
-
-      this.consumerCount = consumerCount;
-
-      this.messageCount = messageCount;
-
-      this.filterString = filterString;
-
-      this.address = address;
-
-      this.exists = exists;
-   }
-
-   public boolean isResponse()
-   {
-      return true;
-   }
-
-   public boolean isExists()
-   {
-      return exists;
-   }
-
-   public boolean isDurable()
-   {
-      return durable;
-   }
-
-   public int getConsumerCount()
-   {
-      return consumerCount;
-   }
-
-   public int getMessageCount()
-   {
-      return messageCount;
-   }
-
-   public SimpleString getFilterString()
-   {
-      return filterString;
-   }
-
-   public SimpleString getAddress()
-   {
-      return address;
-   }
-
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      buffer.putBoolean(exists);
-      buffer.putBoolean(durable);
-      buffer.putInt(consumerCount);
-      buffer.putInt(messageCount);
-      buffer.putNullableSimpleString(filterString);
-      buffer.putNullableSimpleString(address);
-   }
-
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      exists = buffer.getBoolean();
-      durable = buffer.getBoolean();
-      consumerCount = buffer.getInt();
-      messageCount = buffer.getInt();
-      filterString = buffer.getNullableSimpleString();
-      address = buffer.getNullableSimpleString();
-   }
-
-   public boolean equals(Object other)
-   {
-      if (other instanceof SessionQueueQueryResponseMessage == false)
-      {
-         return false;
-      }
-
-      SessionQueueQueryResponseMessage r = (SessionQueueQueryResponseMessage)other;
-
-      return super.equals(other) && this.exists == r.exists &&
-             this.durable == r.durable &&
-             this.consumerCount == r.consumerCount &&
-             this.messageCount == r.messageCount &&
-             this.filterString == null ? r.filterString == null
-                                      : this.filterString.equals(r.filterString) && this.address == null ? r.address == null
-                                                                                                        : this.address.equals(r.address);
-   }
-
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionQueueQueryResponseMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionQueueQueryResponseMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionQueueQueryResponseMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionQueueQueryResponseMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,158 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+import org.jboss.messaging.util.SimpleString;
+
+/**
+ * 
+ * A SessionQueueQueryResponseMessage
+ * 
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ *
+ */
+public class SessionQueueQueryResponseMessage extends PacketImpl
+{
+   private boolean exists;
+
+   private boolean durable;
+
+   private int consumerCount;
+
+   private int messageCount;
+
+   private SimpleString filterString;
+
+   private SimpleString address;
+
+   public SessionQueueQueryResponseMessage(final boolean durable,
+                                           final int consumerCount,
+                                           final int messageCount,
+                                           final SimpleString filterString,
+                                           final SimpleString address)
+   {
+      this(durable, consumerCount, messageCount, filterString, address, true);
+   }
+
+   public SessionQueueQueryResponseMessage()
+   {
+      this(false, 0, 0, null, null, false);
+   }
+
+   private SessionQueueQueryResponseMessage(final boolean durable,
+                                            final int consumerCount,
+                                            final int messageCount,
+                                            final SimpleString filterString,
+                                            final SimpleString address,
+                                            final boolean exists)
+   {
+      super(SESS_QUEUEQUERY_RESP);
+
+      this.durable = durable;
+
+      this.consumerCount = consumerCount;
+
+      this.messageCount = messageCount;
+
+      this.filterString = filterString;
+
+      this.address = address;
+
+      this.exists = exists;
+   }
+
+   public boolean isResponse()
+   {
+      return true;
+   }
+
+   public boolean isExists()
+   {
+      return exists;
+   }
+
+   public boolean isDurable()
+   {
+      return durable;
+   }
+
+   public int getConsumerCount()
+   {
+      return consumerCount;
+   }
+
+   public int getMessageCount()
+   {
+      return messageCount;
+   }
+
+   public SimpleString getFilterString()
+   {
+      return filterString;
+   }
+
+   public SimpleString getAddress()
+   {
+      return address;
+   }
+
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      buffer.putBoolean(exists);
+      buffer.putBoolean(durable);
+      buffer.putInt(consumerCount);
+      buffer.putInt(messageCount);
+      buffer.putNullableSimpleString(filterString);
+      buffer.putNullableSimpleString(address);
+   }
+
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      exists = buffer.getBoolean();
+      durable = buffer.getBoolean();
+      consumerCount = buffer.getInt();
+      messageCount = buffer.getInt();
+      filterString = buffer.getNullableSimpleString();
+      address = buffer.getNullableSimpleString();
+   }
+
+   public boolean equals(Object other)
+   {
+      if (other instanceof SessionQueueQueryResponseMessage == false)
+      {
+         return false;
+      }
+
+      SessionQueueQueryResponseMessage r = (SessionQueueQueryResponseMessage)other;
+
+      return super.equals(other) && this.exists == r.exists &&
+             this.durable == r.durable &&
+             this.consumerCount == r.consumerCount &&
+             this.messageCount == r.messageCount &&
+             this.filterString == null ? r.filterString == null
+                                      : this.filterString.equals(r.filterString) && this.address == null ? r.address == null
+                                                                                                        : this.address.equals(r.address);
+   }
+
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionReceiveContinuationMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionReceiveContinuationMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionReceiveContinuationMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,113 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-import org.jboss.messaging.util.DataConstants;
-
-/**
- * A SessionSendContinuationMessage
- *
- * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
- * 
- * Created Dec 4, 2008 12:25:14 PM
- *
- *
- */
-public class SessionReceiveContinuationMessage extends SessionContinuationMessage
-{
-
-   // Constants -----------------------------------------------------
-
-   public static final int SESSION_RECEIVE_CONTINUATION_BASE_SIZE = SESSION_CONTINUATION_BASE_SIZE + DataConstants.SIZE_LONG;
-   
-   // Attributes ----------------------------------------------------
-
-   private long consumerID;
-
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   /**
-    * @param type
-    */
-   public SessionReceiveContinuationMessage()
-   {
-      super(SESS_RECEIVE_CONTINUATION);
-   }
-
-   /**
-    * @param type
-    * @param body
-    * @param continues
-    * @param requiresResponse
-    */
-   public SessionReceiveContinuationMessage(final long consumerID,
-                                            final byte[] body,
-                                            final boolean continues,
-                                            final boolean requiresResponse)
-   {
-      super(SESS_RECEIVE_CONTINUATION, body, continues);
-      this.consumerID = consumerID;
-   }
-
-   /**
-    * @return the consumerID
-    */
-   public long getConsumerID()
-   {
-      return consumerID;
-   }
-
-   // Public --------------------------------------------------------
-
-   @Override
-   public int getRequiredBufferSize()
-   {
-      return SESSION_RECEIVE_CONTINUATION_BASE_SIZE + body.length; 
-   }
-
-   @Override
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      super.encodeBody(buffer);
-      buffer.putLong(consumerID);
-   }
-
-   @Override
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      super.decodeBody(buffer);
-      consumerID = buffer.getLong();
-   }
-
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionReceiveContinuationMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionReceiveContinuationMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionReceiveContinuationMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionReceiveContinuationMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,113 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+import org.jboss.messaging.util.DataConstants;
+
+/**
+ * A SessionSendContinuationMessage
+ *
+ * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
+ * 
+ * Created Dec 4, 2008 12:25:14 PM
+ *
+ *
+ */
+public class SessionReceiveContinuationMessage extends SessionContinuationMessage
+{
+
+   // Constants -----------------------------------------------------
+
+   public static final int SESSION_RECEIVE_CONTINUATION_BASE_SIZE = SESSION_CONTINUATION_BASE_SIZE + DataConstants.SIZE_LONG;
+   
+   // Attributes ----------------------------------------------------
+
+   private long consumerID;
+
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   /**
+    * @param type
+    */
+   public SessionReceiveContinuationMessage()
+   {
+      super(SESS_RECEIVE_CONTINUATION);
+   }
+
+   /**
+    * @param type
+    * @param body
+    * @param continues
+    * @param requiresResponse
+    */
+   public SessionReceiveContinuationMessage(final long consumerID,
+                                            final byte[] body,
+                                            final boolean continues,
+                                            final boolean requiresResponse)
+   {
+      super(SESS_RECEIVE_CONTINUATION, body, continues);
+      this.consumerID = consumerID;
+   }
+
+   /**
+    * @return the consumerID
+    */
+   public long getConsumerID()
+   {
+      return consumerID;
+   }
+
+   // Public --------------------------------------------------------
+
+   @Override
+   public int getRequiredBufferSize()
+   {
+      return SESSION_RECEIVE_CONTINUATION_BASE_SIZE + body.length; 
+   }
+
+   @Override
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      super.encodeBody(buffer);
+      buffer.putLong(consumerID);
+   }
+
+   @Override
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      super.decodeBody(buffer);
+      consumerID = buffer.getLong();
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionReceiveMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionReceiveMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionReceiveMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,197 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import org.jboss.messaging.core.client.impl.ClientMessageImpl;
-import org.jboss.messaging.core.client.impl.ClientMessageInternal;
-import org.jboss.messaging.core.logging.Logger;
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-import org.jboss.messaging.core.server.ServerMessage;
-import org.jboss.messaging.util.DataConstants;
-
-/**
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * @author <a href="mailto:ovidiu at feodorov.com">Ovidiu Feodorov</a>
- * @author <a href="mailto:jmesnil at redhat.com">Jeff Mesnil</a>
- * 
- * @version <tt>$Revision$</tt>
- */
-public class SessionReceiveMessage extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   public static final int SESSION_RECEIVE_MESSAGE_LARGE_MESSAGE_SIZE = BASIC_PACKET_SIZE + DataConstants.SIZE_LONG +
-                                                                       DataConstants.SIZE_INT +
-                                                                       DataConstants.SIZE_BOOLEAN +
-                                                                       DataConstants.SIZE_INT;
-
-   private static final Logger log = Logger.getLogger(SessionReceiveMessage.class);
-
-   // Attributes ----------------------------------------------------
-
-   private long consumerID;
-
-   private boolean largeMessage;
-
-   private byte[] largeMessageHeader;
-
-   private ClientMessageInternal clientMessage;
-
-   private ServerMessage serverMessage;
-
-   private int deliveryCount;
-
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public SessionReceiveMessage(final long consumerID, final byte[] largeMessageHeader, final int deliveryCount)
-   {
-      super(SESS_RECEIVE_MSG);
-
-      this.consumerID = consumerID;
-
-      this.largeMessageHeader = largeMessageHeader;
-
-      this.deliveryCount = deliveryCount;
-
-      this.largeMessage = true;
-   }
-
-   public SessionReceiveMessage(final long consumerID, final ServerMessage message, final int deliveryCount)
-   {
-      super(SESS_RECEIVE_MSG);
-
-      this.consumerID = consumerID;
-
-      this.serverMessage = message;
-
-      this.clientMessage = null;
-
-      this.deliveryCount = deliveryCount;
-
-      this.largeMessage = false;
-   }
-
-   public SessionReceiveMessage()
-   {
-      super(SESS_RECEIVE_MSG);
-   }
-
-   // Public --------------------------------------------------------
-
-   public long getConsumerID()
-   {
-      return consumerID;
-   }
-
-   public ClientMessageInternal getClientMessage()
-   {
-      return clientMessage;
-   }
-
-   public ServerMessage getServerMessage()
-   {
-      return serverMessage;
-   }
-
-   public byte[] getLargeMessageHeader()
-   {
-      return largeMessageHeader;
-   }
-
-   /**
-    * @return the largeMessage
-    */
-   public boolean isLargeMessage()
-   {
-      return largeMessage;
-   }
-
-   public int getDeliveryCount()
-   {
-      return deliveryCount;
-   }
-
-   public int getRequiredBufferSize()
-   {
-      if (largeMessage)
-      {
-         return SESSION_RECEIVE_MESSAGE_LARGE_MESSAGE_SIZE + largeMessageHeader.length;
-      }
-      else
-      {
-         return BASIC_PACKET_SIZE + DataConstants.SIZE_LONG +
-                DataConstants.SIZE_INT +
-                DataConstants.SIZE_BOOLEAN +
-                serverMessage.getEncodeSize();
-      }
-   }
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      buffer.putLong(consumerID);
-      buffer.putInt(deliveryCount);
-      buffer.putBoolean(largeMessage);
-      if (largeMessage)
-      {
-         buffer.putInt(largeMessageHeader.length);
-         buffer.putBytes(largeMessageHeader);
-      }
-      else
-      {
-         serverMessage.encode(buffer);
-      }
-   }
-
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      // TODO can be optimised
-
-      consumerID = buffer.getLong();
-
-      deliveryCount = buffer.getInt();
-
-      largeMessage = buffer.getBoolean();
-
-      if (largeMessage)
-      {
-         int size = buffer.getInt();
-         largeMessageHeader = new byte[size];
-         buffer.getBytes(largeMessageHeader);
-      }
-      else
-      {
-         clientMessage = new ClientMessageImpl(deliveryCount);
-         clientMessage.decode(buffer);
-         clientMessage.getBody().flip();
-      }
-   }
-
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionReceiveMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionReceiveMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionReceiveMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionReceiveMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,197 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import org.jboss.messaging.core.client.impl.ClientMessageImpl;
+import org.jboss.messaging.core.client.impl.ClientMessageInternal;
+import org.jboss.messaging.core.logging.Logger;
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+import org.jboss.messaging.core.server.ServerMessage;
+import org.jboss.messaging.util.DataConstants;
+
+/**
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:ovidiu at feodorov.com">Ovidiu Feodorov</a>
+ * @author <a href="mailto:jmesnil at redhat.com">Jeff Mesnil</a>
+ * 
+ * @version <tt>$Revision$</tt>
+ */
+public class SessionReceiveMessage extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   public static final int SESSION_RECEIVE_MESSAGE_LARGE_MESSAGE_SIZE = BASIC_PACKET_SIZE + DataConstants.SIZE_LONG +
+                                                                       DataConstants.SIZE_INT +
+                                                                       DataConstants.SIZE_BOOLEAN +
+                                                                       DataConstants.SIZE_INT;
+
+   private static final Logger log = Logger.getLogger(SessionReceiveMessage.class);
+
+   // Attributes ----------------------------------------------------
+
+   private long consumerID;
+
+   private boolean largeMessage;
+
+   private byte[] largeMessageHeader;
+
+   private ClientMessageInternal clientMessage;
+
+   private ServerMessage serverMessage;
+
+   private int deliveryCount;
+
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public SessionReceiveMessage(final long consumerID, final byte[] largeMessageHeader, final int deliveryCount)
+   {
+      super(SESS_RECEIVE_MSG);
+
+      this.consumerID = consumerID;
+
+      this.largeMessageHeader = largeMessageHeader;
+
+      this.deliveryCount = deliveryCount;
+
+      this.largeMessage = true;
+   }
+
+   public SessionReceiveMessage(final long consumerID, final ServerMessage message, final int deliveryCount)
+   {
+      super(SESS_RECEIVE_MSG);
+
+      this.consumerID = consumerID;
+
+      this.serverMessage = message;
+
+      this.clientMessage = null;
+
+      this.deliveryCount = deliveryCount;
+
+      this.largeMessage = false;
+   }
+
+   public SessionReceiveMessage()
+   {
+      super(SESS_RECEIVE_MSG);
+   }
+
+   // Public --------------------------------------------------------
+
+   public long getConsumerID()
+   {
+      return consumerID;
+   }
+
+   public ClientMessageInternal getClientMessage()
+   {
+      return clientMessage;
+   }
+
+   public ServerMessage getServerMessage()
+   {
+      return serverMessage;
+   }
+
+   public byte[] getLargeMessageHeader()
+   {
+      return largeMessageHeader;
+   }
+
+   /**
+    * @return the largeMessage
+    */
+   public boolean isLargeMessage()
+   {
+      return largeMessage;
+   }
+
+   public int getDeliveryCount()
+   {
+      return deliveryCount;
+   }
+
+   public int getRequiredBufferSize()
+   {
+      if (largeMessage)
+      {
+         return SESSION_RECEIVE_MESSAGE_LARGE_MESSAGE_SIZE + largeMessageHeader.length;
+      }
+      else
+      {
+         return BASIC_PACKET_SIZE + DataConstants.SIZE_LONG +
+                DataConstants.SIZE_INT +
+                DataConstants.SIZE_BOOLEAN +
+                serverMessage.getEncodeSize();
+      }
+   }
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      buffer.putLong(consumerID);
+      buffer.putInt(deliveryCount);
+      buffer.putBoolean(largeMessage);
+      if (largeMessage)
+      {
+         buffer.putInt(largeMessageHeader.length);
+         buffer.putBytes(largeMessageHeader);
+      }
+      else
+      {
+         serverMessage.encode(buffer);
+      }
+   }
+
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      // TODO can be optimised
+
+      consumerID = buffer.getLong();
+
+      deliveryCount = buffer.getInt();
+
+      largeMessage = buffer.getBoolean();
+
+      if (largeMessage)
+      {
+         int size = buffer.getInt();
+         largeMessageHeader = new byte[size];
+         buffer.getBytes(largeMessageHeader);
+      }
+      else
+      {
+         clientMessage = new ClientMessageImpl(deliveryCount);
+         clientMessage.decode(buffer);
+         clientMessage.getBody().flip();
+      }
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionRemoveDestinationMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionRemoveDestinationMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionRemoveDestinationMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,116 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-import org.jboss.messaging.util.SimpleString;
-
-
-/**
- * 
- * A SessionRemoveDestinationMessage
- * 
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- *
- */
-public class SessionRemoveDestinationMessage extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-   
-   private SimpleString address;
-   
-   private boolean durable;
-   
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-   
-   public SessionRemoveDestinationMessage(final SimpleString address, final boolean durable)
-   {
-      super(SESS_REMOVE_DESTINATION);
-      
-      this.address = address;
-      
-      this.durable = durable;
-   }
-   
-   public SessionRemoveDestinationMessage()
-   {
-      super(SESS_REMOVE_DESTINATION);
-   }
-
-   // Public --------------------------------------------------------
-   
-   public SimpleString getAddress()
-   {
-      return address;
-   }
-   
-   public boolean isDurable()
-   {
-   	return durable;
-   }
-   
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      buffer.putSimpleString(address);
-      buffer.putBoolean(durable);
-   }
-   
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      address = buffer.getSimpleString();
-      durable = buffer.getBoolean();
-   }
-        
-   @Override
-   public String toString()
-   {
-      return getParentString() + ", address=" + address + ", temp=" + durable + "]";
-   }
-   
-   public boolean equals(Object other)
-   {
-      if (other instanceof SessionRemoveDestinationMessage == false)
-      {
-         return false;
-      }
-            
-      SessionRemoveDestinationMessage r = (SessionRemoveDestinationMessage)other;
-      
-      return super.equals(other) && this.address.equals(r.address) &&
-             this.durable == r.durable;
-   }
-   
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}
-
-

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionRemoveDestinationMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionRemoveDestinationMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionRemoveDestinationMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionRemoveDestinationMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,116 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+import org.jboss.messaging.util.SimpleString;
+
+
+/**
+ * 
+ * A SessionRemoveDestinationMessage
+ * 
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ *
+ */
+public class SessionRemoveDestinationMessage extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+   
+   private SimpleString address;
+   
+   private boolean durable;
+   
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+   
+   public SessionRemoveDestinationMessage(final SimpleString address, final boolean durable)
+   {
+      super(SESS_REMOVE_DESTINATION);
+      
+      this.address = address;
+      
+      this.durable = durable;
+   }
+   
+   public SessionRemoveDestinationMessage()
+   {
+      super(SESS_REMOVE_DESTINATION);
+   }
+
+   // Public --------------------------------------------------------
+   
+   public SimpleString getAddress()
+   {
+      return address;
+   }
+   
+   public boolean isDurable()
+   {
+   	return durable;
+   }
+   
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      buffer.putSimpleString(address);
+      buffer.putBoolean(durable);
+   }
+   
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      address = buffer.getSimpleString();
+      durable = buffer.getBoolean();
+   }
+        
+   @Override
+   public String toString()
+   {
+      return getParentString() + ", address=" + address + ", temp=" + durable + "]";
+   }
+   
+   public boolean equals(Object other)
+   {
+      if (other instanceof SessionRemoveDestinationMessage == false)
+      {
+         return false;
+      }
+            
+      SessionRemoveDestinationMessage r = (SessionRemoveDestinationMessage)other;
+      
+      return super.equals(other) && this.address.equals(r.address) &&
+             this.durable == r.durable;
+   }
+   
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}
+
+

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionReplicateDeliveryMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionReplicateDeliveryMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionReplicateDeliveryMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,99 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors by
- * the @authors tag. See the copyright.txt in the distribution for a full listing of individual contributors. This is
- * free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version.
- * This software is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
- * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
- * details. You should have received a copy of the GNU Lesser General Public License along with this software; if not,
- * write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA, or see the FSF
- * site: http://www.fsf.org.
- */
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-
-/**
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * @version <tt>$Revision$</tt>
- */
-public class SessionReplicateDeliveryMessage extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-
-   private long consumerID;
-
-   private long messageID;
-
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public SessionReplicateDeliveryMessage(final long consumerID, final long messageID)
-   {
-      super(SESS_REPLICATE_DELIVERY);
-
-      this.consumerID = consumerID;
-
-      this.messageID = messageID;
-   }
-
-   public SessionReplicateDeliveryMessage()
-   {
-      super(SESS_REPLICATE_DELIVERY);
-   }
-
-   // Public --------------------------------------------------------
-
-   public long getConsumerID()
-   {
-      return consumerID;
-   }
-
-   public long getMessageID()
-   {
-      return messageID;
-   }
-
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      buffer.putLong(consumerID);
-
-      buffer.putLong(messageID);
-   }
-
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      consumerID = buffer.getLong();
-
-      messageID = buffer.getLong();
-   }
-   
-   public boolean isRequiresConfirmations()
-   {      
-      return false;
-   }
-
-   public boolean equals(Object other)
-   {
-      if (other instanceof SessionReplicateDeliveryMessage == false)
-      {
-         return false;
-      }
-
-      SessionReplicateDeliveryMessage r = (SessionReplicateDeliveryMessage)other;
-
-      return super.equals(other) && this.consumerID == r.consumerID && this.messageID == r.messageID;
-   }
-   
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionReplicateDeliveryMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionReplicateDeliveryMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionReplicateDeliveryMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionReplicateDeliveryMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,99 @@
+/*
+ * JBoss, Home of Professional Open Source Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors by
+ * the @authors tag. See the copyright.txt in the distribution for a full listing of individual contributors. This is
+ * free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version.
+ * This software is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
+ * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
+ * details. You should have received a copy of the GNU Lesser General Public License along with this software; if not,
+ * write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA, or see the FSF
+ * site: http://www.fsf.org.
+ */
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+
+/**
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @version <tt>$Revision$</tt>
+ */
+public class SessionReplicateDeliveryMessage extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   private long consumerID;
+
+   private long messageID;
+
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public SessionReplicateDeliveryMessage(final long consumerID, final long messageID)
+   {
+      super(SESS_REPLICATE_DELIVERY);
+
+      this.consumerID = consumerID;
+
+      this.messageID = messageID;
+   }
+
+   public SessionReplicateDeliveryMessage()
+   {
+      super(SESS_REPLICATE_DELIVERY);
+   }
+
+   // Public --------------------------------------------------------
+
+   public long getConsumerID()
+   {
+      return consumerID;
+   }
+
+   public long getMessageID()
+   {
+      return messageID;
+   }
+
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      buffer.putLong(consumerID);
+
+      buffer.putLong(messageID);
+   }
+
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      consumerID = buffer.getLong();
+
+      messageID = buffer.getLong();
+   }
+   
+   public boolean isRequiresConfirmations()
+   {      
+      return false;
+   }
+
+   public boolean equals(Object other)
+   {
+      if (other instanceof SessionReplicateDeliveryMessage == false)
+      {
+         return false;
+      }
+
+      SessionReplicateDeliveryMessage r = (SessionReplicateDeliveryMessage)other;
+
+      return super.equals(other) && this.consumerID == r.consumerID && this.messageID == r.messageID;
+   }
+   
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionSendContinuationMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionSendContinuationMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionSendContinuationMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,113 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-import org.jboss.messaging.util.DataConstants;
-
-
-/**
- * A SessionSendContinuationMessage
- *
- * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
- * 
- * Created Dec 4, 2008 12:25:14 PM
- *
- *
- */
-public class SessionSendContinuationMessage extends SessionContinuationMessage
-{
-
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-
-   private boolean requiresResponse;
-
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   /**
-    * @param type
-    */
-   public SessionSendContinuationMessage()
-   {
-      super(SESS_SEND_CONTINUATION);
-   }
-
-   /**
-    * @param type
-    * @param body
-    * @param continues
-    * @param requiresResponse
-    */
-   public SessionSendContinuationMessage(final byte[] body,
-                                         final boolean continues,
-                                         final boolean requiresResponse)
-   {
-      super(SESS_SEND_CONTINUATION, body, continues);
-      this.requiresResponse = requiresResponse;
-   }
-
-
-   // Public --------------------------------------------------------
-   
-   /**
-    * @return the requiresResponse
-    */
-   public boolean isRequiresResponse()
-   {
-      return requiresResponse;
-   }
-
-   @Override
-   public int getRequiredBufferSize()
-   {
-      return super.getRequiredBufferSize() + DataConstants.SIZE_BOOLEAN;
-   }
-
-   @Override
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      super.encodeBody(buffer);
-      buffer.putBoolean(requiresResponse);
-   }
-
-   @Override
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      super.decodeBody(buffer);
-      requiresResponse = buffer.getBoolean();
-   }
-
-
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionSendContinuationMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionSendContinuationMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionSendContinuationMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionSendContinuationMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,113 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+import org.jboss.messaging.util.DataConstants;
+
+
+/**
+ * A SessionSendContinuationMessage
+ *
+ * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
+ * 
+ * Created Dec 4, 2008 12:25:14 PM
+ *
+ *
+ */
+public class SessionSendContinuationMessage extends SessionContinuationMessage
+{
+
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   private boolean requiresResponse;
+
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   /**
+    * @param type
+    */
+   public SessionSendContinuationMessage()
+   {
+      super(SESS_SEND_CONTINUATION);
+   }
+
+   /**
+    * @param type
+    * @param body
+    * @param continues
+    * @param requiresResponse
+    */
+   public SessionSendContinuationMessage(final byte[] body,
+                                         final boolean continues,
+                                         final boolean requiresResponse)
+   {
+      super(SESS_SEND_CONTINUATION, body, continues);
+      this.requiresResponse = requiresResponse;
+   }
+
+
+   // Public --------------------------------------------------------
+   
+   /**
+    * @return the requiresResponse
+    */
+   public boolean isRequiresResponse()
+   {
+      return requiresResponse;
+   }
+
+   @Override
+   public int getRequiredBufferSize()
+   {
+      return super.getRequiredBufferSize() + DataConstants.SIZE_BOOLEAN;
+   }
+
+   @Override
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      super.encodeBody(buffer);
+      buffer.putBoolean(requiresResponse);
+   }
+
+   @Override
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      super.decodeBody(buffer);
+      requiresResponse = buffer.getBoolean();
+   }
+
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionSendMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionSendMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionSendMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,251 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import org.jboss.messaging.core.message.Message;
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-import org.jboss.messaging.core.server.ServerMessage;
-import org.jboss.messaging.core.server.impl.ServerMessageImpl;
-import org.jboss.messaging.util.DataConstants;
-
-/**
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * @author <a href="mailto:jmesnil at redhat.com">Jeff Mesnil</a>
- * @author <a href="mailto:csuconic at redhat.com">Clebert Suconic</a>
- * 
- * @version <tt>$Revision$</tt>
- */
-public class SessionSendMessage extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-
-   private Message clientMessage;
-
-   private boolean largeMessage;
-
-   /** Used only if largeMessage */
-   private byte[] largeMessageHeader;
-   
-   /** We need to set the MessageID when replicating this on the server */
-   private long largeMessageId = -1;
-
-   private ServerMessage serverMessage;
-
-   private boolean requiresResponse;
-
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public SessionSendMessage(final Message message, final boolean requiresResponse)
-   {
-      super(SESS_SEND);
-
-      clientMessage = message;
-
-      this.requiresResponse = requiresResponse;
-
-      largeMessage = false;
-   }
-
-   public SessionSendMessage(final byte[] largeMessageHeader, final boolean requiresResponse)
-   {
-      super(SESS_SEND);
-
-      this.largeMessageHeader = largeMessageHeader;
-
-      this.requiresResponse = requiresResponse;
-
-      largeMessage = true;
-   }
-
-   public SessionSendMessage()
-   {
-      super(SESS_SEND);
-   }
-
-   // Public --------------------------------------------------------
-
-   
-   public boolean isLargeMessage()
-   {
-      return largeMessage;
-   }
-   
-   public Message getClientMessage()
-   {
-      return clientMessage;
-   }
-
-   public ServerMessage getServerMessage()
-   {
-      return serverMessage;
-   }
-
-   public byte[] getLargeMessageHeader()
-   {
-      return largeMessageHeader;
-   }
-
-   public boolean isRequiresResponse()
-   {
-      return requiresResponse;
-   }
-   
-   /**
-    * @return the largeMessageId
-    */
-   public long getMessageID()
-   {
-      if (largeMessage)
-      {
-         return largeMessageId;
-      }
-      else
-      {
-         return serverMessage.getMessageID();
-      }
-   }
-
-   /**
-    * @param largeMessageId the largeMessageId to set
-    */
-   public void setMessageID(long id)
-   {
-      if (largeMessage)
-      {
-         this.largeMessageId = id;
-      }
-      else
-      {
-         serverMessage.setMessageID(id);
-      }
-   }
-
-   @Override
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      buffer.putBoolean(largeMessage);
-
-      if (largeMessage)
-      {
-         buffer.putInt(largeMessageHeader.length);
-         buffer.putBytes(largeMessageHeader);
-         
-         if (largeMessageId > 0)
-         {
-            buffer.putBoolean(true);
-            buffer.putLong(largeMessageId);
-         }
-         else
-         {
-            buffer.putBoolean(false);
-         }
-      }
-      else if (clientMessage != null)
-      {
-         clientMessage.encode(buffer);
-      }
-      else
-      {
-         // If we're replicating a buffer to a backup node then we encode the serverMessage not the clientMessage
-         serverMessage.encode(buffer);
-      }
-
-      buffer.putBoolean(requiresResponse);
-   }
-
-   @Override
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      largeMessage = buffer.getBoolean();
-
-      if (largeMessage)
-      {
-         int largeMessageLength = buffer.getInt();
-
-         largeMessageHeader = new byte[largeMessageLength];
-
-         buffer.getBytes(largeMessageHeader);
-         
-         final boolean largeMessageIDFilled = buffer.getBoolean();
-         
-         if (largeMessageIDFilled)
-         {
-            this.largeMessageId = buffer.getLong();
-         }
-         else
-         {
-            this.largeMessageId = -1;
-         }
-      }
-      else
-      {
-         // TODO can be optimised
-
-         serverMessage = new ServerMessageImpl();
-         
-         clientMessage = serverMessage;
-
-         serverMessage.decode(buffer);
-
-         serverMessage.getBody().flip();
-
-         requiresResponse = buffer.getBoolean();
-      }
-   }
-
-   @Override
-   public int getRequiredBufferSize()
-   {
-      if (largeMessage)
-      {
-         return BASIC_PACKET_SIZE +
-                // IsLargeMessage
-                DataConstants.SIZE_BOOLEAN +
-                // BufferSize
-                DataConstants.SIZE_INT +
-                // Bytes sent
-                largeMessageHeader.length +
-                // LargeMessageID (if > 0) and a boolean statying if the largeMessageID is set
-                DataConstants.SIZE_BOOLEAN + (largeMessageId >= 0 ? DataConstants.SIZE_LONG : 0) + 
-                DataConstants.SIZE_BOOLEAN;
-      }
-      else
-      {
-         return DataConstants.SIZE_BOOLEAN + BASIC_PACKET_SIZE +
-                clientMessage.getEncodeSize() +
-                DataConstants.SIZE_BOOLEAN;
-      }
-   }
-
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionSendMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionSendMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionSendMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionSendMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,251 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import org.jboss.messaging.core.message.Message;
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+import org.jboss.messaging.core.server.ServerMessage;
+import org.jboss.messaging.core.server.impl.ServerMessageImpl;
+import org.jboss.messaging.util.DataConstants;
+
+/**
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:jmesnil at redhat.com">Jeff Mesnil</a>
+ * @author <a href="mailto:csuconic at redhat.com">Clebert Suconic</a>
+ * 
+ * @version <tt>$Revision$</tt>
+ */
+public class SessionSendMessage extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   private Message clientMessage;
+
+   private boolean largeMessage;
+
+   /** Used only if largeMessage */
+   private byte[] largeMessageHeader;
+   
+   /** We need to set the MessageID when replicating this on the server */
+   private long largeMessageId = -1;
+
+   private ServerMessage serverMessage;
+
+   private boolean requiresResponse;
+
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public SessionSendMessage(final Message message, final boolean requiresResponse)
+   {
+      super(SESS_SEND);
+
+      clientMessage = message;
+
+      this.requiresResponse = requiresResponse;
+
+      largeMessage = false;
+   }
+
+   public SessionSendMessage(final byte[] largeMessageHeader, final boolean requiresResponse)
+   {
+      super(SESS_SEND);
+
+      this.largeMessageHeader = largeMessageHeader;
+
+      this.requiresResponse = requiresResponse;
+
+      largeMessage = true;
+   }
+
+   public SessionSendMessage()
+   {
+      super(SESS_SEND);
+   }
+
+   // Public --------------------------------------------------------
+
+   
+   public boolean isLargeMessage()
+   {
+      return largeMessage;
+   }
+   
+   public Message getClientMessage()
+   {
+      return clientMessage;
+   }
+
+   public ServerMessage getServerMessage()
+   {
+      return serverMessage;
+   }
+
+   public byte[] getLargeMessageHeader()
+   {
+      return largeMessageHeader;
+   }
+
+   public boolean isRequiresResponse()
+   {
+      return requiresResponse;
+   }
+   
+   /**
+    * @return the largeMessageId
+    */
+   public long getMessageID()
+   {
+      if (largeMessage)
+      {
+         return largeMessageId;
+      }
+      else
+      {
+         return serverMessage.getMessageID();
+      }
+   }
+
+   /**
+    * @param largeMessageId the largeMessageId to set
+    */
+   public void setMessageID(long id)
+   {
+      if (largeMessage)
+      {
+         this.largeMessageId = id;
+      }
+      else
+      {
+         serverMessage.setMessageID(id);
+      }
+   }
+
+   @Override
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      buffer.putBoolean(largeMessage);
+
+      if (largeMessage)
+      {
+         buffer.putInt(largeMessageHeader.length);
+         buffer.putBytes(largeMessageHeader);
+         
+         if (largeMessageId > 0)
+         {
+            buffer.putBoolean(true);
+            buffer.putLong(largeMessageId);
+         }
+         else
+         {
+            buffer.putBoolean(false);
+         }
+      }
+      else if (clientMessage != null)
+      {
+         clientMessage.encode(buffer);
+      }
+      else
+      {
+         // If we're replicating a buffer to a backup node then we encode the serverMessage not the clientMessage
+         serverMessage.encode(buffer);
+      }
+
+      buffer.putBoolean(requiresResponse);
+   }
+
+   @Override
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      largeMessage = buffer.getBoolean();
+
+      if (largeMessage)
+      {
+         int largeMessageLength = buffer.getInt();
+
+         largeMessageHeader = new byte[largeMessageLength];
+
+         buffer.getBytes(largeMessageHeader);
+         
+         final boolean largeMessageIDFilled = buffer.getBoolean();
+         
+         if (largeMessageIDFilled)
+         {
+            this.largeMessageId = buffer.getLong();
+         }
+         else
+         {
+            this.largeMessageId = -1;
+         }
+      }
+      else
+      {
+         // TODO can be optimised
+
+         serverMessage = new ServerMessageImpl();
+         
+         clientMessage = serverMessage;
+
+         serverMessage.decode(buffer);
+
+         serverMessage.getBody().flip();
+
+         requiresResponse = buffer.getBoolean();
+      }
+   }
+
+   @Override
+   public int getRequiredBufferSize()
+   {
+      if (largeMessage)
+      {
+         return BASIC_PACKET_SIZE +
+                // IsLargeMessage
+                DataConstants.SIZE_BOOLEAN +
+                // BufferSize
+                DataConstants.SIZE_INT +
+                // Bytes sent
+                largeMessageHeader.length +
+                // LargeMessageID (if > 0) and a boolean statying if the largeMessageID is set
+                DataConstants.SIZE_BOOLEAN + (largeMessageId >= 0 ? DataConstants.SIZE_LONG : 0) + 
+                DataConstants.SIZE_BOOLEAN;
+      }
+      else
+      {
+         return DataConstants.SIZE_BOOLEAN + BASIC_PACKET_SIZE +
+                clientMessage.getEncodeSize() +
+                DataConstants.SIZE_BOOLEAN;
+      }
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXACommitMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXACommitMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXACommitMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,113 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import javax.transaction.xa.Xid;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-
-
-/**
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * 
- * @version <tt>$Revision$</tt>
- */
-public class SessionXACommitMessage extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-   
-   private boolean onePhase;
-   
-   private Xid xid;
-   
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public SessionXACommitMessage(final Xid xid, final boolean onePhase)
-   {
-      super(SESS_XA_COMMIT);
-      
-      this.xid = xid;
-      this.onePhase = onePhase;
-   }
-   
-   public SessionXACommitMessage()
-   {
-      super(SESS_XA_COMMIT);
-   }
-
-   // Public --------------------------------------------------------
- 
-   public Xid getXid()
-   {
-      return xid;
-   }
-   
-   public boolean isOnePhase()
-   {
-      return onePhase;
-   }
-   
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      XidCodecSupport.encodeXid(xid, buffer);
-      buffer.putBoolean(onePhase);
-   }
-   
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      xid = XidCodecSupport.decodeXid(buffer);
-      onePhase = buffer.getBoolean();
-   }
-
-   @Override
-   public String toString()
-   {
-      return getParentString() + ", xid=" + xid + ", onePhase=" + onePhase + "]";
-   }
-   
-   public boolean equals(Object other)
-   {
-      if (other instanceof SessionXACommitMessage == false)
-      {
-         return false;
-      }
-            
-      SessionXACommitMessage r = (SessionXACommitMessage)other;
-      
-      return super.equals(other) && this.xid.equals(r.xid) &&
-             this.onePhase == r.onePhase;
-   }
-   
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}
-

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXACommitMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXACommitMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXACommitMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXACommitMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,113 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import javax.transaction.xa.Xid;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+
+
+/**
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * 
+ * @version <tt>$Revision$</tt>
+ */
+public class SessionXACommitMessage extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+   
+   private boolean onePhase;
+   
+   private Xid xid;
+   
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public SessionXACommitMessage(final Xid xid, final boolean onePhase)
+   {
+      super(SESS_XA_COMMIT);
+      
+      this.xid = xid;
+      this.onePhase = onePhase;
+   }
+   
+   public SessionXACommitMessage()
+   {
+      super(SESS_XA_COMMIT);
+   }
+
+   // Public --------------------------------------------------------
+ 
+   public Xid getXid()
+   {
+      return xid;
+   }
+   
+   public boolean isOnePhase()
+   {
+      return onePhase;
+   }
+   
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      XidCodecSupport.encodeXid(xid, buffer);
+      buffer.putBoolean(onePhase);
+   }
+   
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      xid = XidCodecSupport.decodeXid(buffer);
+      onePhase = buffer.getBoolean();
+   }
+
+   @Override
+   public String toString()
+   {
+      return getParentString() + ", xid=" + xid + ", onePhase=" + onePhase + "]";
+   }
+   
+   public boolean equals(Object other)
+   {
+      if (other instanceof SessionXACommitMessage == false)
+      {
+         return false;
+      }
+            
+      SessionXACommitMessage r = (SessionXACommitMessage)other;
+      
+      return super.equals(other) && this.xid.equals(r.xid) &&
+             this.onePhase == r.onePhase;
+   }
+   
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}
+

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAEndMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAEndMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAEndMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,114 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import javax.transaction.xa.Xid;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-
-
-/**
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * 
- * @version <tt>$Revision$</tt>
- */
-public class SessionXAEndMessage extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-   
-   private Xid xid;
-   
-   private boolean failed;
-   
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public SessionXAEndMessage(final Xid xid, final boolean failed)
-   {
-      super(SESS_XA_END);
-      
-      this.xid = xid;
-      
-      this.failed = failed;
-   }
-   
-   public SessionXAEndMessage()
-   {
-      super(SESS_XA_END);
-   }
-
-   // Public --------------------------------------------------------
-   
-   public boolean isFailed()
-   {
-      return failed;
-   }
-   
-   public Xid getXid()
-   {
-      return xid;
-   }
-   
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      XidCodecSupport.encodeXid(xid, buffer);
-      buffer.putBoolean(failed);
-   }
-   
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      xid = XidCodecSupport.decodeXid(buffer);
-      failed = buffer.getBoolean();
-   }
-
-   @Override
-   public String toString()
-   {
-      return getParentString() + ", xid=" + xid + ", failed=" + failed + "]";
-   }
-   
-   public boolean equals(Object other)
-   {
-      if (other instanceof SessionXAEndMessage == false)
-      {
-         return false;
-      }
-            
-      SessionXAEndMessage r = (SessionXAEndMessage)other;
-      
-      return super.equals(other) && this.xid.equals(r.xid) &&
-             this.failed == r.failed;
-   }
-
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}
-

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAEndMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAEndMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAEndMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAEndMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,114 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import javax.transaction.xa.Xid;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+
+
+/**
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * 
+ * @version <tt>$Revision$</tt>
+ */
+public class SessionXAEndMessage extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+   
+   private Xid xid;
+   
+   private boolean failed;
+   
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public SessionXAEndMessage(final Xid xid, final boolean failed)
+   {
+      super(SESS_XA_END);
+      
+      this.xid = xid;
+      
+      this.failed = failed;
+   }
+   
+   public SessionXAEndMessage()
+   {
+      super(SESS_XA_END);
+   }
+
+   // Public --------------------------------------------------------
+   
+   public boolean isFailed()
+   {
+      return failed;
+   }
+   
+   public Xid getXid()
+   {
+      return xid;
+   }
+   
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      XidCodecSupport.encodeXid(xid, buffer);
+      buffer.putBoolean(failed);
+   }
+   
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      xid = XidCodecSupport.decodeXid(buffer);
+      failed = buffer.getBoolean();
+   }
+
+   @Override
+   public String toString()
+   {
+      return getParentString() + ", xid=" + xid + ", failed=" + failed + "]";
+   }
+   
+   public boolean equals(Object other)
+   {
+      if (other instanceof SessionXAEndMessage == false)
+      {
+         return false;
+      }
+            
+      SessionXAEndMessage r = (SessionXAEndMessage)other;
+      
+      return super.equals(other) && this.xid.equals(r.xid) &&
+             this.failed == r.failed;
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}
+

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAForgetMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAForgetMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAForgetMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,97 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import javax.transaction.xa.Xid;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-
-
-/**
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * 
- * @version <tt>$Revision$</tt>
- */
-public class SessionXAForgetMessage extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-   
-   private Xid xid;
-      
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public SessionXAForgetMessage(final Xid xid)
-   {
-      super(SESS_XA_FORGET);
-      
-      this.xid = xid;
-   }
-   
-   public SessionXAForgetMessage()
-   {
-      super(SESS_XA_FORGET);
-   }
-
-   // Public --------------------------------------------------------
-   
-   public Xid getXid()
-   {
-      return xid;
-   }
-   
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      XidCodecSupport.encodeXid(xid, buffer);
-   }
-   
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      xid = XidCodecSupport.decodeXid(buffer);
-   }
-   
-   public boolean equals(Object other)
-   {
-      if (other instanceof SessionXAForgetMessage == false)
-      {
-         return false;
-      }
-            
-      SessionXAForgetMessage r = (SessionXAForgetMessage)other;
-      
-      return super.equals(other) && this.xid.equals(r.xid);
-   }
-   
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}
-
-

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAForgetMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAForgetMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAForgetMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAForgetMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,97 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import javax.transaction.xa.Xid;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+
+
+/**
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * 
+ * @version <tt>$Revision$</tt>
+ */
+public class SessionXAForgetMessage extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+   
+   private Xid xid;
+      
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public SessionXAForgetMessage(final Xid xid)
+   {
+      super(SESS_XA_FORGET);
+      
+      this.xid = xid;
+   }
+   
+   public SessionXAForgetMessage()
+   {
+      super(SESS_XA_FORGET);
+   }
+
+   // Public --------------------------------------------------------
+   
+   public Xid getXid()
+   {
+      return xid;
+   }
+   
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      XidCodecSupport.encodeXid(xid, buffer);
+   }
+   
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      xid = XidCodecSupport.decodeXid(buffer);
+   }
+   
+   public boolean equals(Object other)
+   {
+      if (other instanceof SessionXAForgetMessage == false)
+      {
+         return false;
+      }
+            
+      SessionXAForgetMessage r = (SessionXAForgetMessage)other;
+      
+      return super.equals(other) && this.xid.equals(r.xid);
+   }
+   
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}
+
+

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAGetInDoubtXidsResponseMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAGetInDoubtXidsResponseMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAGetInDoubtXidsResponseMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,134 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import javax.transaction.xa.Xid;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-
-
-/**
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * 
- * @version <tt>$Revision$</tt>
- */
-public class SessionXAGetInDoubtXidsResponseMessage extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-   
-   private List<Xid> xids;
-   
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public SessionXAGetInDoubtXidsResponseMessage(final List<Xid> xids)
-   {
-      super(SESS_XA_INDOUBT_XIDS_RESP);
-      
-      this.xids = xids;
-   }
-   
-   public SessionXAGetInDoubtXidsResponseMessage()
-   {
-      super(SESS_XA_INDOUBT_XIDS_RESP);
-   }
-
-   // Public --------------------------------------------------------
-  
-   public boolean isResponse()
-   {
-      return true;
-   }
-   
-   public List<Xid> getXids()
-   {
-      return xids;
-   }
-
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      buffer.putInt(xids.size());
-
-      for (Xid xid: xids)
-      {
-         XidCodecSupport.encodeXid(xid, buffer);
-      }    
-   }
-   
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      int len = buffer.getInt();
-      xids = new ArrayList<Xid>(len);      
-      for (int i = 0; i < len; i++)
-      {
-         Xid xid = XidCodecSupport.decodeXid(buffer);
-         
-         xids.add(xid);
-      }      
-   }
-   
-   public boolean equals(Object other)
-   {
-      if (other instanceof SessionXAGetInDoubtXidsResponseMessage == false)
-      {
-         return false;
-      }
-            
-      SessionXAGetInDoubtXidsResponseMessage r = (SessionXAGetInDoubtXidsResponseMessage)other;
-      
-      if (super.equals(other))
-      {
-         if (this.xids.size() == r.xids.size())
-         {
-            for (int i = 0; i < xids.size(); i++)
-            {
-               if (!xids.get(i).equals(r.xids.get(i)))
-               {
-                  return false;
-               }
-            }
-         }
-      }
-      else
-      {
-         return false;
-      }
-      return true;
-   }
-   
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}
-
-

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAGetInDoubtXidsResponseMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAGetInDoubtXidsResponseMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAGetInDoubtXidsResponseMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAGetInDoubtXidsResponseMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,134 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import javax.transaction.xa.Xid;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+
+
+/**
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * 
+ * @version <tt>$Revision$</tt>
+ */
+public class SessionXAGetInDoubtXidsResponseMessage extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+   
+   private List<Xid> xids;
+   
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public SessionXAGetInDoubtXidsResponseMessage(final List<Xid> xids)
+   {
+      super(SESS_XA_INDOUBT_XIDS_RESP);
+      
+      this.xids = xids;
+   }
+   
+   public SessionXAGetInDoubtXidsResponseMessage()
+   {
+      super(SESS_XA_INDOUBT_XIDS_RESP);
+   }
+
+   // Public --------------------------------------------------------
+  
+   public boolean isResponse()
+   {
+      return true;
+   }
+   
+   public List<Xid> getXids()
+   {
+      return xids;
+   }
+
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      buffer.putInt(xids.size());
+
+      for (Xid xid: xids)
+      {
+         XidCodecSupport.encodeXid(xid, buffer);
+      }    
+   }
+   
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      int len = buffer.getInt();
+      xids = new ArrayList<Xid>(len);      
+      for (int i = 0; i < len; i++)
+      {
+         Xid xid = XidCodecSupport.decodeXid(buffer);
+         
+         xids.add(xid);
+      }      
+   }
+   
+   public boolean equals(Object other)
+   {
+      if (other instanceof SessionXAGetInDoubtXidsResponseMessage == false)
+      {
+         return false;
+      }
+            
+      SessionXAGetInDoubtXidsResponseMessage r = (SessionXAGetInDoubtXidsResponseMessage)other;
+      
+      if (super.equals(other))
+      {
+         if (this.xids.size() == r.xids.size())
+         {
+            for (int i = 0; i < xids.size(); i++)
+            {
+               if (!xids.get(i).equals(r.xids.get(i)))
+               {
+                  return false;
+               }
+            }
+         }
+      }
+      else
+      {
+         return false;
+      }
+      return true;
+   }
+   
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}
+
+

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAGetTimeoutResponseMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAGetTimeoutResponseMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAGetTimeoutResponseMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,100 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-
-
-
-/**
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * 
- * @version <tt>$Revision$</tt>
- */
-public class SessionXAGetTimeoutResponseMessage extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-   
-   private int timeoutSeconds;
-   
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public SessionXAGetTimeoutResponseMessage(final int timeoutSeconds)
-   {
-      super(SESS_XA_GET_TIMEOUT_RESP);
-      
-      this.timeoutSeconds = timeoutSeconds;
-   }
-   
-   public SessionXAGetTimeoutResponseMessage()
-   {
-      super(SESS_XA_GET_TIMEOUT_RESP);
-   }
-   
-   // Public --------------------------------------------------------
-   
-   public boolean isResponse()
-   {
-      return true;
-   }
-   
-   public int getTimeoutSeconds()
-   {
-      return this.timeoutSeconds;
-   }
-   
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      buffer.putInt(timeoutSeconds);  
-   }
-   
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      timeoutSeconds = buffer.getInt(); 
-   }
-   
-   public boolean equals(Object other)
-   {
-      if (other instanceof SessionXAGetTimeoutResponseMessage == false)
-      {
-         return false;
-      }
-            
-      SessionXAGetTimeoutResponseMessage r = (SessionXAGetTimeoutResponseMessage)other;
-      
-      return super.equals(other) && this.timeoutSeconds == r.timeoutSeconds;     
-   }
-
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}
-

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAGetTimeoutResponseMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAGetTimeoutResponseMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAGetTimeoutResponseMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAGetTimeoutResponseMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,100 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+
+
+
+/**
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * 
+ * @version <tt>$Revision$</tt>
+ */
+public class SessionXAGetTimeoutResponseMessage extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+   
+   private int timeoutSeconds;
+   
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public SessionXAGetTimeoutResponseMessage(final int timeoutSeconds)
+   {
+      super(SESS_XA_GET_TIMEOUT_RESP);
+      
+      this.timeoutSeconds = timeoutSeconds;
+   }
+   
+   public SessionXAGetTimeoutResponseMessage()
+   {
+      super(SESS_XA_GET_TIMEOUT_RESP);
+   }
+   
+   // Public --------------------------------------------------------
+   
+   public boolean isResponse()
+   {
+      return true;
+   }
+   
+   public int getTimeoutSeconds()
+   {
+      return this.timeoutSeconds;
+   }
+   
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      buffer.putInt(timeoutSeconds);  
+   }
+   
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      timeoutSeconds = buffer.getInt(); 
+   }
+   
+   public boolean equals(Object other)
+   {
+      if (other instanceof SessionXAGetTimeoutResponseMessage == false)
+      {
+         return false;
+      }
+            
+      SessionXAGetTimeoutResponseMessage r = (SessionXAGetTimeoutResponseMessage)other;
+      
+      return super.equals(other) && this.timeoutSeconds == r.timeoutSeconds;     
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}
+

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAJoinMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAJoinMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAJoinMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,96 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import javax.transaction.xa.Xid;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-
-
-/**
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * 
- * @version <tt>$Revision$</tt>
- */
-public class SessionXAJoinMessage extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-   
-   private Xid xid;
-   
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public SessionXAJoinMessage(final Xid xid)
-   {
-      super(SESS_XA_JOIN);
-      
-      this.xid = xid;
-   }
-   
-   public SessionXAJoinMessage()
-   {
-      super(SESS_XA_JOIN);
-   }
-
-   // Public --------------------------------------------------------
-   
-   public Xid getXid()
-   {
-      return xid;
-   }
-   
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      XidCodecSupport.encodeXid(xid, buffer);
-   }
-   
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      xid = XidCodecSupport.decodeXid(buffer);
-   }
-   
-   public boolean equals(Object other)
-   {
-      if (other instanceof SessionXAJoinMessage == false)
-      {
-         return false;
-      }
-            
-      SessionXAJoinMessage r = (SessionXAJoinMessage)other;
-      
-      return super.equals(other) && this.xid.equals(r.xid);
-   }
-   
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}
-

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAJoinMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAJoinMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAJoinMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAJoinMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,96 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import javax.transaction.xa.Xid;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+
+
+/**
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * 
+ * @version <tt>$Revision$</tt>
+ */
+public class SessionXAJoinMessage extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+   
+   private Xid xid;
+   
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public SessionXAJoinMessage(final Xid xid)
+   {
+      super(SESS_XA_JOIN);
+      
+      this.xid = xid;
+   }
+   
+   public SessionXAJoinMessage()
+   {
+      super(SESS_XA_JOIN);
+   }
+
+   // Public --------------------------------------------------------
+   
+   public Xid getXid()
+   {
+      return xid;
+   }
+   
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      XidCodecSupport.encodeXid(xid, buffer);
+   }
+   
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      xid = XidCodecSupport.decodeXid(buffer);
+   }
+   
+   public boolean equals(Object other)
+   {
+      if (other instanceof SessionXAJoinMessage == false)
+      {
+         return false;
+      }
+            
+      SessionXAJoinMessage r = (SessionXAJoinMessage)other;
+      
+      return super.equals(other) && this.xid.equals(r.xid);
+   }
+   
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}
+

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAPrepareMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAPrepareMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAPrepareMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,96 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import javax.transaction.xa.Xid;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-
-
-/**
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * 
- * @version <tt>$Revision$</tt>
- */
-public class SessionXAPrepareMessage extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-   
-   private Xid xid;
-   
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public SessionXAPrepareMessage(final Xid xid)
-   {
-      super(SESS_XA_PREPARE);
-      
-      this.xid = xid;
-   }
-   
-   public SessionXAPrepareMessage()
-   {
-      super(SESS_XA_PREPARE);
-   }
-
-   // Public --------------------------------------------------------
-   
-   public Xid getXid()
-   {
-      return xid;
-   }
-   
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      XidCodecSupport.encodeXid(xid, buffer);
-   }
-   
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      xid = XidCodecSupport.decodeXid(buffer);
-   }
-   
-   public boolean equals(Object other)
-   {
-      if (other instanceof SessionXAPrepareMessage == false)
-      {
-         return false;
-      }
-            
-      SessionXAPrepareMessage r = (SessionXAPrepareMessage)other;
-      
-      return super.equals(other) && this.xid.equals(r.xid);
-   }
-
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}
-

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAPrepareMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAPrepareMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAPrepareMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAPrepareMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,96 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import javax.transaction.xa.Xid;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+
+
+/**
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * 
+ * @version <tt>$Revision$</tt>
+ */
+public class SessionXAPrepareMessage extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+   
+   private Xid xid;
+   
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public SessionXAPrepareMessage(final Xid xid)
+   {
+      super(SESS_XA_PREPARE);
+      
+      this.xid = xid;
+   }
+   
+   public SessionXAPrepareMessage()
+   {
+      super(SESS_XA_PREPARE);
+   }
+
+   // Public --------------------------------------------------------
+   
+   public Xid getXid()
+   {
+      return xid;
+   }
+   
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      XidCodecSupport.encodeXid(xid, buffer);
+   }
+   
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      xid = XidCodecSupport.decodeXid(buffer);
+   }
+   
+   public boolean equals(Object other)
+   {
+      if (other instanceof SessionXAPrepareMessage == false)
+      {
+         return false;
+      }
+            
+      SessionXAPrepareMessage r = (SessionXAPrepareMessage)other;
+      
+      return super.equals(other) && this.xid.equals(r.xid);
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}
+

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAResponseMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAResponseMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAResponseMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,122 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-
-
-/**
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * 
- * @version <tt>$Revision$</tt>
- */
-public class SessionXAResponseMessage extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-   
-   private boolean error;
-   
-   private int responseCode;
-   
-   private String message;
-      
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public SessionXAResponseMessage(final boolean isError, final int responseCode, final String message)
-   {
-      super(SESS_XA_RESP);
-      
-      this.error = isError;
-      
-      this.responseCode = responseCode;
-      
-      this.message = message;
-   }
-   
-   public SessionXAResponseMessage()
-   {
-      super(SESS_XA_RESP);
-   }
-
-   // Public --------------------------------------------------------
-
-   public boolean isResponse()
-   {
-      return true;
-   }
-   
-   public boolean isError()
-   {
-      return error;
-   }
-   
-   public int getResponseCode()
-   {
-      return this.responseCode;
-   }
-   
-   public String getMessage()
-   {
-      return message;
-   }
-   
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      buffer.putBoolean(error);      
-      buffer.putInt(responseCode);      
-      buffer.putNullableString(message);
-   }
-   
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      error = buffer.getBoolean();      
-      responseCode = buffer.getInt();      
-      message = buffer.getNullableString();
-   }
-   
-   public boolean equals(Object other)
-   {
-      if (other instanceof SessionXAResponseMessage == false)
-      {
-         return false;
-      }
-            
-      SessionXAResponseMessage r = (SessionXAResponseMessage)other;
-      
-      return super.equals(other) && this.error == r.error && this.responseCode == r.responseCode &&
-         this.message.equals(r.message);
-   }
-
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}
-

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAResponseMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAResponseMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAResponseMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAResponseMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,122 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+
+
+/**
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * 
+ * @version <tt>$Revision$</tt>
+ */
+public class SessionXAResponseMessage extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+   
+   private boolean error;
+   
+   private int responseCode;
+   
+   private String message;
+      
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public SessionXAResponseMessage(final boolean isError, final int responseCode, final String message)
+   {
+      super(SESS_XA_RESP);
+      
+      this.error = isError;
+      
+      this.responseCode = responseCode;
+      
+      this.message = message;
+   }
+   
+   public SessionXAResponseMessage()
+   {
+      super(SESS_XA_RESP);
+   }
+
+   // Public --------------------------------------------------------
+
+   public boolean isResponse()
+   {
+      return true;
+   }
+   
+   public boolean isError()
+   {
+      return error;
+   }
+   
+   public int getResponseCode()
+   {
+      return this.responseCode;
+   }
+   
+   public String getMessage()
+   {
+      return message;
+   }
+   
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      buffer.putBoolean(error);      
+      buffer.putInt(responseCode);      
+      buffer.putNullableString(message);
+   }
+   
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      error = buffer.getBoolean();      
+      responseCode = buffer.getInt();      
+      message = buffer.getNullableString();
+   }
+   
+   public boolean equals(Object other)
+   {
+      if (other instanceof SessionXAResponseMessage == false)
+      {
+         return false;
+      }
+            
+      SessionXAResponseMessage r = (SessionXAResponseMessage)other;
+      
+      return super.equals(other) && this.error == r.error && this.responseCode == r.responseCode &&
+         this.message.equals(r.message);
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}
+

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAResumeMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAResumeMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAResumeMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,96 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import javax.transaction.xa.Xid;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-
-
-/**
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * 
- * @version <tt>$Revision$</tt>
- */
-public class SessionXAResumeMessage extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-   
-   private Xid xid;
-   
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public SessionXAResumeMessage(final Xid xid)
-   {
-      super(SESS_XA_RESUME);
-      
-      this.xid = xid;
-   }
-   
-   public SessionXAResumeMessage()
-   {
-      super(SESS_XA_RESUME);
-   }
-
-   // Public --------------------------------------------------------
-   
-   public Xid getXid()
-   {
-      return xid;
-   }
-   
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      XidCodecSupport.encodeXid(xid, buffer);
-   }
-   
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      xid = XidCodecSupport.decodeXid(buffer);
-   }
-   
-   public boolean equals(Object other)
-   {
-      if (other instanceof SessionXAResumeMessage == false)
-      {
-         return false;
-      }
-            
-      SessionXAResumeMessage r = (SessionXAResumeMessage)other;
-      
-      return super.equals(other) &&  this.xid.equals(r.xid);
-   }
-   
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}
-

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAResumeMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAResumeMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAResumeMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAResumeMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,96 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import javax.transaction.xa.Xid;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+
+
+/**
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * 
+ * @version <tt>$Revision$</tt>
+ */
+public class SessionXAResumeMessage extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+   
+   private Xid xid;
+   
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public SessionXAResumeMessage(final Xid xid)
+   {
+      super(SESS_XA_RESUME);
+      
+      this.xid = xid;
+   }
+   
+   public SessionXAResumeMessage()
+   {
+      super(SESS_XA_RESUME);
+   }
+
+   // Public --------------------------------------------------------
+   
+   public Xid getXid()
+   {
+      return xid;
+   }
+   
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      XidCodecSupport.encodeXid(xid, buffer);
+   }
+   
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      xid = XidCodecSupport.decodeXid(buffer);
+   }
+   
+   public boolean equals(Object other)
+   {
+      if (other instanceof SessionXAResumeMessage == false)
+      {
+         return false;
+      }
+            
+      SessionXAResumeMessage r = (SessionXAResumeMessage)other;
+      
+      return super.equals(other) &&  this.xid.equals(r.xid);
+   }
+   
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}
+

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXARollbackMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXARollbackMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXARollbackMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,96 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import javax.transaction.xa.Xid;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-
-
-/**
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * 
- * @version <tt>$Revision$</tt>
- */
-public class SessionXARollbackMessage extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-   
-   private Xid xid;
-   
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public SessionXARollbackMessage(final Xid xid)
-   {
-      super(SESS_XA_ROLLBACK);
-      
-      this.xid = xid;
-   }
-   
-   public SessionXARollbackMessage()
-   {
-      super(SESS_XA_ROLLBACK);
-   }
-
-   // Public --------------------------------------------------------
-   
-   public Xid getXid()
-   {
-      return xid;
-   }
-   
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      XidCodecSupport.encodeXid(xid, buffer);
-   }
-   
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      xid = XidCodecSupport.decodeXid(buffer);
-   }
-   
-   public boolean equals(Object other)
-   {
-      if (other instanceof SessionXARollbackMessage == false)
-      {
-         return false;
-      }
-            
-      SessionXARollbackMessage r = (SessionXARollbackMessage)other;
-      
-      return super.equals(other) && this.xid.equals(r.xid);
-   }
-   
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}
-

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXARollbackMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXARollbackMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXARollbackMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXARollbackMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,96 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import javax.transaction.xa.Xid;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+
+
+/**
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * 
+ * @version <tt>$Revision$</tt>
+ */
+public class SessionXARollbackMessage extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+   
+   private Xid xid;
+   
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public SessionXARollbackMessage(final Xid xid)
+   {
+      super(SESS_XA_ROLLBACK);
+      
+      this.xid = xid;
+   }
+   
+   public SessionXARollbackMessage()
+   {
+      super(SESS_XA_ROLLBACK);
+   }
+
+   // Public --------------------------------------------------------
+   
+   public Xid getXid()
+   {
+      return xid;
+   }
+   
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      XidCodecSupport.encodeXid(xid, buffer);
+   }
+   
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      xid = XidCodecSupport.decodeXid(buffer);
+   }
+   
+   public boolean equals(Object other)
+   {
+      if (other instanceof SessionXARollbackMessage == false)
+      {
+         return false;
+      }
+            
+      SessionXARollbackMessage r = (SessionXARollbackMessage)other;
+      
+      return super.equals(other) && this.xid.equals(r.xid);
+   }
+   
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}
+

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXASetTimeoutMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXASetTimeoutMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXASetTimeoutMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,95 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-
-
-
-/**
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * 
- * @version <tt>$Revision$</tt>
- */
-public class SessionXASetTimeoutMessage extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-   
-   private int timeoutSeconds;
-   
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public SessionXASetTimeoutMessage(final int timeoutSeconds)
-   {
-      super(SESS_XA_SET_TIMEOUT);
-      
-      this.timeoutSeconds = timeoutSeconds;
-   }
-   
-   public SessionXASetTimeoutMessage()
-   {
-      super(SESS_XA_SET_TIMEOUT);
-   }
-   
-   // Public --------------------------------------------------------
-   
-   public int getTimeoutSeconds()
-   {
-      return this.timeoutSeconds;
-   }
-   
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      buffer.putInt(timeoutSeconds);
-   }
-   
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      timeoutSeconds = buffer.getInt();
-   }
-   
-   public boolean equals(Object other)
-   {
-      if (other instanceof SessionXASetTimeoutMessage == false)
-      {
-         return false;
-      }
-            
-      SessionXASetTimeoutMessage r = (SessionXASetTimeoutMessage)other;
-      
-      return super.equals(other) && this.timeoutSeconds == r.timeoutSeconds;
-   }
-
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}
-

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXASetTimeoutMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXASetTimeoutMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXASetTimeoutMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXASetTimeoutMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,95 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+
+
+
+/**
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * 
+ * @version <tt>$Revision$</tt>
+ */
+public class SessionXASetTimeoutMessage extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+   
+   private int timeoutSeconds;
+   
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public SessionXASetTimeoutMessage(final int timeoutSeconds)
+   {
+      super(SESS_XA_SET_TIMEOUT);
+      
+      this.timeoutSeconds = timeoutSeconds;
+   }
+   
+   public SessionXASetTimeoutMessage()
+   {
+      super(SESS_XA_SET_TIMEOUT);
+   }
+   
+   // Public --------------------------------------------------------
+   
+   public int getTimeoutSeconds()
+   {
+      return this.timeoutSeconds;
+   }
+   
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      buffer.putInt(timeoutSeconds);
+   }
+   
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      timeoutSeconds = buffer.getInt();
+   }
+   
+   public boolean equals(Object other)
+   {
+      if (other instanceof SessionXASetTimeoutMessage == false)
+      {
+         return false;
+      }
+            
+      SessionXASetTimeoutMessage r = (SessionXASetTimeoutMessage)other;
+      
+      return super.equals(other) && this.timeoutSeconds == r.timeoutSeconds;
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}
+

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXASetTimeoutResponseMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXASetTimeoutResponseMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXASetTimeoutResponseMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,98 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-
-
-/**
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * 
- * @version <tt>$Revision$</tt>
- */
-public class SessionXASetTimeoutResponseMessage extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-   
-   private boolean ok;
-   
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public SessionXASetTimeoutResponseMessage(final boolean ok)
-   {
-      super(SESS_XA_SET_TIMEOUT_RESP);
-      
-      this.ok = ok;
-   }
-   
-   public SessionXASetTimeoutResponseMessage()
-   {
-      super(SESS_XA_SET_TIMEOUT_RESP);
-   }
-   
-   // Public --------------------------------------------------------
-   
-   public boolean isResponse()
-   {
-      return true;
-   }
-   
-   public boolean isOK()
-   {
-      return ok;
-   }
-   
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      buffer.putBoolean(ok);
-   }
-   
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      ok = buffer.getBoolean();
-   }
-   
-   public boolean equals(Object other)
-   {
-      if (other instanceof SessionXASetTimeoutResponseMessage == false)
-      {
-         return false;
-      }
-            
-      SessionXASetTimeoutResponseMessage r = (SessionXASetTimeoutResponseMessage)other;
-      
-      return super.equals(other) && this.ok == r.ok;  
-   }
-   
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXASetTimeoutResponseMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXASetTimeoutResponseMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXASetTimeoutResponseMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXASetTimeoutResponseMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,98 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+
+
+/**
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * 
+ * @version <tt>$Revision$</tt>
+ */
+public class SessionXASetTimeoutResponseMessage extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+   
+   private boolean ok;
+   
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public SessionXASetTimeoutResponseMessage(final boolean ok)
+   {
+      super(SESS_XA_SET_TIMEOUT_RESP);
+      
+      this.ok = ok;
+   }
+   
+   public SessionXASetTimeoutResponseMessage()
+   {
+      super(SESS_XA_SET_TIMEOUT_RESP);
+   }
+   
+   // Public --------------------------------------------------------
+   
+   public boolean isResponse()
+   {
+      return true;
+   }
+   
+   public boolean isOK()
+   {
+      return ok;
+   }
+   
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      buffer.putBoolean(ok);
+   }
+   
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      ok = buffer.getBoolean();
+   }
+   
+   public boolean equals(Object other)
+   {
+      if (other instanceof SessionXASetTimeoutResponseMessage == false)
+      {
+         return false;
+      }
+            
+      SessionXASetTimeoutResponseMessage r = (SessionXASetTimeoutResponseMessage)other;
+      
+      return super.equals(other) && this.ok == r.ok;  
+   }
+   
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAStartMessage.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAStartMessage.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAStartMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,96 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import javax.transaction.xa.Xid;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-
-
-/**
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * 
- * @version <tt>$Revision$</tt>
- */
-public class SessionXAStartMessage extends PacketImpl
-{
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-   
-   private Xid xid;
-   
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public SessionXAStartMessage(final Xid xid)
-   {
-      super(SESS_XA_START);
-      
-      this.xid = xid;
-   }
-   
-   public SessionXAStartMessage()
-   {
-      super(SESS_XA_START);
-   }
-
-   // Public --------------------------------------------------------
-   
-   public Xid getXid()
-   {
-      return xid;
-   }
-   
-   public void encodeBody(final MessagingBuffer buffer)
-   {
-      XidCodecSupport.encodeXid(xid, buffer);
-   }
-   
-   public void decodeBody(final MessagingBuffer buffer)
-   {
-      xid = XidCodecSupport.decodeXid(buffer);
-   }
-   
-   public boolean equals(Object other)
-   {
-      if (other instanceof SessionXAStartMessage == false)
-      {
-         return false;
-      }
-            
-      SessionXAStartMessage r = (SessionXAStartMessage)other;
-      
-      return super.equals(other) && this.xid.equals(r.xid);
-   }
-
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}
-

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAStartMessage.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAStartMessage.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAStartMessage.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/SessionXAStartMessage.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,96 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import javax.transaction.xa.Xid;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+
+
+/**
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * 
+ * @version <tt>$Revision$</tt>
+ */
+public class SessionXAStartMessage extends PacketImpl
+{
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+   
+   private Xid xid;
+   
+   // Static --------------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public SessionXAStartMessage(final Xid xid)
+   {
+      super(SESS_XA_START);
+      
+      this.xid = xid;
+   }
+   
+   public SessionXAStartMessage()
+   {
+      super(SESS_XA_START);
+   }
+
+   // Public --------------------------------------------------------
+   
+   public Xid getXid()
+   {
+      return xid;
+   }
+   
+   public void encodeBody(final MessagingBuffer buffer)
+   {
+      XidCodecSupport.encodeXid(xid, buffer);
+   }
+   
+   public void decodeBody(final MessagingBuffer buffer)
+   {
+      xid = XidCodecSupport.decodeXid(buffer);
+   }
+   
+   public boolean equals(Object other)
+   {
+      if (other instanceof SessionXAStartMessage == false)
+      {
+         return false;
+      }
+            
+      SessionXAStartMessage r = (SessionXAStartMessage)other;
+      
+      return super.equals(other) && this.xid.equals(r.xid);
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}
+

Deleted: trunk/dotnet/JBMClient/remoting/impl/wireformat/XidCodecSupport.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/XidCodecSupport.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/XidCodecSupport.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,84 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.impl.wireformat;
-
-import javax.transaction.xa.Xid;
-
-import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
-import org.jboss.messaging.core.transaction.impl.XidImpl;
-import org.jboss.messaging.util.DataConstants;
-
-/**
- * @author <a href="mailto:jmesnil at redhat.com">Jeff Mesnil</a>
- *
- * @version <tt>$Revision$</tt>
- *
- */
-public class XidCodecSupport
-{
-
-   // Constants -----------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-
-   // Static --------------------------------------------------------
-
-   public static void encodeXid(final Xid xid, final MessagingBuffer out)
-   {
-      out.putInt(xid.getFormatId());
-      out.putInt(xid.getBranchQualifier().length);
-      out.putBytes(xid.getBranchQualifier());
-      out.putInt(xid.getGlobalTransactionId().length);
-      out.putBytes(xid.getGlobalTransactionId());
-   }
-
-   public static Xid decodeXid(final MessagingBuffer in)
-   {
-      int formatID = in.getInt();
-      byte[] bq = new byte[in.getInt()];
-      in.getBytes(bq);
-      byte[] gtxid = new byte[in.getInt()];
-      in.getBytes(gtxid);      
-      Xid xid = new XidImpl(bq, formatID, gtxid);      
-      return xid;
-   }
-
-   public static int getXidEncodeLength(final Xid xid)
-   {
-      return DataConstants.SIZE_INT * 3 +
-            xid.getBranchQualifier().length +
-            xid.getGlobalTransactionId().length;
-   }
-
-   // Constructors --------------------------------------------------
-
-   // Public --------------------------------------------------------
-
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-}

Copied: trunk/dotnet/JBMClient/remoting/impl/wireformat/XidCodecSupport.java (from rev 5824, trunk/dotnet/JBMClient/remoting/impl/wireformat/XidCodecSupport.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/impl/wireformat/XidCodecSupport.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/impl/wireformat/XidCodecSupport.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,84 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.impl.wireformat;
+
+import javax.transaction.xa.Xid;
+
+import org.jboss.messaging.core.remoting.spi.MessagingBuffer;
+import org.jboss.messaging.core.transaction.impl.XidImpl;
+import org.jboss.messaging.util.DataConstants;
+
+/**
+ * @author <a href="mailto:jmesnil at redhat.com">Jeff Mesnil</a>
+ *
+ * @version <tt>$Revision$</tt>
+ *
+ */
+public class XidCodecSupport
+{
+
+   // Constants -----------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   // Static --------------------------------------------------------
+
+   public static void encodeXid(final Xid xid, final MessagingBuffer out)
+   {
+      out.putInt(xid.getFormatId());
+      out.putInt(xid.getBranchQualifier().length);
+      out.putBytes(xid.getBranchQualifier());
+      out.putInt(xid.getGlobalTransactionId().length);
+      out.putBytes(xid.getGlobalTransactionId());
+   }
+
+   public static Xid decodeXid(final MessagingBuffer in)
+   {
+      int formatID = in.getInt();
+      byte[] bq = new byte[in.getInt()];
+      in.getBytes(bq);
+      byte[] gtxid = new byte[in.getInt()];
+      in.getBytes(gtxid);      
+      Xid xid = new XidImpl(bq, formatID, gtxid);      
+      return xid;
+   }
+
+   public static int getXidEncodeLength(final Xid xid)
+   {
+      return DataConstants.SIZE_INT * 3 +
+            xid.getBranchQualifier().length +
+            xid.getGlobalTransactionId().length;
+   }
+
+   // Constructors --------------------------------------------------
+
+   // Public --------------------------------------------------------
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}

Copied: trunk/dotnet/JBMClient/remoting/spi (from rev 5824, trunk/dotnet/JBMClient/remoting/spi)

Deleted: trunk/dotnet/JBMClient/remoting/spi/Acceptor.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/spi/Acceptor.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/spi/Acceptor.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,37 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.spi;
-
-import org.jboss.messaging.core.server.MessagingComponent;
-
-/**
- * An Acceptor is used tby the Remoting Service to allow clients to connect. It should take care of dispatchin client requests
- * to the Remoting Service's Dispatcher.
- *
- * @author <a href="ataylor at redhat.com">Andy Taylor</a>
- * @author <a href="tim.fox at jboss.com">Tim Fox</a>
- */
-public interface Acceptor extends MessagingComponent
-{
-   void stop();
-}

Copied: trunk/dotnet/JBMClient/remoting/spi/Acceptor.java (from rev 5824, trunk/dotnet/JBMClient/remoting/spi/Acceptor.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/spi/Acceptor.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/spi/Acceptor.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,37 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.spi;
+
+import org.jboss.messaging.core.server.MessagingComponent;
+
+/**
+ * An Acceptor is used tby the Remoting Service to allow clients to connect. It should take care of dispatchin client requests
+ * to the Remoting Service's Dispatcher.
+ *
+ * @author <a href="ataylor at redhat.com">Andy Taylor</a>
+ * @author <a href="tim.fox at jboss.com">Tim Fox</a>
+ */
+public interface Acceptor extends MessagingComponent
+{
+   void stop();
+}

Deleted: trunk/dotnet/JBMClient/remoting/spi/AcceptorFactory.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/spi/AcceptorFactory.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/spi/AcceptorFactory.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,36 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */ 
-
-package org.jboss.messaging.core.remoting.spi;
-
-import java.util.Map;
-
-/**
- * @author <a href="ataylor at redhat.com">Andy Taylor</a>
- * @author <a href="tim.fox at jboss.com">Tim Fox</a>
- */
-public interface AcceptorFactory
-{
-   Acceptor createAcceptor(final Map<String, Object> configuration,
-                           BufferHandler handler,                        
-                           ConnectionLifeCycleListener listener);
-}

Copied: trunk/dotnet/JBMClient/remoting/spi/AcceptorFactory.java (from rev 5824, trunk/dotnet/JBMClient/remoting/spi/AcceptorFactory.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/spi/AcceptorFactory.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/spi/AcceptorFactory.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,36 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */ 
+
+package org.jboss.messaging.core.remoting.spi;
+
+import java.util.Map;
+
+/**
+ * @author <a href="ataylor at redhat.com">Andy Taylor</a>
+ * @author <a href="tim.fox at jboss.com">Tim Fox</a>
+ */
+public interface AcceptorFactory
+{
+   Acceptor createAcceptor(final Map<String, Object> configuration,
+                           BufferHandler handler,                        
+                           ConnectionLifeCycleListener listener);
+}

Deleted: trunk/dotnet/JBMClient/remoting/spi/BufferHandler.cs
===================================================================
--- trunk/dotnet/JBMClient/remoting/spi/BufferHandler.cs	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/spi/BufferHandler.cs	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,37 +0,0 @@
-/*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt in the distribution for a
-  * full listing of individual contributors.
-  *
-  * This is free software; you can redistribute it and/or modify it
-  * under the terms of the GNU Lesser General Public License as
-  * published by the Free Software Foundation; either version 2.1 of
-  * the License, or (at your option) any later version.
-  *
-  * This software is distributed in the hope that it will be useful,
-  * but WITHOUT ANY WARRANTY; without even the implied warranty of
-  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-  * Lesser General Public License for more details.
-  *
-  * You should have received a copy of the GNU Lesser General Public
-  * License along with this software; if not, write to the Free
-  * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-  * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-  */
-namespace JBoss.JBM.Client.remoting.spi
-{
-
-    /**
-     * A BufferHandler
-     * 
-     * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
-     *
-     */
-    public interface BufferHandler
-    {
-        void BufferReceived(object connectionID, MessagingBuffer buffer);
-
-        int IsReadyToHandle(MessagingBuffer buffer);
-    }
-}
\ No newline at end of file

Copied: trunk/dotnet/JBMClient/remoting/spi/BufferHandler.cs (from rev 5824, trunk/dotnet/JBMClient/remoting/spi/BufferHandler.cs)
===================================================================
--- trunk/dotnet/JBMClient/remoting/spi/BufferHandler.cs	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/spi/BufferHandler.cs	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,37 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt in the distribution for a
+  * full listing of individual contributors.
+  *
+  * This is free software; you can redistribute it and/or modify it
+  * under the terms of the GNU Lesser General Public License as
+  * published by the Free Software Foundation; either version 2.1 of
+  * the License, or (at your option) any later version.
+  *
+  * This software is distributed in the hope that it will be useful,
+  * but WITHOUT ANY WARRANTY; without even the implied warranty of
+  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+  * Lesser General Public License for more details.
+  *
+  * You should have received a copy of the GNU Lesser General Public
+  * License along with this software; if not, write to the Free
+  * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+  * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+  */
+namespace JBoss.JBM.Client.remoting.spi
+{
+
+    /**
+     * A BufferHandler
+     * 
+     * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+     *
+     */
+    public interface BufferHandler
+    {
+        void BufferReceived(object connectionID, MessagingBuffer buffer);
+
+        int IsReadyToHandle(MessagingBuffer buffer);
+    }
+}
\ No newline at end of file

Deleted: trunk/dotnet/JBMClient/remoting/spi/Connection.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/spi/Connection.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/spi/Connection.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,45 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-
-package org.jboss.messaging.core.remoting.spi;
-
-
-
-/**
- *
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- *
- * @version <tt>$Revision$</tt>
- *
- */
-public interface Connection
-{
-   MessagingBuffer createBuffer(int size);
-
-   Object getID();
-
-   void write(MessagingBuffer buffer);
-
-   void close();
-
-   String getRemoteAddress();
-}
\ No newline at end of file

Copied: trunk/dotnet/JBMClient/remoting/spi/Connection.java (from rev 5824, trunk/dotnet/JBMClient/remoting/spi/Connection.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/spi/Connection.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/spi/Connection.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,45 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+
+package org.jboss.messaging.core.remoting.spi;
+
+
+
+/**
+ *
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ *
+ * @version <tt>$Revision$</tt>
+ *
+ */
+public interface Connection
+{
+   MessagingBuffer createBuffer(int size);
+
+   Object getID();
+
+   void write(MessagingBuffer buffer);
+
+   void close();
+
+   String getRemoteAddress();
+}
\ No newline at end of file

Deleted: trunk/dotnet/JBMClient/remoting/spi/ConnectionLifeCycleListener.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/spi/ConnectionLifeCycleListener.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/spi/ConnectionLifeCycleListener.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,40 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.messaging.core.remoting.spi;
-
-import org.jboss.messaging.core.exception.MessagingException;
-
-/**
- *
- * A ConnectionLifeCycleListener
- *
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- *
- */
-public interface ConnectionLifeCycleListener
-{
-   void connectionCreated(Connection connection);
-
-   void connectionDestroyed(Object connectionID);
-
-   void connectionException(Object connectionID, MessagingException me);
-}

Copied: trunk/dotnet/JBMClient/remoting/spi/ConnectionLifeCycleListener.java (from rev 5824, trunk/dotnet/JBMClient/remoting/spi/ConnectionLifeCycleListener.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/spi/ConnectionLifeCycleListener.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/spi/ConnectionLifeCycleListener.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,40 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.messaging.core.remoting.spi;
+
+import org.jboss.messaging.core.exception.MessagingException;
+
+/**
+ *
+ * A ConnectionLifeCycleListener
+ *
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ *
+ */
+public interface ConnectionLifeCycleListener
+{
+   void connectionCreated(Connection connection);
+
+   void connectionDestroyed(Object connectionID);
+
+   void connectionException(Object connectionID, MessagingException me);
+}

Deleted: trunk/dotnet/JBMClient/remoting/spi/Connector.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/spi/Connector.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/spi/Connector.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,48 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.messaging.core.remoting.spi;
-
-/**
- * 
- * A Connector
- * 
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- *
- */
-public interface Connector
-{
-   void start();
-   
-   void close();
-   
-   boolean isStarted();
-   
-   /**
-    * Create and return a connection from this connector.
-    * 
-    * This method must NOT throw an exception if it fails to create the connection
-    * (e.g. network is not available), in this case it MUST return null
-    * 
-    * @return The connection, or null if unable to create a connection (e.g. network is unavailable)
-    */
-   Connection createConnection();   
-}

Copied: trunk/dotnet/JBMClient/remoting/spi/Connector.java (from rev 5824, trunk/dotnet/JBMClient/remoting/spi/Connector.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/spi/Connector.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/spi/Connector.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,48 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.messaging.core.remoting.spi;
+
+/**
+ * 
+ * A Connector
+ * 
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ *
+ */
+public interface Connector
+{
+   void start();
+   
+   void close();
+   
+   boolean isStarted();
+   
+   /**
+    * Create and return a connection from this connector.
+    * 
+    * This method must NOT throw an exception if it fails to create the connection
+    * (e.g. network is not available), in this case it MUST return null
+    * 
+    * @return The connection, or null if unable to create a connection (e.g. network is unavailable)
+    */
+   Connection createConnection();   
+}

Deleted: trunk/dotnet/JBMClient/remoting/spi/ConnectorFactory.java
===================================================================
--- trunk/dotnet/JBMClient/remoting/spi/ConnectorFactory.java	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/spi/ConnectorFactory.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,16 +0,0 @@
-package org.jboss.messaging.core.remoting.spi;
-
-import java.util.Map;
-
-/**
- * 
- * A ConnectorFactory
- * 
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- *
- */
-public interface ConnectorFactory
-{
-   Connector createConnector(Map<String, Object> configuration, BufferHandler handler,                           
-                             ConnectionLifeCycleListener listener);
-}

Copied: trunk/dotnet/JBMClient/remoting/spi/ConnectorFactory.java (from rev 5824, trunk/dotnet/JBMClient/remoting/spi/ConnectorFactory.java)
===================================================================
--- trunk/dotnet/JBMClient/remoting/spi/ConnectorFactory.java	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/spi/ConnectorFactory.java	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,16 @@
+package org.jboss.messaging.core.remoting.spi;
+
+import java.util.Map;
+
+/**
+ * 
+ * A ConnectorFactory
+ * 
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ *
+ */
+public interface ConnectorFactory
+{
+   Connector createConnector(Map<String, Object> configuration, BufferHandler handler,                           
+                             ConnectionLifeCycleListener listener);
+}

Deleted: trunk/dotnet/JBMClient/remoting/spi/MessagingBuffer.cs
===================================================================
--- trunk/dotnet/JBMClient/remoting/spi/MessagingBuffer.cs	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/remoting/spi/MessagingBuffer.cs	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,126 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-
-namespace JBoss.JBM.Client.remoting.spi
-{
-    using JBoss.JBM.Client.util;
-
-    /**
-     *
-     * A MessagingBuffer
-     *
-     * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
-     *
-     */
-    public interface MessagingBuffer
-    {
-        void PutByte(byte val);
-
-        void PutBytes(byte[] bytes);
-
-        void PutBytes(byte[] bytes, int offset, int length);
-
-        void PutInt(int val);
-
-        void PutInt(int pos, int val);
-
-        void PutLong(long val);
-
-        void PutShort(short val);
-
-        void PutDouble(double val);
-
-        void PutFloat(float val);
-
-        void PutBoolean(bool val);
-
-        void PutChar(char val);
-
-        void PutNullableString(string val);
-
-        void PutString(string val);
-
-        void PutSimpleString(SimpleString val);
-
-        void PutNullableSimpleString(SimpleString val);
-
-        void PutUTF(string utf);
-
-        byte GetByte();
-
-        short GetUnsignedByte();
-
-        void GetBytes(byte[] bytes);
-
-        void GetBytes(byte[] bytes, int offset, int length);
-
-        int GetInt();
-
-        long GetLong();
-
-        short GetShort();
-
-        int GetUnsignedShort();
-
-        double GetDouble();
-
-        float GetFloat();
-
-        bool GetBoolean();
-
-        char GetChar();
-
-        string GetString();
-
-        string GetNullableString();
-
-        SimpleString GetSimpleString();
-
-        SimpleString getNullableSimpleString();
-
-        string GetUTF();
-
-        byte[] ToArray();
-
-        int Remaining();
-
-        int Capacity();
-
-        int Limit();
-
-        void limit(int limit);
-
-        void Flip();
-
-        void Position(int position);
-
-        int Position();
-
-        void Rewind();
-
-        MessagingBuffer Slice();
-
-        MessagingBuffer CreateNewBuffer(int len);
-
-        object GetUnderlyingBuffer();
-    }
-}
\ No newline at end of file

Copied: trunk/dotnet/JBMClient/remoting/spi/MessagingBuffer.cs (from rev 5824, trunk/dotnet/JBMClient/remoting/spi/MessagingBuffer.cs)
===================================================================
--- trunk/dotnet/JBMClient/remoting/spi/MessagingBuffer.cs	                        (rev 0)
+++ trunk/dotnet/JBMClient/remoting/spi/MessagingBuffer.cs	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,126 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+
+namespace JBoss.JBM.Client.remoting.spi
+{
+    using JBoss.JBM.Client.util;
+
+    /**
+     *
+     * A MessagingBuffer
+     *
+     * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+     *
+     */
+    public interface MessagingBuffer
+    {
+        void PutByte(byte val);
+
+        void PutBytes(byte[] bytes);
+
+        void PutBytes(byte[] bytes, int offset, int length);
+
+        void PutInt(int val);
+
+        void PutInt(int pos, int val);
+
+        void PutLong(long val);
+
+        void PutShort(short val);
+
+        void PutDouble(double val);
+
+        void PutFloat(float val);
+
+        void PutBoolean(bool val);
+
+        void PutChar(char val);
+
+        void PutNullableString(string val);
+
+        void PutString(string val);
+
+        void PutSimpleString(SimpleString val);
+
+        void PutNullableSimpleString(SimpleString val);
+
+        void PutUTF(string utf);
+
+        byte GetByte();
+
+        short GetUnsignedByte();
+
+        void GetBytes(byte[] bytes);
+
+        void GetBytes(byte[] bytes, int offset, int length);
+
+        int GetInt();
+
+        long GetLong();
+
+        short GetShort();
+
+        int GetUnsignedShort();
+
+        double GetDouble();
+
+        float GetFloat();
+
+        bool GetBoolean();
+
+        char GetChar();
+
+        string GetString();
+
+        string GetNullableString();
+
+        SimpleString GetSimpleString();
+
+        SimpleString getNullableSimpleString();
+
+        string GetUTF();
+
+        byte[] ToArray();
+
+        int Remaining();
+
+        int Capacity();
+
+        int Limit();
+
+        void limit(int limit);
+
+        void Flip();
+
+        void Position(int position);
+
+        int Position();
+
+        void Rewind();
+
+        MessagingBuffer Slice();
+
+        MessagingBuffer CreateNewBuffer(int len);
+
+        object GetUnderlyingBuffer();
+    }
+}
\ No newline at end of file

Copied: trunk/dotnet/JBMClient/util (from rev 5824, trunk/dotnet/JBMClient/util)

Deleted: trunk/dotnet/JBMClient/util/DataConstants.cs
===================================================================
--- trunk/dotnet/JBMClient/util/DataConstants.cs	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/util/DataConstants.cs	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,37 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-
-namespace JBoss.JBM.Client.util
-{
-    public class DataConstants
-    {
-        public const int SIZE_INT = 4;
-        public const int SIZE_BOOLEAN = 1;
-        public const int SIZE_LONG = 8;
-        public const int SIZE_BYTE = 1;
-        public const int SIZE_SHORT = 2;
-        public const int SIZE_DOUBLE = 8;
-        public const int SIZE_FLOAT = 4;
-        public const int SIZE_CHAR = 2;
-
-        public const byte TRUE = 1;
-        public const byte FALSE = 0;
-
-        public const byte NULL = 0;
-        public const byte NOT_NULL = 1;
-
-        public const byte BOOLEAN = 2;
-        public const byte BYTE = 3;
-        public const byte BYTES = 4;
-        public const byte SHORT = 5;
-        public const byte INT = 6;
-        public const byte LONG = 7;
-        public const byte FLOAT = 8;
-        public const byte DOUBLE = 9;
-        public const byte STRING = 10;
-        public const byte CHAR = 11;
-
-    }
-}

Copied: trunk/dotnet/JBMClient/util/DataConstants.cs (from rev 5824, trunk/dotnet/JBMClient/util/DataConstants.cs)
===================================================================
--- trunk/dotnet/JBMClient/util/DataConstants.cs	                        (rev 0)
+++ trunk/dotnet/JBMClient/util/DataConstants.cs	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,37 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+
+namespace JBoss.JBM.Client.util
+{
+    public class DataConstants
+    {
+        public const int SIZE_INT = 4;
+        public const int SIZE_BOOLEAN = 1;
+        public const int SIZE_LONG = 8;
+        public const int SIZE_BYTE = 1;
+        public const int SIZE_SHORT = 2;
+        public const int SIZE_DOUBLE = 8;
+        public const int SIZE_FLOAT = 4;
+        public const int SIZE_CHAR = 2;
+
+        public const byte TRUE = 1;
+        public const byte FALSE = 0;
+
+        public const byte NULL = 0;
+        public const byte NOT_NULL = 1;
+
+        public const byte BOOLEAN = 2;
+        public const byte BYTE = 3;
+        public const byte BYTES = 4;
+        public const byte SHORT = 5;
+        public const byte INT = 6;
+        public const byte LONG = 7;
+        public const byte FLOAT = 8;
+        public const byte DOUBLE = 9;
+        public const byte STRING = 10;
+        public const byte CHAR = 11;
+
+    }
+}

Deleted: trunk/dotnet/JBMClient/util/SimpleString.cs
===================================================================
--- trunk/dotnet/JBMClient/util/SimpleString.cs	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClient/util/SimpleString.cs	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,361 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-
-
-using System;
-using System.Collections;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-
-namespace JBoss.JBM.Client.util
-{
-    /**
-     * 
-     * A SimpleString
-     * 
-     * A simple String class that can store all characters, and stores as simple byte[],
-     * this minimises expensive copying between String objects
-     * 
-     * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
-     * @author <a href="mailto:clebert.suconic at jboss.com">Clebert Suconic</a>
-     *
-     */
-    public class SimpleString : IComparable
-    {
-        // Attributes
-        // ------------------------------------------------------------------------
-        private byte[] data;
-
-        private int hash;
-
-        // Cache the string
-        private string str;
-
-        // Static
-        // ----------------------------------------------------------------------
-
-        /**
-         * Returns a SimpleString constructed from the <code>string</code> parameter.
-         * If <code>string</code> is <code>null</code>, the return value will be <code>null</code> too.
-         */
-        public static SimpleString ToSimpleString(string value)
-        {
-            if (value == null)
-            {
-                return null;
-            }
-            return new SimpleString(value);
-        }
-
-        // Constructors
-        // ----------------------------------------------------------------------
-
-        public SimpleString(string value)
-        {
-
-            int j = 0;
-
-            char[] characters = value.ToCharArray();
-
-            int len = characters.Length;
-
-            data = new byte[len << 1];
-
-            for (int i = 0; i < len; i++)
-            {
-                char c = characters[i];
-
-                byte low = (byte)(c & 0xFF); // low byte
-
-                data[j++] = low;
-
-                byte high = (byte)(c >> 8 & 0xFF); // high byte
-
-                data[j++] = high;
-            }
-
-            str = value;
-        }
-
-        public SimpleString(byte[] data)
-        {
-            this.data = data;
-        }
-
-        // CharSequence implementation
-        // ---------------------------------------------------------------------------
-
-        public int Length
-        {
-            get
-            {
-                return data.Length >> 1;
-            }
-        }
-
-        public char CharAt(int pos)
-        {
-            if (pos < 0 || pos >= data.Length >> 1)
-            {
-                throw new IndexOutOfRangeException();
-            }
-            pos <<= 1;
-
-            return (char)(data[pos] | data[pos + 1] << 8);
-        }
-
-        public SimpleString SubSequence(int start, int end)
-        {
-            int len = data.Length >> 1;
-
-            if (end < start || start < 0 || end > len)
-            {
-                throw new IndexOutOfRangeException();
-            }
-            else
-            {
-                int newlen = (end - start) << 1;
-                byte[] bytes = new byte[newlen];
-
-                Array.Copy(data, start << 1, bytes, 0, newlen);
-
-                return new SimpleString(bytes);
-            }
-        }
-
-        // Comparable implementation -------------------------------------
-
-        public int CompareTo(Object o)
-        {
-            return this.ToString().CompareTo(o.ToString());
-        }
-
-        // Public
-        // ---------------------------------------------------------------------------
-
-		public byte[] Data
-		{
-			get
-			{
-				return this.data;
-			}
-			private set
-			{
-				this.data = value;
-			}
-		}
-
-        public bool StartsWith(SimpleString other)
-        {
-            byte[] otherdata = other.data;
-
-            if (otherdata.Length > this.data.Length)
-            {
-                return false;
-            }
-
-            for (int i = 0; i < otherdata.Length; i++)
-            {
-                if (this.data[i] != otherdata[i])
-                {
-                    return false;
-                }
-            }
-
-            return true;
-        }
-
-
-        public override string ToString()
-        {
-            if (str == null)
-            {
-                int len = data.Length >> 1;
-
-                char[] chars = new char[len];
-
-                int j = 0;
-
-                for (int i = 0; i < len; i++)
-                {
-                    int low = data[j++] & 0xFF;
-
-                    int high = (data[j++] << 8) & 0xFF00;
-
-                    chars[i] = (char)(low | high);
-                }
-
-                str = new String(chars);
-            }
-
-            return str;
-        }
-
-        public override bool Equals(Object other)
-        {
-            if (other is SimpleString)
-            {
-                SimpleString s = (SimpleString)other;
-
-                if (data.Length != s.data.Length)
-                {
-                    return false;
-                }
-
-                for (int i = 0; i < data.Length; i++)
-                {
-                    if (data[i] != s.data[i])
-                    {
-                        return false;
-                    }
-                }
-
-                return true;
-            }
-            else
-            {
-                return false;
-            }
-        }
-
-        public override int GetHashCode()
-        {
-            if (hash == 0)
-            {
-                for (int i = 0; i < data.Length; i++)
-                {
-                    hash = (31 * hash + data[i]) % (int.MaxValue>>5);
-                }
-            }
-
-            return hash;
-        }
-
-        public SimpleString[] Split(char delim)
-        {
-            if (!Contains(delim))
-            {
-                return new SimpleString[] { this };
-            }
-            else
-            {
-                IList<SimpleString> all = new List<SimpleString>();
-                int lasPos = 0;
-                for (int i = 0; i < data.Length; i += 2)
-                {
-                    byte low = (byte)(delim & 0xFF); // low byte
-                    byte high = (byte)(delim >> 8 & 0xFF); // high byte
-                    if (data[i] == low && data[i + 1] == high)
-                    {
-                        byte[] bytes = new byte[i - lasPos];
-                        Array.Copy(data, lasPos, bytes, 0, bytes.Length);
-                        lasPos = i + 2;
-                        all.Add(new SimpleString(bytes));
-                    }
-                }
-                byte[] bytes2 = new byte[data.Length - lasPos];
-                Array.Copy(data, lasPos, bytes2, 0, bytes2.Length);
-                all.Add(new SimpleString(bytes2));
-                return all.ToArray();
-            }
-        }
-
-        public bool Contains(char c)
-        {
-            for (int i = 0; i < data.Length; i += 2)
-            {
-                byte low = (byte)(c & 0xFF); // low byte
-                byte high = (byte)(c >> 8 & 0xFF); // high byte
-                if (data[i] == low && data[i + 1] == high)
-                {
-                    return true;
-                }
-            }
-            return false;
-        }
-
-        public SimpleString Concat(SimpleString toAdd)
-        {
-
-            byte[] bytes = new byte[data.Length + toAdd.Data.Length];
-            Array.Copy(data, 0, bytes, 0, data.Length);
-            Array.Copy(toAdd.Data, 0, bytes, data.Length, toAdd.Data.Length);
-            return new SimpleString(bytes);
-        }
-
-        public SimpleString Concat(char c)
-        {
-            byte[] bytes = new byte[data.Length + 2];
-            Array.Copy(data, 0, bytes, 0, data.Length);
-            bytes[data.Length] = (byte)(c & 0xFF);
-            bytes[data.Length + 1] = (byte)(c >> 8 & 0xFF);
-            return new SimpleString(bytes);
-        }
-
-        public static int SizeofString(SimpleString str)
-        {
-
-            return DataConstants.SIZE_INT + str.data.Length;
-        }
-
-        public static int SizeofNullableString(SimpleString str)
-        {
-            if (str == null)
-            {
-                return 1;
-            }
-            else
-            {
-                return 1 + SizeofString(str);
-            }
-        }
-
-        public void GetChars(int srcBegin, int srcEnd, char[] dst, int dstBegin)
-        {
-            if (srcBegin < 0)
-            {
-                throw new IndexOutOfRangeException("Invalid initialIndex: " + srcBegin);
-            }
-            if (srcEnd > this.Length)
-            {
-                throw new IndexOutOfRangeException("Invalid endIndex: " + srcEnd);
-            }
-            if (srcBegin > srcEnd)
-            {
-                throw new IndexOutOfRangeException("Invalid Length: " + (srcEnd - srcBegin));
-            }
-
-            int j = 0;
-
-            for (int i = srcBegin; i < srcEnd - srcBegin; i++)
-            {
-                int low = data[j++] & 0xFF;
-
-                int high = (data[j++] << 8) & 0xFF00;
-
-                dst[i] = (char)(low | high);
-            }
-        }
-
-    }
-}

Copied: trunk/dotnet/JBMClient/util/SimpleString.cs (from rev 5824, trunk/dotnet/JBMClient/util/SimpleString.cs)
===================================================================
--- trunk/dotnet/JBMClient/util/SimpleString.cs	                        (rev 0)
+++ trunk/dotnet/JBMClient/util/SimpleString.cs	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,361 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005-2008, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+
+
+using System;
+using System.Collections;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+
+namespace JBoss.JBM.Client.util
+{
+    /**
+     * 
+     * A SimpleString
+     * 
+     * A simple String class that can store all characters, and stores as simple byte[],
+     * this minimises expensive copying between String objects
+     * 
+     * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+     * @author <a href="mailto:clebert.suconic at jboss.com">Clebert Suconic</a>
+     *
+     */
+    public class SimpleString : IComparable
+    {
+        // Attributes
+        // ------------------------------------------------------------------------
+        private byte[] data;
+
+        private int hash;
+
+        // Cache the string
+        private string str;
+
+        // Static
+        // ----------------------------------------------------------------------
+
+        /**
+         * Returns a SimpleString constructed from the <code>string</code> parameter.
+         * If <code>string</code> is <code>null</code>, the return value will be <code>null</code> too.
+         */
+        public static SimpleString ToSimpleString(string value)
+        {
+            if (value == null)
+            {
+                return null;
+            }
+            return new SimpleString(value);
+        }
+
+        // Constructors
+        // ----------------------------------------------------------------------
+
+        public SimpleString(string value)
+        {
+
+            int j = 0;
+
+            char[] characters = value.ToCharArray();
+
+            int len = characters.Length;
+
+            data = new byte[len << 1];
+
+            for (int i = 0; i < len; i++)
+            {
+                char c = characters[i];
+
+                byte low = (byte)(c & 0xFF); // low byte
+
+                data[j++] = low;
+
+                byte high = (byte)(c >> 8 & 0xFF); // high byte
+
+                data[j++] = high;
+            }
+
+            str = value;
+        }
+
+        public SimpleString(byte[] data)
+        {
+            this.data = data;
+        }
+
+        // CharSequence implementation
+        // ---------------------------------------------------------------------------
+
+        public int Length
+        {
+            get
+            {
+                return data.Length >> 1;
+            }
+        }
+
+        public char CharAt(int pos)
+        {
+            if (pos < 0 || pos >= data.Length >> 1)
+            {
+                throw new IndexOutOfRangeException();
+            }
+            pos <<= 1;
+
+            return (char)(data[pos] | data[pos + 1] << 8);
+        }
+
+        public SimpleString SubSequence(int start, int end)
+        {
+            int len = data.Length >> 1;
+
+            if (end < start || start < 0 || end > len)
+            {
+                throw new IndexOutOfRangeException();
+            }
+            else
+            {
+                int newlen = (end - start) << 1;
+                byte[] bytes = new byte[newlen];
+
+                Array.Copy(data, start << 1, bytes, 0, newlen);
+
+                return new SimpleString(bytes);
+            }
+        }
+
+        // Comparable implementation -------------------------------------
+
+        public int CompareTo(Object o)
+        {
+            return this.ToString().CompareTo(o.ToString());
+        }
+
+        // Public
+        // ---------------------------------------------------------------------------
+
+		public byte[] Data
+		{
+			get
+			{
+				return this.data;
+			}
+			private set
+			{
+				this.data = value;
+			}
+		}
+
+        public bool StartsWith(SimpleString other)
+        {
+            byte[] otherdata = other.data;
+
+            if (otherdata.Length > this.data.Length)
+            {
+                return false;
+            }
+
+            for (int i = 0; i < otherdata.Length; i++)
+            {
+                if (this.data[i] != otherdata[i])
+                {
+                    return false;
+                }
+            }
+
+            return true;
+        }
+
+
+        public override string ToString()
+        {
+            if (str == null)
+            {
+                int len = data.Length >> 1;
+
+                char[] chars = new char[len];
+
+                int j = 0;
+
+                for (int i = 0; i < len; i++)
+                {
+                    int low = data[j++] & 0xFF;
+
+                    int high = (data[j++] << 8) & 0xFF00;
+
+                    chars[i] = (char)(low | high);
+                }
+
+                str = new String(chars);
+            }
+
+            return str;
+        }
+
+        public override bool Equals(Object other)
+        {
+            if (other is SimpleString)
+            {
+                SimpleString s = (SimpleString)other;
+
+                if (data.Length != s.data.Length)
+                {
+                    return false;
+                }
+
+                for (int i = 0; i < data.Length; i++)
+                {
+                    if (data[i] != s.data[i])
+                    {
+                        return false;
+                    }
+                }
+
+                return true;
+            }
+            else
+            {
+                return false;
+            }
+        }
+
+        public override int GetHashCode()
+        {
+            if (hash == 0)
+            {
+                for (int i = 0; i < data.Length; i++)
+                {
+                    hash = (31 * hash + data[i]) % (int.MaxValue>>5);
+                }
+            }
+
+            return hash;
+        }
+
+        public SimpleString[] Split(char delim)
+        {
+            if (!Contains(delim))
+            {
+                return new SimpleString[] { this };
+            }
+            else
+            {
+                IList<SimpleString> all = new List<SimpleString>();
+                int lasPos = 0;
+                for (int i = 0; i < data.Length; i += 2)
+                {
+                    byte low = (byte)(delim & 0xFF); // low byte
+                    byte high = (byte)(delim >> 8 & 0xFF); // high byte
+                    if (data[i] == low && data[i + 1] == high)
+                    {
+                        byte[] bytes = new byte[i - lasPos];
+                        Array.Copy(data, lasPos, bytes, 0, bytes.Length);
+                        lasPos = i + 2;
+                        all.Add(new SimpleString(bytes));
+                    }
+                }
+                byte[] bytes2 = new byte[data.Length - lasPos];
+                Array.Copy(data, lasPos, bytes2, 0, bytes2.Length);
+                all.Add(new SimpleString(bytes2));
+                return all.ToArray();
+            }
+        }
+
+        public bool Contains(char c)
+        {
+            for (int i = 0; i < data.Length; i += 2)
+            {
+                byte low = (byte)(c & 0xFF); // low byte
+                byte high = (byte)(c >> 8 & 0xFF); // high byte
+                if (data[i] == low && data[i + 1] == high)
+                {
+                    return true;
+                }
+            }
+            return false;
+        }
+
+        public SimpleString Concat(SimpleString toAdd)
+        {
+
+            byte[] bytes = new byte[data.Length + toAdd.Data.Length];
+            Array.Copy(data, 0, bytes, 0, data.Length);
+            Array.Copy(toAdd.Data, 0, bytes, data.Length, toAdd.Data.Length);
+            return new SimpleString(bytes);
+        }
+
+        public SimpleString Concat(char c)
+        {
+            byte[] bytes = new byte[data.Length + 2];
+            Array.Copy(data, 0, bytes, 0, data.Length);
+            bytes[data.Length] = (byte)(c & 0xFF);
+            bytes[data.Length + 1] = (byte)(c >> 8 & 0xFF);
+            return new SimpleString(bytes);
+        }
+
+        public static int SizeofString(SimpleString str)
+        {
+
+            return DataConstants.SIZE_INT + str.data.Length;
+        }
+
+        public static int SizeofNullableString(SimpleString str)
+        {
+            if (str == null)
+            {
+                return 1;
+            }
+            else
+            {
+                return 1 + SizeofString(str);
+            }
+        }
+
+        public void GetChars(int srcBegin, int srcEnd, char[] dst, int dstBegin)
+        {
+            if (srcBegin < 0)
+            {
+                throw new IndexOutOfRangeException("Invalid initialIndex: " + srcBegin);
+            }
+            if (srcEnd > this.Length)
+            {
+                throw new IndexOutOfRangeException("Invalid endIndex: " + srcEnd);
+            }
+            if (srcBegin > srcEnd)
+            {
+                throw new IndexOutOfRangeException("Invalid Length: " + (srcEnd - srcBegin));
+            }
+
+            int j = 0;
+
+            for (int i = srcBegin; i < srcEnd - srcBegin; i++)
+            {
+                int low = data[j++] & 0xFF;
+
+                int high = (data[j++] << 8) & 0xFF00;
+
+                dst[i] = (char)(low | high);
+            }
+        }
+
+    }
+}

Deleted: trunk/dotnet/JBMClientSolution.sln
===================================================================
--- trunk/dotnet/JBMClientSolution.sln	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClientSolution.sln	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,41 +0,0 @@
-
-Microsoft Visual Studio Solution File, Format Version 10.00
-# Visual Studio 2008
-Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{18364D7F-A814-4360-9BF1-FBD18737B399}"
-	ProjectSection(SolutionItems) = preProject
-		JBMClientSolution.vsmdi = JBMClientSolution.vsmdi
-		JBMClient.vsmdi = JBMClient.vsmdi
-		LocalTestRun.testrunconfig = LocalTestRun.testrunconfig
-	EndProjectSection
-EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "JBM.Client", "JBMClient\JBM.Client.csproj", "{675AD929-BF42-4930-AC39-603D5EC52D58}"
-EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "JBM.Client.Test", "JBMClientTest\JBM.Client.Test.csproj", "{D6A96159-0551-41C2-9E94-1F253F79AD39}"
-EndProject
-Global
-	GlobalSection(SubversionScc) = preSolution
-		Svn-Managed = True
-		Manager = AnkhSVN - Subversion Support for Visual Studio
-	EndGlobalSection
-	GlobalSection(SolutionConfigurationPlatforms) = preSolution
-		Debug|Any CPU = Debug|Any CPU
-		Release|Any CPU = Release|Any CPU
-	EndGlobalSection
-	GlobalSection(ProjectConfigurationPlatforms) = postSolution
-		{675AD929-BF42-4930-AC39-603D5EC52D58}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
-		{675AD929-BF42-4930-AC39-603D5EC52D58}.Debug|Any CPU.Build.0 = Debug|Any CPU
-		{675AD929-BF42-4930-AC39-603D5EC52D58}.Release|Any CPU.ActiveCfg = Release|Any CPU
-		{675AD929-BF42-4930-AC39-603D5EC52D58}.Release|Any CPU.Build.0 = Release|Any CPU
-		{D6A96159-0551-41C2-9E94-1F253F79AD39}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
-		{D6A96159-0551-41C2-9E94-1F253F79AD39}.Debug|Any CPU.Build.0 = Debug|Any CPU
-		{D6A96159-0551-41C2-9E94-1F253F79AD39}.Release|Any CPU.ActiveCfg = Release|Any CPU
-		{D6A96159-0551-41C2-9E94-1F253F79AD39}.Release|Any CPU.Build.0 = Release|Any CPU
-	EndGlobalSection
-	GlobalSection(SolutionProperties) = preSolution
-		HideSolutionNode = FALSE
-	EndGlobalSection
-	GlobalSection(NestedProjects) = preSolution
-		{675AD929-BF42-4930-AC39-603D5EC52D58} = {18364D7F-A814-4360-9BF1-FBD18737B399}
-		{D6A96159-0551-41C2-9E94-1F253F79AD39} = {18364D7F-A814-4360-9BF1-FBD18737B399}
-	EndGlobalSection
-EndGlobal

Copied: trunk/dotnet/JBMClientSolution.sln (from rev 5824, trunk/dotnet/JBMClientSolution.sln)
===================================================================
--- trunk/dotnet/JBMClientSolution.sln	                        (rev 0)
+++ trunk/dotnet/JBMClientSolution.sln	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,41 @@
+
+Microsoft Visual Studio Solution File, Format Version 10.00
+# Visual Studio 2008
+Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{18364D7F-A814-4360-9BF1-FBD18737B399}"
+	ProjectSection(SolutionItems) = preProject
+		JBMClientSolution.vsmdi = JBMClientSolution.vsmdi
+		JBMClient.vsmdi = JBMClient.vsmdi
+		LocalTestRun.testrunconfig = LocalTestRun.testrunconfig
+	EndProjectSection
+EndProject
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "JBM.Client", "JBMClient\JBM.Client.csproj", "{675AD929-BF42-4930-AC39-603D5EC52D58}"
+EndProject
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "JBM.Client.Test", "JBMClientTest\JBM.Client.Test.csproj", "{D6A96159-0551-41C2-9E94-1F253F79AD39}"
+EndProject
+Global
+	GlobalSection(SubversionScc) = preSolution
+		Svn-Managed = True
+		Manager = AnkhSVN - Subversion Support for Visual Studio
+	EndGlobalSection
+	GlobalSection(SolutionConfigurationPlatforms) = preSolution
+		Debug|Any CPU = Debug|Any CPU
+		Release|Any CPU = Release|Any CPU
+	EndGlobalSection
+	GlobalSection(ProjectConfigurationPlatforms) = postSolution
+		{675AD929-BF42-4930-AC39-603D5EC52D58}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+		{675AD929-BF42-4930-AC39-603D5EC52D58}.Debug|Any CPU.Build.0 = Debug|Any CPU
+		{675AD929-BF42-4930-AC39-603D5EC52D58}.Release|Any CPU.ActiveCfg = Release|Any CPU
+		{675AD929-BF42-4930-AC39-603D5EC52D58}.Release|Any CPU.Build.0 = Release|Any CPU
+		{D6A96159-0551-41C2-9E94-1F253F79AD39}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+		{D6A96159-0551-41C2-9E94-1F253F79AD39}.Debug|Any CPU.Build.0 = Debug|Any CPU
+		{D6A96159-0551-41C2-9E94-1F253F79AD39}.Release|Any CPU.ActiveCfg = Release|Any CPU
+		{D6A96159-0551-41C2-9E94-1F253F79AD39}.Release|Any CPU.Build.0 = Release|Any CPU
+	EndGlobalSection
+	GlobalSection(SolutionProperties) = preSolution
+		HideSolutionNode = FALSE
+	EndGlobalSection
+	GlobalSection(NestedProjects) = preSolution
+		{675AD929-BF42-4930-AC39-603D5EC52D58} = {18364D7F-A814-4360-9BF1-FBD18737B399}
+		{D6A96159-0551-41C2-9E94-1F253F79AD39} = {18364D7F-A814-4360-9BF1-FBD18737B399}
+	EndGlobalSection
+EndGlobal

Deleted: trunk/dotnet/JBMClientSolution.vsmdi
===================================================================
--- trunk/dotnet/JBMClientSolution.vsmdi	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClientSolution.vsmdi	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,6 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<TestLists xmlns="http://microsoft.com/schemas/VisualStudio/TeamTest/2006">
-  <TestList name="Lists of Tests" id="8c43106b-9dc1-4907-a29f-aa66a61bf5b6">
-    <RunConfiguration id="59754eb7-8ee4-4c36-922b-c01d7bda161b" name="Local Test Run" storage="localtestrun.testrunconfig" type="Microsoft.VisualStudio.TestTools.Common.TestRunConfiguration, Microsoft.VisualStudio.QualityTools.Common,   PublicKeyToken=b03f5f7f11d50a3a" />
-  </TestList>
-</TestLists>
\ No newline at end of file

Copied: trunk/dotnet/JBMClientSolution.vsmdi (from rev 5824, trunk/dotnet/JBMClientSolution.vsmdi)
===================================================================
--- trunk/dotnet/JBMClientSolution.vsmdi	                        (rev 0)
+++ trunk/dotnet/JBMClientSolution.vsmdi	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,6 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<TestLists xmlns="http://microsoft.com/schemas/VisualStudio/TeamTest/2006">
+  <TestList name="Lists of Tests" id="8c43106b-9dc1-4907-a29f-aa66a61bf5b6">
+    <RunConfiguration id="59754eb7-8ee4-4c36-922b-c01d7bda161b" name="Local Test Run" storage="localtestrun.testrunconfig" type="Microsoft.VisualStudio.TestTools.Common.TestRunConfiguration, Microsoft.VisualStudio.QualityTools.Common,   PublicKeyToken=b03f5f7f11d50a3a" />
+  </TestList>
+</TestLists>
\ No newline at end of file

Copied: trunk/dotnet/JBMClientTest (from rev 5824, trunk/dotnet/JBMClientTest)


Property changes on: trunk/dotnet/JBMClientTest
___________________________________________________________________
Name: svn:ignore
   + bin
obj


Deleted: trunk/dotnet/JBMClientTest/AuthoringTests.txt
===================================================================
--- trunk/dotnet/JBMClientTest/AuthoringTests.txt	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClientTest/AuthoringTests.txt	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,136 +0,0 @@
-==========================================================================
-    Visual Studio Team System: Overview of Authoring and Running Tests    
-==========================================================================
-
-This overview describes the features for authoring and running tests in 
-Visual Studio Team System and Visual Studio Team Edition for Software Testers.
-
-Opening Tests
--------------
-To open a test, open a test project or a test metadata file (a file with
-extension .vsmdi) that contains the definition of the test. You can find
-test projects and metadata files in Solution Explorer.
-
-Viewing Tests
--------------
-To see which tests are available to you, open the Test View window. Or,
-if you have installed Team Edition for Software Testers, you can also open
-the Test List Editor window to view tests.
-
-To open the Test View window, click the Test menu, point to Windows, and
-then click Test View. To open the Test List Editor window (if you have
-installed Team Edition for Software Testers), click Test, point to Windows,
-and then click Test List Editor.
-
-Running Tests
--------------
-You can run tests from the Test View window and the Test List Editor window.
-See Viewing Tests to learn how to open these windows. To run one or more
-tests displayed in the Test View window, first select the tests in that
-window; to select multiple tests, hold either the Shift or CTRL key while
-clicking tests. Then click the Run Tests button in the Test View window
-toolbar.
-
-If you have installed Visual Studio Team Edition for Software Testers, you can
-also use the Test List Editor window to run tests. To run tests in Test List Editor,
-select the check box next to each test that you want to run. Then click the
-Run Tests button in the Test List Editor window toolbar.
-
-Viewing Test Results
---------------------
-When you run a test or a series of tests, the results of the test run will be
-shown in the Test Results window. Each individual test in the run is shown on
-a separate line so that you can see its status. The window contains an
-embedded status bar in the top half of the window that provides you with
-summary details of the complete test run.
-
-To see more detailed results for a particular test result, double-click it in
-the Test Results window. This opens a window that provides more information
-about the particular test result, such as any specific error messages returned
-by the test.
-
-Changing the way that tests are run
------------------------------------
-Each time you run one or more tests, a collection of settings is used to
-determine how those tests are run. These settings are contained in a “test
-run configuration” file.
-
-Here is a partial list of the changes you can make with a test run 
-configuration file:
-
- - Change the naming scheme for each test run.
- - Change the test controller that the tests are run on so that you can run
-   tests remotely.
- - Gather code coverage data for the code being tested so that you can see
-   which lines of code are covered by your tests.
- - Enable and disable test deployment. 
- - Specify additional files to deploy before tests are run.
- - Select a different host, ASP.NET, for running ASP.NET unit tests.
- - Select a different host, the smart device test host, for running smart device unit tests.
- - Set various properties for the test agents that run your tests.
- - Run custom scripts at the start and end of each test run so that you can
-   set up the test environment exactly as required each time tests are run.
- - Set time limits for tests and test runs.
- - Set the browser mix and the number of times to repeat Web tests in the
-   test run.
-
-By default, a test run configuration file is created whenever you create a
-new test project. You make changes to this file by double-clicking it in 
-Solution Explorer and then changing its settings. (Test run configuration
-files have the extension .testrunconfig.)
-
-A solution can contain multiple test run configuration files. Only one of
-those files, known as the “Active” test run configuration file, is used to
-determine the settings that are currently used for test runs. You select
-the active test run configuration by clicking Select Active Test Run 
-Configuration on the Test menu.
-
--------------------------------------------------------------------------------
-
-Test Types
-----------
-Using Visual Studio Team Edition for Software Testers, you can create a number
-of different test types:
-
-Unit test: Use a unit test to create a programmatic test in C++, Visual C# or
-Visual Basic that exercises source code. A unit test calls the methods of a
-class, passing suitable parameters, and verifies that the returned value is
-what you expect.
-There are three specialized variants of unit tests:
- - Data-driven unit tests are created when you configure a unit test to be
-   called repeatedly for each row of a data source. The data from each row
-   is used by the unit test as input data.
- - ASP.NET unit tests are unit tests that exercise code in an ASP.NET Web
-   application.
- - Smart device unit tests are unit tests that are deployed to a smart device
-   or emulator and then executed by the smart device test host.  
-
-Web Test: Web tests consist of an ordered series of HTTP requests that you
-record in a browser session using Microsoft Internet Explorer. You can have
-the test report specific details about the pages or sites it requests, such
-as whether a particular page contains a specified string.
-
-Load Test: You use a load test to encapsulate non-manual tests, such as
-unit, Web, and generic tests, and then run them simultaneously by using
-virtual users. Running these tests under load generates test results,
-including performance and other counters, in tables and in graphs.
-
-Generic test: A generic test is an existing program wrapped to function as a
-test in Visual Studio. The following are examples of tests or programs that
-you can turn into generic tests:
- - An existing test that uses process exit codes to communicate whether the
-   test passed or failed. 0 indicates passing and any other value indicates
-   a failure.
- - A general program to obtain specific functionality during a test scenario.
- - A test or program that uses a special XML file (called a “summary results
-   file”), to communicate detailed results.
-
-Manual test: The manual test type is used when the test tasks are to be
-completed by a test engineer as opposed to an automated script.
-
-Ordered test: Use an ordered test to execute a set of tests in an order you
-specify.
-
--------------------------------------------------------------------------------
-
-

Copied: trunk/dotnet/JBMClientTest/AuthoringTests.txt (from rev 5824, trunk/dotnet/JBMClientTest/AuthoringTests.txt)
===================================================================
--- trunk/dotnet/JBMClientTest/AuthoringTests.txt	                        (rev 0)
+++ trunk/dotnet/JBMClientTest/AuthoringTests.txt	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,136 @@
+==========================================================================
+    Visual Studio Team System: Overview of Authoring and Running Tests    
+==========================================================================
+
+This overview describes the features for authoring and running tests in 
+Visual Studio Team System and Visual Studio Team Edition for Software Testers.
+
+Opening Tests
+-------------
+To open a test, open a test project or a test metadata file (a file with
+extension .vsmdi) that contains the definition of the test. You can find
+test projects and metadata files in Solution Explorer.
+
+Viewing Tests
+-------------
+To see which tests are available to you, open the Test View window. Or,
+if you have installed Team Edition for Software Testers, you can also open
+the Test List Editor window to view tests.
+
+To open the Test View window, click the Test menu, point to Windows, and
+then click Test View. To open the Test List Editor window (if you have
+installed Team Edition for Software Testers), click Test, point to Windows,
+and then click Test List Editor.
+
+Running Tests
+-------------
+You can run tests from the Test View window and the Test List Editor window.
+See Viewing Tests to learn how to open these windows. To run one or more
+tests displayed in the Test View window, first select the tests in that
+window; to select multiple tests, hold either the Shift or CTRL key while
+clicking tests. Then click the Run Tests button in the Test View window
+toolbar.
+
+If you have installed Visual Studio Team Edition for Software Testers, you can
+also use the Test List Editor window to run tests. To run tests in Test List Editor,
+select the check box next to each test that you want to run. Then click the
+Run Tests button in the Test List Editor window toolbar.
+
+Viewing Test Results
+--------------------
+When you run a test or a series of tests, the results of the test run will be
+shown in the Test Results window. Each individual test in the run is shown on
+a separate line so that you can see its status. The window contains an
+embedded status bar in the top half of the window that provides you with
+summary details of the complete test run.
+
+To see more detailed results for a particular test result, double-click it in
+the Test Results window. This opens a window that provides more information
+about the particular test result, such as any specific error messages returned
+by the test.
+
+Changing the way that tests are run
+-----------------------------------
+Each time you run one or more tests, a collection of settings is used to
+determine how those tests are run. These settings are contained in a “test
+run configuration” file.
+
+Here is a partial list of the changes you can make with a test run 
+configuration file:
+
+ - Change the naming scheme for each test run.
+ - Change the test controller that the tests are run on so that you can run
+   tests remotely.
+ - Gather code coverage data for the code being tested so that you can see
+   which lines of code are covered by your tests.
+ - Enable and disable test deployment. 
+ - Specify additional files to deploy before tests are run.
+ - Select a different host, ASP.NET, for running ASP.NET unit tests.
+ - Select a different host, the smart device test host, for running smart device unit tests.
+ - Set various properties for the test agents that run your tests.
+ - Run custom scripts at the start and end of each test run so that you can
+   set up the test environment exactly as required each time tests are run.
+ - Set time limits for tests and test runs.
+ - Set the browser mix and the number of times to repeat Web tests in the
+   test run.
+
+By default, a test run configuration file is created whenever you create a
+new test project. You make changes to this file by double-clicking it in 
+Solution Explorer and then changing its settings. (Test run configuration
+files have the extension .testrunconfig.)
+
+A solution can contain multiple test run configuration files. Only one of
+those files, known as the “Active” test run configuration file, is used to
+determine the settings that are currently used for test runs. You select
+the active test run configuration by clicking Select Active Test Run 
+Configuration on the Test menu.
+
+-------------------------------------------------------------------------------
+
+Test Types
+----------
+Using Visual Studio Team Edition for Software Testers, you can create a number
+of different test types:
+
+Unit test: Use a unit test to create a programmatic test in C++, Visual C# or
+Visual Basic that exercises source code. A unit test calls the methods of a
+class, passing suitable parameters, and verifies that the returned value is
+what you expect.
+There are three specialized variants of unit tests:
+ - Data-driven unit tests are created when you configure a unit test to be
+   called repeatedly for each row of a data source. The data from each row
+   is used by the unit test as input data.
+ - ASP.NET unit tests are unit tests that exercise code in an ASP.NET Web
+   application.
+ - Smart device unit tests are unit tests that are deployed to a smart device
+   or emulator and then executed by the smart device test host.  
+
+Web Test: Web tests consist of an ordered series of HTTP requests that you
+record in a browser session using Microsoft Internet Explorer. You can have
+the test report specific details about the pages or sites it requests, such
+as whether a particular page contains a specified string.
+
+Load Test: You use a load test to encapsulate non-manual tests, such as
+unit, Web, and generic tests, and then run them simultaneously by using
+virtual users. Running these tests under load generates test results,
+including performance and other counters, in tables and in graphs.
+
+Generic test: A generic test is an existing program wrapped to function as a
+test in Visual Studio. The following are examples of tests or programs that
+you can turn into generic tests:
+ - An existing test that uses process exit codes to communicate whether the
+   test passed or failed. 0 indicates passing and any other value indicates
+   a failure.
+ - A general program to obtain specific functionality during a test scenario.
+ - A test or program that uses a special XML file (called a “summary results
+   file”), to communicate detailed results.
+
+Manual test: The manual test type is used when the test tasks are to be
+completed by a test engineer as opposed to an automated script.
+
+Ordered test: Use an ordered test to execute a set of tests in an order you
+specify.
+
+-------------------------------------------------------------------------------
+
+

Deleted: trunk/dotnet/JBMClientTest/JBM.Client.Test.csproj
===================================================================
--- trunk/dotnet/JBMClientTest/JBM.Client.Test.csproj	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClientTest/JBM.Client.Test.csproj	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,77 +0,0 @@
-<Project ToolsVersion="3.5" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
-  <PropertyGroup>
-    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
-    <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
-    <ProductVersion>9.0.21022</ProductVersion>
-    <SchemaVersion>2.0</SchemaVersion>
-    <ProjectGuid>{D6A96159-0551-41C2-9E94-1F253F79AD39}</ProjectGuid>
-    <OutputType>Library</OutputType>
-    <AppDesignerFolder>Properties</AppDesignerFolder>
-    <RootNamespace>JBM.Client.Test</RootNamespace>
-    <AssemblyName>JBM.Client.Test</AssemblyName>
-    <TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
-    <FileAlignment>512</FileAlignment>
-    <ProjectTypeGuids>{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
-    <StartupObject>
-    </StartupObject>
-    <ApplicationIcon>
-    </ApplicationIcon>
-  </PropertyGroup>
-  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
-    <DebugSymbols>true</DebugSymbols>
-    <DebugType>full</DebugType>
-    <Optimize>false</Optimize>
-    <OutputPath>bin\Debug\</OutputPath>
-    <DefineConstants>DEBUG;TRACE</DefineConstants>
-    <ErrorReport>prompt</ErrorReport>
-    <WarningLevel>4</WarningLevel>
-    <OutputType>Library</OutputType>
-    <AssemblyName>JBMClientTest</AssemblyName>
-    <RootNamespace>JBMClientTest</RootNamespace>
-    <AllowUnsafeBlocks>false</AllowUnsafeBlocks>
-    <CheckForOverflowUnderflow>true</CheckForOverflowUnderflow>
-  </PropertyGroup>
-  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
-    <DebugType>pdbonly</DebugType>
-    <Optimize>true</Optimize>
-    <OutputPath>bin\Release\</OutputPath>
-    <DefineConstants>TRACE</DefineConstants>
-    <ErrorReport>prompt</ErrorReport>
-    <WarningLevel>4</WarningLevel>
-    <OutputType>Library</OutputType>
-    <AssemblyName>JBMClientTest</AssemblyName>
-    <DebugSymbols>true</DebugSymbols>
-    <RootNamespace>JBMClientTest</RootNamespace>
-    <AllowUnsafeBlocks>false</AllowUnsafeBlocks>
-    <CheckForOverflowUnderflow>true</CheckForOverflowUnderflow>
-  </PropertyGroup>
-  <ItemGroup>
-    <Reference Include="nunit.framework, Version=2.4.8.0, Culture=neutral, PublicKeyToken=96d09a1eb7f44a77" />
-    <Reference Include="System" />
-    <Reference Include="System.Core">
-      <RequiredTargetFramework>3.5</RequiredTargetFramework>
-    </Reference>
-  </ItemGroup>
-  <ItemGroup>
-    <Compile Include="Properties\AssemblyInfo.cs" />
-    <Compile Include="util\JBMTest.cs" />
-    <Compile Include="util\SimpleStringTest.cs" />
-  </ItemGroup>
-  <ItemGroup>
-    <Content Include="AuthoringTests.txt" />
-  </ItemGroup>
-  <ItemGroup>
-    <ProjectReference Include="..\JBMClient\JBM.Client.csproj">
-      <Project>{675AD929-BF42-4930-AC39-603D5EC52D58}</Project>
-      <Name>JBM.Client</Name>
-    </ProjectReference>
-  </ItemGroup>
-  <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
-  <!-- To modify your build process, add your task inside one of the targets below and uncomment it. 
-       Other similar extension points exist, see Microsoft.Common.targets.
-  <Target Name="BeforeBuild">
-  </Target>
-  <Target Name="AfterBuild">
-  </Target>
-  -->
-</Project>
\ No newline at end of file

Copied: trunk/dotnet/JBMClientTest/JBM.Client.Test.csproj (from rev 5824, trunk/dotnet/JBMClientTest/JBM.Client.Test.csproj)
===================================================================
--- trunk/dotnet/JBMClientTest/JBM.Client.Test.csproj	                        (rev 0)
+++ trunk/dotnet/JBMClientTest/JBM.Client.Test.csproj	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,77 @@
+<Project ToolsVersion="3.5" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <PropertyGroup>
+    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
+    <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
+    <ProductVersion>9.0.21022</ProductVersion>
+    <SchemaVersion>2.0</SchemaVersion>
+    <ProjectGuid>{D6A96159-0551-41C2-9E94-1F253F79AD39}</ProjectGuid>
+    <OutputType>Library</OutputType>
+    <AppDesignerFolder>Properties</AppDesignerFolder>
+    <RootNamespace>JBM.Client.Test</RootNamespace>
+    <AssemblyName>JBM.Client.Test</AssemblyName>
+    <TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
+    <FileAlignment>512</FileAlignment>
+    <ProjectTypeGuids>{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
+    <StartupObject>
+    </StartupObject>
+    <ApplicationIcon>
+    </ApplicationIcon>
+  </PropertyGroup>
+  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
+    <DebugSymbols>true</DebugSymbols>
+    <DebugType>full</DebugType>
+    <Optimize>false</Optimize>
+    <OutputPath>bin\Debug\</OutputPath>
+    <DefineConstants>DEBUG;TRACE</DefineConstants>
+    <ErrorReport>prompt</ErrorReport>
+    <WarningLevel>4</WarningLevel>
+    <OutputType>Library</OutputType>
+    <AssemblyName>JBMClientTest</AssemblyName>
+    <RootNamespace>JBMClientTest</RootNamespace>
+    <AllowUnsafeBlocks>false</AllowUnsafeBlocks>
+    <CheckForOverflowUnderflow>true</CheckForOverflowUnderflow>
+  </PropertyGroup>
+  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
+    <DebugType>pdbonly</DebugType>
+    <Optimize>true</Optimize>
+    <OutputPath>bin\Release\</OutputPath>
+    <DefineConstants>TRACE</DefineConstants>
+    <ErrorReport>prompt</ErrorReport>
+    <WarningLevel>4</WarningLevel>
+    <OutputType>Library</OutputType>
+    <AssemblyName>JBMClientTest</AssemblyName>
+    <DebugSymbols>true</DebugSymbols>
+    <RootNamespace>JBMClientTest</RootNamespace>
+    <AllowUnsafeBlocks>false</AllowUnsafeBlocks>
+    <CheckForOverflowUnderflow>true</CheckForOverflowUnderflow>
+  </PropertyGroup>
+  <ItemGroup>
+    <Reference Include="nunit.framework, Version=2.4.8.0, Culture=neutral, PublicKeyToken=96d09a1eb7f44a77" />
+    <Reference Include="System" />
+    <Reference Include="System.Core">
+      <RequiredTargetFramework>3.5</RequiredTargetFramework>
+    </Reference>
+  </ItemGroup>
+  <ItemGroup>
+    <Compile Include="Properties\AssemblyInfo.cs" />
+    <Compile Include="util\JBMTest.cs" />
+    <Compile Include="util\SimpleStringTest.cs" />
+  </ItemGroup>
+  <ItemGroup>
+    <Content Include="AuthoringTests.txt" />
+  </ItemGroup>
+  <ItemGroup>
+    <ProjectReference Include="..\JBMClient\JBM.Client.csproj">
+      <Project>{675AD929-BF42-4930-AC39-603D5EC52D58}</Project>
+      <Name>JBM.Client</Name>
+    </ProjectReference>
+  </ItemGroup>
+  <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
+  <!-- To modify your build process, add your task inside one of the targets below and uncomment it. 
+       Other similar extension points exist, see Microsoft.Common.targets.
+  <Target Name="BeforeBuild">
+  </Target>
+  <Target Name="AfterBuild">
+  </Target>
+  -->
+</Project>
\ No newline at end of file

Deleted: trunk/dotnet/JBMClientTest/JBMClientTest.userprefs
===================================================================
--- trunk/dotnet/JBMClientTest/JBMClientTest.userprefs	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClientTest/JBMClientTest.userprefs	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,22 +0,0 @@
-<UserCombinePreferences version="1.0" filename="/tmp/dotnet/JBMClientTest/JBMClientTest.mds">
-  <Files>
-    <File name="Welcome" />
-  </Files>
-  <Views>
-    <ViewMemento id="ProjectPad">
-      <Node expanded="True">
-        <Node name="JBMClientTest" expanded="True" />
-      </Node>
-    </ViewMemento>
-    <ViewMemento id="ClassPad">
-      <Node expanded="True" />
-    </ViewMemento>
-    <ViewMemento id="MonoDevelop.NUnit.TestPad">
-      <Node />
-    </ViewMemento>
-  </Views>
-  <Properties>
-    <Property key="ActiveWindow" value="Welcome" />
-    <Property key="ActiveConfiguration" value="Debug|Any CPU" />
-  </Properties>
-</UserCombinePreferences>
\ No newline at end of file

Copied: trunk/dotnet/JBMClientTest/JBMClientTest.userprefs (from rev 5824, trunk/dotnet/JBMClientTest/JBMClientTest.userprefs)
===================================================================
--- trunk/dotnet/JBMClientTest/JBMClientTest.userprefs	                        (rev 0)
+++ trunk/dotnet/JBMClientTest/JBMClientTest.userprefs	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,22 @@
+<UserCombinePreferences version="1.0" filename="/tmp/dotnet/JBMClientTest/JBMClientTest.mds">
+  <Files>
+    <File name="Welcome" />
+  </Files>
+  <Views>
+    <ViewMemento id="ProjectPad">
+      <Node expanded="True">
+        <Node name="JBMClientTest" expanded="True" />
+      </Node>
+    </ViewMemento>
+    <ViewMemento id="ClassPad">
+      <Node expanded="True" />
+    </ViewMemento>
+    <ViewMemento id="MonoDevelop.NUnit.TestPad">
+      <Node />
+    </ViewMemento>
+  </Views>
+  <Properties>
+    <Property key="ActiveWindow" value="Welcome" />
+    <Property key="ActiveConfiguration" value="Debug|Any CPU" />
+  </Properties>
+</UserCombinePreferences>
\ No newline at end of file

Copied: trunk/dotnet/JBMClientTest/Properties (from rev 5824, trunk/dotnet/JBMClientTest/Properties)

Deleted: trunk/dotnet/JBMClientTest/Properties/AssemblyInfo.cs
===================================================================
--- trunk/dotnet/JBMClientTest/Properties/AssemblyInfo.cs	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClientTest/Properties/AssemblyInfo.cs	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,35 +0,0 @@
-using System.Reflection;
-using System.Runtime.CompilerServices;
-using System.Runtime.InteropServices;
-
-// General Information about an assembly is controlled through the following 
-// set of attributes. Change these attribute values to modify the information
-// associated with an assembly.
-[assembly: AssemblyTitle("JMSClientTest")]
-[assembly: AssemblyDescription("")]
-[assembly: AssemblyConfiguration("")]
-[assembly: AssemblyCompany("")]
-[assembly: AssemblyProduct("JMSClientTest")]
-[assembly: AssemblyCopyright("Copyright ©  2009")]
-[assembly: AssemblyTrademark("")]
-[assembly: AssemblyCulture("")]
-
-// Setting ComVisible to false makes the types in this assembly not visible 
-// to COM componenets.  If you need to access a type in this assembly from 
-// COM, set the ComVisible attribute to true on that type.
-[assembly: ComVisible(false)]
-
-// The following GUID is for the ID of the typelib if this project is exposed to COM
-[assembly: Guid("29860c42-cd01-4298-8e76-a461e9d72cf2")]
-
-// Version information for an assembly consists of the following four values:
-//
-//      Major Version
-//      Minor Version 
-//      Build Number
-//      Revision
-//
-// You can specify all the values or you can default the Revision and Build Numbers 
-// by using the '*' as shown below:
-[assembly: AssemblyVersion("1.0.0.0")]
-[assembly: AssemblyFileVersion("1.0.0.0")]

Copied: trunk/dotnet/JBMClientTest/Properties/AssemblyInfo.cs (from rev 5824, trunk/dotnet/JBMClientTest/Properties/AssemblyInfo.cs)
===================================================================
--- trunk/dotnet/JBMClientTest/Properties/AssemblyInfo.cs	                        (rev 0)
+++ trunk/dotnet/JBMClientTest/Properties/AssemblyInfo.cs	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,35 @@
+using System.Reflection;
+using System.Runtime.CompilerServices;
+using System.Runtime.InteropServices;
+
+// General Information about an assembly is controlled through the following 
+// set of attributes. Change these attribute values to modify the information
+// associated with an assembly.
+[assembly: AssemblyTitle("JMSClientTest")]
+[assembly: AssemblyDescription("")]
+[assembly: AssemblyConfiguration("")]
+[assembly: AssemblyCompany("")]
+[assembly: AssemblyProduct("JMSClientTest")]
+[assembly: AssemblyCopyright("Copyright ©  2009")]
+[assembly: AssemblyTrademark("")]
+[assembly: AssemblyCulture("")]
+
+// Setting ComVisible to false makes the types in this assembly not visible 
+// to COM componenets.  If you need to access a type in this assembly from 
+// COM, set the ComVisible attribute to true on that type.
+[assembly: ComVisible(false)]
+
+// The following GUID is for the ID of the typelib if this project is exposed to COM
+[assembly: Guid("29860c42-cd01-4298-8e76-a461e9d72cf2")]
+
+// Version information for an assembly consists of the following four values:
+//
+//      Major Version
+//      Minor Version 
+//      Build Number
+//      Revision
+//
+// You can specify all the values or you can default the Revision and Build Numbers 
+// by using the '*' as shown below:
+[assembly: AssemblyVersion("1.0.0.0")]
+[assembly: AssemblyFileVersion("1.0.0.0")]

Copied: trunk/dotnet/JBMClientTest/util (from rev 5824, trunk/dotnet/JBMClientTest/util)

Deleted: trunk/dotnet/JBMClientTest/util/JBMTest.cs
===================================================================
--- trunk/dotnet/JBMClientTest/util/JBMTest.cs	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClientTest/util/JBMTest.cs	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,43 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using NUnit.Framework;
-
-namespace JBoss.JBM.Test.util
-{
-    public class JBMTest
-    {
-        public void assertTrue(bool value)
-        {
-            Assert.IsTrue(value);
-        }
-
-        public void assertFalse(bool value)
-        {
-            Assert.IsFalse(value);
-        }
-
-
-        public void assertEquals(Object obj, Object obj2)
-        {
-            Assert.AreEqual(obj, obj2);
-        }
-
-        public void fail(string message)
-        {
-            Assert.Fail(message);
-        }
-
-        public string randomString()
-        {
-            // FIXME : implement this
-            return "implement-me please";
-        }
-
-        public void assertNotNull(Object value)
-        {
-            Assert.IsNotNull(value);
-        }
-    }
-}

Copied: trunk/dotnet/JBMClientTest/util/JBMTest.cs (from rev 5824, trunk/dotnet/JBMClientTest/util/JBMTest.cs)
===================================================================
--- trunk/dotnet/JBMClientTest/util/JBMTest.cs	                        (rev 0)
+++ trunk/dotnet/JBMClientTest/util/JBMTest.cs	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,43 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using NUnit.Framework;
+
+namespace JBoss.JBM.Test.util
+{
+    public class JBMTest
+    {
+        public void assertTrue(bool value)
+        {
+            Assert.IsTrue(value);
+        }
+
+        public void assertFalse(bool value)
+        {
+            Assert.IsFalse(value);
+        }
+
+
+        public void assertEquals(Object obj, Object obj2)
+        {
+            Assert.AreEqual(obj, obj2);
+        }
+
+        public void fail(string message)
+        {
+            Assert.Fail(message);
+        }
+
+        public string randomString()
+        {
+            // FIXME : implement this
+            return "implement-me please";
+        }
+
+        public void assertNotNull(Object value)
+        {
+            Assert.IsNotNull(value);
+        }
+    }
+}

Deleted: trunk/dotnet/JBMClientTest/util/SimpleStringTest.cs
===================================================================
--- trunk/dotnet/JBMClientTest/util/SimpleStringTest.cs	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JBMClientTest/util/SimpleStringTest.cs	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,334 +0,0 @@
-using System;
-using System.Text;
-using System.Collections.Generic;
-using System.Linq;
-using NUnit.Framework;
-using JBoss.JBM.Client.util;
-
-namespace JBoss.JBM.Test.util
-{
-    /// <summary>
-    /// Summary description for SimpleStringTest
-    /// </summary>
-    [TestFixture]
-    public class SimpleStringTest : JBMTest
-    {
-        public SimpleStringTest()
-        {
-            //
-            // TODO: Add constructor logic here
-            //
-        }
-
-
-        [Test]
-        public void testString()
-        {
-            string str = "hello123ABC__524`16254`6125!%^$!%$!%$!%$!%!$%!$$!\uA324";
-
-            SimpleString s = new SimpleString(str);
-
-            assertEquals(str, s.ToString());
-
-            assertEquals(2 * str.Length, s.Data.Length);
-
-            byte[] data = s.Data;
-
-            SimpleString s2 = new SimpleString(data);
-
-            assertEquals(str, s2.ToString());
-        }
-
-        [Test]
-        public void testStartsWith()
-        {
-            SimpleString s1 = new SimpleString("abcdefghi");
-
-            assertTrue(s1.StartsWith(new SimpleString("abc")));
-
-            assertTrue(s1.StartsWith(new SimpleString("abcdef")));
-
-            assertTrue(s1.StartsWith(new SimpleString("abcdefghi")));
-
-            assertFalse(s1.StartsWith(new SimpleString("abcdefghijklmn")));
-
-            assertFalse(s1.StartsWith(new SimpleString("aardvark")));
-
-            assertFalse(s1.StartsWith(new SimpleString("z")));
-        }
-
-        [Test]
-        public void testCharSequence()
-        {
-            string s = "abcdefghijkl";
-            SimpleString s1 = new SimpleString(s);
-
-            assertEquals('a', s1.CharAt(0));
-            assertEquals('b', s1.CharAt(1));
-            assertEquals('c', s1.CharAt(2));
-            assertEquals('k', s1.CharAt(10));
-            assertEquals('l', s1.CharAt(11));
-
-            try
-            {
-                s1.CharAt(-1);
-                fail("Should throw exception");
-            }
-            catch (IndexOutOfRangeException)
-            {
-                //OK
-            }
-
-            try
-            {
-                s1.CharAt(-2);
-                fail("Should throw exception");
-            }
-            catch (IndexOutOfRangeException)
-            {
-                //OK
-            }
-
-            try
-            {
-                s1.CharAt(s.Length);
-                fail("Should throw exception");
-            }
-            catch (IndexOutOfRangeException)
-            {
-                //OK
-            }
-
-            try
-            {
-                s1.CharAt(s.Length + 1);
-                fail("Should throw exception");
-            }
-            catch (IndexOutOfRangeException)
-            {
-                //OK
-            }
-
-            assertEquals(s.Length, s1.Length);
-
-            SimpleString ss = s1.SubSequence(0, s1.Length);
-
-            assertEquals(ss, s1);
-
-            ss = s1.SubSequence(1, 4);
-            assertEquals(ss, new SimpleString("bcd"));
-
-            ss = s1.SubSequence(5, 10);
-            assertEquals(ss, new SimpleString("fghij"));
-
-            ss = s1.SubSequence(5, 12);
-            assertEquals(ss, new SimpleString("fghijkl"));
-
-            try
-            {
-                s1.SubSequence(-1, 2);
-                fail("Should throw exception");
-            }
-            catch (IndexOutOfRangeException)
-            {
-                //OK
-            }
-
-            try
-            {
-                s1.SubSequence(-4, -2);
-                fail("Should throw exception");
-            }
-            catch (IndexOutOfRangeException)
-            {
-                //OK
-            }
-
-            try
-            {
-                s1.SubSequence(0, s1.Length + 1);
-                fail("Should throw exception");
-            }
-            catch (IndexOutOfRangeException)
-            {
-                //OK
-            }
-
-            try
-            {
-                s1.SubSequence(0, s1.Length + 2);
-                fail("Should throw exception");
-            }
-            catch (IndexOutOfRangeException)
-            {
-                //OK
-            }
-
-            try
-            {
-                s1.SubSequence(5, 1);
-                fail("Should throw exception");
-            }
-            catch (IndexOutOfRangeException)
-            {
-                //OK
-            }
-        }
-
-        [Test]
-        public void testEquals()
-        {
-            assertFalse(new SimpleString("abcdef").Equals(new Object()));
-
-            assertEquals(new SimpleString("abcdef"), new SimpleString("abcdef"));
-
-            assertFalse(new SimpleString("abcdef").Equals(new SimpleString("abggcdef")));
-            assertFalse(new SimpleString("abcdef").Equals(new SimpleString("ghijkl")));
-        }
-
-        [Test]
-        public void testHashcode()
-        {
-            SimpleString str = new SimpleString("abcdef");
-            SimpleString sameStr = new SimpleString("abcdef");
-            SimpleString differentStr = new SimpleString("ghijk");
-
-            string tst = str.ToString();
-            tst.GetHashCode();
-
-            assertTrue(str.GetHashCode() == sameStr.GetHashCode());
-            assertFalse(str.GetHashCode() == differentStr.GetHashCode());
-
-        }
-
-        [Test]
-        public void testUnicode()
-        {
-            String myString = "abcdef&^*&!^ghijkl\uB5E2\uCAC7\uB2BB\uB7DD\uB7C7\uB3A3\uBCE4\uB5A5";
-
-            SimpleString s = new SimpleString(myString);
-            byte[] data = s.Data;
-            s = new SimpleString(data);
-
-            assertEquals(myString, s.ToString());
-        }
-
-        [Test]
-        public void testUnicodeWithSurrogates()
-        {
-            String myString = "abcdef&^*&!^ghijkl\uD900\uDD00";
-
-            SimpleString s = new SimpleString(myString);
-            byte[] data = s.Data;
-            s = new SimpleString(data);
-
-            assertEquals(myString, s.ToString());
-        }
-
-        [Test]
-        public void testSizeofString()
-        {
-            assertEquals(DataConstants.SIZE_INT, SimpleString.SizeofString(new SimpleString("")));
-
-            //FIXME: provide a randomString method
-            SimpleString str = new SimpleString(randomString());
-            assertEquals(DataConstants.SIZE_INT + str.Data.Length, SimpleString.SizeofString(str));
-        }
-
-        [Test]
-        public void testSizeofNullableString()
-        {
-            assertEquals(1, SimpleString.SizeofNullableString(null));
-
-            assertEquals(1 + DataConstants.SIZE_INT, SimpleString.SizeofNullableString(new SimpleString("")));
-
-            SimpleString str = new SimpleString(randomString());
-            assertEquals(1 + DataConstants.SIZE_INT + str.Data.Length, SimpleString.SizeofNullableString(str));
-        }
-
-        [Test]
-        public void testSplitNoDelimeter()
-        {
-            SimpleString s = new SimpleString("abcdefghi");
-            SimpleString[] strings = s.Split('.');
-            assertNotNull(strings);
-            assertEquals(strings.Length, 1);
-            assertEquals(strings[0], s);
-        }
-
-        [Test]
-        public void testSplit1Delimeter()
-        {
-            SimpleString s = new SimpleString("abcd.efghi");
-            SimpleString[] strings = s.Split('.');
-            assertNotNull(strings);
-            assertEquals(strings.Length, 2);
-            assertEquals(strings[0], new SimpleString("abcd"));
-            assertEquals(strings[1], new SimpleString("efghi"));
-        }
-
-        [Test]
-        public void testSplitmanyDelimeters()
-        {
-            SimpleString s = new SimpleString("abcd.efghi.jklmn.opqrs.tuvw.xyz");
-            SimpleString[] strings = s.Split('.');
-            assertNotNull(strings);
-            assertEquals(strings.Length, 6);
-            assertEquals(strings[0], new SimpleString("abcd"));
-            assertEquals(strings[1], new SimpleString("efghi"));
-            assertEquals(strings[2], new SimpleString("jklmn"));
-            assertEquals(strings[3], new SimpleString("opqrs"));
-            assertEquals(strings[4], new SimpleString("tuvw"));
-            assertEquals(strings[5], new SimpleString("xyz"));
-        }
-
-        [Test]
-        public void testContains()
-        {
-            SimpleString simpleString = new SimpleString("abcdefghijklmnopqrst");
-            assertFalse(simpleString.Contains('.'));
-            assertFalse(simpleString.Contains('%'));
-            assertFalse(simpleString.Contains('8'));
-            assertFalse(simpleString.Contains('.'));
-            assertTrue(simpleString.Contains('a'));
-            assertTrue(simpleString.Contains('b'));
-            assertTrue(simpleString.Contains('c'));
-            assertTrue(simpleString.Contains('d'));
-            assertTrue(simpleString.Contains('e'));
-            assertTrue(simpleString.Contains('f'));
-            assertTrue(simpleString.Contains('g'));
-            assertTrue(simpleString.Contains('h'));
-            assertTrue(simpleString.Contains('i'));
-            assertTrue(simpleString.Contains('j'));
-            assertTrue(simpleString.Contains('k'));
-            assertTrue(simpleString.Contains('l'));
-            assertTrue(simpleString.Contains('m'));
-            assertTrue(simpleString.Contains('n'));
-            assertTrue(simpleString.Contains('o'));
-            assertTrue(simpleString.Contains('p'));
-            assertTrue(simpleString.Contains('q'));
-            assertTrue(simpleString.Contains('r'));
-            assertTrue(simpleString.Contains('s'));
-            assertTrue(simpleString.Contains('t'));
-        }
-
-        [Test]
-        public void testConcat()
-        {
-            SimpleString start = new SimpleString("abcdefg");
-            SimpleString middle = new SimpleString("hijklmnop");
-            SimpleString end = new SimpleString("qrstuvwxyz");
-            assertEquals(start.Concat(middle).Concat(end), new SimpleString("abcdefghijklmnopqrstuvwxyz"));
-            assertEquals(start.Concat('.').Concat(end), new SimpleString("abcdefg.qrstuvwxyz"));
-        }
-
-        [Test]
-        public void testConcat33()
-        {
-            SimpleString start = new SimpleString("a");
-            SimpleString middle = new SimpleString("b");
-            assertEquals(start.Concat(middle).ToString(), new SimpleString("ab").ToString());
-        }
-    }
-
-}

Copied: trunk/dotnet/JBMClientTest/util/SimpleStringTest.cs (from rev 5824, trunk/dotnet/JBMClientTest/util/SimpleStringTest.cs)
===================================================================
--- trunk/dotnet/JBMClientTest/util/SimpleStringTest.cs	                        (rev 0)
+++ trunk/dotnet/JBMClientTest/util/SimpleStringTest.cs	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,334 @@
+using System;
+using System.Text;
+using System.Collections.Generic;
+using System.Linq;
+using NUnit.Framework;
+using JBoss.JBM.Client.util;
+
+namespace JBoss.JBM.Test.util
+{
+    /// <summary>
+    /// Summary description for SimpleStringTest
+    /// </summary>
+    [TestFixture]
+    public class SimpleStringTest : JBMTest
+    {
+        public SimpleStringTest()
+        {
+            //
+            // TODO: Add constructor logic here
+            //
+        }
+
+
+        [Test]
+        public void testString()
+        {
+            string str = "hello123ABC__524`16254`6125!%^$!%$!%$!%$!%!$%!$$!\uA324";
+
+            SimpleString s = new SimpleString(str);
+
+            assertEquals(str, s.ToString());
+
+            assertEquals(2 * str.Length, s.Data.Length);
+
+            byte[] data = s.Data;
+
+            SimpleString s2 = new SimpleString(data);
+
+            assertEquals(str, s2.ToString());
+        }
+
+        [Test]
+        public void testStartsWith()
+        {
+            SimpleString s1 = new SimpleString("abcdefghi");
+
+            assertTrue(s1.StartsWith(new SimpleString("abc")));
+
+            assertTrue(s1.StartsWith(new SimpleString("abcdef")));
+
+            assertTrue(s1.StartsWith(new SimpleString("abcdefghi")));
+
+            assertFalse(s1.StartsWith(new SimpleString("abcdefghijklmn")));
+
+            assertFalse(s1.StartsWith(new SimpleString("aardvark")));
+
+            assertFalse(s1.StartsWith(new SimpleString("z")));
+        }
+
+        [Test]
+        public void testCharSequence()
+        {
+            string s = "abcdefghijkl";
+            SimpleString s1 = new SimpleString(s);
+
+            assertEquals('a', s1.CharAt(0));
+            assertEquals('b', s1.CharAt(1));
+            assertEquals('c', s1.CharAt(2));
+            assertEquals('k', s1.CharAt(10));
+            assertEquals('l', s1.CharAt(11));
+
+            try
+            {
+                s1.CharAt(-1);
+                fail("Should throw exception");
+            }
+            catch (IndexOutOfRangeException)
+            {
+                //OK
+            }
+
+            try
+            {
+                s1.CharAt(-2);
+                fail("Should throw exception");
+            }
+            catch (IndexOutOfRangeException)
+            {
+                //OK
+            }
+
+            try
+            {
+                s1.CharAt(s.Length);
+                fail("Should throw exception");
+            }
+            catch (IndexOutOfRangeException)
+            {
+                //OK
+            }
+
+            try
+            {
+                s1.CharAt(s.Length + 1);
+                fail("Should throw exception");
+            }
+            catch (IndexOutOfRangeException)
+            {
+                //OK
+            }
+
+            assertEquals(s.Length, s1.Length);
+
+            SimpleString ss = s1.SubSequence(0, s1.Length);
+
+            assertEquals(ss, s1);
+
+            ss = s1.SubSequence(1, 4);
+            assertEquals(ss, new SimpleString("bcd"));
+
+            ss = s1.SubSequence(5, 10);
+            assertEquals(ss, new SimpleString("fghij"));
+
+            ss = s1.SubSequence(5, 12);
+            assertEquals(ss, new SimpleString("fghijkl"));
+
+            try
+            {
+                s1.SubSequence(-1, 2);
+                fail("Should throw exception");
+            }
+            catch (IndexOutOfRangeException)
+            {
+                //OK
+            }
+
+            try
+            {
+                s1.SubSequence(-4, -2);
+                fail("Should throw exception");
+            }
+            catch (IndexOutOfRangeException)
+            {
+                //OK
+            }
+
+            try
+            {
+                s1.SubSequence(0, s1.Length + 1);
+                fail("Should throw exception");
+            }
+            catch (IndexOutOfRangeException)
+            {
+                //OK
+            }
+
+            try
+            {
+                s1.SubSequence(0, s1.Length + 2);
+                fail("Should throw exception");
+            }
+            catch (IndexOutOfRangeException)
+            {
+                //OK
+            }
+
+            try
+            {
+                s1.SubSequence(5, 1);
+                fail("Should throw exception");
+            }
+            catch (IndexOutOfRangeException)
+            {
+                //OK
+            }
+        }
+
+        [Test]
+        public void testEquals()
+        {
+            assertFalse(new SimpleString("abcdef").Equals(new Object()));
+
+            assertEquals(new SimpleString("abcdef"), new SimpleString("abcdef"));
+
+            assertFalse(new SimpleString("abcdef").Equals(new SimpleString("abggcdef")));
+            assertFalse(new SimpleString("abcdef").Equals(new SimpleString("ghijkl")));
+        }
+
+        [Test]
+        public void testHashcode()
+        {
+            SimpleString str = new SimpleString("abcdef");
+            SimpleString sameStr = new SimpleString("abcdef");
+            SimpleString differentStr = new SimpleString("ghijk");
+
+            string tst = str.ToString();
+            tst.GetHashCode();
+
+            assertTrue(str.GetHashCode() == sameStr.GetHashCode());
+            assertFalse(str.GetHashCode() == differentStr.GetHashCode());
+
+        }
+
+        [Test]
+        public void testUnicode()
+        {
+            String myString = "abcdef&^*&!^ghijkl\uB5E2\uCAC7\uB2BB\uB7DD\uB7C7\uB3A3\uBCE4\uB5A5";
+
+            SimpleString s = new SimpleString(myString);
+            byte[] data = s.Data;
+            s = new SimpleString(data);
+
+            assertEquals(myString, s.ToString());
+        }
+
+        [Test]
+        public void testUnicodeWithSurrogates()
+        {
+            String myString = "abcdef&^*&!^ghijkl\uD900\uDD00";
+
+            SimpleString s = new SimpleString(myString);
+            byte[] data = s.Data;
+            s = new SimpleString(data);
+
+            assertEquals(myString, s.ToString());
+        }
+
+        [Test]
+        public void testSizeofString()
+        {
+            assertEquals(DataConstants.SIZE_INT, SimpleString.SizeofString(new SimpleString("")));
+
+            //FIXME: provide a randomString method
+            SimpleString str = new SimpleString(randomString());
+            assertEquals(DataConstants.SIZE_INT + str.Data.Length, SimpleString.SizeofString(str));
+        }
+
+        [Test]
+        public void testSizeofNullableString()
+        {
+            assertEquals(1, SimpleString.SizeofNullableString(null));
+
+            assertEquals(1 + DataConstants.SIZE_INT, SimpleString.SizeofNullableString(new SimpleString("")));
+
+            SimpleString str = new SimpleString(randomString());
+            assertEquals(1 + DataConstants.SIZE_INT + str.Data.Length, SimpleString.SizeofNullableString(str));
+        }
+
+        [Test]
+        public void testSplitNoDelimeter()
+        {
+            SimpleString s = new SimpleString("abcdefghi");
+            SimpleString[] strings = s.Split('.');
+            assertNotNull(strings);
+            assertEquals(strings.Length, 1);
+            assertEquals(strings[0], s);
+        }
+
+        [Test]
+        public void testSplit1Delimeter()
+        {
+            SimpleString s = new SimpleString("abcd.efghi");
+            SimpleString[] strings = s.Split('.');
+            assertNotNull(strings);
+            assertEquals(strings.Length, 2);
+            assertEquals(strings[0], new SimpleString("abcd"));
+            assertEquals(strings[1], new SimpleString("efghi"));
+        }
+
+        [Test]
+        public void testSplitmanyDelimeters()
+        {
+            SimpleString s = new SimpleString("abcd.efghi.jklmn.opqrs.tuvw.xyz");
+            SimpleString[] strings = s.Split('.');
+            assertNotNull(strings);
+            assertEquals(strings.Length, 6);
+            assertEquals(strings[0], new SimpleString("abcd"));
+            assertEquals(strings[1], new SimpleString("efghi"));
+            assertEquals(strings[2], new SimpleString("jklmn"));
+            assertEquals(strings[3], new SimpleString("opqrs"));
+            assertEquals(strings[4], new SimpleString("tuvw"));
+            assertEquals(strings[5], new SimpleString("xyz"));
+        }
+
+        [Test]
+        public void testContains()
+        {
+            SimpleString simpleString = new SimpleString("abcdefghijklmnopqrst");
+            assertFalse(simpleString.Contains('.'));
+            assertFalse(simpleString.Contains('%'));
+            assertFalse(simpleString.Contains('8'));
+            assertFalse(simpleString.Contains('.'));
+            assertTrue(simpleString.Contains('a'));
+            assertTrue(simpleString.Contains('b'));
+            assertTrue(simpleString.Contains('c'));
+            assertTrue(simpleString.Contains('d'));
+            assertTrue(simpleString.Contains('e'));
+            assertTrue(simpleString.Contains('f'));
+            assertTrue(simpleString.Contains('g'));
+            assertTrue(simpleString.Contains('h'));
+            assertTrue(simpleString.Contains('i'));
+            assertTrue(simpleString.Contains('j'));
+            assertTrue(simpleString.Contains('k'));
+            assertTrue(simpleString.Contains('l'));
+            assertTrue(simpleString.Contains('m'));
+            assertTrue(simpleString.Contains('n'));
+            assertTrue(simpleString.Contains('o'));
+            assertTrue(simpleString.Contains('p'));
+            assertTrue(simpleString.Contains('q'));
+            assertTrue(simpleString.Contains('r'));
+            assertTrue(simpleString.Contains('s'));
+            assertTrue(simpleString.Contains('t'));
+        }
+
+        [Test]
+        public void testConcat()
+        {
+            SimpleString start = new SimpleString("abcdefg");
+            SimpleString middle = new SimpleString("hijklmnop");
+            SimpleString end = new SimpleString("qrstuvwxyz");
+            assertEquals(start.Concat(middle).Concat(end), new SimpleString("abcdefghijklmnopqrstuvwxyz"));
+            assertEquals(start.Concat('.').Concat(end), new SimpleString("abcdefg.qrstuvwxyz"));
+        }
+
+        [Test]
+        public void testConcat33()
+        {
+            SimpleString start = new SimpleString("a");
+            SimpleString middle = new SimpleString("b");
+            assertEquals(start.Concat(middle).ToString(), new SimpleString("ab").ToString());
+        }
+    }
+
+}

Deleted: trunk/dotnet/JSMClient.vsmdi
===================================================================
--- trunk/dotnet/JSMClient.vsmdi	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/JSMClient.vsmdi	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,6 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<TestLists xmlns="http://microsoft.com/schemas/VisualStudio/TeamTest/2006">
-  <TestList name="Lists of Tests" id="8c43106b-9dc1-4907-a29f-aa66a61bf5b6">
-    <RunConfiguration id="59754eb7-8ee4-4c36-922b-c01d7bda161b" name="Local Test Run" storage="localtestrun.testrunconfig" type="Microsoft.VisualStudio.TestTools.Common.TestRunConfiguration, Microsoft.VisualStudio.QualityTools.Common,   PublicKeyToken=b03f5f7f11d50a3a" />
-  </TestList>
-</TestLists>
\ No newline at end of file

Copied: trunk/dotnet/JSMClient.vsmdi (from rev 5824, trunk/dotnet/JSMClient.vsmdi)
===================================================================
--- trunk/dotnet/JSMClient.vsmdi	                        (rev 0)
+++ trunk/dotnet/JSMClient.vsmdi	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,6 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<TestLists xmlns="http://microsoft.com/schemas/VisualStudio/TeamTest/2006">
+  <TestList name="Lists of Tests" id="8c43106b-9dc1-4907-a29f-aa66a61bf5b6">
+    <RunConfiguration id="59754eb7-8ee4-4c36-922b-c01d7bda161b" name="Local Test Run" storage="localtestrun.testrunconfig" type="Microsoft.VisualStudio.TestTools.Common.TestRunConfiguration, Microsoft.VisualStudio.QualityTools.Common,   PublicKeyToken=b03f5f7f11d50a3a" />
+  </TestList>
+</TestLists>
\ No newline at end of file

Deleted: trunk/dotnet/LocalTestRun.testrunconfig
===================================================================
--- trunk/dotnet/LocalTestRun.testrunconfig	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/LocalTestRun.testrunconfig	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<TestRunConfiguration name="Local Test Run" id="59754eb7-8ee4-4c36-922b-c01d7bda161b" xmlns="http://microsoft.com/schemas/VisualStudio/TeamTest/2006">
-  <Description>This is a default test run configuration for a local test run.</Description>
-  <TestTypeSpecific />
-</TestRunConfiguration>
\ No newline at end of file

Copied: trunk/dotnet/LocalTestRun.testrunconfig (from rev 5824, trunk/dotnet/LocalTestRun.testrunconfig)
===================================================================
--- trunk/dotnet/LocalTestRun.testrunconfig	                        (rev 0)
+++ trunk/dotnet/LocalTestRun.testrunconfig	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<TestRunConfiguration name="Local Test Run" id="59754eb7-8ee4-4c36-922b-c01d7bda161b" xmlns="http://microsoft.com/schemas/VisualStudio/TeamTest/2006">
+  <Description>This is a default test run configuration for a local test run.</Description>
+  <TestTypeSpecific />
+</TestRunConfiguration>
\ No newline at end of file

Deleted: trunk/dotnet/README.txt
===================================================================
--- trunk/dotnet/README.txt	2009-02-05 19:18:18 UTC (rev 5824)
+++ trunk/dotnet/README.txt	2009-02-05 20:23:48 UTC (rev 5827)
@@ -1 +0,0 @@
-Conversion based on Revision 5812.
\ No newline at end of file

Copied: trunk/dotnet/README.txt (from rev 5824, trunk/dotnet/README.txt)
===================================================================
--- trunk/dotnet/README.txt	                        (rev 0)
+++ trunk/dotnet/README.txt	2009-02-05 20:23:48 UTC (rev 5827)
@@ -0,0 +1 @@
+Conversion based on Revision 5812.
\ No newline at end of file




More information about the jboss-cvs-commits mailing list