Package gnu.expr
Class ModuleInfo
java.lang.Object
gnu.expr.ModuleInfo
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected String
Name of class that implements module.long
long
Last time the source file was modified.Location of source for module, if known. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic gnu.kawa.io.Path
void
addDependency
(ModuleInfo dep) boolean
checkCurrent
(ModuleManager manager, long now) Check if this module and its dependencies are up-to-dete.void
void
static ModuleInfo
static ModuleInfo
findFromInstance
(Object instance) static ModuleInfo
findWithClassName
(String className) The namespace URI associated with this module, ornull
.gnu.kawa.io.Path
int
getState()
void
loadByStages
(int wantedState) boolean
loadEager
(int wantedState) Eagerly process the module and dependencies.static void
void
setClassName
(String name) void
setCompilation
(Compilation comp) void
setModuleClass
(Class clas) void
setNamespaceUri
(String uri) void
setSourceAbsPath
(gnu.kawa.io.Path path) If module has LAZY_DECLARATIONS, fix that.toString()
-
Field Details
-
className
Name of class that implements module. Must be non-null unless we're currently compiling the module, in which case sourcePath and comp must both be non-null. -
sourcePath
Location of source for module, if known. This can be any of an absolute URI, absolute filename, or filename relative to current working directory. Null if source not known; in that case className must be non-null. Avoid using, since "relative to current working directory" is unreliable if the working directory can change. -
lastCheckedTime
public long lastCheckedTime -
lastModifiedTime
public long lastModifiedTimeLast time the source file was modified. At least the last time we checked ...
-
-
Constructor Details
-
ModuleInfo
public ModuleInfo()
-
-
Method Details
-
getNamespaceUri
The namespace URI associated with this module, ornull
. This is null for Scheme modules, but non-null for XQuery modules. -
setNamespaceUri
-
getCompilation
-
setCompilation
-
cleanupAfterCompilation
public void cleanupAfterCompilation() -
absPath
-
getSourceAbsPath
public gnu.kawa.io.Path getSourceAbsPath() -
setSourceAbsPath
public void setSourceAbsPath(gnu.kawa.io.Path path) -
getSourceAbsPathname
-
addDependency
-
getClassType
-
getClassName
-
setClassName
-
getModuleExpRaw
-
getModuleExp
-
setupModuleExp
If module has LAZY_DECLARATIONS, fix that. -
getModuleClass
- Throws:
ClassNotFoundException
-
getModuleClassRaw
-
getOldModuleClass
-
setModuleClass
-
findFromInstance
-
find
-
findWithClassName
-
register
-
getInstance
-
getRunInstance
-
getState
public int getState() -
loadByStages
public void loadByStages(int wantedState) -
loadEager
public boolean loadEager(int wantedState) Eagerly process the module and dependencies.- Returns:
- true on success; false if we were unable to because of an error or a cyclic dependency.
-
clearClass
public void clearClass() -
checkCurrent
Check if this module and its dependencies are up-to-dete. Only checks the sourcePath's modification time if it is at least ModifiedCacheTime since last time we checked. As as side-effects update lastModifiedTime and lastCheckedTime. -
toString
-