43 class ModuleClosure; |
43 class ModuleClosure; |
44 |
44 |
45 // A ModuleEntry describes a module that has been defined by a call to JVM_DefineModule. |
45 // A ModuleEntry describes a module that has been defined by a call to JVM_DefineModule. |
46 // It contains: |
46 // It contains: |
47 // - Symbol* containing the module's name. |
47 // - Symbol* containing the module's name. |
48 // - pointer to the java.lang.reflect.Module for this module. |
48 // - pointer to the java.lang.Module for this module. |
49 // - pointer to the java.security.ProtectionDomain shared by classes defined to this module. |
49 // - pointer to the java.security.ProtectionDomain shared by classes defined to this module. |
50 // - ClassLoaderData*, class loader of this module. |
50 // - ClassLoaderData*, class loader of this module. |
51 // - a growable array containg other module entries that this module can read. |
51 // - a growable array containg other module entries that this module can read. |
52 // - a flag indicating if this module can read all unnamed modules. |
52 // - a flag indicating if this module can read all unnamed modules. |
53 // |
53 // |
54 // The Mutex Module_lock is shared between ModuleEntry and PackageEntry, to lock either |
54 // The Mutex Module_lock is shared between ModuleEntry and PackageEntry, to lock either |
55 // data structure. |
55 // data structure. |
56 class ModuleEntry : public HashtableEntry<Symbol*, mtModule> { |
56 class ModuleEntry : public HashtableEntry<Symbol*, mtModule> { |
57 private: |
57 private: |
58 jobject _module; // java.lang.reflect.Module |
58 jobject _module; // java.lang.Module |
59 jobject _pd; // java.security.ProtectionDomain, cached |
59 jobject _pd; // java.security.ProtectionDomain, cached |
60 // for shared classes from this module |
60 // for shared classes from this module |
61 ClassLoaderData* _loader_data; |
61 ClassLoaderData* _loader_data; |
62 GrowableArray<ModuleEntry*>* _reads; // list of modules that are readable by this module |
62 GrowableArray<ModuleEntry*>* _reads; // list of modules that are readable by this module |
63 Symbol* _version; // module version number |
63 Symbol* _version; // module version number |