impl Into<String> for FileID
This commit is contained in:
parent
1fc1c73b4a
commit
2585472349
1 changed files with 9 additions and 0 deletions
|
@ -95,6 +95,15 @@ impl Display for FileID {
|
|||
|
||||
}
|
||||
|
||||
impl Into<String> for FileID {
|
||||
|
||||
fn into(self) -> String {
|
||||
let typestr : String = self.id_type.into();
|
||||
let idstr : String = self.id.into();
|
||||
typestr + &idstr[..]
|
||||
}
|
||||
}
|
||||
|
||||
#[cfg(test)]
|
||||
mod test {
|
||||
|
||||
|
|
Loading…
Reference in a new issue