Search this API

y.module
Class CircularLayoutModule

java.lang.Object
  extended by y.module.YModule
      extended by y.module.LayoutModule
          extended by y.module.CircularLayoutModule

public class CircularLayoutModule
extends LayoutModule

This module represents an interactive configurator and launcher for CircularLayouter.

See Also:
Section Circular Layout in the yFiles for Java Developer's Guide
 

Field Summary
protected static java.lang.String EDGE_BUNDLING_ENABLED
           
protected static java.lang.String EDGE_BUNDLING_STRENGTH
           
protected static java.lang.String ITEM_ACT_ON_SELECTION_ONLY
           
protected static java.lang.String ITEM_ALLOW_OVERLAPS
           
protected static java.lang.String ITEM_CHOOSE_RADIUS_AUTOMATICALLY
           
protected static java.lang.String ITEM_COMPACTNESS_FACTOR
           
protected static java.lang.String ITEM_EDGE_ROUTING_POLICY
           
protected static java.lang.String ITEM_EXTERIOR_EDGE_CIRCLE_DISTANCE
           
protected static java.lang.String ITEM_EXTERIOR_EDGE_CURVE_LENGTH
           
protected static java.lang.String ITEM_EXTERIOR_EDGE_PREFERRED_ANGLE
           
protected static java.lang.String ITEM_EXTERIOR_EDGE_SMOOTHNESS
           
protected static java.lang.String ITEM_FIXED_RADIUS
           
protected static java.lang.String ITEM_FROM_SKETCH
           
protected static java.lang.String ITEM_HANDLE_NODE_LABELS
           
protected static java.lang.String ITEM_LAYOUT_STYLE
           
protected static java.lang.String ITEM_MAXIMAL_DEVIATION_ANGLE
           
protected static java.lang.String ITEM_MINIMAL_EDGE_LENGTH
           
protected static java.lang.String ITEM_MINIMAL_NODE_DISTANCE
           
protected static java.lang.String ITEM_MINIMAL_TREE_NODE_DISTANCE
           
protected static java.lang.String ITEM_MINIMUM_EXTERIOR_EDGE_DISTANCE
           
protected static java.lang.String ITEM_PLACE_CHILDREN_ON_COMMON_RADIUS
           
protected static java.lang.String ITEM_PREFERRED_CHILD_WEDGE
           
protected static java.lang.String MODULE_CIRCULAR
           
protected static java.lang.String SECTION_BUNDLING
           
protected static java.lang.String SECTION_CYCLE
           
protected static java.lang.String SECTION_EXTERIOR_EDGES
           
protected static java.lang.String SECTION_GENERAL
           
protected static java.lang.String SECTION_TREE
           
protected static java.lang.String VALUE_AUTOMATIC
           
protected static java.lang.String VALUE_BCC_COMPACT
           
protected static java.lang.String VALUE_BCC_ISOLATED
           
protected static java.lang.String VALUE_CIRCULAR_CUSTOM_GROUPS
           
protected static java.lang.String VALUE_EXTERIOR
           
protected static java.lang.String VALUE_INTERIOR
           
protected static java.lang.String VALUE_SELECTED_EXTERIOR
           
protected static java.lang.String VALUE_SINGLE_CYCLE
           
 
Fields inherited from class y.module.YModule
FAILED, moduleListenerSupport, PRECONDITION_VIOLATED, SUCCESS
 
Constructor Summary
CircularLayoutModule()
          Creates an instance of this module.
 
Method Summary
protected  void configure(CircularLayouter circular, OptionHandler options)
          Configures the module's layout algorithm according to the given options.
protected  OptionHandler createOptionHandler()
          Creates an OptionHandler and adds the option items used by this module.
protected  void mainrun()
          Main module execution routine.
protected  void prepareGraph(Graph2D graph, OptionHandler options)
          Prepares a graph depending on the given options for the module's layout algorithm.
protected  void restoreGraph(Graph2D graph, OptionHandler options)
          Restores the given graph by freeing up resources created by prepareGraph(y.view.Graph2D, y.option.OptionHandler).
 
