AVRelation Class Reference

Inherits from NSObject
Declared in AVRelation.h

Overview

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

  targetClass

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

– query

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

- (AVQuery *)query

Return Value

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

Declared In

AVRelation.h

– addObject:

Adds a relation to the passed in object.

- (void)addObject:(AVObject *)object

Parameters

object

AVObject to add relation to.

Discussion

Adds a relation to the passed in object.

Declared In

AVRelation.h

– removeObject:

Removes a relation to the passed in object.

- (void)removeObject:(AVObject *)object

Parameters

object

AVObject to add relation to.

Discussion

Removes a relation to the passed in object.

Declared In

AVRelation.h

+ reverseQuery:relationKey:childObject:

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

+ (AVQuery *)reverseQuery:(NSString *)parentClassName relationKey:(NSString *)relationKey childObject:(AVObject *)child

Parameters

parentClassName

parent Class Name

relationKey

relation Key

child

child object

Return Value

the Query

Discussion

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

Declared In

AVRelation.h