final class MigrationGenerator implements GeneratorInterface

Generator for dist/database/migrations/*.php.

Constants

INTENT

The left padding for the body of the generated.

Methods

void
run(bool $force = false)

Run the generator logic and save it to a file.

merging(array $engines)

Set merger engines.

static void
make(Table $table, string|null $namespace = null, string|null $destination = null)

Create a instance.

Details

at line 48
void run(bool $force = false)

Run the generator logic and save it to a file.

Parameters

bool $force

Whether to force the generation of the generator file or not.

Return Value

void

at line 84
MigrationGenerator merging(array $engines)

Set merger engines.

Parameters

array $engines

An array of merger engines.

Return Value

MigrationGenerator

The method returns the current instance that enables methods chaining.

at line 94
static void make(Table $table, string|null $namespace = null, string|null $destination = null)

Create a instance.

Parameters

Table $table
string|null $namespace

The namespace to be applied to the class

string|null $destination

The path to the dist folder

Return Value

void