use of com.emc.sa.util.StringComparator in project coprhd-controller by CoprHD.
the class BlockProvider method getVolumeFilter.
@Asset("sourceVolumeFilter")
@AssetDependencies({ "project", "blockVirtualPool" })
public List<AssetOption> getVolumeFilter(AssetOptionsContext ctx, URI projectId, URI virtualPoolId) {
List<String> volumeNames = Lists.newArrayList();
for (VolumeRestRep volume : listSourceVolumes(api(ctx), projectId, new VirtualPoolFilter(virtualPoolId))) {
volumeNames.add(volume.getName());
}
Collections.sort(volumeNames, new StringComparator(false));
return VirtualDataCenterProvider.getVolumeFilterOptions(volumeNames);
}
use of com.emc.sa.util.StringComparator in project coprhd-controller by CoprHD.
the class VirtualDataCenterProvider method getUnmanagedVolumeFilter.
@Asset("volumeFilter")
@AssetDependencies({ "host", "unmanagedBlockVirtualPool" })
public List<AssetOption> getUnmanagedVolumeFilter(AssetOptionsContext ctx, URI host, URI vpool) {
List<String> volumeNames = Lists.newArrayList();
for (UnManagedVolumeRestRep volume : listUnmanagedVolumesByHost(ctx, host)) {
if (matchesVpool(volume, vpool)) {
volumeNames.add(getLabel(volume));
}
}
Collections.sort(volumeNames, new StringComparator(false));
return getVolumeFilterOptions(volumeNames);
}
use of com.emc.sa.util.StringComparator in project coprhd-controller by CoprHD.
the class VirtualDataCenterProvider method getVolumeFilter.
@Asset("volumeFilter")
@AssetDependencies({ "unmanagedBlockStorageSystem", "blockVirtualPool" })
public List<AssetOption> getVolumeFilter(AssetOptionsContext ctx, URI storageSystemId, URI vpool) {
List<String> volumeNames = Lists.newArrayList();
for (UnManagedVolumeRestRep volume : listUnmanagedVolumes(ctx, storageSystemId, vpool)) {
if (!isNonRPExported(volume.getVolumeCharacteristics())) {
volumeNames.add(getLabel(volume));
}
}
Collections.sort(volumeNames, new StringComparator(false));
return getVolumeFilterOptions(volumeNames);
}
Aggregations