Creates and returns a new pasteboard with a unique name that supplies the specified data in as many types as possible given the available filter services.
SDK
- macOS 10.0+
Framework
- App
Kit
Declaration
+ (NSPasteboard *)pasteboardByFilteringData:(NSData *)data ofType:(NSPasteboard Type)type;
Parameters
data
The data to be placed on the pasteboard.
type
The type of data in the
data
parameter.
Return Value
The new pasteboard object.
Discussion
The returned pasteboard also declares data of the supplied type
.
No filter service is invoked until the data is actually requested, so invoking this method is reasonably inexpensive.