You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

23 lines
551 B

7 years ago
7 years ago
7 years ago
  1. #/usr/bin/python
  2. def hash_file(path,hash_if_less,sample):
  3. return _imohash(path,hash_if_less,sample)
  4. class fs:
  5. def __init__(self,top,db_path=None,hash_threshold=1024**2,sample=128*1024):
  6. self.top=top
  7. self.hash_threshold=hash_threshold
  8. if db_path is not None:
  9. self.db_path=db_path
  10. else:
  11. self.db_path = 'fs.db'
  12. def from_db(self,top,db_path,_id=0):
  13. pass
  14. def write_to_db(self):
  15. pass
  16. def morph(self,other):
  17. pass
  18. def backup(self,other):
  19. pass