1use alloc::{borrow::Cow, string::String};
10
11#[derive(Clone, Debug, Default, PartialEq, Eq)]
13pub struct VcardLanguageTag<'a>(pub Cow<'a, str>);
14
15impl<'a> From<&'a str> for VcardLanguageTag<'a> {
16 fn from(value: &'a str) -> Self {
17 Self(Cow::Borrowed(value))
18 }
19}
20
21impl From<String> for VcardLanguageTag<'_> {
22 fn from(value: String) -> Self {
23 Self(Cow::Owned(value))
24 }
25}
26
27impl<'a> From<Cow<'a, str>> for VcardLanguageTag<'a> {
28 fn from(value: Cow<'a, str>) -> Self {
29 Self(value)
30 }
31}