Struct weave::Header
[−]
[src]
pub struct Header { pub version: usize, pub deltas: Vec<DeltaInfo>, }
The header placed at the beginning of the each weave file.
Fields
version: usize
deltas: Vec<DeltaInfo>
Methods
impl Header
[src]
fn new() -> Header
Construct a new header, with no deltas in it.
fn from_str(line: &str) -> Result<Header>
Decode from the first line of the file.
fn add(&mut self, tags: BTreeMap<String, String>) -> Result<usize>
Add a delta to this header. Returns the delta number to be used.
fn write<W: Write>(&self, wr: &mut W) -> Result<()>
Write the header to the writer, as the first line.
Trait Implementations
impl Clone for Header
[src]
fn clone(&self) -> Header
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more