Zend_Navigation_Container
AbstractContainer class for ZendNavigationPage classes.
Sorts the page index according to page order
Return type: | void |
---|
Notifies container that the order of pages are updated
Return type: | void |
---|
Adds a page to the container
This method will inject the container as the given page’s parent by calling {@link PageAbstractPage::setParent()}.
Parameters: | PageAbstractPage|array|Traversable – page to add |
---|---|
Return type: | AbstractContainer fluent interface, returns self |
Throws : | ExceptionInvalidArgumentException if page is invalid |
Adds several pages at once
Parameters: | array|Traversable|AbstractContainer – pages to add |
---|---|
Return type: | AbstractContainer fluent interface, returns self |
Throws : | ExceptionInvalidArgumentException if $pages is not array, Traversable or AbstractContainer |
Sets pages this container should have, removing existing pages
Parameters: | array – pages to set |
---|---|
Return type: | AbstractContainer fluent interface, returns self |
Returns pages in the container
Return type: | array array of PageAbstractPage instances |
---|
Removes the given page from the container
Parameters: | PageAbstractPage|int – page to remove, either a page instance or a specific page order |
---|---|
Return type: | bool whether the removal was successful |
Removes all pages in container
Return type: | AbstractContainer fluent interface, returns self |
---|
Checks if the container has the given page
Parameters: |
|
---|---|
Return type: | bool whether page is in container |
Returns true if container contains any pages
Return type: | bool whether container has any pages |
---|
Returns a child page matching $property == $value, or null if not found
Parameters: |
|
---|---|
Return type: | PageAbstractPage|null matching page or null |
Returns all child pages matching $property == $value, or an empty array if no pages are found
Parameters: |
|
---|---|
Return type: | array array containing only PageAbstractPage instances |
Returns page(s) matching $property == $value
Parameters: |
|
---|---|
Return type: | PageAbstractPage|null matching page or null |
Magic overload: Proxy calls to finder methods
Examples of finder calls: <code> // METHOD // SAME AS $nav->findByLabel(‘foo’); // $nav->findOneBy(‘label’, ‘foo’); $nav->findOneByLabel(‘foo’); // $nav->findOneBy(‘label’, ‘foo’); $nav->findAllByClass(‘foo’); // $nav->findAllBy(‘class’, ‘foo’); </code>
Parameters: |
|
---|---|
Throws ExceptionBadMethodCallException: | |
if method does not exist |
Returns an array representation of all pages in container
Return type: | array |
---|
Returns current page
Implements RecursiveIterator interface.
Return type: | PageAbstractPage current page or null |
---|---|
Throws : | ExceptionOutOfBoundsException if the index is invalid |
Returns hash code of current page
Implements RecursiveIterator interface.
Return type: | string hash code of current page |
---|
Moves index pointer to next page in the container
Implements RecursiveIterator interface.
Return type: | void |
---|
Sets index pointer to first page in the container
Implements RecursiveIterator interface.
Return type: | void |
---|
Checks if container index is valid
Implements RecursiveIterator interface.
Return type: | bool |
---|
Proxy to hasPages()
Implements RecursiveIterator interface.
Return type: | bool whether container has any pages |
---|
Returns the child container.
Implements RecursiveIterator interface.
Return type: | PageAbstractPage|null |
---|
Returns number of pages in container
Implements Countable interface.
Return type: | int number of pages in the container |
---|
Full-text doc search.
Enter search terms or a module, class or function name.