Top Description Fields Constructors Methods
com.github.javaparser.ast.modules

public abstract Class ModuleDirective

extends Node
Class Inheritance
Known Direct Subclasses
com.github.javaparser.ast.modules.ModuleExportsDirective, com.github.javaparser.ast.modules.ModuleOpensDirective, com.github.javaparser.ast.modules.ModuleProvidesDirective, com.github.javaparser.ast.modules.ModuleRequiresDirective, com.github.javaparser.ast.modules.ModuleUsesDirective
Imports
com.github.javaparser.ast.AllFieldsConstructor, .Generated, .Node, com.github.javaparser.ast.visitor.CloneVisitor, com.github.javaparser.TokenRange, java.util.function.Consumer, java.util.Optional, com.github.javaparser.metamodel.ModuleDirectiveMetaModel, .JavaParserMetaModel

A module directive.

Field Summary

Inherited from com.github.javaparser.ast.Node:
ABSOLUTE_BEGIN_LINEABSOLUTE_END_LINENODE_BY_BEGIN_POSITIONprettyPrinterNoCommentsConfigurationSYMBOL_RESOLVER_KEY

Constructor Summary

AccessConstructor and Description
public
public
ModuleDirective(TokenRange tokenRange)

This constructor is used by the parser and is considered private.

Method Summary

Modifier and TypeMethod and Description
public ModuleExportsDirective
public ModuleExportsDirective
public ModuleOpensDirective
public ModuleOpensDirective
public ModuleProvidesDirective
public ModuleProvidesDirective
public ModuleRequiresDirective
public ModuleRequiresDirective
public ModuleUsesDirective
public ModuleUsesDirective
public ModuleDirective
clone()

Overrides com.github.javaparser.ast.Node.clone.

Creates and returns a copy of this object.
public ModuleDirectiveMetaModel
public void
public void
public void
public void
public void
public void
public void
public void
public void
public void
public boolean
public boolean
public boolean
public boolean
public boolean
public boolean
public boolean
public boolean
public boolean
public boolean
public boolean
public boolean
replace(Node node, Node replacementNode)

Overrides com.github.javaparser.ast.Node.replace.

public Optional<ModuleExportsDirective>
public Optional<ModuleExportsDirective>
public Optional<ModuleOpensDirective>
public Optional<ModuleOpensDirective>
public Optional<ModuleProvidesDirective>
public Optional<ModuleProvidesDirective>
public Optional<ModuleRequiresDirective>
public Optional<ModuleRequiresDirective>
public Optional<ModuleUsesDirective>
public Optional<ModuleUsesDirective>
Inherited from com.github.javaparser.ast.Node:
addOrphanCommentcontainsDatacustomInitializationequalsfindAllfindAllfindCompilationUnitfindFirstfindFirstfindFirstfindRootNodegetAllContainedCommentsgetChildNodesgetChildNodesByTypegetCommentgetDatagetDataKeysgetNodesByTypegetOrphanCommentsgetParentNodegetParentNodeForChildrengetParsedgetRangegetSymbolResolvergetTokenRangegetToStringPrettyPrinterConfigurationhashCodeisAncestorOfisRegisterednotifyPropertyChangeregisterregisterregisterForSubtreeremoveremoveCommentremoveDataremoveForcedremoveOrphanCommentreplacesetAsParentNodeOfsetAsParentNodeOfsetBlockCommentsetCommentsetDatasetLineCommentsetParentNodesetParsedsetRangesetTokenRangesetToStringPrettyPrinterConfigurationstreamstreamtoStringtoStringtryAddImportToParentCompilationUnitunregisterwalkwalkwalk

Constructor Detail

ModuleDirectiveback to summary
public ModuleDirective()
Annotations
@AllFieldsConstructor
ModuleDirectiveback to summary
public ModuleDirective(TokenRange tokenRange)

This constructor is used by the parser and is considered private.

Annotations
@Generated:com.github.javaparser.generator.core.node.MainConstructorGenerator

Method Detail

asModuleExportsDirectiveback to summary
public ModuleExportsDirective asModuleExportsDirective()
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
asModuleExportsStmtback to summary
public ModuleExportsDirective asModuleExportsStmt()
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
asModuleOpensDirectiveback to summary
public ModuleOpensDirective asModuleOpensDirective()
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
asModuleOpensStmtback to summary
public ModuleOpensDirective asModuleOpensStmt()
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
asModuleProvidesDirectiveback to summary
public ModuleProvidesDirective asModuleProvidesDirective()
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
asModuleProvidesStmtback to summary
public ModuleProvidesDirective asModuleProvidesStmt()
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
asModuleRequiresDirectiveback to summary
public ModuleRequiresDirective asModuleRequiresDirective()
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
asModuleRequiresStmtback to summary
public ModuleRequiresDirective asModuleRequiresStmt()
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
asModuleUsesDirectiveback to summary
public ModuleUsesDirective asModuleUsesDirective()
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
asModuleUsesStmtback to summary
public ModuleUsesDirective asModuleUsesStmt()
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
cloneback to summary
public ModuleDirective clone()

Overrides com.github.javaparser.ast.Node.clone.

Doc from java.lang.Object.clone.

Creates and returns a copy of this object. The precise meaning of "copy" may depend on the class of the object. The general intent is that, for any object x, the expression:

