pub struct Send<S: State> {
pub node: String,
pub state: S,
}Expand description
Dynamic fan-out target
Represents a single task in a dynamic fan-out operation. Each Send target specifies which node to execute and provides a custom state for that task.
§Examples
ⓘ
use juncture_core::{Send, State, command::SendTarget};
use serde_json::json;
struct MyState;
impl State for MyState {
type Update = MyStateUpdate;
}
struct MyStateUpdate;
// Create a send target with custom state
let send = Send {
node: "worker".to_string(),
state: MyState { /* ... */ },
};Fields§
§node: StringTarget node name to execute
state: SCustom state for this task (overrides current state)
Trait Implementations§
Auto Trait Implementations§
impl<S> Freeze for Send<S>where
S: Freeze,
impl<S> RefUnwindSafe for Send<S>where
S: RefUnwindSafe,
impl<S> Send for Send<S>
impl<S> Sync for Send<S>
impl<S> Unpin for Send<S>where
S: Unpin,
impl<S> UnsafeUnpin for Send<S>where
S: UnsafeUnpin,
impl<S> UnwindSafe for Send<S>where
S: UnwindSafe,
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