CreateModule
Less than 1 minute
CreateModule
Class CreateModule
Console module for creating new application objects such as views, controllers, layouts, and models. Provides a command-line interface to generate files from templates.
Methods
configure
Configures the module by adding the 'create' command and its arguments.
protected configure(): voidexecute
Executes the 'create' command to generate a new application object.
protected execute(Input $input, Output $output): intParameters
| Parameter | Type | Description |
|---|---|---|
$input | Input | The input interface for command arguments. |
$output | Output | The output interface for writing messages. |
create
Creates a new application object file from a template.
private create(string $type, string $name, string $targetDir = '.'): boolParameters
| Parameter | Type | Description |
|---|---|---|
$type | string | The type of object to create (layout, view, controller, controller_basic, controller_action, model). |
$name | string | The name of the object to create. |
$targetDir | string | The target directory for the new file. Defaults to current directory. |
Generated by Hazaar API Doc Generator on Sun, 01 Mar 2026 09:22:27 +0000