Struct puzzlefs_lib::oci::Image
source · pub struct Image { /* private fields */ }
Implementations§
source§impl Image
impl Image
pub fn new(oci_dir: &Path) -> Result<Self, WireFormatError>
pub fn open(oci_dir: &Path) -> Result<Self, WireFormatError>
pub fn blob_path(&self) -> PathBuf
pub fn blob_path_relative(&self) -> PathBuf
pub fn put_blob<C: for<'a> Compression<'a> + Any, MT: MediaType>( &self, buf: &[u8] ) -> Result<(Descriptor, [u8; 32], bool), WireFormatError>
pub fn open_compressed_blob<C: for<'a> Compression<'a>>( &self, digest: &Digest, verity: Option<&[u8]> ) -> Result<Box<dyn Decompressor>>
pub fn open_metadata_blob( &self, digest: &Digest, verity: Option<&[u8]> ) -> Result<MetadataBlob, WireFormatError>
pub fn get_image_manifest_fd(&self, tag: &str) -> Result<File, WireFormatError>
pub fn open_rootfs_blob<C: for<'a> Compression<'a>>( &self, tag: &str, verity: Option<&[u8]> ) -> Result<Rootfs, WireFormatError>
pub fn fill_from_chunk( &self, chunk: BlobRef, addl_offset: u64, buf: &mut [u8], verity_data: &Option<BTreeMap<[u8; 32], [u8; 32]>> ) -> Result<usize, WireFormatError>
pub fn get_index(&self) -> Result<Index, WireFormatError>
pub fn put_index(&self, i: &Index) -> Result<(), WireFormatError>
pub fn add_tag( &self, name: &str, desc: Descriptor ) -> Result<(), WireFormatError>
Auto Trait Implementations§
impl RefUnwindSafe for Image
impl Send for Image
impl Sync for Image
impl Unpin for Image
impl UnwindSafe for Image
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