Cytoscape 3.0.0-beta1 API

org.cytoscape.view.vizmap.mappings
Class AbstractVisualMappingFunction<K,V>

java.lang.Object
  extended by org.cytoscape.view.vizmap.mappings.AbstractVisualMappingFunction<K,V>
Type Parameters:
K - Generic type of the attribute mapped.
V - Generic type of the VisualProperty used in this mapping.
All Implemented Interfaces:
VisualMappingFunction<K,V>

public abstract class AbstractVisualMappingFunction<K,V>
extends Object
implements VisualMappingFunction<K,V>

A base class for visual mapping functions where all fields are immutable.


Cytoscape Backwards Compatibility (Abstract Class): This class is abstract and meant to be extended by users. This means that we may add methods for minor version updates. Methods will only be removed for major version updates.

Field Summary
protected  String attrName
          Mapping attribute name.
protected  Class<K> attrType
          Type of attribute.
protected  CyTable table
          The table used for this mapping.
protected  VisualProperty<V> vp
          Visual Property used in this mapping.
 
Constructor Summary
AbstractVisualMappingFunction(String attrName, Class<K> attrType, CyTable table, VisualProperty<V> vp)
          Constructs this AbstractVisualMappingFunction.
 
Method Summary
 String getMappingColumnName()
          Returns attribute name used in this mapping.
 Class<K> getMappingColumnType()
          Returns data type of mapping attribute.
 CyTable getMappingTable()
          Returns table used for this mapping.
 VisualProperty<V> getVisualProperty()
          Visual Property associated with this function.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.cytoscape.view.vizmap.VisualMappingFunction
apply
 

Field Detail

attrName

protected final String attrName
Mapping attribute name.


attrType

protected final Class<K> attrType
Type of attribute.


table

protected final CyTable table
The table used for this mapping.


vp

protected final VisualProperty<V> vp
Visual Property used in this mapping.

Constructor Detail

AbstractVisualMappingFunction

public AbstractVisualMappingFunction(String attrName,
                                     Class<K> attrType,
                                     CyTable table,
                                     VisualProperty<V> vp)
Constructs this AbstractVisualMappingFunction.

Parameters:
attrName - Mapping attribute column name.
attrType - Type of attribute column.
table - The table used to find the column.
vp - Visual Property used in this mapping.
Method Detail

getMappingColumnName

public String getMappingColumnName()
Description copied from interface: VisualMappingFunction
Returns attribute name used in this mapping. This field is immutable.

Specified by:
getMappingColumnName in interface VisualMappingFunction<K,V>
Returns:
name of attribute (a column name in data table) associated with this mapping.

getMappingColumnType

public Class<K> getMappingColumnType()
Description copied from interface: VisualMappingFunction
Returns data type of mapping attribute.

Specified by:
getMappingColumnType in interface VisualMappingFunction<K,V>
Returns:
data type of controlling attribute.

getVisualProperty

public VisualProperty<V> getVisualProperty()
Description copied from interface: VisualMappingFunction
Visual Property associated with this function. This field is immutable.

Specified by:
getVisualProperty in interface VisualMappingFunction<K,V>
Returns:
VisualProperty used in this mapping.

getMappingTable

public CyTable getMappingTable()
Description copied from interface: VisualMappingFunction
Returns table used for this mapping.

Specified by:
getMappingTable in interface VisualMappingFunction<K,V>
Returns:
CyTable associated with this mapping.

Cytoscape 3.0.0-beta1 API

Copyright 2011 Cytoscape Consortium. All rights reserved.