java.lang.Object
org.tentackle.model.parse.OptionParser
Parses [...] options.
- Author:
- harald
-
Constructor Summary
ConstructorsConstructorDescriptionOptionParser(String text, StringBuilder other) Creates a parser for the given text. -
Method Summary
Modifier and TypeMethodDescriptionGets the next option as a string.nextOption(int stopAtOptionLevel) Gets the next option as a string.
-
Constructor Details
-
OptionParser
Creates a parser for the given text.- Parameters:
text- the text to parse, usually a commentother- buffer that gets ignored text outside [...], null if text is not enclosed in square brackets
-
-
Method Details
-
nextOption
Gets the next option as a string.- Returns:
- the next option, null if end of text
-
nextOption
Gets the next option as a string.- Parameters:
stopAtOptionLevel- option level to stop on closing bracket- Returns:
- the next option, null if end of text
-