directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From trus...@apache.org
Subject svn commit: r371309 - in /directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina: common/support/BaseIoSession.java transport/socket/nio/DatagramSession.java transport/socket/nio/SocketSession.java
Date Sun, 22 Jan 2006 14:41:55 GMT
Author: trustin
Date: Sun Jan 22 06:41:50 2006
New Revision: 371309

URL: http://svn.apache.org/viewcvs?rev=371309&view=rev
Log:
Fixed failing tests

Modified:
    directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/common/support/BaseIoSession.java
    directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/transport/socket/nio/DatagramSession.java
    directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/transport/socket/nio/SocketSession.java

Modified: directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/common/support/BaseIoSession.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/common/support/BaseIoSession.java?rev=371309&r1=371308&r2=371309&view=diff
==============================================================================
--- directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/common/support/BaseIoSession.java
(original)
+++ directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/common/support/BaseIoSession.java
Sun Jan 22 06:41:50 2006
@@ -49,6 +49,11 @@
      */
     public static void registerAttributeOverrider( Class sessionType, IoSessionAttributeOverrider
overrider )
     {
+        if( !BaseIoSession.class.isAssignableFrom( sessionType ) )
+        {
+            throw new IllegalArgumentException();
+        }
+
         Map overriders = ( Map ) provider2attributeOverriders.get( sessionType );
         if( overriders == null )
         {

Modified: directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/transport/socket/nio/DatagramSession.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/transport/socket/nio/DatagramSession.java?rev=371309&r1=371308&r2=371309&view=diff
==============================================================================
--- directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/transport/socket/nio/DatagramSession.java
(original)
+++ directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/transport/socket/nio/DatagramSession.java
Sun Jan 22 06:41:50 2006
@@ -45,11 +45,11 @@
 {
     static
     {
-        BaseIoSession.registerAttributeOverrider( DatagramServiceProvider.class, new ReceiveBufferSizeOverrider()
);
-        BaseIoSession.registerAttributeOverrider( DatagramServiceProvider.class, new SendBufferSizeOverrider()
);
-        BaseIoSession.registerAttributeOverrider( DatagramServiceProvider.class, new BroadcastOverrider()
);
-        BaseIoSession.registerAttributeOverrider( DatagramServiceProvider.class, new ReuseAddressOverrider()
);
-        BaseIoSession.registerAttributeOverrider( DatagramServiceProvider.class, new TrafficClassOverrider()
);
+        BaseIoSession.registerAttributeOverrider( DatagramSession.class, new ReceiveBufferSizeOverrider()
);
+        BaseIoSession.registerAttributeOverrider( DatagramSession.class, new SendBufferSizeOverrider()
);
+        BaseIoSession.registerAttributeOverrider( DatagramSession.class, new BroadcastOverrider()
);
+        BaseIoSession.registerAttributeOverrider( DatagramSession.class, new ReuseAddressOverrider()
);
+        BaseIoSession.registerAttributeOverrider( DatagramSession.class, new TrafficClassOverrider()
);
     }
 
     private final DatagramSessionManager managerDelegate;

Modified: directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/transport/socket/nio/SocketSession.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/transport/socket/nio/SocketSession.java?rev=371309&r1=371308&r2=371309&view=diff
==============================================================================
--- directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/transport/socket/nio/SocketSession.java
(original)
+++ directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/transport/socket/nio/SocketSession.java
Sun Jan 22 06:41:50 2006
@@ -45,14 +45,14 @@
 {
     static
     {
-        BaseIoSession.registerAttributeOverrider( SocketServiceProvider.class, new ReceiveBufferSizeOverrider()
);
-        BaseIoSession.registerAttributeOverrider( SocketServiceProvider.class, new SendBufferSizeOverrider()
);
-        BaseIoSession.registerAttributeOverrider( SocketServiceProvider.class, new ReuseAddressOverrider()
);
-        BaseIoSession.registerAttributeOverrider( SocketServiceProvider.class, new TrafficClassOverrider()
);
-        BaseIoSession.registerAttributeOverrider( SocketServiceProvider.class, new KeepAliveOverrider()
);
-        BaseIoSession.registerAttributeOverrider( SocketServiceProvider.class, new OOBInlineOverrider()
);
-        BaseIoSession.registerAttributeOverrider( SocketServiceProvider.class, new LingerOverrider()
);
-        BaseIoSession.registerAttributeOverrider( SocketServiceProvider.class, new NoDelayOverrider()
);
+        BaseIoSession.registerAttributeOverrider( SocketSession.class, new ReceiveBufferSizeOverrider()
);
+        BaseIoSession.registerAttributeOverrider( SocketSession.class, new SendBufferSizeOverrider()
);
+        BaseIoSession.registerAttributeOverrider( SocketSession.class, new ReuseAddressOverrider()
);
+        BaseIoSession.registerAttributeOverrider( SocketSession.class, new TrafficClassOverrider()
);
+        BaseIoSession.registerAttributeOverrider( SocketSession.class, new KeepAliveOverrider()
);
+        BaseIoSession.registerAttributeOverrider( SocketSession.class, new OOBInlineOverrider()
);
+        BaseIoSession.registerAttributeOverrider( SocketSession.class, new LingerOverrider()
);
+        BaseIoSession.registerAttributeOverrider( SocketSession.class, new NoDelayOverrider()
);
     }
     
     private final SocketIoProcessor ioProcessor;



Mime
View raw message