Methods inherited from class y.module.LayoutModule
backupDataProvider, createAnimationPlayer, createLayoutExecutor, createLayoutMorpher, getBufferedMode, getLayoutExecutor, isAbortable, isMorphingEnabled, isPortIntersectionCalculatorEnabled, launchLayouter, launchLayouter, restoreDataProvider, setBufferedMode, setLayoutExecutor, setMorphingEnabled, setPortIntersectionCalculatorEnabled, useEventDispatchThread
 
Methods inherited from class y.module.YModule
addModuleListener, createThread, dispose, exceptionHappened, fitGraph2DView, getAuthor, getDescription, getExitStatus, getGraph2D, getGraph2DView, getModuleListeners, getModuleName, getOptionHandler, getTimer, getView, init, initGuiFactory, isBackupRealizersEnabled, removeModuleListener, run, setBackupRealizersEnabled, setExitStatus, setGraph2D, setModuleName, setOptionHandler, start, startAsThread
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

MODULE_CIRCULAR

protected static final java.lang.String MODULE_CIRCULAR
See Also:
Constant Field Values

SECTION_GENERAL

protected static final java.lang.String SECTION_GENERAL
See Also:
Constant Field Values

ITEM_LAYOUT_STYLE

protected static final java.lang.String ITEM_LAYOUT_STYLE
See Also:
Constant Field Values

VALUE_BCC_COMPACT

protected static final java.lang.String VALUE_BCC_COMPACT
See Also:
Constant Field Values

VALUE_BCC_ISOLATED

protected static final java.lang.String VALUE_BCC_ISOLATED
See Also:
Constant Field Values

VALUE_CIRCULAR_CUSTOM_GROUPS

protected static final java.lang.String VALUE_CIRCULAR_CUSTOM_GROUPS
See Also:
Constant Field Values

VALUE_SINGLE_CYCLE

protected static final java.lang.String VALUE_SINGLE_CYCLE
See Also:
Constant Field Values

ITEM_ACT_ON_SELECTION_ONLY

protected static final java.lang.String ITEM_ACT_ON_SELECTION_ONLY
See Also:
Constant Field Values

ITEM_FROM_SKETCH

protected static final java.lang.String ITEM_FROM_SKETCH
See Also:
Constant Field Values

ITEM_HANDLE_NODE_LABELS

protected static final java.lang.String ITEM_HANDLE_NODE_LABELS
See Also:
Constant Field Values

SECTION_CYCLE

protected static final java.lang.String SECTION_CYCLE
See Also:
Constant Field Values

ITEM_MINIMAL_NODE_DISTANCE

protected static final java.lang.String ITEM_MINIMAL_NODE_DISTANCE
See Also:
Constant Field Values

ITEM_CHOOSE_RADIUS_AUTOMATICALLY

protected static final java.lang.String ITEM_CHOOSE_RADIUS_AUTOMATICALLY
See Also:
Constant Field Values

ITEM_FIXED_RADIUS

protected static final java.lang.String ITEM_FIXED_RADIUS
See Also:
Constant Field Values

ITEM_EDGE_ROUTING_POLICY

protected static final java.lang.String ITEM_EDGE_ROUTING_POLICY
See Also:
Constant Field Values

VALUE_INTERIOR

protected static final java.lang.String VALUE_INTERIOR
See Also:
Constant Field Values

VALUE_EXTERIOR

protected static final java.lang.String VALUE_EXTERIOR
See Also:
Constant Field Values

VALUE_AUTOMATIC

protected static final java.lang.String VALUE_AUTOMATIC
See Also:
Constant Field Values

VALUE_SELECTED_EXTERIOR

protected static final java.lang.String VALUE_SELECTED_EXTERIOR
See Also:
Constant Field Values

SECTION_EXTERIOR_EDGES

protected static final java.lang.String SECTION_EXTERIOR_EDGES
See Also:
Constant Field Values

ITEM_MINIMUM_EXTERIOR_EDGE_DISTANCE

protected static final java.lang.String ITEM_MINIMUM_EXTERIOR_EDGE_DISTANCE
See Also:
Constant Field Values

