Produced by Araxis Merge on 3/1/2018 12:13:18 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.
| # | Location | File | Last Modified |
|---|---|---|---|
| 1 | ehealth_xchange_cif.zip\NHIN_adapter\AdapterSubscriptionServiceWEB\src\main\java\gov\va\med\nhin\adapter\subscription\web\proxy\provider\documentreference | InMemoryDocumentReferenceProvider.java | Thu Feb 22 14:27:20 2018 UTC |
| 2 | ehealth_xchange_cif.zip\NHIN_adapter\AdapterSubscriptionServiceWEB\src\main\java\gov\va\med\nhin\adapter\subscription\web\proxy\provider\documentreference | InMemoryDocumentReferenceProvider.java | Tue Feb 27 14:30:12 2018 UTC |
| Description | Between Files 1 and 2 |
|
|---|---|---|
| Text Blocks | Lines | |
| Unchanged | 2 | 158 |
| 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 | /* | |
| 2 | * To chan ge this li cense head er, choose License H eaders in Project Pr operties. | |
| 3 | * To chan ge this te mplate fil e, choose Tools | Te mplates | |
| 4 | * and ope n the temp late in th e editor. | |
| 5 | */ | |
| 6 | package go v.va.med.n hin.adapte r.subscrip tion.web.p roxy.provi der.docume ntreferenc e; | |
| 7 | ||
| 8 | import gov .va.med.nh in.adapter .subscript ion.web.da o.InMemory DAO; | |
| 9 | import gov .va.med.nh in.adapter .subscript ion.web.re source.EHX DocumentRe ference; | |
| 10 | import jav a.util.Dat e; | |
| 11 | import jav a.util.Lis t; | |
| 12 | import jav ax.enterpr ise.contex t.Applicat ionScoped; | |
| 13 | import jav ax.enterpr ise.inject .Alternati ve; | |
| 14 | import jav ax.inject. Named; | |
| 15 | import org .hl7.fhir. dstu3.mode l.IdType; | |
| 16 | ||
| 17 | /** | |
| 18 | * | |
| 19 | * @author DN S VAZQUD | |
| 20 | */ | |
| 21 | @Named("In MemoryDocu mentRefere nceProvide r") | |
| 22 | @Applicati onScoped() | |
| 23 | @Alternati ve() | |
| 24 | public cla ss InMemor yDocumentR eferencePr ovider imp lements Do cumentRefe renceProvi der | |
| 25 | { | |
| 26 | privat e InMemory DAO<EHXDoc umentRefer ence> inMe moryDAO = new InMemo ryDAO<>(); | |
| 27 | ||
| 28 | @Overr ide | |
| 29 | public Long crea te(EHXDocu mentRefere nce resour ce) | |
| 30 | { | |
| 31 | Do cumentRefe renceProvi der.super. create(res ource); | |
| 32 | re turn inMem oryDAO.sto re(resourc e); | |
| 33 | } | |
| 34 | ||
| 35 | @Overr ide | |
| 36 | public EHXDocume ntReferenc e read(Lon g id) | |
| 37 | { | |
| 38 | re turn inMem oryDAO.fin dByID(id); | |
| 39 | } | |
| 40 | ||
| 41 | @Overr ide | |
| 42 | public EHXDocume ntReferenc e read(IdT ype id) | |
| 43 | { | |
| 44 | re turn inMem oryDAO.fin dByResourc eID(id.get IdPart()); | |
| 45 | } | |
| 46 | ||
| 47 | @Overr ide | |
| 48 | public void upda te(Long id , EHXDocum entReferen ce resourc e) | |
| 49 | { | |
| 50 | Do cumentRefe renceProvi der.super. update(id, resource) ; | |
| 51 | in MemoryDAO. update(id, resource) ; | |
| 52 | } | |
| 53 | ||
| 54 | @Overr ide | |
| 55 | public EHXDocume ntReferenc e delete(L ong id) | |
| 56 | { | |
| 57 | re turn inMem oryDAO.del ete(id); | |
| 58 | } | |
| 59 | ||
| 60 | @Overr ide | |
| 61 | public List<EHXD ocumentRef erence> fi ndByPatien tIDAndDocu mentRefere nceUpdated OnOrAfter( String pat ientID, Da te date) | |
| 62 | { | |
| 63 | re turn inMem oryDAO.fin d((EHXDocu mentRefere nce dr) -> { | |
| 64 | Date las tUpdated = dr.getMet a().getLas tUpdated() ; | |
| 65 | return d r.getPatie ntID().equ als(patien tID) | |
| 66 | & & lastUpda ted != nul l | |
| 67 | & & (lastUpd ated.equal s(date) | |
| 68 | || last Updated.af ter(date)) ; | |
| 69 | }) ; | |
| 70 | } | |
| 71 | ||
| 72 | @Overr ide | |
| 73 | public EHXDocume ntReferenc e findByBi naryRefere nceURL(Str ing url) | |
| 74 | { | |
| 75 | Li st<EHXDocu mentRefere nce> drs = inMemoryD AO.find((E HXDocument Reference dr) -> { | |
| 76 | return t rue; | |
| 77 | }) ; | |
| 78 | re turn null; | |
| 79 | } | |
| 80 | } |
Araxis Merge (but not the data content of this report) is Copyright © 1993-2016 Araxis Ltd (www.araxis.com). All rights reserved.