raklib\protocol\Packet::getAddress PHP Метод

getAddress() защищенный Метод

protected getAddress ( &$addr, &$port, &$version = null )
    protected function getAddress(&$addr, &$port, &$version = null)
    {
        $version = $this->getByte();
        if ($version === 4) {
            $addr = (~$this->getByte() & 0xff) . "." . (~$this->getByte() & 0xff) . "." . (~$this->getByte() & 0xff) . "." . (~$this->getByte() & 0xff);
            $port = $this->getShort(false);
        } else {
            //TODO: IPv6
        }
    }