PHP 클래스 ElasticSearch\Transport\Base

(c) Raymond Julin For the full copyright and license information, please view the LICENSE file that was distributed with this source code.
파일 보기 프로젝트 열기: nervetattoo/elasticsearch 1 사용 예제들

보호된 프로퍼티들

프로퍼티 타입 설명
$host string What host to connect to for server
$index string ElasticSearch index
$port integer Port to connect on
$type string ElasticSearch document type

공개 메소드들

메소드 설명
__construct ( string $host, integer $port ) Default constructor, just set host and port
delete ( mixed $id = false ) Delete a document by its id
deleteByQuery ( mixed $query, array $options = [] ) : array Search
index ( array | object $document, mixed $id = false, array $options = [] ) Method for indexing a new document
request ( string | array $path, string $method = "GET", array | boolean $payload = false ) Perform a request against the given path/method/payload combination Example: $es->request('/_status');
search ( array | string $query ) Perform a search based on query
setIndex ( string $index ) Set what index to act against
setType ( string $type ) Set what document types to act against
update ( array | object $partialDocument, mixed $id, array $options = [] ) Method for updating a document

보호된 메소드들

메소드 설명
buildUrl ( array | boolean $path = false, array $options = [] ) : string Build a callable url

메소드 상세

__construct() 공개 메소드

Default constructor, just set host and port
public __construct ( string $host, integer $port )
$host string
$port integer

buildUrl() 보호된 메소드

Build a callable url
protected buildUrl ( array | boolean $path = false, array $options = [] ) : string
$path array | boolean
$options array Query parameter options to pass
리턴 string

delete() 추상적인 공개 메소드

Delete a document by its id
abstract public delete ( mixed $id = false )
$id mixed

deleteByQuery() 공개 메소드

Search
public deleteByQuery ( mixed $query, array $options = [] ) : array
$query mixed String or array to use as criteria for delete
$options array Parameters to pass to delete action
리턴 array

index() 추상적인 공개 메소드

Method for indexing a new document
abstract public index ( array | object $document, mixed $id = false, array $options = [] )
$document array | object
$id mixed
$options array

request() 추상적인 공개 메소드

Perform a request against the given path/method/payload combination Example: $es->request('/_status');
abstract public request ( string | array $path, string $method = "GET", array | boolean $payload = false )
$path string | array
$method string
$payload array | boolean

setIndex() 공개 메소드

Set what index to act against
public setIndex ( string $index )
$index string

setType() 공개 메소드

Set what document types to act against
public setType ( string $type )
$type string

update() 추상적인 공개 메소드

Method for updating a document
abstract public update ( array | object $partialDocument, mixed $id, array $options = [] )
$partialDocument array | object
$id mixed
$options array

프로퍼티 상세

$host 보호되어 있는 프로퍼티

What host to connect to for server
protected string $host
리턴 string

$index 보호되어 있는 프로퍼티

ElasticSearch index
protected string $index
리턴 string

$port 보호되어 있는 프로퍼티

Port to connect on
protected int $port
리턴 integer

$type 보호되어 있는 프로퍼티

ElasticSearch document type
protected string $type
리턴 string