public abstract class ModuleOperations extends Object
Constructor and Description |
---|
ModuleOperations() |
Modifier and Type | Method and Description |
---|---|
static boolean |
assignableTo(RubyClass thisClass,
RubyClass otherClass) |
static Map<String,Object> |
getAllClassVariables(RubyModule module) |
static Map<String,RubyConstant> |
getAllConstants(RubyModule module) |
static Map<String,InternalMethod> |
getAllMethods(RubyModule module) |
static boolean |
includesModule(RubyModule module,
RubyModule other) |
static Object |
lookupClassVariable(RubyModule module,
String name) |
static RubyConstant |
lookupConstant(RubyContext context,
LexicalScope lexicalScope,
RubyModule module,
String name) |
static InternalMethod |
lookupMethod(RubyModule module,
String name) |
static InternalMethod |
lookupSuperMethod(RubyModule declaringModule,
String name,
RubyClass objectMetaClass) |
static void |
setClassVariable(RubyModule module,
String name,
Object value) |
public static boolean includesModule(RubyModule module, RubyModule other)
public static Map<String,RubyConstant> getAllConstants(RubyModule module)
public static RubyConstant lookupConstant(RubyContext context, LexicalScope lexicalScope, RubyModule module, String name)
lexicalScope
- The surrounding LexicalScope (as in Constant),
or null if it is ignored (as in Mod::Constant or ::Constant)module
- The receiver of the constant lookup.
Must be identical to lexicalScope.getLiveModule() if lexicalScope != null.public static Map<String,InternalMethod> getAllMethods(RubyModule module)
public static InternalMethod lookupMethod(RubyModule module, String name)
public static InternalMethod lookupSuperMethod(RubyModule declaringModule, String name, RubyClass objectMetaClass)
public static Map<String,Object> getAllClassVariables(RubyModule module)
public static Object lookupClassVariable(RubyModule module, String name)
public static void setClassVariable(RubyModule module, String name, Object value)
Copyright © 2001-2015 JRuby. All Rights Reserved.