Bool represents a boolean condition of true or false.
Slots
- andSource
-
Bitwise "and" of this and b. Shortcut is a&b. Note boolean bitwise "and" does not short circuit like logical "and" (&& operator).
- defValSource
-
static Bool defVal
Default value is false.
- equalsSource
-
override Bool equals(Obj? obj)
Overrides sys::Obj.equals
Return if same boolean value.
- fromStrSource
-
static Bool? fromStr(Str s, Bool checked := true)
Parse a Str into a Bool. Valid formats are "true" or "false". If invalid format and checked is false return null, otherwise throw ParseErr.
- hashSource
-
override Int hash()
Overrides sys::Obj.hash
Return 1231 for true and 1237 for false.
- notSource
-
Bool not()
Return the logical not: if true return false; if false return true.
- orSource
-
Bitwise "or" of this and b. Shortcut is a|b. Note boolean bitwise "or" does not short circuit like logical "or" (|| operator).
-
new privateMake()
Private constructor.
- toCodeSource
-
Str toCode()
Get this Bool as a Fantom code literal - returns toStr.
- toLocaleSource
-
Str toLocale()
Return localized strings for "true" and "false" using current locale.
- toStrSource
-
override Str toStr()
Overrides sys::Obj.toStr
Return "true" or "false".
- xorSource
-
Bitwise "exclusive-or" of this and b. Shortcut is a^b. Note this operator does not short circuit like && or ||.