Struct vortex_flatbuffers::footer::Layout
source · pub struct Layout<'a> {
pub _tab: Table<'a>,
}
Expand description
A Layout
is a recursive data structure that describes the physical layout of the data in a Vortex file.
As a starting, concrete example, the first three Layout encodings are defined as:
- encoding == 1,
Flat
-> one buffer, zero child Layouts - encoding == 2,
Chunked
-> zero buffers, one or more child Layouts (used for chunks of rows) - encoding == 3,
Columnar
-> zero buffers, one or more child Layouts (used for columns of structs)
The row_count
represents the number of rows represented by this Layout. This is very useful for
pruning the Layout tree based on row filters.
The metadata
field is fully opaque at this layer, and allows the Layout implementation corresponding to
encoding
to embed additional information that may be useful for the reader. For example, the ChunkedLayout
uses the first byte of the metadata
array as a boolean to indicate whether the first child Layout represents
the statistics table for the other chunks.
Fields§
§_tab: Table<'a>
Implementations§
source§impl<'a> Layout<'a>
impl<'a> Layout<'a>
pub const VT_ENCODING: VOffsetT = 4u16
pub const VT_BUFFERS: VOffsetT = 6u16
pub const VT_CHILDREN: VOffsetT = 8u16
pub const VT_ROW_COUNT: VOffsetT = 10u16
pub const VT_METADATA: VOffsetT = 12u16
pub unsafe fn init_from_table(table: Table<'a>) -> Self
pub fn create<'bldr: 'args, 'args: 'mut_bldr, 'mut_bldr, A: Allocator + 'bldr>( _fbb: &'mut_bldr mut FlatBufferBuilder<'bldr, A>, args: &'args LayoutArgs<'args>, ) -> WIPOffset<Layout<'bldr>>
pub fn encoding(&self) -> u16
pub fn buffers(&self) -> Option<Vector<'a, Buffer>>
pub fn children(&self) -> Option<Vector<'a, ForwardsUOffset<Layout<'a>>>>
pub fn row_count(&self) -> u64
pub fn metadata(&self) -> Option<Vector<'a, u8>>
Trait Implementations§
impl<'a> Copy for Layout<'a>
impl<'a> StructuralPartialEq for Layout<'a>
Auto Trait Implementations§
impl<'a> Freeze for Layout<'a>
impl<'a> RefUnwindSafe for Layout<'a>
impl<'a> Send for Layout<'a>
impl<'a> Sync for Layout<'a>
impl<'a> Unpin for Layout<'a>
impl<'a> UnwindSafe for Layout<'a>
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§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)