private function parseScheme(array $locationParts): void
    {
        if (! $this->isValidScheme($locationParts['scheme'])) {
            throw new InvalidArgumentException(
                sprintf('"%s" is not a valid scheme.', $locationParts['scheme'])
            );
        }

        $this->scheme = strtolower($locationParts['scheme']);
    }