pub struct DiceBot { /* private fields */ }Expand description
The actual dicebot structure, which drives the entire operation.
This is the core of the dicebot program.
Implementations§
Source§impl DiceBot
impl DiceBot
Sourcepub async fn new(
config_path: Option<PathBuf>,
config: Config,
) -> Result<Self, Box<dyn Error>>
pub async fn new( config_path: Option<PathBuf>, config: Config, ) -> Result<Self, Box<dyn Error>>
Create a new dicebot from the given config path and config
Sourcepub async fn from_path<P: Into<PathBuf>>(
config_path: P,
) -> Result<Self, Box<dyn Error>>
pub async fn from_path<P: Into<PathBuf>>( config_path: P, ) -> Result<Self, Box<dyn Error>>
Create a new dicebot, storing the config path to write it out
Auto Trait Implementations§
impl Freeze for DiceBot
impl !RefUnwindSafe for DiceBot
impl Send for DiceBot
impl Sync for DiceBot
impl Unpin for DiceBot
impl UnsafeUnpin for DiceBot
impl !UnwindSafe for DiceBot
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