diff options
author | Arne Georg Gleditsch <argggh@lxr.linpro.no> | 2007-11-30 10:44:31 +0100 |
---|---|---|
committer | Arne Georg Gleditsch <argggh@lxr.linpro.no> | 2007-11-30 10:44:31 +0100 |
commit | f35e367d61277573326be776f2eb8af5755657cd (patch) | |
tree | b2063dddf66ecf55a8fa650cc2bcfdb531eb1906 | |
parent | 088bf6be531eef1d591e645056a6b3db7d6a439e (diff) |
Add cache keys for Plain repo backend.
-rw-r--r-- | lib/LXRng/Repo/Plain.pm | 6 | ||||
-rw-r--r-- | lib/LXRng/Repo/Plain/Directory.pm | 6 |
2 files changed, 12 insertions, 0 deletions
diff --git a/lib/LXRng/Repo/Plain.pm b/lib/LXRng/Repo/Plain.pm index 7e64d3c..46fb3f4 100644 --- a/lib/LXRng/Repo/Plain.pm +++ b/lib/LXRng/Repo/Plain.pm @@ -12,6 +12,12 @@ sub new { return bless({root => $root}, $class); } +sub cache_key { + my ($self) = @_; + + return $$self{'root'}; +} + sub allversions { my ($self) = @_; diff --git a/lib/LXRng/Repo/Plain/Directory.pm b/lib/LXRng/Repo/Plain/Directory.pm index 8d7e701..788f6bc 100644 --- a/lib/LXRng/Repo/Plain/Directory.pm +++ b/lib/LXRng/Repo/Plain/Directory.pm @@ -12,6 +12,12 @@ sub new { return bless({name => $name, path => $path, stat => $stat}, $class); } +sub cache_key { + my ($self) = @_; + + return $$self{'path'}; +} + sub time { my ($self) = @_; |