Class: Edge

Edge

(abstract) new Edge()

Edge instances should be created with Factory#createOrUpdateEdge.

Extends

  • EventEmitter

Members

(abstract) fromNode :Node

Type:

(abstract) fromNodeType :NodeType

Type:

(abstract) id :EdgeId

Type:

(abstract) toNode :Node

Type:

(abstract) toNodeType :NodeType

Type:

(abstract) type :EdgeType

Type:

Methods

delete()

Delete the edge.

Will also remove the edge from all connected nodes.

(abstract) extendJson() → {Object}

Hook for children to provide additional fields in the Edge#toJson response.

Returns:
Type
Object

toJson() → {EdgeJson}

Get a JSON representation of the Edge.

Returns:
Type
EdgeJson

(abstract) update(raw)

Update the Edge's data.

Parameters:
Name Type Description
raw Object