Retrieves the clan, who matches the given id
@param string $param the clan tag
@return Clan a Clan object, containing the searched clan
9325
private function _clanById(string $param): Clan
    {
        $curlClient = curl_init(
            self::BASE_URL .
            self::CLANS_URL .
            '/' .
            \urlencode($param)
        );
        curl_setopt($curlClient, CURLOPT_HTTPHEADER, $this->_curlHeader);
        curl_setopt($curlClient, CURLOPT_RETURNTRANSFER, true);
        $result = json_decode(curl_exec($curlClient), true);
        return Clan::create($result);
    }
432681
public function get($param) {
        global $CFG, $USER;
        $this->cleanup($this->ttl);
        $filename = 'u'.$USER->id.'_'.md5(serialize($param));
        if(file_exists($this->dir.$filename)) {
            $lasttime = filemtime($this->dir.$filename);
            if (time()-$lasttime > $this->ttl) {
                return false;
            } else {
                $fp = fopen($this->dir.$filename, 'r');
                $size = filesize($this->dir.$filename);
                $content = fread($fp, $size);
                return unserialize($content);
            }
        }
        return false;
    }
903526
public static function getInstance($param = null): Cache
    {
        if (!self::$instance instanceof self) {
            $param = json_decode(json_encode($param), true);

            self::$instance = new Cache(
                $param[self::IDX_ADAPTER_NAME],
                $param[self::IDX_PARAMETERS] ?? []
            );
        }

        return self::$instance;
    }
922872
public function search($params)
    {
        $query = $this->finder->getUserQuery();

        $dataProvider = new ActiveDataProvider([
            'query' => $query,
            'sort' => ['defaultOrder' => ['created_at' => SORT_DESC]],
        ]);

        if (!($this->load($params) && $this->validate())) {
            return $dataProvider;
        }

        $modelClass = $query->modelClass;
        $table_name = $modelClass::tableName();

        if ($this->created_at !== null) {
            $date = strtotime($this->created_at);
            $query->andFilterWhere(['between', $table_name . '.created_at', $date, $date + 3600 * 24]);
        }

        $query->andFilterWhere(['like', $table_name . '.username', $this->username])
              ->andFilterWhere(['like', $table_name . '.email', $this->email])
              ->andFilterWhere([$table_name . '.id' => $this->id])
              ->andFilterWhere([$table_name . '.registration_ip' => $this->registration_ip]);

        return $dataProvider;
    }
1372911
public function get(AbstractModel $model, $param = null)
    {
        $this->modelStorage->rewind();

        foreach ($this->modelStorage as $storedModel) {
            if ($storedModel === $model) {
                return $model;
            }
        }

        return null;
    }
591343
protected function getQueryParam($param, $url) {
    $keys = [];
    $parse = parse_url($url);
    parse_str($parse['query'], $keys);

    if (isset($keys[$param])) {
      return $keys[$param];
    }

    return FALSE;
  }
359539
protected function getParamDefaultLocal($param)
    {
        $param = $this->getParameter($param);
        if (!is_null($param))
            return $param;

        return $this->getLocal($param);
    }
1332208
public function findBy(AbstractModel $model, $param = [])
    {
        if ($this->useCache && $this->modelCache) {
            if (($ret = $this->modelCache->get($model, $param))) {
                return $ret;
            }
        }

        list($query, $param, $type) = $this->queryBuilder->generateSelectForModel($model, $param);

        $result = $this->executeQuery(
            $model,
            $this->prepare(
                $query,
                $this->prepareParam($param)
            )
        );

        if ($this->useCache && $this->modelCache) {
            $this->modelCache->set($model, $param);
        }

        return $result;
    }
572891
public function getResponseParam($param) {
    if (isset($this->notifyParams[$param])) {
      return $this->notifyParams[$param];
    }
    return NULL;
  }
781894
public function getCreator($id, array $params = array())
    {
        return $this->get($this->getPath().'/'.rawurlencode($id).'/memberCreator', $params);
    }
641557
public function findOneBy($modelName, $param = [])
    {
        if (!class_exists($modelName, true)) {
            return null;
        }

        $collection = $this->getCollectionBy(
            $this->getModelConfiguration($modelName)
        );
        $result = $collection->findOne($param);

        if (!$result) {
            return null;
        }

        // clone is much faster than new [speed over memory!]
        if (!$this->modelPrototypeStorage[$modelName]) {
            $this->modelTemplateStorage[$modelName] = new $modelName();
        }

        return $this->fillModel($this->modelTemplateStorage[$modelName], $result);
    }
1292318
public static function find($id, array $params = [])
    {
        $instance = new static([], static::getParentID());

        return $instance->request($instance->getEndpoint(), 'find', [$id, $params]);
    }
280695
protected function getParam($param)
    {
        $params = $this->getParams();
        if (! isset($params[$param])) {
            return false;
        }
        return $params[$param];
    }
434180
public static function paramFilter($param) {
        if (empty($param)) {
            $param = '';
        }

        if (is_array($param)) {
            foreach ($param as $key => $value) {
                $param[$key] = String::urlSafetyFilter($value);
            }
        }

        if (is_string($param)) {
            $param = String::urlSafetyFilter($param);
        }

        return $param;
    }
671281
function nodeIdByName( $params )
    {
        $node = $this->nodeByName( $params );

        $id = false;
        if( is_object( $node ) )
            $id = $node->attribute( 'node_id' );

        return $id;
    }
1193401
public function load($param = null)
    {

        $configSet = $this->_getConfigSet();

        if (0 === count($configSet)) {
            // set default config set for the default execution
            $configSet = [
                realpath(
                    "{$this->config_path}/{$this->get(self::HIERARCHY_PLACEHOLDER_INDEX)}"
                    . (string) self::CONFIG_DELIMITER
                    . (string) self::FILE_EXTENSION
                )
            ];
            $this->set('config_set', $configSet);
        }

        return $this->populateEngine(
            $this->checkConfigForDefaultConfig($configSet)
        );
    }
1129567
public function getParam(string $param)
    {
        if (! empty($this->match['params'][$param])) {
            return $this->match['params'][$param];
        }
    }