gnu.kawa.functions
Class GetModuleClass
java.lang.Object
gnu.mapping.PropertySet
gnu.mapping.Procedure
gnu.mapping.Procedure0
gnu.kawa.functions.GetModuleClass
- All Implemented Interfaces:
- Inlineable, Named
public class GetModuleClass
- extends Procedure0
- implements Inlineable
Special procedure to get the Class of the current module.
Since "current module" is defined by lexical scope,
this isn't a first-class procedure - it has to be inlined.
Methods inherited from class gnu.mapping.Procedure |
apply, apply, check0, check1, check2, check3, check4, checkArgCount, checkN, getSetter, getSourceLocation, match0, match1, match2, match3, match4, matchN, maxArgs, minArgs, set0, set1, setN, setSetter, setSourceLocation, toString |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
getModuleClass
public static final GetModuleClass getModuleClass
GetModuleClass
public GetModuleClass()
apply0
public java.lang.Object apply0()
- Specified by:
apply0
in class Procedure0
compile
public void compile(ApplyExp exp,
Compilation comp,
Target target)
- Specified by:
compile
in interface Inlineable
getReturnType
public Type getReturnType(Expression[] args)
- Specified by:
getReturnType
in interface Inlineable
getModuleClassURI
public static Expression getModuleClassURI(Compilation comp)
- Return an expression that evaluates to a module-relative URI.
This has the Kawa-specific URI scheme "class-resource:" and an
assocatied ClassLoader (using a WekaHashMap). It used to reference
resources located using the compiled class's ClassLoader.