Proxy Class Reference

#import <Proxy.h>

Inherits Notifier, and IProxy-p.

List of all members.

Public Member Functions

(void) - initializeProxy
(void) - onRegister [implementation]
(void) - onRemove [implementation]
(void) - sendNotification:body:type: [implementation]
(id) - data
(NSString *) - proxyName
(void) - setData:


Detailed Description

A base IProxy implementation.

In PureMVC, Proxy classes are used to manage parts of the application's data model.

A Proxy might 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.

Proxy classes are also used to encapsulate the application's interaction with remote services to save or retrieve data, in which case, we adopt an asyncronous idiom; setting data (or calling a method) on the Proxy and listening for a Notification to be sent when the Proxy has retrieved the data from the service.

See also:
Model

Member Function Documentation

- (id) data  

Get the data object

Returns:
the data as type id

- (void) initializeProxy  

Initialize the Proxy instance.

Called automatically by the constructor, this is your opportunity to initialize the Proxy instance in your subclass without overriding the constructor.

Returns:
void

- (void) onRegister   [implementation]

Called by the Model when the Proxy is registered

Reimplemented from < IProxy >.

- (void) onRemove   [implementation]

Called by the Model when the Proxy is removed

Reimplemented from < IProxy >.

- (NSString *) proxyName  

Get the Proxy name

Returns:
the Proxy instance name

- (void) sendNotification: (NSString *)  notificationName
body: (id)  body
type: (NSString *)  type 
[implementation]

Create and send an INotification.

Keeps us from having to construct new INotification instances in our implementation code.

Parameters:
notificationName the name of the notiification to send
body the body of the notification
type the type of the notification

Reimplemented from < INotifier >.

- (void) setData: (id)  data  

Set the data object

Parameters:
data the data object


Generated on Wed Dec 24 14:19:08 2008 for PureMVC Objective-C by  doxygen 1.5.7.1