Package io.substrait.type
Class ImmutableType.UserDefined.Builder
java.lang.Object
io.substrait.type.ImmutableType.UserDefined.Builder
- Enclosing class:
- ImmutableType.UserDefined
Builds instances of type
UserDefined.
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.
-
Method Summary
Modifier and TypeMethodDescriptionaddAllTypeParameters(Iterable<? extends Type.Parameter> elements) Adds elements totypeParameterslist.addTypeParameters(Type.Parameter element) Adds one element totypeParameterslist.addTypeParameters(Type.Parameter... elements) Adds elements totypeParameterslist.build()Builds a newUserDefined.from(NullableType instance) Fill a builder with attribute values from the providedio.substrait.function.NullableTypeinstance.Fill a builder with attribute values from the providedio.substrait.type.Typeinstance.from(Type.UserDefined instance) Fill a builder with attribute values from the providedio.substrait.type.Type.UserDefinedinstance.Initializes the value for thenameattribute.nullable(boolean nullable) Initializes the value for thenullableattribute.typeParameters(Iterable<? extends Type.Parameter> elements) Sets or replaces all elements fortypeParameterslist.Initializes the value for theurnattribute.
-
Method Details
-
from
Fill a builder with attribute values from the providedio.substrait.function.NullableTypeinstance.- Parameters:
instance- The instance from which to copy values- Returns:
thisbuilder for use in a chained invocation
-
from
Fill a builder with attribute values from the providedio.substrait.type.Typeinstance.- Parameters:
instance- The instance from which to copy values- Returns:
thisbuilder for use in a chained invocation
-
from
Fill a builder with attribute values from the providedio.substrait.type.Type.UserDefinedinstance.- Parameters:
instance- The instance from which to copy values- Returns:
thisbuilder for use in a chained invocation
-
nullable
Initializes the value for thenullableattribute.- Parameters:
nullable- The value for nullable- Returns:
thisbuilder for use in a chained invocation
-
urn
Initializes the value for theurnattribute.- Parameters:
urn- The value for urn- Returns:
thisbuilder for use in a chained invocation
-
name
Initializes the value for thenameattribute.- Parameters:
name- The value for name- Returns:
thisbuilder for use in a chained invocation
-
addTypeParameters
Adds one element totypeParameterslist.- Parameters:
element- A typeParameters element- Returns:
thisbuilder for use in a chained invocation
-
addTypeParameters
Adds elements totypeParameterslist.- Parameters:
elements- An array of typeParameters elements- Returns:
thisbuilder for use in a chained invocation
-
typeParameters
public final ImmutableType.UserDefined.Builder typeParameters(Iterable<? extends Type.Parameter> elements) Sets or replaces all elements fortypeParameterslist.- Parameters:
elements- An iterable of typeParameters elements- Returns:
thisbuilder for use in a chained invocation
-
addAllTypeParameters
public final ImmutableType.UserDefined.Builder addAllTypeParameters(Iterable<? extends Type.Parameter> elements) Adds elements totypeParameterslist.- Parameters:
elements- An iterable of typeParameters elements- Returns:
thisbuilder for use in a chained invocation
-
build
Builds a newUserDefined.- Returns:
- An immutable instance of UserDefined
- Throws:
IllegalStateException- if any required attributes are missing
-