MLRelation Class Reference

Inherits from NSObject
Conforms to NSSecureCoding
Declared in MLRelation.h

Overview

A class that is used to access all of the children of a many-to-many relationship. Each instance of MLRelation is associated with a particular parent object and key.

Other Methods

  targetClass

The name of the class of the target child objects.

@property (nonatomic, strong, nullable) NSString *targetClass

Declared In

MLRelation.h

Accessing Objects

– query

A MLQuery that can be used to get objects in this relation.

- (nullable MLQuery *)query

Return Value

A MLQuery that can be used to get objects in this relation.

Declared In

MLRelation.h

Modifying Relations

– addObject:

Adds a relation to the passed in object.

- (void)addObject:(MLObject *)object

Parameters

object

MLObject to add relation to.

Declared In

MLRelation.h

– removeObject:

Removes a relation to the passed in object.

- (void)removeObject:(MLObject *)object

Parameters

object

MLObject to add relation to.

Declared In

MLRelation.h