pub struct Coder {
pub encoder_path: String,
pub decoder_path: String,
pub error_path: String,
pub any_value: String,
pub prefer: bool,
pub builtin: bool,
}
Expand description
Represents the en/decoder for some MIME media range.
Fields§
§encoder_path: String
Path to the encoding function.
decoder_path: String
Path to the decoding function.
error_path: String
Path to the error type.
any_value: String
Path to the struct/enum that represents Any
(such as serde_json::Value
).
prefer: bool
Whether this media type should be preferred when multiple types are available. When multiple types are preferred, it’s unspecified as to which is chosen.
builtin: bool
Whether this en/decoder is built-in.
Trait Implementations§
source§impl<'de> Deserialize<'de> for Coder
impl<'de> Deserialize<'de> for Coder
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
Auto Trait Implementations§
impl Freeze for Coder
impl RefUnwindSafe for Coder
impl Send for Coder
impl Sync for Coder
impl Unpin for Coder
impl UnwindSafe for Coder
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§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)