Package apple.uikit

Class UIAction

    • Constructor Detail

      • UIAction

        protected UIAction​(org.moe.natj.general.Pointer peer)
    • Method Detail

      • accessInstanceVariablesDirectly

        public static boolean accessInstanceVariablesDirectly()
      • actionWithTitleImageIdentifierHandler

        public static UIAction actionWithTitleImageIdentifierHandler​(@NotNull
                                                                     @NotNull java.lang.String title,
                                                                     @Nullable
                                                                     @Nullable UIImage image,
                                                                     @Nullable
                                                                     @Nullable java.lang.String identifier,
                                                                     @NotNull
                                                                     @NotNull UIAction.Block_actionWithTitleImageIdentifierHandler handler)
        Creates a UIAction with the given arguments.
        Parameters:
        title - The action's title.
        image - Image that can appear next to this action, if needed.
        identifier - The action's identifier. Pass nil to use an auto-generated identifier.
        handler - Handler block. Called when the user selects the action.
        Returns:
        A new UIAction.
      • alloc

        public static UIAction alloc()
      • allocWithZone

        public static UIAction allocWithZone​(org.moe.natj.general.ptr.VoidPtr zone)
      • attributes

        public long attributes()
        This action's style.
        Specified by:
        attributes in interface UIMenuLeaf
      • automaticallyNotifiesObserversForKey

        public static boolean automaticallyNotifiesObserversForKey​(@NotNull
                                                                   @NotNull java.lang.String key)
      • cancelPreviousPerformRequestsWithTarget

        public static void cancelPreviousPerformRequestsWithTarget​(@NotNull
                                                                   @NotNull java.lang.Object aTarget)
      • cancelPreviousPerformRequestsWithTargetSelectorObject

        public static void cancelPreviousPerformRequestsWithTargetSelectorObject​(@NotNull
                                                                                 @NotNull java.lang.Object aTarget,
                                                                                 @NotNull
                                                                                 @NotNull org.moe.natj.objc.SEL aSelector,
                                                                                 @Nullable
                                                                                 @Nullable java.lang.Object anArgument)
      • classFallbacksForKeyedArchiver

        @NotNull
        public static @NotNull NSArray<java.lang.String> classFallbacksForKeyedArchiver()
      • classForKeyedUnarchiver

        @NotNull
        public static @NotNull org.moe.natj.objc.Class classForKeyedUnarchiver()
      • debugDescription_static

        public static java.lang.String debugDescription_static()
      • description_static

        public static java.lang.String description_static()
      • discoverabilityTitle

        @Nullable
        public @Nullable java.lang.String discoverabilityTitle()
        Elaborated title, if any.
        Specified by:
        discoverabilityTitle in interface UIMenuLeaf
      • hash_static

        public static long hash_static()
      • identifier

        @NotNull
        public @NotNull java.lang.String identifier()
        This action's identifier.
      • 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

        @NotNull
        public static @NotNull NSSet<java.lang.String> keyPathsForValuesAffectingValueForKey​(@NotNull
                                                                                             @NotNull java.lang.String key)
      • new_objc

        public static UIAction new_objc()
      • resolveClassMethod

        public static boolean resolveClassMethod​(org.moe.natj.objc.SEL sel)
      • resolveInstanceMethod

        public static boolean resolveInstanceMethod​(org.moe.natj.objc.SEL sel)
      • setAttributes

        public void setAttributes​(long value)
        This action's style.
        Specified by:
        setAttributes in interface UIMenuLeaf
      • setDiscoverabilityTitle

        public void setDiscoverabilityTitle​(@Nullable
                                            @Nullable java.lang.String value)
        Elaborated title, if any.
        Specified by:
        setDiscoverabilityTitle in interface UIMenuLeaf
      • setImage

        public void setImage​(@Nullable
                             @Nullable UIImage value)
        Image that can appear next to this action.
        Specified by:
        setImage in interface UIMenuLeaf
      • setState

        public void setState​(long value)
        State that can appear next to this action.
        Specified by:
        setState in interface UIMenuLeaf
      • setTitle

        public void setTitle​(@NotNull
                             @NotNull java.lang.String value)
        Short display title.
        Specified by:
        setTitle in interface UIMenuLeaf
      • setVersion_static

        public static void setVersion_static​(long aVersion)
      • state

        public long state()
        State that can appear next to this action.
        Specified by:
        state in interface UIMenuLeaf
      • superclass_static

        public static org.moe.natj.objc.Class superclass_static()
      • supportsSecureCoding

        public static boolean supportsSecureCoding()
      • _supportsSecureCoding

        public boolean _supportsSecureCoding()
        Description copied from interface: NSSecureCoding
        This property must return YES on all classes that allow secure coding. Subclasses of classes that adopt NSSecureCoding and override initWithCoder: must also override this method and return YES. The Secure Coding Guide should be consulted when writing methods that decode data.
        Specified by:
        _supportsSecureCoding in interface NSSecureCoding
        Overrides:
        _supportsSecureCoding in class UIMenuElement
      • title

        @NotNull
        public @NotNull java.lang.String title()
        Short display title.
        Specified by:
        title in interface UIMenuLeaf
        Overrides:
        title in class UIMenuElement
      • version_static

        public static long version_static()
      • actionWithHandler

        public static UIAction actionWithHandler​(@NotNull
                                                 @NotNull UIAction.Block_actionWithHandler handler)
        Creates a UIAction with an empty title, nil image, and automatically generated identifier
        Parameters:
        handler - Handler block. Called when the user selects the action.
        Returns:
        A new UIAction. API-Since: 14.0
      • sender

        @Nullable
        public @Nullable java.lang.Object sender()
        If available, the object on behalf of which the actionHandler is called.
        Specified by:
        sender in interface UIMenuLeaf
      • captureTextFromCameraActionForResponderIdentifier

        @NotNull
        public static @NotNull UIAction captureTextFromCameraActionForResponderIdentifier​(@NotNull
                                                                                          @NotNull UIResponder responder,
                                                                                          @Nullable
                                                                                          @Nullable java.lang.String identifier)
        Creates a new UIAction for the captureTextFromCamera: standard edit action.
        Parameters:
        responder - The UIKeyInput responder to send captureTextFromCamera: to.
        identifier - The action's identifier. Pass nil to use an auto-generated identifier.
        Returns:
        A new UIAction. API-Since: 15.0
      • performWithSenderTarget

        public void performWithSenderTarget​(@Nullable
                                            @Nullable java.lang.Object sender,
                                            @Nullable
                                            @Nullable java.lang.Object target)
        Description copied from interface: UIMenuLeaf
        Performs the element’s primary action (i.e. it's handler or selector).
        Specified by:
        performWithSenderTarget in interface UIMenuLeaf
      • presentationSourceItem

        @Nullable
        public @Nullable UIPopoverPresentationControllerSourceItem presentationSourceItem()
        Description copied from interface: UIMenuLeaf
        Source item for subsequent presentations. For example, an element displayed in a menu attached to a [@c] UIButton may return the button so that a popover may be presented from it when the element is tapped. If available, this property is only populated during the execution of the element's action (i.e. its handler or selector). API-Since: 16.0
        Specified by:
        presentationSourceItem in interface UIMenuLeaf
      • selectedImage

        @Nullable
        public @Nullable UIImage selectedImage()
        Description copied from interface: UIMenuLeaf
        Image that can appear next to this action when the `state` is `UIMenuElementStateOn` API-Since: 17.0
        Specified by:
        selectedImage in interface UIMenuLeaf
      • setSelectedImage

        public void setSelectedImage​(@Nullable
                                     @Nullable UIImage value)
        Description copied from interface: UIMenuLeaf
        Image that can appear next to this action when the `state` is `UIMenuElementStateOn` API-Since: 17.0
        Specified by:
        setSelectedImage in interface UIMenuLeaf
      • useStoredAccessor

        @Deprecated
        public static boolean useStoredAccessor()
        Deprecated.