pub trait GraphNode<S>: Send + Syncwhere
S: GraphStateTrait,{
// Required method
fn run<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
state: &'life1 S,
ctx: &'life2 mut NodeContext,
) -> Pin<Box<dyn Future<Output = Result<S::Update>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
}Expand description
图节点抽象:给定当前状态与上下文,返回一个状态增量。