pub struct TextRef {
pub key: &'static str,
pub text: &'static str,
}Expand description
A reference to localized text.
key is a resource key ("endpoint.blog.list.name"); text is a literal
default used when the key is absent from every resource. Either may be empty.
Fields§
§key: &'static strResource key; empty for literal-only text.
text: &'static strLiteral fallback; empty when the key is the only source.
Implementations§
Trait Implementations§
impl Copy for TextRef
impl Eq for TextRef
Source§impl Serialize for TextRef
impl Serialize for TextRef
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 StructuralPartialEq for TextRef
Auto Trait Implementations§
impl Forget for TextRef
impl Freeze for TextRef
impl Move for TextRef
impl RefUnwindSafe for TextRef
impl Send for TextRef
impl Sync for TextRef
impl Unpin for TextRef
impl UnsafeUnpin for TextRef
impl UnwindSafe for TextRef
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.