|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.pkrete.jsip2.parser.SIP2ResponseParser
public abstract class SIP2ResponseParser
This is an abstract base class for all the response message parser classes, which task is to parse the response messages received from the ILS SIP server and create the corresponding objects.
| Constructor Summary | |
|---|---|
SIP2ResponseParser()
|
|
| Method Summary | |
|---|---|
protected boolean |
charEmptyToBool(char character)
Converts the given character to a boolean value. |
protected boolean |
charToBool(char character)
Converts the given character to a boolean value. |
protected boolean |
exists(String variable,
String data)
Returns true if and only if the given variable is present in the given string. |
protected boolean |
existsAndNotEmpty(String variable,
String data)
Returns true if and only if the given variable and a value are present in the given string. |
protected boolean |
intToBool(char character)
Converts the given character to a boolean value. |
abstract SIP2MessageResponse |
parse(String data)
Parses a SIP2MessageResponse from the given string. |
protected String |
parseChecksum(String data)
Parses the checksum from the given string. |
protected String |
parseSequence(String data)
Parses the sequence from the given string. |
protected String |
parseVariable(String variable,
String data)
Parses the value of the given variable from the given data string. |
protected String |
parseVariable(String variable,
String data,
boolean required)
Parses the value of the given variable from the given data string. |
protected List<String> |
parseVariableMulti(String variable,
String data)
Parses the value of the given variable from the given data string. |
protected String |
parseVariableWithoutDelimiter(String variable,
String data)
Parses the value of the given variable from the given data string. |
protected String |
parseVariableWithoutDelimiter(String variable,
String data,
boolean required)
Parses the value of the given variable from the given data string. |
protected int |
stringToInt(String value)
Converts the given string to an integer. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public SIP2ResponseParser()
| Method Detail |
|---|
public abstract SIP2MessageResponse parse(String data)
throws InvalidSIP2ResponseValueException,
InvalidSIP2ResponseException
data - message response data
InvalidSIP2ResponseValueException
InvalidSIP2ResponseException
protected boolean intToBool(char character)
throws InvalidSIP2ResponseValueException
character - char to be converted
InvalidSIP2ResponseValueException
protected boolean charToBool(char character)
throws InvalidSIP2ResponseValueException
character - char to be converted
InvalidSIP2ResponseValueException
protected int stringToInt(String value)
throws InvalidSIP2ResponseValueException
value - string to be converted
InvalidSIP2ResponseValueException
protected boolean charEmptyToBool(char character)
throws InvalidSIP2ResponseValueException
character - char to be converted
InvalidSIP2ResponseValueException
protected String parseVariable(String variable,
String data,
boolean required)
variable - code of the variable, 2 charactersdata - data stringrequired - true if the variable is required, false if optional
protected String parseVariable(String variable,
String data)
variable - code of the variable, 2 charactersdata - data string
protected String parseVariableWithoutDelimiter(String variable,
String data,
boolean required)
variable - code of the variable, 2 charactersdata - data stringrequired - true if the variable is required, false if optional
protected String parseVariableWithoutDelimiter(String variable,
String data)
variable - code of the variable, 2 charactersdata - data string
protected List<String> parseVariableMulti(String variable,
String data)
variable - code of the variable, 2 charactersdata - data string
protected String parseSequence(String data)
data - data string
protected String parseChecksum(String data)
data - data string
protected boolean exists(String variable,
String data)
variable - code of the variable, 2 charactersdata - data string
protected boolean existsAndNotEmpty(String variable,
String data)
variable - code of the variable, 2 charactersdata - data string
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||