rounded64

rounded64(): Integer64;

The rounded64 method of the Decimal primitive type returns a signed 64-bit integer containing the rounded value of the receiver.

The following code fragment shows the use of the rounded64 method.

write (6.4).Decimal.rounded64;   // outputs 6 [0,1,2,3,4 are rounded down]
write (6.5).Decimal.rounded64;   // outputs 7 [5,6,7,8,9 are rounded up]

write (-6.4).Decimal.rounded64;  // outputs -6 [0,1,2,3,4 are rounded up]
write (-6.5).Decimal.rounded64;  // outputs -7 [5,6,7,8,9 are rounded down]