Trait stam::AssociatedFile
source · pub trait AssociatedFile: Configurable + Sealed {
// Required methods
fn filename(&self) -> Option<&str>;
fn set_filename(&mut self, filename: &str) -> &mut Self;
// Provided methods
fn with_filename(self, filename: &str) -> Self
where Self: Sized { ... }
fn filename_without_extension(&self) -> Option<&str> { ... }
fn filename_without_workdir(&self) -> Option<&str> { ... }
}Required Methods§
fn filename(&self) -> Option<&str>
fn set_filename(&mut self, filename: &str) -> &mut Self
Provided Methods§
fn with_filename(self, filename: &str) -> Selfwhere Self: Sized,
sourcefn filename_without_extension(&self) -> Option<&str>
fn filename_without_extension(&self) -> Option<&str>
Returns the filename without (known!) extension. The extension must be a known extension used by STAM for this to work.
sourcefn filename_without_workdir(&self) -> Option<&str>
fn filename_without_workdir(&self) -> Option<&str>
Serializes the filename ready for use with STAM JSON’s @include or STAM CSV. It basically only strips the workdir component, if any.