prefuse.visual.expression
Class GroupSizeFunction

java.lang.Object
  extended byprefuse.data.expression.AbstractExpression
      extended byprefuse.visual.expression.GroupExpression
          extended byprefuse.visual.expression.GroupSizeFunction
All Implemented Interfaces:
java.util.EventListener, Expression, ExpressionListener, Function

public class GroupSizeFunction
extends GroupExpression

GroupExpression that returns the size of a data group.

Author:
jeffrey heer

Field Summary
 
Fields inherited from class prefuse.visual.expression.GroupExpression
m_group
 
Fields inherited from interface prefuse.data.expression.Function
VARARGS
 
Constructor Summary
GroupSizeFunction()
          Create a new, uninitialized GroupSizeFunction.
GroupSizeFunction(java.lang.String group)
          Create a new GroupSizeFunction using the given data group name as the Function parameter.
 
Method Summary
 java.lang.Object get(Tuple t)
          Evaluate the Expression on the given input Tuple.
 double getDouble(Tuple t)
          Evaluate the Expression on the given input Tuple.
 float getFloat(Tuple t)
          Evaluate the Expression on the given input Tuple.
 int getInt(Tuple t)
          Evaluate the Expression on the given input Tuple.
 long getLong(Tuple t)
          Evaluate the Expression on the given input Tuple.
 java.lang.String getName()
          Get the name of this function.
 java.lang.Class getType(Schema s)
          Returns the type that this expression evaluates to when tuples with the given Schema are provided as input.
 
Methods inherited from class prefuse.visual.expression.GroupExpression
addParameter, getGroup, getParameterCount, toString
 
Methods inherited from class prefuse.data.expression.AbstractExpression
addChildListeners, addExpressionListener, expressionChanged, fireExpressionChange, getBoolean, hasListeners, removeChildListeners, removeExpressionListener, visit
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface prefuse.data.expression.Expression
addExpressionListener, getBoolean, removeExpressionListener, visit
 

Constructor Detail

GroupSizeFunction

public GroupSizeFunction()
Create a new, uninitialized GroupSizeFunction. The parameter for this Function needs to be set.


GroupSizeFunction

public GroupSizeFunction(java.lang.String group)
Create a new GroupSizeFunction using the given data group name as the Function parameter.

Parameters:
group - the data group name to use as a parameter
Method Detail

getName

public java.lang.String getName()
Description copied from interface: Function
Get the name of this function.

Returns:
the function name
See Also:
Function.getName()

getType

public java.lang.Class getType(Schema s)
Description copied from interface: Expression
Returns the type that this expression evaluates to when tuples with the given Schema are provided as input.

See Also:
Expression.getType(prefuse.data.Schema)

get

public java.lang.Object get(Tuple t)
Description copied from interface: Expression
Evaluate the Expression on the given input Tuple.

Specified by:
get in interface Expression
Overrides:
get in class AbstractExpression
See Also:
Expression.get(prefuse.data.Tuple)

getDouble

public double getDouble(Tuple t)
Description copied from interface: Expression
Evaluate the Expression on the given input Tuple.

Specified by:
getDouble in interface Expression
Overrides:
getDouble in class AbstractExpression
See Also:
Expression.getDouble(prefuse.data.Tuple)

getFloat

public float getFloat(Tuple t)
Description copied from interface: Expression
Evaluate the Expression on the given input Tuple.

Specified by:
getFloat in interface Expression
Overrides:
getFloat in class AbstractExpression
See Also:
Expression.getFloat(prefuse.data.Tuple)

getInt

public int getInt(Tuple t)
Description copied from interface: Expression
Evaluate the Expression on the given input Tuple.

Specified by:
getInt in interface Expression
Overrides:
getInt in class AbstractExpression
See Also:
Expression.getInt(prefuse.data.Tuple)

getLong

public long getLong(Tuple t)
Description copied from interface: Expression
Evaluate the Expression on the given input Tuple.

Specified by:
getLong in interface Expression
Overrides:
getLong in class AbstractExpression
See Also:
Expression.getLong(prefuse.data.Tuple)


Copyright ? 2007 Regents of the University of California