org.objectweb.dream.message
Class MessageTypeNCImpl

java.lang.Object
  extended byorg.objectweb.dream.message.MessageTypeImpl
      extended byorg.objectweb.dream.message.MessageTypeNCImpl
All Implemented Interfaces:
EmptyStringArray, MessageType, MessageTypeNC

public class MessageTypeNCImpl
extends MessageTypeImpl
implements MessageTypeNC


Field Summary
static MessageType EMPTY_MESSAGE_TYPE_NC
          A constant designating the empty message type NC.
 
Fields inherited from class org.objectweb.dream.message.MessageTypeImpl
chkNames, chunkTypes, EMPTY_MESSAGE_TYPE, subMessageTypes, subMessageTypesArray
 
Fields inherited from interface org.objectweb.dream.message.MessageType
EMPTY_MESSAGE_TYPE_ARRAY
 
Fields inherited from interface org.objectweb.dream.util.EmptyStringArray
EMPTY_STRING_ARRAY
 
Constructor Summary
MessageTypeNCImpl()
           
 
Method Summary
 void addSubMessageType(String messageName, MessageType messageType)
          Adds a sub Message type
 String[] getSubMessageNames()
          Returns an (eventually empty) array containing the sub message's names of messages of this type.
 Iterator getSubMessageNamesIterator()
          Returns an iterator over the sub message's names of messages of this type.
 MessageType getSubMessageType(String name)
          Returns the type of the sub message having the specified name.
 MessageType[] getSubMessageTypes()
          Returns an (eventually empty) array containing the types of the sub messages of messages of this type.
 Iterator getSubMessageTypesIterator()
          Returns an iterator over the types of the sub messages of messages of this type.
 MessageType[] getUnnamedSubMessageTypes()
          Returns an (eventually empty) array containing the types of the unnamed sub messages of messages of this type.
 Iterator getUnnamedSubMessageTypesIterator()
          Returns an iterator over the types of the unnamed sub messages of messages of this type.
 MessageType removeSubMessageType(String subMessageName)
          Removes a sub message type
 
Methods inherited from class org.objectweb.dream.message.MessageTypeImpl
addChunkType, addSubMessageType, getChunkNames, getChunkNamesIterator, getChunkType, isEmpty, isSubTypeOf, removeChunkType, removeSubMessageType
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.objectweb.dream.message.MessageType
getChunkNames, getChunkNamesIterator, getChunkType, isEmpty, isSubTypeOf
 

Field Detail

EMPTY_MESSAGE_TYPE_NC

public static final MessageType EMPTY_MESSAGE_TYPE_NC
A constant designating the empty message type NC.

Constructor Detail

MessageTypeNCImpl

public MessageTypeNCImpl()
Method Detail

getSubMessageType

public MessageType getSubMessageType(String name)
Description copied from interface: MessageTypeNC
Returns the type of the sub message having the specified name.

Specified by:
getSubMessageType in interface MessageTypeNC
Parameters:
name - the name of one of the message types returned by MessageTypeNC.getSubMessageNames().
Returns:
the type of the sub message having the specified name or null if no sub message with the specified name exists.
See Also:
MessageTypeNC.getSubMessageType(java.lang.String)

getSubMessageNames

public String[] getSubMessageNames()
Description copied from interface: MessageTypeNC
Returns an (eventually empty) array containing the sub message's names of messages of this type.

Specified by:
getSubMessageNames in interface MessageTypeNC
Returns:
an array containing the sub message's names of messages of this type.
See Also:
MessageTypeNC.getSubMessageNames()

getSubMessageNamesIterator

public Iterator getSubMessageNamesIterator()
Description copied from interface: MessageTypeNC
Returns an iterator over the sub message's names of messages of this type.

Specified by:
getSubMessageNamesIterator in interface MessageTypeNC
Returns:
an iterator over the sub message's names of messages of this type.
See Also:
MessageTypeNC.getSubMessageNamesIterator()

addSubMessageType

public void addSubMessageType(String messageName,
                              MessageType messageType)
                       throws MessageAlreadyExistException
Adds a sub Message type

Parameters:
messageName - the name of the sub message type
messageType - the sub message type
Throws:
MessageAlreadyExistException - if this type already contains a sub message type with the specified name

removeSubMessageType

public MessageType removeSubMessageType(String subMessageName)
Removes a sub message type

Parameters:
subMessageName - the name of the sub message type
Returns:
the sub message type or null if no sub message type with the specified name exists.

getSubMessageTypes

public MessageType[] getSubMessageTypes()
Description copied from interface: MessageType
Returns an (eventually empty) array containing the types of the sub messages of messages of this type.

Specified by:
getSubMessageTypes in interface MessageType
Overrides:
getSubMessageTypes in class MessageTypeImpl
See Also:
MessageType.getSubMessageTypes()

getSubMessageTypesIterator

public Iterator getSubMessageTypesIterator()
Description copied from interface: MessageType
Returns an iterator over the types of the sub messages of messages of this type.

Specified by:
getSubMessageTypesIterator in interface MessageType
Overrides:
getSubMessageTypesIterator in class MessageTypeImpl
See Also:
MessageType.getSubMessageTypesIterator()

getUnnamedSubMessageTypes

public MessageType[] getUnnamedSubMessageTypes()
Description copied from interface: MessageTypeNC
Returns an (eventually empty) array containing the types of the unnamed sub messages of messages of this type.

Specified by:
getUnnamedSubMessageTypes in interface MessageTypeNC
Returns:
an array containing the types of the unnamed sub messages of messages of this type.
See Also:
MessageTypeNC.getUnnamedSubMessageTypes()

getUnnamedSubMessageTypesIterator

public Iterator getUnnamedSubMessageTypesIterator()
Description copied from interface: MessageTypeNC
Returns an iterator over the types of the unnamed sub messages of messages of this type.

Specified by:
getUnnamedSubMessageTypesIterator in interface MessageTypeNC
Returns:
an iterator over the types of the unnamed sub messages of messages of this type.
See Also:
MessageTypeNC.getUnnamedSubMessageTypesIterator()


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