|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectfr.lri.swingstates.sm.Tag
fr.lri.swingstates.sm.JTag
fr.lri.swingstates.sm.JExtensionalTag
fr.lri.swingstates.sm.JNamedTag
public class JNamedTag
A JNamedTag tag is a JExtensionalTag.
A JNamedTag tag is a set of components having the same label.
One can create a CNamedTag named "colorable":
CNamedTag tag = new CNamedTag("colorable");
and use transitions in state machine like:
Transition onAnyColor = new Press("colorable", BUTTON1) {
public void action() {
...
}
};
JExtensionalTag| Constructor Summary | |
|---|---|
JNamedTag(java.lang.String n)
Builds a JNamedTag tag. |
|
| Method Summary | |
|---|---|
static void |
clear()
Clear all registered tags. |
java.lang.String |
getName()
Returns the name of this tag. |
static JNamedTag |
getTag(java.lang.String t)
Returns the tag object given its name. |
static java.util.LinkedList |
getTaggedComponents(java.lang.String t)
Returns the list of components that have a given tag. |
boolean |
setName(java.lang.String n)
Sets the name of this tag. |
| Methods inherited from class fr.lri.swingstates.sm.JExtensionalTag |
|---|
added, addTo, removed, removeFrom, reset |
| Methods inherited from class fr.lri.swingstates.sm.JTag |
|---|
action, action, getTaggedComponents, hasNext, next, nextComponent, setBackground, tagsComponent, tagsComponent |
| Methods inherited from class fr.lri.swingstates.sm.Tag |
|---|
getCollection, remove, size |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public JNamedTag(java.lang.String n)
JNamedTag tag.
Note that if a tag with the same name already exists, this new tag is not registered and the results are undefined.
This constructor is left public and does not throw an exception in order to make it possible to create anonymous classes derived from JNamedTag.
n - The name of the tag| Method Detail |
|---|
public static void clear()
public static java.util.LinkedList getTaggedComponents(java.lang.String t)
t - The name of the tag
public static JNamedTag getTag(java.lang.String t)
t - The name of the tag
public java.lang.String getName()
public boolean setName(java.lang.String n)
n - The name.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||