eaLib API Docs
Last Modified : January 7 2002

mss.ea.al
Class MessageType

java.lang.Object
  |
  +--mss.ea.al.MessageType

public class MessageType
extends java.lang.Object

Class representation for a message type.

Since:
0.2
Version:
$Revision: 1.3 $ $Date: 2001/11/13 10:00:34 $
Author:
Andreas Rummler

Field Summary
protected  long encoding
          Encoding of this message.
protected  java.lang.String name
          Textual representation of this message type.
 
Constructor Summary
MessageType(java.lang.String name, long encoding)
          Constructor.
 
Method Summary
 boolean equals(java.lang.Object obj)
          Performs an equality check.
 long getEncoding()
          Get the encoding of this message type.
 java.lang.String getName()
          Get the textual representation of this message type.
 java.lang.String toString()
          Returns a string representation of this message type.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

encoding

protected long encoding
Encoding of this message. This number is used to check the equality of messages.

name

protected java.lang.String name
Textual representation of this message type.
Constructor Detail

MessageType

public MessageType(java.lang.String name,
                   long encoding)
Constructor.
Parameters:
name - textual representation of this message type
encoding - encoding
Method Detail

getEncoding

public long getEncoding()
Get the encoding of this message type.
Returns:
encoding

getName

public java.lang.String getName()
Get the textual representation of this message type.
Returns:
textual representation

equals

public boolean equals(java.lang.Object obj)
Performs an equality check. In this check a cast to MessageType of the given object is performed and both encodings are compared.
Overrides:
equals in class java.lang.Object
Parameters:
obj - message type to compare to
Returns:
true, if encodings are equal, false otherwise

toString

public java.lang.String toString()
Returns a string representation of this message type.
Overrides:
toString in class java.lang.Object
Returns:
string representation

eaLib API Docs
Last Modified : January 7 2002

Copyright © 2000-2001 Technical University of Ilmenau, Department ESS