|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object | +--com.adventnet.agent.tl1.TL1AgentResponseInfo
This class is used to hold the information of the response block for both response messages and autonomous messages. The object of this class will be returned from the doAction() method of the generated code. These details will be taken into account by the agent while sending the response/autonomous messages.
| Field Summary | |
static java.lang.String |
COMMENT
This variable describes that the TL1Line is a comment. |
static java.lang.String |
QUOTED
This variable describes that the TL1Line is a quoted one. |
static java.lang.String |
UNQUOTED
This variable describes that the TL1Line is an Unquoted one. |
| Constructor Summary | |
TL1AgentResponseInfo()
Default Constructor |
|
TL1AgentResponseInfo(java.util.Hashtable[] responseLines,
java.lang.String[] responseLineTypes,
boolean[] nameEqualsValue,
java.lang.String[] responseKeys,
java.lang.String completionCode)
Constructor to initialise the TL1AgentResponseInfo. |
|
TL1AgentResponseInfo(java.util.Hashtable[] responseLines,
java.lang.String[] responseLineTypes,
boolean[] nameEqualsValue,
java.lang.String[] responseKeys,
java.util.Vector sessionList,
java.lang.String alarmCode)
Constructor to initialise the TL1AgentResponseInfo. |
|
| Method Summary | |
java.lang.String |
getAlarmCode()
Getter for Alarm code of the autonomous message. |
double |
getATag()
Getter for the atag of the autonomous message. |
(package private) java.lang.String |
getCommandCode()
Thease methods are included for the getting or setting command codes for autoInfo while creating autonomous messages. |
java.lang.String |
getCompletionCode()
Getter for the completion code of the response message. |
java.lang.String[] |
getResponseDelimiters()
Getter for the response delimiters in a particular response. |
java.lang.String[] |
getResponseKeys()
Getter for the response keys. |
java.util.Hashtable[] |
getResponseLines()
Getter for responseLines. |
java.util.Vector |
getResponseLinesVector()
Returns the Vector having TL1Line objects as it's elements. |
java.lang.String[] |
getResponseLineTypes()
Getter for responseLineTypes. |
java.util.Vector |
getSessionList()
Getter for session list. |
java.lang.String |
getSourceIdentifier()
|
boolean[] |
isNameEqualsValue()
To check whether each line in the responseBlock is name-defined or position-defined. |
void |
setAlarmCode(java.lang.String alarmCode)
Used to set the alarm code for the autonomous message. |
void |
setATag(double aTag)
Used to set the atag of the autonomous message. |
void |
setCommandCode(java.lang.String command)
Setting the command code. |
void |
setCompletionCode(java.lang.String completionCode)
Used to set the completion code of the response message. |
void |
setNameEqualsValue(boolean[] nameEqualsValue)
Used to specify whether a response block is name-defined or position-defined. |
void |
setResponseDelimiters(java.lang.String[] delimiters)
Used to set the delimiters of a response/autonomous message. |
void |
setResponseKeys(java.lang.String[] keys)
Used to set the response keys. |
void |
setResponseLines(java.util.Hashtable[] responseLines)
Used to set the responseLineTypes. |
void |
setResponseLinesVector(java.util.Vector respVec)
Set the ResponseLinesVector. |
void |
setResponseLineTypes(java.lang.String[] responseLineTypes)
Used to set the responseLineTypes. |
void |
setSessionList(java.util.Vector sessionList)
Used to set the TL1SessionList which should receive the autonomous message. |
void |
setSourceIdentifier(java.lang.String sid)
|
| Methods inherited from class java.lang.Object |
|
| Field Detail |
public static final java.lang.String QUOTED
public static final java.lang.String UNQUOTED
public static final java.lang.String COMMENT
| Constructor Detail |
public TL1AgentResponseInfo()
public TL1AgentResponseInfo(java.util.Hashtable[] responseLines,
java.lang.String[] responseLineTypes,
boolean[] nameEqualsValue,
java.lang.String[] responseKeys,
java.lang.String completionCode)
responseLines - An Hashtable array containing the name - value
pairs of each line.responseLineTypes - A String array mentioning the line types
of each line - whether quoted or unquoted
or comment.nameEqualsValue - This specifies whether each line in the response
block should be name-defined or position-defined.responseKeys - The response keys for a particular command code.completionCode - The completion code of the Autonomous Message.
If it is null, it will be taken as COMPLD.
public TL1AgentResponseInfo(java.util.Hashtable[] responseLines,
java.lang.String[] responseLineTypes,
boolean[] nameEqualsValue,
java.lang.String[] responseKeys,
java.util.Vector sessionList,
java.lang.String alarmCode)
responseLines - An Hashtable array containing the name - value
pairs of each line.responseLineTypes - A String array mentioning the line types
of each line - whether quoted or unquoted
or comment.nameEqualsValue - This specifies whether each line in the response
block should be name-defined or position-defined.responseKeys - The response keys for a particular command code.sessionList - A vector of TL1Sessions.alarmCode - The alarm code of the Autonomous Message.
If it is null, it will be taken as MAJOR_ALARM.| Method Detail |
public java.lang.String[] getResponseLineTypes()
public void setResponseLineTypes(java.lang.String[] responseLineTypes)
responseLineTypes - A String array mentioning the line types
of each line - whether quoted or unquoted
or comment.
For Example:
String[] lineTypes = new String[2];
lineTypes[0] = TL1AgentResponseInfo.UNQUOTED;
lineTypes[1] = TL1AgentResponseInfo.QUOTED;
TL1AgentResponseInfo respInfo = new TL1AgentResponseInfo();
respInfo.setResponseLineTypes(lineTypes);
public java.util.Hashtable[] getResponseLines()
public void setResponseLines(java.util.Hashtable[] responseLines)
responseLines - An Hashtable array which contains the name - value
pairs of the response lines. Each element in the
array represents a line.
For Example:
Hashtable[] table = new Hashtable[2];
table[0] = new Hashtable();
table[1] = new Hashtable();
for(int i=0; i<responseKeys.length; i++) {
table[0].put(responseKeys[i], defaultRespVals[i]);
table[1].put(responseKeys[i], responseVals[i]);
}
TL1AgentResponseInfo respInfo = new TL1AgentResponseInfo();
respInfo.setResponseLines(table);
public boolean[] isNameEqualsValue()
public void setNameEqualsValue(boolean[] nameEqualsValue)
nameEqualsValue - Specifies how each line should be -
either name-defined or position-defined.public java.lang.String[] getResponseKeys()
public void setResponseKeys(java.lang.String[] keys)
keys - The Keys as a String array.public java.lang.String[] getResponseDelimiters()
public void setResponseDelimiters(java.lang.String[] delimiters)
delimiters - The delimiters that will be used in a response.public java.lang.String getCompletionCode()
TL1ResponseMessagepublic void setCompletionCode(java.lang.String completionCode)
completionCode - The completion code. If it is not mentioned,
it will be taken as COMPLD.TL1ResponseMessagepublic java.lang.String getAlarmCode()
TL1AutonomousMessagepublic void setAlarmCode(java.lang.String alarmCode)
alarmCode - The alarm code.TL1AutonomousMessagepublic java.util.Vector getSessionList()
public void setSessionList(java.util.Vector sessionList)
sessionList - A vector of session list.public double getATag()
public void setATag(double aTag)
aTag - The A-Tag as a double.public java.util.Vector getResponseLinesVector()
public void setResponseLinesVector(java.util.Vector respVec)
respVec - - The Vector containg response lines.java.lang.String getCommandCode()
public java.lang.String getSourceIdentifier()
public void setCommandCode(java.lang.String command)
command - - command code to be shown in autonomous message.public void setSourceIdentifier(java.lang.String sid)
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||