1 | <?php |
||
8 | class MetadataOptions extends Model implements \JsonSerializable |
||
9 | { |
||
10 | use JsonModel; |
||
11 | /** |
||
12 | * @var string |
||
13 | */ |
||
14 | public $url; |
||
15 | |||
16 | /** |
||
17 | * @var string |
||
18 | */ |
||
19 | protected $expiryInterval; |
||
20 | |||
21 | /** |
||
22 | * @var \DateTime |
||
23 | */ |
||
24 | protected $expiryDate; |
||
25 | |||
26 | /** |
||
27 | * @param string|null $expiry |
||
28 | * @return $this |
||
29 | */ |
||
30 | public function setExpiryInterval($expiry) |
||
47 | |||
48 | /** |
||
49 | * @return string |
||
50 | */ |
||
51 | public function getExpiryInterval() |
||
55 | |||
56 | /** |
||
57 | * @return \DateTime |
||
58 | */ |
||
59 | public function getExpiryDate() |
||
63 | |||
64 | /** |
||
65 | * @param string|null $expiry |
||
66 | * @return \DateTime |
||
67 | */ |
||
68 | public function setExpiryDate($expiry) |
||
78 | |||
79 | /** |
||
80 | * @return array |
||
81 | */ |
||
82 | public function jsonSerialize() |
||
94 | } |
||
95 |
In PHP, under loose comparison (like
==
, or!=
, orswitch
conditions), values of different types might be equal.For
string
values, the empty string''
is a special case, in particular the following results might be unexpected: