Search in sources :

Example 1 with StoragePoolBulkRep

use of com.emc.storageos.model.pools.StoragePoolBulkRep in project coprhd-controller by CoprHD.

the class StoragePoolService method queryBulkResourceReps.

@Override
public StoragePoolBulkRep queryBulkResourceReps(List<URI> ids) {
    Iterator<StoragePool> _dbIterator = _dbClient.queryIterativeObjects(getResourceClass(), ids);
    return new StoragePoolBulkRep(BulkList.wrapping(_dbIterator, new Function<StoragePool, StoragePoolRestRep>() {

        @Override
        public StoragePoolRestRep apply(StoragePool storagePool) {
            StoragePoolRestRep restRep = toStoragePoolRep(storagePool, _dbClient, _coordinator);
            restRep.setNumResources(getNumResources(storagePool, _dbClient));
            return restRep;
        }
    }));
}
Also used : Function(com.google.common.base.Function) StoragePool(com.emc.storageos.db.client.model.StoragePool) StoragePoolBulkRep(com.emc.storageos.model.pools.StoragePoolBulkRep) StoragePoolRestRep(com.emc.storageos.model.pools.StoragePoolRestRep)

Aggregations

StoragePool (com.emc.storageos.db.client.model.StoragePool)1 StoragePoolBulkRep (com.emc.storageos.model.pools.StoragePoolBulkRep)1 StoragePoolRestRep (com.emc.storageos.model.pools.StoragePoolRestRep)1 Function (com.google.common.base.Function)1