|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectedu.harvard.deas.hyperenc.MessageParser
public abstract class MessageParser
Parses the contents of protocol messages.
Constructor Summary | |
---|---|
MessageParser()
|
Method Summary | |
---|---|
abstract String |
mrecToString(List<Pair<Integer,byte[]>> lst)
Converts a master reconciliation message hash list into a string. |
abstract List<Pair<Integer,byte[]>> |
parseMRec(String message)
Converts the raw contents of a master reconciliation message into a list of pairs; each pair contains an integer ID identifying a page, and the hash of that page. |
abstract List<Pair<Integer,SlaveRecResult>> |
parseSRec(String message)
Converts the raw contents of a slave reconciliation message into a list of pairs; each pair contains an integer ID identifying a page, and a code indicating the result of the reconciliation. |
abstract String |
srecToString(List<Pair<Integer,SlaveRecResult>> lst)
Converts a slave reconciliation message hash list into a string. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public MessageParser()
Method Detail |
---|
public abstract List<Pair<Integer,byte[]>> parseMRec(String message) throws MessageParseException
message
- the raw message
MessageParseException
- if message
cannot be parsedpublic abstract List<Pair<Integer,SlaveRecResult>> parseSRec(String message) throws MessageParseException
message
- the raw message
MessageParseException
- if message
cannot be parsedpublic abstract String mrecToString(List<Pair<Integer,byte[]>> lst)
parseMRec
; passing a list to this
method, then parsing the returned string with parseMRec
yields
a list equivalent to the original.
lst
- a list of ID-hash pairs
public abstract String srecToString(List<Pair<Integer,SlaveRecResult>> lst)
parseSRec
; passing a list to this
method, then parsing the returned string with parseSRec
yields
a list equivalent to the original.
lst
- a list of ID-result code pairs
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |