Decimal64#

class swordfish._swordfishcpp.Decimal64(data: int, scale: int = EXPARAM_DEFAULT)#
class swordfish._swordfishcpp.Decimal64(data: Decimal, scale: int = EXPARAM_DEFAULT)

Represents a Swordfish Decimal64 object.

Parameters:
  • data (int or Decimal) – The raw data representation or value of the Decimal64.

  • scale (int, optional) – The scale of the Decimal64. Defaults to EXPARAM_DEFAULT.

Examples

>>> import swordfish as sf
>>> sf.data.Decimal64(12345, 3)
Decimal64(12.345, scale=3)
>>> sf.data.Decimal64(3.14,2)
Decimal64(3.14, scale=2)
NULL_VALUE: Decimal64#