AnnotationBase.php 938 B

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566
  1. <?php
  2. namespace Drupal\Component\Annotation;
  3. /**
  4. * Provides a base class for classed annotations.
  5. */
  6. abstract class AnnotationBase implements AnnotationInterface {
  7. /**
  8. * The annotated class ID.
  9. *
  10. * @var string
  11. */
  12. public $id;
  13. /**
  14. * The class used for this annotated class.
  15. *
  16. * @var string
  17. */
  18. protected $class;
  19. /**
  20. * The provider of the annotated class.
  21. *
  22. * @var string
  23. */
  24. protected $provider;
  25. /**
  26. * {@inheritdoc}
  27. */
  28. public function getProvider() {
  29. return $this->provider;
  30. }
  31. /**
  32. * {@inheritdoc}
  33. */
  34. public function setProvider($provider) {
  35. $this->provider = $provider;
  36. }
  37. /**
  38. * {@inheritdoc}
  39. */
  40. public function getId() {
  41. return $this->id;
  42. }
  43. /**
  44. * {@inheritdoc}
  45. */
  46. public function getClass() {
  47. return $this->class;
  48. }
  49. /**
  50. * {@inheritdoc}
  51. */
  52. public function setClass($class) {
  53. $this->class = $class;
  54. }
  55. }