Protected Optional_datathe data object
Protected Readonly_namethe proxy name
ProtectedmultitonThe Multiton Key for this app
Protected StaticMULTITON_Message Constants
StaticNAMEThe default name for the Proxy.
Get the data object
The current data or undefined if no data is set.
Set the data object
The data to set. Can be null.
Get the proxy name
The name of the proxy.
Initialize this Notifier instance.
This is how a Notifier gets its multitonKey. Calls to sendNotification or to access the facade will fail until after this method has been called.
Mediators, Commands or Proxies may override this method in order to send notifications or access the Multiton Facade instance as soon as possible. They CANNOT access the facade in their constructors, since this method will not yet have been called.
the multitonKey for this Notifier to use
Create and send an Notification.
Keeps us from having to construct new Notification instances in our implementation code.
The name of the notification to be sent.
Optionalbody: anyOptional data to be included with the notification.
Optionaltype: stringOptional type of the notification.
A base
Proxyimplementation.In PureMVC,
Proxyclasses are used to manage parts of the application's data model.A
Proxymight simply manage a reference to a local data object, in which case interacting with it might involve setting and getting of its data in synchronous fashion.Proxyclasses are also used to encapsulate the application's interaction with remote services to save or retrieve data, in which case, we adopt an asynchronous idiom; setting data (or calling a method) on theProxyand listening for aNotificationto be sent when theProxyhas retrieved the data from the service.See
Model
Proxy