1 | <?php |
||
18 | trait ComparisonTrait |
||
19 | { |
||
20 | /** |
||
21 | * @return int |
||
22 | */ |
||
23 | public abstract function getValue(); |
||
24 | |||
25 | /** |
||
26 | * @param ValueObjectInterface $object |
||
27 | * @return bool |
||
28 | */ |
||
29 | 3 | public function isGreaterThan(ValueObjectInterface $object) |
|
33 | |||
34 | /** |
||
35 | * @param ValueObjectInterface $object |
||
36 | * @return bool |
||
37 | */ |
||
38 | 3 | public function isLessThan(ValueObjectInterface $object) |
|
42 | |||
43 | /** |
||
44 | * @param ValueObjectInterface $object |
||
45 | * @return bool |
||
46 | */ |
||
47 | 3 | public function isGreaterThanOrEqualTo(ValueObjectInterface $object) |
|
51 | |||
52 | /** |
||
53 | * @param ValueObjectInterface $object |
||
54 | * @return bool |
||
55 | */ |
||
56 | 3 | public function isLessThanOrEqualTo(ValueObjectInterface $object) |
|
60 | |||
61 | /** |
||
62 | * @param ValueObjectInterface $object |
||
63 | * @return int |
||
64 | */ |
||
65 | 1 | public function spaceship(ValueObjectInterface $object) |
|
75 | } |
||
76 |