|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--edu.wpi.cs.dsrg.xmldb.xat.common.operator.XATPropertiesImp | +--edu.wpi.cs.dsrg.xmldb.xat.common.operator.XATQueryObjectImp | +--edu.wpi.cs.dsrg.xmldb.xat.component.statisticsgatherer.StatisticsObject
Subclasses of this should override the calculateNewValue() and calculateNewValue(String) method. The compareTo(Object) method provides a default comparision (on propertyValue), but should be overwritten if more is desired. The calculateNewValue just copies the value from the operator
Statistics Object that stores a propertyName, propertyValue, and an associated operator. The StatisticsObject stores an operator's value of a property at a certain time. The propertyValue here does not necessarily correspond to the value in the operator because the operator's value is updated continuosly (after each time the operator is run) while this value is updated only when the execution controller decides to do so.
This object implements Comparable so that one StatisticsObject may be compared to another. This allows the StatisticsGatherer to sort these objects based on the given property.
The calculateNewValue is called by the statisticsGatherer. Creation date: (1/10/2003 4:45:18 PM)
Fields inherited from class edu.wpi.cs.dsrg.xmldb.xat.common.operator.XATQueryObjectImp |
stats,
statsPresent |
Constructor Summary | |
StatisticsObject()
Default Constructor |
|
StatisticsObject(java.lang.String name,
XATQueryObject queryObject)
StatisticsObject constructor comment. |
Method Summary | |
void |
calculateNewValue()
Calculates the new Value of the given property of this operator. |
void |
calculateNewValue(java.lang.String newValue)
This is semantically the same as calculateNewValue(), but this provides a parameter which assists in the calculation. |
int |
compareTo(java.lang.Object o)
It is important that care is taken when implementing this method. |
boolean |
equals(java.lang.Object otherObject)
Compare this to another StatsObject. |
XATQueryObject |
getAssociatedQueryObject()
Insert the method's description here. |
java.lang.Object |
getCategory()
Insert the method's description here. |
java.lang.String |
getPropertyName()
Insert the method's description here. |
java.lang.String |
getPropertyValue()
Get the value of the property specfied by this.getPropertyName(). |
void |
setAssociatedQueryObject(XATQueryObject newAssociatedQueryObject)
Insert the method's description here. |
void |
setCategory(java.lang.Object newCategory)
Insert the method's description here. |
void |
setPropertyName(java.lang.String newPropertyName)
Insert the method's description here. |
void |
setPropertyValue(java.lang.String newPropertyValue)
Sets the property value. |
java.lang.String |
toString()
Insert the method's description here. |
Methods inherited from class edu.wpi.cs.dsrg.xmldb.xat.common.operator.XATQueryObjectImp |
addStatistic,
getStatistics,
isValidStatistic,
setDefaultProperties,
setDefaultStatistics |
Methods inherited from class edu.wpi.cs.dsrg.xmldb.xat.common.operator.XATPropertiesImp |
addProperty,
getProperties,
getProperty,
isValidPropertyName,
setNewPropertyValue,
setProperty |
Methods inherited from class java.lang.Object |
clone,
finalize,
getClass,
hashCode,
notify,
notifyAll,
wait,
wait,
wait |
Constructor Detail |
public StatisticsObject()
public StatisticsObject(java.lang.String name, XATQueryObject queryObject)
Method Detail |
public void calculateNewValue()
This method should update at least the local propertyValue and possibly the value with the operator The entire StatisticsGatherer is available for assistance.
The procedure for calculating new values should be as follows:
public void calculateNewValue(java.lang.String newValue)
This method should update at least the local propertyValue and possibly the value with the operator The entire StatisticsGatherer is available for assistance.
The procedure for calculating new values should be as follows:
public int compareTo(java.lang.Object o)
This particular implementation tries to determine the data type of the propertyValue and then do a standard comparison. Compares this object with the specified object for order. Returns a negative integer, zero, or a positive integer as this object is less than, equal to, or greater than the specified object.
The implementor must ensure sgn(x.compareTo(y)) == -sgn(y.compareTo(x)) for all x and y. (This implies that x.compareTo(y) must throw an exception iff y.compareTo(x) throws an exception.)
The implementor must also ensure that the relation is transitive: (x.compareTo(y)>0 && y.compareTo(z)>0) implies x.compareTo(z)>0.
Finally, the implementer must ensure that x.compareTo(y)==0 implies that sgn(x.compareTo(z)) == sgn(y.compareTo(z)), for all z.
It is strongly recommended, but not strictly required that (x.compareTo(y)==0) == (x.equals(y)). Generally speaking, any class that implements the Comparable interface and violates this condition should clearly indicate this fact. The recommended language is "Note: this class has a natural ordering that is inconsistent with equals."
o
- the Object to be compared.public boolean equals(java.lang.Object otherObject)
otherObject
- java.lang.Objectpublic XATQueryObject getAssociatedQueryObject()
public java.lang.Object getCategory()
public java.lang.String getPropertyName()
public java.lang.String getPropertyValue()
public void setAssociatedQueryObject(XATQueryObject newAssociatedQueryObject)
newAssociatedOperator
- edu.wpi.cs.dsrg.xmldb.xat.common.operator.XATOperatorpublic void setCategory(java.lang.Object newCategory)
newCategory
- java.lang.Objectpublic void setPropertyName(java.lang.String newPropertyName)
newPropertyName
- java.lang.Stringpublic void setPropertyValue(java.lang.String newPropertyValue)
newPropertyValue
- java.lang.Stringpublic java.lang.String toString()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |