Packagecom.yworks.graph.model
Classpublic final class GraphItemTypes
InheritanceGraphItemTypes Inheritance Object

This class provides constants that can be used for various properties which take a bitwise combination of IGraph item types as well as static methods to determine whether a given item matches the type.



Public Methods
 MethodDefined By
  
[static] The type of the item.
GraphItemTypes
  
isOfType(item:IModelItem, types:uint):Boolean
[static] Whether the given item is represented by the given type.
GraphItemTypes
Public Constants
 ConstantDefined By
  ALL : uint = 63
[static] Constant for all item types.
GraphItemTypes
  BEND : uint = 32
[static] Constant for bends.
GraphItemTypes
  EDGE : uint = 2
[static] Constant for edges.
GraphItemTypes
  EDGE_LABEL : uint = 8
[static] Constant for edge labels.
GraphItemTypes
  LABEL : uint = 12
[static] Constant for all kinds of labels.
GraphItemTypes
  LABELED_ITEM : uint = 3
[static] Constant for labeled items.
GraphItemTypes
  NODE : uint = 1
[static] Constant for nodes.
GraphItemTypes
  NODE_LABEL : uint = 4
[static] Constant for node labels.
GraphItemTypes
  NONE : uint = 0
[static] Constant for no item type.
GraphItemTypes
  PORT : uint = 16
[static] Constant for ports.
GraphItemTypes
Method Detail
getItemType()method
public static function getItemType(item:IModelItem):uint

The type of the item.

Parameters

item:IModelItem — The item.

Returns
uint — The type as defined the constants of this class.
isOfType()method 
public static function isOfType(item:IModelItem, types:uint):Boolean

Whether the given item is represented by the given type.

Parameters

item:IModelItem — The item to test.
 
types:uint — A bitwise combination of one or more of the constants of this class.

Returns
Boolean — Whether the given item's type is among the given types.
Constant Detail
ALLConstant
public static const ALL:uint = 63

Constant for all item types.

This is a bitwise combination of all other types declared in this class.

BENDConstant 
public static const BEND:uint = 32

Constant for bends.

See also

EDGEConstant 
public static const EDGE:uint = 2

Constant for edges.

See also

EDGE_LABELConstant 
public static const EDGE_LABEL:uint = 8

Constant for edge labels.

See also

LABELConstant 
public static const LABEL:uint = 12

Constant for all kinds of labels.

This is a bitwise combination of NODE_LABEL and EDGE_LABEL

See also

LABELED_ITEMConstant 
public static const LABELED_ITEM:uint = 3

Constant for labeled items.

A bitwise combination of NODE and EDGE.

See also

NODEConstant 
public static const NODE:uint = 1

Constant for nodes.

See also

NODE_LABELConstant 
public static const NODE_LABEL:uint = 4

Constant for node labels.

See also

NONEConstant 
public static const NONE:uint = 0

Constant for no item type.

This is a constant where no type bit is set, i.e. it is 0.

PORTConstant 
public static const PORT:uint = 16

Constant for ports.

See also