public function processYield(Session $session, YieldMessage $msg)
    {

        $keepIndex = true;
        $details   = new \stdClass();

        $yieldOptions = $msg->getOptions();
        if (is_object($yieldOptions) && isset($yieldOptions->progress) && $yieldOptions->progress) {
            if ($this->isProgressive()) {
                $details->progress = true;
            } else {
                // not sure what to do here - just going to drop progress
                // if we are getting progress messages that the caller didn't ask for
                return $keepIndex;
            }
        } else {
            $this->getRegistration()->removeCall($this);
            $keepIndex = false;
        }

        $resultMessage = new ResultMessage(
            $this->getCallMessage()->getRequestId(),
            $details,
            $msg->getArguments(),
            $msg->getArgumentsKw()
        );

        $this->getCallerSession()->sendMessage($resultMessage);

        return $keepIndex;
    }
public function processYield(Session $session, YieldMessage $msg)
    {

        $keepIndex = true;
        $details   = new \stdClass();

        $yieldOptions = $msg->getOptions();
        if (is_object($yieldOptions) && isset($yieldOptions->progress) && $yieldOptions->progress) {
            if ($this->isProgressive()) {
                $details->progress = true;
            } else {
                // not sure what to do here - just going to drop progress
                // if we are getting progress messages that the caller didn't ask for
                return $keepIndex;
            }
        } else {
            $this->getRegistration()->removeCall($this);
            $keepIndex = false;
        }

        $resultMessage = new ResultMessage(
            $this->getCallMessage()->getRequestId(),
            $details,
            $msg->getArguments(),
            $msg->getArgumentsKw()
        );

        $this->getCallerSession()->sendMessage($resultMessage);

        return $keepIndex;
    }
public function processYield ( Session $ session , YieldMessage $ msg ) { $ keepIndex = true ; $ details = new \ stdClass ( ) ; $ yieldOptions = $ msg -> getOptions ( ) ; if ( is_object ( $ yieldOptions ) && isset ( $ yieldOptions -> progress ) && $ yieldOptions -> progress ) { if ( $ this -> isProgressive ( ) ) { $ details -> progress = true ; } else { // not sure what to do here - just going to drop progress // if we are getting progress messages that the caller didn't ask for return $ keepIndex ; } } else { $ this -> getRegistration ( ) -> removeCall ( $ this ) ; $ keepIndex = false ; } $ resultMessage = new ResultMessage ( $ this -> getCallMessage ( ) -> getRequestId ( ) , $ details , $ msg -> getArguments ( ) , $ msg -> getArgumentsKw ( ) ) ; $ this -> getCallerSession ( ) -> sendMessage ( $ resultMessage ) ; return $ keepIndex ; }
Process Yield message

@param \Thruway\Session $session
@param \Thruway\Message\YieldMessage $msg
@return bool if we need to keep the call indexed
Process Yield message