MyPlaces
public class MyPlaces
extension MyPlaces: NativeBase
extension MyPlaces: Hashable
Provides means to populate personal places data source. Also acts as a owner of the collection of personal places. MyPlaces is memory-only object: nothing is persisted and/or sent over the network. Client has full control on how to store personal places.
-
Creates a new instance of this class.
Declaration
Swift
public init() -
The list of places which currently belong to this data source. This list is a clone of the internal list and thus changing it has no effect on the data source.
Declaration
Swift
public var places: [GeoPlace] { get } -
Adds a place to this data source.
Declaration
Swift
public func addPlace(place: GeoPlace, callback: @escaping TaskCompletionHandler) -> TaskHandleParameters
placeThe place.
callbackThe callback to be called when task is completed.
Return Value
Handle that will be used to manipulate the execution of the task.
-
Adds a list of places to this data source.
Declaration
Swift
public func addPlaces(places: [GeoPlace], callback: @escaping TaskCompletionHandler) -> TaskHandleParameters
placesPlaces
callbackThe callback to be called when task is completed.
Return Value
Handle that will be used to manipulate the execution of the task.
-
Removes a place from this data source.
Declaration
Swift
public func removePlace(placeId: String, callback: @escaping TaskCompletionHandler) -> TaskHandleParameters
placeIdThe place id
callbackThe callback to be called when task is completed.
Return Value
Handle that will be used to manipulate the execution of the task.
-
Removes a list of places from this data source.
Declaration
Swift
public func removePlaces(placeIds: [String], callback: @escaping TaskCompletionHandler) -> TaskHandleParameters
placeIdsPlace ids
callbackThe callback to be called when task is completed.
Return Value
Handle that will be used to manipulate the execution of the task.
-
Removes all places from this data source.
Declaration
Swift
public func removeAll(callback: @escaping TaskCompletionHandler) -> TaskHandleParameters
callbackThe callback to be called when task is completed.
Return Value
Handle that will be used to manipulate the execution of the task.