pub struct SeedOptions {
pub seed: u64,
pub count: Vec<String>,
pub relation: Vec<String>,
pub skip: Vec<String>,
pub reset: bool,
pub out: Option<PathBuf>,
pub force: bool,
pub dialect: Option<Dialect>,
pub filters: FilterArgs,
pub connection: ConnectionOverrides,
}Fields§
§seed: u64RNG seed: the same seed and drizzle version give the same rows
count: Vec<String>Rows per table: --count 50 for every table, --count users=100
for one (repeatable). A table without a count that references a
seeded table gets one row per parent row, or --relation rows.
relation: Vec<String>Rows of CHILD per row of PARENT: --relation users:posts=3
(repeatable). CHILD needs a foreign key to PARENT.
skip: Vec<String>Leave a table out (repeatable)
reset: boolEmpty the seeded tables first (children before parents)
out: Option<PathBuf>Write the SQL to FILE instead of running it (- for stdout)
force: boolRun --reset without asking for confirmation
dialect: Option<Dialect>Override dialect from config
filters: FilterArgs§connection: ConnectionOverridesTrait Implementations§
Source§impl Args for SeedOptions
impl Args for SeedOptions
Source§fn augment_args<'b>(__clap_app: Command) -> Command
fn augment_args<'b>(__clap_app: Command) -> Command
Source§fn augment_args_for_update<'b>(__clap_app: Command) -> Command
fn augment_args_for_update<'b>(__clap_app: Command) -> Command
Append to
Command so it can instantiate self via
FromArgMatches::update_from_arg_matches_mut Read moreSource§impl Clone for SeedOptions
impl Clone for SeedOptions
Source§impl Debug for SeedOptions
impl Debug for SeedOptions
Source§impl FromArgMatches for SeedOptions
impl FromArgMatches for SeedOptions
Source§fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>
fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>
Source§fn from_arg_matches_mut(
__clap_arg_matches: &mut ArgMatches,
) -> Result<Self, Error>
fn from_arg_matches_mut( __clap_arg_matches: &mut ArgMatches, ) -> Result<Self, Error>
Source§fn update_from_arg_matches(
&mut self,
__clap_arg_matches: &ArgMatches,
) -> Result<(), Error>
fn update_from_arg_matches( &mut self, __clap_arg_matches: &ArgMatches, ) -> Result<(), Error>
Assign values from
ArgMatches to self.Source§fn update_from_arg_matches_mut(
&mut self,
__clap_arg_matches: &mut ArgMatches,
) -> Result<(), Error>
fn update_from_arg_matches_mut( &mut self, __clap_arg_matches: &mut ArgMatches, ) -> Result<(), Error>
Assign values from
ArgMatches to self.Auto Trait Implementations§
impl Freeze for SeedOptions
impl RefUnwindSafe for SeedOptions
impl Send for SeedOptions
impl Sync for SeedOptions
impl Unpin for SeedOptions
impl UnsafeUnpin for SeedOptions
impl UnwindSafe for SeedOptions
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