pub struct ServerFnErrorEncoding;Expand description
Serializes and deserializes JSON with serde_json.
Trait Implementations§
Source§impl ContentType for ServerFnErrorEncoding
impl ContentType for ServerFnErrorEncoding
Source§const CONTENT_TYPE: &'static str = "text/plain"
const CONTENT_TYPE: &'static str = "text/plain"
The MIME type of the data.
Source§impl<CustErr> Decodes<ServerFnError<CustErr>> for ServerFnErrorEncodingwhere
CustErr: FromStr,
impl<CustErr> Decodes<ServerFnError<CustErr>> for ServerFnErrorEncodingwhere
CustErr: FromStr,
Source§fn decode(
bytes: Bytes,
) -> Result<ServerFnError<CustErr>, <ServerFnErrorEncoding as Decodes<ServerFnError<CustErr>>>::Error>
fn decode( bytes: Bytes, ) -> Result<ServerFnError<CustErr>, <ServerFnErrorEncoding as Decodes<ServerFnError<CustErr>>>::Error>
Decodes the given bytes into a value.
Source§impl<CustErr> Encodes<ServerFnError<CustErr>> for ServerFnErrorEncodingwhere
CustErr: Display,
impl<CustErr> Encodes<ServerFnError<CustErr>> for ServerFnErrorEncodingwhere
CustErr: Display,
Source§fn encode(
output: &ServerFnError<CustErr>,
) -> Result<Bytes, <ServerFnErrorEncoding as Encodes<ServerFnError<CustErr>>>::Error>
fn encode( output: &ServerFnError<CustErr>, ) -> Result<Bytes, <ServerFnErrorEncoding as Encodes<ServerFnError<CustErr>>>::Error>
Encodes the given value into a bytes.
Source§impl FormatType for ServerFnErrorEncoding
impl FormatType for ServerFnErrorEncoding
Source§const FORMAT_TYPE: Format = Format::Text
const FORMAT_TYPE: Format = Format::Text
The representation type
Source§fn into_encoded_string(bytes: Bytes) -> String
fn into_encoded_string(bytes: Bytes) -> String
Encodes data into a string.
Source§fn from_encoded_string(data: &str) -> Result<Bytes, DecodeError>
fn from_encoded_string(data: &str) -> Result<Bytes, DecodeError>
Decodes string to bytes
Auto Trait Implementations§
impl Freeze for ServerFnErrorEncoding
impl RefUnwindSafe for ServerFnErrorEncoding
impl Send for ServerFnErrorEncoding
impl Sync for ServerFnErrorEncoding
impl Unpin for ServerFnErrorEncoding
impl UnwindSafe for ServerFnErrorEncoding
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> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> SerializableKey for T
impl<T> SerializableKey for T
Source§impl<T> StorageAccess<T> for T
impl<T> StorageAccess<T> for T
Source§fn as_borrowed(&self) -> &T
fn as_borrowed(&self) -> &T
Borrows the value.
Source§fn into_taken(self) -> T
fn into_taken(self) -> T
Takes the value.