Generate the identifier url.

@throws InvalidArgumentException

@return string[]
15399
private function generateIdentifiersUrl(array $identifiers, string $resourceClass): array
    {
        if (0 === \count($identifiers)) {
            throw new InvalidArgumentException(sprintf(
                'No identifiers defined for resource of type "%s"',
                $resourceClass
            ));
        }

        if (1 === \count($identifiers)) {
            return [rawurlencode((string) reset($identifiers))];
        }

        foreach ($identifiers as $name => $value) {
            $identifiers[$name] = sprintf('%s=%s', $name, $value);
        }

        return array_values($identifiers);
    }
502325
public function generateLinks() {
        return '<' . $this->generateUrl($this->getNextPageQueryCriteria()) . '>; rel="next",'
        . '<' . $this->generateUrl($this->getLastPageQueryCriteria()) . '>; rel="last",'
        . '<' . $this->generateUrl($this->getFirstPageQueryCriteria()) . '>; rel="first",'
        . '<' . $this->generateUrl($this->getPreviousPageQueryCriteria()) . '>; rel="prev"';
    }
965219
public function getArguments()
    {
        if ($this->arguments === null) {
            $this->arguments = UriHelper::parseQueryIntoArguments($this);
        }
        return $this->arguments;
    }
36621
public function parseUrl($url) : array
    {
        $url = (string) $url;

        $parsedUrl = $this->doParseUrl($url);

        if ($parsedUrl === []) {
            throw new InvalidArgumentException(sprintf('Invalid url %s', $url));
        }

        $parsedUrl = array_merge(self::$defaultParts, $parsedUrl);

        if (isset($parsedUrl['host'])) {
            $parsedUrl['canonical'] = implode('.', array_reverse(explode('.', $parsedUrl['host']))) . ($parsedUrl['path'] ?? '') . (isset($parsedUrl['query']) ? '?' . $parsedUrl['query'] : '');

            $parsedUrl['resource'] = $parsedUrl['path'] ?? '';

            if (isset($parsedUrl['query'])) {
                $parsedUrl['resource'] .= '?' . $parsedUrl['query'];
            }
        }

        return $parsedUrl;
    }
1178905
public function getCandidateIds(): array
    {
        $candidateIds = [];

        foreach ($this->candidates as $candidate) {
            $candidateIds[] = $candidate->getId();
        }

        return $candidateIds;
    }
925293
public function getUrlfriendlyInitials()
    {
        $urlFriendlyInitials = $this->convertToUrlFriendlyString($this->getInitials());

        $urlFriendlyInitials = mb_substr($urlFriendlyInitials, 0, $this->length);

        return $urlFriendlyInitials;
    }
560626
public function getQueryUrl()
    {

        $uri = Zend_Gdata_Gapps::APPS_BASE_FEED_URI;
        $uri .= Zend_Gdata_Gapps::APPS_GROUP_PATH;
        $uri .= '/' . $this->_domain;
        if ($this->_groupId !== null) {
            $uri .= '/' . $this->_groupId;
        } else {
            require_once 'Zend/Gdata/App/InvalidArgumentException.php';
            throw new Zend_Gdata_App_InvalidArgumentException(
                    'groupId must not be null');
        }

        $uri .= '/member';

        if ($this->_memberId !== null) {
            $uri .= '/' . $this->_memberId;
        }
        $uri .= $this->getQueryString();
        return $uri;
    }
855441
protected function identifiersToArray(): array
    {
        $data = [];

        foreach ($this->getIdentifiers() as $identifier)
        {
            $data[] = $identifier->toArray();
        }

        return $data;
    }
1310057
private function getUserUuid() {
        if ($this->uuid === null) {

            $path = $this->getRequest()->getUri()->getPath();
            $uuid = substr($path, strrpos($path, '/')+1);
            if (strlen($uuid) === 32 && preg_match('/[a-z0-9]/', $uuid)) {
                $this->uuid = $uuid;
            }
            else {
                throw new \InvalidArgumentException('The uuid cannot be empty.');
            }
        }
        return $this->uuid;
    }
1255538
public String[] getUrl() {
        String[] valueDestination = new String[ url.size() ];
        this.url.getValue(valueDestination);
        return valueDestination;
    }
556137
private function getLocaleRegexUrls()
    {
        $urls = array();
        foreach ($this->getLocales() as $locale) {
            if ($locale->hasACustomUrl()) {
                $urls[] =  preg_quote($locale->getUrl(), '/');
            }
        }
        return $urls;
    }
1147578
public function base()
    {
        if (!$this->validate()) {
            throw new \InvalidArgumentException("Invalid URI: $this->uri");
        }
        $parts = [
            'scheme' => parse_url($this->uri, PHP_URL_SCHEME),
            'host' => parse_url($this->uri, PHP_URL_HOST),
        ];
        $parts['port'] = is_int($port = parse_url($this->uri, PHP_URL_PORT)) ? $port : getservbyname($parts['scheme'], 'tcp');
        return strtolower($parts['scheme'] . '://' . $parts['host'] . ':' . $parts['port']);
    }
256814
protected function getArguments()
    {
        $strings = array();

        foreach ($this->getParameterInfo() as $name => $parameter) {
            $string = '';

            if ($parameter['hint_type']) {
                $string .= $parameter['hint_type'] . ' ';
            }

            $string .= '$' . $name;

            if (isset($parameter['default'])) {
                if ($parameter['default'] == '~~NOT RESOLVED~~') {
                    $parameter['default'] = '';
                }
                $string .= ' = ' . $parameter['default'];
            }

            $strings[] = $string;
        }

        return implode(', ', $strings);
    }
494667
public function url()
    {
        $parameters = [
            'id'    => $this->userToken->getUserId(),
            'token' => $this->userToken->getToken(),
        ];

        $url = $this->urlGenerator->generate(
            'reset-password',
            $parameters,
            UrlGenerator::ABSOLUTE_URL
        );

        return $url;
    }
1298296
public function getMalUrls(): array
    {
        if (!$this->imageLinks) {
            $this->crawler->filterXPath('//a/img')->each(
                function (Crawler $c) {
                    $node = $c->parents()->first()->getNode(0);
                    /** @noinspection NullPointerExceptionInspection */
                    $node->parentNode->removeChild($node);
                }
            );
        }

        $xpath = sprintf('//a[contains(@href, "%s/%s")]', Constants::BASE_URL, $this->type);

        return $this->crawler
            ->filterXPath($xpath)
            ->each(
                function (Crawler $c) {
                    return (new MalUrlParser($c))->getModel();
                }
            );
    }
925208
protected function get_url_params() {
        $params = array(
            'id'         => $this->cm->id,
            'mode'       => $this->mode,
            'attempts'   => $this->attempts,
            'onlygraded' => $this->onlygraded,
        );

        if ($this->states) {
            $params['states'] = implode('-', $this->states);
        }

        if (groups_get_activity_groupmode($this->cm, $this->course)) {
            $params['group'] = $this->group;
        }
        return $params;
    }
174435
public function getUrl()
    {
        if (!$this->url) {
            throw new InvalidUrlException();
        }

        $url = $this->url;

        if (! parse_url($this->url, PHP_URL_SCHEME)) {
            $url = $this->getProtocol().$url;
        }

        return $url;
    }