Class TypedElementInfo.BuilderBase<BUILDER extends TypedElementInfo.BuilderBase<BUILDER,PROTOTYPE>,PROTOTYPE extends TypedElementInfo>
- Type Parameters:
BUILDER
- type of the builder extending this abstract builderPROTOTYPE
- type of the prototype interface that would be built byPrototype.Builder.buildPrototype()
- All Implemented Interfaces:
Prototype.Builder<BUILDER,
PROTOTYPE>
- Direct Known Subclasses:
TypedElementInfo.Builder
- Enclosing interface:
TypedElementInfo
TypedElementInfo
.-
Nested Class Summary
Modifier and TypeClassDescriptionprotected static class
Generated implementation of the prototype, can be extended by descendant prototype implementations. -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionAccess modifier of the element.accessModifier
(AccessModifier accessModifier) Access modifier of the element.addAnnotation
(Annotation annotation) List of declared and known annotations for this element.addAnnotation
(Consumer<Annotation.Builder> consumer) List of declared and known annotations for this element.addAnnotations
(List<? extends Annotation> annotations) List of declared and known annotations for this element.addComponentTypes
(List<? extends TypeName> componentTypes) Returns the component type names describing the element.addElementModifier
(Modifier elementModifier) Element modifiers.addElementModifiers
(Set<? extends Modifier> elementModifiers) Element modifiers.addElementTypeAnnotations
(List<? extends Annotation> elementTypeAnnotations) The list of known annotations on the type name referenced bytypeName()
.addInheritedAnnotation
(Annotation inheritedAnnotation) List of all inherited annotations for this element.addInheritedAnnotation
(Consumer<Annotation.Builder> consumer) List of all inherited annotations for this element.addInheritedAnnotations
(List<? extends Annotation> inheritedAnnotations) List of all inherited annotations for this element.addModifier
(String modifier) Deprecated, for removal: This API element is subject to removal in a future version.addModifiers
(Set<? extends String> modifiers) Element modifiers.addParameterArgument
(TypedElementInfo parameterArgument) Parameter arguments applicable if this type element represents aElementKind.METHOD
.addParameterArgument
(Consumer<TypedElementInfo.Builder> consumer) Parameter arguments applicable if this type element represents aElementKind.METHOD
.addParameterArguments
(List<? extends TypedElementInfo> parameterArguments) Parameter arguments applicable if this type element represents aElementKind.METHOD
.addThrowsChecked
(Set<? extends TypeName> throwsChecked) List of declared and known annotations for this element.annotations
(List<? extends Annotation> annotations) List of declared and known annotations for this element.Clear existing value of this property.Clear existing value of this property.Clear existing value of this property.Clear existing value of this property.Returns the component type names describing the element.componentTypes
(List<? extends TypeName> componentTypes) Returns the component type names describing the element.The default value assigned to the element, represented as a string.defaultValue
(String defaultValue) The default value assigned to the element, represented as a string.Description, such as javadoc, if available.description
(String description) Description, such as javadoc, if available.Element modifiers.elementModifiers
(Set<? extends Modifier> elementModifiers) Element modifiers.The element (e.g., method, field, etc) name.elementName
(String elementName) The element (e.g., method, field, etc) name.The list of known annotations on the type name referenced bytypeName()
.elementTypeAnnotations
(List<? extends Annotation> elementTypeAnnotations) The list of known annotations on the type name referenced bytypeName()
.Deprecated, for removal: This API element is subject to removal in a future version.usekind()
insteadelementTypeKind
(String elementTypeKind) Deprecated, for removal: This API element is subject to removal in a future version.usekind()
insteadThe enclosing type name for this typed element.enclosingType
(TypeName enclosingType) The enclosing type name for this typed element.enclosingType
(Consumer<TypeName.Builder> consumer) The enclosing type name for this typed element.from
(TypedElementInfo prototype) Update this builder from an existing prototype instance.from
(TypedElementInfo.BuilderBase<?, ?> builder) Update this builder from an existing prototype builder instance.List of all inherited annotations for this element.inheritedAnnotations
(List<? extends Annotation> inheritedAnnotations) List of all inherited annotations for this element.kind()
The kind of element (e.g., method, field, etc).kind
(ElementKind kind) The kind of element (e.g., method, field, etc).Deprecated, for removal: This API element is subject to removal in a future version.useelementModifiers()
insteadElement modifiers.The element used to create this instance.originatingElement
(Object originatingElement) The element used to create this instance.Parameter arguments applicable if this type element represents aElementKind.METHOD
.parameterArguments
(List<? extends TypedElementInfo> parameterArguments) Parameter arguments applicable if this type element represents aElementKind.METHOD
.protected void
Handles providers and decorators.throwsChecked
(Set<? extends TypeName> throwsChecked) typeName()
The type name for the element (e.g., java.util.List).The type name for the element (e.g., java.util.List).typeName
(Consumer<TypeName.Builder> consumer) The type name for the element (e.g., java.util.List).The type name for the element (e.g., java.util.List).protected void
Validates required properties.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface io.helidon.builder.api.Prototype.Builder
buildPrototype, self
-
Constructor Details
-
BuilderBase
protected BuilderBase()Protected to support extensibility.
-
-
Method Details
-
from
Update this builder from an existing prototype instance.- Parameters:
prototype
- existing prototype to update this builder from- Returns:
- updated builder instance
-
from
Update this builder from an existing prototype builder instance.- Parameters:
builder
- existing builder prototype to update this builder from- Returns:
- updated builder instance
-
clearDescription
Clear existing value of this property.- Returns:
- updated builder instance
- See Also:
-
description
Description, such as javadoc, if available.- Parameters:
description
- description of this element- Returns:
- updated builder instance
- See Also:
-
typeName
The type name for the element (e.g., java.util.List). If the element is a method, then this is the return type of the method.- Parameters:
typeName
- the type name of the element- Returns:
- updated builder instance
- See Also:
-
typeName
The type name for the element (e.g., java.util.List). If the element is a method, then this is the return type of the method.- Parameters:
consumer
- consumer of builder for the type name of the element- Returns:
- updated builder instance
- See Also:
-
typeName
The type name for the element (e.g., java.util.List). If the element is a method, then this is the return type of the method.- Parameters:
supplier
- supplier of the type name of the element- Returns:
- updated builder instance
- See Also:
-
elementName
The element (e.g., method, field, etc) name.- Parameters:
elementName
- the name of the element- Returns:
- updated builder instance
- See Also:
-
elementTypeKind
Deprecated, for removal: This API element is subject to removal in a future version.usekind()
insteadThe kind of element (e.g., method, field, etc).- Parameters:
elementTypeKind
- the element kind- Returns:
- updated builder instance
- See Also:
-
kind
The kind of element (e.g., method, field, etc).- Parameters:
kind
- the element kind- Returns:
- updated builder instance
- See Also:
-
clearDefaultValue
Clear existing value of this property.- Returns:
- updated builder instance
- See Also:
-
defaultValue
The default value assigned to the element, represented as a string.- Parameters:
defaultValue
- the default value as a string- Returns:
- updated builder instance
- See Also:
-
elementTypeAnnotations
The list of known annotations on the type name referenced bytypeName()
.- Parameters:
elementTypeAnnotations
- the list of annotations on this element's (return) type.- Returns:
- updated builder instance
- See Also:
-
addElementTypeAnnotations
The list of known annotations on the type name referenced bytypeName()
.- Parameters:
elementTypeAnnotations
- the list of annotations on this element's (return) type.- Returns:
- updated builder instance
- See Also:
-
componentTypes
Returns the component type names describing the element.- Parameters:
componentTypes
- the component type names of the element- Returns:
- updated builder instance
- See Also:
-
addComponentTypes
Returns the component type names describing the element.- Parameters:
componentTypes
- the component type names of the element- Returns:
- updated builder instance
- See Also:
-
modifiers
Element modifiers.- Parameters:
modifiers
- element modifiers- Returns:
- updated builder instance
- See Also:
-
addModifiers
Element modifiers.- Parameters:
modifiers
- element modifiers- Returns:
- updated builder instance
- See Also:
-
addModifier
Deprecated, for removal: This API element is subject to removal in a future version.useelementModifiers()
insteadElement modifiers.- Parameters:
modifier
- element modifiers- Returns:
- updated builder instance
- See Also:
-
elementModifiers
Element modifiers.- Parameters:
elementModifiers
- element modifiers- Returns:
- updated builder instance
- See Also:
-
addElementModifiers
Element modifiers.- Parameters:
elementModifiers
- element modifiers- Returns:
- updated builder instance
- See Also:
-
addElementModifier
Element modifiers.- Parameters:
elementModifier
- element modifiers- Returns:
- updated builder instance
- See Also:
-
accessModifier
Access modifier of the element.- Parameters:
accessModifier
- access modifier- Returns:
- updated builder instance
- See Also:
-
clearEnclosingType
Clear existing value of this property.- Returns:
- updated builder instance
- See Also:
-
enclosingType
The enclosing type name for this typed element. Applicable when this instance represents aElementKind.FIELD
, orElementKind.METHOD
, orElementKind.PARAMETER
- Parameters:
enclosingType
- the enclosing type element- Returns:
- updated builder instance
- See Also:
-
enclosingType
The enclosing type name for this typed element. Applicable when this instance represents aElementKind.FIELD
, orElementKind.METHOD
, orElementKind.PARAMETER
- Parameters:
consumer
- the enclosing type element- Returns:
- updated builder instance
- See Also:
-
parameterArguments
Parameter arguments applicable if this type element represents aElementKind.METHOD
. Each instance of this list will be the individualElementKind.PARAMETER
's for the method.- Parameters:
parameterArguments
- the list of parameters belonging to this method if applicable- Returns:
- updated builder instance
- See Also:
-
addParameterArguments
Parameter arguments applicable if this type element represents aElementKind.METHOD
. Each instance of this list will be the individualElementKind.PARAMETER
's for the method.- Parameters:
parameterArguments
- the list of parameters belonging to this method if applicable- Returns:
- updated builder instance
- See Also:
-
addParameterArgument
Parameter arguments applicable if this type element represents aElementKind.METHOD
. Each instance of this list will be the individualElementKind.PARAMETER
's for the method.- Parameters:
parameterArgument
- the list of parameters belonging to this method if applicable- Returns:
- updated builder instance
- See Also:
-
addParameterArgument
Parameter arguments applicable if this type element represents aElementKind.METHOD
. Each instance of this list will be the individualElementKind.PARAMETER
's for the method.- Parameters:
consumer
- the list of parameters belonging to this method if applicable- Returns:
- updated builder instance
- See Also:
-
throwsChecked
- Parameters:
throwsChecked
- set of thrown checked types- Returns:
- updated builder instance
- See Also:
-
addThrowsChecked
- Parameters:
throwsChecked
- set of thrown checked types- Returns:
- updated builder instance
- See Also:
-
clearOriginatingElement
Clear existing value of this property.- Returns:
- updated builder instance
- See Also:
-
originatingElement
The element used to create this instance. The type of the object depends on the environment we are in - it may be anElement
in annotation processing, or aMethodInfo
(and such) when using classpath scanning.- Parameters:
originatingElement
- originating element- Returns:
- updated builder instance
- See Also:
-
annotations
List of declared and known annotations for this element. Note that "known" implies that the annotation is visible, which depends upon the context in which it was build (such as theof the annotation
).- Parameters:
annotations
- the list of annotations declared on this element- Returns:
- updated builder instance
- See Also:
-
addAnnotations
List of declared and known annotations for this element. Note that "known" implies that the annotation is visible, which depends upon the context in which it was build (such as theof the annotation
).- Parameters:
annotations
- the list of annotations declared on this element- Returns:
- updated builder instance
- See Also:
-
addAnnotation
List of declared and known annotations for this element. Note that "known" implies that the annotation is visible, which depends upon the context in which it was build (such as theof the annotation
).- Parameters:
annotation
- the list of annotations declared on this element- Returns:
- updated builder instance
- See Also:
-
addAnnotation
List of declared and known annotations for this element. Note that "known" implies that the annotation is visible, which depends upon the context in which it was build (such as theof the annotation
).- Parameters:
consumer
- the list of annotations declared on this element- Returns:
- updated builder instance
- See Also:
-
inheritedAnnotations
List of all inherited annotations for this element. Inherited annotations are annotations declared on annotations of this element that are also marked asInherited
.The returned list does not contain
annotations()
. If a meta-annotation is present on multiple annotations, it will be returned once for each such declaration.- Parameters:
inheritedAnnotations
- list of all meta annotations of this element- Returns:
- updated builder instance
- See Also:
-
addInheritedAnnotations
List of all inherited annotations for this element. Inherited annotations are annotations declared on annotations of this element that are also marked asInherited
.The returned list does not contain
annotations()
. If a meta-annotation is present on multiple annotations, it will be returned once for each such declaration.- Parameters:
inheritedAnnotations
- list of all meta annotations of this element- Returns:
- updated builder instance
- See Also:
-
addInheritedAnnotation
List of all inherited annotations for this element. Inherited annotations are annotations declared on annotations of this element that are also marked asInherited
.The returned list does not contain
annotations()
. If a meta-annotation is present on multiple annotations, it will be returned once for each such declaration.- Parameters:
inheritedAnnotation
- list of all meta annotations of this element- Returns:
- updated builder instance
- See Also:
-
addInheritedAnnotation
List of all inherited annotations for this element. Inherited annotations are annotations declared on annotations of this element that are also marked asInherited
.The returned list does not contain
annotations()
. If a meta-annotation is present on multiple annotations, it will be returned once for each such declaration.- Parameters:
consumer
- list of all meta annotations of this element- Returns:
- updated builder instance
- See Also:
-
description
Description, such as javadoc, if available.- Returns:
- the description
-
typeName
The type name for the element (e.g., java.util.List). If the element is a method, then this is the return type of the method.- Returns:
- the type name
-
elementName
The element (e.g., method, field, etc) name.- Returns:
- the element name
-
elementTypeKind
Deprecated, for removal: This API element is subject to removal in a future version.usekind()
insteadThe kind of element (e.g., method, field, etc).- Returns:
- the element type kind
- See Also:
-
kind
The kind of element (e.g., method, field, etc).- Returns:
- the kind
- See Also:
-
defaultValue
The default value assigned to the element, represented as a string.- Returns:
- the default value
-
elementTypeAnnotations
The list of known annotations on the type name referenced bytypeName()
.- Returns:
- the element type annotations
-
componentTypes
Returns the component type names describing the element.- Returns:
- the component types
-
modifiers
Deprecated, for removal: This API element is subject to removal in a future version.useelementModifiers()
insteadElement modifiers.- Returns:
- the modifiers
- See Also:
-
elementModifiers
Element modifiers.- Returns:
- the element modifiers
- See Also:
-
accessModifier
Access modifier of the element.- Returns:
- the access modifier
-
enclosingType
The enclosing type name for this typed element. Applicable when this instance represents aElementKind.FIELD
, orElementKind.METHOD
, orElementKind.PARAMETER
- Returns:
- the enclosing type
-
parameterArguments
Parameter arguments applicable if this type element represents aElementKind.METHOD
. Each instance of this list will be the individualElementKind.PARAMETER
's for the method.- Returns:
- the parameter arguments
-
throwsChecked
- Returns:
- the throws checked
-
originatingElement
The element used to create this instance. The type of the object depends on the environment we are in - it may be anElement
in annotation processing, or aMethodInfo
(and such) when using classpath scanning.- Returns:
- the originating element
-
annotations
List of declared and known annotations for this element. Note that "known" implies that the annotation is visible, which depends upon the context in which it was build (such as theof the annotation
).- Returns:
- the annotations
-
inheritedAnnotations
List of all inherited annotations for this element. Inherited annotations are annotations declared on annotations of this element that are also marked asInherited
.The returned list does not contain
annotations()
. If a meta-annotation is present on multiple annotations, it will be returned once for each such declaration.- Returns:
- the inherited annotations
-
preBuildPrototype
protected void preBuildPrototype()Handles providers and decorators. -
validatePrototype
protected void validatePrototype()Validates required properties.
-
elementModifiers()
instead