You are here

public static function OpignoTrueFalseFieldType::generateSampleValue in Opigno module 3.x

Same name and namespace in other branches
  1. 8 src/Plugin/Field/FieldType/OpignoTrueFalseFieldType.php \Drupal\opigno_module\Plugin\Field\FieldType\OpignoTrueFalseFieldType::generateSampleValue()

Generates placeholder field values.

Useful when populating site with placeholder content during site building or profiling.

Parameters

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

Return value

array An associative array of values.

Overrides FieldItemBase::generateSampleValue

File

src/Plugin/Field/FieldType/OpignoTrueFalseFieldType.php, line 64

Class

OpignoTrueFalseFieldType
Plugin implementation of the 'opigno_true_false_field' field type.

Namespace

Drupal\opigno_module\Plugin\Field\FieldType

Code

public static function generateSampleValue(FieldDefinitionInterface $field_definition) {
  $values['value'] = 0;
  return $values;
}