FileMapping
API reference › Scaffold › Manifest › FileMapping
Represents one provider file to apply: its source, destination, write mode and merge strategy.
Properties
Section titled “Properties”| Property | Type | Description | Defined by |
|---|---|---|---|
$destination readonly constructor | string | Destination path relative to the project root, using forward slashes. | FileMapping |
$mergeStrategy readonly constructor | PHPForge\| | Merge strategy declared by the manifest merge map for the append mode, or null to resolve it from the destination basename. Default: null. | FileMapping |
$mode readonly constructor | FileMode | Write mode applied to the destination. | FileMapping |
$providerName readonly constructor | string | Composer package name of the provider. | FileMapping |
$providerPath readonly constructor | string | Absolute path to the provider root on disk. | FileMapping |
$source readonly constructor | string | Source path relative to the provider root, using forward slashes. | FileMapping |
Methods
Section titled “Methods”| Method | Description | Defined by |
|---|---|---|
__construct() | Creates a provider file mapping. | FileMapping |
Method details
Section titled “Method details”__construct()
Section titled “__construct() ”public function __construct(string $destination, string $source, PHPForge\Scaffold\Manifest\FileMode $mode, string $providerName, string $providerPath, PHPForge\Scaffold\Merge\MergeStrategyKind|null $mergeStrategy = null)Creates a provider file mapping.
Parameters
| Parameter | Type | Description |
|---|---|---|
$destination | string | Destination path relative to the project root, using forward slashes. |
$source | string | Source path relative to the provider root, using forward slashes. |
$mode | FileMode | Write mode applied to the destination. |
$providerName | string | Composer package name of the provider. |
$providerPath | string | Absolute path to the provider root on disk. |
$mergeStrategy | PHPForge\| | Merge strategy declared by the manifest merge map for the append mode, or null to resolve it from the destination basename. |