Cytoscape 2.6.2 (c) 2006,2007 ISB, MSKCC, UCSD

cytoscape.visual.calculators
Interface Calculator

All Superinterfaces:
Cloneable
All Known Subinterfaces:
EdgeArrowCalculator, EdgeColorCalculator, EdgeFontFaceCalculator, EdgeFontSizeCalculator, EdgeLabelCalculator, EdgeLineTypeCalculator, EdgeToolTipCalculator, NodeColorCalculator, NodeFontFaceCalculator, NodeFontSizeCalculator, NodeLabelCalculator, NodeLabelColorCalculator, NodeLineTypeCalculator, NodeShapeCalculator, NodeSizeCalculator, NodeToolTipCalculator
All Known Implementing Classes:
AbstractCalculator, BasicCalculator, EdgeCalculator, GenericEdgeArrowCalculator, GenericEdgeColorCalculator, GenericEdgeFontFaceCalculator, GenericEdgeFontSizeCalculator, GenericEdgeLabelCalculator, GenericEdgeLabelColorCalculator, GenericEdgeLineStyleCalculator, GenericEdgeLineTypeCalculator, GenericEdgeLineWidthCalculator, GenericEdgeSourceArrowCalculator, GenericEdgeSourceArrowColorCalculator, GenericEdgeSourceArrowShapeCalculator, GenericEdgeTargetArrowCalculator, GenericEdgeTargetArrowColorCalculator, GenericEdgeTargetArrowShapeCalculator, GenericEdgeToolTipCalculator, GenericNodeBorderColorCalculator, GenericNodeColorCalculator, GenericNodeFillColorCalculator, GenericNodeFontFaceCalculator, GenericNodeFontSizeCalculator, GenericNodeHeightCalculator, GenericNodeLabelCalculator, GenericNodeLabelColorCalculator, GenericNodeLabelPositionCalculator, GenericNodeLineStyleCalculator, GenericNodeLineTypeCalculator, GenericNodeLineWidthCalculator, GenericNodeShapeCalculator, GenericNodeSizeCalculator, GenericNodeToolTipCalculator, GenericNodeUniformSizeCalculator, GenericNodeWidthCalculator, NodeCalculator

public interface Calculator
extends Cloneable

Calculator specifies a super-interface for all calculator interfaces. DO NOT create classes that only implement Calculator! When writing calculators, you MUST extend one of NodeCalculator or EdgeCalculator and implement one of the 11 attribute calculator interfaces.


Field Summary
static String ID
           
 
Method Summary
 void addChangeListener(ChangeListener l)
          Add a ChangeListener to the calcaultor.
 void apply(Appearance appr, Edge e, CyNetwork net)
          DOCUMENT ME!
 void apply(Appearance appr, Node n, CyNetwork net)
          DOCUMENT ME!
 Object clone()
          Clone the calculator.
 ObjectMapping getMapping(int i)
          DOCUMENT ME!
 Vector<ObjectMapping> getMappings()
          DOCUMENT ME!
 Properties getProperties()
          Get a description of this calculator as a Properties object.
 String getPropertyLabel()
          Deprecated. Will be removed 5/2008
 byte getType()
          Deprecated. Will be removed 5/2008
 String getTypeName()
          Deprecated. Will be removed 5/2008
 JPanel getUI(JDialog parent, CyNetwork network)
          Get the UI for a calculator.
 VisualPropertyType getVisualPropertyType()
          This method replaces the three methods above.
 void removeChangeListener(ChangeListener l)
          Remove a ChangeListener from the calcaultor.
 void setName(String newName)
          Set calculator name.
 String toString()
          Gets calculator name.
 

Field Detail

ID

static final String ID
See Also:
Constant Field Values
Method Detail

getUI

JPanel getUI(JDialog parent,
             CyNetwork network)
Get the UI for a calculator.

Parameters:
parent - Parent JDialog for the UI
network - CyNetwork object containing underlying graph data

toString

String toString()
Gets calculator name.

Overrides:
toString in class Object

setName

void setName(String newName)
Set calculator name. DO NOT CALL THIS METHOD unless you first get a valid name from the CalculatorCatalog. Even if you have a guaranteed valid name from the CalculatorCatalog, it is still preferrable to use the renameCalculator method in the CalculatorCatalog.


clone

Object clone()
             throws CloneNotSupportedException
Clone the calculator.

Throws:
CloneNotSupportedException

getProperties

Properties getProperties()
Get a description of this calculator as a Properties object.


addChangeListener

void addChangeListener(ChangeListener l)
Add a ChangeListener to the calcaultor. When the state underlying the calculator changes, all ChangeListeners will be notified. This is used in the UI classes to ensure that the UI panes stay consistent with the data held in the mappings.

Parameters:
l - ChangeListener to add

removeChangeListener

void removeChangeListener(ChangeListener l)
Remove a ChangeListener from the calcaultor. When the state underlying the calculator changes, all ChangeListeners will be notified. This is used in the UI classes to ensure that the UI panes stay consistent with the data held in the mappings.

Parameters:
l - ChangeListener to add

getType

@Deprecated
byte getType()
Deprecated. Will be removed 5/2008

DOCUMENT ME!

Returns:
DOCUMENT ME!

getTypeName

@Deprecated
String getTypeName()
Deprecated. Will be removed 5/2008

DOCUMENT ME!

Returns:
DOCUMENT ME!

getPropertyLabel

@Deprecated
String getPropertyLabel()
Deprecated. Will be removed 5/2008

DOCUMENT ME!

Returns:
DOCUMENT ME!

getVisualPropertyType

VisualPropertyType getVisualPropertyType()
This method replaces the three methods above.

Returns:

apply

void apply(Appearance appr,
           Edge e,
           CyNetwork net)
DOCUMENT ME!

Parameters:
appr - DOCUMENT ME!
e - DOCUMENT ME!
net - DOCUMENT ME!

apply

void apply(Appearance appr,
           Node n,
           CyNetwork net)
DOCUMENT ME!

Parameters:
appr - DOCUMENT ME!
n - DOCUMENT ME!
net - DOCUMENT ME!

getMappings

Vector<ObjectMapping> getMappings()
DOCUMENT ME!

Returns:
DOCUMENT ME!

getMapping

ObjectMapping getMapping(int i)
DOCUMENT ME!

Parameters:
i - DOCUMENT ME!
Returns:
DOCUMENT ME!

www.cytoscape.org