use of org.n52.shetland.ogc.sensorML.v20.DescribedObject in project arctic-sea by 52North.
the class SensorMLDecoderV20 method parseIdentifications.
private void parseIdentifications(DescribedObject describedObject, IdentifierListPropertyType[] identificationArray) {
for (final IdentifierListPropertyType ilpt : identificationArray) {
if (ilpt.isSetIdentifierList() && CollectionHelper.isNotNullOrEmpty(ilpt.getIdentifierList().getIdentifier2Array())) {
for (final Identifier i : ilpt.getIdentifierList().getIdentifier2Array()) {
if (i.getTerm() != null) {
final SmlIdentifier identifier = new SmlIdentifier();
parseTerm(i.getTerm(), identifier);
describedObject.addIdentifier(identifier);
if (isIdentificationProcedureIdentifier(identifier)) {
describedObject.setIdentifier(identifier.getValue());
}
}
}
}
}
}
use of org.n52.shetland.ogc.sensorML.v20.DescribedObject in project arctic-sea by 52North.
the class SensorMLDecoderV20 method parseSimpleProcess.
private DescribedObject parseSimpleProcess(SimpleProcessType describedObject) throws DecodingException {
SimpleProcess sp = new SimpleProcess();
parseAbstractProcess(describedObject, sp);
parseDescribedObject(describedObject, sp);
return sp;
}
use of org.n52.shetland.ogc.sensorML.v20.DescribedObject in project arctic-sea by 52North.
the class SensorMLDecoderV20 method parsePhysicalSystem.
private DescribedObject parsePhysicalSystem(PhysicalSystemType describedObject) throws DecodingException {
PhysicalSystem ps = new PhysicalSystem();
parseAbstractPhysicalProcess(describedObject, ps);
parseAbstractProcess(describedObject, ps);
parseDescribedObject(describedObject, ps);
if (describedObject.isSetComponents()) {
ps.addComponents(parseComponents(describedObject.getComponents()));
final List<Integer> compsToRemove = checkComponentsForRemoval(describedObject.getComponents().getComponentList());
compsToRemove.forEach(describedObject.getComponents().getComponentList()::removeComponent);
if (removeEmptyComponents(describedObject.getComponents())) {
describedObject.unsetComponents();
}
}
return ps;
}
use of org.n52.shetland.ogc.sensorML.v20.DescribedObject in project arctic-sea by 52North.
the class SensorMLDecoderV20 method parseAggregateProcess.
private DescribedObject parseAggregateProcess(AggregateProcessType describedObject) throws DecodingException {
AggregateProcess ap = new AggregateProcess();
parseAbstractProcess(describedObject, ap);
parseDescribedObject(describedObject, ap);
if (describedObject.isSetComponents()) {
ap.addComponents(parseComponents(describedObject.getComponents()));
List<Integer> compsToRemove = checkComponentsForRemoval(describedObject.getComponents().getComponentList());
compsToRemove.forEach(describedObject.getComponents().getComponentList()::removeComponent);
if (removeEmptyComponents(describedObject.getComponents())) {
describedObject.unsetComponents();
}
}
if (describedObject.isSetConnections()) {
ap.setConnections(parseConnections(describedObject.getConnections()));
}
return ap;
}
use of org.n52.shetland.ogc.sensorML.v20.DescribedObject in project arctic-sea by 52North.
the class SensorMLDecoderV20 method parsePhysicalComponent.
private DescribedObject parsePhysicalComponent(PhysicalComponentType describedObject) throws DecodingException {
PhysicalComponent pc = new PhysicalComponent();
parseAbstractPhysicalProcess(describedObject, pc);
parseAbstractProcess(describedObject, pc);
parseDescribedObject(describedObject, pc);
return pc;
}
Aggregations