add countAll method