GravityKit\GravityMigrate\Schema\PipelineContext
What a conversion needs to know about the migration running it.
Converting a form needs nothing from outside the form itself. The two exceptions are about the run: which platform this is, so a warning can name it, and whether this source form has been migrated here before, so a repeat attempt can say so instead of quietly making a duplicate.
An implementation may run on either side of a migration, so it cannot assume an importer exists.
Since: %ver%
Source: src/Schema/PipelineContext.php:21
Details
- Kind:
interface - Namespace:
GravityKit\GravityMigrate\Schema
Methods
| Method | Description |
|---|---|
get_slug() | The platform this side of the migration belongs to. |
get_tracked_import_id() | The form this source form was migrated into before, if it was. |
Method Reference
get_slug()
public function get_slug(): string
The platform this side of the migration belongs to.
Returns
string
Since: %ver%
Source: src/Schema/PipelineContext.php:30
get_tracked_import_id()
public function get_tracked_import_id( $source_form_id ): ?int
The form this source form was migrated into before, if it was.
Parameters
| Name | Type | Default | Description |
|---|---|---|---|
$source_form_id | int | string | Id of the form on the source platform. |
Returns
int|null— Target form id, or null when this is the first time.
Since: %ver%
Source: src/Schema/PipelineContext.php:41