public class SynchronizedVariableAccessor extends VariableAccessor
classId, DUMMY_ACCESSOR, index, name, realClass
Constructor and Description |
---|
SynchronizedVariableAccessor(RubyClass realClass,
String name,
int index,
int classId)
Construct a new SynchronizedVariableAccessor for the given "real" class,
variable name, variable index, and class ID.
|
Modifier and Type | Method and Description |
---|---|
void |
set(Object object,
Object value)
Set this variable into the given object using synchronization to ensure
safe updating of the variable table.
|
static void |
setVariable(RubyBasicObject self,
RubyClass realClass,
int index,
Object value)
Set the given variable index into the specified object.
|
static void |
setVariableChecked(RubyBasicObject self,
RubyClass realClass,
int index,
Object value)
Set the given variable index into the specified object.
|
get, getClassId, getIndex, getName, getVariable, verify
public SynchronizedVariableAccessor(RubyClass realClass, String name, int index, int classId)
realClass
- the "real" classname
- the variable's nameindex
- the variable's indexclassId
- the class's IDpublic void set(Object object, Object value)
set
in class VariableAccessor
object
- the object into which to set this variablevalue
- the variable's valuepublic static void setVariableChecked(RubyBasicObject self, RubyClass realClass, int index, Object value)
self
- the object into which to set the variablerealClass
- the "real" class for the objectindex
- the index of the variablevalue
- the variable's valuepublic static void setVariable(RubyBasicObject self, RubyClass realClass, int index, Object value)
self
- the object into which to set the variablerealClass
- the "real" class for the objectindex
- the index of the variablevalue
- the variable's valueCopyright © 2001-2015 JRuby. All Rights Reserved.