Package org.projectnessie.model
Class ImmutableIcebergTable
- java.lang.Object
-
- org.projectnessie.model.Content
-
- org.projectnessie.model.IcebergTable
-
- org.projectnessie.model.ImmutableIcebergTable
-
@ParametersAreNonnullByDefault @Generated("org.immutables.processor.ProxyProcessor") @Immutable @CheckReturnValue public final class ImmutableIcebergTable extends IcebergTable
Immutable implementation ofIcebergTable.Use the builder to create immutable instances:
ImmutableIcebergTable.builder().
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classImmutableIcebergTable.BuilderBuilds instances of typeImmutableIcebergTable.-
Nested classes/interfaces inherited from class org.projectnessie.model.Content
Content.Type
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static ImmutableIcebergTable.Builderbuilder()Creates a builder forImmutableIcebergTable.static ImmutableIcebergTablecopyOf(IcebergTable instance)Creates an immutable copy of aIcebergTablevalue.booleanequals(Object another)This instance is equal to all instances ofImmutableIcebergTablethat have equal attribute values.StringgetId()Unique id for this object.StringgetMetadataLocation()Location where Iceberg stored itsTableMetadatafile.intgetSchemaId()longgetSnapshotId()intgetSortOrderId()intgetSpecId()inthashCode()Computes a hash code from attributes:id,metadataLocation,snapshotId,schemaId,specId,sortOrderId.StringtoString()Prints the immutable valueIcebergTablewith attribute values.ImmutableIcebergTablewithId(String value)Copy the current immutable object by setting a value for theidattribute.ImmutableIcebergTablewithMetadataLocation(String value)Copy the current immutable object by setting a value for themetadataLocationattribute.ImmutableIcebergTablewithSchemaId(int value)Copy the current immutable object by setting a value for theschemaIdattribute.ImmutableIcebergTablewithSnapshotId(long value)Copy the current immutable object by setting a value for thesnapshotIdattribute.ImmutableIcebergTablewithSortOrderId(int value)Copy the current immutable object by setting a value for thesortOrderIdattribute.ImmutableIcebergTablewithSpecId(int value)Copy the current immutable object by setting a value for thespecIdattribute.-
Methods inherited from class org.projectnessie.model.IcebergTable
getType, of, of
-
-
-
-
Method Detail
-
getId
public String getId()
Unique id for this object.This id is unique for the entire lifetime of this Content object and persists across renames. Two content objects with the same key will have different id.
-
getMetadataLocation
public String getMetadataLocation()
Location where Iceberg stored itsTableMetadatafile. The location depends on the (implementation of) Iceberg'sFileIOconfigured for the particular Iceberg table.- Specified by:
getMetadataLocationin classIcebergTable
-
getSnapshotId
public long getSnapshotId()
- Specified by:
getSnapshotIdin classIcebergTable- Returns:
- The value of the
snapshotIdattribute
-
getSchemaId
public int getSchemaId()
- Specified by:
getSchemaIdin classIcebergTable- Returns:
- The value of the
schemaIdattribute
-
getSpecId
public int getSpecId()
- Specified by:
getSpecIdin classIcebergTable- Returns:
- The value of the
specIdattribute
-
getSortOrderId
public int getSortOrderId()
- Specified by:
getSortOrderIdin classIcebergTable- Returns:
- The value of the
sortOrderIdattribute
-
withId
public final ImmutableIcebergTable withId(String value)
Copy the current immutable object by setting a value for theidattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for id- Returns:
- A modified copy of the
thisobject
-
withMetadataLocation
public final ImmutableIcebergTable withMetadataLocation(String value)
Copy the current immutable object by setting a value for themetadataLocationattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for metadataLocation- Returns:
- A modified copy of the
thisobject
-
withSnapshotId
public final ImmutableIcebergTable withSnapshotId(long value)
Copy the current immutable object by setting a value for thesnapshotIdattribute. A value equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for snapshotId- Returns:
- A modified copy of the
thisobject
-
withSchemaId
public final ImmutableIcebergTable withSchemaId(int value)
Copy the current immutable object by setting a value for theschemaIdattribute. A value equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for schemaId- Returns:
- A modified copy of the
thisobject
-
withSpecId
public final ImmutableIcebergTable withSpecId(int value)
Copy the current immutable object by setting a value for thespecIdattribute. A value equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for specId- Returns:
- A modified copy of the
thisobject
-
withSortOrderId
public final ImmutableIcebergTable withSortOrderId(int value)
Copy the current immutable object by setting a value for thesortOrderIdattribute. A value equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for sortOrderId- Returns:
- A modified copy of the
thisobject
-
equals
public boolean equals(@Nullable Object another)
This instance is equal to all instances ofImmutableIcebergTablethat have equal attribute values.
-
hashCode
public int hashCode()
Computes a hash code from attributes:id,metadataLocation,snapshotId,schemaId,specId,sortOrderId.
-
toString
public String toString()
Prints the immutable valueIcebergTablewith attribute values.
-
copyOf
public static ImmutableIcebergTable copyOf(IcebergTable instance)
Creates an immutable copy of aIcebergTablevalue. 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 IcebergTable instance
-
builder
public static ImmutableIcebergTable.Builder builder()
Creates a builder forImmutableIcebergTable.ImmutableIcebergTable.builder() .id(String) // optionalid.metadataLocation(String) // requiredmetadataLocation.snapshotId(long) // requiredsnapshotId.schemaId(int) // requiredschemaId.specId(int) // requiredspecId.sortOrderId(int) // requiredsortOrderId.build();- Returns:
- A new ImmutableIcebergTable builder
-
-