WordPress\AiClientDependencies\Nyholm\Psr7

Uri::withPort │ public │ WP 1.0

Метод класса: Uri{}

Хуков нет.

Возвращает

static.

Использование

$Uri = new Uri();
$Uri->withPort( $port ): UriInterface;
$port(обязательный)
.

Код Uri::withPort() WP 7.1.2

public function withPort($port): UriInterface
{
    if ($this->port === $port = $this->filterPort($port)) {
        return $this;
    }
    $new = clone $this;
    $new->port = $port;
    return $new;
}