ITEM_EXTERIOR_EDGE_CIRCLE_DISTANCE

protected static final java.lang.String ITEM_EXTERIOR_EDGE_CIRCLE_DISTANCE
See Also:
Constant Field Values

ITEM_EXTERIOR_EDGE_PREFERRED_ANGLE

protected static final java.lang.String ITEM_EXTERIOR_EDGE_PREFERRED_ANGLE
See Also:
Constant Field Values

ITEM_EXTERIOR_EDGE_CURVE_LENGTH

protected static final java.lang.String ITEM_EXTERIOR_EDGE_CURVE_LENGTH
See Also:
Constant Field Values

ITEM_EXTERIOR_EDGE_SMOOTHNESS

protected static final java.lang.String ITEM_EXTERIOR_EDGE_SMOOTHNESS
See Also:
Constant Field Values

SECTION_BUNDLING

protected static final java.lang.String SECTION_BUNDLING
See Also:
Constant Field Values

EDGE_BUNDLING_ENABLED

protected static final java.lang.String EDGE_BUNDLING_ENABLED
See Also:
Constant Field Values

EDGE_BUNDLING_STRENGTH

protected static final java.lang.String EDGE_BUNDLING_STRENGTH
See Also:
Constant Field Values

SECTION_TREE

protected static final java.lang.String SECTION_TREE
See Also:
Constant Field Values

ITEM_PREFERRED_CHILD_WEDGE

protected static final java.lang.String ITEM_PREFERRED_CHILD_WEDGE
See Also:
Constant Field Values

ITEM_MINIMAL_EDGE_LENGTH

protected static final java.lang.String ITEM_MINIMAL_EDGE_LENGTH
See Also:
Constant Field Values

ITEM_MAXIMAL_DEVIATION_ANGLE

protected static final java.lang.String ITEM_MAXIMAL_DEVIATION_ANGLE
See Also:
Constant Field Values

ITEM_COMPACTNESS_FACTOR

protected static final java.lang.String ITEM_COMPACTNESS_FACTOR
See Also:
Constant Field Values

ITEM_MINIMAL_TREE_NODE_DISTANCE

protected static final java.lang.String ITEM_MINIMAL_TREE_NODE_DISTANCE
See Also:
Constant Field Values

ITEM_ALLOW_OVERLAPS

protected static final java.lang.String ITEM_ALLOW_OVERLAPS
See Also:
Constant Field Values

ITEM_PLACE_CHILDREN_ON_COMMON_RADIUS

protected static final java.lang.String ITEM_PLACE_CHILDREN_ON_COMMON_RADIUS
See Also:
Constant Field Values
Constructor Detail

CircularLayoutModule

public CircularLayoutModule()
Creates an instance of this module.

Method Detail

createOptionHandler

protected OptionHandler createOptionHandler()
Creates an OptionHandler and adds the option items used by this module.

Overrides:
createOptionHandler in class YModule
Returns:
the created OptionHandler providing module related options

mainrun

protected void mainrun()
Main module execution routine. Launches the module's underlying algorithm on the module's graph based on user options.

Specified by:
mainrun in class YModule

prepareGraph

protected void prepareGraph(Graph2D graph,
                            OptionHandler options)
Prepares a graph depending on the given options for the module's layout algorithm.
Additional resources created by this method have to be freed up by calling restoreGraph(y.view.Graph2D, y.option.OptionHandler) after layout calculation.

Parameters:
graph - the graph to be prepared
options - the options for the module's layout algorithm

restoreGraph

protected void restoreGraph(Graph2D graph,
                            OptionHandler options)
Restores the given graph by freeing up resources created by prepareGraph(y.view.Graph2D, y.option.OptionHandler).

Parameters:
graph - the graph for which prepareGraph has been called
options - the options for the module's layout algorithm

configure

protected void configure(CircularLayouter circular,
                         OptionHandler options)
Configures the module's layout algorithm according to the given options.

Parameters:
circular - the CircularLayouter to be configured
options - the layout options to set

© Copyright 2000-2021,
yWorks GmbH.
All rights reserved.