new Boolean()
Represents a baja:Boolean
in BajaScript.
Augments Boolean
to be a baja:Boolean
.
Extends
Members
-
<static> DEFAULT
-
Default
Boolean
instance.
Methods
-
<static> getBooleanFromIBoolean()
-
Return a
Boolean
from a BIBoolean.Returns:
- Type
- Boolean
-
<static> make(b)
-
Make a
Boolean
.Parameters:
Name Type Description b
Boolean a JavaScript
Boolean
value.Returns:
- Type
- Boolean
-
decodeFromString(str)
-
Decode a
Boolean
from aString
.Parameters:
Name Type Description str
String an encoded
Boolean
.Returns:
- Type
- Boolean
-
encodeToString()
-
Encode the
Boolean
(itself) to aString
.Returns:
- Type
- String
-
equals(obj)
-
Equality test.
Parameters:
Name Type Description obj
Returns:
- Type
- Boolean
-
equivalent(obj)
-
Equivalence test.
Used to compare if two objects have equivalent state, but might not want to
return true for equals since it it has implied semantics for many
operations. The default implementation returns the result of {@link
Boolean#equals}.Parameters:
Name Type Description obj
Returns:
- Type
- Boolean
-
getBoolean()
-
Return the
Boolean
(itself).Returns:
- Type
- Boolean
-
getDataTypeSymbol()
-
Return the data type symbol.
Used for encoding this data type (primarily for facets).
Returns:
- Type
- String
-
getDisplayTag(obj)
-
Asynchronously get the display tag of this
Enum
value.Parameters:
Name Type Description obj
Object the Object Literal used to specify the method's
arguments.Properties
Name Type Argument Description facets
baja.Facets | Object <optional>
facets used to specify the true
and false text. The argument can also be an Object Literal.Properties
Name Type Argument Description trueText
String <optional>
a baja Format string. If
Boolean
is true, function will return baja.Format(obj.facets.trueText) instead of
'true'.falseText
String <optional>
a baja Format string. If
Boolean
is false, function will return baja.Format(obj.facets.falseText) instead of
'false'.ok
function <optional>
(Deprecated: use Promise) ok callback called
with String value as argument.fail
function <optional>
(Deprecated: use Promise) optional fail
callback.Returns:
- Type
- Promise.<String>
-
getEnum()
-
Return the
Boolean
(itself).Returns:
- Type
- Boolean
-
getIcon()
-
Return the Object's Icon.
Returns:
- Type
- baja.Icon
-
getOrdinal()
-
Return the
Enum
ordinal.Returns:
- Type
- Number
-
getRange()
-
Return the
Enum Range
.Returns:
- Type
- baja.EnumRange
-
getTag()
-
Return the
String
identifier of thisEnum
value.Returns:
- Type
- String
-
isActive()
-
Return true if this
Enum
value is considered to be in an active state.Returns:
- Type
- Boolean
-
make(b)
-
Make a
Boolean
.Parameters:
Name Type Description b
Boolean a JavaScript
Boolean
value.Returns:
- Type
- Boolean
-
newCopy()
-
New Copy.
Returns:
- Type
- Boolean