ArangoConfigTrait
The command to manage an ArangoDB database.
Table of Contents
Properties
- $database : string|null
- The ArangoDB database name.
- $endpoint : string|null
- The ArangoDB database endpoint.
- $password : string|null
- The ArangoDB database password.
- $username : string|null
- The ArangoDB database username.
Methods
- assertDatabase() : void
- Assert the database reference.
- assertEndpoint() : void
- Assert the passed-in endpoint reference.
- assertPassword() : void
- Assert the passed-in password reference.
- assertUsername() : void
- Assert the passed-in username reference.
- getDatabase() : string
- Returns the database name and asserts the existence of the value.
- getEndpoint() : string
- Returns the database endpoint and throws an error if not set.
- getPassword() : string
- Returns the database password and throws an error if not set.
- getUsername() : string
- Returns the database username and throws an error if not set.
- initializeArangoDB() : static
- Initialize the arangodb components.
Properties
$database
The ArangoDB database name.
protected
string|null
$database
= null
$endpoint
The ArangoDB database endpoint.
protected
string|null
$endpoint
= null
$password
The ArangoDB database password.
protected
string|null
$password
= null
$username
The ArangoDB database username.
protected
string|null
$username
= null
Methods
assertDatabase()
Assert the database reference.
public
assertDatabase(string|null $database) : void
Parameters
- $database : string|null
Tags
assertEndpoint()
Assert the passed-in endpoint reference.
public
assertEndpoint(string|null $endpoint) : void
Parameters
- $endpoint : string|null
Tags
assertPassword()
Assert the passed-in password reference.
public
assertPassword(string|null $password) : void
Parameters
- $password : string|null
Tags
assertUsername()
Assert the passed-in username reference.
public
assertUsername(string|null $username) : void
Parameters
- $username : string|null
Tags
getDatabase()
Returns the database name and asserts the existence of the value.
public
getDatabase() : string
Tags
Return values
stringgetEndpoint()
Returns the database endpoint and throws an error if not set.
public
getEndpoint() : string
Tags
Return values
stringgetPassword()
Returns the database password and throws an error if not set.
public
getPassword() : string
Tags
Return values
stringgetUsername()
Returns the database username and throws an error if not set.
public
getUsername() : string
Tags
Return values
stringinitializeArangoDB()
Initialize the arangodb components.
public
initializeArangoDB([array<string|int, mixed> $init = [] ]) : static
Parameters
- $init : array<string|int, mixed> = []