Top Description Methods
com.sun.source.tree

public Interface RequiresTree

extends DirectiveTree
Known Direct Implementers
com.sun.tools.javac.tree.JCTree.JCRequires

A tree node for a 'requires' directive in a module declaration. For example:
   requires module-name;
   requires static module-name;
   requires transitive module-name;
Since
9

Method Summary

Modifier and TypeMethod and Description
public ExpressionTree

Returns:

the name of the module that is required
getModuleName
()

Returns the name of the module that is required.

public boolean

Returns:

true if this is a "requires static" directive
isStatic
()

Returns true if this is a "requires static" directive.

public boolean

Returns:

true if this is a "requires transitive" directive
isTransitive
()

Returns true if this is a "requires transitive" directive.

Method Detail

getModuleNameback to summary
public ExpressionTree getModuleName()

Returns the name of the module that is required.

Returns:ExpressionTree

the name of the module that is required

isStaticback to summary
public boolean isStatic()

Returns true if this is a "requires static" directive.

Returns:boolean

true if this is a "requires static" directive

isTransitiveback to summary
public boolean isTransitive()

Returns true if this is a "requires transitive" directive.

Returns:boolean

true if this is a "requires transitive" directive