Class 
Use 
SUMMARY: NESTED | FIELD | CONSTR | METHOD      DETAIL: FIELD | CONSTR | METHOD
FlexDoc/Javadoc 2.0
Demo Java Doc

java.base / java.lang
Class ModuleLayer.Controller
java.lang.Object
  java.lang.ModuleLayer.Controller
Enclosing class:
ModuleLayer

public static final class ModuleLayer.Controller
extends Object
Controls a module layer. The static methods defined by ModuleLayer to create module layers return a Controller that can be used to control modules in the layer.

Unless otherwise specified, passing a null argument to a method in this class causes a NullPointerException to be thrown.

Since:
9

Method Summary
addExports(Module source, String pn, Module target)
Updates module source in the layer to export a package to module target.
addOpens(Module source, String pn, Module target)
Updates module source in the layer to open a package to module target.
addReads(Module source, Module target)
Updates module source in the layer to read module target.
Returns the layer that this object controls.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Method Detail
layer
public ModuleLayer layer
()
Returns the layer that this object controls.
Returns:
the module layer

addReads
public ModuleLayer.Controller addReads
(Module source,
 Module target)
Updates module source in the layer to read module target. This method is a no-op if source already reads target.
Implementation Note:
Read edges added by this method are weak and do not prevent target from being GC'ed when source is strongly reachable.
Parameters:
source - The source module
target - The target module to read
Returns:
This controller
Throws:
IllegalArgumentException - If source is not in the module layer
See Also:
Module.addReads(Module)

addExports
public ModuleLayer.Controller addExports
(Module source,
 String pn,
 Module target)
Updates module source in the layer to export a package to module target. This method is a no-op if source already exports the package to at least target.
Parameters:
source - The source module
pn - The package name
target - The target module
Returns:
This controller
Throws:
IllegalArgumentException - If source is not in the module layer or the package is not in the source module
See Also:
Module.addExports(String, Module)

addOpens
public ModuleLayer.Controller addOpens
(Module source,
 String pn,
 Module target)
Updates module source in the layer to open a package to module target. This method is a no-op if source already opens the package to at least target.
Parameters:
source - The source module
pn - The package name
target - The target module
Returns:
This controller
Throws:
IllegalArgumentException - If source is not in the module layer or the package is not in the source module
See Also:
Module.addOpens(String, Module)

 Class 
Use 
SUMMARY: NESTED | FIELD | CONSTR | METHOD      DETAIL: FIELD | CONSTR | METHOD
FlexDoc/Javadoc 2.0
Demo Java Doc

Java API documentation generated with FlexDoc/Javadoc 2.0 using JavadocClassic 3.0 template set.
FlexDoc/Javadoc is a template-driven programming tool for rapid development of any Javadoc-based Java API documentation generators (i.e. doclets). If you need to customize your Javadoc without writing a full-blown doclet from scratch, FlexDoc/Javadoc may be the only tool able to help you! Find out more at www.flexdoc.xyz