pub struct SimpleDatabaseForge { /* private fields */ }Expand description
简化的数据库填充器(不依赖sqlx)
Implementations§
Source§impl SimpleDatabaseForge
impl SimpleDatabaseForge
Sourcepub fn batch_size(self, size: usize) -> Self
pub fn batch_size(self, size: usize) -> Self
设置批次大小
Sourcepub fn table<F>(
self,
table_name: &str,
count: usize,
config: F,
) -> TableFillConfig
pub fn table<F>( self, table_name: &str, count: usize, config: F, ) -> TableFillConfig
配置表填充
Sourcepub fn schema_parser(&self) -> &SchemaParser
pub fn schema_parser(&self) -> &SchemaParser
获取Schema解析器
Sourcepub fn schema_parser_mut(&mut self) -> &mut SchemaParser
pub fn schema_parser_mut(&mut self) -> &mut SchemaParser
获取可变的Schema解析器
Sourcepub fn connection_string(&self) -> &str
pub fn connection_string(&self) -> &str
获取连接字符串
Sourcepub fn get_batch_size(&self) -> usize
pub fn get_batch_size(&self) -> usize
获取当前批次大小
Auto Trait Implementations§
impl Freeze for SimpleDatabaseForge
impl !RefUnwindSafe for SimpleDatabaseForge
impl Send for SimpleDatabaseForge
impl Sync for SimpleDatabaseForge
impl Unpin for SimpleDatabaseForge
impl !UnwindSafe for SimpleDatabaseForge
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
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more