Struct static_files::ResourceDir [−][src]
pub struct ResourceDir { /* fields omitted */ }
Resource dir.
A builder structure allows to change default settings for:
- file filter
- generated file name
- generated function name
Implementations
impl ResourceDir
[src]
impl ResourceDir
[src]pub fn build(self) -> Result<()>
[src]
Generates resources for current configuration.
pub fn with_filter(&mut self, filter: fn(p: &Path) -> bool) -> &mut Self
[src]
Sets the file filter.
pub fn with_generated_filename<P: AsRef<Path>>(
&mut self,
generated_filename: P
) -> &mut Self
[src]
&mut self,
generated_filename: P
) -> &mut Self
Sets the generated filename.
pub fn with_generated_fn<S>(&mut self, generated_fn: S) -> &mut Self where
S: Into<String>,
[src]
S: Into<String>,
Sets the generated function name.
pub fn with_module_name<S>(&mut self, module_name: S) -> &mut Self where
S: Into<String>,
[src]
S: Into<String>,
Sets the generated module name.
Default value is based on generated function name and the suffix “sets”. Generated module would be overriden by each call.
pub fn with_count_per_module(&mut self, count_per_module: usize) -> &mut Self
[src]
Sets maximal count of files per module.
Trait Implementations
impl Default for ResourceDir
[src]
impl Default for ResourceDir
[src]fn default() -> ResourceDir
[src]
Auto Trait Implementations
impl RefUnwindSafe for ResourceDir
impl RefUnwindSafe for ResourceDir
impl Send for ResourceDir
impl Send for ResourceDir
impl Sync for ResourceDir
impl Sync for ResourceDir
impl Unpin for ResourceDir
impl Unpin for ResourceDir
impl UnwindSafe for ResourceDir
impl UnwindSafe for ResourceDir