Options
All
  • Public
  • Public/Protected
  • All
Menu

Handler that set-ups and tear-downs listeners needed to handle user input associated with adding new edges to a graph. Also contains methods that are passed to those listeners.

Hierarchy

  • EdgesAddHandler

Implements

Index

Constructors

constructor

Properties

Protected graph

graph: Grapher

Graph representatation to which new edges are to be added.

Private tempEdge

tempEdge: SvgEdge | null

Temporary edge that is displayed while user is connecting vertices by dragging.

Methods

disable

  • disable(): void

enable

  • enable(): void

Protected onEdgeDrag

  • onEdgeDrag(event: InteractEvent): void
  • Method that handles dragging input when connecting two vertices.

    Parameters

    • event: InteractEvent

      Drag event.

    Returns void

Protected onEdgeDragEnd

  • onEdgeDragEnd(startVertex: SvgVertex, event: InteractEvent): void
  • Method that handles end of drag when connecting two vertices.

    Parameters

    • startVertex: SvgVertex

      Vertex from which dragging started. Will be used as start vertex for new edge.

    • event: InteractEvent

      Drag start event.

    Returns void

Protected onEdgeDragStart

  • onEdgeDragStart(startVertex: SvgVertex, event: InteractEvent): void
  • Method that handles start of drag when connecting two vertices.

    Parameters

    • startVertex: SvgVertex

      Vertex from which dragging started. Will be used as start vertex for temp edge.

    • event: InteractEvent

      Drag start event.

    Returns void

Legend

  • Module
  • Object literal
  • Variable
  • Function
  • Function with type parameter
  • Index signature
  • Type alias
  • Enumeration
  • Enumeration member
  • Property
  • Method
  • Interface
  • Interface with type parameter
  • Constructor
  • Property
  • Method
  • Index signature
  • Class
  • Class with type parameter
  • Constructor
  • Property
  • Method
  • Accessor
  • Index signature
  • Inherited constructor
  • Inherited property
  • Inherited method
  • Inherited accessor
  • Protected property
  • Protected method
  • Protected accessor
  • Private property
  • Private method
  • Private accessor
  • Static property
  • Static method

Generated using TypeDoc