Enumeration

NSSaveOperationType

Constants for specifying the type of document-save operation to perform.

Declaration

typedef enum NSSaveOperationType : NSUInteger {
    ...
} NSSaveOperationType;

Overview

These values are used with method parameters of type NSSaveOperationType. Depending on the method, the save operation type can affect the title of the Save dialog and can affect which files are displayed in the dialog.

Topics

Constants

NSSaveOperation

An operation that overwrites a document’s file or file package with the document’s contents.

NSSaveAsOperation

An operation that writes the document’s contents to a new location and updates the document to point to that location

NSSaveToOperation

An operation that writes a copy of the document's contents to the specified location, without changing the original document’s location.

NSAutosaveElsewhereOperation

An operation that writes an autosave version of the file to a different location.

NSAutosaveInPlaceOperation

An operation that overwrites the document’s current contents with autosave data.

NSAutosaveAsOperation

An operation that writes a document’s contents to a new file or file package even though the user has not explicitly requested it, then changes the document’s current location to point to the just-written file or file package.

NSAutosaveOperation

Old name for the NSAutosaveElsewhereOperation operation type.

Deprecated

See Also

Writing the Document's Content

- canAsynchronouslyWriteToURL:ofType:forSaveOperation:

Returns whether the receiver can concurrently write to a file or file package located by a URL, that is formatted for a specific type, for a specific kind of save operation.

- unblockUserInteraction

Unblocks the main thread during asynchronous saving.

- writeToURL:ofType:error:

Writes the contents of the document to a file or file package located by a URL, that is formatted to a specified type.

- writeSafelyToURL:ofType:forSaveOperation:error:

Writes the contents of the document to a file or file package located by a URL.

- fileWrapperOfType:error:

Creates and returns a file wrapper that contains the contents of the document, formatted to the specified type.

- dataOfType:error:

Creates and returns a data object that contains the contents of the document, formatted to a specified type.

- writeToURL:ofType:forSaveOperation:originalContentsURL:error:

Writes the contents of the document to a file or file package located by a URL.

- saveToURL:ofType:forSaveOperation:delegate:didSaveSelector:contextInfo:

Saves the contents of the document to a file or file package located by a URL, that is formatted to a specified type, for a particular kind of save operation.

- saveToURL:ofType:forSaveOperation:completionHandler:

Saves the contents of the document to a file or file package located by a URL, that is formatted to a specified type, for a particular kind of save operation, and invokes the passed-in completion handler.

- fileAttributesToWriteToURL:ofType:forSaveOperation:originalContentsURL:error:

Returns the attributes to write to the file or file package at the specified URL, and targeting the specified type of save operation.