pub struct Schema { /* private fields */ }
Expand description
Gather size information about the full AST.
Implementations§
Source§impl Schema
impl Schema
Sourcepub fn new(file: &File) -> Schema
pub fn new(file: &File) -> Schema
Check correct definition of packet sizes. Annotate fields and declarations with the size in bits.
pub fn field_size(&self, key: FieldKey) -> Size
pub fn decl_size(&self, key: DeclKey) -> Size
pub fn parent_size(&self, key: DeclKey) -> Size
pub fn padded_size(&self, key: FieldKey) -> Option<usize>
pub fn payload_size(&self, key: DeclKey) -> Size
pub fn total_size(&self, key: DeclKey) -> Size
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Schema
impl RefUnwindSafe for Schema
impl Send for Schema
impl Sync for Schema
impl Unpin for Schema
impl UnwindSafe for Schema
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