DrawingAPI#

Interface DrawingAPI

The DrawingAPI provides basic functionalities to interact with 2D Drawings created with the help of the ViewerDrawingAPI.

Hierarchy

Methods

  • Changes one or more properties of a Drawing with the specified id.

    Parameters

    • drawingId: number

      The id of the Drawing.

    • properties: DrawingProperties

      The properties of the Drawing.

    Returns DrawingProperties

    An object with the changed properties.

  • Returns all available Drawing ids.

    Returns number[]

    An Array of all available Drawing ids.

  • Removes a Drawing with the specified id. If a Drawing is part of a Snapshot the removal will fail with the State REFERENCED_BY_SNAPSHOT

    Parameters

    • drawingId: number

      The id of the to be removed Drawing.

    • Optional safe: boolean

      Performs a safe remove which interrupt the removal process if the Drawing is part of one or more Snapshots.

    Returns RemoveState

  • Returns the DrawingData for the specified Drawing id.

    Parameters

    • drawingId: number

      The id of the Drawing from which the data is requested.

    Returns Promise<DrawingData>

    The requested Drawing data.


Did you find this page useful? Please give it a rating:
Thank you for rating this page!
Any issues or feedback?
What kind of problem would you like to report?
Please tell us more about what's wrong: