@@ 165-174 (lines=10) @@ | ||
162 | * @param float $float |
|
163 | * @return self |
|
164 | */ |
|
165 | public function setFloat($float) |
|
166 | { |
|
167 | $msg = null; |
|
168 | if (null != $float && $float !== floatval($float)) { |
|
169 | $msg = "Float must be floating-point"; |
|
170 | throw new \InvalidArgumentException($msg); |
|
171 | } |
|
172 | $this->float = $float; |
|
173 | return $this; |
|
174 | } |
|
175 | ||
176 | /** |
|
177 | * Gets as guid |
|
@@ 219-228 (lines=10) @@ | ||
216 | * @param float $decimal |
|
217 | * @return self |
|
218 | */ |
|
219 | public function setDecimal($decimal) |
|
220 | { |
|
221 | $msg = null; |
|
222 | if (null != $decimal && $decimal !== floatval($decimal)) { |
|
223 | $msg = "Decimal must be decimal"; |
|
224 | throw new \InvalidArgumentException($msg); |
|
225 | } |
|
226 | $this->decimal = $decimal; |
|
227 | return $this; |
|
228 | } |
|
229 | ||
230 | /** |
|
231 | * Gets as bool |