Get request relationships if any attributes.
@param  object $parameters Request parameters
@return object
483695
protected static function getRequestRelationships($parameters)
    {
        //work with objects
        if (!is_object($parameters) && is_array($parameters)) {
            $parameters = (object) $parameters;
        }

        //Require data
        Request::requireParameters($parameters, ['data']);

        //Require data['relationships']
        if (isset($parameters->data->relationships)) {
            return (object) $parameters->data->relationships;
        } else {
            return new \stdClass();
        }
    }
324428
protected function createSentinelConnection($parameters)
    {
        if ($parameters instanceof NodeConnectionInterface) {
            return $parameters;
        }

        if (is_string($parameters)) {
            $parameters = Parameters::parse($parameters);
        }

        if (is_array($parameters)) {
            // We explicitly set "database" and "password" to null,
            // so that no AUTH and SELECT command is send to the sentinels.
            $parameters['database'] = null;
            $parameters['password'] = null;

            if (!isset($parameters['timeout'])) {
                $parameters['timeout'] = $this->sentinelTimeout;
            }
        }

        $connection = $this->connectionFactory->create($parameters);

        return $connection;
    }
1301346
public function getDependencies(array $parameters)
    {
    	$dependencies = array();

        foreach ($parameters as $parameter) {

            try {

                $dependency = $parameter->getClass();

            } catch (ReflectionException $e) {

                throw new ResolveException('Target <' . $parameter . '> could not be found.', $e->getCode(), $e);

            }

            if (is_null($dependency)) {
                // It 's a string or the like
                $dependencies[] = $this->resolveArgument($parameter);

            } else {

                $dependencies[] = $this->resolveClass($parameter);

            }
        }

        return (array) $dependencies;
    }
648941
protected function passGetScope(array $parameters): ?array
    {
        $scope = $this->passReadStringValue($parameters, 'scope');

        return empty($scope) === false ? explode(' ', $scope) : null;
    }
681210
protected function implicitGetScope(array $parameters): ?array
    {
        $scope = $this->implicitReadStringValue($parameters, 'scope');

        return empty($scope) === false ? explode(' ', $scope) : null;
    }
511136
public function get(array $params) {
        $this->_requireDataType($params);

        if (array_get($params, 'datatype') === self::METHOD_DICTIONARY) {
            return $this->getDictionary();
        } elseif (array_get($params, 'relatedType') && array_get($params, 'id')) {
            list($response, $httpCode) = $this->_getRelatedResults($params);
        } elseif (array_get($params, 'id')) {
            list($response, $httpCode) = $this->_getSingleResult($params);
        } else {
            list($response, $httpCode) = $this->_getIndex($params);
        }

        return $this->_formatResponse($response, $httpCode);
    }
1119442
public function addRelation($parameters)
    {
        $bag = $this->getParameter('relations');

        if (!($bag instanceof Bag)) {
            $bag = new Bag();
        }

        $bag->add(new Relation($parameters));

        return $this->setParameter('relations', $bag);
    }
329491
public function getBusinessesSearchResults($parameters = [])
    {
        $csvParams = ['attributes', 'categories', 'price'];

        $path = $this->appendParametersToUrl('/v3/businesses/search', $parameters, $csvParams);
        $request = $this->getRequest('GET', $path, $this->getDefaultHeaders());

        return $this->processRequest($request);
    }
290065
public function get($name, $parameters = null)
    {
        if (isset($this->_instances[$name])) {
            return $this->_instances[$name];
        }

        if (isset($this->_definitions[$name])) {
            $definition = $this->_definitions[$name];
        } else {
            return $this->getInstance($name, $parameters, $name);
        }

        $instance = $this->getInstance($definition, $parameters, $name);

        if (is_string($definition) || !isset($definition['shared']) || $definition['shared'] === true) {
            $this->_instances[$name] = $instance;
        }

        return $instance;
    }
509639
private function getSearchResults($parameters)
    {
        $searchRequest  = $this->requestBuilder->getSearchRequest($parameters);
        $searchResponse = $this->searchEngine->search($searchRequest);

        return $searchResponse;
    }
1133415
public static function findFirst($parameters = null)
    {
        $result = parent::findFirst($parameters);

        if ($result) {
            $customFields = $result->getAllCustomFields();

            if (is_array($customFields)) {
                //field the object
                foreach ($result->getAllCustomFields() as $key => $value) {
                    $result->{$key} = $value;
                }
            }
        }

        return $result;
    }
994718
public function getParameter( $parameter )
    {

        self::isParameterAllowed( $parameter );

        $value = $this->query(new Raw("SHOW {$parameter}"))->fetch( Result::FETCH_SINGLE );

        return ( $value === 'true' or $value === 'false' )
            ? \Bond\boolval( $value )
            : $value;

    }
177144
public function findWhereIn(array $parameters)
    {
        $q = $this->getQuery();

        foreach ($parameters as $name => $value) {
            $q->whereIn($name, $value);
        }

        return $q->get();
    }
514354
protected function getFilterCriteria(array $parameters)
    {
        /** @var \Netgen\EzPlatformSiteApi\API\Values\Content $content */
        $content = $parameters['content'];
        $tagIds = $this->extractTagIds($content);

        if (empty($tagIds)) {
            return new MatchNone();
        }

        $criteria = [];
        $criteria[] = new TagId($tagIds);

        if ($parameters['exclude_self']) {
            $criteria[] = new LogicalNot(new ContentId($content->id));
        }

        return $criteria;
    }
892682
public function mergeRequests(array $parameters = [])
    {
        $data = $this->client->mergeRequests()->all($this->id, $parameters);

        $mrs = array();
        foreach ($data as $mr) {
            $mrs[] = MergeRequest::fromArray($this->getClient(), $this, $mr);
        }

        return $mrs;
    }
61410
private function castObjectsAsArrays(array $parameters)
    {
        foreach ($parameters as $key => $value) {
            if (is_object($value)) {
                $value = (array) $value;
                $parameters[$key] = $value;
            }
            if (is_array($value)) {
                $parameters[$key] = $this->castObjectsAsArrays($value);
            }
        }
        return $parameters;
    }
609440
public function find($parameters): array
    {
        if ($parameters instanceof Query) {
            $parameters = $parameters->compileParameters();
        }

        $parameters = $this->formatParameters($parameters, self::ENPOINT_COLLECTION);
        $url = $this->urlCollection.'/';

        $results = $this->client->loadResource($url, $parameters['parameters']);

        $models = [];
        foreach ($results as $result) {
            $models[] = new Model($this->name, $result);
        }

        return $models;
    }