This project does not seem to handle request data directly as such no vulnerable execution paths were found.
include
, or for example
via PHP's auto-loading mechanism.
These results are based on our legacy PHP analysis, consider migrating to our new PHP analysis engine instead. Learn more
1 | <?php |
||
2 | |||
3 | namespace Gueststream\PMS\IQWare\API; |
||
4 | |||
5 | class cInfoTmpl |
||
6 | { |
||
7 | |||
8 | /** |
||
9 | * @var boolean $IsMarried |
||
10 | */ |
||
11 | protected $IsMarried = null; |
||
12 | |||
13 | /** |
||
14 | * @var int $Sex |
||
15 | */ |
||
16 | protected $Sex = null; |
||
17 | |||
18 | /** |
||
19 | * @var \DateTime $DateOfBirth |
||
20 | */ |
||
21 | protected $DateOfBirth = null; |
||
22 | |||
23 | /** |
||
24 | * @var string $SocialSecurityNo |
||
25 | */ |
||
26 | protected $SocialSecurityNo = null; |
||
27 | |||
28 | /** |
||
29 | * @var string $PassportID |
||
30 | */ |
||
31 | protected $PassportID = null; |
||
32 | |||
33 | /** |
||
34 | * @var int $ID_Nationality |
||
35 | */ |
||
36 | protected $ID_Nationality = null; |
||
37 | |||
38 | /** |
||
39 | * @var string $PassportIssuingLocation |
||
40 | */ |
||
41 | protected $PassportIssuingLocation = null; |
||
42 | |||
43 | /** |
||
44 | * @var \DateTime $PassportExpireDate |
||
45 | */ |
||
46 | protected $PassportExpireDate = null; |
||
47 | |||
48 | /** |
||
49 | * @param boolean $IsMarried |
||
50 | * @param int $Sex |
||
51 | * @param \DateTime $DateOfBirth |
||
52 | * @param int $ID_Nationality |
||
53 | * @param \DateTime $PassportExpireDate |
||
54 | */ |
||
55 | View Code Duplication | public function __construct($IsMarried, $Sex, \DateTime $DateOfBirth, $ID_Nationality, \DateTime $PassportExpireDate) |
|
0 ignored issues
–
show
|
|||
56 | { |
||
57 | $this->IsMarried = $IsMarried; |
||
58 | $this->Sex = $Sex; |
||
59 | $this->DateOfBirth = $DateOfBirth->format(\DateTime::ATOM); |
||
0 ignored issues
–
show
It seems like
$DateOfBirth->format(\DateTime::ATOM) of type string is incompatible with the declared type object<DateTime> of property $DateOfBirth .
Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property. Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property.. ![]() |
|||
60 | $this->ID_Nationality = $ID_Nationality; |
||
61 | $this->PassportExpireDate = $PassportExpireDate->format(\DateTime::ATOM); |
||
0 ignored issues
–
show
It seems like
$PassportExpireDate->format(\DateTime::ATOM) of type string is incompatible with the declared type object<DateTime> of property $PassportExpireDate .
Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property. Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property.. ![]() |
|||
62 | } |
||
63 | |||
64 | /** |
||
65 | * @return boolean |
||
66 | */ |
||
67 | public function getIsMarried() |
||
68 | { |
||
69 | return $this->IsMarried; |
||
70 | } |
||
71 | |||
72 | /** |
||
73 | * @param boolean $IsMarried |
||
74 | * @return \Gueststream\PMS\IQWare\API\cInfoTmpl |
||
75 | */ |
||
76 | public function setIsMarried($IsMarried) |
||
77 | { |
||
78 | $this->IsMarried = $IsMarried; |
||
79 | return $this; |
||
80 | } |
||
81 | |||
82 | /** |
||
83 | * @return int |
||
84 | */ |
||
85 | public function getSex() |
||
86 | { |
||
87 | return $this->Sex; |
||
88 | } |
||
89 | |||
90 | /** |
||
91 | * @param int $Sex |
||
92 | * @return \Gueststream\PMS\IQWare\API\cInfoTmpl |
||
93 | */ |
||
94 | public function setSex($Sex) |
||
95 | { |
||
96 | $this->Sex = $Sex; |
||
97 | return $this; |
||
98 | } |
||
99 | |||
100 | /** |
||
101 | * @return \DateTime |
||
102 | */ |
||
103 | public function getDateOfBirth() |
||
104 | { |
||
105 | if ($this->DateOfBirth == null) { |
||
106 | return null; |
||
107 | } else { |
||
108 | try { |
||
109 | return new \DateTime($this->DateOfBirth); |
||
110 | } catch (\Exception $e) { |
||
111 | return false; |
||
112 | } |
||
113 | } |
||
114 | } |
||
115 | |||
116 | /** |
||
117 | * @param \DateTime $DateOfBirth |
||
118 | * @return \Gueststream\PMS\IQWare\API\cInfoTmpl |
||
119 | */ |
||
120 | public function setDateOfBirth(\DateTime $DateOfBirth) |
||
121 | { |
||
122 | $this->DateOfBirth = $DateOfBirth->format(\DateTime::ATOM); |
||
0 ignored issues
–
show
It seems like
$DateOfBirth->format(\DateTime::ATOM) of type string is incompatible with the declared type object<DateTime> of property $DateOfBirth .
Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property. Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property.. ![]() |
|||
123 | return $this; |
||
124 | } |
||
125 | |||
126 | /** |
||
127 | * @return string |
||
128 | */ |
||
129 | public function getSocialSecurityNo() |
||
130 | { |
||
131 | return $this->SocialSecurityNo; |
||
132 | } |
||
133 | |||
134 | /** |
||
135 | * @param string $SocialSecurityNo |
||
136 | * @return \Gueststream\PMS\IQWare\API\cInfoTmpl |
||
137 | */ |
||
138 | public function setSocialSecurityNo($SocialSecurityNo) |
||
139 | { |
||
140 | $this->SocialSecurityNo = $SocialSecurityNo; |
||
141 | return $this; |
||
142 | } |
||
143 | |||
144 | /** |
||
145 | * @return string |
||
146 | */ |
||
147 | public function getPassportID() |
||
148 | { |
||
149 | return $this->PassportID; |
||
150 | } |
||
151 | |||
152 | /** |
||
153 | * @param string $PassportID |
||
154 | * @return \Gueststream\PMS\IQWare\API\cInfoTmpl |
||
155 | */ |
||
156 | public function setPassportID($PassportID) |
||
157 | { |
||
158 | $this->PassportID = $PassportID; |
||
159 | return $this; |
||
160 | } |
||
161 | |||
162 | /** |
||
163 | * @return int |
||
164 | */ |
||
165 | public function getID_Nationality() |
||
166 | { |
||
167 | return $this->ID_Nationality; |
||
168 | } |
||
169 | |||
170 | /** |
||
171 | * @param int $ID_Nationality |
||
172 | * @return \Gueststream\PMS\IQWare\API\cInfoTmpl |
||
173 | */ |
||
174 | public function setID_Nationality($ID_Nationality) |
||
175 | { |
||
176 | $this->ID_Nationality = $ID_Nationality; |
||
177 | return $this; |
||
178 | } |
||
179 | |||
180 | /** |
||
181 | * @return string |
||
182 | */ |
||
183 | public function getPassportIssuingLocation() |
||
184 | { |
||
185 | return $this->PassportIssuingLocation; |
||
186 | } |
||
187 | |||
188 | /** |
||
189 | * @param string $PassportIssuingLocation |
||
190 | * @return \Gueststream\PMS\IQWare\API\cInfoTmpl |
||
191 | */ |
||
192 | public function setPassportIssuingLocation($PassportIssuingLocation) |
||
193 | { |
||
194 | $this->PassportIssuingLocation = $PassportIssuingLocation; |
||
195 | return $this; |
||
196 | } |
||
197 | |||
198 | /** |
||
199 | * @return \DateTime |
||
200 | */ |
||
201 | public function getPassportExpireDate() |
||
202 | { |
||
203 | if ($this->PassportExpireDate == null) { |
||
204 | return null; |
||
205 | } else { |
||
206 | try { |
||
207 | return new \DateTime($this->PassportExpireDate); |
||
208 | } catch (\Exception $e) { |
||
209 | return false; |
||
210 | } |
||
211 | } |
||
212 | } |
||
213 | |||
214 | /** |
||
215 | * @param \DateTime $PassportExpireDate |
||
216 | * @return \Gueststream\PMS\IQWare\API\cInfoTmpl |
||
217 | */ |
||
218 | public function setPassportExpireDate(\DateTime $PassportExpireDate) |
||
219 | { |
||
220 | $this->PassportExpireDate = $PassportExpireDate->format(\DateTime::ATOM); |
||
0 ignored issues
–
show
It seems like
$PassportExpireDate->format(\DateTime::ATOM) of type string is incompatible with the declared type object<DateTime> of property $PassportExpireDate .
Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property. Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property.. ![]() |
|||
221 | return $this; |
||
222 | } |
||
223 | } |
||
224 |
Duplicated code is one of the most pungent code smells. If you need to duplicate the same code in three or more different places, we strongly encourage you to look into extracting the code into a single class or operation.
You can also find more detailed suggestions in the “Code” section of your repository.