|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--shout3d.core.Field
An abstract class which is subclassed to create Shout3D Fields
Constructor Summary | |
Field(Node owner,
java.lang.String name,
int usage)
Constructs this Field |
Method Summary | |
void |
addFieldObserver(FieldObserver fo,
java.lang.Object userData)
This method registers the interest of a FieldObserver |
boolean |
addRoute(Field toField)
Adds a route that copies values from this field to 'toField' each time that fromField's value changes. |
boolean |
deleteRoute(Field toField)
Removes any existing route from this field to toField Returns true if a route existed and was removed, false otherwise Note: Routes of ArrayFields copy by reference, not by value. |
void |
fieldNotify()
Notifies all registered observers and routes that the field was changed. |
java.lang.String |
getName()
Gets this Field's name. |
int |
getNumRoutes()
Returns the number of fields to which this field is routed. |
Node |
getOwner()
Gets this Field's owner. |
Field |
getRoutedField(int i)
Returns a field to which this field is routed to. |
java.lang.String |
getTypeName()
Gets a string representing this Field's type |
int |
getUsage()
Gets this Field's usageType. |
java.lang.String |
getValueByString()
|
boolean |
isOfType(java.lang.String type)
Returns whether this field is of the same type, or a type derived from, the Field type given by the input string. |
boolean |
isRouted(Field toField)
Checks if a route currently exists from this field to toField |
void |
removeFieldObserver(FieldObserver fo)
This method unregisters the interest of a FieldObserver |
void |
setValueByString(java.lang.String string)
|
Methods inherited from class java.lang.Object |
equals,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
Constructor Detail |
public Field(Node owner, java.lang.String name, int usage)
owner
- this field's ownername
- this field's nameusage
- this field's usageMethod Detail |
public Node getOwner()
public int getUsage()
public java.lang.String getName()
public java.lang.String getTypeName()
public boolean isOfType(java.lang.String type)
type
- the field type stringpublic void addFieldObserver(FieldObserver fo, java.lang.Object userData)
observer
- the FieldObserveruserData
- data that will be passed back to the observer's
onFieldChange method.public void removeFieldObserver(FieldObserver fo)
observer
- the FieldObserver to unregisterpublic boolean addRoute(Field toField) throws Shout3DException
toField
- the field to which values will be copiedpublic boolean deleteRoute(Field toField)
toField
- the field to which values will be copiedpublic int getNumRoutes()
public Field getRoutedField(int i)
public boolean isRouted(Field toField)
public void fieldNotify()
public void setValueByString(java.lang.String string)
public java.lang.String getValueByString()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |