Class AnnotationAttributeConfigurationImpl.BuilderImpl
java.lang.Object
org.infinispan.protostream.config.impl.AnnotationAttributeConfigurationImpl.BuilderImpl
- All Implemented Interfaces:
AnnotationAttributeConfiguration.Builder
- Enclosing class:
AnnotationAttributeConfigurationImpl
static final class AnnotationAttributeConfigurationImpl.BuilderImpl
extends Object
implements AnnotationAttributeConfiguration.Builder
-
Field Summary
FieldsModifier and TypeFieldDescription(package private) String[]The set of allowed values.(package private) Object(package private) booleanprivate final StringThe attribute name.private StringThe package name.private final AnnotationConfiguration.Builder(package private) AnnotationElement.AttributeTypeThe type. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionallowedValues(String... allowedValues) annotation(String annotationName, AnnotationElement.AnnotationTarget... target) Starts the creation of a new annotation with the given name and return its builder to continue define it.Create a new attribute with the given name and return the builder to configure it.build()(package private) AnnotationAttributeConfigurationdefaultValue(Object defaultValue) metadataCreator(AnnotationMetadataCreator<?, ? extends AnnotatedDescriptor> annotationMetadataCreator) multiple(boolean isMultiple) packageName(String packageName) Sets the optional package namerepeatable(String containingAnnotationName) The type.
-
Field Details
-
parentBuilder
-
name
The attribute name. -
packageName
The package name. -
type
The type. Defaults to String if not explicitly set. -
isMultiple
boolean isMultiple -
defaultValue
Object defaultValue -
allowedValues
String[] allowedValuesThe set of allowed values. This is only used with STRING, IDENTIFIER, or ANNOTATION type.
-
-
Constructor Details
-
BuilderImpl
BuilderImpl(AnnotationConfiguration.Builder parentBuilder, String name)
-
-
Method Details
-
type
Description copied from interface:AnnotationAttributeConfiguration.BuilderThe type. Defaults to String if not explicitly set.- Specified by:
typein interfaceAnnotationAttributeConfiguration.Builder
-
multiple
- Specified by:
multiplein interfaceAnnotationAttributeConfiguration.Builder
-
defaultValue
- Specified by:
defaultValuein interfaceAnnotationAttributeConfiguration.Builder
-
allowedValues
- Specified by:
allowedValuesin interfaceAnnotationAttributeConfiguration.Builder
-
attribute
Description copied from interface:AnnotationAttributeConfiguration.BuilderCreate a new attribute with the given name and return the builder to configure it.- Specified by:
attributein interfaceAnnotationAttributeConfiguration.Builder
-
metadataCreator
public AnnotationAttributeConfiguration.Builder metadataCreator(AnnotationMetadataCreator<?, ? extends AnnotatedDescriptor> annotationMetadataCreator) - Specified by:
metadataCreatorin interfaceAnnotationAttributeConfiguration.Builder
-
repeatable
- Specified by:
repeatablein interfaceAnnotationAttributeConfiguration.Builder
-
packageName
Description copied from interface:AnnotationAttributeConfiguration.BuilderSets the optional package name- Specified by:
packageNamein interfaceAnnotationAttributeConfiguration.Builder
-
buildAnnotationAttributeConfiguration
AnnotationAttributeConfiguration buildAnnotationAttributeConfiguration() -
parentBuilder
- Specified by:
parentBuilderin interfaceAnnotationAttributeConfiguration.Builder- Returns:
- the parent builder in order to allow defining more annotations
-
annotation
public AnnotationConfiguration.Builder annotation(String annotationName, AnnotationElement.AnnotationTarget... target) Description copied from interface:AnnotationAttributeConfiguration.BuilderStarts the creation of a new annotation with the given name and return its builder to continue define it.- Specified by:
annotationin interfaceAnnotationAttributeConfiguration.Builder
-
build
- Specified by:
buildin interfaceAnnotationAttributeConfiguration.Builder
-