voltmx.actionExtension Namespace
The voltmx.actionExtension Namespace provides support for the iOS Action extension, which is a kind of iOS app extension.
An Action extension helps users view or update content originating in a host app. For example, an Action extension might help users edit an image in a document that they’re viewing in a document editor. For more information about what Action extensions are and what you can use them for, please see the Apple developer documentation.
You add an Action extension to your app in the same way that you add any other type of iOS app extension. For more details, refer App Extension API for iOS.
Before your Action extension can be used, your app must set the callback functions that provide the Action extension with its functionality. It does this by invoking the voltmx.actionExtension.setExtensionsCallbacks function.
The voltmx.actionExtension Namespace contains the following API elements.
Properties
The voltmx.actionExtensions Namespace provides the following properties.
voltmx.actionExtensions.view
Holds the current extension view.
Syntax
Example
Type
UIView
Read/Write
Read only.
Platform Availability
iOS.
Functions
The voltmx.actionExtension namespace contains the following functions.
voltmx.actionExtension.setExtensionsCallbacks
Sets an Action Extension with callbacks for app extension state changes.
Syntax
Input Parameters
callbacks
Contains an object with key-value pairs where the key specifies the extension state and the value is a callback function. The following are the possible keys.
Key | Description |
---|---|
beginRequestWithExtensionContext | The user has selected the action. |
loadView | Loads a view that the controller manages. |
viewDidAppear | A view was just displayed. |
viewDidDisappear | A view just removed from the view hierarchy. |
viewDidLoad | The view’s controller was loaded into memory. |
viewWillAppear | A view is about to be displayed. |
viewWillDisappear | A view is about to be removed from the view hierarchy. |
Example: beginRequestWithExtensionContext
Example: loadView
Example: viewDidAppear
Example: viewDidLoad
Example: viewDidDisappear
Example: viewWillAppear
Example: viewWillDisappear
Return Values
None.
Platform Availability
iOS only