RLMProperty

@interface RLMProperty : NSObject

RLMProperty instances represent properties managed by a Realm in the context of an object schema. Such properties may be persisted to a Realm file or computed from other data from the Realm.

When using Realm, RLMProperty instances allow performing migrations and introspecting the database’s schema.

These property instances map to columns in the core database.

  • The name of the property.

    Declaration

    Objective-C

    @property (readonly, nonatomic) NSString *_Nonnull name;
  • The type of the property.

    Declaration

    Objective-C

    @property (readonly, nonatomic) RLMPropertyType type;
  • Indicates whether this property is indexed.

    See

    RLMObject

    Declaration

    Objective-C

    @property (readonly, nonatomic) BOOL indexed;
  • For RLMObject and RLMArray properties, the name of the class of object stored in the property.

    Declaration

    Objective-C

    @property (readonly, copy, nonatomic, nullable) NSString *objectClassName;
  • For linking objects properties, the property name of the property the linking objects property is linked to.

    Declaration

    Objective-C

    @property (readonly, copy, nonatomic, nullable) NSString *linkOriginPropertyName;
  • Indicates whether this property is optional.

    Declaration

    Objective-C

    @property (readonly, nonatomic) BOOL optional;
  • Indicates whether this property is an array.

    Declaration

    Objective-C

    @property (readonly, nonatomic) BOOL array;
  • Returns whether a given property object is equal to the receiver.

    Declaration

    Objective-C

    - (BOOL)isEqualToProperty:(nonnull RLMProperty *)property;