View source

abstract thx.Rational(RationalImpl) from RationalImpl to RationalImpl

Available on all platforms

Class Fields

var zero(default,null):Rational

function create(num:BigInt, den:BigInt):Rational

function equals(self:Rational, that:Rational):Bool

function fromInt(i:Int):Rational

function fromString(s:String):Rational

function greater(self:Rational, that:Rational):Bool

function greaterEquals(self:Rational, that:Rational):Bool

function less(self:Rational, that:Rational):Bool

function lessEquals(self:Rational, that:Rational):Bool

function notEquals(self:Rational, that:Rational):Bool

Instance Fields

var den(get,null):BigInt

var num(get,null):BigInt

inline function new(num:Int, den:Int):Rational

function abs():Rational

function add(that:Rational):Rational

function compareTo(that:Rational):Int

function divide(that:Rational):Rational

function equalsTo(that:Rational):Bool

function greaterEqualsTo(that:Rational):Bool

function greaterThan(that:Rational):Bool

inline function isNegative():Bool

inline function isZero():Bool

function lessEqualsTo(that:Rational):Bool

function lessThan(that:Rational):Bool

function multiply(that:Rational):Rational

function negate():Rational

function notEqualsTo(that:Rational):Bool

function reciprocal():Rational

function subtract(that:Rational):Rational

function toDecimal(extraScale:Int = 0):Decimal

function toFloat():Float

function toString():String