#[non_exhaustive]pub struct IcebergStructField {
pub id: i32,
pub name: String,
pub type: Document,
pub required: bool,
pub doc: Option<String>,
pub initial_default: Option<Document>,
pub write_default: Option<Document>,
}Expand description
Defines a single field within an Iceberg table schema, including its identifier, name, data type, nullability, and documentation.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.id: i32The unique identifier assigned to this field within the Iceberg table schema, used for schema evolution and field tracking.
name: StringThe name of the field as it appears in the table schema and query operations.
type: DocumentThe data type definition for this field, specifying the structure and format of the data it contains.
required: boolIndicates whether this field is required (non-nullable) or optional (nullable) in the table schema.
doc: Option<String>Optional documentation or description text that provides additional context about the purpose and usage of this field.
initial_default: Option<Document>Default value used to populate the field's value for all records that were written before the field was added to the schema. This enables backward compatibility when adding new fields to existing Iceberg tables.
write_default: Option<Document>Default value used to populate the field's value for any records written after the field was added to the schema, if the writer does not supply the field's value. This can be changed through schema evolution.
Implementations§
Source§impl IcebergStructField
impl IcebergStructField
Sourcepub fn id(&self) -> i32
pub fn id(&self) -> i32
The unique identifier assigned to this field within the Iceberg table schema, used for schema evolution and field tracking.
Sourcepub fn name(&self) -> &str
pub fn name(&self) -> &str
The name of the field as it appears in the table schema and query operations.
Sourcepub fn type(&self) -> &Document
pub fn type(&self) -> &Document
The data type definition for this field, specifying the structure and format of the data it contains.
Sourcepub fn required(&self) -> bool
pub fn required(&self) -> bool
Indicates whether this field is required (non-nullable) or optional (nullable) in the table schema.
Sourcepub fn doc(&self) -> Option<&str>
pub fn doc(&self) -> Option<&str>
Optional documentation or description text that provides additional context about the purpose and usage of this field.
Sourcepub fn initial_default(&self) -> Option<&Document>
pub fn initial_default(&self) -> Option<&Document>
Default value used to populate the field's value for all records that were written before the field was added to the schema. This enables backward compatibility when adding new fields to existing Iceberg tables.
Sourcepub fn write_default(&self) -> Option<&Document>
pub fn write_default(&self) -> Option<&Document>
Default value used to populate the field's value for any records written after the field was added to the schema, if the writer does not supply the field's value. This can be changed through schema evolution.
Source§impl IcebergStructField
impl IcebergStructField
Sourcepub fn builder() -> IcebergStructFieldBuilder
pub fn builder() -> IcebergStructFieldBuilder
Creates a new builder-style object to manufacture IcebergStructField.
Trait Implementations§
Source§impl Clone for IcebergStructField
impl Clone for IcebergStructField
Source§fn clone(&self) -> IcebergStructField
fn clone(&self) -> IcebergStructField
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for IcebergStructField
impl Debug for IcebergStructField
Source§impl PartialEq for IcebergStructField
impl PartialEq for IcebergStructField
Source§fn eq(&self, other: &IcebergStructField) -> bool
fn eq(&self, other: &IcebergStructField) -> bool
self and other values to be equal, and is used by ==.impl StructuralPartialEq for IcebergStructField
Auto Trait Implementations§
impl Freeze for IcebergStructField
impl RefUnwindSafe for IcebergStructField
impl Send for IcebergStructField
impl Sync for IcebergStructField
impl Unpin for IcebergStructField
impl UnsafeUnpin for IcebergStructField
impl UnwindSafe for IcebergStructField
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more