SwatObject
└─SwatCellRendererSet
public class SwatCellRendererSet
extends SwatObject
| Method Summary | |
|---|---|
| void | addMappingToRenderer(SwatCellRenderer renderer, SwatCellRendererMapping mapping) Adds a single property-datafield mapping to a cell renderer already in this set. |
| void | addMappingsToRenderer(SwatCellRenderer renderer, array mappings) Adds a set of datafield-property mappings to a cell renderer already in this set. |
| void | addRenderer(SwatCellRenderer renderer) Adds a cell renderer to this set. |
| void | addRendererWithMappings(SwatCellRenderer renderer, array mappings) Adds a cell renderer to this set with a predefined set of datafield-property mappings. |
| void | applyMappingsToRenderer(SwatCellRenderer renderer, mixed data_object) Applies the property-datafield mappings to a cell renderer already in this set using a specified data object. |
| integer | count() Gets the number of cell renderers in this set. |
| SwatCellRenderer | current() Returns the current renderer. |
| integer | getCount() Gets the number of renderers in this set. |
| SwatCellRenderer | getFirst() Gets the first renderer in this set. |
| array | getMappingsByRenderer(SwatCellRenderer renderer) Gets the mappings of a cell renderer already in this set. |
| SwatCellRenderer | getRenderer(string renderer_id) Gets a renderer in this set by its id. |
| SwatCellRenderer | getRendererByPosition(integer position) Gets a cell renderer in this set by its ordinal position. |
| integer | key() Returns the key of the current renderer. |
| boolean | Whether or not mappings have been applied to this cell-renderer set. |
| void | next() Moves forward to the next renderer. |
| void | rewind() Rewinds this iterator to the first renderer. |
| boolean | valid() Checks is there is a current renderer after calls to rewind() and next(). |
public void addMappingToRenderer(SwatCellRenderer renderer, SwatCellRendererMapping mapping)
Adds a single property-datafield mapping to a cell renderer already in this set
renderer - the cell renderer to add the mapping to.mapping - the mapping to add.public void addMappingsToRenderer(SwatCellRenderer renderer, array mappings)
Adds a set of datafield-property mappings to a cell renderer already in this set
renderer - the cell renderer to add the mappings to.mappings - an array of SwatCellRendererMapping objects.public void addRenderer(SwatCellRenderer renderer)
Adds a cell renderer to this set
An empty datafield-property mapping array is created for the added renderer.
renderer - the renderer to add.public void addRendererWithMappings(SwatCellRenderer renderer, array mappings)
Adds a cell renderer to this set with a predefined set of datafield-property mappings
renderer - the renderer to add.mappings - an array of SwatCellRendererMapping objects.public void applyMappingsToRenderer(SwatCellRenderer renderer, mixed data_object)
Applies the property-datafield mappings to a cell renderer already in this set using a specified data object
renderer - the cell renderer to apply the mappings to.data_object - an object containg datafields to be mapped onto the cell renderer.public integer count()
Gets the number of cell renderers in this set
This satisfies the Countable interface.
public SwatCellRenderer current()
Returns the current renderer
public integer getCount()
Gets the number of renderers in this set
public SwatCellRenderer getFirst()
Gets the first renderer in this set
public array getMappingsByRenderer(SwatCellRenderer renderer)
Gets the mappings of a cell renderer already in this set
renderer - the cell renderer to get the mappings for.public SwatCellRenderer getRenderer(string renderer_id)
Gets a renderer in this set by its id
renderer_id - the id of the renderer to get.public SwatCellRenderer getRendererByPosition(integer position)
Gets a cell renderer in this set by its ordinal position
position - the ordinal position of the renderer.public integer key()
Returns the key of the current renderer
public boolean mappingsApplied()
Whether or not mappings have been applied to this cell-renderer set
public void next()
Moves forward to the next renderer
public void rewind()
Rewinds this iterator to the first renderer
public boolean valid()
Checks is there is a current renderer after calls to rewind() and next()
A collection of cell renderers with associated datafield-property mappings