// and create a direct map between required outputs and
// the gt process outputs
Map<String, ProcessOutput> outputMap = new HashMap<String, ProcessOutput>();
if (request.getResponseForm().getRawDataOutput() != null) {
// only one output in raw form
OutputDefinitionType od = request.getResponseForm().getRawDataOutput();
String outputName = od.getIdentifier().getValue();
outputMap.put(outputName, new ProcessOutput(od, result.get(outputName)));
} else {
for (Iterator it = request.getResponseForm().getResponseDocument().getOutput()
.iterator(); it.hasNext();) {
OutputDefinitionType od = (OutputDefinitionType) it.next();
String outputName = od.getIdentifier().getValue();
outputMap.put(outputName, new ProcessOutput(od, result.get(outputName)));
}
}
return outputMap;