pub fn save_without_crc<T, O>(&mut self, mut writer: &mut T, object: &O) -> Result<(), Error>
    where
        T: Write,
        O: Versionize,
    {
        self.hdr = SnapshotHdr {
            data_version: self.target_version,
        };

        let format_version_map = Self::format_version_map();
        let magic_id = build_magic_id(format_version_map.latest_version());

        // Serialize magic id using the format version map.
        magic_id
            .serialize(&mut writer, &format_version_map, 0 /* unused */)
            .map_err(Error::Versionize)?;

        // Serialize header using the format version map.
        self.hdr
            .serialize(
                &mut writer,
                &format_version_map,
                format_version_map.latest_version(),
            )
            .map_err(Error::Versionize)?;

        // Serialize the object using the state version map.
        object
            .serialize(&mut writer, &self.version_map, self.target_version)
            .map_err(Error::Versionize)?;
        writer
            .flush()
            .map_err(|ref err| Error::Io(err.raw_os_error().unwrap_or(libc::EINVAL)))
    }
/// Save a snapshot with no CRC64 checksum included.
Save a snapshot with no CRC64 checksum included.
Save a snapshot with no CRC64 checksum included .
pub fn save_without_crc<T, O>(&mut self, mut writer: &mut T, object: &O) -> Result<(), Error>
    where
        T: Write,
        O: Versionize,
    {
        self.hdr = SnapshotHdr {
            data_version: self.target_version,
        };
        let format_version_map = Self::format_version_map();
        let magic_id = build_magic_id(format_version_map.latest_version());
        // Serialize magic id using the format version map.
        magic_id
            .serialize(&mut writer, &format_version_map, 0 /* unused */)
            .map_err(Error::Versionize)?;
        // Serialize header using the format version map.
        self.hdr
            .serialize(
                &mut writer,
                &format_version_map,
                format_version_map.latest_version(),
            )
            .map_err(Error::Versionize)?;
        // Serialize the object using the state version map.
        object
            .serialize(&mut writer, &self.version_map, self.target_version)
            .map_err(Error::Versionize)?;
        writer
            .flush()
            .map_err(|ref err| Error::Io(err.raw_os_error().unwrap_or(libc::EINVAL)))
    }
pub fn save_without_crc < T , O > ( & mut self , mut writer : & mut T , object : & O ) -> Result < ( ) , Error > where T : Write , O : Versionize , { self . hdr = SnapshotHdr { data_version : self . target_version , } ; let format_version_map = Self :: format_version_map ( ) ; let magic_id = build_magic_id ( format_version_map . latest_version ( ) ) ; // Serialize magic id using the format version map. magic_id . serialize ( & mut writer , & format_version_map , 0 /* unused */ ) . map_err ( Error :: Versionize ) ? ; // Serialize header using the format version map. self . hdr . serialize ( & mut writer , & format_version_map , format_version_map . latest_version ( ) , ) . map_err ( Error :: Versionize ) ? ; // Serialize the object using the state version map. object . serialize ( & mut writer , & self . version_map , self . target_version ) . map_err ( Error :: Versionize ) ? ; writer . flush ( ) . map_err ( | ref err | Error :: Io ( err . raw_os_error ( ) . unwrap_or ( libc :: EINVAL ) ) ) }
Save a snapshot with no CRC64 checksum included.
Save a snapshot with no CRC64 checksum included .
&mut self
writer
&mut T
object
&O
&mut self
writer
&mut T
object
&O