public function withUserInfo(string $username, $password = null): URI
    {
        $result = clone $this;
        $result->user = $username.((string) $password != '' ? ':'.(string) $password : '');

        return $result;
    }