Added the hasCollection method.