DataReferenceInterface.php 628 B

12345678910111213141516171819202122232425262728
  1. <?php
  2. namespace Drupal\Core\TypedData;
  3. /**
  4. * Interface for typed data references.
  5. *
  6. * @see \Drupal\Core\TypedData\DataReferenceDefinitionInterface
  7. */
  8. interface DataReferenceInterface {
  9. /**
  10. * Gets the referenced data.
  11. *
  12. * @return \Drupal\Core\TypedData\TypedDataInterface|null
  13. * The referenced typed data object, or NULL if the reference is unset.
  14. */
  15. public function getTarget();
  16. /**
  17. * Gets the identifier of the referenced data.
  18. *
  19. * @return int|string|null
  20. * The identifier of the referenced data, or NULL if the reference is unset.
  21. */
  22. public function getTargetIdentifier();
  23. }