pub struct InputFile {
pub filename: String,
pub path: String,
pub is_directory: bool,
pub extension: String,
}
Fields§
§filename: String
§path: String
§is_directory: bool
§extension: String
Implementations§
Source§impl InputFile
impl InputFile
pub fn create_directory(&self, output_filename: String) -> String
pub fn replace_extensions(&self, new_value: &str) -> Self
pub fn replace_filename_extension(&self, new_value: &str) -> String
pub fn replace_path_extension(&self, new_value: &str) -> String
pub fn read_contents(&self) -> String
pub fn is_in_directory(&self, directory: String, root: String) -> bool
pub fn is_extension(&self, extension: &str) -> bool
Trait Implementations§
Source§impl<'de> Deserialize<'de> for InputFile
impl<'de> Deserialize<'de> for InputFile
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for InputFile
impl RefUnwindSafe for InputFile
impl Send for InputFile
impl Sync for InputFile
impl Unpin for InputFile
impl UnwindSafe for InputFile
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