com.adventnet.tl1.message
Class TL1AckMessage

java.lang.Object
  |
  +--com.adventnet.tl1.message.TL1Message
        |
        +--com.adventnet.tl1.message.TL1AckMessage

public class TL1AckMessage
extends TL1Message

This object represents a TL1 Acknowledgement Message type which is a brief Output Message generated in reponse to an Input Message. Usually, if the TL1 NE (Network Element) is unable to send the response message to the Manager within two seconds, then it sends the Acknowledgement Message. This message contains an Acknowledgement code that identifies the reason for sending the Acknowledgement Message.

TL1 Acknowledgement Message block

The Acknowledgement Message can have one of the following Acknowledgement Codes:

See Also:
IN_PROGRESS, PRINTOUT_FOLLOWS, ALL_RIGHT, NO_ACKNOWLEDGEMENT, NO_GOOD, REPEAT_LATER

Field Summary
static java.lang.String ALL_RIGHT
          Constant for Ack code that represents request All Right.
static java.lang.String IN_PROGRESS
          Constant for Ack code that represents request In Progress.
static java.lang.String NO_ACKNOWLEDGEMENT
          Constant for Ack code that represents No Acknowledgement.
static java.lang.String NO_GOOD
          Constant for Ack code that represents No Good.
static java.lang.String PRINTOUT_FOLLOWS
          Constant for Ack code that represents Printout Follows.
static java.lang.String REPEAT_LATER
          Constant for Ack code that represents Repeat Later.
 
Constructor Summary
TL1AckMessage()
          The Default Constructor which creates an instance of the TL1AckMessage.
TL1AckMessage(java.lang.String ackCode, java.lang.String correlationTag)
          The constructor which creates an instance of the TL1AckMessage with the Acknowledgement Code and Correlation Tag intialized to the specified values.
 
Method Summary
 byte[] encode()
          Encodes the TL1AckMessage.
 java.lang.String getAckCode()
          Get the Acknowledgement Code set on this message.
 java.lang.String getCorrelationTag()
          Get the Correlation Tag.
 int getSize()
          Returns the length of the message.
 void setAckCode(java.lang.String ackCode)
          Set the Acknowledgement Code of the message with the specified value.
 void setCorrelationTag(java.lang.String correlationTag)
          Set the Correlation Tag of the message with the specified value.
 
Methods inherited from class com.adventnet.tl1.message.TL1Message
getType, isSetSplCharParsing, setSplCharParsing, setType, toString
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

IN_PROGRESS

public static java.lang.String IN_PROGRESS
Constant for Ack code that represents request In Progress. This code indicates that the request has been initiated

PRINTOUT_FOLLOWS

public static java.lang.String PRINTOUT_FOLLOWS
Constant for Ack code that represents Printout Follows. This code indicates that the request has been initiated and a termination report may follow.

ALL_RIGHT

public static java.lang.String ALL_RIGHT
Constant for Ack code that represents request All Right. This code indicates that the request was received and the action was executed.

NO_ACKNOWLEDGEMENT

public static java.lang.String NO_ACKNOWLEDGEMENT
Constant for Ack code that represents No Acknowledgement. This code indicates an abnormal condition where the execution status of the requested command is uncertain.

NO_GOOD

public static java.lang.String NO_GOOD
Constant for Ack code that represents No Good. This code indicates a valid command that cannot be executed due to inconsistant state of system parameters.

REPEAT_LATER

public static java.lang.String REPEAT_LATER
Constant for Ack code that represents Repeat Later. This code indicates that the command cannot be executed due to non availability of system resources.
Constructor Detail

TL1AckMessage

public TL1AckMessage()
The Default Constructor which creates an instance of the TL1AckMessage.

TL1AckMessage

public TL1AckMessage(java.lang.String ackCode,
                     java.lang.String correlationTag)
The constructor which creates an instance of the TL1AckMessage with the Acknowledgement Code and Correlation Tag intialized to the specified values.
Parameters:
ackCode - String representing Acknowledgement Code.
correlationTag - String representing Correlation Tag.
Method Detail

setCorrelationTag

public void setCorrelationTag(java.lang.String correlationTag)
Set the Correlation Tag of the message with the specified value. it is used to correlate the Output Message to the specific Input Message.
Parameters:
correlationTag - String representing ctag value.

getCorrelationTag

public java.lang.String getCorrelationTag()
Get the Correlation Tag. It is used to correlate the Output Message to the specific Input Message.
Returns:
String representing correlationTag.

getAckCode

public java.lang.String getAckCode()
Get the Acknowledgement Code set on this message. It can be any one of IP , PF , OK , NG ,NA , RL.
Returns:
String representing AckCode.

setAckCode

public void setAckCode(java.lang.String ackCode)
Set the Acknowledgement Code of the message with the specified value. It can be any one of IP , PF , OK ,NG ,NA , RL.
Parameters:
ackCode - String.

getSize

public int getSize()
Returns the length of the message.
Returns:
size as an integer.

encode

public byte[] encode()
Encodes the TL1AckMessage. Not to be used by the user. This method is internally used by the API.
Overrides:
encode in class TL1Message
Returns:
Returns the encoded form of the Acknowledgement Message.