Interface EditorManager
public interface EditorManager
Manages all editor objects for the VizMap GUI.
Module: vizmap-gui-api
To use this in your app, include the following dependency in your POM:
<dependency>
<groupId>org.cytoscape</groupId>
<artifactId>vizmap-gui-api</artifactId>
</dependency>Cytoscape Backwards Compatibility (API Interface): We expect that this interface will be used but not implemented by developers using this interface. As such, we reserve the right to add methods to the interface as part of minor version upgrades. We will not remove methods for any changes other than major version upgrades.
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionvoidaddValueEditor(ValueEditor<?> va, Map properties) Add value editor OSGi services.voidaddVisualPropertyValueEditor(VisualPropertyValueEditor<?> va, Map properties) Add value editor--invoked by OSGi when a new bundle exports an instance.Returns set of selector for available attributes (table columns).Returns editors for individual cells in discrete mapping editor.Returns the continuous editor for the specified visual property.getDataTableComboBoxEditor(Class<? extends CyIdentifiable> targetObjectType) Attribute selector for the given table entry type.getDefaultComboBoxEditor(String editorName) GetJComboBoxtype editorReturns selector for Mapping Type.<V> ValueEditor<V>getValueEditor(Class<V> dataType) Returns value editor for the given data type.<V> VisualPropertyEditor<V>Returns theVisualPropertyEditorfor the givenVisualProperty.voidremoveValueEditor(ValueEditor<?> va, Map properties) Remove an editor from manager (through OSGi).voidremoveVisualPropertyValueEditor(VisualPropertyValueEditor<?> va, Map properties) Remove an editor from manager--invoked by OSGi when a bundle that exports an instance is being unloaded.<V> VshowVisualPropertyValueEditor(Component parentComponent, VisualProperty<V> type, V initialVal) Display value editor to get a new value.
-
Field Details
-
EDITOR_WINDOW_OPENED
Editor window state- See Also:
-
EDITOR_WINDOW_CLOSED
Tell vizMapper main which editor is disabled/enabled.- See Also:
-
-
Method Details
-
addValueEditor
Add value editor OSGi services.- Parameters:
va- New value editor to be added.properties- OSGi service metadata.
-
removeValueEditor
Remove an editor from manager (through OSGi).- Parameters:
va- editor to be removed.properties- OSGi metadata
-
addVisualPropertyValueEditor
Add value editor--invoked by OSGi when a new bundle exports an instance.- Parameters:
va- New value editor to be added.properties- OSGi service metadata.
-
removeVisualPropertyValueEditor
Remove an editor from manager--invoked by OSGi when a bundle that exports an instance is being unloaded.- Parameters:
va- editor to be removed.properties- OSGi metadata
-
showVisualPropertyValueEditor
<V> V showVisualPropertyValueEditor(Component parentComponent, VisualProperty<V> type, V initialVal) throws Exception Display value editor to get a new value. This should first search forVisualPropertyValueEditors with matching value types. If none are found, resort to searching forValueEditors.- Parameters:
parentComponent- parent GUI componenttype- Visual Property type to be editedinitialVal- default value for the editor.- Returns:
- New value fot the given Visual Property.
- Throws:
Exception
-
getContinuousEditor
Returns the continuous editor for the specified visual property.- Parameters:
vp- The visual property.- Returns:
- the continuous editor for the specified visual property.
-
getVisualPropertyEditor
Returns theVisualPropertyEditorfor the givenVisualProperty.- Type Parameters:
V- the generic type of the VisualProperty.- Parameters:
vp- theVisualPropertyto get the VisualPropertyEditor of.- Returns:
- the
VisualPropertyEditorfor the givenVisualProperty.
-
getCellEditors
List<PropertyEditor> getCellEditors()Returns editors for individual cells in discrete mapping editor.- Returns:
- all available cell editors.
-
getAttributeSelectors
Collection<PropertyEditor> getAttributeSelectors()Returns set of selector for available attributes (table columns).- Returns:
- all attribute selectors.
-
getMappingFunctionSelector
PropertyEditor getMappingFunctionSelector()Returns selector for Mapping Type. For now, users can select Discrete, Continuous, and Passthrough from this object.- Returns:
- mapping type selector.
-
getDefaultComboBoxEditor
GetJComboBoxtype editor- Parameters:
editorName- name (ID) of editor- Returns:
- combobox editor associated with the name.
-
getDataTableComboBoxEditor
Attribute selector for the given table entry type.- Parameters:
targetObjectType- node, edge, or network.- Returns:
- selector
-
getValueEditor
Returns value editor for the given data type.- Parameters:
dataType- type of data. They are Color, number, Shape, etc.- Returns:
- Value editor
-