Instance Method


Returns whether the specified pasteboard items contain data of the given representation types.


- (BOOL)containsPasteboardTypes:(NSArray<NSString *> *)pasteboardTypes inItemSet:(NSIndexSet *)itemSet;



An array of strings, with each string identifying a representation type. Typically you use UTIs as pasteboard types.


An index set with each integer value identifying a pasteboard item positionally in the pasteboard. Pass in nil to request all pasteboard items.

Return Value

YES if the pasteboard items identified by itemSet have data corresponding to the representation types specified by pasteboardTypes; otherwise, returns NO.

See Also

Determining the Types of Multiple Pasteboard Items


Returns the number of items in the pasteboard

- pasteboardTypesForItemSet:

Returns an array of representation types for each specified pasteboard item.

- itemSetWithPasteboardTypes:

Returns an index set identifying pasteboard items having the specified representation types.