MCEActionRegistry Class Reference

Inherits from NSObject
Declared in MCEActionRegistry.h
MCEActionRegistry.m

Overview

The MCEActionRegistry class is used to register and perform actions in the “notification-action” and “category-actions” sections of the APNS payload.

+ sharedInstance

This method returns the singleton object of this class.

+ (instancetype)sharedInstance

Discussion

This method returns the singleton object of this class.

Declared In

MCEActionRegistry.h

– performAction:forPayload:source:userText:

Method is deprecated, please use performAction:forPayload:source:attributes:userText: instead.

- (void)performAction:(NSDictionary *)action forPayload:(NSDictionary *)payload source:(NSString *)source userText:(NSString *)userText

Discussion

Method is deprecated, please use performAction:forPayload:source:attributes:userText: instead.

Declared In

MCEActionRegistry.h

– performAction:forPayload:source:

Method is deprecated, please use performAction:forPayload:source:attributes:userText: instead.

- (void)performAction:(NSDictionary *)action forPayload:(NSDictionary *)payload source:(NSString *)source

Discussion

Method is deprecated, please use performAction:forPayload:source:attributes:userText: instead.

Declared In

MCEActionRegistry.h

– performAction:forPayload:source:attributes:

Method is deprecated, please use performAction:forPayload:source:attributes:userText: instead.

- (void)performAction:(NSDictionary *)action forPayload:(NSDictionary *)payload source:(NSString *)source attributes:(NSDictionary *)attributes

Discussion

Method is deprecated, please use performAction:forPayload:source:attributes:userText: instead.

Declared In

MCEActionRegistry.h

– performAction:forPayload:source:attributes:userText:

This method performs the registered specified action for the APNS payload.

- (void)performAction:(NSDictionary *)action forPayload:(NSDictionary *)payload source:(NSString *)source attributes:(NSDictionary *)attributes userText:(NSString *)userText

Parameters

action

the action dictionary to be executed. (either the “notification-action” or one of the “category-actions”)

payload

the full APNS payload

source

the event type value to report

attributes

Additional attributes for event payload

userText

Text entered by the user

Discussion

This method performs the registered specified action for the APNS payload.

Declared In

MCEActionRegistry.h

– unregisterAction:

This method removes the registration for handling a specified action type name.

- (void)unregisterAction:(NSString *)type

Parameters

type

action the specified action type name to be used in the APNS payload as the type value

Discussion

This method removes the registration for handling a specified action type name.

Declared In

MCEActionRegistry.h

– registerTarget:withSelector:forAction:

This method is used to register an object to receive action messages for a specified action type name.

- (BOOL)registerTarget:(NSObject<MCEActionProtocol> *)target withSelector:(SEL)selector forAction:(NSString *)type

Parameters

target

the object that will accept action messages

selector

a selector that processes the action, can either take one or two arguments. The first argument is always the action payload and the second, if included is the full APNS payload.

type

action the specified action type name to be used in the APNS payload as the type value

Return Value

TRUE or FALSE depending if the registration was successful or not.

Discussion

This method is used to register an object to receive action messages for a specified action type name.

Declared In

MCEActionRegistry.h

– configureAlertTextField:forAction:

Method is deprecated, please do not use.

- (void)configureAlertTextField:(UITextField *)textField forAction:(NSString *)action

Parameters

textField

The UITextField object to be configured

action

The name of the action registered.

Discussion

Method is deprecated, please do not use.

This method calls the registered action handler’s configureAlertTextField method.

Declared In

MCEActionRegistry.h

– actionIncludesUserText:

Method is deprecated, please do not use.

- (BOOL)actionIncludesUserText:(NSString *)action

Parameters

action

The name of the action registered.

Return Value

TRUE or FALSE depending if the action expects user text input.

Discussion

Method is deprecated, please do not use.

This method returns true if the action registered for the specified action type expects user text input.

Declared In

MCEActionRegistry.h

– actionExpectsUserText:

Method is deprecated, please do not use.

- (BOOL)actionExpectsUserText:(NSDictionary *)action

Parameters

action

the action dictionary to be evaluated. (either the “notification-action” or one of the “category-actions”)

Return Value

TRUE or FALSE depending if the action plugin wants the user to be prompted for text input if it wasn’t provided otherwise.

Discussion

Method is deprecated, please do not use.

This method allows the action plugins to specifiy if they want the user prompted for text input if it isn’t provided by the standard text input push method.

Declared In

MCEActionRegistry.h