LineManager

class LineManager()

This class provides an interface to 3D line management related functions of the viewer.


Methods

addLine

LineManager.addLine(lineItem)
Arguments
  • lineItem (LineMarkup()) – LineMarkup Object that will be added

Adds a new Line to the Line Manager

Return type

Promise <void>

exportMarkup

LineManager.exportMarkup()
Returns

JSON Array with line markup

Return type

[object]

getAllLines

LineManager.getAllLines()

Return an array of line items.

Returns

array of all line items.

Return type

[LineMarkup]

getLineByNodeId

LineManager.getLineByNodeId(id)
Arguments
  • id (number()) – None

Gets a line markup item associated with a node id.

Return type

null | LineMarkup

loadData

LineManager.loadData(lineDataJson)
Arguments
  • lineDataJson ([any]()) – None

Loads JSON markup data

Return type

Promise <[boolean]>

removeAllLines

LineManager.removeAllLines()

Removes all line items.

Return type

Promise <void>

removeLastLine

LineManager.removeLastLine()

Removes the most recently added line item.

Return type

Promise <void>

removeLine

LineManager.removeLine(lineItem)
Arguments
  • lineItem (LineMarkup()) – the line item to remove.

Removes an existing line item.

Return type

Promise <void>