pub struct Snapshot { /* private fields */ }Expand description
A snapshot represents the state of a table at some time and is used to access the complete set of data files in the table.
Implementations§
Source§impl Snapshot
impl Snapshot
Sourcepub fn builder() -> SnapshotBuilder<((), (), (), (), (), (), ())>
pub fn builder() -> SnapshotBuilder<((), (), (), (), (), (), ())>
Create a builder for building Snapshot.
On the builder, call .snapshot_id(...), .parent_snapshot_id(...)(optional), .sequence_number(...), .timestamp_ms(...), .manifest_list(...), .summary(...), .schema_id(...)(optional) to set the values of the fields.
Finally, call .build() to create the instance of Snapshot.
Source§impl Snapshot
impl Snapshot
Sourcepub fn snapshot_id(&self) -> i64
pub fn snapshot_id(&self) -> i64
Get the id of the snapshot
Sourcepub fn parent_snapshot_id(&self) -> Option<i64>
pub fn parent_snapshot_id(&self) -> Option<i64>
Get parent snapshot id.
Sourcepub fn sequence_number(&self) -> i64
pub fn sequence_number(&self) -> i64
Get sequence_number of the snapshot. Is 0 for Iceberg V1 tables.
Sourcepub fn manifest_list(&self) -> &str
pub fn manifest_list(&self) -> &str
Get location of manifest_list file
Sourcepub fn timestamp(&self) -> Result<DateTime<Utc>>
pub fn timestamp(&self) -> Result<DateTime<Utc>>
Get the timestamp of when the snapshot was created
Sourcepub fn timestamp_ms(&self) -> i64
pub fn timestamp_ms(&self) -> i64
Get the timestamp of when the snapshot was created in milliseconds
Sourcepub fn schema(&self, table_metadata: &TableMetadata) -> Result<SchemaRef>
pub fn schema(&self, table_metadata: &TableMetadata) -> Result<SchemaRef>
Get the schema of this snapshot.
Sourcepub async fn load_manifest_list(
&self,
file_io: &FileIO,
table_metadata: &TableMetadata,
) -> Result<ManifestList>
pub async fn load_manifest_list( &self, file_io: &FileIO, table_metadata: &TableMetadata, ) -> Result<ManifestList>
Load manifest list.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Snapshot
impl<'de> Deserialize<'de> for Snapshot
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for Snapshot
impl StructuralPartialEq for Snapshot
Auto Trait Implementations§
impl Freeze for Snapshot
impl RefUnwindSafe for Snapshot
impl Send for Snapshot
impl Sync for Snapshot
impl Unpin for Snapshot
impl UnwindSafe for Snapshot
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
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Downcast for T
impl<T> Downcast for T
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
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> ⓘ
Converts
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> ⓘ
Converts
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 moreSource§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
Source§impl<T> ServiceExt for T
impl<T> ServiceExt for T
Source§fn map_response_body<F>(self, f: F) -> MapResponseBody<Self, F>where
Self: Sized,
fn map_response_body<F>(self, f: F) -> MapResponseBody<Self, F>where
Self: Sized,
Apply a transformation to the response body. Read more
Source§fn decompression(self) -> Decompression<Self>where
Self: Sized,
fn decompression(self) -> Decompression<Self>where
Self: Sized,
Decompress response bodies. Read more
Source§fn trace_for_http(self) -> Trace<Self, SharedClassifier<ServerErrorsAsFailures>>where
Self: Sized,
fn trace_for_http(self) -> Trace<Self, SharedClassifier<ServerErrorsAsFailures>>where
Self: Sized,
High level tracing that classifies responses using HTTP status codes. Read more
Source§fn trace_for_grpc(self) -> Trace<Self, SharedClassifier<GrpcErrorsAsFailures>>where
Self: Sized,
fn trace_for_grpc(self) -> Trace<Self, SharedClassifier<GrpcErrorsAsFailures>>where
Self: Sized,
High level tracing that classifies responses using gRPC headers. Read more