DITUpdateResult
@interface DITUpdateResult : NSObject
Provides information about a successful update operation on a document.
The update result can be one of the following types:
set
removed
replacedWithCounter
incremented
pushed
popped
inserted
-
The update result’s type.
Check this value before using one of
asSet
,asRemoved
,asReplacedWithCounter
,asIncremented
,asPushed
, orasPopped
to ensure that you get the correct richer update result object.Declaration
Objective-C
@property (nonatomic, readonly) DITUpdateResultType type;
-
The ID of the document that was updated.
Declaration
Objective-C
@property (nonatomic, readonly) DITDocumentID *_Nonnull docID;
-
The path to the key in the document that was updated.
Declaration
Objective-C
@property (nonatomic, readonly) NSString *_Nonnull path;
-
Return the update result object as a
DITUpdateResultSet
object.Declaration
Objective-C
- (nullable DITUpdateResultSet *)asSet;
Return Value
A
DITUpdateResultSet
object ornil
if the update result’s type is notset
. -
Return the update result object as a
DITUpdateResultRemoved
object.Declaration
Objective-C
- (nullable DITUpdateResultRemoved *)asRemoved;
Return Value
A
DITUpdateResultRemoved
object ornil
if the update result’s type is notremoved
. -
Return the update result object as a
DITUpdateResultReplacedWithCounter
object.Declaration
Objective-C
- (nullable DITUpdateResultReplacedWithCounter *)asReplacedWithCounter;
Return Value
A
DITUpdateResultReplacedWithCounter
object ornil
if the update result’s type is notreplacedWithCounter
. -
Return the update result object as a
DITUpdateResultIncremented
object.Declaration
Objective-C
- (nullable DITUpdateResultIncremented *)asIncremented;
Return Value
A
DITUpdateResultIncremented
object ornil
if the update result’s type is notincremented
. -
Return the update result object as a
DITUpdateResultPushed
object.Declaration
Objective-C
- (nullable DITUpdateResultPushed *)asPushed;
Return Value
A
DITUpdateResultPushed
object ornil
if the update result’s type is notpushed
. -
Return the update result object as a
DITUpdateResultPopped
object.Declaration
Objective-C
- (nullable DITUpdateResultPopped *)asPopped;
Return Value
A
DITUpdateResultPopped
object ornil
if the update result’s type is notpopped
. -
Return the update result object as a
DITUpdateResultInserted
object.Declaration
Objective-C
- (nullable DITUpdateResultInserted *)asInserted;
Return Value
A
DITUpdateResultInserted
object ornil
if the update result’s type is notinserted
.