pub struct RetentionClass(/* private fields */);Expand description
An opaque, case-sensitive artifact retention-policy class.
Core assigns no default lifetime, ordering, legal-hold behavior, or deletion permission. A versioned runtime policy interprets the class and records concrete lifecycle decisions separately.
Implementations§
Source§impl RetentionClass
impl RetentionClass
Sourcepub fn new(value: impl Into<String>) -> Result<Self, RetentionClassError>
pub fn new(value: impl Into<String>) -> Result<Self, RetentionClassError>
Validates and constructs an opaque retention class.
§Errors
Returns RetentionClassError for empty, oversized, or invalid ASCII
policy keys.
Trait Implementations§
Source§impl AsRef<str> for RetentionClass
impl AsRef<str> for RetentionClass
Source§impl Borrow<str> for RetentionClass
impl Borrow<str> for RetentionClass
Source§impl Clone for RetentionClass
impl Clone for RetentionClass
Source§impl Debug for RetentionClass
impl Debug for RetentionClass
Source§impl<'de> Deserialize<'de> for RetentionClass
impl<'de> Deserialize<'de> for RetentionClass
Source§fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Display for RetentionClass
impl Display for RetentionClass
impl Eq for RetentionClass
Source§impl From<RetentionClass> for String
impl From<RetentionClass> for String
Source§fn from(value: RetentionClass) -> Self
fn from(value: RetentionClass) -> Self
Converts to this type from the input type.
Source§impl FromStr for RetentionClass
impl FromStr for RetentionClass
Source§impl Hash for RetentionClass
impl Hash for RetentionClass
Source§impl JsonSchema for RetentionClass
impl JsonSchema for RetentionClass
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Returns a string that uniquely identifies the schema produced by this type. Read more
Source§fn json_schema(_: &mut SchemaGenerator) -> Schema
fn json_schema(_: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
Whether JSON Schemas generated for this type should be included directly in parent schemas,
rather than being re-used where possible using the
$ref keyword. Read moreSource§impl Ord for RetentionClass
impl Ord for RetentionClass
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
1.21.0 (const: unstable) · Source§fn min(self, other: Self) -> Selfwhere
Self: Sized,
fn min(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the minimum of two values. Read more
Source§impl PartialEq for RetentionClass
impl PartialEq for RetentionClass
Source§impl PartialOrd for RetentionClass
impl PartialOrd for RetentionClass
Source§impl Serialize for RetentionClass
impl Serialize for RetentionClass
impl StructuralPartialEq for RetentionClass
Source§impl TryFrom<&str> for RetentionClass
impl TryFrom<&str> for RetentionClass
Auto Trait Implementations§
impl Forget for RetentionClass
impl Freeze for RetentionClass
impl Move for RetentionClass
impl RefUnwindSafe for RetentionClass
impl Send for RetentionClass
impl Sync for RetentionClass
impl Unpin for RetentionClass
impl UnsafeUnpin for RetentionClass
impl UnwindSafe for RetentionClass
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