|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.jfree.report.function.ExpressionCollection
Collects all expressions used in the report. There exist 2 states of the ExpressionCollection. In the first, modifiable state, expressions can be added to the collection. During the adding the expressions get initialized. An ExpressionCollection in this state is not able to connect to an DataRow.
The second state is an immutable state of this collection, no expressions can be added or removed. This ReadOnlyExpressionCollection can be created by calling getCopy() on the first-state expression collection. The ReadOnlyExpressionCollection is able to connect to a DataRow.
Constructor Summary | |
ExpressionCollection()
Creates a new expression collection (initially empty). |
|
ExpressionCollection(java.util.Collection expressions)
Creates a new expression collection, populated with the supplied expressions. |
Method Summary | |
void |
add(Expression e)
Adds an expression to the collection. |
void |
addAll(java.util.Collection expressions)
Adds all expressions contained in the given collection to this expression collection. |
java.lang.Object |
clone()
Clones this expression collection and all expressions contained in the collection. |
Expression |
get(java.lang.String name)
Returns the Expression with the specified name (or null ). |
Expression |
getExpression(int pos)
Returns the expression on the given position in the list. |
protected void |
privateAdd(Expression e)
Adds an expression to the collection. |
void |
removeExpression(Expression e)
Removes an expression from the collection. |
int |
size()
Returns the number of active expressions in this collection. |
Methods inherited from class java.lang.Object |
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public ExpressionCollection()
public ExpressionCollection(java.util.Collection expressions) throws FunctionInitializeException
expressions
- a collection of expressions.
FunctionInitializeException
- if any of the expressions cannot be initialized.
java.lang.ClassCastException
- if the collection does not contain ExpressionsMethod Detail |
public void addAll(java.util.Collection expressions) throws FunctionInitializeException
expressions
- the expressions to be added.
java.lang.ClassCastException
- if the collection does not contain expressions
FunctionInitializeException
- if a contained expression could not be initialized.public Expression get(java.lang.String name)
Expression
with the specified name (or null
).
name
- the expression name (null
not permitted).
java.lang.NullPointerException
- if the name given is null
.public void add(Expression e) throws FunctionInitializeException
e
- the expression.
FunctionInitializeException
- if the Expression could not be initialized correctlyprotected void privateAdd(Expression e)
e
- the expression.
java.lang.NullPointerException
- if the given Expression is null.public void removeExpression(Expression e)
e
- the expression.
java.lang.NullPointerException
- if the given Expression is null.public int size()
public Expression getExpression(int pos)
pos
- the position in the list.
java.lang.IndexOutOfBoundsException
- if the given position is invalidpublic java.lang.Object clone() throws java.lang.CloneNotSupportedException
java.lang.CloneNotSupportedException
- should never happen.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |