|
GXPARSE hosted by |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectca.gorman.xml.parse.toolkit.Coroutine_NoCallback<T>
ca.gorman.xml.parse.toolkit.Coroutine_Callback<T>
ca.gorman.xml.parse.toolkit.CoroutineEntityStack<T>
public final class CoroutineEntityStack<T extends Parser>
Entity stack
implemented for
coroutine parser.
Constructor Summary | |
---|---|
|
CoroutineEntityStack()
Construct instance that cannot be used until initialized by setCoroutine ,
setListener and
setParser . |
protected |
CoroutineEntityStack(Coroutine coroutine)
Construct instance that cannot be used until initialized by setListener and
setParser . |
protected |
CoroutineEntityStack(Coroutine coroutine,
EntityListener<T> entityListener)
Construct instance that cannot be used until initialized by setParser . |
Method Summary | |
---|---|
Entity |
getCurrentEntity()
Get the CurrentEntity at the top of the stack
without removing it from the stack. |
EntityListener<T> |
getListener()
Get the listener . |
boolean |
isEmpty()
Indicate whether entity stack is empty. |
Entity |
pop()
Remove the current entity from the top of the
stack. |
void |
push(CoroutineEntity<T> coroutineEntity)
Push a CoroutineEntity on the entity stack from
the parser thread, and invoke an
entity handler
on the entity as current entity in the
application thread. |
void |
setListener(EntityListener<T> entityListener)
Set or reset the listener . |
Methods inherited from class ca.gorman.xml.parse.toolkit.Coroutine_Callback |
---|
getCoroutine, setCoroutine |
Methods inherited from class ca.gorman.xml.parse.toolkit.Coroutine_NoCallback |
---|
getParser, setParser |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public CoroutineEntityStack()
Construct instance that cannot be used until initialized by
setCoroutine
,
setListener
and
setParser
.
protected CoroutineEntityStack(Coroutine coroutine)
Construct instance that cannot be used until initialized by
setListener
and
setParser
.
NullPointerException
- if coroutine is nullprotected CoroutineEntityStack(Coroutine coroutine, EntityListener<T> entityListener)
Construct instance that cannot be used until initialized by
setParser
.
NullPointerException
- if coroutine or entityListener is nullMethod Detail |
---|
public void setListener(EntityListener<T> entityListener)
Set or reset the listener
.
NullPointerException
- if entityListener is nullpublic EntityListener<T> getListener()
Get the listener
.
public void push(CoroutineEntity<T> coroutineEntity)
Push a CoroutineEntity
on the entity stack from
the parser thread, and invoke an
entity handler
on the entity as current entity
in the
application thread.
push
in interface EntityStack<T extends Parser>
public Entity pop()
EntityStack
Remove the current entity
from the top of the
stack. The entity is no longer valid as an instance of
CurrentEntity
. The entity is normally popped
when it goes out of scope in the document, in which case it will not
be valid even as an instance of the superclass Entity
.
pop
in interface EntityStack<T extends Parser>
public boolean isEmpty()
EntityStack
Indicate whether entity stack is empty.
isEmpty
in interface EntityStack<T extends Parser>
public Entity getCurrentEntity()
EntityStack
Get the CurrentEntity
at the top of the stack
without removing it from the stack.
getCurrentEntity
in interface EntityStack<T extends Parser>
|
GXPARSE download | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |