# HG changeset patch # User Jeff Hammel # Date 1380305847 25200 # Node ID d85093ba9f456fe666bad8811f6bfa9ac41bad9d # Parent 2bc7eee1120785b16894974194a45225668a6991 commitwatcher/store.py diff -r 2bc7eee11207 -r d85093ba9f45 commitwatcher/store.py --- a/commitwatcher/store.py Thu Sep 26 22:27:11 2013 -0700 +++ b/commitwatcher/store.py Fri Sep 27 11:17:27 2013 -0700 @@ -1,15 +1,27 @@ from abc import abstractmethod class CommitStore(object): - """ABC for commits""" + """ + ABC for commits + """ @abstractmethod def add(self, commit): """adds a commit to the store""" + @abstractmethod + def paths(self, *commits): + """return all paths touched for a given commit""" + + class MemoryStore(CommitStore): """store in volatile memory""" # volatile! def add(self, commit): - raise NotImplementedError + raise NotImplementedError() + + def paths(self, *commits): + """ + return touched by commits + """