Title.php 969 B

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566
  1. <?php
  2. namespace PhpOffice\PhpSpreadsheet\Chart;
  3. class Title
  4. {
  5. /**
  6. * Title Caption.
  7. *
  8. * @var string
  9. */
  10. private $caption;
  11. /**
  12. * Title Layout.
  13. *
  14. * @var Layout
  15. */
  16. private $layout;
  17. /**
  18. * Create a new Title.
  19. *
  20. * @param null|mixed $caption
  21. */
  22. public function __construct($caption = null, ?Layout $layout = null)
  23. {
  24. $this->caption = $caption;
  25. $this->layout = $layout;
  26. }
  27. /**
  28. * Get caption.
  29. *
  30. * @return string
  31. */
  32. public function getCaption()
  33. {
  34. return $this->caption;
  35. }
  36. /**
  37. * Set caption.
  38. *
  39. * @param string $caption
  40. *
  41. * @return $this
  42. */
  43. public function setCaption($caption)
  44. {
  45. $this->caption = $caption;
  46. return $this;
  47. }
  48. /**
  49. * Get Layout.
  50. *
  51. * @return Layout
  52. */
  53. public function getLayout()
  54. {
  55. return $this->layout;
  56. }
  57. }