pub enum Converter {
Dummy,
Feat,
}
Expand description
Converters to process 5e.tools data into Reroll data.
Variants§
Dummy
Converter sample for testing that returns the input data unmodified.
Feat
Converter to process feats from 5e.tools into Reroll data.
Implementations§
Source§impl Converter
Implement Converter methods to handle data processing.
impl Converter
Implement Converter methods to handle data processing.
Sourcepub fn convert_file(&self, input_path: &Path, output_path: &Path) -> Result<()>
pub fn convert_file(&self, input_path: &Path, output_path: &Path) -> Result<()>
Convert a JSON file containing an array of 5e.tools entries to the Reroll equivalent.
Sourcepub fn convert_string(&self, input: &str) -> Result<String>
pub fn convert_string(&self, input: &str) -> Result<String>
Convert a serialised JSON array of 5e.tools entries to the Reroll equivalent.
Sourcepub fn convert_json(&self, input: &JsonValue) -> Result<JsonValue>
pub fn convert_json(&self, input: &JsonValue) -> Result<JsonValue>
Convert a JsonValue array of 5e.tools entries to the Reroll equivalent.
Auto Trait Implementations§
impl Freeze for Converter
impl RefUnwindSafe for Converter
impl Send for Converter
impl Sync for Converter
impl Unpin for Converter
impl UnwindSafe for Converter
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