Interface SiteModelRepositoryInterface

Site model data repository.

The site model repository object enables standard create, read, update, and delete methods on site model entities. Additional helpful methods are provided that enable more advanced retrieval of site model entities.

Hierarchy

Methods

  • Gets all repository items. The cached data will be returned if the data has been fetched before. Using the forceFetch parameter, a user can order a fresh copy to be fetched from the server.

    Parameters

    • Optional forceFetch: boolean

      Whether to bypass the cache and retrieve a fresh copy from the server.

    Returns Promise<SiteModelEntityInterface[]>

    Promise with the repository items.

  • Find the closest site model entity of a certain type within a given 2-dimensional radius [m] from a given point.

    Parameters

    • type: SiteModelType

      The SiteModelType to find.

    • pos: Vector3

      The starting, central point to search from.

    • maxDist: number

      The maximum distance [m] from the central point.

    Returns Promise<SiteModelEntityInterface>

  • Get one repository item by id. The cached data will be returned if the data has been fetched before. Use the forceFetch parameter to retrieve a fresh copy from the server. In case a new record is fetched, the data and dataMap will be updated accordingly.

    Parameters

    • id: number

      Identifier of the repository item

    • Optional forceFetch: boolean

      Whether to bypass the cache and retrieve a fresh copy from the server.

    Returns Promise<SiteModelEntityInterface>

  • Find site model entities from a given local coordinate with optional site model type.

    Parameters

    • localLocation: Vector3 | Vector2

      Local point from which to find nearby site model entities.

    • Optional entityType: SiteModelType

      Reduce search to include only the given site model type.

    Returns Promise<SiteModelEntityInterface[]>

Generated using TypeDoc