Made it possible to throw an exception on the getType method, in the Collection interface