Package org.jruby

Class RubyClass

All Implemented Interfaces:
Serializable, Cloneable, Comparable<IRubyObject>, InstanceVariables, InternalVariables, IRubyObject, CoreObjectType
Direct Known Subclasses:
IncludedModule, MetaClass, PrependedModule

public class RubyClass extends RubyModule
See Also:
  • Field Details

    • LOG

      private static final Logger LOG
    • CLASS_ALLOCATOR

      public static final ObjectAllocator CLASS_ALLOCATOR
    • DEFAULT_OBJECT_MARSHAL

      protected static final ObjectMarshal DEFAULT_OBJECT_MARSHAL
    • DEBUG_REIFY

      private static final boolean DEBUG_REIFY
      See Also:
    • defaultSimplePosition

      private static final PositionAware defaultSimplePosition
    • runtime

      protected final Ruby runtime
    • allocator

      private ObjectAllocator allocator
    • marshal

      protected ObjectMarshal marshal
    • subclasses

      private volatile Map<RubyClass,Object> subclasses
    • CS_IDX_INITIALIZE

      public static final int CS_IDX_INITIALIZE
      See Also:
    • baseCallSites

      private final CallSite[] baseCallSites
    • extraCallSites

      private CallSite[] extraCallSites
    • reifiedClass

      private Class<? extends Reified> reifiedClass
    • reifiedClassJava

      private Boolean reifiedClassJava
    • javaClassConfiguration

      private JavaClassConfiguration javaClassConfiguration
    • cachedDumpMarshal

      private RubyClass.MarshalTuple cachedDumpMarshal
      A cached tuple of method, type, and generation for dumping
    • cachedLoad

      private CacheEntry cachedLoad
      A cached tuple of method and generation for marshal loading
    • realClass

      private final RubyClass realClass
      The "real" class, used by includes and singletons to locate the actual type of the object
    • variableTableManager

      private final VariableTableManager variableTableManager
      Variable table manager for this class
  • Constructor Details

    • RubyClass

      protected RubyClass(Ruby runtime, RubyClass superClass, boolean objectSpace)
      separate path for MetaClass and IncludedModuleWrapper construction (rb_class_boot version for MetaClasses) no marshal, allocator initialization and addSubclass(this) here!
    • RubyClass

      protected RubyClass(Ruby runtime)
      used by CLASS_ALLOCATOR (any Class' class will be a Class!) also used to bootstrap Object class
    • RubyClass

      protected RubyClass(Ruby runtime, RubyClass superClazz)
      rb_class_boot (for plain Classes) also used to bootstrap Module and Class classes
    • RubyClass

      protected RubyClass(Ruby runtime, RubyClass superClazz, CallSite[] extraCallSites)
      A constructor which allows passing in an array of supplementary call sites.
  • Method Details