Instance Method

updateChangeCountWithToken:forSaveOperation:

Updates the document's change count settings after a successful save operation.

Declaration

- (void)updateChangeCountWithToken:(id)changeCountToken forSaveOperation:(NSSaveOperationType)saveOperation;

Parameters

changeCountToken

An object encapsulating the document changes, returned from changeCountTokenForSaveOperation:.

saveOperation

The type of save operation.

Discussion

This method updates the values in the documentEdited and hasUnautosavedChanges properties. For example, saveToURL:ofType:forSaveOperation:completionHandler: invokes this method, on the main thread, when it is done saving. The default implementation of this method also sends all of the document’s window controllers setDocumentEdited: messages when appropriate.

See Also

Updating the Document Change Count

- updateChangeCount:

Updates the receiver’s change count according to the given change type.

NSDocumentChangeType

Values that indicate a document’s edit status.

- changeCountTokenForSaveOperation:

Returns an object that encapsulates the current record of document changes at the beginning of a save operation.