@magiclane/maps-sdk
    Preparing search index...

    Class LandmarkStoreServiceAbstract

    Landmark store service

    A static service providing high-level management for landmark store lifecycle and discovery. It is the central entry point for creating or registering stores, looking up existing stores, removing stores, enumerating all available stores and obtaining built-in store identifiers used by the map.

    Main capabilities include store creation/registration and lookup, retrieval of special-purpose store identifiers used by the SDK, enumeration of available stores. Common tasks are creating or importing a store, resolving a store to use for imports or queries, removing an unused store, listing store and adding/removing event listeners to react to store lifecycle changes.

    Index

    Constructors

    Accessors

    • get geofenceLandmarkStoreId(): number

      Get LandmarkStore id attached to geofence database.

      The result Id cannot be used with getLandmarkStoreById

      Returns number

      Landmark store ID

      An exception if it fails.

    • get landmarkStores(): LandmarkStore[]

      Get all landmark stores.

      Returns LandmarkStore[]

      List of LandmarkStore objects

      An exception if it fails.

    • get mapAddressLandmarkStoreId(): number

      Get Map Address landmarkstore id attached to map address database information.

      The result Id cannot be used with getLandmarkStoreById

      Returns number

      Map Address landmarkstore id

      An exception if it fails.

    • get mapCitiesLandmarkStoreId(): number

      Get Map Cities landmarkstore id attached to map address database information.

      The result Id cannot be used with getLandmarkStoreById

      Returns number

      Map Cities landmarkstore id

      An exception if it fails.

    • get mapPoisLandmarkStoreId(): number

      Get Map POIs landmarkstore id.

      Returns number

      Map POI landmark store id

      An exception if it fails.

    • get mapRoadsLandmarkStoreId(): number

      Get LandmarkStore id attached to map roads database information.

      The result Id cannot be used with getLandmarkStoreById

      Returns number

      Landmark store ID

      An exception if it fails.

    • get overlaysLandmarkStoreId(): number

      Get LandmarkStore id attached to overlays database.

      The result Id cannot be used with getLandmarkStoreById

      Returns number

      Landmark store ID

      An exception if it fails.

    Methods

    • Add new listener for landmark store events.

      Parameters

      Returns void

      An exception if it fails.

    • Create a new landmark store. The landmark store type for all stores created with this function is LandmarkStoreType.defaultType

      Parameters

      • name: string

        The name of the landmark store. The name must be unique otherwise will return GemError.exist.

      • options: { folder?: string; zoom?: number } = {}

        Optional parameters

        • Optionalfolder?: string

          Folder path where the landmark store will be created. If empty, the landmark store will be created in the SDK default location. Defaults to empty string.

        • Optionalzoom?: number

          The max zoom step at which the landmark store will be visible. If -1, a default optimal zoom level is selected. Defaults to -1.

      Returns LandmarkStore

      LandmarkStore object. If a landmark store with the given name already exists, it is returned.

      An exception if it fails.

    • Get landmark store by ID.

      Parameters

      • landmarkStoreId: number

        The ID of the landmark store

      Returns LandmarkStore | null

      LandmarkStore object if it exists, otherwise null.

      An exception if it fails.

    • Get landmark store by name.

      Parameters

      • name: string

        The name of the landmark store

      Returns LandmarkStore | null

      LandmarkStore object if it exists, otherwise null.

      An exception if it fails.

    • Get the type of the landmark store

      Parameters

      • landmarkStoreId: number

        The ID of the landmark store.

      Returns LandmarkStoreType

      The landmark store type as LandmarkStoreType. If landmarkStoreId is invalid, it returns LandmarkStoreType.none

      An exception if it fails.

    • Register an already existing landmark store.

      The name parameter will override the landmark store internal creation name. This allows registering landmark stores in order to import data from them

      Parameters

      • options: { name: string; path: string }

        Object containing registration parameters

        • name: string

          The landmark store name. Must be unique, otherwise GemError.exist.code is returned

        • path: string

          The landmark store path

      Returns number

      On success the landmark store ID (greater than zero) is returned

      • GemError.exist.code if the name already exists
      • GemError.notFound.code if the landmark store cannot be found
      • GemError.invalidInput.code if the path is not a valid landmark store

      An exception if it fails.

    • Remove the landmark store specified by ID.

      The landmark store should be disposed before calling this method. Dispose the landmark store using LandmarkStore.dispose. The landmarks store will not be removed unless the object is disposed.

      The method does not work if the landmark store is in use.

      Parameters

      • landmarkStoreId: number

        The landmark store ID

      Returns void

      An exception if it fails.

    • Remove listener for landmark store events.

      Parameters

      Returns void

      An exception if it fails.