Struct chekov::ApplicationBuilder
source · pub struct ApplicationBuilder<A: Application> { /* private fields */ }
Expand description
Struct to configure and launch an Application
instance
An application can only be launch though an ApplicationBuilder.
This builder will have the responsability to configure every part of the application.
Note: In most cases you will not have to use ApplicationBuilder
directly.
Application
will be the root of everything.
Implementations§
source§impl<A> ApplicationBuilder<A>where
A: Application,
impl<A> ApplicationBuilder<A>where A: Application,
pub fn listener_url(self, url: String) -> Self
sourcepub fn event_handler<E: EventHandler + 'static>(self, handler: E) -> Self
pub fn event_handler<E: EventHandler + 'static>(self, handler: E) -> Self
Adds an EventHandler to the application
sourcepub fn with_storage_config<CFG: StorageConfig<A::Storage> + 'static>(
self,
storage: CFG
) -> Self
pub fn with_storage_config<CFG: StorageConfig<A::Storage> + 'static>( self, storage: CFG ) -> Self
Adds a StorageConfig use later to create the event_store Storage
Trait Implementations§
source§impl<A: Application> Default for ApplicationBuilder<A>
impl<A: Application> Default for ApplicationBuilder<A>
Auto Trait Implementations§
impl<A> !RefUnwindSafe for ApplicationBuilder<A>
impl<A> !Send for ApplicationBuilder<A>
impl<A> !Sync for ApplicationBuilder<A>
impl<A> Unpin for ApplicationBuilder<A>
impl<A> !UnwindSafe for ApplicationBuilder<A>
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