Kraken\Channel\Channel::handlePushAsync PHP Method

handlePushAsync() protected method

protected handlePushAsync ( $name, $message, $flags = Channel::MODE_DEFAULT )
    protected function handlePushAsync($name, $message, $flags = Channel::MODE_DEFAULT)
    {
        if ($message->getType() === '') {
            $message->setType(Channel::TYPE_SND);
        }
        if ($message->getDestination() === '') {
            $message->setDestination($name);
        }
        $status = $this->model->unicast($name, $this->encoder->with($message)->encode(), $flags);
        if ($status) {
            $this->resolveOrRejectResponse($message->getPid(), $message->getException());
            $this->emit('output', [$name, $message]);
        }
        return $status;
    }