LuxChat  2.0
Instant messenger for iOS
Instance Methods | Class Methods | List of all members
PFObject(Synchronous) Category Reference

#import <PFObject+Synchronous.h>

Instance Methods

(BOOL) - PF_SWIFT_UNAVAILABLE
 
More...
 
(BOOL) - save:
 
(nullable instancetype) - PF_SWIFT_UNAVAILABLE
 
More...
 
(nullable instancetype) - fetch:
 
(nullable instancetype) - PF_SWIFT_UNAVAILABLE
 
(nullable instancetype) - fetchIfNeeded:
 
(nullable instancetype) - PF_SWIFT_UNAVAILABLE
 
More...
 
(nullable instancetype) - fetchFromLocalDatastore:
 
(BOOL) - PF_SWIFT_UNAVAILABLE
 
More...
 
(BOOL) - delete:
 
(BOOL) - PF_SWIFT_UNAVAILABLE
 
More...
 
(BOOL) - pin:
 
(BOOL) - pinWithName:
 
(BOOL) - pinWithName:error:
 
(BOOL) - PF_SWIFT_UNAVAILABLE
 
More...
 
(BOOL) - unpin:
 
(BOOL) - unpinWithName:
 
(BOOL) - unpinWithName:error:
 

Class Methods

(BOOL) + saveAll:
 
More...
 
(BOOL) + saveAll:error:
 
(nullable NSArray< __kindof PFObject * > *) + fetchAll:
 
More...
 
(nullable NSArray< __kindof PFObject * > *) + fetchAll:error:
 
(nullable NSArray< __kindof PFObject * > *) + fetchAllIfNeeded:
 
(nullable NSArray< __kindof PFObject * > *) + fetchAllIfNeeded:error:
 
(BOOL) + deleteAll:
 
More...
 
(BOOL) + deleteAll:error:
 
(BOOL) + pinAll:
 
More...
 
(BOOL) + pinAll:error:
 
(BOOL) + pinAll:withName:
 
(BOOL) + pinAll:withName:error:
 
(BOOL) + PF_SWIFT_UNAVAILABLE
 
More...
 
(BOOL) + unpinAllObjects:
 
(BOOL) + unpinAllObjectsWithName:
 
(BOOL) + unpinAllObjectsWithName:error:
 
(BOOL) + unpinAll:
 
(BOOL) + unpinAll:error:
 
(BOOL) + unpinAll:withName:
 
(BOOL) + unpinAll:withName:error:
 

Detailed Description

Copyright (c) 2015-present, Parse, LLC. All rights reserved.

This source code is licensed under the BSD-style license found in the LICENSE file in the root directory of this source tree. An additional grant of patent rights can be found in the PATENTS file in the same directory. This category lists all methods of PFObject class that are synchronous, but have asynchronous counterpart, Calling one of these synchronous methods could potentially block the current thread for a large amount of time, since it might be fetching from network or saving/loading data from disk.

Method Documentation

- (BOOL) delete: (NSError **)  error

Synchronously* deletes the PFObject and sets an error if it occurs.

Parameters
errorPointer to an NSError that will be set if necessary.
Returns
Returns whether the delete succeeded.

Extends class PFObject.

+ (BOOL) deleteAll: (nullable NSArray< PFObject * > *)  PF_SWIFT_UNAVAILABLE



Synchronously* deletes a collection of objects all at once.

Parameters
objectsThe array of objects to delete.
Returns
Returns whether the delete succeeded.

Extends class PFObject.

+ (BOOL) deleteAll: (nullable NSArray< PFObject * > *)  objects
error: (NSError **)  error 

Synchronously* deletes a collection of objects all at once and sets an error if necessary.

Parameters
objectsThe array of objects to delete.
errorPointer to an NSError that will be set if necessary.
Returns
Returns whether the delete succeeded.

Extends class PFObject.

- (nullable instancetype) fetch: (NSError **)  error

Synchronously* fetches the PFObject with the current data from the server and sets an error if it occurs.

Parameters
errorPointer to an NSError that will be set if necessary.

Extends class PFObject.

+ (nullable NSArray<__kindof PFObject *> *) fetchAll: (nullable NSArray< PFObject * > *)  PF_SWIFT_UNAVAILABLE



Synchronously* fetches all of the PFObject objects with the current data from the server.

Parameters
objectsThe list of objects to fetch.

Extends class PFObject.

