PluginProbe ʕ •ᴥ•ʔ
Booking for Appointments and Events Calendar – Amelia / 2.0.2
Booking for Appointments and Events Calendar – Amelia v2.0.2
2.4.4 2.4.3 2.4.2 2.4.1 2.4 trunk 1.2.1 1.2.10 1.2.11 1.2.12 1.2.13 1.2.14 1.2.15 1.2.16 1.2.17 1.2.18 1.2.19 1.2.2 1.2.20 1.2.21 1.2.22 1.2.23 1.2.24 1.2.25 1.2.26 1.2.27 1.2.28 1.2.29 1.2.3 1.2.30 1.2.31 1.2.32 1.2.33 1.2.34 1.2.35 1.2.36 1.2.37 1.2.38 1.2.4 1.2.5 1.2.6 1.2.7 1.2.8 1.2.9 2.0 2.0.1 2.0.2 2.1 2.1.1 2.1.2 2.1.3 2.2 2.2.1 2.3
ameliabooking / src / Application / Commands / CommandResult.php
ameliabooking / src / Application / Commands Last commit date
Bookable 6 months ago Booking 5 months ago Calendar 6 months ago Entities 6 months ago Import 6 months ago Notification 6 months ago Payment 6 months ago QrCode 6 months ago Settings 6 months ago Square 6 months ago Stash 6 months ago Stats 6 months ago Test 6 months ago User 5 months ago WhatsNew 6 months ago Command.php 6 months ago CommandHandler.php 7 years ago CommandResult.php 1 year ago
CommandResult.php
142 lines
1 <?php
2
3 /**
4 * Class for standardizing command results
5 */
6
7 namespace AmeliaBooking\Application\Commands;
8
9 /**
10 * Class CommandResult
11 *
12 * @package AmeliaBooking\Application\Commands
13 */
14 class CommandResult
15 {
16 public const RESULT_SUCCESS = 'success';
17 public const RESULT_ERROR = 'error';
18 public const RESULT_CONFLICT = 'conflict';
19
20 private $data;
21 private $message;
22
23 private $result = self::RESULT_SUCCESS;
24
25 private $attachment = false;
26 private $file = null;
27 private $url;
28 private $dataInResponse = true;
29
30 /**
31 * @return string
32 */
33 public function getResult()
34 {
35 return $this->result;
36 }
37
38 /**
39 * @param string $result
40 */
41 public function setResult($result)
42 {
43 $this->result = $result;
44 }
45
46 /**
47 * @return mixed
48 */
49 public function getData()
50 {
51 return $this->data;
52 }
53
54 /**
55 * @param mixed $data
56 */
57 public function setData($data)
58 {
59 $this->data = $data;
60 }
61
62 /**
63 * @return mixed
64 */
65 public function getMessage()
66 {
67 return $this->message;
68 }
69
70 /**
71 * @param mixed $message
72 */
73 public function setMessage($message)
74 {
75 $this->message = $message;
76 }
77
78 /**
79 * @return mixed
80 */
81 public function hasAttachment()
82 {
83 return $this->attachment;
84 }
85
86 /**
87 * @param mixed $attachment
88 */
89 public function setAttachment($attachment)
90 {
91 $this->attachment = $attachment;
92 }
93
94 /**
95 * @return mixed
96 */
97 public function getUrl()
98 {
99 return $this->url;
100 }
101
102 /**
103 * @param mixed $url
104 */
105 public function setUrl($url)
106 {
107 $this->url = $url;
108 }
109
110 /**
111 * @param mixed $file
112 */
113 public function setFile($file)
114 {
115 $this->file = $file;
116 }
117
118 /**
119 * @return mixed
120 */
121 public function getFile()
122 {
123 return $this->file;
124 }
125
126 /**
127 * @return mixed
128 */
129 public function hasDataInResponse()
130 {
131 return $this->dataInResponse;
132 }
133
134 /**
135 * @param mixed $dataInResponse
136 */
137 public function setDataInResponse($dataInResponse)
138 {
139 $this->dataInResponse = $dataInResponse;
140 }
141 }
142