Class ParseState
java.lang.Object
org.springframework.beans.factory.parsing.ParseState
Simple
ArrayDeque
-based structure for tracking the logical position during
a parsing process. entries
are added to the ArrayDeque at each point
during the parse phase in a reader-specific manner.
Calling toString()
will render a tree-style view of the current logical
position in the parse phase. This representation is intended for use in error messages.
- Since:
- 2.0
- Author:
- Rob Harrop, Juergen Hoeller
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic interface
Marker interface for entries into theParseState
. -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionpeek()
Return theParseState.Entry
currently at the top of theArrayDeque
ornull
if theArrayDeque
is empty.void
pop()
Remove anParseState.Entry
from theArrayDeque
.void
push
(ParseState.Entry entry) Add a newParseState.Entry
to theArrayDeque
.snapshot()
Create a new instance ofParseState
which is an independent snapshot of this instance.toString()
Returns a tree-style representation of the currentParseState
.
-
Constructor Details
-
ParseState
public ParseState()Create a newParseState
with an emptyArrayDeque
.
-
-
Method Details
-
push
Add a newParseState.Entry
to theArrayDeque
. -
pop
public void pop()Remove anParseState.Entry
from theArrayDeque
. -
peek
Return theParseState.Entry
currently at the top of theArrayDeque
ornull
if theArrayDeque
is empty. -
snapshot
Create a new instance ofParseState
which is an independent snapshot of this instance. -
toString
Returns a tree-style representation of the currentParseState
.
-