3908. EPMO Open Source Coordination Office Redaction File Detail Report

Produced by Araxis Merge on 6/9/2017 3:50:58 PM Eastern Daylight 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.

3908.1 Files compared

# Location File Last Modified
1 Fri Jun 9 19:50:58 2017 UTC
2 eHealth_Exch (eHealth Exchange Enhancements) Build 3 docs & code_May_2017.zip\VAP_CIF_CODE0502.zip\VAP_CIF_CODE0502\VAP_CIF_CODE0502\nvap-server\src\main\java\gov\va\nvap\server\service\permission\sls\simulator XmlParseUtil.java Fri Apr 21 20:15:58 2017 UTC

3908.2 Comparison summary

Description Between
Files 1 and 2
Text Blocks Lines
Unchanged 0 0
Changed 0 0
Inserted 1 52
Removed 0 0

3908.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

3908.4 Active regular expressions

No regular expressions were active.

3908.5 Comparison detail

        1   package go v.va.nvap. server.ser vice.permi ssion.sls. simulator;
        2  
        3   import jav a.io.ByteA rrayInputS tream;
        4   import jav a.io.IOExc eption;
        5   import jav ax.xml.par sers.Docum entBuilder ;
        6   import jav ax.xml.par sers.Docum entBuilder Factory;
        7   import jav ax.xml.par sers.Parse rConfigura tionExcept ion;
        8   import jav ax.xml.xpa th.XPath;
        9   import jav ax.xml.xpa th.XPathCo nstants;
        10   import jav ax.xml.xpa th.XPathEx pressionEx ception;
        11   import jav ax.xml.xpa th.XPathFa ctory;
        12   import org .w3c.dom.D ocument;
        13   import org .xml.sax.I nputSource ;
        14   import org .xml.sax.S AXExceptio n;
        15  
        16   /**
        17    * Class t o Parse th e XML Docu ment
        18    * @author  Sricharan  Reddy *
        19    */
        20   public cla ss XmlPars eUtil
        21   {
        22  
        23           pu blic stati c final St ring PATIE NT_ID_XPAT H = "/Clin icalDocume nt/recordT arget/pati entRole/id /@extensio n";
        24           
        25           /* *
        26            *  Function  to parse t he XML Doc ument
        27            *  @param    xmlArray t he Byte ar ray repres enting the  XML Docum ent
        28            *  @return   The string  object re presenting  the Patie nt ID from  the Docum ent 
        29            * /
        30           pu blic stati c String p arse(byte[ ] xmlArray )
        31           {
        32            S tring id =  null;
        33              try 
        34                    {
        35                      Do cumentBuil der db = D ocumentBui lderFactor y.newInsta nce().newD ocumentBui lder();
        36                      By teArrayInp utStream b yteStream  = new Byte ArrayInput Stream(xml Array);
        37              InputSourc e is = new  InputSour ce(byteStr eam);
        38                      Do cument doc  = db.pars e(is);
        39                      do c.getDocum entElement ().normali ze();
        40                      XP athFactory  xpf = XPa thFactory. newInstanc e();
        41                  XPath  xpath = xp f.newXPath ();
        42                  id = ( String) xp ath.evalua te(PATIENT _ID_XPATH,  doc, XPat hConstants .STRING);
        43            }
        44                 catch ( XPathExpre ssionExcep tion | Par serConfigu rationExce ption | IO Exception  |SAXExcept ion e)
        45                     {
        46                             throw  new Runtim eException (e);
        47                     }
        48             
        49                     ret urn id!=nu ll?id:"";
        50            }
        51           
        52   }