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 |
Error
Prints error value
function : Error() ~ Nil
ErrorLine
Prints error value with newline
function : ErrorLine() ~ Nil
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 |
Pow
Calculates the power value
function : Pow(b:Int, r:Int) ~ Int
Parameters
Name | Type | Description |
---|
b | Int | power base |
r | Int | power to raise |
Return
Type | Description |
---|
Int | pseudo power value |
Calculates the power value
function : Pow(b:Int, r:Float) ~ Float
Parameters
Name | Type | Description |
---|
b | Int | power base |
r | Float | power to raise |
Return
Type | Description |
---|
Float | pseudo power value |
Print
Prints value
function : Print() ~ Nil
PrintLine
Prints value with newline
function : PrintLine() ~ Nil
Prints values
function : native : PrintLine(v:Int[]) ~ Nil
Parameters
Name | Type | Description |
---|
v | Int[] | values to print |
Prints values
function : native : PrintLine(v:Int[,]) ~ Nil
Parameters
Name | Type | Description |
---|
v | Int[,] | values to print |
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 |
Sqrt
Calculates the natural log value
function : Sqrt() ~ Int
Return
Type | Description |
---|
Int | natural log value |
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 |
Returns a string representation of the int array
function : ToString(v:Int[,]) ~ String
Parameters
Name | Type | Description |
---|
v | Int[,] | int array |
Return
Type | Description |
---|
String | string representation of the int array |