public static Volume checkStorageVolumeExistsInDB(DbClient dbClient,String nativeGuid) throws IOException {
  List<Volume> volumes=CustomQueryUtility.getActiveVolumeByNativeGuid(dbClient,nativeGuid);
  Iterator<Volume> volumesItr=volumes.iterator();
  if (volumesItr.hasNext()) {
    return volumesItr.next();
  }
  return null;
}

public static Volume checkStorageVolumeExistsInDB ( DbClient dbClient , String nativeGuid ) throws IOException { List < Volume > volumes = CustomQueryUtility . getActiveVolumeByNativeGuid ( dbClient , nativeGuid ) ; Iterator < Volume > volumesItr = volumes . iterator ( ) ; if ( volumesItr . hasNext ( ) ) { return volumesItr . next ( ) ; } return null ; }
check storage volume exists in db
