subscribe • Rust AI Agent SDK
subscribe: Subscribe to events on the global bus
subscribe
Function
</div>
This function is defined in the bus module.
Subscribe to events on the global bus
Signature
def subscribe(event_type: EventType, handler: F) -> usize
where
F: Fn(&Event) + Send + Sync + 'static,Parameters
ParamField
EventTypeNo description available.
ParamField
FNo description available.
Returns
ResponseField
usize
where
F: Fn(&Event) + Send + Sync + 'static,The result of the operation.
Uses
get_event_bussubscribe
Source
View on GitHubpraisonai/src/bus/mod.rs at line 409