This API documentation is for Ballerina 1.2.0. View API documentation for the latest release.

Module : lang.decimal

Module Overview

This module provides lang library operations on decimal values defined by the language specification 2020R1.

Functions

abs

IEEE abs operation.

ceiling

Rounds a decimal up to the closest integral value.

floor

Rounds a decimal down to the closest integral value.

fromString

Return the decimal value represented by s.

max

Maximum of one or more decimal values.

min

Minimum of one or more decimal values

round

Round a decimal to the closest integral value.

sum

Sum of zero or more decimal values.