+ (nullable NSArray<__kindof PFObject *> *) fetchAll: (nullable NSArray< PFObject * > *)  objects
error: (NSError **)  error 

Synchronously* fetches all of the PFObject objects with the current data from the server and sets an error if it occurs.

Parameters
objectsThe list of objects to fetch.
errorPointer to an NSError that will be set if necessary.

Extends class PFObject.

+ (nullable NSArray<__kindof PFObject *> *) fetchAllIfNeeded: (nullable NSArray< PFObject * > *)  PF_SWIFT_UNAVAILABLE

Synchronously* fetches all of the PFObject objects with the current data from the server.

Parameters
objectsThe list of objects to fetch.

Extends class PFObject.

+ (nullable NSArray<__kindof PFObject *> *) fetchAllIfNeeded: (nullable NSArray< PFObject * > *)  objects
error: (NSError **)  error 

Synchronously* fetches all of the PFObject objects with the current data from the server and sets an error if it occurs.

Parameters
objectsThe list of objects to fetch.
errorPointer to an NSError that will be set if necessary.

Extends class PFObject.

- (nullable instancetype) fetchFromLocalDatastore: (NSError **)  error

Synchronously* loads data from the local datastore into this object, if it has not been fetched from the server already.

If the object is not stored in the local datastore, this error will be set to return kPFErrorCacheMiss.

Parameters
errorPointer to an NSError that will be set if necessary.

Extends class PFObject.

- (nullable instancetype) fetchIfNeeded: (NSError **)  error

Synchronously* fetches the PFObject data from the server if dataAvailable is NO.

Parameters
errorPointer to an NSError that will be set if necessary.

Extends class PFObject.

- (nullable instancetype) PF_SWIFT_UNAVAILABLE



Synchronously* fetches the PFObject with the current data from the server.

Extends class PFObject.

- (BOOL) PF_SWIFT_UNAVAILABLE



Synchronously* stores the object and every object it points to in the local datastore, recursively, using a default pin name: PFObjectDefaultPin.

If those other objects have not been fetched from Parse, they will not be stored. However, if they have changed data, all the changes will be retained. To get the objects back later, you can use a PFQuery that uses PFQuery.-fromLocalDatastore, or you can create an unfetched pointer with +objectWithoutDataWithClassName:objectId: and then call -fetchFromLocalDatastore on it.

Returns
Returns whether the pin succeeded.
See also
-unpin:
PFObjectDefaultPin

Extends class PFObject.

- (BOOL) PF_SWIFT_UNAVAILABLE



Synchronously* removes the object and every object it points to in the local datastore, recursively, using a default pin name: PFObjectDefaultPin.

Returns
Returns whether the unpin succeeded.
See also
pin:
PFObjectDefaultPin

Extends class PFObject.

+ (BOOL) PF_SWIFT_UNAVAILABLE



Synchronously* removes all objects in the local datastore using a default pin name: PFObjectDefaultPin.

Returns
Returns whether the unpin succeeded.
See also
PFObjectDefaultPin

Extends class PFObject.

- (BOOL) PF_SWIFT_UNAVAILABLE



Synchronously* saves the PFObject.

Returns
Returns whether the save succeeded.

Extends class PFObject.

- (nullable instancetype) PF_SWIFT_UNAVAILABLE



Synchronously* loads data from the local datastore into this object, if it has not been fetched from the server already.

Extends class PFObject.

- (nullable instancetype) PF_SWIFT_UNAVAILABLE

Synchronously* fetches the PFObject data from the server if dataAvailable is NO.

Extends class PFObject.

- (BOOL) PF_SWIFT_UNAVAILABLE



Synchronously* deletes the PFObject.

Returns
Returns whether the delete succeeded.

Extends class PFObject.

- (BOOL) pin: (NSError **)  error

Synchronously* stores the object and every object it points to in the local datastore, recursively, using a default pin name: PFObjectDefaultPin.

If those other objects have not been fetched from Parse, they will not be stored. However, if they have changed data, all the changes will be retained. To get the objects back later, you can use a PFQuery that uses PFQuery.-fromLocalDatastore, or you can create an unfetched pointer with +objectWithoutDataWithClassName:objectId: and then call -fetchFromLocalDatastore on it.

Parameters
errorPointer to an NSError that will be set if necessary.
Returns
Returns whether the pin succeeded.
See also
-unpin:
PFObjectDefaultPin

Extends class PFObject.

+ (BOOL) pinAll: (nullable NSArray< PFObject * > *)  PF_SWIFT_UNAVAILABLE



