public class IllegalEventException extends InconsistentAdapterDataException
JPhyloIOEventReceiver and indicates that a data adapter passed
an event that is illegal at the current position according to the grammar defined in the documentation of
JPhyloIOEventReader.
The cause for this exception would usually be an error in the implementation of a data adapter.
| Constructor and Description |
|---|
IllegalEventException(java.lang.String message,
JPhyloIOEventReceiver receiver,
JPhyloIOEvent parentEvent,
JPhyloIOEvent invalidEvent) |
| Modifier and Type | Method and Description |
|---|---|
JPhyloIOEvent |
getInvalidEvent() |
JPhyloIOEvent |
getParentEvent() |
JPhyloIOEventReceiver |
getReceiver() |
static IllegalEventException |
newInstance(JPhyloIOEventReceiver receiver,
JPhyloIOEvent parentEvent,
JPhyloIOEvent invalidEvent)
Tool method that creates a new instance of this class.
|
boolean |
wasAtReceiverRootLevel() |
public IllegalEventException(java.lang.String message, JPhyloIOEventReceiver receiver, JPhyloIOEvent parentEvent, JPhyloIOEvent invalidEvent)
public static IllegalEventException newInstance(JPhyloIOEventReceiver receiver, JPhyloIOEvent parentEvent, JPhyloIOEvent invalidEvent)
null, a different exception message will be used.receiver - the receiver throwing the returned exceptionparentEvent - the current parent event or nullinvalidEvent - the invalid element that was encounteredpublic JPhyloIOEventReceiver getReceiver()
public JPhyloIOEvent getParentEvent()
public boolean wasAtReceiverRootLevel()
public JPhyloIOEvent getInvalidEvent()