public CountConnection method