PhpExt : [ class tree ] [ index ] [ all elements ]

Source for file ButtonCollection.php

Documentation is available at ButtonCollection.php

  1. <?php
  2. /**
  3.  * PHP-Ext Library
  4.  * http://php-ext.googlecode.com
  5.  * @author Sergei Walter <sergeiw[at]gmail[dot]com>
  6.  * @copyright 2008 Sergei Walter
  7.  * @license http://www.gnu.org/licenses/lgpl.html
  8.  * @link http://php-ext.googlecode.com
  9.  * 
  10.  *  Reference for Ext JS: http://extjs.com
  11.  * 
  12.  */
  13. /**
  14.  * @see PhpExt_AbstractCollection
  15.  */
  16. include_once 'PhpExt/AbstractCollection.php';
  17.  
  18.  
  19. /**
  20.  * Provides functionality to manage a PhpExt_Component Collection
  21.  * 
  22.  * @package PhpExt
  23.  */
  24. {
  25.     
  26.     public function __construct($collection array()) {
  27.         parent::__construct($collection);        
  28.         $this->setForceArray(true);    
  29.     }
  30.     
  31.     /**
  32.      * Adds a PhpExt_Button to the Collection
  33.      *
  34.      * @param PhpExt_Button $object 
  35.      * @param string $name 
  36.      * @return int the index of the new element
  37.      */
  38.     public function add(PhpExt_Button $object$name null{
  39.         return $this->addObject($object$name);
  40.     }
  41.     
  42.     /**
  43.      * Gets the Component with the key specified by $name
  44.      *
  45.      * @param string $name 
  46.      * @return PhpExt_Button 
  47.      */
  48.     public function getByName($name{
  49.         return $this->getObjectByName($name);
  50.     }
  51.     
  52.     /**
  53.      * Gets the Component in the specified index
  54.      *
  55.      * @param int $index 
  56.      * @return PhpExt_Button 
  57.      */
  58.     public function &getByIndex($index{
  59.         return $this->getObjectByIndex($index);
  60.     }
  61.             
  62. }

Documentation generated on Fri, 08 Aug 2008 15:50:49 -0500 by phpDocumentor 1.4.0