Package kawa.lang
Class AutoloadProcedure
java.lang.Object
gnu.mapping.PropertySet
gnu.mapping.Procedure
kawa.lang.AutoloadProcedure
- All Implemented Interfaces:
Named
,Externalizable
,Serializable
Implement autoloading of Procedures.
A named class is loaded, and apply requests are forwarded to it.
- See Also:
-
Field Summary
Fields inherited from class gnu.mapping.Procedure
applyMethodType, applyToConsumerDefault, applyToConsumerMethod, applyToObjectDefault, applyToObjectMethod, compilerKey, compilerXKey, inlineIfConstantSymbol, validateApplyKey, validateXApplyKey
Fields inherited from class gnu.mapping.PropertySet
nameKey
-
Constructor Summary
ConstructorsConstructorDescriptionAutoloadProcedure
(String name, String className) AutoloadProcedure
(String name, String className, Language language) -
Method Summary
Modifier and TypeMethodDescriptionapply0()
getProperty
(Object key, Object defaultValue) int
numArgs()
ReturnminArgs()|(maxArgs<<12)
.void
print
(PrintWriter ps) void
void
Methods inherited from class gnu.mapping.Procedure
applyL, applyToConsumerDefault, applyToObjectDefault, checkArgCount, checkBadCode, getApplyMethod, getApplyToConsumerMethod, getApplyToObjectMethod, getReturnType, getSourceLocation, isSideEffectFree, lookupApplyHandle, maxArgs, maxArgs, minArgs, minArgs, set0, set1, setN, setSetter, setSourceLocation, toString
Methods inherited from class gnu.mapping.PropertySet
getName, getSymbol, removeProperty, setName, setProperty, setProperty, setSymbol
-
Constructor Details
-
AutoloadProcedure
public AutoloadProcedure() -
AutoloadProcedure
-
AutoloadProcedure
-
-
Method Details
-
print
-
getLoaded
-
numArgs
public int numArgs()Description copied from class:Procedure
ReturnminArgs()|(maxArgs<<12)
. We use a single virtual function to reduce the number of methods in the system, as well as the number of virtual method table entries. We shift by 12 so the number can normally be represented using a sipush instruction, without requiring a constant pool entry. -
apply0
-
apply1
-
apply2
-
apply3
-
apply4
-
applyN
-
getSetter
-
writeExternal
- Specified by:
writeExternal
in interfaceExternalizable
- Throws:
IOException
-
readExternal
- Specified by:
readExternal
in interfaceExternalizable
- Throws:
IOException
ClassNotFoundException
-
getProperty
- Overrides:
getProperty
in classPropertySet
-