public interface VisualStyle
Module: vizmap-api
To use this in your app, include the following dependency in your POM:
<dependency> <groupId>org.cytoscape</groupId> <artifactId>vizmap-api</artifactId> </dependency>
Modifier and Type | Method and Description |
---|---|
void |
addVisualMappingFunction(VisualMappingFunction<?,?> mapping)
Add a new VisualMappingFunction to this VisualStyle.
|
void |
addVisualPropertyDependency(VisualPropertyDependency<?> dependency)
Add a new VisualPropertyDependency.
|
void |
apply(CyNetworkView networkView)
Apply Visual Style to the entire network view.
|
void |
apply(CyRow row,
View<? extends CyIdentifiable> view)
Apply Visual Property values only to the given View Object (node or edge).
|
Collection<VisualMappingFunction<?,?>> |
getAllVisualMappingFunctions()
Returns all VisualMappingFunctions in this style.
|
Set<VisualPropertyDependency<?>> |
getAllVisualPropertyDependencies()
Get all dependencies for this style.
|
<V> V |
getDefaultValue(VisualProperty<V> vp)
Returns default value for the VisualProperty.
|
String |
getTitle()
Returns name of this visual style.
|
<V> VisualMappingFunction<?,V> |
getVisualMappingFunction(VisualProperty<V> vp)
Get current VisualMappingFunction for the VisualProperty.
|
void |
removeVisualMappingFunction(VisualProperty<?> vp)
Remove a VisualMappingFunction for the VisualProperty.
|
void |
removeVisualPropertyDependency(VisualPropertyDependency<?> dependency)
Remove a VisualPropertyDependency.
|
<V,S extends V> |
setDefaultValue(VisualProperty<V> vp,
S value)
Set default value for the VisualProperty.
|
void |
setTitle(String title)
Set new title for this VisualStyle.
|
String getTitle()
Title of Visual Style is a mutable field and may NOT be unique.
void setTitle(String title)
title
- New title of this VisualStyle.void addVisualMappingFunction(VisualMappingFunction<?,?> mapping)
mapping
- new VisualMappingFunction to be added.void removeVisualMappingFunction(VisualProperty<?> vp)
vp
- VisualMappingFunction associated with this VisualProperty will be removed.<V> VisualMappingFunction<?,V> getVisualMappingFunction(VisualProperty<V> vp)
V
- Data type of VisualProperty.vp
- visual property associated with the target mapping.Collection<VisualMappingFunction<?,?>> getAllVisualMappingFunctions()
<V> V getDefaultValue(VisualProperty<V> vp)
V
- Data type of VisualPropertyvp
- target VisualProperty<V,S extends V> void setDefaultValue(VisualProperty<V> vp, S value)
V
- Data type of VisualPropertyS
- Data type of actual default value. This can be same as V or its child classes.vp
- target VisualPropertyvalue
- Value to be set as default. This can be child type of V. For example,
if V is Number, S can be Double, Integer, etc.void apply(CyNetworkView networkView)
networkView
- The view that the visual property should be applied to.void apply(CyRow row, View<? extends CyIdentifiable> view)
row
- Data table row for the view's model. This is necessary for applying mapped values.view
- The view that the visual property should be applied to.Set<VisualPropertyDependency<?>> getAllVisualPropertyDependencies()
void addVisualPropertyDependency(VisualPropertyDependency<?> dependency)
dependency
- new dependency to be addedvoid removeVisualPropertyDependency(VisualPropertyDependency<?> dependency)
dependency
- Copyright 2011-2015 Cytoscape Consortium. All rights reserved.