Package org.orekit.files.sinex
Class BlockParser<T extends ParseInfo<?>>
java.lang.Object
org.orekit.files.sinex.BlockParser<T>
- Type Parameters:
T- type of the sinex files parse info
- All Implemented Interfaces:
LineParser<T>
- Direct Known Subclasses:
IgnoredBlockParser
Parser for SINEX block.
- Since:
- 13.0
- Author:
- Luc Maisonobe
-
Constructor Summary
ConstructorsConstructorDescriptionBlockParser(String blockId, List<Predicate<T>> predicates) Simple constructor. -
Method Summary
Modifier and TypeMethodDescriptionallowedNextParsers(T parseInfo) Get allowed next line parsers.protected booleancheckEntering(T parseInfo) Check if we are at the start marker.protected booleancheckLeaving(T parseInfo) Check if we are at the end marker.protected booleanCheck if we are outside block.booleanparseIfRecognized(T parseInfo) Parse a line if recognized.voidsetSiblingParsers(List<LineParser<T>> siblingParsers) Set allowed parsers when leaving this block.
-
Constructor Details
-
BlockParser
Simple constructor.- Parameters:
blockId- regular expression for block namepredicates- predicates for parsing block content lines
-
-
Method Details
-
setSiblingParsers
Set allowed parsers when leaving this block.- Parameters:
siblingParsers- allowed parsers when leaving this block
-
parseIfRecognized
Parse a line if recognized.- Specified by:
parseIfRecognizedin interfaceLineParser<T extends ParseInfo<?>>- Parameters:
parseInfo- holder for transient data- Returns:
- true if line was recognized
-
allowedNextParsers
Get allowed next line parsers.- Specified by:
allowedNextParsersin interfaceLineParser<T extends ParseInfo<?>>- Parameters:
parseInfo- holder for transient data- Returns:
- allowed parszers for next lines
-
outsideBlock
protected boolean outsideBlock()Check if we are outside block.- Returns:
- true if we are at block end
-
checkEntering
Check if we are at the start marker.- Parameters:
parseInfo- holder for transient data- Returns:
- true if we are at block start
-
checkLeaving
Check if we are at the end marker.- Parameters:
parseInfo- holder for transient data- Returns:
- true if we are at block end
-