Instance Property

extensionContext

For a view controller that is part of an app extension, the app extension context.

Declaration

@property(readonly, retain) NSExtensionContext *extensionContext;

Discussion

If the view controller is not part of an app extension, the value of this property is nil.

By checking for nil you can employ this method to determine whether the view controller is part of an app or an app extension, for the purpose of conditionalizing your view controller implementation. Refer to NSExtensionContext for information about the extension context.

See Also

Configuring an App Extension View Controller

preferredScreenOrigin

For a view controller that is part of an app extension, the preferred screen origin.

preferredMaximumSize

For a view controller that is part of an app extension, the largest allowable size for the app extension’s primary view, in screen units.

preferredMinimumSize

For a view controller that is part of an app extension, the smallest allowable size for the app extension’s primary view, in screen units.

- viewWillTransitionToSize:

For a view controller that is part of an app extension, called when its view is about to be resized.