Synchronously* stores the objects and every object they point to in the local datastore, recursively, using a default pin name: PFObjectDefaultPin.

If those other objects have not been fetched from Parse, they will not be stored. However, if they have changed data, all the changes will be retained. To get the objects back later, you can use a PFQuery that uses PFQuery.-fromLocalDatastore, or you can create an unfetched pointer with +objectWithoutDataWithClassName:objectId: and then call fetchFromLocalDatastore: on it.

Parameters
objectsThe objects to be pinned.
Returns
Returns whether the pin succeeded.
See also
unpinAll:
PFObjectDefaultPin

Extends class PFObject.

+ (BOOL) pinAll: (nullable NSArray< PFObject * > *)  objects
error: (NSError **)  error 

Synchronously* stores the objects and every object they point to in the local datastore, recursively, using a default pin name: PFObjectDefaultPin.

If those other objects have not been fetched from Parse, they will not be stored. However, if they have changed data, all the changes will be retained. To get the objects back later, you can use a PFQuery that uses PFQuery.-fromLocalDatastore, or you can create an unfetched pointer with +objectWithoutDataWithClassName:objectId: and then call fetchFromLocalDatastore: on it.

Parameters
objectsThe objects to be pinned.
errorPointer to an NSError that will be set if necessary.
Returns
Returns whether the pin succeeded.
See also
unpinAll:error:
PFObjectDefaultPin

Extends class PFObject.

+ (BOOL) pinAll: (nullable NSArray< PFObject * > *)  objects
withName: (NSString *)  PF_SWIFT_UNAVAILABLE 

Synchronously* stores the objects and every object they point to in the local datastore, recursively.

If those other objects have not been fetched from Parse, they will not be stored. However, if they have changed data, all the changes will be retained. To get the objects back later, you can use a PFQuery that uses PFQuery.-fromLocalDatastore, or you can create an unfetched pointer with +objectWithoutDataWithClassName:objectId: and then call fetchFromLocalDatastore: on it.

Parameters
objectsThe objects to be pinned.
nameThe name of the pin.
Returns
Returns whether the pin succeeded.
See also
unpinAll:withName:

Extends class PFObject.

+ (BOOL) pinAll: (nullable NSArray< PFObject * > *)  objects
withName: (NSString *)  name
error: (NSError **)  error 

Synchronously* stores the objects and every object they point to in the local datastore, recursively.

If those other objects have not been fetched from Parse, they will not be stored. However, if they have changed data, all the changes will be retained. To get the objects back later, you can use a PFQuery that uses PFQuery.-fromLocalDatastore, or you can create an unfetched pointer with +objectWithoutDataWithClassName:objectId: and then call fetchFromLocalDatastore: on it.

Parameters
objectsThe objects to be pinned.
nameThe name of the pin.
errorPointer to an NSError that will be set if necessary.
Returns
Returns whether the pin succeeded.
See also
unpinAll:withName:error:

Extends class PFObject.

- (BOOL) pinWithName: (NSString *)  PF_SWIFT_UNAVAILABLE

Synchronously* stores the object and every object it points to in the local datastore, recursively.

If those other objects have not been fetched from Parse, they will not be stored. However, if they have changed data, all the changes will be retained. To get the objects back later, you can use a PFQuery that uses PFQuery.-fromLocalDatastore, or you can create an unfetched pointer with +objectWithoutDataWithClassName:objectId: and then call -fetchFromLocalDatastore on it.

Parameters
nameThe name of the pin.
Returns
Returns whether the pin succeeded.
See also
-unpinWithName:

Extends class PFObject.

- (BOOL) pinWithName: (NSString *)  name
error: (NSError **)  error 

Synchronously* stores the object and every object it points to in the local datastore, recursively.

If those other objects have not been fetched from Parse, they will not be stored. However, if they have changed data, all the changes will be retained. To get the objects back later, you can use a PFQuery that uses PFQuery.-fromLocalDatastore, or you can create an unfetched pointer with +objectWithoutDataWithClassName:objectId: and then call -fetchFromLocalDatastore on it.

Parameters
nameThe name of the pin.
errorPointer to an NSError that will be set if necessary.
Returns
Returns whether the pin succeeded.
See also
-unpinWithName:

Extends class PFObject.

- (BOOL) save: (NSError **)  error

Synchronously* saves the PFObject and sets an error if it occurs.

