final class ServerApi implements Serializable, Serializable (View source)

Constants

V1

Methods

__construct(string $version, bool|null $strict = false, bool|null $deprecationErrors = false)

No description

static 
__set_state(array $properties)

No description

void
unserialize(string $data)

Constructs the object.

string|null
serialize()

String representation of object.

PackedArray
bsonSerialize()

Provides an array or document to serialize as BSON Called during serialization of the object to BSON. The method must return an array or stdClass.

Details

final __construct(string $version, bool|null $strict = false, bool|null $deprecationErrors = false)

No description

Parameters

string $version
bool|null $strict
bool|null $deprecationErrors

static __set_state(array $properties)

No description

Parameters

array $properties

final void unserialize(string $data)

Constructs the object.

Parameters

string $data

The string representation of the object.

Return Value

void

final string|null serialize()

String representation of object.

Return Value

string|null

The string representation of the object or null

Exceptions

Exception

final PackedArray bsonSerialize()

Provides an array or document to serialize as BSON Called during serialization of the object to BSON. The method must return an array or stdClass.

Root documents (e.g. a MongoDB\BSON\Serializable passed to MongoDB\BSON\fromPHP()) will always be serialized as a BSON document. For field values, associative arrays and stdClass instances will be serialized as a BSON document and sequential arrays (i.e. sequential, numeric indexes starting at 0) will be serialized as a BSON array.

Return Value

PackedArray