Agile Toolkit  4.2
Agile Toolkit is a powerful web development framework. Inspired by GUI Applications development
Lister Class Reference
Inheritance diagram for Lister:
View AbstractView AbstractObject CompleteLister Grid_Basic Menu_Basic Paginator_Basic Grid_Advanced Menu Paginator Grid InfoWindow MVCGrid

Public Member Functions

 setSource ($source, $fields=null)
 setStaticSource ($data)
 formatRow ()
 rowRender ($template)
 getIterator ()
 render ()
 defaultTemplate ()

Data Fields

 $dq = null
 $iter = null
 $current_row = array()
 $current_row_html = array()
 $current_id = null
 $iterator = array()

Detailed Description

Lister implements a very simple and fast way to output series of data by applying template formatting

Use: $list=$this->add('Lister'); $list->setModel('User'); Template (view/users.html): <?$name?>

<?$desc?>

See http://agiletoolkit.org/about/license


Member Function Documentation

Redefine to return default template, when 4th argument of add() is omitted

Reimplemented from View.

Reimplemented in CompleteLister, Paginator_Basic, Grid_Advanced, Menu_Basic, Grid_Basic, and InfoWindow.

formatRow ( )

Redefine and change $this->current_row to format data before it appears

Reimplemented in Grid_Basic, and CompleteLister.

Reimplemented in Grid_Advanced.

render ( )

Default render. Generates HTML presentation of the view based on $this->template and passes it to output() function which then inserts output into parent's template

For visual objects, their default action while rendering is rely on SMlite engine. For sake of simplicity and speed you can redefine this method with a simple call

Reimplemented from AbstractView.

Reimplemented in Grid_Advanced, CompleteLister, Menu_Basic, and InfoWindow.

rowRender ( template)

Renders single row. If you use for formatting then interact with template->set() directly prior to calling parent

setStaticSource ( data)

set array source


Field Documentation

$current_id = null

Contains ID of current record

$current_row = array()

Points to current row before it's being outputted. Used in formatRow()

$current_row_html = array()

Similar to $current_row, but will use for direct HTML output, no escaping. Use with care.

$dq = null

If lister data is retrieed from the SQL database, this will contain dynamic query.

$iter = null

For other iterators, this variable will be used

$iterator = array()

Data set fetched from source


The documentation for this class was generated from the following file:
 All Data Structures Files Functions Variables Enumerations