/// Creates a new AddPages struct for a page at a certain offset
Creates a new AddPages struct for a page at a certain offset
Creates a new AddPages struct for a page at a certain offset
pub fn new(bytes: &'a [u8], offset: usize, secinfo: &'a SecInfo, measure: bool) -> Self {
        const MEASURE: u64 = 1 << 0;
        let flags = match measure {
            true => MEASURE,
            false => 0,
        };
        Self {
            src: bytes.as_ptr() as _,
            offset: offset as _,
            length: bytes.len() as _,
            secinfo: secinfo as *const _ as _,
            flags,
            count: 0,
            phantom: PhantomData,
        }
    }
pub fn new ( bytes : & ' a [ u8 ] , offset : usize , secinfo : & ' a SecInfo , measure : bool ) -> Self { const MEASURE : u64 = 1 << 0 ; let flags = match measure { true => MEASURE , false => 0 , } ; Self { src : bytes . as_ptr ( ) as _ , offset : offset as _ , length : bytes . len ( ) as _ , secinfo : secinfo as * const _ as _ , flags , count : 0 , phantom : PhantomData , } }
Creates a new AddPages struct for a page at a certain offset
Creates a new AddPages struct for a page at a certain offset
bytes
&'a [u8]
offset
usize
secinfo
&'a SecInfo
measure
bool