Package puremvc :: Module interfaces :: Class IProxy
[hide private]
[frames] | no frames]

classobj IProxy

source code

Known Subclasses:

The interface definition for a PureMVC Proxy.

In PureMVC, IProxy implementors assume these responsibilities:

Implement a common method which returns the name of the Proxy.

Provide methods for setting and getting the data object.

Additionally, IProxys typically:

Maintain references to one or more pieces of model data. Provide methods for manipulating that data. Generate INotifications when their model data changes. Expose their name as a public static const called NAME, if they are not instantiated multiple times. Encapsulate interaction with local or remote services used to fetch and persist model data.

Instance Methods [hide private]
 
getProxyName(self)
Get the Proxy name
source code
 
setData(data)
Set the data object
source code
 
getData()
Get the data object
source code
 
onRegister()
Called by the Model when the Proxy is registered
source code
 
onRemove()
Called by the Model when the Proxy is removed
source code
Method Details [hide private]

getProxyName(self)

source code 

Get the Proxy name

Returns:
the Proxy instance name

setData(data)

source code 

Set the data object

Parameters:
  • data - the data object

getData()

source code 

Get the data object

Returns:
the data as type Object