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: transaction.rs
    path of file: ./repos/risinglight/src/storage/memory
    
    the code of the file until where you have to start completion: // Copyright 2024 RisingLight Project Authors. Licensed under Apache-2.0.

use std::collections::HashSet;
use std::sync::Arc;

use itertools::Itertools;

use super::table::InMemoryTableInnerRef;
use super::{InMemoryRowHandler, InMemoryTable, InMemoryTxnIterator};
use crate::array:
    
    pub(super) fn start(table: &InMemoryTable) -> StorageResult<Self> {
        let inner = table.inner.read().unwrap();
        let ordered_pk_idx = table
            .ordered_pk_ids()
            .iter()
            .map(|id| {
                table
                    .columns
                    .iter()
                    .position(|c| c.id() == *id)
                    .expect("Malformed table object")
            })
            .collect_vec();
        Ok(Self {
            finished: false,
            buffer: vec![],
            delete_buffer: vec![],
            table: table.inner.clone(),
            snapshot: Arc::new(inner.get_all_chunks()),
            deleted_rows: Arc::new(inner.get_all_deleted_rows()),
            ordered_pk_idx,
        })
    }