Class LibrarySettings


  • public class LibrarySettings
    extends Object
    Situm Maps initialization settings.
    • Constructor Detail

      • LibrarySettings

        public LibrarySettings()
    • Method Detail

      • setUseDashboardTheme

        public void setUseDashboardTheme​(boolean useDashboardTheme)
        Use the theme defined in the dashboard.
        Parameters:
        useDashboardTheme - Whether the dashboard vs default theme should be used.
      • setDrawGeofences

        public void setDrawGeofences​(boolean drawGeofences)
        Draw the geofences over the map.
      • getCredentials

        @Nullable
        public es.situm.maps.library.domain.model.Credentials getCredentials()
        Get login credentials.
        Returns:
        Login credentials or null if none were provided.
      • setApiKey

        public void setApiKey​(@NonNull
                              String email,
                              @NonNull
                              String apiKey)
        Set dashboard credentials.
        Parameters:
        email - Email.
        apiKey - ApiKey.
      • setUserPass

        public void setUserPass​(@NonNull
                                String email,
                                @NonNull
                                String password)
        Set dashboard credentials.
        Parameters:
        email - Email.
        password - Password.
      • setDashboardUrl

        public void setDashboardUrl​(@NonNull
                                    String dashboardUrl)
        Overrides default dashboard URL.
        Parameters:
        dashboardUrl - Dashboard URL.
      • setHasSearchView

        public void setHasSearchView​(boolean hasSearchView)
        Set whether or not the search view should be displayed.
        Parameters:
        hasSearchView - true to display the search view component.
      • setSearchViewPlaceholder

        public void setSearchViewPlaceholder​(String placeholder)
        Set the text that will be used as placeholder in the search view component.
        Parameters:
        placeholder - Placeholder text.
      • setGoogleMap

        public void setGoogleMap​(@NonNull
                                 com.google.android.gms.maps.MapView googleMap)
        By default the library will create a Google Map itself, use this method to set your own one.
        Parameters:
        googleMap - Google Map view instance
      • getUserPositionIcon

        public String getUserPositionIcon()
        Get the icon representing the user position.
        Returns:
        Path of the icon in the assets folder.
      • setUserPositionIcon

        public void setUserPositionIcon​(String userPositionIcon)
        Set the icon representing the user position.
        Parameters:
        userPositionIcon - Path in the assets folder.
      • getUserPositionArrowIcon

        public String getUserPositionArrowIcon()
        Get the icon representing the user position with orientation.
        Returns:
        Path of the icon in the assets folder.
      • setUserPositionArrowIcon

        public void setUserPositionArrowIcon​(String userPositionArrowIcon)
        Set the icon representing the user position with orientation.
        Parameters:
        userPositionArrowIcon - Path in the assets folder.
      • setUseRemoteConfig

        public void setUseRemoteConfig​(boolean useRemoteConfig)
        Set whether or not to use the Remote Configuration when the positioning is started. The default value is false. Both default and remote config can be overridden using the provided interceptor.
        Parameters:
        useRemoteConfig - true to use Remote Config, false to use the default location settings.
        See Also:
        SitumMapsLibrary#addLocationRequestInterceptor(Interceptor)
      • isUseRemoteConfig

        public boolean isUseRemoteConfig()
        Returns whether or not to use the Remote Configuration when the positioning is started.
        Returns:
        true to use Remote Config, false to use the default location settings.
      • isShowPoiNames

        public boolean isShowPoiNames()
        Shows the title of the poi above the marker
        Returns:
        Return true if it should show the title of the poi above the marker. Default is false
      • setShowPoiNames

        public void setShowPoiNames​(boolean showPoiNames)
        Shows the title of the poi above the marker
        Parameters:
        showPoiNames - True to show the title of the poi above the marker
      • setEnablePoiClustering

        public void setEnablePoiClustering​(boolean enablePoiClustering)
        Sets whether or not the marker clustering for POIs is enabled.
        Parameters:
        enablePoiClustering - true to enable clustering, false to disable it. Default is false.
      • isEnablePoiClustering

        public boolean isEnablePoiClustering()
        Returns whether or not the marker clustering for POIs is enabled. Default is false.
        Returns:
        true to enable clustering, false to disable it.