Property | Type | Description | |
---|---|---|---|
$description | string | The console command description. | |
$signature | string | The name and signature of the console command. | |
$type | string | The type of class being generated. |
Method | Description | |
---|---|---|
buildClass ( string $name ) : string | Build the model class with the given name. | |
createRelationshipFunction ( string &$stub, string $relationshipName, string $relationshipType, $argsString ) | Create the code for a model relationship | |
getDefaultNamespace ( string $rootNamespace ) : string | Get the default namespace for the class. | |
getStub ( ) : string | Get the stub file for the generator. | |
replaceFillable ( string &$stub, string $fillable ) | Replace the fillable for the given stub. | |
replacePrimaryKey ( string &$stub, string $primaryKey ) | Replace the primary key for the given stub. | |
replaceRelationshipPlaceholder ( &$stub ) | remove the relationships placeholder when it's no longer needed | |
replaceTable ( string &$stub, string $table ) | Replace the table for the given stub. |
protected buildClass ( string $name ) : string | ||
$name | string | |
return | string |
protected getDefaultNamespace ( string $rootNamespace ) : string | ||
$rootNamespace | string | |
return | string |
protected replaceFillable ( string &$stub, string $fillable ) | ||
$stub | string | |
$fillable | string |
protected replacePrimaryKey ( string &$stub, string $primaryKey ) | ||
$stub | string | |
$primaryKey | string |
protected replaceRelationshipPlaceholder ( &$stub ) | ||
$stub |
protected replaceTable ( string &$stub, string $table ) | ||
$stub | string | |
$table | string |
protected string $description | ||
return | string |
protected string $signature | ||
return | string |