Struct ImageMetadata
pub struct ImageMetadata { /* private fields */ }Expand description
OCI image metadata composed from focused primitive crates.
Implementations§
§impl ImageMetadata
impl ImageMetadata
pub fn new(name: ImageName) -> ImageMetadata
pub fn new(name: ImageName) -> ImageMetadata
Creates image metadata from a name.
pub fn with_reference(self, reference: ImageReference) -> ImageMetadata
pub fn with_reference(self, reference: ImageReference) -> ImageMetadata
Adds an image reference.
pub fn with_id(self, id: ImageId) -> ImageMetadata
pub fn with_id(self, id: ImageId) -> ImageMetadata
Adds an image ID.
pub const fn with_kind(self, kind: ImageKind) -> ImageMetadata
pub const fn with_kind(self, kind: ImageKind) -> ImageMetadata
Adds an image kind.
pub fn with_descriptor(self, descriptor: OciDescriptor) -> ImageMetadata
pub fn with_descriptor(self, descriptor: OciDescriptor) -> ImageMetadata
Adds a descriptor.
pub fn with_platform(self, platform: OciPlatform) -> ImageMetadata
pub fn with_platform(self, platform: OciPlatform) -> ImageMetadata
Adds platform metadata.
pub fn with_media_type(self, media_type: OciMediaType) -> ImageMetadata
pub fn with_media_type(self, media_type: OciMediaType) -> ImageMetadata
Adds a media type marker.
pub fn with_annotation(self, annotation: Annotation) -> ImageMetadata
pub fn with_annotation(self, annotation: Annotation) -> ImageMetadata
Adds an annotation.
pub const fn reference(&self) -> Option<&ImageReference>
pub const fn reference(&self) -> Option<&ImageReference>
Returns the optional reference.
pub fn descriptors(&self) -> &[OciDescriptor]
pub fn descriptors(&self) -> &[OciDescriptor]
Returns descriptors.
pub fn annotations(&self) -> &[Annotation]
pub fn annotations(&self) -> &[Annotation]
Returns annotations.
Trait Implementations§
§impl Clone for ImageMetadata
impl Clone for ImageMetadata
§fn clone(&self) -> ImageMetadata
fn clone(&self) -> ImageMetadata
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read more§impl Debug for ImageMetadata
impl Debug for ImageMetadata
§impl PartialEq for ImageMetadata
impl PartialEq for ImageMetadata
impl Eq for ImageMetadata
impl StructuralPartialEq for ImageMetadata
Auto Trait Implementations§
impl Freeze for ImageMetadata
impl RefUnwindSafe for ImageMetadata
impl Send for ImageMetadata
impl Sync for ImageMetadata
impl Unpin for ImageMetadata
impl UnsafeUnpin for ImageMetadata
impl UnwindSafe for ImageMetadata
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