@situm/react-native
    Preparing search index...

    Class default

    Index
    navigationIsRunning: () => boolean = ...

    Whether the navigation is currently in execution.

    Type Declaration

      • (): boolean
      • Returns boolean

        boolean

    positioningIsRunning: () => boolean = ...

    Whether the positioning is currently in execution.

    Type Declaration

      • (): boolean
      • Returns boolean

        boolean

    • Checks if a point is inside a Geofence

      Parameters

      • request: any
      • Optionalcallback: (response: { geofence: any; isInsideGeofence: boolean }) => void

      Returns void

    • Automatically assists users in resolving app-related permission and sensor issues.

      This method tells the native SDKs to present a user interface that explains detected configuration issues and guides users through the required steps to resolve them, following best practices for runtime permission requests.

      Issues addressed include:

      • Missing permissions for Location or Bluetooth.
      • Disabled Location or Bluetooth sensors.

      Use the userHelperOptions parameter to configure the available options. Call enableUserHelper as a shortcut to enable the user helper with default configuration. Call disableUserHelper as a shortcut to disable the user helper.

      Parameters

      Returns Promise<void>

      Promise that resolves when the user helper is configured, and rejects if the native SDK fails to configure it.

    • (Experimental) Downloads the tiled-map of a certain building

      Parameters

      Returns Promise<any>

    • Returns the device identifier that has generated the location

      Returns Promise<string>

    • Initializes SitumPlugin.

      This method must be called before invoking any other methods. This method can be safely called many times as it will only initialise the SDK if it is not already initialised.

      Returns void

      void

      Exception

    • INTERNAL METHOD.

      Set a native MethodCall delegate. Do not use this method as it is intended for internal use by the map viewer module.

      Parameters

      Returns void

    • Invalidate all the resources in the cache

      Returns void

      void

      Exception

    • Callback that notifies when the user enters a Geofence.

      In order to use correctly these callbacks you must know the following:

      • Positioning geofences (with trainer_metadata custom field) won't be notified.
      • These callbacks only work with indoor locations. Any outdoor location will produce a call to onExitedGeofences with the last positioned geofences as argument.

      Parameters

      • callback: (event: Geofence) => void

        the function called when the user enters a Geofence

      Returns void

    • Callback that notifies when the user exits a Geofence.

      In order to use correctly these callbacks you must know the following:

      • Positioning geofences (with trainer_metadata custom field) won't be notified.
      • These callbacks only work with indoor locations. Any outdoor location will produce a call to onExitedGeofences with the last positioned geofences as argument.

      Parameters

      • callback: (event: Geofence) => void

        the function called when the user exits a Geofence

      Returns void

    • Callback that notifies when there is an error while the user is positioining.

      Parameters

      • callback: (error: Error) => void

        the function called when there is an error

      Returns void

    • Callback that notifies when the user stops positioning.

      Parameters

      • callback: () => void

        the function called when the user stops positioning.

      Returns void

    • Callback that notifies when the user Location changes.

      Parameters

      • callback: (location: Location) => void

        the function called when the user Location changes

      Returns void

    • Callback that notifies when the user does cancel the navigation.

      Parameters

      • callback: () => void

        the function called when the user cancels the navigation.

      Returns void

    • Callback that notifies when the user reaches the destination POI.

      Parameters

      • callback: (route: Route) => void

        a function that returns the completed Route by parameters.

      Returns void

    • Callback that notifies when there is an error during navigation.

      Parameters

      • callback: (error: any) => void

        the function called when there is an error during navigation.

      Returns void

    • Parameters

      • callback: () => void

        the function called when the user finishes the route.

      Returns void

      DEPRECATED: Use instead onNavigationCancellation() and onNavigationDestinationReached() to determine why did the navigation end.

      Callback that notifies when the user finishes the route.

    • Callback that notifies when the user gets out of the current route.

      Parameters

      • callback: () => void

        the function called when the user gets out of the current route.

      Returns void

    • Callback that notifies when navigation starts.

      Parameters

      • callback: (route: Route) => void

        a function that returns the initial Route by parameters.

      Returns void

    • Stops positioning, removing all location updates

      Returns Promise<void>

      Promise that resolves when positioning is stopped, and rejects if the native positioning stop operation fails.

    • Removes all location updates. This removes the internal state of the manager, including the listener provided in requestNavigationUpdates(NavigationRequest, NavigationListener), so it won't receive more progress updates.

      Returns Promise<void>

    • Removes all real time updates listners.

      Parameters

      • Optional_callback: Function

      Returns void

    • Starts positioning.

      Parameters

      • OptionallocationRequest: LocationRequest

        Positioning options to configure how positioning will behave

      Returns void

    • Set the navigation params, and the listener that receives the updated navigation progress.

      Can only exist one navigation with one listener at a time. If this method was previously invoked, but removeLocationUpdates() wasn't, removeLocationUpdates() is called internally.

      Parameters

      Returns void

    • Requests a real time devices positions

      Parameters

      • realtimeUpdates: (event: any) => void

        callback to use when new device positions are updated

      • Optionalerror: (event: any) => void

        callback to use when an error on navigation udpates raises

      • Optionaloptions: any

        Represents the configuration for getting realtime devices positions in

      Returns void

    • Returns SdkVersion

      void

      DEPRECATED: this method will not work anymore.

      Gets the list of versions for the current plugin and environment

      Exception

    • Provides your API key to the Situm SDK.

      This key is generated for your application in the Dashboard. Old credentials will be removed.

      Parameters

      • apiKey: string

        user's apikey.

      Returns Promise<void>

      Promise that resolves when the API key is set, and rejects if the native SDK rejects it.

    • Sets the API's base URL to retrieve the data.

      Parameters

      • url: string

        Base URL of the Situm API, including the protocol and the domain.

      Returns void

      void

      Exception if the URL is empty.

    • Provides your token to the Situm SDK. Any previously configured credentials will be replaced. The SDK does not cryptographically validate the token signature, nor does it verify the token against Situm servers when this method is called. The token is parsed locally only to obtain the account information needed by the SDK, and it will be sent as a Bearer token in subsequent authenticated network requests.

      If the provided token is expired, has an invalid signature, or is otherwise rejected by Situm servers, network operations that require server authentication will fail. However, features that can operate with already cached local data may continue to work, such as visualizing cached resources or positioning with previously downloaded positioning data.

      User-provided tokens cannot be renewed automatically by the SDK. To recover from an expired or rejected token, provide a new token by calling this method again.

      Parameters

      • token: string

        JWT token used for authentication. The expected format is a base64-encoded JWT with header, payload and signature sections. This token can be retrieved from a REST endpoint.

      Returns Promise<void>

      Promise that resolves when the token is set, and rejects if the native SDK rejects it.

    • Set to true if you want the SDK to download the configuration from the Situm API and use it by default. Right now it only affects the LocationRequest. Default value is true from SDK version 2.83.5

      Parameters

      • useRemoteConfig: boolean

      Returns Promise<void>

      Promise that resolves when the setting is applied.

    • Provides user's email and password. This credentials will be used to obtain a valid user token to authenticate the server request, when necessary. Token obtaining is not necessary done when this method is executed. Old credentials will be removed.

      Parameters

      • email: string

        user's email.

      • password: string

        user's password.

      Returns Promise<void>

      Promise that resolves when the credentials are set, and rejects if the native SDK rejects them.

    • INTERNAL METHOD.

      Ask sdk to start sharing its location. Do not use this method as it is intended for internal use by the map viewer module.

      Parameters

      • options: any

      Returns void

    • INTERNAL METHOD.

      Ask sdk to stop sharing its location. Do not use this method as it is intended for internal use by the map viewer module.

      Returns void

    • INTERNAL METHOD.

      Update SDK with the viewer navigation states. Do not use this method as it is intended for internal use by the map viewer module.

      Parameters

      • externalNavigation: Map<string, any>

      Returns void

    • Informs NavigationManager object the change of the user's location

      Parameters

      Returns Promise<void>

      Promise that resolves when the navigation is updated, and rejects if the native SDK fails to update it.

      Exception if there is no active navigation.

    • INTERNAL METHOD.

      Validate if the mapView internal settings have been properly configured Do not use this method as it is intended for internal use by the map viewer module.

      Returns void