Exponential 6.0.13 Exponential Enterprise Open Source CMS - PHP Class Reference

Public Member Functions | Public Attributes | List of all members
eZTemplateSectionIterator Class Reference
Template system » Template functions

The iterator item in a section loop which works as a proxy. More...

## Public Member Functions
| __construct ()
| templateValue ()
| attributes ()
| hasAttribute ( $name)
| attribute ( $name)
| setIteratorValues ( $item, $key, $index, $number, $sequence, &$last)
| setSequence ( $sequence)

## Public Attributes
| $InternalAttributes

## Detailed Description

The iterator item in a section loop which works as a proxy.

The iterator provides transparent access to iterator items. It will redirect all attribute calls to the iterator item with the exception of a few internal values. The internal values are

- item - The actual item, provides backwards compatibility
- key - The current key
- index - The current index value (starts at 0 and increases with 1 for each element)
- number - The current index value + 1 (starts at 1 and increases with 1 for each element)
- sequence - The current sequence value
- last - The last iterated element item

Definition at line 27 of file eztemplatesectioniterator.php.

## Constructor & Destructor Documentation

## ◆ __construct()

eZTemplateSectionIterator::__construct | ( |  | ) |

Initializes the iterator with empty values.

Definition at line 33 of file eztemplatesectioniterator.php.

## Member Function Documentation

## ◆ attribute()

eZTemplateSectionIterator::attribute | ( |  | $name | ) |

Returns
  the attribute value of either the internal attributes or from the item value if the attribute exists for it.

Definition at line 105 of file eztemplatesectioniterator.php.

References eZDebug\writeError().

## ◆ attributes()

eZTemplateSectionIterator::attributes | ( |  | ) |

Returns
  a merged list of attributes from both the internal attributes and the items attributes.

Definition at line 55 of file eztemplatesectioniterator.php.

## ◆ hasAttribute()

eZTemplateSectionIterator::hasAttribute | ( |  | $name | ) |

Returns
  `true` if the attribute $name exists either in the internal attributes or in the item value.

Definition at line 77 of file eztemplatesectioniterator.php.

## ◆ setIteratorValues()

eZTemplateSectionIterator::setIteratorValues | ( |  | $item,
|  |  | $key,
|  |  | $index,
|  |  | $number,
|  |  | $sequence,
|  | & | $last
| ) |  |

Updates the iterator with the current iteration values.

Definition at line 133 of file eztemplatesectioniterator.php.

## ◆ setSequence()

eZTemplateSectionIterator::setSequence | ( |  | $sequence | ) |

Updates the current sequence value to $sequence.

Definition at line 146 of file eztemplatesectioniterator.php.

## ◆ templateValue()

eZTemplateSectionIterator::templateValue | ( |  | ) |

Returns
  the value of the current item for the template system to use.

Definition at line 46 of file eztemplatesectioniterator.php.

## Member Data Documentation

## ◆ $InternalAttributes

eZTemplateSectionIterator::$InternalAttributes

Definition at line 29 of file eztemplatesectioniterator.php.

The documentation for this class was generated from the following file:

- eztemplatesectioniterator.php

Copyright © 1998 – 2026 7x. All rights reserved. Licensed under the GNU GPLv2+.