Trait ServantBuilder

Source
pub trait ServantBuilder:
    Send
    + BoxClone
    + ServantBuilderParameters
    + Serialize
    + Deserialize {
    // Provided methods
    fn dyn_clone(&self) -> Box<dyn ServantBuilder> { ... }
    fn build(
        &self,
        servant_id: u32,
        servant_name: String,
        ch_naming: &FnvHashMap<u64, String>,
        recv_from_master: Receiver<(MsgFromMaster, Sender<ReplyToMaster>)>,
        send_2_master: SendToMaster,
        task_id: IdBuilder,
    ) -> Result<Servant, String> { ... }
}
Expand description

Trait with serde tag and main servant builder implementations

Provided Methods§

Source

fn dyn_clone(&self) -> Box<dyn ServantBuilder>

Clone the servant builder as boxed dyn ServantBuilder

  • Output: boxed clone as dyn ServantBuilder
Source

fn build( &self, servant_id: u32, servant_name: String, ch_naming: &FnvHashMap<u64, String>, recv_from_master: Receiver<(MsgFromMaster, Sender<ReplyToMaster>)>, send_2_master: SendToMaster, task_id: IdBuilder, ) -> Result<Servant, String>

Build a servant instance

  • This method is for silx internal use
  • servant_id: ServantIdType : internal servant id
  • servant_name: String : servant name
  • ch_naming: &FnvHashMap<ChannelIdType, String,> : channels ids and names
  • recv_from_master: RecvFromMaster : channel receiver from the cluster master
  • send_2_master: SendToMaster : channel sender to the cluster master
  • task_id: IdBuilder : task id builder for tasking the cluster master
  • Output: a servant instance or an error

Trait Implementations§

Source§

impl Clone for Box<dyn ServantBuilder>

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for Box<dyn ServantBuilder>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
Source§

impl<'typetag> Serialize for dyn ServantBuilder + 'typetag

Source§

fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
where S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl<'typetag> Serialize for dyn ServantBuilder + Send + 'typetag

Source§

fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
where S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl<'typetag> Serialize for dyn ServantBuilder + Send + Sync + 'typetag

Source§

fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
where S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl<'typetag> Serialize for dyn ServantBuilder + Sync + 'typetag

Source§

fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
where S: Serializer,

Serialize this value into the given Serde serializer. Read more

Implementors§