public function leave(Session $session)
    {
        // remove all registrations that belong to this session
        /* @var $registration \Thruway\Registration */
        foreach ($this->registrations as $i => $registration) {
            if ($registration->getSession() === $session) {
                // if this session is the callee on pending calls - error them out
                $registration->errorAllPendingCalls();
                array_splice($this->registrations, $i, 1);
            }
        }
    }
public function leave(Session $session)
    {
        // remove all registrations that belong to this session
        /* @var $registration \Thruway\Registration */
        foreach ($this->registrations as $i => $registration) {
            if ($registration->getSession() === $session) {
                // if this session is the callee on pending calls - error them out
                $registration->errorAllPendingCalls();
                array_splice($this->registrations, $i, 1);
            }
        }
    }
public function leave ( Session $ session ) { // remove all registrations that belong to this session /* @var $registration \Thruway\Registration */ foreach ( $ this -> registrations as $ i => $ registration ) { if ( $ registration -> getSession ( ) === $ session ) { // if this session is the callee on pending calls - error them out $ registration -> errorAllPendingCalls ( ) ; array_splice ( $ this -> registrations , $ i , 1 ) ; } } }
process session leave

@param \Thruway\Session $session
process session leave