rsc3/doc-schelp/HelpSource/Classes/Boolean.schelp

65 lines
1.7 KiB
Text

class::Boolean
summary:: abstract class whose instances represent a logical value
categories::Core
related:: Reference/Control-Structures
description::
Boolean is the superclass of link::Classes/True:: and link::Classes/False:: which are the concrete realizations.
In code True and False are represented by the literal values code::true:: and code::false::.
instanceMethods::
private:: while
private:: storeOn
private:: trace
private:: printOn
private:: archiveAsCompileString
method::xor
returns:: the exclusive or of the receiver and another Boolean.
method::and
If the receiver is true then answer the evaluation of function.
If the receiver is false then function is not evaluated and the message answers false.
method::or
If the receiver is false then answer the evaluation of function.
If the receiver is true then function is not evaluated and the message answers true.
method::&&
returns:: true if the receiver is true and aBoolean is true.
method::||
returns:: true if either the receiver is true or aBoolean is true.
method::nand
returns:: true unless both the operands are true (Sheffer stroke)
method::not
returns:: true if the receiver is false, and false if the receiver is true.
method::if
If the receiver is true, answer the evaluation of the trueFunc. If the receiver is false, answer the evaluation of the falseFunc.
method::asInteger
method::binaryValue
returns:: 1 if the receiver is true, and 0 if the receiver is false.
method::asBoolean
method::booleanValue
Returns:: The receiver. The same message is understood by link::Classes/SimpleNumber:: and can be used to convert it to boolean.
method::keywordWarnings
turn on/off warnings if a keyword argument is not found