
###########
LineManager
###########

.. js:class:: LineManager

   This class provides an interface to 3D line management related functions of the viewer.
   
   
   Index
   =====
   
   .. rubric:: Methods
   
   
   .. rst-class:: api-xref-list
   
   
   * :js:meth:`~LineManager.addLine`
   * :js:meth:`~LineManager.exportMarkup`
   * :js:meth:`~LineManager.getAllLines`
   * :js:meth:`~LineManager.getLineByNodeId`
   * :js:meth:`~LineManager.loadData`
   * :js:meth:`~LineManager.removeAllLines`
   * :js:meth:`~LineManager.removeLastLine`
   * :js:meth:`~LineManager.removeLine`
   
   




Methods
=======

.. js:method:: LineManager.addLine

   .. rst-class:: sig-pretty-signature
   
      | addLine(**lineItem**\ : :js:class:`LineMarkup <Markup.Line.LineMarkup>`\ ): *Promise*
   
   Adds a new Line to the Line Manager
   
   **Parameters**
   
      **lineItem**\ : :js:class:`LineMarkup <Markup.Line.LineMarkup>`
   
         LineMarkup Object that will be added
   
   
   
   **Returns**\ : *Promise*
   



.. js:method:: LineManager.exportMarkup

   .. rst-class:: sig-pretty-signature
   
      | exportMarkup(): *object*\ []
   
   **Returns**\ : *object*\ []
   
      JSON Array with line markup
   
   



.. js:method:: LineManager.getAllLines

   .. rst-class:: sig-pretty-signature
   
      | getAllLines(): :js:class:`LineMarkup <Markup.Line.LineMarkup>`\ []
   
   Return an array of line items.
   
   **Returns**\ : :js:class:`LineMarkup <Markup.Line.LineMarkup>`\ []
   
      array of all line items.
   
   



.. js:method:: LineManager.getLineByNodeId

   .. rst-class:: sig-pretty-signature
   
      | getLineByNodeId(**id**\ : *number*\ ): (*None* \| :js:class:`LineMarkup <Markup.Line.LineMarkup>`\ )
   
   Gets a line markup item associated with a node id.
   
   **Parameters**
   
      **id**\ : *number*
   
   
   **Returns**\ : (*None* \| :js:class:`LineMarkup <Markup.Line.LineMarkup>`\ )
   



.. js:method:: LineManager.loadData

   .. rst-class:: sig-pretty-signature
   
      | loadData(**lineDataJson**\ : *any*\ []): *Promise*
   
   Loads JSON markup data
   
   **Parameters**
   
      **lineDataJson**\ : *any*\ []
   
   
   **Returns**\ : *Promise*
   



.. js:method:: LineManager.removeAllLines

   .. rst-class:: sig-pretty-signature
   
      | removeAllLines(): *Promise*
   
   Removes all line items.
   
   **Returns**\ : *Promise*
   



.. js:method:: LineManager.removeLastLine

   .. rst-class:: sig-pretty-signature
   
      | removeLastLine(): *Promise*
   
   Removes the most recently added line item.
   
   **Returns**\ : *Promise*
   



.. js:method:: LineManager.removeLine

   .. rst-class:: sig-pretty-signature
   
      | removeLine(**lineItem**\ : :js:class:`LineMarkup <Markup.Line.LineMarkup>`\ ): *Promise*
   
   Removes an existing line item.
   
   **Parameters**
   
      **lineItem**\ : :js:class:`LineMarkup <Markup.Line.LineMarkup>`
   
         the line item to remove.
   
   
   
   **Returns**\ : *Promise*
   





