pub struct ArtifactReference {
pub artifact_id: String,
pub sha256: String,
pub bytes: u64,
pub media_type: String,
}Expand description
Typed description of an artifact as issued by the runtime (evidence
artifactId/mediaType/bytes/sha256 fields). The client verifies a
fetched body against it before returning any bytes.
Fields§
§artifact_id: String§sha256: String§bytes: u64§media_type: StringImplementations§
Source§impl ArtifactReference
impl ArtifactReference
Sourcepub fn media_type_essence(&self) -> String
pub fn media_type_essence(&self) -> String
Lowercase media-type essence (text/plain from text/plain; charset=utf-8).
Returns the empty string when the media type has no valid essence —
[validate_artifact_reference] rejects such references before fetch.
Trait Implementations§
Source§impl Clone for ArtifactReference
impl Clone for ArtifactReference
Source§impl Debug for ArtifactReference
impl Debug for ArtifactReference
impl Eq for ArtifactReference
Source§impl PartialEq for ArtifactReference
impl PartialEq for ArtifactReference
impl StructuralPartialEq for ArtifactReference
Auto Trait Implementations§
impl Freeze for ArtifactReference
impl RefUnwindSafe for ArtifactReference
impl Send for ArtifactReference
impl Sync for ArtifactReference
impl Unpin for ArtifactReference
impl UnsafeUnpin for ArtifactReference
impl UnwindSafe for ArtifactReference
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