Zero  0.1.0
Public Member Functions | Public Attributes | List of all members
page_img_format_t< PagePtr > Struct Template Reference

#include <logrec_support.h>

Public Member Functions

int size ()
 
 page_img_format_t (const PagePtr p)
 
void apply (PagePtr page)
 

Public Attributes

size_t beginning_bytes
 
size_t ending_bytes
 
char data [logrec_t::max_data_sz - 2 *sizeof(size_t)]
 

Detailed Description

template<class PagePtr>
struct page_img_format_t< PagePtr >

This is a special way of logging the creation of a new page. New page creation is usually a page split, so the new page has many records in it. To simplify and to avoid many log entries in that case, we log ALL bytes from the beginning to the end of slot vector, and from the record_head8 to the end of page. We can assume totally defragmented page image because this is page creation. We don't need UNDO (again, this is page creation!), REDO is just two memcpy().

Constructor & Destructor Documentation

§ page_img_format_t()

template<class PagePtr >
page_img_format_t< PagePtr >::page_img_format_t ( const PagePtr  p)
inline

Member Function Documentation

§ apply()

template<class PagePtr >
void page_img_format_t< PagePtr >::apply ( PagePtr  page)
inline

§ size()

template<class PagePtr >
int page_img_format_t< PagePtr >::size ( )
inline

Member Data Documentation

§ beginning_bytes

template<class PagePtr >
size_t page_img_format_t< PagePtr >::beginning_bytes

§ data

template<class PagePtr >
char page_img_format_t< PagePtr >::data[logrec_t::max_data_sz - 2 *sizeof(size_t)]

§ ending_bytes

template<class PagePtr >
size_t page_img_format_t< PagePtr >::ending_bytes

The documentation for this struct was generated from the following file: