TTCenterOnPointBuilder

Objective-C

@interface TTCenterOnPointBuilder : NSObject

Swift

class TTCenterOnPointBuilder : NSObject

Use this builder to create a TTCenterOnPoint viewport transform tailored to your needs.

  • Unavailable

    Use the createWithCenter method to create the builder.

    Declaration

    Objective-C

    - (instancetype _Nonnull)init;
  • Create a basic builder with a geometry array and a padding object.

    Declaration

    Objective-C

    + (TTCenterOnPointBuilder *_Nonnull)createWithCenter:
        (CLLocationCoordinate2D)center;

    Swift

    class func create(withCenter center: CLLocationCoordinate2D) -> TTCenterOnPointBuilder

    Parameters

    geometry

    An array of CLLocation objects, used to create bounding box.

    padding

    An UIEdgeInsets object, used to for padding.

    Return Value

    Reference to builder.

  • Add zoom for transform.

    Declaration

    Objective-C

    - (TTCenterOnPointBuilder *_Nonnull)withZoom:(double)zoom;

    Swift

    func withZoom(_ zoom: Double) -> TTCenterOnPointBuilder

    Parameters

    zoom

    Zoom of the map.

    Return Value

    Reference to builder.

  • Add bearing for transform.

    Declaration

    Objective-C

    - (TTCenterOnPointBuilder *_Nonnull)withBearing:(double)bearing;

    Swift

    func withBearing(_ bearing: Double) -> TTCenterOnPointBuilder

    Parameters

    bearing

    An angle of bearing in degrees.

    Return Value

    Reference to builder.

  • Add a padding object for insets.

    Declaration

    Objective-C

    - (TTCenterOnPointBuilder *_Nonnull)withPadding:(id)padding;

    Swift

    func withPadding(_ padding: Any!) -> TTCenterOnPointBuilder

    Parameters

    padding

    An UIEdgeInsets object, used for padding.

    Return Value

    Reference to builder.

  • Add pitch for transform.

    Declaration

    Objective-C

    - (TTCenterOnPointBuilder *_Nonnull)withPitch:(double)pitch;

    Swift

    func withPitch(_ pitch: Double) -> TTCenterOnPointBuilder

    Parameters

    pitch

    An angle of pitch in degrees.

    Return Value

    Reference to builder.

  • Build and get the TTCenterOnGeometry object.

    Declaration

    Objective-C

    - (TTCenterOnPoint *_Nonnull)build;

    Swift

    func build() -> TTCenterOnPoint

    Return Value

    TTCenterOnGeometry An object made with parameters that you provided to the builder.