Prado\TComponent::__construct PHP Метод

__construct() публичный Метод

This function installs all class behaviors in a class hierarchy from the deepest subclass through each parent to the top most class, TComponent.
public __construct ( )
    public function __construct()
    {
        if ($this->getAutoGlobalListen()) {
            $this->listen();
        }
        $classes = array_reverse($this->getClassHierarchy(true));
        foreach ($classes as $class) {
            if (isset(self::$_um[$class])) {
                $this->attachBehaviors(self::$_um[$class]);
            }
        }
    }

Usage Example

Пример #1
0
 /**
  * Constructor.
  * @param TStyle style to copy from
  */
 public function __construct($style = null)
 {
     parent::__construct();
     if ($style !== null) {
         $this->copyFrom($style);
     }
 }