Contents

NSFilePromiseProvider

An object that provides a promise for the pasteboard.

Declaration

class NSFilePromiseProvider

Overview

A file promise is a possible future file of a specified type. When you’re working with drag and drop, use promises to indicate intent for future action. Avoid loading or performing any actions on the file until the promise completes.

Use the NSFilePromiseProvider class when creating file promises. Instantiate one NSFilePromiseProvider for each file promised. Set the fileType and delegate properties before writing any NSFilePromiseProvider to the pasteboard. The file type must be a Uniform Type Identifier (UTI) that ultimately conforms to kUTTypeData or kUTTypeDirectory. The NSFilePromiseProviderDelegate will write the promised file to the destination directory.

Optionally, you may attach a userInfo object of your choosing to the NSFilePromiseProvider to determine which promise is being referenced when promising multiple files under the same NSFilePromiseProviderDelegate instance.

Topics

Initializers

Instance Properties

See Also

File Promises