ModuleVisitor that generates the corresponding Module, ModulePackages and
ModuleMainClass attributes, as defined in the Java Virtual Machine Specification (JVMS).
| Modifier and Type | Field and Description |
|---|---|
| private final ByteVector | exports
The binary content of the 'exports' array of the JVMS Module attribute. |
| private int | exportsCount
The exports_count field of the JVMS Module attribute. |
| private int | mainClassIndex
The main_class_index field of the JVMS ModuleMainClass attribute, or 0. |
| private final int | moduleFlags
The module_flags field of the JVMS Module attribute. |
| private final int | moduleNameIndex
The module_name_index field of the JVMS Module attribute. |
| private final int | moduleVersionIndex
The module_version_index field of the JVMS Module attribute. |
| private final ByteVector | opens
The binary content of the 'opens' array of the JVMS Module attribute. |
| private int | opensCount
The opens_count field of the JVMS Module attribute. |
| private int | packageCount
The provides_count field of the JVMS ModulePackages attribute. |
| private final ByteVector | packageIndex
The binary content of the 'package_index' array of the JVMS ModulePackages attribute. |
| private final ByteVector | provides
The binary content of the 'provides' array of the JVMS Module attribute. |
| private int | providesCount
The provides_count field of the JVMS Module attribute. |
| private final ByteVector | requires
The binary content of the 'requires' array of the JVMS Module attribute. |
| private int | requiresCount
The requires_count field of the JVMS Module attribute. |
| private final SymbolTable | symbolTable
Where the constants used in this AnnotationWriter must be stored. |
| private int | usesCount
The uses_count field of the JVMS Module attribute. |
| private final ByteVector | usesIndex
The binary content of the 'uses_index' array of the JVMS Module attribute. |
| Access | Constructor and Description |
|---|---|
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| pack-priv int | Returns: the size in bytes of the Module, ModulePackages and ModuleMainClass attributes.Returns the size of the Module, ModulePackages and ModuleMainClass attributes generated by this ModuleWriter. |
| pack-priv int | Returns: the number of Module, ModulePackages and ModuleMainClass attributes (between 1 and 3).Returns the number of Module, ModulePackages and ModuleMainClass attributes generated by this ModuleWriter. |
| pack-priv void | putAttributes(final ByteVector
where the attributes must be put. output)Puts the Module, ModulePackages and ModuleMainClass attributes generated by this ModuleWriter in the given ByteVector. |
| public void | |
| public void | visitExport(final String
the internal name of the exported package (see packaze, final int Type#getInternalName()).the access flag of the exported package, valid values are among access, final String... ACC_SYNTHETIC and ACC_MANDATED.the fully qualified names (using dots) of the modules that can access the public
classes of the exported package, or null. modules)
Visit an exported package of the current module.
|
| public void | visitMainClass(final String
the internal name of the main class of the current module (see mainClass)Type#getInternalName()).Overrides net. |
| public void | visitOpen(final String
the internal name of the opened package (see packaze, final int Type#getInternalName()).the access flag of the opened package, valid values are among access, final String... ACC_SYNTHETIC and ACC_MANDATED.the fully qualified names (using dots) of the modules that can use deep
reflection to the classes of the open package, or null. modules)
Visit an open package of the current module.
|
| public void | visitPackage(final String
the internal name of a package (see packaze)
Visit a package of the current module.
Type#getInternalName()). |
| public void | visitProvide(final String
the internal name of the service (see service, final String... Type#getInternalName()).the internal names (see providers)
Visit an implementation of a service.
Type#getInternalName()) of the implementations
of the service (there is at least one provider). |
| public void | visitRequire(final String
the fully qualified name (using dots) of the dependence. module, final int the access flag of the dependence among access, final String ACC_TRANSITIVE, ACC_STATIC_PHASE, ACC_SYNTHETIC and ACC_MANDATED.the module version at compile time, or null. version)
Visits a dependence of the current module.
|
| public void | visitUse(final String
the internal name of the service (see service)Type#getInternalName()).Overrides net. |
| exports | back to summary |
|---|---|
| private final ByteVector exports The binary content of the 'exports' array of the JVMS Module attribute. | |
| exportsCount | back to summary |
|---|---|
| private int exportsCount The exports_count field of the JVMS Module attribute. | |
| mainClassIndex | back to summary |
|---|---|
| private int mainClassIndex The main_class_index field of the JVMS ModuleMainClass attribute, or 0. | |
| moduleFlags | back to summary |
|---|---|
| private final int moduleFlags The module_flags field of the JVMS Module attribute. | |
| moduleNameIndex | back to summary |
|---|---|
| private final int moduleNameIndex The module_name_index field of the JVMS Module attribute. | |
| moduleVersionIndex | back to summary |
|---|---|
| private final int moduleVersionIndex The module_version_index field of the JVMS Module attribute. | |
| opens | back to summary |
|---|---|
| private final ByteVector opens The binary content of the 'opens' array of the JVMS Module attribute. | |
| opensCount | back to summary |
|---|---|
| private int opensCount The opens_count field of the JVMS Module attribute. | |
| packageCount | back to summary |
|---|---|
| private int packageCount The provides_count field of the JVMS ModulePackages attribute. | |
| packageIndex | back to summary |
|---|---|
| private final ByteVector packageIndex The binary content of the 'package_index' array of the JVMS ModulePackages attribute. | |
| provides | back to summary |
|---|---|
| private final ByteVector provides The binary content of the 'provides' array of the JVMS Module attribute. | |
| providesCount | back to summary |
|---|---|
| private int providesCount The provides_count field of the JVMS Module attribute. | |
| requires | back to summary |
|---|---|
| private final ByteVector requires The binary content of the 'requires' array of the JVMS Module attribute. | |
| requiresCount | back to summary |
|---|---|
| private int requiresCount The requires_count field of the JVMS Module attribute. | |
| symbolTable | back to summary |
|---|---|
| private final SymbolTable symbolTable Where the constants used in this AnnotationWriter must be stored. | |
| usesCount | back to summary |
|---|---|
| private int usesCount The uses_count field of the JVMS Module attribute. | |
| usesIndex | back to summary |
|---|---|
| private final ByteVector usesIndex The binary content of the 'uses_index' array of the JVMS Module attribute. | |
| ModuleWriter | back to summary |
|---|---|
| pack-priv ModuleWriter(final SymbolTable symbolTable, final int name, final int access, final int version) | |
| computeAttributesSize | back to summary |
|---|---|
| pack-priv int computeAttributesSize() Returns the size of the Module, ModulePackages and ModuleMainClass attributes generated by this ModuleWriter. Also add the names of these attributes in the constant pool.
| |
| getAttributeCount | back to summary |
|---|---|
| pack-priv int getAttributeCount() Returns the number of Module, ModulePackages and ModuleMainClass attributes generated by this ModuleWriter.
| |
| putAttributes | back to summary |
|---|---|
| pack-priv void putAttributes(final ByteVector output) Puts the Module, ModulePackages and ModuleMainClass attributes generated by this ModuleWriter in the given ByteVector.
| |
| visitEnd | back to summary |
|---|---|
| public void visitEnd() Overrides net. Doc from net. Visits the end of the module. This method, which is the last one to be called, is used to inform the visitor that everything have been visited.
| |
| visitExport | back to summary |
|---|---|
| public void visitExport(final String packaze, final int access, final String... modules) Overrides net. Doc from net. Visit an exported package of the current module.
| |
| visitMainClass | back to summary |
|---|---|
| public void visitMainClass(final String mainClass) Overrides net. Doc from net. Visit the main class of the current module.
| |
| visitOpen | back to summary |
|---|---|
| public void visitOpen(final String packaze, final int access, final String... modules) Overrides net. Doc from net. Visit an open package of the current module.
| |
| visitPackage | back to summary |
|---|---|
| public void visitPackage(final String packaze) Overrides net. Doc from net. Visit a package of the current module.
| |
| visitProvide | back to summary |
|---|---|
| public void visitProvide(final String service, final String... providers) Overrides net. Doc from net. Visit an implementation of a service.
| |
| visitRequire | back to summary |
|---|---|
| public void visitRequire(final String module, final int access, final String version) Overrides net. Doc from net. Visits a dependence of the current module. | |
| visitUse | back to summary |
|---|---|
| public void visitUse(final String service) Overrides net. Doc from net. Visit a service used by the current module. The name must be the internal name of an interface or a class.
| |