use of spold2.FlowData in project olca-modules by GreenDelta.
the class EcoSpold2Export method mapExchanges.
private void mapExchanges(Process process, DataSet ds) {
if (ds.flowData == null)
ds.flowData = new FlowData();
for (Exchange exchange : process.exchanges) {
if (!isValid(exchange))
continue;
Flow flow = exchange.flow;
UserMasterData masterData = ds.masterData;
if (flow.flowType == FlowType.ELEMENTARY_FLOW) {
ElementaryExchange e = createElemExchange(exchange, masterData);
ds.flowData.elementaryExchanges.add(e);
} else {
IntermediateExchange e = createIntermediateExchange(exchange, process, masterData);
ds.flowData.intermediateExchanges.add(e);
}
}
}
Aggregations