Package io.substrait.extension
Class ImmutableSimpleExtension.TypeAnchor
java.lang.Object
io.substrait.extension.ImmutableSimpleExtension.TypeAnchor
- All Implemented Interfaces:
SimpleExtension.Anchor,SimpleExtension.TypeAnchor
- Enclosing class:
- ImmutableSimpleExtension
public static final class ImmutableSimpleExtension.TypeAnchor
extends Object
implements SimpleExtension.TypeAnchor
Immutable implementation of
SimpleExtension.TypeAnchor.
Use the builder to create immutable instances:
ImmutableSimpleExtension.TypeAnchor.builder().
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionbuilder()Creates a builder forTypeAnchor.copyOf(SimpleExtension.TypeAnchor instance) Creates an immutable copy of aSimpleExtension.TypeAnchorvalue.booleanThis instance is equal to all instances ofTypeAnchorthat have equal attribute values.inthashCode()Computes a hash code from attributes:urn,key.key()toString()Prints the immutable valueTypeAnchorwith attribute values.urn()Copy the current immutable object by setting a value for thekeyattribute.Copy the current immutable object by setting a value for theurnattribute.
-
Method Details
-
urn
- Specified by:
urnin interfaceSimpleExtension.Anchor- Returns:
- The value of the
urnattribute
-
key
- Specified by:
keyin interfaceSimpleExtension.Anchor- Returns:
- The value of the
keyattribute
-
withUrn
Copy the current immutable object by setting a value for theurnattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for urn- Returns:
- A modified copy or the
thisobject
-
withKey
Copy the current immutable object by setting a value for thekeyattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for key- Returns:
- A modified copy or the
thisobject
-
equals
This instance is equal to all instances ofTypeAnchorthat have equal attribute values. -
hashCode
public int hashCode()Computes a hash code from attributes:urn,key. -
toString
Prints the immutable valueTypeAnchorwith attribute values. -
copyOf
Creates an immutable copy of aSimpleExtension.TypeAnchorvalue. 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 TypeAnchor instance
-
builder
Creates a builder forTypeAnchor.ImmutableSimpleExtension.TypeAnchor.builder() .urn(String) // requiredurn.key(String) // requiredkey.build();- Returns:
- A new TypeAnchor builder
-