directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From trus...@apache.org
Subject svn commit: r371444 - in /directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina: common/ transport/socket/nio/ transport/vmpipe/
Date Mon, 23 Jan 2006 02:40:19 GMT
Author: trustin
Date: Sun Jan 22 18:40:12 2006
New Revision: 371444

URL: http://svn.apache.org/viewcvs?rev=371444&view=rev
Log:
Replaced tabs with spaces

Modified:
    directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/common/IoService.java
    directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/transport/socket/nio/DatagramServiceProvider.java
    directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/transport/socket/nio/SocketAcceptor.java
    directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/transport/socket/nio/SocketAddresses.java
    directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/transport/socket/nio/SocketServiceProvider.java
    directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/transport/vmpipe/VmPipeServiceProvider.java

Modified: directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/common/IoService.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/common/IoService.java?rev=371444&r1=371443&r2=371444&view=diff
==============================================================================
--- directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/common/IoService.java
(original)
+++ directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/common/IoService.java
Sun Jan 22 18:40:12 2006
@@ -134,7 +134,7 @@
      */
     public static IoServiceProvider getProvider( String providerType, String transportType
)
     {
-    	return ( IoServiceProvider ) providers.get( getProviderKey( providerType, transportType
) );
+        return ( IoServiceProvider ) providers.get( getProviderKey( providerType, transportType
) );
     }
     
     /**
@@ -158,22 +158,22 @@
         {
             throw new NullPointerException( "address" );
         }
-    	IoServiceProvider p = getProvider( address.getProviderType(), address.getTransportType()
);
-    	if( p != null )
-    	{
-    		return p;
-    	}
-    	
-    	throw new UnsupportedAddressException( address.toString() );
+        IoServiceProvider p = getProvider( address.getProviderType(), address.getTransportType()
);
+        if( p != null )
+        {
+            return p;
+        }
+        
+        throw new UnsupportedAddressException( address.toString() );
     }
     
     /**
      * Returns the key which is used to manage provider list.
      */
-	private static String getProviderKey( IoServiceProvider provider )
+    private static String getProviderKey( IoServiceProvider provider )
     {
-		return getProviderKey( provider.getProviderType(), provider.getTransportType() );
-	}
+        return getProviderKey( provider.getProviderType(), provider.getTransportType() );
+    }
     
     /**
      * Returns the key which is used to manage provider list.
@@ -182,17 +182,17 @@
     {
         return getProviderKey( address.getProviderType(), address.getTransportType() );
     }
-	
+    
     /**
      * Returns the key which is used to manage provider list.
      */
-	private static String getProviderKey( String providerType, String transportType )
-	{
-		return providerType + ':' + transportType;
-	}
+    private static String getProviderKey( String providerType, String transportType )
+    {
+        return providerType + ':' + transportType;
+    }
+    
+    // Acceptor side
     
