Trait bee_runtime::node::NodeBuilder [−][src]
A trait that provides generic build configuration capabilities for a node.
Associated Types
type Error: Error
[src]
The type of errors that may be emitted as a result of the build process.
type Config
[src]
Global configuration provided to the node on creation.
Required methods
fn new(config: Self::Config) -> Result<Self, Self::Error>
[src]
Begin building a new node with the provided configuration state.
fn with_worker<W: Worker<N> + 'static>(self) -> Self where
W::Config: Default,
[src]
W::Config: Default,
Register a worker, with default configuration state, that should be started with the node.
fn with_worker_cfg<W: Worker<N> + 'static>(self, config: W::Config) -> Self
[src]
Register a worker, with the given configuration state, that should be started with the node.
fn with_resource<R: Any + Send + Sync>(self, res: R) -> Self
[src]
Provide a resource that should be registered with the node upon start.
#[must_use]fn finish<'async_trait>(
self
) -> Pin<Box<dyn Future<Output = Result<N, Self::Error>> + 'async_trait>> where
Self: 'async_trait,
[src]
self
) -> Pin<Box<dyn Future<Output = Result<N, Self::Error>> + 'async_trait>> where
Self: 'async_trait,
Finish building the node, returning the final node.