public class NonvolatileVariableAccessor extends VariableAccessor
classId, DUMMY_ACCESSOR, index, name, realClass| Constructor and Description |
|---|
NonvolatileVariableAccessor(RubyClass realClass,
java.lang.String name,
int index,
int classId)
Construct a new NonvolatileVariableAccessor for the given "real" class,
variable name, variable index, and class ID.
|
| Modifier and Type | Method and Description |
|---|---|
void |
set(java.lang.Object object,
java.lang.Object value)
Set this variable into the given object using Unsafe to ensure
safe creation or growth of the variable table.
|
static void |
setVariable(RubyBasicObject self,
RubyClass realClass,
int index,
java.lang.Object value)
Set the given variable index into the specified object.
|
static void |
setVariableChecked(RubyBasicObject self,
RubyClass realClass,
int index,
java.lang.Object value)
Set the given variable index into the specified object.
|
get, getClassId, getIndex, getName, getVariable, toString, verifypublic NonvolatileVariableAccessor(RubyClass realClass, java.lang.String name, int index, int classId)
realClass - the "real" classname - the variable's nameindex - the variable's indexclassId - the class's IDpublic void set(java.lang.Object object,
java.lang.Object value)
set in class VariableAccessorobject - the object into which to set this variablevalue - the variable's valuepublic static void setVariableChecked(RubyBasicObject self, RubyClass realClass, int index, java.lang.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, java.lang.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-2021 JRuby. All Rights Reserved.