Enum ConnectionWidget.RoutingPolicy
java.lang.Object
java.lang.Enum<ConnectionWidget.RoutingPolicy>
org.netbeans.api.visual.widget.ConnectionWidget.RoutingPolicy
- All Implemented Interfaces:
Serializable
,Comparable<ConnectionWidget.RoutingPolicy>
,java.lang.constant.Constable
- Enclosing class:
ConnectionWidget
This enum represents a policy which is used for re-routing control points of a ConnectionWidget.
- Since:
- 2.9
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionAll control points are rerouted when it is necessary.Disable routing completely, so control points are kept at their previous location.Temporarily disables routing until any end point changes its location.All control points (except end points) are kept at the same location. -
Method Summary
Modifier and TypeMethodDescriptionReturns the enum constant of this type with the specified name.static ConnectionWidget.RoutingPolicy[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
Enum Constant Details
-
ALWAYS_ROUTE
All control points are rerouted when it is necessary. This is the default policy.- Since:
- 2.9
-
UPDATE_END_POINTS_ONLY
All control points (except end points) are kept at the same location. End points are updated to locations resolved by source and target anchors. Note: This is used when an user customizes/adds/removes control points and the change has to be kept until it is reset by the user (setting policy to ALWAYS_ROUTE.- Since:
- 2.9
-
DISABLE_ROUTING_UNTIL_END_POINT_IS_MOVED
Temporarily disables routing until any end point changes its location. Locations are the first and the last point of control points. When an end point location is changed, then the policy is automatically changed toALWAYS_ROUTE
. Note: This is used by GraphLayouts which routes the path (control points) by themselves and would like to keep the path until user moves with source or target widget/anchor.- Since:
- 2.9
-
DISABLE_ROUTING
Disable routing completely, so control points are kept at their previous location. Note: This is not often used unless you have to freeze a ConnectionWidget- Since:
- 2.9
-
-
Method Details
-
values
Returns an array containing the constants of this enum type, in the order they are declared.- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null
-