equal
deleted
inserted
replaced
7 use crate::revlog::RevlogEntry; |
7 use crate::revlog::RevlogEntry; |
8 use crate::revlog::{Revlog, RevlogError}; |
8 use crate::revlog::{Revlog, RevlogError}; |
9 use crate::utils::files::get_path_from_bytes; |
9 use crate::utils::files::get_path_from_bytes; |
10 use crate::utils::hg_path::HgPath; |
10 use crate::utils::hg_path::HgPath; |
11 use crate::utils::SliceExt; |
11 use crate::utils::SliceExt; |
|
12 use crate::Graph; |
|
13 use crate::GraphError; |
12 use crate::UncheckedRevision; |
14 use crate::UncheckedRevision; |
13 use std::path::PathBuf; |
15 use std::path::PathBuf; |
14 |
16 |
15 /// A specialized `Revlog` to work with file data logs. |
17 /// A specialized `Revlog` to work with file data logs. |
16 pub struct Filelog { |
18 pub struct Filelog { |
17 /// The generic `revlog` format. |
19 /// The generic `revlog` format. |
18 revlog: Revlog, |
20 revlog: Revlog, |
|
21 } |
|
22 |
|
23 impl Graph for Filelog { |
|
24 fn parents(&self, rev: Revision) -> Result<[Revision; 2], GraphError> { |
|
25 self.revlog.parents(rev) |
|
26 } |
19 } |
27 } |
20 |
28 |
21 impl Filelog { |
29 impl Filelog { |
22 pub fn open_vfs( |
30 pub fn open_vfs( |
23 store_vfs: &crate::vfs::Vfs<'_>, |
31 store_vfs: &crate::vfs::Vfs<'_>, |