PHPDaemon\Servers\FlashPolicy\Connection::onRead PHP Method

onRead() public method

Called when new data received
public onRead ( ) : void
return void
    public function onRead()
    {
        if (false === ($pct = $this->readExact($this->lowMark))) {
            return;
            // not readed yet
        }
        if ($pct === "<policy-file-request/>") {
            if ($this->pool->policyData) {
                $this->write($p = $this->pool->policyData . "");
            } else {
                $this->write("<error/>");
            }
        }
        $this->finish();
    }
Connection