com.ldodds.foaf.thinlet
Class FieldState
java.lang.Object
|
+--com.ldodds.foaf.thinlet.FieldState
- public class FieldState
- extends java.lang.Object
Describes the state of a field, used to cache a fields original status
before altering it to (for example) display error cues. This wouldn't
be required if the Thinlet framework allowed arbitrary annotation of
components.
This code is Public Domain
- Author:
- ccslrd
Constructor Summary |
FieldState(ComponentManager thinlet,
java.lang.Object field)
Constructs a FieldState object
referring to a given field. |
Method Summary |
void |
add(java.lang.String property,
boolean b)
|
void |
add(java.lang.String property,
int i)
|
void |
add(java.lang.String property,
java.lang.Object value)
Adds a property to this FieldState. |
void |
addChoice(java.lang.String property,
java.lang.String choice)
|
boolean |
equals(java.lang.Object object)
|
int |
hashCode()
|
void |
reset()
Resets this fields properties to the values of the properties
contained in this FieldState instance. |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
FieldState
public FieldState(ComponentManager thinlet,
java.lang.Object field)
- Constructs a
FieldState
object
referring to a given field.
add
public void add(java.lang.String property,
java.lang.Object value)
- Adds a property to this FieldState. Can be used to
store original values of a fields properties so they can
be later reset.
add
public void add(java.lang.String property,
boolean b)
add
public void add(java.lang.String property,
int i)
addChoice
public void addChoice(java.lang.String property,
java.lang.String choice)
reset
public void reset()
- Resets this fields properties to the values of the properties
contained in this
FieldState
instance.
equals
public boolean equals(java.lang.Object object)
- Overrides:
equals
in class java.lang.Object
- See Also:
Object.equals(Object)
hashCode
public int hashCode()
- Overrides:
hashCode
in class java.lang.Object
- See Also:
Object.hashCode()