Struct teo::core::builders::model_builder::ModelBuilder
source · [−]pub struct ModelBuilder { /* private fields */ }
Implementations
sourceimpl ModelBuilder
impl ModelBuilder
pub fn table_name(&mut self, table_name: impl Into<String>) -> &mut Self
pub fn url_segment_name(
&mut self,
url_segment_name: impl Into<String>
) -> &mut Self
pub fn localized_name(&mut self, localized_name: impl Into<String>) -> &mut Self
pub fn description(&mut self, description: impl Into<String>) -> &mut Self
pub fn identity(&mut self) -> &mut Self
pub fn field<F: Fn(&mut FieldBuilder)>(
&mut self,
name: &'static str,
build: F
) -> &mut Self
pub fn relation<F: Fn(&mut RelationBuilder)>(
&mut self,
name: &'static str,
build: F
) -> &mut Self
pub fn internal(&mut self) -> &mut Self
pub fn enable<F: Fn(&mut ActionBuilder)>(&mut self, build: F) -> &mut Self
pub fn disable<F: Fn(&mut ActionBuilder)>(&mut self, build: F) -> &mut Self
pub fn permissions<F: Fn(&mut PermissionBuilder)>(
&mut self,
build: F
) -> &mut Self
pub fn primary<I, T>(&mut self, keys: I) -> &mut Self where
I: IntoIterator<Item = T>,
T: Into<String>,
pub fn primary_settings<F: Fn(&mut ModelIndexBuilder)>(
&mut self,
build: F
) -> &mut Self
pub fn index<I, T>(&mut self, keys: I) -> &mut Self where
I: IntoIterator<Item = T>,
T: Into<String>,
pub fn index_settings<F: Fn(&mut ModelIndexBuilder)>(
&mut self,
build: F
) -> &mut Self
pub fn unique<I, T>(&mut self, keys: I) -> &mut Self where
I: IntoIterator<Item = T>,
T: Into<String>,
pub fn unique_settings<F: Fn(&mut ModelIndexBuilder)>(
&mut self,
build: F
) -> &mut Self
pub fn on_saved<F, Fut>(&mut self, callback: &'static F) -> &mut Self where
F: Fn(Object) -> Fut + 'static,
Fut: Future<Output = ()> + 'static,
pub fn on_created<F, Fut>(&mut self, callback: &'static F) -> &mut Self where
F: Fn(Object) -> Fut + 'static,
Fut: Future<Output = ()> + 'static,
pub fn on_updated<F, Fut>(&mut self, callback: &'static F) -> &mut Self where
F: Fn(Object) -> Fut + 'static,
Fut: Future<Output = ()> + 'static,
pub fn on_deleted<F, Fut>(&mut self, callback: &'static F) -> &mut Self where
F: Fn(Object) -> Fut + 'static,
Fut: Future<Output = ()> + 'static,
pub fn on_save<F, Fut>(&mut self, callback: &'static F) -> &mut Self where
F: Fn(Object) -> Fut + 'static,
Fut: Future<Output = ()> + 'static,
pub fn on_create<F, Fut>(&mut self, callback: &'static F) -> &mut Self where
F: Fn(Object) -> Fut + 'static,
Fut: Future<Output = ()> + 'static,
pub fn on_update<F, Fut>(&mut self, callback: &'static F) -> &mut Self where
F: Fn(Object) -> Fut + 'static,
Fut: Future<Output = ()> + 'static,
pub fn on_delete<F, Fut>(&mut self, callback: &'static F) -> &mut Self where
F: Fn(Object) -> Fut + 'static,
Fut: Future<Output = ()> + 'static,
Auto Trait Implementations
impl !RefUnwindSafe for ModelBuilder
impl !Send for ModelBuilder
impl !Sync for ModelBuilder
impl Unpin for ModelBuilder
impl !UnwindSafe for ModelBuilder
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
fn vzip(self) -> V
sourceimpl<T> WithSubscriber for T
impl<T> WithSubscriber for T
sourcefn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
sourcefn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more