From 4ada86876033fa171e2896d7e3d3c5645d8062db Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sun, 28 Apr 2024 14:46:47 +0200 Subject: Adding upstream version 0.10.0. Signed-off-by: Daniel Baumann --- library/Reporting/Schedule.php | 160 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 160 insertions(+) create mode 100644 library/Reporting/Schedule.php (limited to 'library/Reporting/Schedule.php') diff --git a/library/Reporting/Schedule.php b/library/Reporting/Schedule.php new file mode 100644 index 0000000..e0ffa9f --- /dev/null +++ b/library/Reporting/Schedule.php @@ -0,0 +1,160 @@ +id; + } + + /** + * @param int $id + * + * @return $this + */ + public function setId($id) + { + $this->id = $id; + + return $this; + } + + /** + * @return int + */ + public function getReportId() + { + return $this->reportId; + } + + /** + * @param int $id + * + * @return $this + */ + public function setReportId($id) + { + $this->reportId = $id; + + return $this; + } + + /** + * @return \DateTime + */ + public function getStart() + { + return $this->start; + } + + /** + * @param \DateTime $start + * + * @return $this + */ + public function setStart(\DateTime $start) + { + $this->start = $start; + + return $this; + } + + /** + * @return string + */ + public function getFrequency() + { + return $this->frequency; + } + + /** + * @param string $frequency + * + * @return $this + */ + public function setFrequency($frequency) + { + $this->frequency = $frequency; + + return $this; + } + + /** + * @return string + */ + public function getAction() + { + return $this->action; + } + + /** + * @param string $action + * + * @return $this + */ + public function setAction($action) + { + $this->action = $action; + + return $this; + } + + /** + * @return array + */ + public function getConfig() + { + return $this->config; + } + + /** + * @param array $config + * + * @return $this + */ + public function setConfig(array $config) + { + $this->config = $config; + + return $this; + } + + /** + * @return string + */ + public function getChecksum() + { + return \md5( + $this->getId() + . $this->getReportId() + . $this->getStart()->format('Y-m-d H:i:s') + . $this->getAction() + . $this->getFrequency() + . \json_encode($this->getConfig()) + ); + } +} -- cgit v1.2.3