Package apple.foundation
Class NSItemProvider
- java.lang.Object
-
- org.moe.natj.general.NativeObject
-
- org.moe.natj.objc.ObjCObject
-
- apple.NSObject
-
- apple.foundation.NSItemProvider
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class apple.NSObject
NSObject.Function_instanceMethodForSelector_ret, NSObject.Function_methodForSelector_ret
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedNSItemProvider(org.moe.natj.general.Pointer peer)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static booleanaccessInstanceVariablesDirectly()static NSItemProvideralloc()static java.lang.ObjectallocWithZone(org.moe.natj.general.ptr.VoidPtr zone)static booleanautomaticallyNotifiesObserversForKey(java.lang.String key)static voidcancelPreviousPerformRequestsWithTarget(java.lang.Object aTarget)static voidcancelPreviousPerformRequestsWithTargetSelectorObject(java.lang.Object aTarget, org.moe.natj.objc.SEL aSelector, java.lang.Object anArgument)booleancanLoadObjectOfClass(NSItemProviderReading aClass)static NSArray<java.lang.String>classFallbacksForKeyedArchiver()static org.moe.natj.objc.ClassclassForKeyedUnarchiver()java.lang.ObjectcopyWithZone(org.moe.natj.general.ptr.VoidPtr zone)static java.lang.StringdebugDescription_static()static java.lang.Stringdescription_static()static longhash_static()booleanhasItemConformingToTypeIdentifier(java.lang.String typeIdentifier)Returns YES if the item provider has at least one item that conforms to the supplied type identifier.booleanhasRepresentationConformingToTypeIdentifierFileOptions(java.lang.String typeIdentifier, long fileOptions)NSItemProviderinit()NSItemProviderinitWithContentsOfURL(NSURL fileURL)Initialize an NSItemProvider with load handlers for the given file URL, and the file content.NSItemProviderinitWithItemTypeIdentifier(NSSecureCoding item, java.lang.String typeIdentifier)Initialize an NSItemProvider with an object assigned to a single UTI.NSItemProviderinitWithObject(NSItemProviderWriting object)Instantiate an NSItemProvider by querying an object for its eligible type identifiers via the NSItemProviderWriting protocol.static NSObject.Function_instanceMethodForSelector_retinstanceMethodForSelector(org.moe.natj.objc.SEL aSelector)static NSMethodSignatureinstanceMethodSignatureForSelector(org.moe.natj.objc.SEL aSelector)static booleaninstancesRespondToSelector(org.moe.natj.objc.SEL aSelector)static booleanisSubclassOfClass(org.moe.natj.objc.Class aClass)static NSSet<java.lang.String>keyPathsForValuesAffectingValueForKey(java.lang.String key)NSProgressloadDataRepresentationForTypeIdentifierCompletionHandler(java.lang.String typeIdentifier, NSItemProvider.Block_loadDataRepresentationForTypeIdentifierCompletionHandler completionHandler)Copies the provided data into an NSData object.NSProgressloadFileRepresentationForTypeIdentifierCompletionHandler(java.lang.String typeIdentifier, NSItemProvider.Block_loadFileRepresentationForTypeIdentifierCompletionHandler completionHandler)Writes a copy of the data to a temporary file.NSProgressloadInPlaceFileRepresentationForTypeIdentifierCompletionHandler(java.lang.String typeIdentifier, NSItemProvider.Block_loadInPlaceFileRepresentationForTypeIdentifierCompletionHandler completionHandler)Open the original file in place, if possible.voidloadItemForTypeIdentifierOptionsCompletionHandler(java.lang.String typeIdentifier, NSDictionary<?,?> options, NSItemProvider.Block_loadItemForTypeIdentifierOptionsCompletionHandler completionHandler)Loads the best matching item for a type identifier.NSProgressloadObjectOfClassCompletionHandler(NSItemProviderReading aClass, NSItemProvider.Block_loadObjectOfClassCompletionHandler completionHandler)Instantiate an object using the NSItemProviderReading protocol.voidloadPreviewImageWithOptionsCompletionHandler(NSDictionary<?,?> options, NSItemProvider.Block_loadPreviewImageWithOptionsCompletionHandler completionHandler)Loads the preview image for this item by either calling the supplied preview block or falling back to a QuickLook-based handler.static java.lang.Objectnew_objc()CGSizepreferredPresentationSize()Estimated presentation size, in points.longpreferredPresentationStyle()NSItemProvider.Block_previewImageHandler_retpreviewImageHandler()Sets a custom preview image handler block for this item provider.voidregisterDataRepresentationForTypeIdentifierVisibilityLoadHandler(java.lang.String typeIdentifier, long visibility, NSItemProvider.Block_registerDataRepresentationForTypeIdentifierVisibilityLoadHandler loadHandler)Registers a data-backed representation.NSArray<java.lang.String>registeredTypeIdentifiers()Returns the list of registered type identifiers, in the order they were registered.NSArray<java.lang.String>registeredTypeIdentifiersWithFileOptions(long fileOptions)voidregisterFileRepresentationForTypeIdentifierFileOptionsVisibilityLoadHandler(java.lang.String typeIdentifier, long fileOptions, long visibility, NSItemProvider.Block_registerFileRepresentationForTypeIdentifierFileOptionsVisibilityLoadHandler loadHandler)Registers a file-backed representation.voidregisterItemForTypeIdentifierLoadHandler(java.lang.String typeIdentifier, NSItemProvider.Block_registerItemForTypeIdentifierLoadHandler loadHandler)Registers a load handler that returns an object, assigned to a single UTI.voidregisterObjectOfClassVisibilityLoadHandler(NSItemProviderWriting aClass, long visibility, NSItemProvider.Block_registerObjectOfClassVisibilityLoadHandler loadHandler)Add representations from a class, but defer loading the object until needed.voidregisterObjectVisibility(NSItemProviderWriting object, long visibility)Add representations from an object using the NSItemProviderWriting protocol.static booleanresolveClassMethod(org.moe.natj.objc.SEL sel)static booleanresolveInstanceMethod(org.moe.natj.objc.SEL sel)voidsetPreferredPresentationSize(CGSize value)Estimated presentation size, in points.voidsetPreferredPresentationStyle(long value)voidsetPreviewImageHandler(NSItemProvider.Block_setPreviewImageHandler value)Sets a custom preview image handler block for this item provider.voidsetSuggestedName(java.lang.String value)voidsetTeamData(NSData value)static voidsetVersion_static(long aVersion)java.lang.StringsuggestedName()static org.moe.natj.objc.Classsuperclass_static()NSDatateamData()static longversion_static()-
Methods inherited from class apple.NSObject
accessibilityActivate, accessibilityActivationPoint, accessibilityAssistiveTechnologyFocusedIdentifiers, accessibilityAttributedHint, accessibilityAttributedLabel, accessibilityAttributedUserInputLabels, accessibilityAttributedValue, accessibilityContainerType, accessibilityCustomActions, accessibilityCustomRotors, accessibilityDecrement, accessibilityDragSourceDescriptors, accessibilityDropPointDescriptors, accessibilityElementAtIndex, accessibilityElementCount, accessibilityElementDidBecomeFocused, accessibilityElementDidLoseFocus, accessibilityElementIsFocused, accessibilityElements, accessibilityElementsHidden, accessibilityFrame, accessibilityHint, accessibilityIncrement, accessibilityLabel, accessibilityLanguage, accessibilityNavigationStyle, accessibilityPath, accessibilityPerformEscape, accessibilityPerformMagicTap, accessibilityRespondsToUserInteraction, accessibilityScroll, accessibilityTextualContext, accessibilityTraits, accessibilityUserInputLabels, accessibilityValue, accessibilityViewIsModal, addObserverForKeyPathOptionsContext, attemptRecoveryFromErrorOptionIndex, attemptRecoveryFromErrorOptionIndexDelegateDidRecoverSelectorContextInfo, autoContentAccessingProxy, awakeAfterUsingCoder, awakeFromNib, class_objc, classForCoder, classForKeyedArchiver, copy, dealloc, debugDescription, description, dictionaryWithValuesForKeys, didChangeValueForKey, didChangeValueForKeyWithSetMutationUsingObjects, didChangeValuesAtIndexesForKey, doesNotRecognizeSelector, fileManagerShouldProceedAfterError, fileManagerWillProcessPath, finalize_objc, forwardingTargetForSelector, forwardInvocation, hash, indexOfAccessibilityElement, isAccessibilityElement, isEqual, isKindOfClass, isMemberOfClass, isProxy, methodForSelector, methodSignatureForSelector, mutableArrayValueForKey, mutableArrayValueForKeyPath, mutableCopy, mutableOrderedSetValueForKey, mutableOrderedSetValueForKeyPath, mutableSetValueForKey, mutableSetValueForKeyPath, observationInfo, observeValueForKeyPathOfObjectChangeContext, performSelector, performSelectorInBackgroundWithObject, performSelectorOnMainThreadWithObjectWaitUntilDone, performSelectorOnMainThreadWithObjectWaitUntilDoneModes, performSelectorOnThreadWithObjectWaitUntilDone, performSelectorOnThreadWithObjectWaitUntilDoneModes, performSelectorWithObject, performSelectorWithObjectAfterDelay, performSelectorWithObjectAfterDelayInModes, performSelectorWithObjectWithObject, prepareForInterfaceBuilder, provideImageDataBytesPerRowOrigin_Size_UserInfo, removeObserverForKeyPath, removeObserverForKeyPathContext, replacementObjectForCoder, replacementObjectForKeyedArchiver, respondsToSelector, self, setAccessibilityActivationPoint, setAccessibilityAttributedHint, setAccessibilityAttributedLabel, setAccessibilityAttributedUserInputLabels, setAccessibilityAttributedValue, setAccessibilityContainerType, setAccessibilityCustomActions, setAccessibilityCustomRotors, setAccessibilityDragSourceDescriptors, setAccessibilityDropPointDescriptors, setAccessibilityElements, setAccessibilityElementsHidden, setAccessibilityFrame, setAccessibilityHint, setAccessibilityLabel, setAccessibilityLanguage, setAccessibilityNavigationStyle, setAccessibilityPath, setAccessibilityRespondsToUserInteraction, setAccessibilityTextualContext, setAccessibilityTraits, setAccessibilityUserInputLabels, setAccessibilityValue, setAccessibilityViewIsModal, setIsAccessibilityElement, setNilValueForKey, setObservationInfo, setShouldGroupAccessibilityChildren, setValueForKey, setValueForKeyPath, setValueForUndefinedKey, setValuesForKeysWithDictionary, shouldGroupAccessibilityChildren, superclass, validateValueForKeyError, validateValueForKeyPathError, valueForKey, valueForKeyPath, valueForUndefinedKey, willChangeValueForKey, willChangeValueForKeyWithSetMutationUsingObjects, willChangeValuesAtIndexesForKey
-
-
-
-
Method Detail
-
accessInstanceVariablesDirectly
public static boolean accessInstanceVariablesDirectly()
-
alloc
public static NSItemProvider alloc()
-
allocWithZone
public static java.lang.Object allocWithZone(org.moe.natj.general.ptr.VoidPtr zone)
-
automaticallyNotifiesObserversForKey
public static boolean automaticallyNotifiesObserversForKey(java.lang.String key)
-
cancelPreviousPerformRequestsWithTarget
public static void cancelPreviousPerformRequestsWithTarget(java.lang.Object aTarget)
-
cancelPreviousPerformRequestsWithTargetSelectorObject
public static void cancelPreviousPerformRequestsWithTargetSelectorObject(java.lang.Object aTarget, org.moe.natj.objc.SEL aSelector, java.lang.Object anArgument)
-
classFallbacksForKeyedArchiver
public static NSArray<java.lang.String> classFallbacksForKeyedArchiver()
-
classForKeyedUnarchiver
public static org.moe.natj.objc.Class classForKeyedUnarchiver()
-
debugDescription_static
public static java.lang.String debugDescription_static()
-
description_static
public static java.lang.String description_static()
-
hash_static
public static long hash_static()
-
instanceMethodForSelector
public static NSObject.Function_instanceMethodForSelector_ret instanceMethodForSelector(org.moe.natj.objc.SEL aSelector)
-
instanceMethodSignatureForSelector
public static NSMethodSignature instanceMethodSignatureForSelector(org.moe.natj.objc.SEL aSelector)
-
instancesRespondToSelector
public static boolean instancesRespondToSelector(org.moe.natj.objc.SEL aSelector)
-
isSubclassOfClass
public static boolean isSubclassOfClass(org.moe.natj.objc.Class aClass)
-
keyPathsForValuesAffectingValueForKey
public static NSSet<java.lang.String> keyPathsForValuesAffectingValueForKey(java.lang.String key)
-
new_objc
public static java.lang.Object new_objc()
-
resolveClassMethod
public static boolean resolveClassMethod(org.moe.natj.objc.SEL sel)
-
resolveInstanceMethod
public static boolean resolveInstanceMethod(org.moe.natj.objc.SEL sel)
-
setVersion_static
public static void setVersion_static(long aVersion)
-
superclass_static
public static org.moe.natj.objc.Class superclass_static()
-
version_static
public static long version_static()
-
copyWithZone
public java.lang.Object copyWithZone(org.moe.natj.general.ptr.VoidPtr zone)
- Specified by:
copyWithZonein interfaceNSCopying
-
hasItemConformingToTypeIdentifier
public boolean hasItemConformingToTypeIdentifier(java.lang.String typeIdentifier)
Returns YES if the item provider has at least one item that conforms to the supplied type identifier.
-
init
public NSItemProvider init()
-
initWithContentsOfURL
public NSItemProvider initWithContentsOfURL(NSURL fileURL)
Initialize an NSItemProvider with load handlers for the given file URL, and the file content. A type identifier is inferred from the file extension.
-
initWithItemTypeIdentifier
public NSItemProvider initWithItemTypeIdentifier(NSSecureCoding item, java.lang.String typeIdentifier)
Initialize an NSItemProvider with an object assigned to a single UTI. `item` is retained.
-
loadItemForTypeIdentifierOptionsCompletionHandler
public void loadItemForTypeIdentifierOptionsCompletionHandler(java.lang.String typeIdentifier, NSDictionary<?,?> options, NSItemProvider.Block_loadItemForTypeIdentifierOptionsCompletionHandler completionHandler)Loads the best matching item for a type identifier. The returned object depends on the class specified for the completion handler's `item` parameter. See the table above for coercion rules.
-
loadPreviewImageWithOptionsCompletionHandler
public void loadPreviewImageWithOptionsCompletionHandler(NSDictionary<?,?> options, NSItemProvider.Block_loadPreviewImageWithOptionsCompletionHandler completionHandler)
Loads the preview image for this item by either calling the supplied preview block or falling back to a QuickLook-based handler. This method, like loadItemForTypeIdentifier:options:completionHandler:, supports implicit type coercion for the item parameter of the completion block. Allowed value classes are: NSData, NSURL, UIImage/NSImage.
-
registeredTypeIdentifiers
public NSArray<java.lang.String> registeredTypeIdentifiers()
Returns the list of registered type identifiers, in the order they were registered.
-
canLoadObjectOfClass
public boolean canLoadObjectOfClass(NSItemProviderReading aClass)
-
hasRepresentationConformingToTypeIdentifierFileOptions
public boolean hasRepresentationConformingToTypeIdentifierFileOptions(java.lang.String typeIdentifier, long fileOptions)
-
initWithObject
public NSItemProvider initWithObject(NSItemProviderWriting object)
Instantiate an NSItemProvider by querying an object for its eligible type identifiers via the NSItemProviderWriting protocol.
-
loadDataRepresentationForTypeIdentifierCompletionHandler
public NSProgress loadDataRepresentationForTypeIdentifierCompletionHandler(java.lang.String typeIdentifier, NSItemProvider.Block_loadDataRepresentationForTypeIdentifierCompletionHandler completionHandler)
Copies the provided data into an NSData object.
-
loadFileRepresentationForTypeIdentifierCompletionHandler
public NSProgress loadFileRepresentationForTypeIdentifierCompletionHandler(java.lang.String typeIdentifier, NSItemProvider.Block_loadFileRepresentationForTypeIdentifierCompletionHandler completionHandler)
Writes a copy of the data to a temporary file. This file will be deleted when the completion handler returns. Your program should copy or move the file within the completion handler.
-
loadInPlaceFileRepresentationForTypeIdentifierCompletionHandler
public NSProgress loadInPlaceFileRepresentationForTypeIdentifierCompletionHandler(java.lang.String typeIdentifier, NSItemProvider.Block_loadInPlaceFileRepresentationForTypeIdentifierCompletionHandler completionHandler)
Open the original file in place, if possible. If a file is not available for opening in place, a copy of the file is written to a temporary location, and `isInPlace` is set to NO. Your program may then copy or move the file, or the system will delete this file at some point in the future.
-
loadObjectOfClassCompletionHandler
public NSProgress loadObjectOfClassCompletionHandler(NSItemProviderReading aClass, NSItemProvider.Block_loadObjectOfClassCompletionHandler completionHandler)
Instantiate an object using the NSItemProviderReading protocol.
-
preferredPresentationSize
public CGSize preferredPresentationSize()
Estimated presentation size, in points. CGSizeZero value indicates this information is not available.
-
preferredPresentationStyle
public long preferredPresentationStyle()
-
registerObjectVisibility
public void registerObjectVisibility(NSItemProviderWriting object, long visibility)
Add representations from an object using the NSItemProviderWriting protocol. Duplicate representations are ignored.
-
registeredTypeIdentifiersWithFileOptions
public NSArray<java.lang.String> registeredTypeIdentifiersWithFileOptions(long fileOptions)
-
setPreferredPresentationSize
public void setPreferredPresentationSize(CGSize value)
Estimated presentation size, in points. CGSizeZero value indicates this information is not available.
-
setPreferredPresentationStyle
public void setPreferredPresentationStyle(long value)
-
setSuggestedName
public void setSuggestedName(java.lang.String value)
-
setTeamData
public void setTeamData(NSData value)
-
suggestedName
public java.lang.String suggestedName()
-
teamData
public NSData teamData()
-
previewImageHandler
public NSItemProvider.Block_previewImageHandler_ret previewImageHandler()
Sets a custom preview image handler block for this item provider. The returned item should preferably be NSData or a file NSURL.
-
registerDataRepresentationForTypeIdentifierVisibilityLoadHandler
public void registerDataRepresentationForTypeIdentifierVisibilityLoadHandler(java.lang.String typeIdentifier, long visibility, NSItemProvider.Block_registerDataRepresentationForTypeIdentifierVisibilityLoadHandler loadHandler)Registers a data-backed representation.
-
registerFileRepresentationForTypeIdentifierFileOptionsVisibilityLoadHandler
public void registerFileRepresentationForTypeIdentifierFileOptionsVisibilityLoadHandler(java.lang.String typeIdentifier, long fileOptions, long visibility, NSItemProvider.Block_registerFileRepresentationForTypeIdentifierFileOptionsVisibilityLoadHandler loadHandler)Registers a file-backed representation. Set `coordinated` to YES if the returned file must be accessed using NSFileCoordinator. If `NSItemProviderFileOptionOpenInPlace` is not provided, the file provided will be copied before the load handler returns.
-
registerItemForTypeIdentifierLoadHandler
public void registerItemForTypeIdentifierLoadHandler(java.lang.String typeIdentifier, NSItemProvider.Block_registerItemForTypeIdentifierLoadHandler loadHandler)Registers a load handler that returns an object, assigned to a single UTI.
-
registerObjectOfClassVisibilityLoadHandler
public void registerObjectOfClassVisibilityLoadHandler(NSItemProviderWriting aClass, long visibility, NSItemProvider.Block_registerObjectOfClassVisibilityLoadHandler loadHandler)
Add representations from a class, but defer loading the object until needed.
-
setPreviewImageHandler
public void setPreviewImageHandler(NSItemProvider.Block_setPreviewImageHandler value)
Sets a custom preview image handler block for this item provider. The returned item should preferably be NSData or a file NSURL.
-
-