Added count() method.