protected AuditEvent.AuditEventEntityComponent participantObjectIdentificationToEntity(ParticipantObjectIdentificationType poit) { AuditEvent.AuditEventEntityComponent entity = new AuditEvent.AuditEventEntityComponent() .setIdentifier(new Identifier() .setValue(poit.getParticipantObjectID())) // poit.getParticipantObjectIDTypeCode())) not used here .setType(new Coding() .setCode(String.valueOf(poit.getParticipantObjectTypeCode().getValue())) .setSystem("http://hl7.org/fhir/audit-entity-type")) .setRole(new Coding() .setCode(String.valueOf(poit.getParticipantObjectTypeCodeRole().getValue())) .setSystem("http://hl7.org/fhir/object-role")) .setLifecycle(new Coding() .setCode(String.valueOf(poit.getParticipantObjectDataLifeCycle().getValue())) .setSystem("http://hl7.org/fhir/dicom-audit-lifecycle")) .addSecurityLabel(new Coding() .setCode(poit.getParticipantObjectSensitivity())) .setName(poit.getParticipantObjectName()) // poit.getParticipantObjectDescription) not mappable here .setQuery(poit.getParticipantObjectQuery()); poit.getParticipantObjectDetails().forEach(tvp -> entity.addDetail(new AuditEvent.AuditEventEntityDetailComponent() .setType(tvp.getType()) .setValue(tvp.getValue()))); return entity; }
protected AuditEvent.AuditEventEntityComponent participantObjectIdentificationToEntity(ParticipantObjectIdentificationType poit) { AuditEvent.AuditEventEntityComponent entity = new AuditEvent.AuditEventEntityComponent() .setWhat(new Reference().setIdentifier(new Identifier() .setValue(poit.getParticipantObjectID()))) // poit.getParticipantObjectIDTypeCode())) not used here .setType(new Coding() .setCode(String.valueOf(poit.getParticipantObjectTypeCode().getValue())) .setSystem("http://hl7.org/fhir/audit-entity-type")) .setRole(new Coding() .setCode(String.valueOf(poit.getParticipantObjectTypeCodeRole().getValue())) .setSystem("http://hl7.org/fhir/object-role")) .setLifecycle(new Coding() .setCode(String.valueOf(poit.getParticipantObjectDataLifeCycle().getValue())) .setSystem("http://hl7.org/fhir/dicom-audit-lifecycle")) .addSecurityLabel(new Coding() .setCode(poit.getParticipantObjectSensitivity())) .setName(poit.getParticipantObjectName()) // poit.getParticipantObjectDescription) not mappable here .setQuery(poit.getParticipantObjectQuery()); poit.getParticipantObjectDetails().forEach(tvp -> entity.addDetail(new AuditEvent.AuditEventEntityDetailComponent() .setType(tvp.getType()) .setValue(new Base64BinaryType(tvp.getValue())))); return entity; }