You are here

protected static function Dimensions::prepareTarget in Commerce Feeds 8

Prepares a target definition.

Parameters

\Drupal\Core\Field\FieldDefinitionInterface $field_definition: The field definition.

Return value

\Drupal\feeds\FieldTargetDefinition The target definition.

Overrides FieldTargetBase::prepareTarget

File

src/Feeds/Target/Dimensions.php, line 25

Class

Dimensions
Defines a physical_dimensions field mapper.

Namespace

Drupal\commerce_feeds\Feeds\Target

Code

protected static function prepareTarget(FieldDefinitionInterface $field_definition) {
  return FieldTargetDefinition::createFromFieldDefinition($field_definition)
    ->addProperty('length')
    ->addProperty('width')
    ->addProperty('height');
}