+ "</ParticipantObjectIdentification>"
+ "</AuditMessage>";
@Test
public void testDICOMInstancesTransferred() throws Exception {
AuditMessage msg = new AuditMessage();
msg.setEventIdentification(AuditMessages.createEventIdentification(
AuditMessages.EventID.DICOMInstancesTransferred,
AuditMessages.EventActionCode.Create,
null,
AuditMessages.EventOutcomeIndicator.Success,
null));
msg.getActiveParticipant().add(
AuditMessages.createActiveParticipant(
"123",
AuditMessages.alternativeUserIDForAETitle("AEFOO"),
null,
false,
"192.168.1.2",
AuditMessages.NetworkAccessPointTypeCode.IPAddress,
null,
AuditMessages.RoleIDCode.Source));
msg.getActiveParticipant().add(
AuditMessages.createActiveParticipant(
"67562",
AuditMessages.alternativeUserIDForAETitle("AEPACS"),
null,
false,
"192.168.1.5",
AuditMessages.NetworkAccessPointTypeCode.IPAddress,
null,
AuditMessages.RoleIDCode.Destination));
msg.getActiveParticipant().add(
AuditMessages.createActiveParticipant(
"smitty@readingroom.hospital.org",
"smith@nema",
"Dr. Smith",
true,
"192.168.1.2",
AuditMessages.NetworkAccessPointTypeCode.IPAddress,
null,
AuditMessages.RoleIDCode.Source));
msg.getAuditSourceIdentification().add(
AuditMessages.createAuditSourceIdentification(
"Hospital",
"ReadingRoom",
AuditMessages.AuditSourceTypeCode.EndUserDisplayDevice));
ParticipantObjectDescription pod = new ParticipantObjectDescription();
pod.getMPPS().add(AuditMessages.createMPPS("1.2.840.10008.1.2.3.4.5"));
pod.getAccession().add(AuditMessages.createAccession("12341234"));
pod.getSOPClass().add(AuditMessages.createSOPClass(
"1.2.840.10008.5.1.4.1.1.2", 1500));
pod.getSOPClass().add(AuditMessages.createSOPClass(
"1.2.840.10008.5.1.4.1.1.11.1", 3));
msg.getParticipantObjectIdentification().add(
AuditMessages.createParticipantObjectIdentification(
"1.2.840.10008.2.3.4.5.6.7.78.8",
AuditMessages.ParticipantObjectIDTypeCode.StudyInstanceUID,
null,
null,
AuditMessages.ParticipantObjectTypeCode.SystemObject,
AuditMessages.ParticipantObjectTypeCodeRole.Resource,
AuditMessages.ParticipantObjectDataLifeCycle.OriginationCreation,
null,
pod));
msg.getParticipantObjectIdentification().add(
AuditMessages.createParticipantObjectIdentification(
"ptid12345",
AuditMessages.ParticipantObjectIDTypeCode.PatientNumber,
"John Doe",
null,