values method, some pythonic fixes
count method in DocumentManager class