|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectblackboard.data.BbAttribute
public class BbAttribute
The BbAttribute class is used to form the basis of the name/value
pairs used for IBbObject based object properties. Beyond the basic
name and value information, this object also provides additional information
regarding the "state" of an attribute. This "state" information is internally
controlled and should be useful in some special circumstances.
This object can not be directed instantiated or manipulated and therefore, the
majority of interaction with it will be through its parent container BbAttributes.
| Nested Class Summary | |
|---|---|
static class |
BbAttribute.Type
|
| Constructor Summary | |
|---|---|
protected |
BbAttribute(BbAttribute.Type eType,
java.lang.String strName,
java.lang.Object val,
BbAttributes parent)
Initialization with generic object but of a specific type. |
| Method Summary | |
|---|---|
boolean |
getIsDirty()
Get the "dirty" status of this BbAttribute. |
boolean |
getIsReadOnly()
Returns value of the isReadOnly flag. |
boolean |
getIsSet()
Retrieve "set" status of this BbAtribute. |
java.lang.String |
getName()
Retrieves name ("key") associated with this BbAttribute object. |
BbAttribute.Type |
getType()
Retrieves BbAttribute object type. |
java.lang.Object |
getValue()
Retrieves object value associated with BbAttribute object. |
void |
setIsDirty(boolean bIsDirty)
Sets "dirty" (changed) status of BbAttribute |
void |
setIsReadOnly(boolean isReadOnly)
Sets the value of the isReadOnly flag. |
protected void |
setIsSet(boolean bIsSet)
Sets the "has been set" status of this BbAttribute. |
protected void |
setValue()
Sets the value of this BbAttribute to "unset". |
void |
setValue(java.lang.Object val)
Sets value object with type Object. |
java.lang.String |
toString()
Converts this BbAttribute value to a string representation. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
protected BbAttribute(BbAttribute.Type eType,
java.lang.String strName,
java.lang.Object val,
BbAttributes parent)
eType - The BbAttribute.Type describing the attribute object type.strName - The string describing the attributes key.val - The Object describing the attributes value.parent - the parent BbAttributes object that will "contain" this attribute.| Method Detail |
|---|
public java.lang.String getName()
BbAttribute object.
public BbAttribute.Type getType()
BbAttribute.Typepublic boolean getIsReadOnly()
isReadOnly flag. If an attribute
is read-only, attempting to set it would result in an ImmutableException
being thrown
public void setIsReadOnly(boolean isReadOnly)
isReadOnly flag.
isReadOnly - The isReadOnly to set.public java.lang.Object getValue()
protected void setValue()
BbAttribute to "unset". The "unset"
case results in an ambiguous attribute value but will result in a sensible
default being used should the attribute value be retrieved. The "unset"
case will typically signify the state where an attribute value has not
been loaded as in the case of a "light-weight" load being performed. In
this case, the objects contained by the heavy object will have not been
loaded and therefore be in an "unset" state.
public void setValue(java.lang.Object val)
Object.
val - The new attribute value.public boolean getIsSet()
BbAtribute. Unless an attribute
value is "set", any value retrieved through getValue() will be
ambiguous. The value provided by an attribute in an "unset" state could be
any default value the attribute deems appropriate based upon its type,
although the typical return value will be null.
BbAttribute. true if
the object value has been "set", false otherwise.protected void setIsSet(boolean bIsSet)
BbAttribute.
bIsSet - boolean flag denoting whether this attribute is "set".public boolean getIsDirty()
BbAttribute. An attribute is
"dirty" if it value has been changed sinced a saved state. A BbAttribute
starts out "dirty" since it has yet to be saved to any location.
BbAttribute.
true if the attribute is "dirty", false otherwise.public void setIsDirty(boolean bIsDirty)
BbAttribute
bIsDirty - boolean flag denoting whether a change has been made to
this attribute.public java.lang.String toString()
BbAttribute value to a string representation.
Can be used for debug purposes.
toString in class java.lang.Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||