Skip to content

Commit

Permalink
Merge pull request #162 from GoogleCloudPlatform/jk/161
Browse files Browse the repository at this point in the history
Change default TS for SCM, fixes issue #161
  • Loading branch information
danielbeaudreau authored Mar 2, 2023
2 parents 3566612 + df52453 commit d7b7782
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,9 @@ public class StorageCommitmentService extends AbstractDicomService {
private final IDicomWebClient dicomWebClient;
private final AetDictionary aets;

// Set as default negotiated transfer syntax
private final String transferSyntax = UID.ImplicitVRLittleEndian;

StorageCommitmentService(IDicomWebClient dicomWebClient, AetDictionary aets) {
super(UID.StorageCommitmentPushModelSOPClass);
this.dicomWebClient = dicomWebClient;
Expand Down Expand Up @@ -188,7 +191,7 @@ public void run() {
UID.StorageCommitmentPushModelSOPInstance,
eventTypeId,
makeDataset(presentInstances, absentInstances),
UID.ExplicitVRLittleEndian,
transferSyntax,
handler);

handler.next();
Expand Down Expand Up @@ -217,7 +220,7 @@ private AAssociateRQ makeAAssociateRQ() {
new PresentationContext(
1,
UID.StorageCommitmentPushModelSOPClass,
UID.ExplicitVRLittleEndian));
transferSyntax));
aarq.addRoleSelection(
new RoleSelection(UID.StorageCommitmentPushModelSOPClass, false, true));
return aarq;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,9 @@ public final class StorageCommitmentServiceTest {
final static String clientAET = "CLIENT";
final static String clientHostname = "localhost";

// Default negotiated transfer syntax
final static String transferSyntax = UID.ImplicitVRLittleEndian;


// Client properties.
ApplicationEntity clientAE;
Expand Down Expand Up @@ -142,7 +145,7 @@ public void basicCommitmentServiceTest(IDicomWebClient serverDicomWebClient,
// Associate with peer AE.
Association association =
associate(serverHostname, serverPort,
UID.StorageCommitmentPushModelSOPClass, UID.ExplicitVRLittleEndian);
UID.StorageCommitmentPushModelSOPClass, transferSyntax);

// Issue N-ACTION
DimseRSPAssert rspAssert = new DimseRSPAssert(association, expectedStatus);
Expand All @@ -151,7 +154,7 @@ public void basicCommitmentServiceTest(IDicomWebClient serverDicomWebClient,
UID.StorageCommitmentPushModelSOPInstance,
1,
requestData,
UID.ExplicitVRLittleEndian,
transferSyntax,
rspAssert);
association.waitForOutstandingRSP();

Expand Down Expand Up @@ -204,7 +207,7 @@ private Device createSCUDevice(int listenerPort, Attributes expectReportAttrs,
new TransferCapability(null,
UID.StorageCommitmentPushModelSOPClass,
TransferCapability.Role.SCU,
UID.ExplicitVRLittleEndian));
transferSyntax));
serverDevice.bindConnections();
return serverDevice;
}
Expand Down

0 comments on commit d7b7782

Please sign in to comment.