function FieldTestItem::schema

Same name in other branches
  1. 9 core/modules/system/tests/modules/entity_test/src/Plugin/Field/FieldType/FieldTestItem.php \Drupal\entity_test\Plugin\Field\FieldType\FieldTestItem::schema()
  2. 10 core/modules/system/tests/modules/entity_test/src/Plugin/Field/FieldType/FieldTestItem.php \Drupal\entity_test\Plugin\Field\FieldType\FieldTestItem::schema()
  3. 11.x core/modules/system/tests/modules/entity_test/src/Plugin/Field/FieldType/FieldTestItem.php \Drupal\entity_test\Plugin\Field\FieldType\FieldTestItem::schema()

Overrides FieldItemInterface::schema

File

core/modules/system/tests/modules/entity_test/src/Plugin/Field/FieldType/FieldTestItem.php, line 47

Class

FieldTestItem
Defines the 'field_test' entity field type.

Namespace

Drupal\entity_test\Plugin\Field\FieldType

Code

public static function schema(FieldStorageDefinitionInterface $field_definition) {
    return [
        'columns' => [
            'value' => [
                'type' => 'varchar',
                'length' => 255,
            ],
        ],
    ];
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.