public function getAuthenticationUrl(
        $action,
        \FACTFinder\Util\Parameters $parameters
    ) {
        $this->ensureChannelParameter($parameters);

        $c = $this->configuration;
        if ($c->isAdvancedAuthenticationType())
            return $this->getAdvancedAuthenticationUrl($action, $parameters);
        else if ($c->isSimpleAuthenticationType())
            return $this->getSimpleAuthenticationUrl($action, $parameters);
        else if ($c->isHttpAuthenticationType())
            return $this->getHttpAuthenticationUrl($action, $parameters);
        else
            throw new \Exception('Invalid authentication type configured.');
    }