Adding the partition method for collection classes.