Documentation

Bootstrap
in package

The entry point for constructing a properly configured LotGD Game object.

Table of Contents

$annotationDirectories  : mixed
$game  : mixed
$libraryConfigurationManager  : LibraryConfigurationManager
$logger  : mixed
addDaenerysCommands()  : mixed
Adds Symfony/Console commands to the provided application from configured libraries.
createGame()  : Game
Create a new Game object, with all the necessary configuration.
extendModels()  : mixed
Runs the code to extend models.
getGame()  : Game
Starts the game kernel with the most important classes and returns the object.
connectToDatabase()  : PDO
Connects to a database using pdo.
createComposerManager()  : ComposerManager
Creates and returns an instance of ComposerManager.
createConfiguration()  : Configuration
Returns a configuration object reading from the file located at the path stored in $cwd/config/lotgd.yml.
createEntityManager()  : EntityManagerInterface
Creates the EntityManager using the pdo connection given in it's argument.
createLibraryConfigurationManager()  : LibraryConfigurationManager
Creates a library configuration manager.
createLogger()  : LoggerInterface
Returns a logger instance.
generateAnnotationDirectories()  : array<string|int, mixed>
Is used to get all directories used to generate annotations.

Properties

$annotationDirectories

private mixed $annotationDirectories = []

Methods

addDaenerysCommands()

Adds Symfony/Console commands to the provided application from configured libraries.

public addDaenerysCommands(Application $application) : mixed
Parameters
$application : Application
Return values
mixed

createGame()

Create a new Game object, with all the necessary configuration.

public static createGame([string|null $cwd = null ]) : Game
Parameters
$cwd : string|null = null
Return values
Game

The newly created Game object.

extendModels()

Runs the code to extend models.

public extendModels() : mixed
Return values
mixed

getGame()

Starts the game kernel with the most important classes and returns the object.

public getGame(string $cwd) : Game
Parameters
$cwd : string
Return values
Game

connectToDatabase()

Connects to a database using pdo.

protected connectToDatabase(string $dsn, string $user, string $password) : PDO
Parameters
$dsn : string
$user : string
$password : string
Return values
PDO

createComposerManager()

Creates and returns an instance of ComposerManager.

protected createComposerManager(string $cwd) : ComposerManager
Parameters
$cwd : string
Return values
ComposerManager

createEntityManager()

Creates the EntityManager using the pdo connection given in it's argument.

protected createEntityManager(PDO $pdo, Configuration $config) : EntityManagerInterface
Parameters
$pdo : PDO
$config : Configuration
Return values
EntityManagerInterface

createLogger()

Returns a logger instance.

protected createLogger(Configuration $config, string $name) : LoggerInterface
Parameters
$config : Configuration
$name : string
Return values
LoggerInterface

generateAnnotationDirectories()

Is used to get all directories used to generate annotations.

protected generateAnnotationDirectories() : array<string|int, mixed>
Return values
array<string|int, mixed>

Search results