protected Collection<ModelType> getModelInstances(
            ModeledPermissions<? extends EntityModel> targetEntity,
            Collection<PermissionType> permissions) {

        // Create new collection of models by manually converting each permission
        Collection<ModelType> models = new ArrayList<ModelType>(permissions.size());
        for (PermissionType permission : permissions)
            models.add(getModelInstance(targetEntity, permission));

        return models;

    }
protected Collection < ModelType > getModelInstances ( ModeledPermissions < ? extends EntityModel > targetEntity , Collection < PermissionType > permissions ) { Collection < ModelType > models = new ArrayList < ModelType > ( permissions . size ( ) ) ; for ( PermissionType permission : permissions ) models . add ( getModelInstance ( targetEntity , permission ) ) ; return models ; }
Returns a collection of model objects which are based on the given
permissions and target entity.

@param targetEntity
The entity to whom this permission is granted.

@param permissions
The permissions to use to produce the returned model objects.

@return
A collection of model objects which are based on the given
permissions and target entity.