* Returns a new [[FixedNumber]] which is the largest **integer** * that is less than or equal to %%this%%. * * The decimal component of the result will always be ``0``.
()
| 384 | * The decimal component of the result will always be ``0``. |
| 385 | */ |
| 386 | floor() { |
| 387 | let val = this.#val; |
| 388 | if (this.#val < BN_0) { |
| 389 | val -= this.#tens - BN_1; |
| 390 | } |
| 391 | val = (this.#val / this.#tens) * this.#tens; |
| 392 | return this.#checkValue(val, "floor"); |
| 393 | } |
| 394 | /** |
| 395 | * Returns a new [[FixedNumber]] which is the smallest **integer** |
| 396 | * that is greater than or equal to %%this%%. |
no test coverage detected