All Bundles
Int
Integer class represents an operating system long value
Derived from: Number
Operations
Abs
Returns the absolute value
function : Abs() ~ Int
Return
Type | Description |
---|
Int | absolute value |
Clamp
Returns a given value between an upper and lower bound
function : Clamp(min:Int, value:Int, max:Int) ~ Int
Parameters
Name | Type | Description |
---|
min | Int | minimal value |
value | Int | value between the min and max |
max | Int | maximum value |
Return
Type | Description |
---|
Int | min if vaule is less than main, max if max is less than value, otherwise the value |
Clear
Set all array elements to zero
function : Clear(a:Int[]) ~ Nil
Parameters
Name | Type | Description |
---|
a | Int[] | array |
Compare
Compares two values
function : native : Compare(l:Int, r:Int) ~ Int
Parameters
Name | Type | Description |
---|
l | Int | left compare object |
r | Int | right compare object |
Return
Type | Description |
---|
Int | 0 if equal, -1 if types differ, 1 if equal |
DoubleFactorial
Calculates the double factorial of the value
function : native : DoubleFactorial() ~ Int
Parameters
Return
Type | Description |
---|
Int | double factorial of the value |
Error
Prints error value
function : Error() ~ Nil
ErrorLine
Prints error value with newline
function : ErrorLine() ~ Nil
Factorial
Calculates the factorial of the value
function : native : Factorial() ~ Int
Parameters
Return
Type | Description |
---|
Int | factorial of the value |
IsNeg
Checks is a number is negative
function : IsNeg() ~ Bool
Return
Type | Description |
---|
Bool | true if negative, false otherwise |
Max
Returns the largest integer value
function : native : Max(l:Int, r:Int) ~ Int
Parameters
Name | Type | Description |
---|
l | Int | value to compare |
r | Int | value to compare |
Return
Type | Description |
---|
Int | largest integer value |
MaxSize
Returns the maximum size of an integer
function : MaxSize() ~ Int
Return
Type | Description |
---|
Int | maximum size of an integer |
Min
Returns the smallest integer value
function : native : Min(l:Int, r:Int) ~ Int
Parameters
Name | Type | Description |
---|
l | Int | value to compare |
r | Int | value to compare |
Return
Type | Description |
---|
Int | smallest integer value |
MinSize
Returns the minimum size of an integer
function : MinSize() ~ Int
Return
Type | Description |
---|
Int | maximum size of an integer |
Print
Prints value
function : Print() ~ Nil
PrintLine
Prints value with newline
function : PrintLine() ~ Nil
Random
Returns a random number within the given range
function : Random(min:Int, max:Int) ~ Int
Parameters
Name | Type | Description |
---|
min | Int | minimal value |
max | Int | max value |
Return
Type | Description |
---|
Int | random number within range |
Returns a random number between 0 and max value
function : Random(max:Int) ~ Int
Parameters
Name | Type | Description |
---|
max | Int | max value |
Return
Type | Description |
---|
Int | random number within range |
ToBinaryString
Returns the binary string value
function : native : ToBinaryString() ~ String
Return
Type | Description |
---|
String | binary string value |
ToByte
Returns the Byte value
function : ToByte() ~ Byte
Return
ToChar
Returns the Character value
function : ToChar() ~ Char
Return
ToCommaString
Returns a comma formatted string value
function : native : ToCommaString() ~ String
Return
Type | Description |
---|
String | string value |
ToFloat
Returns the Float value
function : ToFloat() ~ Float
Return
Type | Description |
---|
Float | value |
ToHexString
Returns the hex string value
function : native : ToHexString() ~ String
Return
Type | Description |
---|
String | hex string value |
ToString
Returns the string value
function : ToString() ~ String
Return
Type | Description |
---|
String | string value |
Returns a string representation of the value
function : native : ToString() ~ String
Return
Type | Description |
---|
String | string representation of the value |