break;
default:
throw new IllegalStateException("Unknown code");
}
//Status
Status status = result.getStatus();
StatusType statusType = objectFactory.createStatusType();
StatusCodeType statusCodeType = objectFactory.createStatusCodeType();
List statusList = status.getCode();
if(statusList != null && statusList.size() > 0)
{
statusCodeType.setValue((String) statusList.get(0));
}
statusType.setStatusMessage(status.getMessage());
statusType.setStatusCode(statusCodeType);
resultType.setStatus(statusType);
//Obligations
Set<Obligation> obligationsSet = result.getObligations();