CalendarObjectRestoredEvent.php 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879
  1. <?php
  2. declare(strict_types=1);
  3. /**
  4. * SPDX-FileCopyrightText: 2021 Nextcloud GmbH and Nextcloud contributors
  5. * SPDX-License-Identifier: AGPL-3.0-or-later
  6. */
  7. namespace OCA\DAV\Events;
  8. use OCP\EventDispatcher\Event;
  9. /**
  10. * @since 22.0.0
  11. */
  12. class CalendarObjectRestoredEvent extends Event {
  13. /** @var int */
  14. private $calendarId;
  15. /** @var array */
  16. private $calendarData;
  17. /** @var array */
  18. private $shares;
  19. /** @var array */
  20. private $objectData;
  21. /**
  22. * @param int $calendarId
  23. * @param array $calendarData
  24. * @param array $shares
  25. * @param array $objectData
  26. * @since 22.0.0
  27. */
  28. public function __construct(int $calendarId,
  29. array $calendarData,
  30. array $shares,
  31. array $objectData) {
  32. parent::__construct();
  33. $this->calendarId = $calendarId;
  34. $this->calendarData = $calendarData;
  35. $this->shares = $shares;
  36. $this->objectData = $objectData;
  37. }
  38. /**
  39. * @return int
  40. * @since 22.0.0
  41. */
  42. public function getCalendarId(): int {
  43. return $this->calendarId;
  44. }
  45. /**
  46. * @return array
  47. * @since 22.0.0
  48. */
  49. public function getCalendarData(): array {
  50. return $this->calendarData;
  51. }
  52. /**
  53. * @return array
  54. * @since 22.0.0
  55. */
  56. public function getShares(): array {
  57. return $this->shares;
  58. }
  59. /**
  60. * @return array
  61. * @since 22.0.0
  62. */
  63. public function getObjectData(): array {
  64. return $this->objectData;
  65. }
  66. }