abstract class GeneratorCommand extends Command

Traits

ConfirmableTrait

Properties

protected Filesystem $files

The filesystem instance.

protected string $type

The type of class being generated.

protected array $stubs

A mapping of stub to generated file.

protected array $vars

An array of variables to use in stubs.

protected $destinationPath

Methods

void
__construct(Filesystem $files)

Create a new controller creator command instance.

prepareVars()

Prepare variables for stubs.

bool|null
handle()

Execute the console command.

buildStubs()

No description

buildStub($stubName, $className)

No description

getExtensionInput()

No description

string
makeDirectory(string $path)

Build the directory for the class if necessary.

getStubPath($stubName)

No description

getDestinationPath($className)

No description

parseString($stubContent)

No description

Details

at line 52
void __construct(Filesystem $files)

Create a new controller creator command instance.

Parameters

Filesystem $files

Return Value

void

at line 64
abstract protected prepareVars()

Prepare variables for stubs.

return @array

at line 71
bool|null handle()

Execute the console command.

Return Value

bool|null

at line 83
buildStubs()

No description

at line 90
buildStub($stubName, $className)

No description

Parameters

$stubName
$className

at line 115
protected getExtensionInput()

No description

at line 133
protected string makeDirectory(string $path)

Build the directory for the class if necessary.

Parameters

string $path

Return Value

string

at line 140
protected getStubPath($stubName)

No description

Parameters

$stubName

at line 148
protected getDestinationPath($className)

No description

Parameters

$className

at line 156
protected parseString($stubContent)

No description

Parameters

$stubContent