Struct oci_distribution::client::Config
source · pub struct Config {
pub data: Vec<u8>,
pub media_type: String,
pub annotations: Option<HashMap<String, String>>,
}
Expand description
The data and media type for a configuration object
Fields§
§data: Vec<u8>
The data of this config object
media_type: String
The media type of this object
annotations: Option<HashMap<String, String>>
This OPTIONAL property contains arbitrary metadata for this descriptor. This OPTIONAL property MUST use the annotation rules
Implementations§
source§impl Config
impl Config
sourcepub fn new(
data: Vec<u8>,
media_type: String,
annotations: Option<HashMap<String, String>>
) -> Self
pub fn new(
data: Vec<u8>,
media_type: String,
annotations: Option<HashMap<String, String>>
) -> Self
Constructs a new Config struct with provided data and media type
sourcepub fn oci_v1(
data: Vec<u8>,
annotations: Option<HashMap<String, String>>
) -> Self
pub fn oci_v1(
data: Vec<u8>,
annotations: Option<HashMap<String, String>>
) -> Self
Constructs a new Config struct with provided data and media type application/vnd.oci.image.config.v1+json
sourcepub fn sha256_digest(&self) -> String
pub fn sha256_digest(&self) -> String
Helper function to compute the sha256 digest of this config object