SPMapViewBuilding

@interface SPMapViewBuilding : NSObject

Object for storing building information visible on the map. This class is mainly used internally by the SDK.

  • Recommended constructor for creating SPMapViewBuilding objects.

    Declaration

    Objective-C

    + (nullable instancetype)buildingWithAttributes:(nonnull NSDictionary *)attrs;

    Swift

    convenience init?(attributes attrs: [AnyHashable : Any] = [:])

    Parameters

    attrs

    building attributes

    Return Value

    new instance of SPMapViewBuilding

  • Get unique identifier for building

    Declaration

    Objective-C

    - (nonnull NSString *)buildingId;

    Swift

    func buildingId() -> String

    Return Value

    building identifier

  • Declaration

    Objective-C

    - (nonnull NSArray<SPFloor *> *)floors;

    Swift

    func floors() -> [SPFloor]

    Return Value

    list of floors

  • Change the currently selected floor for the building.

    Declaration

    Objective-C

    - (BOOL)setSelectedFloor:(nonnull NSNumber *)floorIndex;

    Swift

    func setSelectedFloor(_ floorIndex: NSNumber) -> Bool

    Parameters

    floorIndex

    index to select

    Return Value

    true if floor selection was successful

  • Declaration

    Objective-C

    - (nonnull SPFloor *)selectedFloor;

    Swift

    func selectedFloor() -> SPFloor

    Return Value

    currently selected floor