use of eu.esdihumboldt.hale.io.oml.internal.model.generated.oml.PropertyCollectionType in project hale by halestudio.
the class OmlRdfGenerator method getPropertyCollection.
/**
* Translate the list of the OML Properties To the Jaxb-based
* PropertyCollectionType
*
* @param collection
* @return
*/
private PropertyCollectionType getPropertyCollection(List<Property> collection) {
PropertyCollectionType propCollectionType = new PropertyCollectionType();
if (collection != null) {
Iterator<?> iterator = collection.iterator();
while (iterator.hasNext()) {
// get property from a list
Property property = (Property) iterator.next();
// convert property to the property type
// TODO could be the circular dependencies in case of
// ComposedProperty
PropertyType pType = getPropertyType(property);
// add to the collection
Item item = new Item();
item.setProperty(pType);
propCollectionType.getItem().add(item);
}
}
return propCollectionType;
}
Aggregations