public DataSource createCustomVolumeNameDataSource(Project project,TenantOrg tenant,String volumeLabel,String volumeWWN,String exportName,String configName){
  List<DataObject> dataObjectsList=new ArrayList<>();
  dataObjectsList.add(project);
  dataObjectsList.add(tenant);
  Volume volume=new Volume();
  volume.setLabel(volumeLabel);
  volume.setWWN(volumeWWN);
  dataObjectsList.add(volume);
  Map<String,String> computedValueMap=new HashMap<String,String>();
  if (exportName != null) {
    computedValueMap.put(CustomConfigConstants.CUSTOM_VOLUME_EXPORT_NAME,exportName);
  }
  DataObject[] dataObjects=new DataObject[dataObjectsList.size()];
  return createDataSource(configName,dataObjectsList.toArray(dataObjects),computedValueMap);
}

public DataSource createCustomVolumeNameDataSource ( Project project , TenantOrg tenant , String volumeLabel , String volumeWWN , String exportName , String configName ) { List < DataObject > dataObjectsList = new ArrayList < > ( ) ; dataObjectsList . add ( project ) ; dataObjectsList . add ( tenant ) ; Volume volume = new Volume ( ) ; volume . setLabel ( volumeLabel ) ; volume . setWWN ( volumeWWN ) ; dataObjectsList . add ( volume ) ; Map < String , String > computedValueMap = new HashMap < String , String > ( ) ; if ( exportName != null ) { computedValueMap . put ( CustomConfigConstants . CUSTOM_VOLUME_EXPORT_NAME , exportName ) ; } DataObject [ ] dataObjects = new DataObject [ dataObjectsList . size ( ) ] ; return createDataSource ( configName , dataObjectsList . toArray ( dataObjects ) , computedValueMap ) ; }
creates a datasource that can be used to populate the custom name for a volume .
