@NotThreadSafe public static final class ImmutableProcedureMeta.Builder extends Object
ImmutableProcedureMeta.
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.
| Modifier and Type | Method and Description |
|---|---|
ImmutableProcedureMeta.Builder |
addAllArgs(Iterable<? extends ArgumentMeta> elements)
Adds elements to
args list. |
ImmutableProcedureMeta.Builder |
addArgs(ArgumentMeta... elements)
Adds elements to
args list. |
ImmutableProcedureMeta.Builder |
addArgs(ArgumentMeta element)
Adds one element to
args list. |
ImmutableProcedureMeta.Builder |
args(Iterable<? extends ArgumentMeta> elements)
Sets or replaces all elements for
args list. |
ImmutableProcedureMeta |
build()
Builds a new
ImmutableProcedureMeta. |
ImmutableProcedureMeta.Builder |
comment(Optional<String> comment)
Initializes the optional value
comment to comment. |
ImmutableProcedureMeta.Builder |
comment(String comment)
Initializes the optional value
comment to comment. |
ImmutableProcedureMeta.Builder |
from(ProcedureMeta instance)
Fill a builder with attribute values from the provided
ProcedureMeta instance. |
ImmutableProcedureMeta.Builder |
name(String name)
Initializes the value for the
name attribute. |
@CanIgnoreReturnValue public final ImmutableProcedureMeta.Builder from(ProcedureMeta instance)
ProcedureMeta instance.
Regular attribute values will be replaced with those from the given instance.
Absent optional values will not replace present values.
Collection elements and entries will be added, not replaced.instance - The instance from which to copy valuesthis builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableProcedureMeta.Builder name(String name)
name attribute.name - The value for namethis builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableProcedureMeta.Builder addArgs(ArgumentMeta element)
args list.element - A args elementthis builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableProcedureMeta.Builder addArgs(ArgumentMeta... elements)
args list.elements - An array of args elementsthis builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableProcedureMeta.Builder args(Iterable<? extends ArgumentMeta> elements)
args list.elements - An iterable of args elementsthis builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableProcedureMeta.Builder addAllArgs(Iterable<? extends ArgumentMeta> elements)
args list.elements - An iterable of args elementsthis builder for use in a chained invocation@CanIgnoreReturnValue public final ImmutableProcedureMeta.Builder comment(String comment)
comment to comment.comment - The value for commentthis builder for chained invocation@CanIgnoreReturnValue public final ImmutableProcedureMeta.Builder comment(Optional<String> comment)
comment to comment.comment - The value for commentthis builder for use in a chained invocationpublic ImmutableProcedureMeta build()
ImmutableProcedureMeta.IllegalStateException - if any required attributes are missingCopyright © 2019–2021 Nuiton. All rights reserved.