Produced by Araxis Merge on 4/5/2017 4:21:47 PM Central 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.
| # | Location | File | Last Modified |
|---|---|---|---|
| 1 | C:\working_scrub\Unredacted\eHX Code Base\eHX_Bld2_Source Code_CIF_2017-02-14\NHIN_adapter\AdapterLIB\src\main\java\gov\va\med\nhin\adapter\datamanager\translators | LatestDateDataTranslator.java | Fri Feb 10 15:41:44 2017 UTC |
| 2 | eHX-CIF.zip\eHX-CIF\eHX Code Base\eHX_Bld2_Source Code_CIF_2017-02-14\NHIN_adapter\AdapterLIB\src\main\java\gov\va\med\nhin\adapter\datamanager\translators | LatestDateDataTranslator.java | Mon Apr 3 14:25:39 2017 UTC |
| Description | Between Files 1 and 2 |
|
|---|---|---|
| Text Blocks | Lines | |
| Unchanged | 2 | 84 |
| Changed | 1 | 2 |
| Inserted | 0 | 0 |
| Removed | 0 | 0 |
| 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 |
No regular expressions were active.
| 1 | package go v.va.med.n hin.adapte r.datamana ger.transl ators; | |
| 2 | ||
| 3 | import jav a.util.Dat e; | |
| 4 | ||
| 5 | import gov .va.med.nh in.adapter .datamanag er.DataMan agerExcept ion; | |
| 6 | import gov .va.med.nh in.adapter .datamanag er.DataQue ry; | |
| 7 | import gov .va.med.nh in.adapter .datamanag er.DataTra nslator; | |
| 8 | import gov .va.med.nh in.adapter .datamanag er.Referen ce; | |
| 9 | ||
| 10 | /** | |
| 11 | * | |
| 12 | * @author DN S VAZQUD | |
| 13 | */ | |
| 14 | public cla ss LatestD ateDataTra nslator im plements D ataTransla tor | |
| 15 | { | |
| 16 | pu blic Objec t translat e(Object i nput, Obje ct result, Reference translati on, DataQu ery dataQu ery) | |
| 17 | { | |
| 18 | Date ret = nul l; | |
| 19 | Stri ng propert yNames = t ranslation .getProper ty("proper tyNames"); | |
| 20 | ||
| 21 | for( String pro pertyName : property Names.spli t(",")) | |
| 22 | { | |
| 23 | try | |
| 24 | { | |
| 25 | Object v alue = tra nslation.g etValue(pr opertyName ); | |
| 26 | if(value != null) | |
| 27 | { | |
| 28 | Date dateV alue = (Da te) value; | |
| 29 | if(ret == null || da teValue.af ter(ret)) | |
| 30 | { | |
| 31 | re t = dateVa lue; | |
| 32 | } | |
| 33 | } | |
| 34 | } | |
| 35 | catch( ClassCastE xception c ce) | |
| 36 | { | |
| 37 | throw ne w DataMana gerExcepti on("Only p roperties of type ja va.util.Da te are sup ported."); | |
| 38 | } | |
| 39 | } | |
| 40 | ||
| 41 | retu rn ret; | |
| 42 | } | |
| 43 | } |
Araxis Merge (but not the data content of this report) is Copyright © 1993-2016 Araxis Ltd (www.araxis.com). All rights reserved.