Parameters
errorPointer to an NSError that will be set if necessary.
Returns
Returns whether the save succeeded.

Extends class PFObject.

+ (BOOL) saveAll: (nullable NSArray< PFObject * > *)  PF_SWIFT_UNAVAILABLE



Saves a collection of objects *synchronously all at once.

Parameters
objectsThe array of objects to save.
Returns
Returns whether the save succeeded.

Extends class PFObject.

+ (BOOL) saveAll: (nullable NSArray< PFObject * > *)  objects
error: (NSError **)  error 

Saves a collection of objects synchronously all at once and sets an error if necessary.

Parameters
objectsThe array of objects to save.
errorPointer to an NSError that will be set if necessary.
Returns
Returns whether the save succeeded.

Extends class PFObject.

- (BOOL) unpin: (NSError **)  error

Synchronously* removes the object and every object it points to in the local datastore, recursively, using a default pin name: PFObjectDefaultPin.

Parameters
errorPointer to an NSError that will be set if necessary.
Returns
Returns whether the unpin succeeded.
See also
pin:
PFObjectDefaultPin

Extends class PFObject.

+ (BOOL) unpinAll: (nullable NSArray< PFObject * > *)  PF_SWIFT_UNAVAILABLE

Synchronously* removes the objects and every object they point to in the local datastore, recursively, using a default pin name: PFObjectDefaultPin.

Parameters
objectsThe objects.
Returns
Returns whether the unpin succeeded.
See also
pinAll:
PFObjectDefaultPin

Extends class PFObject.

+ (BOOL) unpinAll: (nullable NSArray< PFObject * > *)  objects
error: (NSError **)  error 

Synchronously* removes the objects and every object they point to in the local datastore, recursively, using a default pin name: PFObjectDefaultPin.

Parameters
objectsThe objects.
errorPointer to an NSError that will be set if necessary.
Returns
Returns whether the unpin succeeded.
See also
pinAll:error:
PFObjectDefaultPin

Extends class PFObject.

+ (BOOL) unpinAll: (nullable NSArray< PFObject * > *)  objects
withName: (NSString *)  PF_SWIFT_UNAVAILABLE 

Synchronously* removes the objects and every object they point to in the local datastore, recursively.

Parameters
objectsThe objects.
nameThe name of the pin.
Returns
Returns whether the unpin succeeded.
See also
pinAll:withName:

Extends class PFObject.

+ (BOOL) unpinAll: (nullable NSArray< PFObject * > *)  objects
withName: (NSString *)  name
error: (NSError **)  error 

Synchronously* removes the objects and every object they point to in the local datastore, recursively.

Parameters
objectsThe objects.
nameThe name of the pin.
errorPointer to an NSError that will be set if necessary.
Returns
Returns whether the unpin succeeded.
See also
pinAll:withName:error:

Extends class PFObject.

+ (BOOL) unpinAllObjects: (NSError **)  error

Synchronously* removes all objects in the local datastore using a default pin name: PFObjectDefaultPin.

Parameters
errorPointer to an NSError that will be set if necessary.
Returns
Returns whether the unpin succeeded.
See also
PFObjectDefaultPin

Extends class PFObject.

+ (BOOL) unpinAllObjectsWithName: (NSString *)  PF_SWIFT_UNAVAILABLE

Synchronously* removes all objects with the specified pin name.

Parameters
nameThe name of the pin.
Returns
Returns whether the unpin succeeded.

Extends class PFObject.

+ (BOOL) unpinAllObjectsWithName: (NSString *)  name
error: (NSError **)  error 

Synchronously* removes all objects with the specified pin name.

Parameters
nameThe name of the pin.
errorPointer to an NSError that will be set if necessary.
Returns
Returns whether the unpin succeeded.

Extends class PFObject.

- (BOOL) unpinWithName: (NSString *)  PF_SWIFT_UNAVAILABLE

Synchronously* removes the object and every object it points to in the local datastore, recursively.

Parameters
nameThe name of the pin.
Returns
Returns whether the unpin succeeded.
See also
pinWithName:

Extends class PFObject.

- (BOOL) unpinWithName: (NSString *)  name
error: (NSError **)  error 

Synchronously* removes the object and every object it points to in the local datastore, recursively.

Parameters
nameThe name of the pin.
errorPointer to an NSError that will be set if necessary.
Returns
Returns whether the unpin succeeded.
See also
pinWithName:error:

Extends class PFObject.


The documentation for this category was generated from the following file: