You are here

interface PrimitiveInterface in Zircon Profile 8.0

Same name and namespace in other branches
  1. 8 core/lib/Drupal/Core/TypedData/PrimitiveInterface.php \Drupal\Core\TypedData\PrimitiveInterface

Interface for primitive data.

Hierarchy

Expanded class hierarchy of PrimitiveInterface

All classes that implement PrimitiveInterface

Related topics

9 files declare their use of PrimitiveInterface
BinaryInterface.php in core/lib/Drupal/Core/TypedData/Type/BinaryInterface.php
Contains \Drupal\Core\TypedData\Type\BinaryInterface.
BooleanInterface.php in core/lib/Drupal/Core/TypedData/Type/BooleanInterface.php
Contains \Drupal\Core\TypedData\Type\BooleanInterface.
FloatInterface.php in core/lib/Drupal/Core/TypedData/Type/FloatInterface.php
Contains \Drupal\Core\TypedData\Type\FloatInterface.
IntegerInterface.php in core/lib/Drupal/Core/TypedData/Type/IntegerInterface.php
Contains \Drupal\Core\TypedData\Type\IntegerInterface.
PrimitiveTypeConstraintValidatorTest.php in core/tests/Drupal/Tests/Core/Validation/Plugin/Validation/Constraint/PrimitiveTypeConstraintValidatorTest.php
Contains \Drupal\Tests\Core\Validation\Plugin\Validation\Constraint\PrimitiveTypeConstraintValidatorTest.

... See full list

File

core/lib/Drupal/Core/TypedData/PrimitiveInterface.php, line 15
Contains \Drupal\Core\TypedData\PrimitiveInterface.

Namespace

Drupal\Core\TypedData
View source
interface PrimitiveInterface {

  /**
   * Gets the primitive data value.
   *
   * @return mixed
   */
  public function getValue();

  /**
   * Sets the primitive data value.
   *
   * @param mixed|null $value
   *   The value to set in the format as documented for the data type or NULL to
   *   unset the data value.
   */
  public function setValue($value);

  /**
   * Gets the primitive data value casted to the correct PHP type.
   *
   * @return mixed
   */
  public function getCastedValue();

}

Members

Namesort descending Modifiers Type Description Overrides
PrimitiveInterface::getCastedValue public function Gets the primitive data value casted to the correct PHP type. 5
PrimitiveInterface::getValue public function Gets the primitive data value.
PrimitiveInterface::setValue public function Sets the primitive data value.