Instance Method

validate(_:)

Asks the receiving responder to validate the command.

Declaration

func validate(_ command: UICommand)

Parameters

command

A mutable command object.

Discussion

Override this method in your view controller to make changes to a command before the command system renders it as a menu item.

See Also

Building and Validating Commands

func canPerformAction(Selector, withSender: Any?) -> Bool

Requests the receiving responder to enable or disable the specified command in the user interface.

func target(forAction: Selector, withSender: Any?) -> Any?

Returns the target object that responds to an action.