jruby/docs BETA
Navigation
org.jruby.ir.operands 57
C Array
C Bignum
C Boolean
C BuiltinClass
C ChilledString
C ClosureLocalVariable
C Complex
C CurrentScope
I DepthCloneable
C DynamicSymbol
C Filename
C Fixnum
C Float
C FrozenString
C GlobalVariable
C Hash
C IRException
C ImmutableLiteral
C Integer
C Label
C LocalVariable
C MutableString
C Nil
C NullBlock
C Operand
E OperandType
C Range
C Rational
C Reference
C Regexp
C SValue
C Scope
C ScopeModule
C Self
C Splat
C StandardError
I StringLiteral
I Stringable
C Symbol
C SymbolProc
C TemporaryBooleanVariable
C TemporaryClosureVariable
C TemporaryCurrentModuleVariable
C TemporaryFixnumVariable
C TemporaryFloatVariable
C TemporaryIntVariable
C TemporaryLocalReplacementVariable
C TemporaryLocalVariable
C TemporaryVariable
E TemporaryVariableType
C UnboxedBoolean
C UnboxedFixnum
C UnboxedFloat
C UndefinedValue
C UnexecutableNil
C Variable
C WrappedIRClosure
Boolean — members 13+
C new(truthy)
M create_cache_object(context) Object
M decode(d) Boolean
C encode(e)
M equals(other) boolean
M false?() boolean
M falsey_immediate?() boolean
M hash_code() int
M operand_type() OperandType
M to_string() String
M true?() boolean
M truthy_immediate?() boolean
C visit(visitor)
from Operand
F EMPTY_ARRAY Operand[]
M get_simplified_operand(value_map, force) Operand
M get_value(value_map) Operand
from ImmutableLiteral
C add_used_variables(l)
M cached?() boolean
M cached_object(context) T
M can_copy_propagate() boolean
M clone_for_inlining(ii) Operand
M has_known_value?() boolean
M retrieve(context, self, curr_scope, curr_dyn_scope, temp) T

org.jruby.ir.operands.Boolean

class extends ImmutableLiteral 13 members

Constructors

new

new ( boolean truthy )
Java: <init>(boolean truthy)

Class Methods

decode

Boolean decode ( IRReaderDecoder d )
Java: decode(org.jruby.ir.persistence.IRReaderDecoder d)

Instance Methods

create_cache_object

Object create_cache_object ( ThreadContext context )
Java: createCacheObject(org.jruby.runtime.ThreadContext context)

encode

encode ( IRWriterEncoder e )
Java: encode(org.jruby.ir.persistence.IRWriterEncoder e)

equals

boolean equals ( Object other )
Java: equals(Object other)

false?

boolean false? ( )
Java: isFalse() · also: is_false

falsey_immediate?

boolean falsey_immediate? ( )
Java: isFalseyImmediate() · also: is_falsey_immediate

hash_code

int hash_code ( )
Java: hashCode()

operand_type

OperandType operand_type ( )
Java: getOperandType() · also: get_operand_type

to_string

String to_string ( )
Java: toString()

true?

boolean true? ( )
Java: isTrue() · also: is_true

truthy_immediate?

boolean truthy_immediate? ( )
Java: isTruthyImmediate() · also: is_truthy_immediate

visit

visit ( IRVisitor visitor )
Java: visit(org.jruby.ir.IRVisitor visitor)

Inherited

from Operand

fieldtypenote
EMPTY_ARRAY Operand[]

get_simplified_operand

Operand get_simplified_operand ( Map<Operand,Operand> value_map, boolean force )
Java: getSimplifiedOperand(Map<org.jruby.ir.operands.Operand,org.jruby.ir.operands.Operand> valueMap, boolean force)

get_value

Operand get_value ( Map<Operand,Operand> value_map )
Java: getValue(Map<org.jruby.ir.operands.Operand,org.jruby.ir.operands.Operand> valueMap)

from ImmutableLiteral

add_used_variables

add_used_variables ( List<Variable> l )
Java: addUsedVariables(List<org.jruby.ir.operands.Variable> l)

cached?

boolean cached? ( )
Java: isCached() · also: is_cached

Has this object already been cached?

cached_object

T cached_object ( ThreadContext context )
Java: cachedObject(org.jruby.runtime.ThreadContext context)

Returns the cached object. If not then it asks class to create an object to cache.

can_copy_propagate

boolean can_copy_propagate ( )
Java: canCopyPropagate()

clone_for_inlining

Operand clone_for_inlining ( CloneInfo ii )
Java: cloneForInlining(org.jruby.ir.transformations.inlining.CloneInfo ii)

has_known_value?

boolean has_known_value? ( )
Java: hasKnownValue() · also: has_known_value

retrieve

T retrieve ( ThreadContext context, IRubyObject self, StaticScope curr_scope, DynamicScope curr_dyn_scope, Object[] temp )
Java: retrieve(org.jruby.runtime.ThreadContext context, org.jruby.runtime.builtin.IRubyObject self, org.jruby.parser.StaticScope currScope, org.jruby.runtime.DynamicScope currDynScope, Object[] temp)

retrieve the live value represented by this immutable literal. An interesting property of knowing something cannot change at compile time is that all information necessary to construct it is also known at compile time. We don't pre-create these since we don't want to assume the cost of constructing literals which may never be used.