StringChars class
Parses the internal parts of a string (all characters except quotes) in the following order:
- Applies a predicate to parse the normal characters of the string
- Checks (and consumes) if the next character is an escape control character
- Invokes the escape sequence parser if a control character is consumed
- Repeats everything from the beginning if at least one parse succeeded
At the end of the parsing the parts, combines everything into one string value and parsing completes successfully.
Returns the combined (from parts) string value.
- Inheritance
-
- Object
- Parser<
StringReader, String> - StringChars
Constructors
-
StringChars.new(bool isNormalChar(int), int controlChar, Parser<
StringReader, String> escapeChar, {String? name}) -
const
Properties
- controlChar → int
-
final
-
escapeChar
→ Parser<
StringReader, String> -
final
- getInputType → Type
-
no setterinherited
- getOutputType → Type
-
no setterinherited
- hashCode → int
-
The hash code for this object.
no setterinherited
- isNormalChar → bool Function(int)
-
final
- name → String?
-
finalinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
backtrack(
State< ChunkedData< state) → boolStringReader> > -
inherited
-
build(
ParserBuilder< StringReader> builder) → Parser<StringReader, String> -
Builds a new parser using the specified
builder
.override -
fastParse(
State< StringReader> state) → bool -
Parses the input and returns
true
if successful,false
otherwise.override -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
parse(
State< StringReader> state) → Result<String> ? -
Parses the input and returns a result wrapped in Result if successful,
null
otherwise.override -
parseAsync(
State< ChunkedData< state) → AsyncResult<StringReader> >String> -
Experimental. Not yet fully implemented
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited