/// Creates a page-map from the given serialization-friendly representation.
Creates a page-map from the given serialization-friendly representation.
Creates a page - map from the given serialization - friendly representation .
pub fn deserialize(page_map: PageMapSerialization) -> Result<Self, PersistenceError> {
        let checkpoint = Checkpoint::deserialize(page_map.checkpoint)?;
        let page_allocator = PageAllocator::deserialize(page_map.page_allocator);
        let page_delta =
            PageDelta::from(page_allocator.deserialize_page_delta(page_map.page_delta));
        let round_delta =
            PageDelta::from(page_allocator.deserialize_page_delta(page_map.round_delta));
        Ok(Self {
            checkpoint,
            base_height: page_map.base_height,
            page_delta,
            round_delta,
            page_allocator,
        })
    }
pub fn deserialize ( page_map : PageMapSerialization ) -> Result < Self , PersistenceError > { let checkpoint = Checkpoint :: deserialize ( page_map . checkpoint ) ? ; let page_allocator = PageAllocator :: deserialize ( page_map . page_allocator ) ; let page_delta = PageDelta :: from ( page_allocator . deserialize_page_delta ( page_map . page_delta ) ) ; let round_delta = PageDelta :: from ( page_allocator . deserialize_page_delta ( page_map . round_delta ) ) ; Ok ( Self { checkpoint , base_height : page_map . base_height , page_delta , round_delta , page_allocator , } ) }
Creates a page-map from the given serialization-friendly representation.
Creates a page - map from the given serialization - friendly representation .
page_map
PageMapSerialization