163. EPMO Open Source Coordination Office Redaction File Detail Report

Produced by Araxis Merge on 12/5/2017 12:06:40 PM Central Standard Time. See www.araxis.com for information about Merge. This report uses XHTML and CSS2, and is best viewed with a modern standards-compliant browser. For optimum results when printing this report, use landscape orientation and enable printing of background images and colours in your browser.

163.1 Files compared

# Location File Last Modified
1 IV-eHMP_CIF.zip\IMAG_Source\VISA\Java\ExchangeDataSource\main\src\java\gov\va\med\imaging\exchange\storage ExchangeStorageUtility.java Mon Dec 4 21:35:10 2017 UTC
2 IV-eHMP_CIF.zip\IMAG_Source\VISA\Java\ExchangeDataSource\main\src\java\gov\va\med\imaging\exchange\storage ExchangeStorageUtility.java Mon Dec 4 21:59:58 2017 UTC

163.2 Comparison summary

Description Between
Files 1 and 2
Text Blocks Lines
Unchanged 3 204
Changed 2 4
Inserted 0 0
Removed 0 0

163.3 Comparison options

Whitespace
Character case Differences in character case are significant
Line endings Differences in line endings (CR and LF characters) are ignored
CR/LF characters Not shown in the comparison detail

163.4 Active regular expressions

No regular expressions were active.

