Example #1
0
 @Override
 public void onDimseRSP(Association as, DicomObject cmd, DicomObject data) {
   int status = cmd.getInt(Tag.Status);
   switch (status) {
     case 0:
       {
         LOG.debug("Dataset stored at {}", as.getCalledAET());
         break;
       }
     case 0xA700:
       {
         LOG.error(
             "Failed to store dataset - Out Of Resources! (status: {}H, calledAET:{}, comment:{})",
             new Object[] {
               StringUtils.shortToHex(status), as.getCalledAET(), cmd.getString(Tag.ErrorComment)
             });
         break;
       }
     case 0xA900:
       {
         LOG.error(
             "Failed to store dataset - Dataset doesn't match SOP class! (status: {}H, calledAET:{}, comment:{})",
             new Object[] {
               StringUtils.shortToHex(status), as.getCalledAET(), cmd.getString(Tag.ErrorComment)
             });
         break;
       }
     case 0xC000:
       {
         LOG.error(
             "Failed to store dataset - Can't understand! (status: {}H, calledAET:{}, comment:{})",
             new Object[] {
               StringUtils.shortToHex(status), as.getCalledAET(), cmd.getString(Tag.ErrorComment)
             });
         break;
       }
     case 0xB000:
     case 0xB006:
     case 0xB007:
       LOG.warn(
           "Dataset stored at {} with status {}H",
           as.getCalledAET(),
           StringUtils.shortToHex(status));
       break;
     default:
       LOG.error(
           "Failed to store dataset! (status: {}H, calledAET:{}, comment:{})",
           new Object[] {
             StringUtils.shortToHex(status), as.getCalledAET(), cmd.getString(Tag.ErrorComment)
           });
   }
 }
Example #2
0
    @Override
    public void onDimseRSP(Association as, DicomObject cmd, DicomObject data) {
      int status = cmd.getInt(Tag.Status);

      switch (status) {
        case 0x0000:
        case 0x0001:
        case 0x0002:
        case 0x0003:
          break;
        case 0x0116:
          LOG.warn(
              "Received Warning Status 116H (=Attribute Value Out of Range) from remote AE {}",
              as.getCalledAET());
          break;
        default:
          LOG.error(
              "Sending IAN(SCN) failed with status {}H at calledAET:{}",
              StringUtils.shortToHex(status),
              as.getCalledAET());
      }
    }
Example #3
0
 public void setCalledAETs(String calledAET) {
   this.calledAETs = NONE.equals(calledAET) ? null : StringUtils.split(calledAET, '\\');
 }
Example #4
0
 public String getCalledAETs() {
   return calledAETs == null ? NONE : StringUtils.join(calledAETs, '\\');
 }