Performs the retrieval of the resource

@param string $key
@param string $id
@param array|null $options
@return array
3614
protected function performGet(string $key, string $id, array $options = null)
    {
        return $this->flow->send(
            'get',
            $this->endpoint . '/' . ($options['method'] ?? $this->verbsMap['get'] ?? 'get'),
            [$key => $id]
        );
    }
503449
public static function retrieve( $resource, $id )
    {
        $instance = self::resolveClass( $resource, $id );
        $instance->refresh( $resource );
        return $instance;
    }
788664
protected function parseData($data, array $options, $key = null)
    {
        $architect = new Architect();

        return $architect->parseData($data, $options['modes'], $key);
    }
194638
protected function deleteByKey($id, string $key = null): int
    {
        $key = empty($key) ? $this->repository->getModel()->getKeyName() : $key;

        $row = 0;

        try {
            $row = $this->queryRelate->whereIn($key, (array) $id)->getQuery()->delete();
        } catch (\RuntimeException $exception) {
            throw new ResourceDeleteException($exception->getMessage(), $exception->getCode(), $exception);
        } finally {
            $this->resetQueryRelate();
        }

        return $row;
    }
963024
public static function reverse($id, $options = null)
    {
        $url = static::classUrl().'/'.$id.'/reverse';
        $params = [];
        return static::_directRequest('post', $url, $params, $options);
    }
1050795
public function getTaskStatus($id, $options=array()){

        $data = array();
        
        $data['id'] = $id;

        $data = array_merge($data, $options);

        return $this->request($this->taskStatusUrl, $data);
    }
627926
static public function fromArray($id, array $array=null, callable $callback, array $options=[]){
		$form = static::createInstance($id, $callback);
		$form->parseOptions($options);
		$form->createResource($array);
		$form->render();
	}
1022066
public function fetchRole($id, array $options = [])
    {
        $data = [
            '_id' => $id
        ];

        $response = $this->kuzzle->query(
            $this->buildQueryArgs('getRole'),
            $data,
            $options
        );

        return new Role($this, $response['result']['_id'], $response['result']['_source'], $response['result']['_meta']);
    }
1097560
public static function load($id, $options = [], $fetchOptions = [])
    {
        $options = ['conditions' => [static::definition()->key() => $id]] + $options;
        return static::find($options)->first($fetchOptions);
    }
1198665
public static function retrieve($userId, $id, $options = null)
    {
        return self::_userBasedRetrieve($userId, $id, $options);
    }
1152613
public function postEvent($id, $event, $options = [ ]) {
        $data = $options;
        $data['id'] = $id;
        $data['event'] = $event;

        $result = $this->apiPost('event', $data);
        return $result;
    }
105608
public function fetch($sql, array $params, array $options = array())
    {
        $sth = $this->run($sql, $params);
        $result = $sth->fetch(PDO::FETCH_ASSOC);

        $this->prepareResult($result, $options);
        return empty($result) ? array() : (array) $result;
    }
113913
public function childCount($id, array $options = [])
	{
		$options['for'] = $id;

		$query = $this->findChildren($this->_table->find(), $options);

		return $query->count();
	}
1171446
public function getWithFilter(int $id, array $keys): array
    {
        return $this->parent->performAPICallWithJsonResponse(
            'get',
            '/series/'.$id.'/filter',
            [
                'query' => ['keys' => join(',', $keys)]
            ]
        );
    }
583976
protected function parseKey($key, $options = [])
    {
        $key = trim($key);
        if (strpos($key, '$.') && false === strpos($key, '(')) {
            // JSON字段支持
            list($field, $name) = explode('$.', $key);
            $key                = 'json_extract(' . $field . ', \'$.' . $name . '\')';
        } elseif (strpos($key, '.') && !preg_match('/[,\'\"\(\)`\s]/', $key)) {
            list($table, $key) = explode('.', $key, 2);
            if ('__TABLE__' == $table) {
                $table = $this->query->getTable();
            }
            if (isset($options['alias'][$table])) {
                $table = $options['alias'][$table];
            }
        }
        if (!preg_match('/[,\'\"\*\(\)`.\s]/', $key)) {
            $key = '`' . $key . '`';
        }
        if (isset($table)) {
            if (strpos($table, '.')) {
                $table = str_replace('.', '`.`', $table);
            }
            $key = '`' . $table . '`.' . $key;
        }
        return $key;
    }
199288
public static function find( $table, $id, $key = null, $handler = null ) 
	{
		return Query::select( $table )->find( $id, $key, $handler );
	}
503857
public static function find($id = null, array $options = array())
	{
		$timestamp_end_name = static::temporal_property('end_column');
		$max_timestamp = static::temporal_property('max_timestamp');

		switch ($id)
		{
			case 'all':
			case 'first':
			case 'last':
				break;
			default:
				$id = (array) $id;
				$count = 0;
				foreach(static::getNonTimestampPks() as $key)
				{
					$options['where'][] = array($key, $id[$count]);

					$count++;
				}
				break;
		}

		$options['where'][] = array($timestamp_end_name, $max_timestamp);

		static::enable_id_only_primary_key();
		$result = parent::find($id, $options);
		static::disable_id_only_primary_key();

		return $result;
	}