163.5 Comparison detail

  1   /**
  2    * 
  3     Package:  MAG - Vis tA Imaging
  4     WARNING:  Per VHA D irective 2 004-038, t his routin e should n ot be modi fied.
  5     Date Cre ated: Sep  26, 2008
  6     Site Nam e:  Washin gton OI Fi eld Office , Silver S pring, MD
  7       Developer:          
WERFEJ
  8     Descript ion: 
  9  
  10           ;;  +-------- ---------- ---------- ---------- ---------- ---------- ---------- +
  11           ;;  Property  of the US  Government .
  12           ;;  No permis sion to co py or redi stribute t his softwa re is give n.
  13           ;;  Use of un released v ersions of  this soft ware requi res the us er
  14           ;;   to execu te a writt en test ag reement wi th the Vis tA Imaging
  15           ;;   Developm ent Office  of the De partment o f Veterans  Affairs,
  16           ;;   telephon e (301) 73 4-0100.
  17           ;;
  18           ;;  The Food  and Drug A dministrat ion classi fies this  software a s
  19           ;;  a Class I I medical  device.  A s such, it  may not b e changed
  20           ;;  in any wa y.  Modifi cations to  this soft ware may r esult in a n
  21           ;;  adulterat ed medical  device un der 21CFR8 20, the us e of which
  22           ;;  is consid ered to be  a violati on of US F ederal Sta tutes.
  23           ;;  +-------- ---------- ---------- ---------- ---------- ---------- ---------- +
  24  
  25    */
  26   package go v.va.med.i maging.exc hange.stor age;
  27  
  28   import gov .va.med.im aging.Size dInputStre am;
  29   import gov .va.med.im aging.core .interface s.StorageC redentials ;
  30   import gov .va.med.im aging.core .interface s.exceptio ns.Connect ionExcepti on;
  31   import gov .va.med.im aging.core .interface s.exceptio ns.ImageCo nversionEx ception;
  32   import gov .va.med.im aging.core .interface s.exceptio ns.ImageNe arLineExce ption;
  33   import gov .va.med.im aging.core .interface s.exceptio ns.ImageNo tFoundExce ption;
  34   import gov .va.med.im aging.core .interface s.exceptio ns.MethodE xception;
  35   import gov .va.med.im aging.exch ange.busin ess.ImageF ormatQuali tyList;
  36   import gov .va.med.im aging.exch ange.enums .StoragePr oximity;
  37   import gov .va.med.im aging.exch ange.proxy .ExchangeP roxy;
  38  
  39   /**
  40    * @author         
WERFEJ
  41    *
  42    */
  43   public cla ss Exchang eStorageUt ility 
  44   extends Ab stractBuff eredImageS torageFaca de
  45   {
  46           pr ivate fina l Exchange Proxy imag ingProxy;
  47           
  48           pu blic Excha ngeStorage Utility(Ex changeProx y imagingP roxy)
  49           {
  50                    this .imagingPr oxy = imag ingProxy;
  51           }
  52  
  53           /*  (non-Java doc)
  54            *  @see gov. va.med.ima ging.excha nge.storag e.Abstract BufferedIm ageStorage Facade#ope nImageStre amInternal (java.lang .String, g ov.va.med. imaging.co re.interfa ces.Storag eCredentia ls, gov.va .med.imagi ng.exchang e.enums.St orageProxi mity, gov. va.med.ima ging.excha nge.busine ss.ImageFo rmatQualit yList)
  55            * /
  56           @O verride
  57           pr otected By teBufferBa ckedImageS treamRespo nse openIm ageStreamI nternal(
  58                    Stri ng imageId entifier,  StorageCre dentials i mageCreden tials,
  59                    Stor ageProximi ty imagePr oximity,
  60                    Imag eFormatQua lityList r equestForm atQualityL ist)
  61           th rows Image NearLineEx ception, I mageNotFou ndExceptio n,
  62                    Conn ectionExce ption, Ima geConversi onExceptio n, MethodE xception
  63           {        
  64                    Size dInputStre am sizedSt ream = ima gingProxy. getInstanc e(imageIde ntifier, r equestForm atQualityL ist, false );
  65                    if(s izedStream  == null)
  66                             throw  new ImageN otFoundExc eption("No  input str eam return ed from Ex change sou rce [" + i magingProx y.getImage ProxyServi ce() + "]  for image  [" + image Identifier  + "].");
  67                    
  68                    // J MW 3/21/20 11 P104 -  changed ca ll to crea te new Byt eBufferBac kedImageIn putStream  to detect  if the inp ut stream
  69                    // i s an empty  stream. 
  70                    // I f the stre am is empt y, then th row a new  ImageNotFo undExcepti on to prev ent the em pty image  from being  used and  cached         
  71                    Byte BufferBack edImageInp utStream i mageInputS tream = ne w ByteBuff erBackedIm ageInputSt ream(
  72                                      sizedStr eam.getInS tream(), s izedStream .getByteSi ze(), imag ingProxy.g etResponse Checksum() , true);
  73                    if(i mageInputS tream.isEm ptyStream( ))
  74                             throw  new ImageN otFoundExc eption("De tected 0 l ength inpu t stream r esponse fr om Exchang e for imag e '" + ima geIdentifi er + "'.") ;
  75                    
  76                    Byte BufferBack edImageStr eamRespons e response  = 
  77                             new By teBufferBa ckedImageS treamRespo nse(imageI nputStream );
  78                    resp onse.setIm ageQuality (imagingPr oxy.getReq uestedQual ity());
  79                    retu rn respons e;
  80           }
  81  
  82           /*  (non-Java doc)
  83            *  @see gov. va.med.ima ging.excha nge.storag e.Abstract BufferedIm ageStorage Facade#ope nTXTStream Internal(j ava.lang.S tring, gov .va.med.im aging.core .interface s.StorageC redentials , gov.va.m ed.imaging .exchange. enums.Stor ageProximi ty)
  84            * /
  85           @O verride
  86           pr otected By teBufferBa ckedInputS tream open TXTStreamI nternal(St ring image Identifier ,
  87                    Stor ageCredent ials image Credential s, Storage Proximity  imageProxi mity)
  88           th rows Image NearLineEx ception, I mageNotFou ndExceptio n,
  89                    Conn ectionExce ption 
  90           {
  91                    retu rn null;
  92           }
  93  
  94           /*  (non-Java doc)
  95            *  @see gov. va.med.ima ging.core. interfaces .ImageStor ageFacade# openPhotoI d(java.lan g.String,  gov.va.med .imaging.c ore.interf aces.Stora geCredenti als)
  96            * /
  97           @O verride
  98           pu blic ByteB ufferBacke dInputStre am openPho toId(Strin g imageIde ntifier,
  99                             Storag eCredentia ls imageCr edentials)  
  100           th rows Image NotFoundEx ception, C onnectionE xception {
  101                    
  102                    retu rn null;
  103           }
  104   }