com.adventnet.tl1.message
Class TL1CommandCode

java.lang.Object
  |
  +--com.adventnet.tl1.message.TL1CommandCode

public class TL1CommandCode
extends java.lang.Object

This class represents the Command Code that is part of the TL1 Input Message. It specifies the action that needs to be initiated on the TL1 NE (Network Element). It contains the verb and optional modifiers. The verb identifies the action to be taken on the NE and the modifier specify the object on which the action is to be executed upon.

TL1 Input Message block


Constructor Summary
TL1CommandCode()
          Default constructor that creates an instance of the TL1CommandCode object.
TL1CommandCode(java.lang.String verb, java.lang.String[] modifiers)
          Constructors that creates an instance of the TL1CommandCode object with the the verb and modifiers initialized to the given values.
 
Method Summary
 java.lang.String[] getModifiers()
          Return the Command Modifiers.
 java.lang.String getModifierString()
          Return the Command Modifiers as a String.
 char getSeparator()
          Get the separator used to delimit the Command Modifiers.
 java.lang.String getVerb()
          Get the Command Verb that specifies the action needed to be initiated on the TL1 Network Element (device).
 boolean isModifier()
          Checks whether the Command Modifier field is set or not.
 void setModifiers(java.lang.String[] modifiers)
          Set the Command Modifiers with the given values.
 void setSeparator(char sep)
          Set the separator with the given value.
 void setVerb(java.lang.String verb)
          Set the Command Verb with the given value.
 java.lang.String toString()
          Return the String representation of this Object.
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

TL1CommandCode

public TL1CommandCode()
Default constructor that creates an instance of the TL1CommandCode object.

TL1CommandCode

public TL1CommandCode(java.lang.String verb,
                      java.lang.String[] modifiers)
Constructors that creates an instance of the TL1CommandCode object with the the verb and modifiers initialized to the given values.
Parameters:
verb - String representing the Command verb.
modifiers - String array representing the Command Modifiers.
Method Detail

getSeparator

public char getSeparator()
Get the separator used to delimit the Command Modifiers. It can be '-' or '#'.
Returns:
The separator as a character.

setSeparator

public void setSeparator(char sep)
Set the separator with the given value. It can be '-' or '#'.
Parameters:
sep - The separator character to set.

getVerb

public java.lang.String getVerb()
Get the Command Verb that specifies the action needed to be initiated on the TL1 Network Element (device).
Returns:
string representing the Command Verb.

setVerb

public void setVerb(java.lang.String verb)
Set the Command Verb with the given value.
Parameters:
verb - String representing the Commmand Verb.

setModifiers

public void setModifiers(java.lang.String[] modifiers)
Set the Command Modifiers with the given values.
Parameters:
modifiers - String array of size 2 representing the 2 Command Modifiers.

getModifiers

public java.lang.String[] getModifiers()
Return the Command Modifiers.
Returns:
string [] of size 2 representing the 2 Command Modifiers.

getModifierString

public java.lang.String getModifierString()
Return the Command Modifiers as a String. It converts the string array into a single string with the separator field seperating the individual array elements.
Returns:
String representing the modifiers.

isModifier

public boolean isModifier()
Checks whether the Command Modifier field is set or not.
Returns:
true - if the Command Modifier field is set ,
false otherwise

toString

public java.lang.String toString()
Return the String representation of this Object.
Overrides:
toString in class java.lang.Object
Returns:
String representation of this object.