org.apache.mina.core.service
Class DefaultTransportMetadata

java.lang.Object
  extended by org.apache.mina.core.service.DefaultTransportMetadata
All Implemented Interfaces:
TransportMetadata

public class DefaultTransportMetadata
extends java.lang.Object
implements TransportMetadata

A default immutable implementation of TransportMetadata.

Author:
Apache MINA Project

Constructor Summary
DefaultTransportMetadata(java.lang.String providerName, java.lang.String name, boolean connectionless, boolean fragmentation, java.lang.Class<? extends java.net.SocketAddress> addressType, java.lang.Class<? extends IoSessionConfig> sessionConfigType, java.lang.Class<?>... envelopeTypes)
           
 
Method Summary
 java.lang.Class<? extends java.net.SocketAddress> getAddressType()
          Returns the address type of the service.
 java.util.Set<java.lang.Class<? extends java.lang.Object>> getEnvelopeTypes()
          Returns the set of the allowed message type when you write to an IoSession that is managed by the service.
 java.lang.String getName()
          Returns the name of the service.
 java.lang.String getProviderName()
          Returns the name of the service provider (e.g.
 java.lang.Class<? extends IoSessionConfig> getSessionConfigType()
          Returns the type of the IoSessionConfig of the service
 boolean hasFragmentation()
          Returns true if the messages exchanged by the service can be fragmented or reassembled by its underlying transport.
 boolean isConnectionless()
          Returns true if the session of this transport type is connectionless.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

DefaultTransportMetadata

public DefaultTransportMetadata(java.lang.String providerName,
                                java.lang.String name,
                                boolean connectionless,
                                boolean fragmentation,
                                java.lang.Class<? extends java.net.SocketAddress> addressType,
                                java.lang.Class<? extends IoSessionConfig> sessionConfigType,
                                java.lang.Class<?>... envelopeTypes)
Method Detail

getAddressType

public java.lang.Class<? extends java.net.SocketAddress> getAddressType()
Description copied from interface: TransportMetadata
Returns the address type of the service.

Specified by:
getAddressType in interface TransportMetadata

getEnvelopeTypes

public java.util.Set<java.lang.Class<? extends java.lang.Object>> getEnvelopeTypes()
Description copied from interface: TransportMetadata
Returns the set of the allowed message type when you write to an IoSession that is managed by the service.

Specified by:
getEnvelopeTypes in interface TransportMetadata

getSessionConfigType

public java.lang.Class<? extends IoSessionConfig> getSessionConfigType()
Description copied from interface: TransportMetadata
Returns the type of the IoSessionConfig of the service

Specified by:
getSessionConfigType in interface TransportMetadata

getProviderName

public java.lang.String getProviderName()
Description copied from interface: TransportMetadata
Returns the name of the service provider (e.g. "nio", "apr" and "rxtx").

Specified by:
getProviderName in interface TransportMetadata

getName

public java.lang.String getName()
Description copied from interface: TransportMetadata
Returns the name of the service.

Specified by:
getName in interface TransportMetadata

isConnectionless

public boolean isConnectionless()
Description copied from interface: TransportMetadata
Returns true if the session of this transport type is connectionless.

Specified by:
isConnectionless in interface TransportMetadata

hasFragmentation

public boolean hasFragmentation()
Description copied from interface: TransportMetadata
Returns true if the messages exchanged by the service can be fragmented or reassembled by its underlying transport.

Specified by:
hasFragmentation in interface TransportMetadata

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object