pub struct DevReloadBuilder { /* private fields */ }Expand description
Settings for DevReload.
Implementations§
Source§impl DevReloadBuilder
impl DevReloadBuilder
Sourcepub fn poll_interval(self, interval: Duration) -> Self
pub fn poll_interval(self, interval: Duration) -> Self
How often fetchlet.json is checked for a new build. 200 ms by default.
Sourcepub fn on_error(
self,
callback: impl Fn(&ReloadError) + Send + Sync + 'static,
) -> Self
pub fn on_error( self, callback: impl Fn(&ReloadError) + Send + Sync + 'static, ) -> Self
Report failed reloads. By default they are written to standard error.
Sourcepub async fn start<S, F, Fut, E>(
self,
build: F,
) -> Result<DevReload<S>, ReloadError>
pub async fn start<S, F, Fut, E>( self, build: F, ) -> Result<DevReload<S>, ReloadError>
Open the artifact, build the first generation with build, and start
watching for new builds. Fails when the first generation fails.
Auto Trait Implementations§
impl !RefUnwindSafe for DevReloadBuilder
impl !UnwindSafe for DevReloadBuilder
impl Forget for DevReloadBuilder
impl Freeze for DevReloadBuilder
impl Move for DevReloadBuilder
impl Send for DevReloadBuilder
impl Sync for DevReloadBuilder
impl Unpin for DevReloadBuilder
impl UnsafeUnpin for DevReloadBuilder
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