x.clone() != x
will be true, and that the expression:
x.clone().getClass() == x.getClass()
will be true, but these are not absolute requirements. While it is typically the case that:
x.clone().equals(x)
will be true, this is not an absolute requirement.

By convention, the returned object should be obtained by calling super.clone. If a class and all of its superclasses (except Object) obey this convention, it will be the case that x.clone().getClass() == x.getClass().

By convention, the object returned by this method should be independent of this object (which is being cloned). To achieve this independence, it may be necessary to modify one or more fields of the object returned by super.clone before returning it. Typically, this means copying any mutable objects that comprise the internal "deep structure" of the object being cloned and replacing the references to these objects with references to the copies. If a class contains only primitive fields or references to immutable objects, then it is usually the case that no fields in the object returned by super.clone need to be modified.

Returns:ModuleDirective

a clone of this instance.

Annotations
@Override
@Generated:com.github.javaparser.generator.core.node.CloneGenerator
getMetaModelback to summary
public ModuleDirectiveMetaModel getMetaModel()

Overrides com.github.javaparser.ast.Node.getMetaModel.

Returns:ModuleDirectiveMetaModel

Doc from com.github.javaparser.ast.Node.getMetaModel.

get JavaParser specific node introspection information.

Annotations
@Override
@Generated:com.github.javaparser.generator.core.node.GetMetaModelGenerator
ifModuleExportsDirectiveback to summary
public void ifModuleExportsDirective(Consumer<ModuleExportsDirective> action)
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
ifModuleExportsStmtback to summary
public void ifModuleExportsStmt(Consumer<ModuleExportsDirective> action)
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
ifModuleOpensDirectiveback to summary
public void ifModuleOpensDirective(Consumer<ModuleOpensDirective> action)
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
ifModuleOpensStmtback to summary
public void ifModuleOpensStmt(Consumer<ModuleOpensDirective> action)
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
ifModuleProvidesDirectiveback to summary
public void ifModuleProvidesDirective(Consumer<ModuleProvidesDirective> action)
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
ifModuleProvidesStmtback to summary
public void ifModuleProvidesStmt(Consumer<ModuleProvidesDirective> action)
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
ifModuleRequiresDirectiveback to summary
public void ifModuleRequiresDirective(Consumer<ModuleRequiresDirective> action)
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
ifModuleRequiresStmtback to summary
public void ifModuleRequiresStmt(Consumer<ModuleRequiresDirective> action)
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
ifModuleUsesDirectiveback to summary
public void ifModuleUsesDirective(Consumer<ModuleUsesDirective> action)
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
ifModuleUsesStmtback to summary
public void ifModuleUsesStmt(Consumer<ModuleUsesDirective> action)
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
isModuleExportsDirectiveback to summary
public boolean isModuleExportsDirective()
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
isModuleExportsStmtback to summary
public boolean isModuleExportsStmt()
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
isModuleOpensDirectiveback to summary
public boolean isModuleOpensDirective()
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
isModuleOpensStmtback to summary
public boolean isModuleOpensStmt()
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
isModuleProvidesDirectiveback to summary
public boolean isModuleProvidesDirective()
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
isModuleProvidesStmtback to summary
public boolean isModuleProvidesStmt()
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
isModuleRequiresDirectiveback to summary
public boolean isModuleRequiresDirective()
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
isModuleRequiresStmtback to summary
public boolean isModuleRequiresStmt()
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
isModuleUsesDirectiveback to summary
public boolean isModuleUsesDirective()
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
isModuleUsesStmtback to summary
public boolean isModuleUsesStmt()
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
removeback to summary
public boolean remove(Node node)

Overrides com.github.javaparser.ast.Node.remove.

Annotations
@Override
@Generated:com.github.javaparser.generator.core.node.RemoveMethodGenerator
replaceback to summary
public boolean replace(Node node, Node replacementNode)

Overrides com.github.javaparser.ast.Node.replace.

Annotations
@Override
@Generated:com.github.javaparser.generator.core.node.ReplaceMethodGenerator
toModuleExportsDirectiveback to summary
public Optional<ModuleExportsDirective> toModuleExportsDirective()
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
toModuleExportsStmtback to summary
public Optional<ModuleExportsDirective> toModuleExportsStmt()
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
toModuleOpensDirectiveback to summary
public Optional<ModuleOpensDirective> toModuleOpensDirective()
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
toModuleOpensStmtback to summary
public Optional<ModuleOpensDirective> toModuleOpensStmt()
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
toModuleProvidesDirectiveback to summary
public Optional<ModuleProvidesDirective> toModuleProvidesDirective()
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
toModuleProvidesStmtback to summary
public Optional<ModuleProvidesDirective> toModuleProvidesStmt()
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
toModuleRequiresDirectiveback to summary
public Optional<ModuleRequiresDirective> toModuleRequiresDirective()
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
toModuleRequiresStmtback to summary
public Optional<ModuleRequiresDirective> toModuleRequiresStmt()
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
toModuleUsesDirectiveback to summary
public Optional<ModuleUsesDirective> toModuleUsesDirective()
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator
toModuleUsesStmtback to summary
public Optional<ModuleUsesDirective> toModuleUsesStmt()
Annotations
@Generated:com.github.javaparser.generator.core.node.TypeCastingGenerator