Returns an object in the pasteboard for the given representation type.
- iOS 3.0+
- Mac Catalyst 13.0+
A string identifying a representation type of a pasteboard item.
An object that is an instance of the appropriate class based on
pasteboard or an
NSData object containing “raw” data.
This method attempts to return an object that is of a class type appropriate to the representation type, which typically is a UTI. For example, if the representation type is
public), the method returns an
NSString object. If the method can’t determine the class type from the representation type, it returns the object as a generic object, such as an
NSData object. This method works on the first item in the pasteboard. If there are other items, it ignores them.