PointOfInterestManaging
public protocol PointOfInterestManaging : AnyObject
                - 
                  
                  
Declaration
Swift
var delegate: PointOfInterestManagerDelegate? { get set } - 
                  
                  
Indicates whether user interaction for selection is enabled.
When set to
true, the user can interact with the POIs to select them. When set tofalse, selection is disabled and user interaction will not result in any selection changes.The default value is
true.Declaration
Swift
var isUserSelectionEnabled: Bool { get set } - 
                  
                  
Determines how POIs can be selected. See
PointOfInterestManager.SelectionModefor possible values.When changing from
.multipleto.single, all previously selected POIs, except one, will be unselected.Default value is
.single.Declaration
Swift
var selectionMode: PointOfInterestManager.SelectionMode { get set } - 
                  
                  
Retrieves a set of all available Points of Interest (POIs).
Declaration
Swift
func getPOIs() -> Set<PointOfInterest>Return Value
A
SetofPointOfInterestrepresenting all known POIs. Returns an empty set if no POIs are available. 
- 
                  
                  
Adds a Point of Interest (POI) to the manager.
Declaration
Swift
func addPOI(_ poi: PointOfInterest) -> BoolParameters
poiThe
PointOfInterestto add.Return Value
trueif the POI was successfully added,falseotherwise (e.g., if a POI with the same ID already exists). - 
                  
                  
Removes a Point of Interest (POI) from the manager.
Declaration
Swift
func removePOI(_ poi: PointOfInterest) -> BoolParameters
poiThe
PointOfInterestto remove.Return Value
trueif the POI was successfully removed,falseotherwise (e.g., if the POI was not found or on attempt to remove POI received from Wemap backend). - 
                  
                  
Adds multiple Points of Interest (POIs) to the manager.
Declaration
Swift
func addPOIs(_ pois: Set<PointOfInterest>) -> BoolParameters
poisA
SetofPointOfInterestto add.Return Value
trueif all POIs were successfully added,falseotherwise (e.g., if any POI could not be added). - 
                  
                  
Removes multiple Points of Interest (POIs) from the manager.
Declaration
Swift
func removePOIs(_ pois: Set<PointOfInterest>) -> BoolParameters
poisA
SetofPointOfInterestto remove.Return Value
trueif all POIs were successfully removed,falseotherwise (e.g., if any POI was not found or on attempt to remove POI received from Wemap backend). 
- 
                  
                  
Shows all Points of Interest (POIs).
Declaration
Swift
func showAllPOIs() -> BoolReturn Value
trueif the POIs were successfully shown,falseotherwise. - 
                  
                  
Hides all Points of Interest (POIs).
Declaration
Swift
func hideAllPOIs() -> BoolReturn Value
trueif the POIs were successfully hidden,falseotherwise. - 
                  
                  
Shows a specific Point of Interest (POI).
Declaration
Swift
func showPOI(_ poi: PointOfInterest) -> BoolParameters
poiThe
PointOfInterestto show.Return Value
trueif the POI was successfully shown,falseotherwise (e.g., if the POI was not found or could not be shown). - 
                  
                  
Hides a specific Point of Interest (POI).
Declaration
Swift
func hidePOI(_ poi: PointOfInterest) -> BoolParameters
poiThe
PointOfInterestto hide.Return Value
trueif the POI was successfully hidden,falseotherwise (e.g., if the POI was not found or could not be hidden). - 
                  
                  
Shows the POI with the specified ID.
Declaration
Swift
func showPOI(id: Int) -> BoolParameters
idThe unique identifier of the POI.
Return Value
trueif the POI was shown,falseotherwise (e.g., if the POI with the given ID was not found or could not be shown). - 
                  
                  
Hides the POI with the specified ID.
Declaration
Swift
func hidePOI(id: Int) -> BoolParameters
idThe unique identifier of the POI.
Return Value
trueif the POI was hidden,falseotherwise (e.g., if the POI with the given ID was not found or could not be hidden). - 
                  
                  
Shows a set of Points of Interest.
Declaration
Swift
func showPOIs(_ pois: Set<PointOfInterest>) -> BoolParameters
poisThe set of
PointOfInterestto show.Return Value
trueif the POIs were shown successfully,falseotherwise. - 
                  
                  
Hides a set of Points of Interest.
Declaration
Swift
func hidePOIs(_ pois: Set<PointOfInterest>) -> BoolParameters
poisThe set of
PointOfInterestto hide.Return Value
trueif the POIs were hidden successfully,falseotherwise. 
- 
                  
                  
Retrieves the set of currently selected POIs (for
.multiplemode).This method should be used only when
selectionModeis set to.multiple. IfselectionModeis set to.singleusegetSelectedPOI.Declaration
Swift
func getSelectedPOIs() -> Set<PointOfInterest>Return Value
A
Setof currently selectedPointOfInterest. May be empty. - 
                  
                  
Retrieves the currently selected POI (for
.singlemode).This method should be used only when
selectionModeis set to.single. Otherwise, it will return the first selected POI. IfselectionModeis set to.multipleusegetSelectedPOIs.Declaration
Swift
func getSelectedPOI() -> PointOfInterest?Return Value
The currently selected
PointOfInterest, ornilif none is selected. - 
                  
                  
Unselects all selected POIs (for
.multiplemode).This method should be used only when
selectionModeis set to.multiple. IfselectionModeis set to.singleuseunselectPOI.Declaration
Swift
func unselectAllPOIs() -> BoolReturn Value
trueif the operation was successful,falseotherwise. - 
                  
                  
Unselects a specific POI.
Declaration
Swift
func unselectPOI(_ poi: PointOfInterest) -> BoolParameters
poiThe POI to unselect.
Return Value
trueif the POI was successfully unselected,falseotherwise. - 
                  
                  
Unselects a POI by ID.
Declaration
Swift
func unselectPOI(id: Int) -> BoolParameters
idThe ID of the POI to unselect.
Return Value
trueif the POI was unselected,falseotherwise. - 
                  
                  
Unselects the currently selected POI (for
.singlemode).This method should be used only when
selectionModeis set to.single. Otherwise, it will unselect the first selected POI. IfselectionModeis set to.multipleuseunselectAllPOIsor unselect a specific POI instead.Declaration
Swift
func unselectPOI() -> BoolReturn Value
trueif a POI was selected and successfully unselected,falseotherwise. 
- 
                  
                  
Filters POIs based on the presence of a specific tag.
This function checks if a given tag is present within a collection of tags associated with the
PointOfInterest.Declaration
Swift
func filterByTag(_ tag: String) -> BoolParameters
tagThe tag to filter by.
Return Value
trueif any POI contains the tag,falseotherwise. - 
                  
                  
Removes all active POI filters.
Declaration
Swift
func removeFilters() -> BoolReturn Value
trueif any filters were removed,falseotherwise. 
- 
                  
                  
Sorts POIs by graph distance from a given origin.
This function utilizes a graph-based routing to calculate the distance from the origin to each POI. The POIs are then sorted in ascending order of distance.
Declaration
Swift
func sortPOIsByGraphDistance(origin: Coordinate, pois: [PointOfInterest]) -> Single<[PointOfInterestWithInfo]>Parameters
originThe origin
Coordinatefor distance calculation.poisAn array of POIs to sort.
Return Value
A
Singleemitting an array ofPointOfInterestWithInfosorted by graph distance. ThePointOfInterestWithInfoobjects contain the original POI data and additional information including the calculated distance. If a POI’s distance cannot be determined, it will likely be placed at the end of the sorted array, or an error will be propagated through theSingle. - 
                  
                  
Sorts POIs by estimated travel duration from a given origin.
This function takes an origin coordinate and an array of POIs and returns a
Singleemitting an array of POIs sorted by the time it takes to travel from the origin to each POI. The returned array containsPointOfInterestWithInfoobjects which encapsulate the original POI and associated travel information.Declaration
Swift
func sortPOIsByDuration(origin: Coordinate, pois: [PointOfInterest]) -> Single<[PointOfInterestWithInfo]>Parameters
originThe origin
Coordinate.poisAn array of POIs to sort.
Return Value
A
Singleemitting an array ofPointOfInterestWithInfosorted by duration. The array will be sorted in ascending order of duration (shortest duration first). If the origin is the same as a POI, the duration will be 0. If a POI’s duration cannot be determined, it will likely be placed at the end of the sorted array, or an error will be propagated through theSingle. - 
                  
                  
Sorts all POIs by graph distance from a given origin.
This function utilizes a graph-based routing to calculate the distance from the origin to each POI. The POIs are then sorted in ascending order of distance.
Declaration
Swift
func sortPOIsByGraphDistance(origin: Coordinate) -> Single<[PointOfInterestWithInfo]>Parameters
originThe origin
Coordinatefor distance calculation.Return Value
A
Singleemitting an array ofPointOfInterestWithInfosorted by graph distance. ThePointOfInterestWithInfoobjects contain the original POI data and additional information including the calculated distance. If a POI’s distance cannot be determined, it will likely be placed at the end of the sorted array, or an error will be propagated through theSingle. - 
                  
                  
Sorts all POIs by estimated travel duration from a given origin.
This function takes an origin coordinate and an array of all POIs and returns a
Singleemitting an array of POIs sorted by the time it takes to travel from the origin to each POI. The returned array containsPointOfInterestWithInfoobjects which encapsulate the original POI and associated travel information.Declaration
Swift
func sortPOIsByDuration(origin: Coordinate) -> Single<[PointOfInterestWithInfo]>Parameters
originThe origin
Coordinate.Return Value
A
Singleemitting an array ofPointOfInterestWithInfosorted by duration. The array will be sorted in ascending order of duration (shortest duration first). If the origin is the same as a POI, the duration will be 0. If a POI’s duration cannot be determined, it will likely be placed at the end of the sorted array, or an error will be propagated through theSingle. 
            View on GitHub