pub trait MigrationHook: Fn(&Transaction<'_>) -> HookResult + Send + Sync {
    // Required method
    fn clone_box(&self) -> Box<dyn MigrationHook>;
}
Expand description

Helper trait to make hook functions cloneable.

Required Methods§

source

fn clone_box(&self) -> Box<dyn MigrationHook>

Clone self.

Trait Implementations§

source§

impl Clone for Box<dyn MigrationHook>

source§

fn clone(&self) -> Self

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for Box<dyn MigrationHook>

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Implementors§

source§

impl<T> MigrationHook for T
where T: 'static + Clone + Send + Sync + Fn(&Transaction<'_>) -> HookResult,