PTAnnotationOptions


@interface PTAnnotationOptions : NSObject <NSCopying, NSCoding>

An object that contains options for a type of annotation.

  • Creates and returns an annotation options instance with the default values.

    Declaration

    Objective-C

    + (nonnull instancetype)options;

    Return Value

    An annotation options instance with the default values.

  • Returns an initialized PTAnnotationOptions with the specified values.

    Declaration

    Objective-C

    - (nonnull instancetype)initWithCanCreate:(BOOL)canCreate canEdit:(BOOL)canEdit;

    Swift

    init(canCreate: Bool, canEdit: Bool)

    Parameters

    canCreate

    YES if the annotation type can be created, NO otherwise.

    canEdit

    YES if the annotation type can be edited, NO otherwise.

    Return Value

    An initialized PTAnnotationOptions with the specified values.

  • Whether the annotation type can be created. The default value is YES.

    Declaration

    Objective-C

    @property (nonatomic) BOOL canCreate;

    Swift

    var canCreate: Bool { get set }
  • Whether the annotation type can be edited. The default value is YES.

    Declaration

    Objective-C

    @property (nonatomic) BOOL canEdit;

    Swift

    var canEdit: Bool { get set }
  • Compares the receiving annotation options instance to another instance.

    Declaration

    Objective-C

    - (BOOL)isEqualToAnnotationOptions:
        (nonnull PTAnnotationOptions *)annotationOptions;

    Swift

    func isEqual(to annotationOptions: PTAnnotationOptions) -> Bool

    Parameters

    annotationOptions

    an other annotation options instance

    Return Value

    YES if the annotation options instance is equal to the receiving instance, otherwise NO

  • Undocumented

    Declaration

    Objective-C

    - (instancetype)initWithCoder:(NSCoder *)coder NS_DESIGNATED_INITIALIZER;

    Swift

    init(coder: NSCoder)