You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: state.rs
    path of file: ./repos/delta-rs/crates/core/src/table
    
    the code of the file until where you have to start completion: //! The module for delta table state.

use std::collections::HashMap;
use std::sync::Arc;

use chrono::Utc;
use futures::TryStreamExt;
use object_store::{path::Path, ObjectStore};
use serde::{Deserialize, Serialize};

use super::config::TableConfig;
use super::{get_partition_col_data_types, DeltaTableConfig};
use crate::kernel::{
    Action, Add, DataType, EagerSnapshot, LogDataHandler, LogicalFile, Metadata, Protocol, Remove,
    StructType,
};
use crate::logstore::LogStore;
use crate::partitions::{DeltaTablePartition, PartitionFilter};
use crate::protocol::DeltaOperation;
use crate::{DeltaResult, DeltaTableError};

/// State snapshot currently held by the Delta Table instance.
#[derive(Debug, Clone, Serialize, Deserialize)]
#[serde(rename_all = "camelCase")]
pub struct DeltaTableState {
    app_transaction_version: HashMap<String, i64>,
    pub(crate) snapshot: EagerSnapshot,
    
    pub fn from_actions(actions: Vec<Action>) -> DeltaResult<Self> {
        use crate::protocol::SaveMode;
        let metadata = actions
            .iter()
            .find_map(|a| match a {
                Action::Metadata(m) => Some(m.clone()),
                _ => None,
            })
            .ok_or(DeltaTableError::NotInitialized)?;
        let protocol = actions
            .iter()
            .find_map(|a| match a {
                Action::Protocol(p) => Some(p.clone()),
                _ => None,
            })
            .ok_or(DeltaTableError::NotInitialized)?;

        let commit_data = [(
            actions,
            DeltaOperation::Create {
                mode: SaveMode::Append,
                location: Path::default().to_string(),
                protocol: protocol.clone(),
                metadata: metadata.clone(),
            },
            None,
        )];
        let snapshot = EagerSnapshot::new_test(&commit_data).unwrap();
        Ok(Self {
            app_transaction_version: Default::default(),
            snapshot,
        })
    }