Interface MessageParser<T>
- Type Parameters:
T- type of the file
- All Known Implementing Classes:
AbstractConstituentParser,AbstractMessageParser,AcmParser,AdmParser,AemParser,ApmParser,CdmParser,NdmParser,OcmParser,OdmParser,OemParser,OmmParser,OpmParser,TdmParser
public interface MessageParser<T>
Parser for CCSDS messages.
- Since:
- 11.0
- Author:
- Luc Maisonobe
-
Method Summary
Modifier and TypeMethodDescriptionbuild()Build the file from parsed entries.Get the file format of the last message parsed.Get the key for format version.Get the non-default token builders for special XML elements.parseMessage(DataSource source) Parse a data source.voidprocess(ParseToken token) Process a parse token.voidreset(FileFormat fileFormat) Reset parser to initial state before parsing.
-
Method Details
-
parseMessage
Parse a data source.- Parameters:
source- data source to parse- Returns:
- parsed file
-
getFormatVersionKey
String getFormatVersionKey()Get the key for format version.- Returns:
- format version key
-
getSpecialXmlElementsBuilders
Map<String,XmlTokenBuilder> getSpecialXmlElementsBuilders()Get the non-default token builders for special XML elements.- Returns:
- map of token builders for special XML elements (keyed by XML element name)
-
reset
Reset parser to initial state before parsing.- Parameters:
fileFormat- format of the file ready to be parsed
-
process
Process a parse token.- Parameters:
token- token to process
-
build
T build()Build the file from parsed entries.- Returns:
- parsed file
-
getFileFormat
FileFormat getFileFormat()Get the file format of the last message parsed.- Returns:
- file format of the last message parsed
- Since:
- 12.0
-