Class Field.Builder
java.lang.Object
io.helidon.common.processor.classmodel.Field.Builder
- All Implemented Interfaces:
Builder<Field.Builder,
,Field> Supplier<Field>
- Enclosing class:
Field
Fluent API builder for
Field
.-
Method Summary
Modifier and TypeMethodDescriptionaccessModifier
(AccessModifier accessModifier) addAnnotation
(Annotation annotation) Add new annotation to the component.addAnnotation
(Annotation.Builder builder) Add new annotation to the component.addAnnotation
(Consumer<Annotation.Builder> consumer) Add new annotation to the component.addDescriptionLine
(String line) build()
Build the instance from this builder.defaultValue
(String defaultValue) Set default value this field should be initialized with, wrapping the value in double quotes if the field type is String.defaultValueContent
(String defaultValue) Configure a default value for this field as a string that will be copied verbatim to the generated sources.description
(String description) description
(List<String> description) includeImport
(boolean includeImport) Whether to include import type information among the imports.isFinal
(boolean isFinal) Whether this field is final.isStatic
(boolean isStatic) Whether this field is static.
-
Method Details
-
build
Description copied from interface:Builder
Build the instance from this builder.- Returns:
- instance of the built type
-
defaultValue
Set default value this field should be initialized with, wrapping the value in double quotes if the field type is String.- Parameters:
defaultValue
- default value- Returns:
- updated builder instance
-
defaultValueContent
Configure a default value for this field as a string that will be copied verbatim to the generated sources.- Parameters:
defaultValue
- default value- Returns:
- updated builder instance
-
isFinal
Whether this field is final.- Parameters:
isFinal
- final field- Returns:
- updated builder instance
-
isStatic
Whether this field is static.- Parameters:
isStatic
- static field- Returns:
- updated builder instance
-
type
-
type
-
type
-
accessModifier
-
description
-
description
-
addDescriptionLine
-
addAnnotation
Add new annotation to the component.- Parameters:
consumer
- annotation builder consumer- Returns:
- updated builder instance
-
addAnnotation
Add new annotation to the component.- Parameters:
builder
- annotation builder- Returns:
- updated builder instance
-
addAnnotation
Add new annotation to the component.- Parameters:
annotation
- annotation instance- Returns:
- updated builder instance
-
name
-
includeImport
Whether to include import type information among the imports.- Parameters:
includeImport
-- Returns:
-