UtilsControllerInterface
public protocol UtilsControllerInterface
                - 
                  
                  
Calculates distance in meters between two mercator points
Declaration
Swift
func getDistance(m1: MNMercator, m2: MNMercator) -> DoubleParameters
m1The first point (mercator)
m2The second point (mercator)
Return Value
Distance between m1 and m2
 - 
                  
                  
Calculates distance in meters between two points each with a latitude/longitude value
Declaration
Swift
func getDistance(l1: MNLatLng, l2: MNLatLng) -> DoubleParameters
l1The first location (latitude/longitude)
l2The second location (latitude/longitude)
Return Value
Distance between m1 and m2
 - 
                  
                  
Calculates distance from a point to a polygon
Declaration
Swift
func getDistFromPointToPolygon(point: MNMercator, polygon: [MNMercator]) -> DoubleParameters
pointA mercator point
polygonA polygon defined by a list of mercator points
Return Value
Distance between point and polygon
 - 
                  
                  
Checks whether a point is inside the boundary of a polygon
Declaration
Swift
func isPointInPolygon(point: MNMercator, polygon: [MNMercator]) -> BoolParameters
pointA mercator point
polygonA polygon defined by a list of mercator points
Return Value
true if the point lies inside the boundaries of the polygon
 - 
                  
                  
Attempts to find a property and building in which the point lies
Declaration
Swift
func findPropertyAndBuilding(point: MNMercator) -> MNZone?Parameters
pointA mercator point
Return Value
A possible property/building zone in which the point lies
 - 
                  
                  
Call this function to perform intelligent search on the list of searchables based on a search string.
Declaration
Swift
func filterAndSortSearchables(input: String, listOfSearchables: [ISearchable]) -> [ISearchable]Parameters
inputThe string to search for
listOfSearchablesThe string to search for
Return Value
A list of searchables filtered for input and sorted by best match
 - 
                  
                  
Call this function to perform search of an entity inside a property
Declaration
Swift
func findEntityByName(name: String) -> [ISearchable]Parameters
nameThe name of the entity to search for
propertyIdAn identifier for the property
Return Value
A list of searchables matching the name
 - 
                  
                  
Declaration
Swift
func fetchOnlineSearch(propertyId: Int, text: String, lang: String, page: Int, limit: Int, completion: ((CMSOnlineSearchResultInfo?) -> Void)?) - 
                  
                  
Declaration
Swift
func fetchDestinationInstruction(propertyId: Int, completion: @escaping ((Bool) -> Void)) 
      UtilsControllerInterface Protocol Reference