Package 

Interface SearchController

  • All Implemented Interfaces:

    
    public interface SearchController
    
                        

    Controller to handle search POI

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
    • Field Summary

      Fields 
      Modifier and Type Field Description
    • Constructor Summary

      Constructors 
      Constructor Description
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
    • Method Summary

      Modifier and Type Method Description
      abstract Unit injectSearchEngine(SearchEngine searchEngine, CoroutineDispatcher dispatcher) Inject a search engine to the controller.
      abstract Unit injectPoiAnnotationFactory(PoiAnnotationFactory factory) Inject a POI annotation factory to the controller.
      abstract Unit displayPOI(List<String> displayContent) SDK will observe the movement of camera and show POI if exist.
      abstract Unit clear() Clear all displayed POIs and their cached data.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

    • Method Detail

      • injectSearchEngine

         abstract Unit injectSearchEngine(SearchEngine searchEngine, CoroutineDispatcher dispatcher)

        Inject a search engine to the controller. If inject search engine multiple times, only the last one will work.

        Parameters:
        searchEngine - engine for the search task
        dispatcher - used for custom kotlinx.coroutines CoroutineDispatcher for poi search task, default dispatcher is Dispatchers.
      • injectPoiAnnotationFactory

         abstract Unit injectPoiAnnotationFactory(PoiAnnotationFactory factory)

        Inject a POI annotation factory to the controller. If this method is called, the map will refresh and use the new injected factory to create annotations. If this method is never called, the map will use the default method to create Annotation

      • displayPOI

         abstract Unit displayPOI(List<String> displayContent)

        SDK will observe the movement of camera and show POI if exist. The POIs are searched by the injected searchEngine with the searchTexts as search parameter. If the searchEngine is not injected. This method will not work.

        Parameters:
        displayContent - The search parameter.
      • clear

         abstract Unit clear()

        Clear all displayed POIs and their cached data.