3 namespace Drupal\Core\TypedData\Plugin\DataType;
5 use Drupal\Core\TypedData\PrimitiveBase;
6 use Drupal\Core\TypedData\Type\StringInterface;
9 * The string data type.
11 * The plain value of a string is a regular PHP string. For setting the value
12 * any PHP variable that casts to a string may be passed.
16 * label = @Translation("String")
19 class StringData extends PrimitiveBase implements StringInterface {
24 public function getCastedValue() {
25 return $this->getString();