Added class Counts with most functionality complete, untested