NixDeserialize

Trait NixDeserialize 

Source
pub trait NixDeserialize: Sized {
    // Required method
    fn try_deserialize<R>(
        reader: &mut R,
    ) -> impl Future<Output = Result<Option<Self>, R::Error>> + Send + '_
       where R: ?Sized + NixRead + Send;

    // Provided method
    fn deserialize<R>(
        reader: &mut R,
    ) -> impl Future<Output = Result<Self, R::Error>> + Send + '_
       where R: ?Sized + NixRead + Send { ... }
}
Available on crate feature wire only.
Expand description

A data structure that can be deserialized from the Nix daemon worker protocol.

Required Methods§

Source

fn try_deserialize<R>( reader: &mut R, ) -> impl Future<Output = Result<Option<Self>, R::Error>> + Send + '_
where R: ?Sized + NixRead + Send,

Read a value from the reader. This returns an Option to support gracefull shutdown.

Provided Methods§

Source

fn deserialize<R>( reader: &mut R, ) -> impl Future<Output = Result<Self, R::Error>> + Send + '_
where R: ?Sized + NixRead + Send,

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl NixDeserialize for Option<CAHash>

Available on crate feature daemon only.
Source§

async fn try_deserialize<R>(reader: &mut R) -> Result<Option<Self>, R::Error>
where R: ?Sized + NixRead + Send,

Available on crate feature wire only.
Source§

impl NixDeserialize for Option<StorePath<String>>

Available on crate feature daemon only.
Source§

async fn try_deserialize<R>(reader: &mut R) -> Result<Option<Self>, R::Error>
where R: ?Sized + NixRead + Send,

Available on crate feature wire only.
Source§

impl NixDeserialize for bool

Source§

async fn try_deserialize<R>(reader: &mut R) -> Result<Option<Self>, R::Error>
where R: ?Sized + NixRead + Send,

Source§

impl NixDeserialize for i64

Source§

async fn try_deserialize<R>(reader: &mut R) -> Result<Option<Self>, R::Error>
where R: ?Sized + NixRead + Send,

Source§

impl NixDeserialize for u64

Source§

async fn try_deserialize<R>(reader: &mut R) -> Result<Option<Self>, R::Error>
where R: ?Sized + NixRead + Send,

Source§

impl NixDeserialize for usize

Source§

async fn try_deserialize<R>(reader: &mut R) -> Result<Option<Self>, R::Error>
where R: ?Sized + NixRead + Send,

Source§

impl NixDeserialize for String

Source§

async fn try_deserialize<R>(reader: &mut R) -> Result<Option<Self>, R::Error>
where R: ?Sized + NixRead + Send,

Source§

impl NixDeserialize for Bytes

Source§

async fn try_deserialize<R>(reader: &mut R) -> Result<Option<Self>, R::Error>
where R: ?Sized + NixRead + Send,

Source§

impl<K, V> NixDeserialize for BTreeMap<K, V>

Source§

fn try_deserialize<R>( reader: &mut R, ) -> impl Future<Output = Result<Option<Self>, R::Error>> + Send + '_
where R: ?Sized + NixRead + Send,

Source§

impl<T> NixDeserialize for Vec<T>
where T: NixDeserialize + Send,

Source§

fn try_deserialize<R>( reader: &mut R, ) -> impl Future<Output = Result<Option<Self>, R::Error>> + Send + '_
where R: ?Sized + NixRead + Send,

Implementors§

Source§

impl NixDeserialize for VerbosityLevel

Source§

impl NixDeserialize for Operation

Available on crate feature daemon only.
Source§

impl NixDeserialize for CAHash

Available on crate feature daemon only.
Source§

impl NixDeserialize for Signature<String>

Available on crate feature daemon only.
Source§

impl NixDeserialize for AddToStoreNarRequest

Available on crate feature daemon only.
Source§

impl NixDeserialize for IgnoredZero

Available on crate feature daemon only.
Source§

impl NixDeserialize for NarHash

Available on crate feature daemon only.
Source§

impl NixDeserialize for QueryValidPaths

Available on crate feature daemon only.
Source§

impl NixDeserialize for ClientSettings

Available on crate feature daemon only.
Source§

impl NixDeserialize for StorePath<String>

Available on crate feature daemon only.