Documentation

LookupInResult extends Result
in package

Interface for results created by the lookupIn operation.

Table of Contents

$cas  : string|null
$error  : CouchbaseException|null
$fields  : array<string|int, mixed>
$id  : string
$transcoder  : Transcoder
cas()  : string|null
Returns the CAS value for the document
content()  : mixed
Returns the value located at the index specified
contentByPath()  : mixed
error()  : CouchbaseException|null
Returns the error (populated for multi-operations)
exists()  : bool
Returns whether the path at the index specified exists
existsByPath()  : bool
expiryTime()  : DateTimeInterface|null
Returns the document expiration time or null if the document does not expire.
id()  : string
Returns the ID of the document
path()  : string|null

Properties

$cas

private string|null $cas = null

Methods

cas()

Returns the CAS value for the document

public cas() : string|null
Tags
since
4.0.0
Return values
string|null

content()

Returns the value located at the index specified

public content(int $index) : mixed
Parameters
$index : int

the index to retrieve content from

Tags
throws
OutOfBoundsException
throws
PathNotFoundException
since
4.0.0
Return values
mixed

contentByPath()

public contentByPath(string $path) : mixed
Parameters
$path : string
Tags
throws
OutOfBoundsException
throws
PathNotFoundException
since
4.0.0
Return values
mixed

exists()

Returns whether the path at the index specified exists

public exists(int $index) : bool
Parameters
$index : int

the index to check for existence

Tags
since
4.0.0
Return values
bool

existsByPath()

public existsByPath(string $path) : bool
Parameters
$path : string
Tags
since
4.0.0
Return values
bool

expiryTime()

Returns the document expiration time or null if the document does not expire.

public expiryTime() : DateTimeInterface|null

Note, that this function will return expiry only when LookupInOptions had withExpiry set to true.

Return values
DateTimeInterface|null

id()

Returns the ID of the document

public id() : string
Tags
since
4.0.0
Return values
string

path()

public path(int $index) : string|null
Parameters
$index : int
Tags
since
4.0.0
Return values
string|null

        

Search results