Struct includedir_codegen::IncludeDir
[−]
[src]
pub struct IncludeDir { /* fields omitted */ }
Methods
impl IncludeDir
[src]
pub fn file<P: AsRef<Path>>(self, path: P, comp: Compression) -> IncludeDir
[src]
Add a single file to the binary. With Gzip compression, the file will be encoded to OUT_DIR first. For chaining, it's not sensible to return a Result. If any to-be-included files can't be found, or encoded, this function will panic!.
pub fn add_file<P: AsRef<Path>>(
&mut self,
path: P,
comp: Compression
) -> Result<()>
[src]
&mut self,
path: P,
comp: Compression
) -> Result<()>
Panics
This function panics when CARGO_MANIFEST_DIR or OUT_DIR are not defined.
pub fn dir<P: AsRef<Path>>(self, path: P, comp: Compression) -> IncludeDir
[src]
Add a whole directory recursively to the binary.
This function calls file
, and therefore will panic! on missing files.
pub fn add_dir<P: AsRef<Path>>(
&mut self,
path: P,
comp: Compression
) -> Result<()>
[src]
&mut self,
path: P,
comp: Compression
) -> Result<()>
Panics
This function panics when CARGO_MANIFEST_DIR or OUT_DIR are not defined.