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

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

The behavior's {@link IBehavior::detach} method will be invoked. Behaviors may implement the function: public function dyDetachBehavior($name,$behavior[, $chain]) { } to be executed when detachBehavior is called. All attached behaviors are notified through dyDetachBehavior.
С версии: 3.2.3
public detachBehavior ( $name, $priority = false ) : Prado\Util\IBehavior
Результат Prado\Util\IBehavior the detached behavior. Null if the behavior does not exist.
    public function detachBehavior($name, $priority = false)
    {
        if ($this->_m != null && isset($this->_m[$name])) {
            $this->_m[$name]->detach($this);
            $behavior = $this->_m->itemAt($name);
            $this->_m->remove($name, $priority);
            $this->dyDetachBehavior($name, $behavior);
            return $behavior;
        }
    }