Prereqs
This commit is contained in:
parent
7d629e38d8
commit
2ccc56a097
5 changed files with 32 additions and 4 deletions
|
|
@ -22,3 +22,12 @@ impl<'a> Resource for DirResource<'a> {
|
|||
fn get_type(&self) -> &str { "dir" }
|
||||
fn get_value(&self) -> &str { &*self.path }
|
||||
}
|
||||
|
||||
pub struct FileResource<'a> {
|
||||
pub path: Cow<'a, str>
|
||||
}
|
||||
|
||||
impl<'a> Resource for FileResource<'a> {
|
||||
fn get_type(&self) -> &str { "file" }
|
||||
fn get_value(&self) -> &str { &*self.path }
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue