use of es.bsc.compss.types.resources.jaxb.ImageType in project compss by bsc-wdc.
the class Validator method validateImages.
private void validateImages(ImagesType images) throws InvalidElementException {
List<String> imageNames = new ArrayList<String>();
List<ImageType> images_list = images.getImage();
if (images_list != null) {
for (ImageType im : images_list) {
if (imageNames.contains(im.getName())) {
throw new InvalidElementException("Images", "Attribute Image " + im.getName(), "Name already used");
} else {
imageNames.add(im.getName());
validateImage(im);
}
}
} else {
// Empty inner elements
throw new InvalidElementException("Images", "", "Content is empty");
}
}
Aggregations