org.jfree.report.function
Class AverageExpression

java.lang.Object
  |
  +--org.jfree.report.function.AbstractExpression
        |
        +--org.jfree.report.function.AverageExpression

Deprecated. this has been replaced by the ColumnAverageExpression.

public class AverageExpression
extends AbstractExpression
implements java.io.Serializable

An expression that takes values from one or more fields and returns the average of them.

See Also:
Serialized Form

Constructor Summary
AverageExpression()
          Deprecated. Creates a new expression.
 
Method Summary
 java.lang.Object clone()
          Deprecated. Clones the expression.
 java.lang.String[] getField()
          Deprecated. Returns the defined fields as array.
 java.lang.String getField(int idx)
          Deprecated.  
 java.lang.Object getValue()
          Deprecated. Returns the average of the values.
 void setField(int idx, java.lang.String object)
          Deprecated.  
 void setField(java.lang.String[] fields)
          Deprecated.  
 
Methods inherited from class org.jfree.report.function.AbstractExpression
getDataRow, getDependencyLevel, getInstance, getName, getReportConfiguration, getResourceBundleFactory, getRuntime, isActive, setActive, setDependencyLevel, setName, setRuntime
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AverageExpression

public AverageExpression()
Deprecated. 
Creates a new expression. The fields used by the expression are defined using properties named '0', '1', ... 'N'. These fields should contain Number instances.
Method Detail

getValue

public java.lang.Object getValue()
Deprecated. 
Returns the average of the values.
Returns:
a BigDecimal instance.

clone

public java.lang.Object clone()
                       throws java.lang.CloneNotSupportedException
Deprecated. 
Clones the expression.
Overrides:
clone in class AbstractExpression
Returns:
A copy of this expression.
Throws:
java.lang.CloneNotSupportedException - this should never happen.

getField

public java.lang.String[] getField()
Deprecated. 
Returns the defined fields as array.
Returns:
the fields

setField

public void setField(java.lang.String[] fields)
Deprecated. 

getField

public java.lang.String getField(int idx)
Deprecated. 
Parameters:
idx -  
Returns:
the field at the given index
Throws:
java.lang.IndexOutOfBoundsException - if the index is invalid.

setField

public void setField(int idx,
                     java.lang.String object)
Deprecated.