DatabaseInfo
in package
implements
ArrayAccess
Database information model class.
This class models the database information returned by the listDatabases command. It provides methods to access common database properties.
Tags
Table of Contents
Interfaces
- ArrayAccess
Properties
- $info : array<string|int, mixed>
Methods
- __construct() : mixed
- __debugInfo() : array<string|int, mixed>
- Return the database info as an array.
- getName() : string
- Return the database name.
- getSizeOnDisk() : int
- Return the databases size on disk (in bytes).
- isEmpty() : bool
- Return whether the database is empty.
- offsetExists() : bool
- Check whether a field exists in the database information.
- offsetGet() : mixed
- Return the field's value from the database information.
- offsetSet() : void
- Not supported.
- offsetUnset() : void
- Not supported.
Properties
$info
private
array<string|int, mixed>
$info
Methods
__construct()
public
__construct(array<string|int, mixed> $info) : mixed
Parameters
- $info : array<string|int, mixed>
-
Database info
__debugInfo()
Return the database info as an array.
public
__debugInfo() : array<string|int, mixed>
Tags
Return values
array<string|int, mixed>getName()
Return the database name.
public
getName() : string
Return values
stringgetSizeOnDisk()
Return the databases size on disk (in bytes).
public
getSizeOnDisk() : int
Return values
intisEmpty()
Return whether the database is empty.
public
isEmpty() : bool
Return values
booloffsetExists()
Check whether a field exists in the database information.
public
offsetExists(mixed $offset) : bool
Parameters
- $offset : mixed
Tags
Return values
booloffsetGet()
Return the field's value from the database information.
public
offsetGet(mixed $offset) : mixed
Parameters
- $offset : mixed
Tags
offsetSet()
Not supported.
public
offsetSet(mixed $offset, mixed $value) : void
Parameters
- $offset : mixed
- $value : mixed
Tags
offsetUnset()
Not supported.
public
offsetUnset(mixed $offset) : void
Parameters
- $offset : mixed