/** @brief Constructs new search connector. * * All parameter values should have been provided by Antidot. * * @param $host [in] server hosting the required service. * @param $service [in] Antidot service (see @a AfsService). * @param $scheme [in] Scheme for the connection URL see * @ref uri_scheme (default: @a AFS_SCHEME_HTTP). * * @exception InvalidArgumentException invalid scheme parameter provided. */ public function __construct($host, AfsService $service, $scheme = AFS_SCHEME_HTTP, SAI_CurlInterface $curlConnector = null) { parent::__construct($host, $service, $scheme, $curlConnector); if ($scheme != AFS_SCHEME_HTTP) { throw new InvalidArgumentException('Search connector support only HTTP connection'); } }
/** @internal * @brief Overloads default implementation by setting json version to 1 in order to make it work with the API. * @param $parameters [in-out] List of parameters to update with standard parameters. */ protected function update_with_defaults(array &$parameters) { parent::update_with_defaults($parameters); $parameters['afs:output'] = 'json,1'; }