Main Page | Class Hierarchy | Class List | File List | Class Members | File Members

SmartyApp Class Reference

Inheritance diagram for SmartyApp:

Inheritance graph
List of all members.

Detailed Description

Combine a WebApp with a Smarty template.

This class combines the functionality of the WebApp class with a Smarty template. It makes it easy to create Smarty templates that can render the controls contained in the WebApp without having to assign each control to the Smarty object manually.

Definition at line 20 of file smartyapp.php.

Public Member Functions

 SmartyApp ()
 Instantiates a new Smarty object .

 assign ()
 Assign controls to the Smarty object.

getSmarty ()
 Get the smarty object.

 setSmarty (&$smarty)
 Set the smarty object.

 getTemplate ()
 Get the Smarty template.

 setTemplate ($template)
 Set the Smarty template.

 version ()
 Get the version of the class.

 toString ()
 Get the result of rendering the map to the Smarty template.

 __sleep ()
 Prepare object for serialisation.


Public Attributes

 $smarty
 A Smarty object.

 $template
 A Smarty template.


Constructor & Destructor Documentation

SmartyApp::SmartyApp  ) 
 

Instantiates a new Smarty object .

Definition at line 30 of file smartyapp.php.


Member Function Documentation

SmartyApp::__sleep  ) 
 

Prepare object for serialisation.

This method is automatically called just before the object is serialised to carry out clean-up operations. See the PHP documentation at http://www.php.net/manual/en/language.oop.magic-functions.php for more information.

Returns:
an array of object property names to be serialised.

Reimplemented from WebApp.

Reimplemented in MapApp.

Definition at line 134 of file smartyapp.php.

SmartyApp::assign  ) 
 

Assign controls to the Smarty object.

Assigns all controls in the ControlBox to the Smarty object. Only objects which are allowed to be displayed are assigned. The ID of each control is the name with which it should be referenced in the template.

Returns:
void

Reimplemented in MapApp.

Definition at line 44 of file smartyapp.php.

References $smarty.

& SmartyApp::getSmarty  ) 
 

Get the smarty object.

Returns:
a reference to the internal Smarty object

Definition at line 61 of file smartyapp.php.

SmartyApp::getTemplate  ) 
 

Get the Smarty template.

Returns:
the Smarty template

Reimplemented in MapApp.

Definition at line 79 of file smartyapp.php.

SmartyApp::setSmarty &$  smarty  ) 
 

Set the smarty object.

Parameters:
$smarty a reference to a Smarty instance
Returns:
void

Definition at line 71 of file smartyapp.php.

References $smarty.

SmartyApp::setTemplate template  ) 
 

Set the Smarty template.

Parameters:
$template the template
Returns:
void

Reimplemented in MapApp.

Definition at line 88 of file smartyapp.php.

References $template.

SmartyApp::toString  ) 
 

Get the result of rendering the map to the Smarty template.

Returns:
string

Reimplemented in MapApp.

Definition at line 111 of file smartyapp.php.

References $smarty, and $template.

SmartyApp::version  ) 
 

Get the version of the class.

Returns:
the version string

Reimplemented from WebApp.

Reimplemented in MapApp.

Definition at line 97 of file smartyapp.php.

References SMARTYAPP_VERSION.


Member Data Documentation

SmartyApp::$smarty
 

A Smarty object.

Definition at line 23 of file smartyapp.php.

Referenced by assign(), setSmarty(), and toString().

SmartyApp::$template
 

A Smarty template.

Definition at line 25 of file smartyapp.php.

Referenced by setTemplate(), and toString().


The documentation for this class was generated from the following file:
Generated on Mon Feb 14 10:55:55 2005 for MapApp by doxygen 1.3.5