|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.shale.dialog.basic.config.DialogImpl
public final class DialogImpl
DialogImpl is a basic implementation of Dialog.
| Constructor Summary | |
|---|---|
DialogImpl()
|
|
| Method Summary | |
|---|---|
void |
addState(State state)
Add the specified State to the States owned by
this Dialog. |
void |
addTransition(Transition transition)
Add the specified Transition to the global Transitions
associated with this Dialog. |
State |
findState(String id)
Return the specified State, owned by this Dialog,
if any. |
Transition |
findTransition(String outcome)
Return the global Transition for the specified logical outcome,
if any; otherwise, return null. |
Class |
getDataClass()
Return the class of a JavaBean to be instantiated as the initial value of the data property of a newly instantiated
DialogContext. |
String |
getDataClassName()
Return the data class name for the data property
of a newly instantiated DialogContext. |
String |
getName()
Return the name of this Dialog. |
String |
getStart()
Return the name of the starting State for this
Dialog. |
Iterator |
getStateIds()
Return an Iterator over the names of States
that are owned by this Dialog. |
Iterator |
getTransitionOutcomes()
Return an Iterator over the logical outcomes of
global Transitions for this Dialog. |
void |
removeState(State state)
Remove the specified State from the States owned by
this Dialog, if it is currently registered. |
void |
removeTransition(Transition transition)
Remove the specified Transition from the global
Transitions associated with this Dialog, if it is
currently registered. |
void |
setDataClassName(String dataClassName)
Set the data class name for the data property
of a newly instantiated DialogContext. |
void |
setName(String name)
Set the name of this Dialog. |
void |
setStart(String start)
Set the name of the starting State for this
Dialog. |
String |
toString()
Render a printable version of this instance. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public DialogImpl()
| Method Detail |
|---|
public Class getDataClass()
Return the class of a JavaBean to be instantiated as the initial
value of the data property of a newly instantiated
DialogContext.
getDataClass in interface Dialogdata
property of a new instance of this dialogpublic String getName()
Return the name of this Dialog.
getName in interface DialogDialogpublic String getStart()
Return the name of the starting State for this
Dialog.
getStart in interface DialogDialogpublic Iterator getStateIds()
Return an Iterator over the names of States
that are owned by this Dialog. If there are no such
States, an empty Iterator is returned.
getStateIds in interface DialogIterator over all the States in this
Dialogpublic Iterator getTransitionOutcomes()
Return an Iterator over the logical outcomes of
global Transitions for this Dialog. If there are
no such Transitions, an empty Iterator is
returned.
getTransitionOutcomes in interface DialogIterator over the logical outcomes of global
Transitions for this Dialogpublic State findState(String id)
Return the specified State, owned by this Dialog,
if any. Otherwise, return null.
findState in interface Dialogid - Identifier of the requested State
State specified by the identifier, may be nullpublic Transition findTransition(String outcome)
Return the global Transition for the specified logical outcome,
if any; otherwise, return null.
findTransition in interface Dialogoutcome - Logical outcome for which to return a Transition
Transition for the specified logical outcomepublic String toString()
Render a printable version of this instance.
toString in class Object
public void addState(State state)
throws IllegalArgumentException
Add the specified State to the States owned by
this Dialog.
state - State to be added
IllegalArgumentException - if there is already a State
with the specified id owned by this Dialog
public void addTransition(Transition transition)
throws IllegalArgumentException
Add the specified Transition to the global Transitions
associated with this Dialog.
transition - Transition to be added
IllegalArgumentException - if the specified Transition
cannot be added to this Statepublic String getDataClassName()
Return the data class name for the data property
of a newly instantiated DialogContext.
data property of a new instance of this dialogpublic void setDataClassName(String dataClassName)
Set the data class name for the data property
of a newly instantiated DialogContext.
dataClassName - New data class name
Exception - if the specified class name cannot be loadedpublic void setName(String name)
Set the name of this Dialog.
name - New namepublic void setStart(String start)
public void removeState(State state)
Remove the specified State from the States owned by
this Dialog, if it is currently registered. Otherwise,
do nothing.
state - State to be removedpublic void removeTransition(Transition transition)
Remove the specified Transition from the global
Transitions associated with this Dialog, if it is
currently registered. Otherwise, do nothing.
transition - Transition to be removed
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||