Package io.substrait.relation
Class ImmutableExpand
java.lang.Object
io.substrait.relation.AbstractRel
io.substrait.relation.SingleInputRel
io.substrait.relation.Expand
io.substrait.relation.ImmutableExpand
- All Implemented Interfaces:
Rel
Immutable implementation of
Expand.
Use the builder to create immutable instances:
ImmutableExpand.builder().
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classBuilds instances of typeImmutableExpand.static final classImmutable implementation ofExpand.ConsistentField.static final classImmutable implementation ofExpand.SwitchingField.Nested classes/interfaces inherited from class io.substrait.relation.Expand
Expand.ExpandField -
Method Summary
Modifier and TypeMethodDescriptionstatic ImmutableExpand.Builderbuilder()Creates a builder forImmutableExpand.static ImmutableExpandCreates an immutable copy of aExpandvalue.booleanThis instance is equal to all instances ofImmutableExpandthat have equal attribute values.Returns the fields produced by the expand operation.getHint()getInput()getRemap()inthashCode()Computes a hash code from attributes:remap,commonExtension,hint,input,fields.toString()Prints the immutable valueExpandwith attribute values.final ImmutableExpandCopy the current immutable object by setting a present value for the optionalcommonExtensionattribute.final ImmutableExpandwithCommonExtension(Optional<? extends AdvancedExtension> optional) Copy the current immutable object by setting an optional value for thecommonExtensionattribute.final ImmutableExpandwithFields(Expand.ExpandField... elements) Copy the current immutable object with elements that replace the content offields.final ImmutableExpandwithFields(Iterable<? extends Expand.ExpandField> elements) Copy the current immutable object with elements that replace the content offields.final ImmutableExpandCopy the current immutable object by setting a present value for the optionalhintattribute.final ImmutableExpandCopy the current immutable object by setting an optional value for thehintattribute.final ImmutableExpandCopy the current immutable object by setting a value for theinputattribute.final ImmutableExpandCopy the current immutable object by setting a present value for the optionalremapattribute.final ImmutableExpandCopy the current immutable object by setting an optional value for theremapattribute.Methods inherited from class io.substrait.relation.Expand
accept, deriveRecordTypeMethods inherited from class io.substrait.relation.SingleInputRel
getInputsMethods inherited from class io.substrait.relation.AbstractRel
getRecordType
-
Method Details
-
getRemap
- Returns:
- The value of the
remapattribute
-
getCommonExtension
- Returns:
- the
AdvancedExtensionassociated with aRelCommonmessage, if present
-
getHint
- Returns:
- The value of the
hintattribute
-
getInput
- Specified by:
getInputin classSingleInputRel- Returns:
- The value of the
inputattribute
-
getFields
Returns the fields produced by the expand operation. -
withRemap
Copy the current immutable object by setting a present value for the optionalremapattribute.- Parameters:
value- The value for remap- Returns:
- A modified copy or
thisif not changed
-
withRemap
Copy the current immutable object by setting an optional value for theremapattribute. A shallow reference equality check is used on unboxed optional value to prevent copying of the same value by returningthis.- Parameters:
optional- An optional value for remap- Returns:
- A modified copy or
thisif not changed
-
withCommonExtension
Copy the current immutable object by setting a present value for the optionalcommonExtensionattribute.- Parameters:
value- The value for commonExtension- Returns:
- A modified copy or
thisif not changed
-
withCommonExtension
Copy the current immutable object by setting an optional value for thecommonExtensionattribute. A shallow reference equality check is used on unboxed optional value to prevent copying of the same value by returningthis.- Parameters:
optional- An optional value for commonExtension- Returns:
- A modified copy or
thisif not changed
-
withHint
Copy the current immutable object by setting a present value for the optionalhintattribute.- Parameters:
value- The value for hint- Returns:
- A modified copy or
thisif not changed
-
withHint
Copy the current immutable object by setting an optional value for thehintattribute. A shallow reference equality check is used on unboxed optional value to prevent copying of the same value by returningthis.- Parameters:
optional- An optional value for hint- Returns:
- A modified copy or
thisif not changed
-
withInput
Copy the current immutable object by setting a value for theinputattribute. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for input- Returns:
- A modified copy or the
thisobject
-
withFields
Copy the current immutable object with elements that replace the content offields.- Parameters:
elements- The elements to set- Returns:
- A modified copy of
thisobject
-
withFields
Copy the current immutable object with elements that replace the content offields. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
elements- An iterable of fields elements to set- Returns:
- A modified copy or
thisif not changed
-
equals
This instance is equal to all instances ofImmutableExpandthat have equal attribute values. -
hashCode
public int hashCode()Computes a hash code from attributes:remap,commonExtension,hint,input,fields. -
toString
Prints the immutable valueExpandwith attribute values. -
copyOf
Creates an immutable copy of aExpandvalue. Uses accessors to get values to initialize the new immutable instance. If an instance is already immutable, it is returned as is.- Parameters:
instance- The instance to copy- Returns:
- A copied immutable Expand instance
-
builder
Creates a builder forImmutableExpand.ImmutableExpand.builder() .remap(Optional<io.substrait.relation.Rel.Remap>) // optionalremap.commonExtension(Optional<io.substrait.extension.AdvancedExtension>) // optionalcommonExtension.hint(Optional<io.substrait.hint.Hint>) // optionalhint.input(io.substrait.relation.Rel) // requiredinput.addFields|addAllFields(io.substrait.relation.Expand.ExpandField) //fieldselements .build();- Returns:
- A new ImmutableExpand builder
-