|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnl.tue.win.riaca.openmath.lang.OMObject
Models an abstract OpenMath object.
Note: every other OpenMath object inherits from this object. So each OpenMath object will have a hashtable of attributes.
Field Summary | |
protected java.util.Hashtable |
attributes
Stores the attribute table. |
Constructor Summary | |
OMObject()
Constructor. |
Method Summary | |
abstract java.lang.Object |
clone()
This will perform a shallow copy of the object. |
abstract java.lang.Object |
copy()
Creates a copy of the OMObject. |
java.lang.Object |
getAttribute(java.lang.String name)
Get an attribute. |
java.util.Hashtable |
getAttributes()
Gets the attributes. |
abstract java.lang.String |
getType()
Get the type of this element. |
abstract boolean |
isAtom()
Is this an atom. |
abstract boolean |
isComposite()
Is this a composite object. |
abstract boolean |
isSame(OMObject object)
Is this the same object. |
abstract boolean |
isValid()
Is this a valid object. |
void |
removeAttribute(java.lang.String name)
Remove an attribute. |
void |
setAttribute(java.lang.String name,
java.lang.String value)
Set an attribute. |
void |
setAttributes(java.util.Hashtable newAttributes)
Sets the attributes. |
abstract java.lang.String |
toString()
Returns a string representation of the object. |
Methods inherited from class java.lang.Object |
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
protected java.util.Hashtable attributes
Constructor Detail |
public OMObject()
Method Detail |
public abstract java.lang.String getType()
public abstract boolean isAtom()
public abstract boolean isComposite()
public abstract boolean isSame(OMObject object)
object
- the object to test against.
public abstract boolean isValid()
public abstract java.lang.Object clone()
public abstract java.lang.String toString()
public abstract java.lang.Object copy()
public java.util.Hashtable getAttributes()
Note: this is an extension to the OpenMath standard 1.0. For the OpenMath standard 2.0 this is needed. So if you want 1.0 compliant code do not use attributes.
public void setAttributes(java.util.Hashtable newAttributes)
Note: this is an extension to the OpenMath standard 1.0. For the OpenMath standard 2.0 this is needed. So if you want 1.0 compliant code do not use attributes.
newAttributes
- the attributes to set.public java.lang.Object getAttribute(java.lang.String name)
Note: this is an extension to the OpenMath standard 1.0. For the OpenMath standard 2.0 this is needed. So if you want 1.0 compliant code do not use attributes.
name
- the name of the attribute to get.
public void setAttribute(java.lang.String name, java.lang.String value)
Note: this is an extension to the OpenMath standard 1.0. For the OpenMath standard 2.0 this is needed. So if you want 1.0 compliant code do not use attributes.
name
- the name of the attribute to set.value
- the value of the attribute.public void removeAttribute(java.lang.String name)
Note: this is an extension to the OpenMath standard 1.0. For the OpenMath standard 2.0 this is needed. So if you want 1.0 compliant code do not use attributes.
name
- the name of the attribute to remove.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |