public class JModule
extends java.lang.Object
| Modifier and Type | Method | Description |
|---|---|---|
void |
_exports(JPackage pkg) |
Adds a package to the list of Java module exports.
|
void |
_exports(java.util.Collection<JPackage> pkgs,
boolean addEmpty) |
Adds packages to the list of Java module exports.
|
void |
_requires(boolean isPublic,
boolean isStatic,
java.lang.String... names) |
Adds all modules to the list of Java module requirements.
|
void |
_requires(java.lang.String name) |
Adds a module to the list of Java module requirements without
public and static modifiers. |
void |
_requires(java.lang.String... names) |
Adds all modules to the list of Java module requirements without
public and static modifiers. |
void |
_requires(java.lang.String name,
boolean isPublic,
boolean isStatic) |
Adds a module to the list of Java module requirements.
|
JFormatter |
generate(JFormatter f) |
Print source code of Java Module declaration.
|
java.lang.String |
name() |
Gets the name of this module.
|
public java.lang.String name()
public void _exports(JPackage pkg)
null or empty String.pkg - Java package to be exported.public void _exports(java.util.Collection<JPackage> pkgs, boolean addEmpty)
pkgs - Collection of packages to be added.addEmpty - Adds also packages without any classes when true.public void _requires(java.lang.String name,
boolean isPublic,
boolean isStatic)
null or empty String.name - Name of required Java module.isPublic - Use public modifier.isStatic - Use static modifier.public void _requires(java.lang.String name)
public and static modifiers.
The module name shall not be null or empty String.name - Name of required Java module.public void _requires(boolean isPublic,
boolean isStatic,
java.lang.String... names)
null or empty String.names - Names of required Java module.isPublic - Use public modifier.isStatic - Use static modifier.public void _requires(java.lang.String... names)
public and static modifiers.names - Names of required Java module.public JFormatter generate(JFormatter f)
f - Java code formatter.Copyright © 2017 Oracle Corporation. All rights reserved.