api: merge "collectionize" code moved to Collection class method