pub struct MetaEntry {
pub visibility: MetaVisibility,
pub value: String,
}Expand description
An entry in the MAF Meta API.
The value stored in the entry should be unmarshalled from JSON using MetaEntry::deserialize.
Fields§
§visibility: MetaVisibility§value: StringImplementations§
Source§impl MetaEntry
impl MetaEntry
Sourcepub fn deserialize<T>(&self) -> Result<T, Error>where
T: DeserializeOwned,
pub fn deserialize<T>(&self) -> Result<T, Error>where
T: DeserializeOwned,
Deserialize the value of the meta entry into the specified type.
Sourcepub fn visibility(&self) -> &MetaVisibility
pub fn visibility(&self) -> &MetaVisibility
Get the visibility of the meta entry.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for MetaEntry
impl<'de> Deserialize<'de> for MetaEntry
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<MetaEntry, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<MetaEntry, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Serialize for MetaEntry
impl Serialize for MetaEntry
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
Auto Trait Implementations§
impl Freeze for MetaEntry
impl RefUnwindSafe for MetaEntry
impl Send for MetaEntry
impl Sync for MetaEntry
impl Unpin for MetaEntry
impl UnsafeUnpin for MetaEntry
impl UnwindSafe for MetaEntry
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