use of org.sonar.java.model.declaration.ExportsDirectiveTreeImpl in project sonar-java by SonarSource.
the class TreeFactory method newExportsModuleDirective.
public ModuleDirectiveTree newExportsModuleDirective(InternalSyntaxToken exportsKeyword, ExpressionTree packageName, Optional<Tuple<InternalSyntaxToken, ListTreeImpl<ModuleNameTree>>> moduleNames, InternalSyntaxToken semicolonToken) {
InternalSyntaxToken toKeyword = null;
ListTreeImpl<ModuleNameTree> otherModuleNames = ModuleNameListTreeImpl.emptyList();
if (moduleNames.isPresent()) {
Tuple<InternalSyntaxToken, ListTreeImpl<ModuleNameTree>> toModuleNames = moduleNames.get();
toKeyword = toModuleNames.first();
otherModuleNames = toModuleNames.second();
}
return new ExportsDirectiveTreeImpl(exportsKeyword, packageName, toKeyword, otherModuleNames, semicolonToken);
}
Aggregations