pub enum Tag {
Simple(String),
Pair(String, String),
List(String, Vec<String>),
}Expand description
Tag enum supporting Simple, Pair, and List formats
Variants§
Simple(String)
Simple tag: single word (e.g., “finance”)
Pair(String, String)
Pair tag: key:value format (e.g., “Environment:Dev”)
List(String, Vec<String>)
List tag: key:[value1, value2, …] format (e.g., “SecondaryDomains:[XXXXX, PPPP]”)
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Tag
impl<'de> Deserialize<'de> for Tag
Source§fn deserialize<D>(
deserializer: D,
) -> Result<Tag, <D as Deserializer<'de>>::Error>where
D: Deserializer<'de>,
fn deserialize<D>(
deserializer: D,
) -> Result<Tag, <D as Deserializer<'de>>::Error>where
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl FromStr for Tag
impl FromStr for Tag
Source§fn from_str(s: &str) -> Result<Tag, <Tag as FromStr>::Err>
fn from_str(s: &str) -> Result<Tag, <Tag as FromStr>::Err>
Parse a tag string into a Tag enum with auto-detection
Parsing logic:
- No colon = Simple tag
- Single colon (not followed by bracket, and no more colons) = Pair tag
- Colon followed by bracket = List tag
- Multiple colons without brackets = Simple tag (malformed, graceful degradation)
Malformed tags are treated as Simple tags (graceful degradation)
Source§impl Serialize for Tag
impl Serialize for Tag
Source§fn serialize<S>(
&self,
serializer: S,
) -> Result<<S as Serializer>::Ok, <S as Serializer>::Error>where
S: Serializer,
fn serialize<S>(
&self,
serializer: S,
) -> Result<<S as Serializer>::Ok, <S as Serializer>::Error>where
S: Serializer,
Serialize this value into the given Serde serializer. Read more
impl Eq for Tag
impl StructuralPartialEq for Tag
Auto Trait Implementations§
impl Freeze for Tag
impl RefUnwindSafe for Tag
impl Send for Tag
impl Sync for Tag
impl Unpin for Tag
impl UnwindSafe for Tag
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
Source§impl<T> ToStringFallible for Twhere
T: Display,
impl<T> ToStringFallible for Twhere
T: Display,
Source§fn try_to_string(&self) -> Result<String, TryReserveError>
fn try_to_string(&self) -> Result<String, TryReserveError>
ToString::to_string, but without panic on OOM.