-	// Acceptor side
-	
     /**
      * Binds to the specified <code>address</code> and handles incoming
      * connections with the specified <code>handler</code>.
@@ -201,7 +201,7 @@
      */
     public static void bind( IoAddress address, IoHandler handler ) throws IOException
     {
-    	bind( address, handler, IoFilterChainBuilder.NOOP );
+        bind( address, handler, IoFilterChainBuilder.NOOP );
     }
 
     /**
@@ -332,8 +332,8 @@
      */
     public static Collection getManagedSessions( IoAddress address )
     {
-    	IoAcceptor acceptor = getProviderSafely( address ).getAcceptor();
-    	return acceptor.getManagedSessions( address );
+        IoAcceptor acceptor = getProviderSafely( address ).getAcceptor();
+        return acceptor.getManagedSessions( address );
     }
     
     /**
@@ -371,8 +371,8 @@
         {
             throw new NullPointerException( "localAddress" );
         }
-    	IoAcceptor acceptor = getProviderSafely( localAddress ).getAcceptor();
-    	return acceptor.newSession( remoteAddress, localAddress );
+        IoAcceptor acceptor = getProviderSafely( localAddress ).getAcceptor();
+        return acceptor.newSession( remoteAddress, localAddress );
     }
     
     /**
@@ -401,7 +401,7 @@
      */
     public static ConnectFuture connect( IoAddress address, IoHandler handler )
     {
-    	return connect( address, handler, IoFilterChainBuilder.NOOP );
+        return connect( address, handler, IoFilterChainBuilder.NOOP );
     }
     
     /**
@@ -429,7 +429,7 @@
     public static ConnectFuture connect( IoAddress address, IoHandler handler,
                            IoFilterChainBuilder filterChainBuilder )
     {
-    	return connect( address, null, handler, filterChainBuilder );
+        return connect( address, null, handler, filterChainBuilder );
     }
 
     /**
@@ -458,7 +458,7 @@
      */
     public static ConnectFuture connect( IoAddress address, IoAddress localAddress, IoHandler
handler )
     {
-    	return connect( address, localAddress, handler, IoFilterChainBuilder.NOOP );
+        return connect( address, localAddress, handler, IoFilterChainBuilder.NOOP );
     }
 
     /**
@@ -491,12 +491,12 @@
         {
             throw new NullPointerException( "handler" );
         }
-    	IoConnector connector = getProviderSafely( address ).getConnector();
+        IoConnector connector = getProviderSafely( address ).getConnector();
         if( filterChainBuilder == null )
         {
             filterChainBuilder = IoFilterChainBuilder.NOOP;
         }
-    	return connector.connect(
+        return connector.connect(
                 address, localAddress, handler,
                 createFilterChainBuilder( address, filterChainBuilder ) );
     }

Modified: directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/transport/socket/nio/DatagramServiceProvider.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/transport/socket/nio/DatagramServiceProvider.java?rev=371444&r1=371443&r2=371444&view=diff
==============================================================================
--- directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/transport/socket/nio/DatagramServiceProvider.java
(original)
+++ directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/transport/socket/nio/DatagramServiceProvider.java
Sun Jan 22 18:40:12 2006
@@ -23,9 +23,9 @@
 
 public class DatagramServiceProvider implements IoServiceProvider
 {
-	private final IoAcceptor acceptor = new DatagramAcceptor();
-	private final IoConnector connector = new DatagramConnector();
-	
+    private final IoAcceptor acceptor = new DatagramAcceptor();
+    private final IoConnector connector = new DatagramConnector();
+    
     public String getProviderType()
     {
         return "nio";
@@ -33,7 +33,7 @@
     
     public String getTransportType()
     {
-    	return "datagram";
+        return "datagram";
     }
 
     public boolean isConnectionless()

Modified: directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/transport/socket/nio/SocketAcceptor.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/transport/socket/nio/SocketAcceptor.java?rev=371444&r1=371443&r2=371444&view=diff
==============================================================================
--- directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/transport/socket/nio/SocketAcceptor.java
(original)
+++ directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/transport/socket/nio/SocketAcceptor.java
Sun Jan 22 18:40:12 2006
@@ -241,10 +241,10 @@
     
     public IoSession newSession( IoAddress remoteAddress, IoAddress localAddress )
     {
-    	throw new UnsupportedOperationException();
-	}
+        throw new UnsupportedOperationException();
+    }
 
-	private class Worker extends Thread
+    private class Worker extends Thread
     {
         public Worker()
         {

Modified: directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/transport/socket/nio/SocketAddresses.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/transport/socket/nio/SocketAddresses.java?rev=371444&r1=371443&r2=371444&view=diff
==============================================================================
--- directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/transport/socket/nio/SocketAddresses.java
(original)
+++ directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/transport/socket/nio/SocketAddresses.java
Sun Jan 22 18:40:12 2006
@@ -31,51 +31,51 @@
  */
 class SocketAddresses
 {
-	public static SocketAddress parse( IoAddress address )
-	{
-		if( address == null )
-		{
-			throw new NullPointerException( "address" );
-		}
-		
-		String addrStr = address.getAddress();
-		int colonPos = addrStr.lastIndexOf( ':' );
-		if( colonPos < 0 )
-		{
-			throw new IllegalArgumentException( "no port: " + address );
-		}
-		
+    public static SocketAddress parse( IoAddress address )
+    {
+        if( address == null )
+        {
+            throw new NullPointerException( "address" );
+        }
+        
+        String addrStr = address.getAddress();
+        int colonPos = addrStr.lastIndexOf( ':' );
+        if( colonPos < 0 )
+        {
+            throw new IllegalArgumentException( "no port: " + address );
+        }
+        
         String portStr = addrStr.substring( colonPos + 1 );
-		int port;
-		try
-		{
-			port = Integer.parseInt( portStr );
-		}
-		catch( NumberFormatException e )
-		{
-			throw new IllegalArgumentException( "Invalid port: " + portStr + " (in " + address + ')'
);
-		}
-		
-		if( port == 0 )
-		{
-			throw new IllegalArgumentException( "Unsupported port number: 0" );
-		}
-		
-		String hostname = addrStr.substring( 0, colonPos ).trim();
-		if( hostname.length() == 0 )
-		{
-			throw new IllegalArgumentException( "no hostname: " + address );
-		}
-		
-		if( hostname.equals( "*" ) )
-		{
-			return new InetSocketAddress( port );
-		}
-		else
-		{
-			return new InetSocketAddress( addrStr.substring( 0, colonPos ), port );
-		}
-	}
+        int port;
+        try
+        {
+            port = Integer.parseInt( portStr );
+        }
+        catch( NumberFormatException e )
+        {
+            throw new IllegalArgumentException( "Invalid port: " + portStr + " (in " + address
+ ')' );
+        }
+        
+        if( port == 0 )
+        {
+            throw new IllegalArgumentException( "Unsupported port number: 0" );
+        }
+        
+        String hostname = addrStr.substring( 0, colonPos ).trim();
+        if( hostname.length() == 0 )
+        {
+            throw new IllegalArgumentException( "no hostname: " + address );
+        }
+        
+        if( hostname.equals( "*" ) )
+        {
+            return new InetSocketAddress( port );
+        }
+        else
+        {
+            return new InetSocketAddress( addrStr.substring( 0, colonPos ), port );
+        }
+    }
     
     public static IoAddress compose( String transportType, SocketAddress address )
     {

Modified: directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/transport/socket/nio/SocketServiceProvider.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/transport/socket/nio/SocketServiceProvider.java?rev=371444&r1=371443&r2=371444&view=diff
==============================================================================
--- directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/transport/socket/nio/SocketServiceProvider.java
(original)
+++ directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/transport/socket/nio/SocketServiceProvider.java
Sun Jan 22 18:40:12 2006
@@ -23,9 +23,9 @@
 
 public class SocketServiceProvider implements IoServiceProvider
 {
-	private final IoAcceptor acceptor = new SocketAcceptor();
-	private final IoConnector connector = new SocketConnector();
-	
+    private final IoAcceptor acceptor = new SocketAcceptor();
+    private final IoConnector connector = new SocketConnector();
+    
     public String getProviderType()
     {
         return "nio";
@@ -33,7 +33,7 @@
     
     public String getTransportType()
     {
-    	return "socket";
+        return "socket";
     }
 
     public Class getEnvelopeType()

Modified: directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/transport/vmpipe/VmPipeServiceProvider.java
URL: http://svn.apache.org/viewcvs/directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/transport/vmpipe/VmPipeServiceProvider.java?rev=371444&r1=371443&r2=371444&view=diff
==============================================================================
--- directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/transport/vmpipe/VmPipeServiceProvider.java
(original)
+++ directory/sandbox/trustin/mina-spi/core/src/main/java/org/apache/mina/transport/vmpipe/VmPipeServiceProvider.java
Sun Jan 22 18:40:12 2006
@@ -28,8 +28,8 @@
  */
 public class VmPipeServiceProvider implements IoServiceProvider
 {
-	private final IoAcceptor acceptor = new VmPipeAcceptor();
-	private final IoConnector connector = new VmPipeConnector();
+    private final IoAcceptor acceptor = new VmPipeAcceptor();
+    private final IoConnector connector = new VmPipeConnector();
 
     public String getProviderType()
     {
@@ -38,7 +38,7 @@
     
     public String getTransportType()
     {
-    	return "pipe";
+        return "pipe";
     }
     
     public boolean isConnectionless()



Mime
View raw message