public static final class ModuleAnnotator.Builder
extends java.lang.Object
ModuleAnnotator
instances.Modifier and Type | Method and Description |
---|---|
ModuleAnnotator.Builder |
add(ModuleAnnotator.Job job)
Adds a
ModuleAnnotator.Job to execute. |
ModuleAnnotator |
build()
Creates a new instance of
ModuleAnnotator . |
ModuleAnnotator.Builder |
setAnnotatorFactory(AnnotatorFactory annotatorFactory) |
ModuleAnnotator.Builder |
setInternalAnnotation(io.spine.code.java.ClassName internalAnnotation)
Specifies the
internal annotation class name. |
ModuleAnnotator.Builder |
setInternalMethodNames(com.google.common.collect.ImmutableSet<java.lang.String> methodNames)
Sets names of methods to be annotated as
internal . |
ModuleAnnotator.Builder |
setInternalPatterns(com.google.common.collect.ImmutableSet<java.lang.String> patterns)
Sets patters for Java classes to be annotated as
internal . |
public ModuleAnnotator.Builder setAnnotatorFactory(AnnotatorFactory annotatorFactory)
@CanIgnoreReturnValue public ModuleAnnotator.Builder add(ModuleAnnotator.Job job)
ModuleAnnotator.Job
to execute.the {@code Job} construction DSL
public ModuleAnnotator.Builder setInternalPatterns(com.google.common.collect.ImmutableSet<java.lang.String> patterns)
internal
.
The patterns are compiled with no additional flags.
All the classes, fully qualified canonical names of which match at least one of the given patterns, should be marked as internal by the resulting annotator.
patterns
- class name patternssetInternalAnnotation(io.spine.code.java.ClassName)
public ModuleAnnotator.Builder setInternalMethodNames(com.google.common.collect.ImmutableSet<java.lang.String> methodNames)
internal
.methodNames
- the method namessetInternalAnnotation(io.spine.code.java.ClassName)
public ModuleAnnotator.Builder setInternalAnnotation(io.spine.code.java.ClassName internalAnnotation)
internal
annotation class name.
This annotation will be used to mark internal classes and methods.
internalAnnotation
- annotation class namepublic ModuleAnnotator build()
ModuleAnnotator
.ModuleAnnotator