Пример #1
0
 public void TestSafePrivateGEPACSRelated_FromFile() throws Exception {
   AttributeList list = new AttributeList();
   String testFilePath = System.getProperty("com.pixelmed.test.filepath");
   // System.err.println("TestSafePrivateGEPACSRelated.TestSafePrivateGEPACSRelated_FromFile():
   // testFilePath = "+testFilePath);
   list.read(new java.io.File(testFilePath, "philipsctwithgepacsprivateattributes.dcm"));
   // System.err.print("TestSafePrivateGEPACSRelated.TestSafePrivateGEPACSRelated():\n"+list);
   list.removeUnsafePrivateAttributes();
   assertTrue(
       "Checking Creator is not removed", list.get(new AttributeTag(0x0903, 0x0010)) != null);
   assertTrue(
       "Checking Reject Image Flag is not removed",
       list.get(new AttributeTag(0x0903, 0x1010)) != null);
 }
 public void TestSafePrivatePhilipsPETRelated_ScaleFactors_FromFile() throws Exception {
   AttributeList list = new AttributeList();
   String testFilePath = System.getProperty("com.pixelmed.test.filepath");
   // System.err.println("TestSafePrivatePhilipsPETRelated.TestSafePrivatePhilipsPETRelated_ScaleFactors_FromFile(): testFilePath = "+testFilePath);
   list.read(new java.io.File(testFilePath, "philipssuvandactivityscalefactors.dcm"));
   // System.err.print("TestSafePrivatePhilipsPETRelated.TestSafePrivatePhilipsPETRelated_ScaleFactors():\n"+list);
   list.removeUnsafePrivateAttributes();
   assertTrue(
       "Checking Creator is not removed", list.get(new AttributeTag(0x7053, 0x0010)) != null);
   assertTrue(
       "Checking SUV Factor is not removed", list.get(new AttributeTag(0x7053, 0x1000)) != null);
   assertTrue(
       "Checking Activity Concentration Factor is not removed",
       list.get(new AttributeTag(0x7053, 0x1009)) != null);
 }
Пример #3
0
  @Override
  public String toString() {
    String eol = System.getProperty("line.separator");
    String returnString = "Device Observer:" + eol;
    returnString =
        returnString
            + "Device Observer UID = "
            + (this.deviceObserverUID != null ? this.deviceObserverUID : "null")
            + eol
            + "Device Observer Manufacturer = "
            + (this.deviceObserverManufacturer != null ? this.deviceObserverManufacturer : "null")
            + eol
            + "Device Observer Model Name = "
            + (this.deviceObserverModelName != null ? this.deviceObserverModelName : "null")
            + eol
            + "Device Observer Serial Number = "
            + (this.deviceObserverSerialNumber != null ? this.deviceObserverSerialNumber : "null")
            + eol
            + "Device Observer Physical Location  = "
            + (this.deviceObserverPhysicalLocation != null
                ? this.deviceObserverPhysicalLocation
                : "null")
            + eol
            + "Manufacturer = "
            + (this.manufacturer != null ? this.manufacturer : "null")
            + eol
            + "Institution Name = "
            + (this.institutionName != null ? this.institutionName : "null")
            + eol
            + "Station Name = "
            + (this.stationName != null ? this.stationName : "null")
            + eol
            + "Institutional Department Name = "
            + (this.institutionalDepartmentName != null ? this.institutionalDepartmentName : "null")
            + eol
            + "Manufacturer's Model Name = "
            + (this.manufacturersModelName != null ? this.manufacturersModelName : "null")
            + eol
            + "Device Serial Number = "
            + (this.deviceSerialNumber != null ? this.deviceSerialNumber : "null")
            + eol
            + "Software Version = "
            + (this.softwareVersions != null ? this.softwareVersions : "null")
            + eol;

    return returnString;
  }