Class ImmutableRound.Builder
java.lang.Object
org.immutables.value.processor.meta.ImmutableRound.Builder
- Enclosing class:
ImmutableRound
Builds instances of type
ImmutableRound.
Initialize attributes and then invoke the build() method to create an
immutable instance.
Builder is not thread-safe and generally should not be stored in a field or collection,
but instead used immediately to create instances.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final com.google.common.collect.ImmutableSet.Builder<TypeElement> private final com.google.common.collect.ImmutableSet.Builder<String> private static final longprivate static final longprivate longprivate ProcessingEnvironmentprivate RoundEnvironment -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal ImmutableRound.BuilderaddAllAnnotations(Iterable<? extends TypeElement> elements) Adds elements toannotationsset.final ImmutableRound.BuilderaddAllCustomImmutableAnnotations(Iterable<String> elements) Adds elements tocustomImmutableAnnotationsset.final ImmutableRound.BuilderaddAnnotations(TypeElement element) Adds one element toannotationsset.final ImmutableRound.BuilderaddAnnotations(TypeElement... elements) Adds elements toannotationsset.final ImmutableRound.BuilderaddCustomImmutableAnnotations(String element) Adds one element tocustomImmutableAnnotationsset.final ImmutableRound.BuilderaddCustomImmutableAnnotations(String... elements) Adds elements tocustomImmutableAnnotationsset.build()Builds a newImmutableRound.private static voidcheckNotIsSet(boolean isSet, String name) private voidprivate Stringfinal ImmutableRound.Builderprocessing(ProcessingEnvironment processing) Initializes the value for theprocessingattribute.private booleanfinal ImmutableRound.Builderround(RoundEnvironment round) Initializes the value for theroundattribute.private boolean
-
Field Details
-
INIT_BIT_PROCESSING
private static final long INIT_BIT_PROCESSING- See Also:
-
INIT_BIT_ROUND
private static final long INIT_BIT_ROUND- See Also:
-
initBits
private long initBits -
processing
-
round
-
annotations
-
customImmutableAnnotations
-
-
Constructor Details
-
Builder
private Builder()
-
-
Method Details
-
processing
Initializes the value for theprocessingattribute.- Parameters:
processing- The value for processing- Returns:
thisbuilder for use in a chained invocation
-
round
Initializes the value for theroundattribute.- Parameters:
round- The value for round- Returns:
thisbuilder for use in a chained invocation
-
addAnnotations
Adds one element toannotationsset.- Parameters:
element- A annotations element- Returns:
thisbuilder for use in a chained invocation
-
addAnnotations
Adds elements toannotationsset.- Parameters:
elements- An array of annotations elements- Returns:
thisbuilder for use in a chained invocation
-
addAllAnnotations
Adds elements toannotationsset.- Parameters:
elements- An iterable of annotations elements- Returns:
thisbuilder for use in a chained invocation
-
addCustomImmutableAnnotations
Adds one element tocustomImmutableAnnotationsset.- Parameters:
element- A customImmutableAnnotations element- Returns:
thisbuilder for use in a chained invocation
-
addCustomImmutableAnnotations
Adds elements tocustomImmutableAnnotationsset.- Parameters:
elements- An array of customImmutableAnnotations elements- Returns:
thisbuilder for use in a chained invocation
-
addAllCustomImmutableAnnotations
Adds elements tocustomImmutableAnnotationsset.- Parameters:
elements- An iterable of customImmutableAnnotations elements- Returns:
thisbuilder for use in a chained invocation
-
build
Builds a newImmutableRound.- Returns:
- An immutable instance of Round
- Throws:
IllegalStateException- if any required attributes are missing
-
processingIsSet
private boolean processingIsSet() -
roundIsSet
private boolean roundIsSet() -
checkNotIsSet
-
checkRequiredAttributes
private void checkRequiredAttributes() -
formatRequiredAttributesMessage
-