org.objectweb.dream.message
Class BasicChunkType

java.lang.Object
  extended byorg.objectweb.dream.message.BasicChunkType
All Implemented Interfaces:
ChunkType, Serializable

public class BasicChunkType
extends Object
implements ChunkType, Serializable

Basic implementation of ChunkType interface

See Also:
Serialized Form

Constructor Summary
BasicChunkType(Class chunkItf, Class chunkImpl)
          Creates a new Chunk type by specifying the class object of the interface provided by chunks of this type
BasicChunkType(String itfSignature, String implSignature)
          Creates a new chunk type.
 
Method Summary
 Class getChunkImpl()
          Returns the Class object implementing the chunk interface.
 Class getChunkItf()
          Returns the Class object corresponding to the signature of this chunk type
 String getChunkSignature()
          Returns the signatures of the methods provided by chunks of this type.
 boolean isSubTypeOf(ChunkType t)
          Returns true if this chunk type if a sub type of the given chunk type.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BasicChunkType

public BasicChunkType(String itfSignature,
                      String implSignature)
               throws ClassNotFoundException
Creates a new chunk type.

Parameters:
itfSignature - the signature of this chunk type
implSignature - the signature of the chunk implementation
Throws:
ClassNotFoundException - if the the class corresponding to the signature cannot be found.
IllegalArgumentException - if the specified signature does not correspond to an interface.

BasicChunkType

public BasicChunkType(Class chunkItf,
                      Class chunkImpl)
Creates a new Chunk type by specifying the class object of the interface provided by chunks of this type

Parameters:
chunkItf - class object of the interface provided by chunks of this type
chunkImpl - class object of the implementation of the chunk.
Throws:
IllegalArgumentException - if the specified class object does not designate an interface.
Method Detail

getChunkSignature

public String getChunkSignature()
Description copied from interface: ChunkType
Returns the signatures of the methods provided by chunks of this type. In Java this method returns the fully qualified name of a Java interface corresponding to these method signatures.

Specified by:
getChunkSignature in interface ChunkType
Returns:
the signatures of the methods provided by chunks of this type.
See Also:
ChunkType.getChunkSignature()

getChunkItf

public Class getChunkItf()
Returns the Class object corresponding to the signature of this chunk type

Returns:
the Class object corresponding to the signature of this chunk type

getChunkImpl

public Class getChunkImpl()
Returns the Class object implementing the chunk interface.

Returns:
the Class object implementing the chunk interface.

isSubTypeOf

public boolean isSubTypeOf(ChunkType t)
Description copied from interface: ChunkType
Returns true if this chunk type if a sub type of the given chunk type.

Specified by:
isSubTypeOf in interface ChunkType
Parameters:
t - a chunk type
Returns:
true if this chunk type if a sub type of the given chunk type.
See Also:
ChunkType.isSubTypeOf(org.objectweb.dream.message.ChunkType)


Copyright © 2003, 2004 - INRIA Rhone-Alpes - All Rights Reserved.