Trait autd3::derive::Datagram

source ·
pub trait Datagram {
    type O1: Operation;
    type O2: Operation;
    type G: OperationGenerator<O1 = Self::O1, O2 = Self::O2>;

    // Required method
    fn operation_generator(
        self,
        geometry: &Geometry,
    ) -> Result<Self::G, AUTDInternalError>;

    // Provided methods
    fn timeout(&self) -> Option<Duration> { ... }
    fn parallel_threshold(&self) -> Option<usize> { ... }
    fn trace(&self, _geometry: &Geometry) { ... }
}

Required Associated Types§

source

type O1: Operation

source

type O2: Operation

source

type G: OperationGenerator<O1 = Self::O1, O2 = Self::O2>

Required Methods§

source

fn operation_generator( self, geometry: &Geometry, ) -> Result<Self::G, AUTDInternalError>

Provided Methods§

source

fn timeout(&self) -> Option<Duration>

source

fn parallel_threshold(&self) -> Option<usize>

source

fn trace(&self, _geometry: &Geometry)

Implementations on Foreign Types§

source§

impl<'a> Datagram for Box<dyn Gain + 'a>

§

type O1 = GainOp

§

type O2 = NullOp

§

type G = GainOperationGenerator<Box<dyn Gain + 'a>>

source§

fn operation_generator( self, geometry: &Geometry, ) -> Result<<Box<dyn Gain + 'a> as Datagram>::G, AUTDInternalError>

source§

fn trace(&self, geometry: &Geometry)

source§

impl<D1, D2> Datagram for (D1, D2)
where D1: Datagram<O2 = NullOp>, D2: Datagram<O2 = NullOp>,

§

type O1 = <D1 as Datagram>::O1

§

type O2 = <D2 as Datagram>::O1

§

type G = CombinedOperationGenerator<<D1 as Datagram>::G, <D2 as Datagram>::G>

source§

fn operation_generator( self, geometry: &Geometry, ) -> Result<<(D1, D2) as Datagram>::G, AUTDInternalError>

source§

fn timeout(&self) -> Option<Duration>

source§

fn parallel_threshold(&self) -> Option<usize>

source§

fn trace(&self, geometry: &Geometry)

Implementors§

source§

impl Datagram for SwapSegment

source§

impl Datagram for Bessel

source§

impl Datagram for Focus

source§

impl Datagram for Null

source§

impl Datagram for Plane

source§

impl Datagram for Uniform

source§

impl Datagram for Clear

§

type O1 = ClearOp

§

type O2 = NullOp

§

type G = ClearOpGenerator

source§

impl Datagram for Silencer<FixedCompletionSteps>

§

type O1 = SilencerFixedCompletionStepsOp

§

type O2 = NullOp

§

type G = SilencerFixedCompletionStepsOpGenerator

source§

impl Datagram for Silencer<FixedUpdateRate>

§

type O1 = SilencerFixedUpdateRateOp

§

type O2 = NullOp

§

type G = SilencerFixedUpdateRateOpGenerator

source§

impl Datagram for ConfigureFPGAClock

§

type O1 = ConfigureClockOp

§

type O2 = NullOp

§

type G = ConfigureClockOpGenerator

source§

impl Datagram for Synchronize

§

type O1 = SyncOp

§

type O2 = NullOp

§

type G = SynchronizeOpGenerator

source§

impl<D> Datagram for DatagramWithParallelThreshold<D>
where D: Datagram,

§

type O1 = <D as Datagram>::O1

§

type O2 = <D as Datagram>::O2

§

type G = <D as Datagram>::G

source§

impl<D> Datagram for DatagramWithSegment<D>
where D: DatagramS,

§

type O1 = <D as DatagramS>::O1

§

type O2 = <D as DatagramS>::O2

§

type G = <D as DatagramS>::G

source§

impl<D> Datagram for DatagramWithSegmentTransition<D>
where D: DatagramST,

§

type O1 = <D as DatagramST>::O1

§

type O2 = <D as DatagramST>::O2

§

type G = <D as DatagramST>::G

source§

impl<D> Datagram for DatagramWithTimeout<D>
where D: Datagram,

§

type O1 = <D as Datagram>::O1

§

type O2 = <D as Datagram>::O2

§

type G = <D as Datagram>::G

source§

impl<D> Datagram for D
where D: DatagramST,

§

type O1 = <D as DatagramST>::O1

§

type O2 = <D as DatagramST>::O2

§

type G = <D as DatagramST>::G

source§

impl<F> Datagram for DebugSettings<F>
where F: Fn(&Device, GPIOOut) -> DebugType<'_> + Send + Sync,

§

type O1 = DebugSettingOp

§

type O2 = NullOp

§

type G = DebugSettingOpGenerator<F>

source§

impl<F> Datagram for ForceFan<F>
where F: Fn(&Device) -> bool,

§

type O1 = ForceFanOp

§

type O2 = NullOp

§

type G = ForceFanOpGenerator<F>

source§

impl<F> Datagram for ReadsFPGAState<F>
where F: Fn(&Device) -> bool,

§

type O1 = ReadsFPGAStateOp

§

type O2 = NullOp

§

type G = ReadsFPGAStateOpGenerator<F>

source§

impl<FT: Fn(&Transducer) -> Drive + Send + Sync + 'static, F: Fn(&Device) -> FT + 'static> Datagram for Custom<FT, F>

source§

impl<G> Datagram for Cache<G>
where G: Gain,

source§

impl<G, FT, F> Datagram for Transform<G, FT, F>
where G: Gain, FT: Fn(&Transducer, Drive) -> Drive + Send + Sync + 'static, F: Fn(&Device) -> FT,

§

type O1 = GainOp

§

type O2 = NullOp

§

type G = GainOperationGenerator<Transform<G, FT, F>>

source§

impl<H, F> Datagram for EmulateGPIOIn<H, F>
where H: Fn(GPIOIn) -> bool + Send + Sync, F: Fn(&Device) -> H,

§

type O1 = EmulateGPIOInOp

§

type O2 = NullOp

§

type G = EmulateGPIOInOpGenerator<H, F>

source§

impl<H, F> Datagram for PulseWidthEncoder<H, F>
where H: Fn(usize) -> u16 + Send + Sync, F: Fn(&Device) -> H,

§

type O1 = PulseWidthEncoderOp<H>

§

type O2 = NullOp

§

type G = PulseWidthEncoderOpGenerator<H, F>

source§

impl<K, FK, F> Datagram for Group<K, FK, F>
where K: Hash + Eq + Clone + Debug + Send + Sync + 'static, FK: Fn(&Transducer) -> Option<K> + Send + Sync + 'static, F: Fn(&Device) -> FK + Send + Sync + 'static,

§

type O1 = GainOp

§

type O2 = NullOp

§

type G = GainOperationGenerator<Group<K, FK, F>>