PHP Класс ElasticSearch\Transport\HTTP

Наследование: extends Base
Показать файл Открыть проект

Защищенные свойства (Protected)

Свойство Тип Описание
$ch resource curl handler which is needed for reusing existing http connection to the server

Открытые методы

Метод Описание
__construct ( $host = 'localhost', $port = 9200, $timeout = null )
delete ( mixed $id = false, array $options = [] ) : array Flush this index/type combination
deleteByQuery ( mixed $query, array $options = [] ) : array Search
getTimeout ( )
index ( array $document, mixed $id = false, array $options = [] ) : array Index a new document or update it if existing
request ( string | array $path, string $method = "GET", array | boolean $payload = false ) : array Perform a request against the given path/method/payload combination Example: $es->request('/_status');
search ( array | string $query, array $options = [] ) : array Search
setTimeout ( $timeout )
update ( array $partialDocument, mixed $id, array $options = [] ) : array Update a part of a document

Защищенные методы

Метод Описание
call ( string $url, string $method = "GET", array | boolean $payload = null ) : array Perform a http call against an url with an optional payload

Описание методов

__construct() публичный Метод

public __construct ( $host = 'localhost', $port = 9200, $timeout = null )

call() защищенный Метод

Perform a http call against an url with an optional payload
protected call ( string $url, string $method = "GET", array | boolean $payload = null ) : array
$url string
$method string (GET/POST/PUT/DELETE)
$payload array | boolean The document/instructions to pass along
Результат array

delete() публичный Метод

Flush this index/type combination
public delete ( mixed $id = false, array $options = [] ) : array
$id mixed Id of document to delete
$options array Parameters to pass to delete action
Результат array

deleteByQuery() публичный Метод

Search
public deleteByQuery ( mixed $query, array $options = [] ) : array
$query mixed
$options array Parameters to pass to delete action
Результат array

getTimeout() публичный Метод

public getTimeout ( )

index() публичный Метод

Index a new document or update it if existing
public index ( array $document, mixed $id = false, array $options = [] ) : array
$document array
$id mixed Optional
$options array
Результат array

request() публичный Метод

Perform a request against the given path/method/payload combination Example: $es->request('/_status');
public request ( string | array $path, string $method = "GET", array | boolean $payload = false ) : array
$path string | array
$method string
$payload array | boolean
Результат array

setTimeout() публичный Метод

public setTimeout ( $timeout )

update() публичный Метод

Update a part of a document
public update ( array $partialDocument, mixed $id, array $options = [] ) : array
$partialDocument array
$id mixed
$options array
Результат array

Описание свойств

$ch защищенное свойство

curl handler which is needed for reusing existing http connection to the server
protected resource $ch
Результат resource