Produced by Araxis Merge on 8/1/2019 1:42:44 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.
# | Location | File | Last Modified |
---|---|---|---|
1 | JLV_2_8_0_0_0_July_2019.zip\JLV_2_8_0_0_0_July_2019\jMeadows\src\main\java\gov\va\med\jmeadows\dataservicehandler | VistaDataVLERServiceHandler.java | Mon Jul 8 19:18:48 2019 UTC |
2 | JLV_2_8_0_0_0_July_2019.zip\JLV_2_8_0_0_0_July_2019\jMeadows\src\main\java\gov\va\med\jmeadows\dataservicehandler | VistaDataVLERServiceHandler.java | Tue Jul 30 20:04:44 2019 UTC |
Description | Between Files 1 and 2 |
|
---|---|---|
Text Blocks | Lines | |
Unchanged | 2 | 436 |
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 | * Janus 4 .0 (c) | |
3 | * Copyrig ht (c) 201 1 Hawaii R esource Gr oup LLC. A ll Rights Reserved. | |
4 | * Develop ed for the Pacific T elehealth & Technolo gy Hui and the Pacif ic Joint I nformation Technolog y Center | |
5 | * Contrib utors: | |
6 | * Hon orable Sen ator Danie l K. Inouy e | |
7 | * VA Pacific Is lands Heal th Care Sy stem | |
8 | * Tri pler Army Medical Ce nter | |
9 | */ | |
10 | ||
11 | ||
12 | package go v.va.med.j meadows.da taserviceh andler; | |
13 | ||
14 | import gov .va.med.jm eadows.com mon.JMeado wsExceptio n; | |
15 | import gov .va.med.jm eadows.dao .beans.JMe dResultCol lection; | |
16 | import gov .va.med.jm eadows.dao .hdd.VLERS iteCache; | |
17 | import gov .va.med.vd s.webservi ce.*; | |
18 | import org .slf4j.Log ger; | |
19 | import org .slf4j.Log gerFactory ; | |
20 | ||
21 | import jav ax.xml.nam espace.QNa me; | |
22 | import jav ax.xml.ws. BindingPro vider; | |
23 | import jav ax.xml.ws. handler.Ha ndler; | |
24 | import jav a.util.Lis t; | |
25 | ||
26 | ||
27 | /** | |
28 | * | |
29 | * @author vhahongot om | |
30 | */ | |
31 | public cla ss VistaDa taVLERServ iceHandler extends D ataService Handler { | |
32 | privat e VistaDat aService m _VistaData VLERServic e; | |
33 | privat e static f inal Logge r LOGGER = LoggerFac tory.getLo gger(Vista DataVLERSe rviceHandl er.class); | |
34 | ||
35 | public VistaData VLERServic eHandler(S tring url) { | |
36 | su per(); | |
37 | ||
38 | se rviceURL = url; | |
39 | se rviceName = "VistaDa taVLERServ ice"; | |
40 | serviceNam espace = " http:// DNS . URL /"; | |
41 | qS erviceName = new QNa me(service Namespace, serviceNa me); | |
42 | ||
43 | se rviceConne ctionTimeo utMS = APP _CONFIG.ge tVLERConne ctionTimeo utMS(); | |
44 | se rviceReque stTimeoutM S = APP_CO NFIG.getVL ERRequestT imeoutMS() ; | |
45 | ||
46 | } | |
47 | ||
48 | privat e synchron ized void createServ ice() { | |
49 | if (m_VistaD ataVLERSer vice == nu ll) { | |
50 | try { | |
51 | m_Vi staDataVLE RService = new Vista DataServic e(); | |
52 | } catch (Exception e) { | |
53 | logE rror(e); | |
54 | thro w new Runt imeExcepti on(e); | |
55 | } | |
56 | } | |
57 | } | |
58 | privat e VistaDat a getVista DataPort() { | |
59 | ||
60 | if (m_VistaD ataVLERSer vice == nu ll) { | |
61 | createSe rvice(); | |
62 | } | |
63 | ||
64 | Vi staData po rt = m_Vis taDataVLER Service.ge tVistaData Port(); | |
65 | ||
66 | // set port e ndpoint ad dress | |
67 | Bi ndingProvi der prov = (BindingP rovider) p ort; | |
68 | pr ov.getRequ estContext ().put(Bin dingProvid er.ENDPOIN T_ADDRESS_ PROPERTY, serviceURL ); | |
69 | pr ov.getRequ estContext ().put("co m.sun.xml. internal.w s.connect. timeout", serviceCon nectionTim eoutMS); | |
70 | pr ov.getRequ estContext ().put("co m.sun.xml. internal.w s.request. timeout", serviceReq uestTimeou tMS); | |
71 | pr ov.getRequ estContext ().put("co m.sun.xml. ws.connect .timeout", serviceCo nnectionTi meoutMS); | |
72 | pr ov.getRequ estContext ().put("co m.sun.xml. ws.request .timeout", serviceRe questTimeo utMS); | |
73 | ||
74 | // SOAP mess age loggin g - Enable to show l ogging in output win dow | |
75 | if ("test".e qualsIgnor eCase(APP_ CONFIG.get AppEnviron ment()) || "developm ent".equal sIgnoreCas e(APP_CONF IG.getAppE nvironment ())) { | |
76 | prov.get Binding(). getHandler Chain().ad d(new SOAP LoggingHan dler()); | |
77 | List<Han dler> hand lerList = prov.getBi nding().ge tHandlerCh ain(); | |
78 | handlerL ist.add(ne w SOAPLogg ingHandler ()); | |
79 | prov.get Binding(). setHandler Chain(hand lerList); | |
80 | } | |
81 | ||
82 | re turn port; | |
83 | } | |
84 | ||
85 | public JMedResul tCollectio n getVLERD ocumentLis t(QueryBea n queryBea n) throws JMeadowsEx ception { | |
86 | JM edResultCo llection r etVal; | |
87 | tr y { | |
88 | VistaDat a port = g etVistaDat aPort(); | |
89 | retVal = new JMedR esultColle ction(port .getPatien tDocumentL ist(queryB ean)); | |
90 | List<Vle rDocument> vdList = retVal.get VlerDocume nts(); | |
91 | for (Vle rDocument vd : vdLis t) { | |
92 | if ( vd.getHome CommunityI d() != nul l) { | |
93 | Author aut hor = new Author(); | |
94 | author.set Institutio n(VLERSite Cache.getV LERSiteNam e(vd.getHo meCommunit yId())); | |
95 | author.set Name(vd.ge tHomeCommu nityId()); | |
96 | vd.getAuth orList().a dd(0, auth or); | |
97 | } | |
98 | } | |
99 | for (Int erfaceStat us interfa ceStatus : retVal.ge tInterface StatusList ()) { | |
100 | inte rfaceStatu s.setName( VLERSiteCa che.getVLE RSiteName( interfaceS tatus)); | |
101 | inte rfaceStatu s.setSourc e("VA Part ner"); | |
102 | } | |
103 | } catch (Exc eption e) { | |
104 | logError (e); | |
105 | retVal = new JMedR esultColle ction(); | |
106 | Interfac eStatus is = new Int erfaceStat us(); | |
107 | is.setDo main("VLER "); | |
108 | is.setEr rorMessage ("Connecti on unavail able."); | |
109 | is.setSt atus("Conn ection una vailable." ); | |
110 | is.setSo urce("VA P artner"); | |
111 | is.setNa me("eHX"); | |
112 | retVal.g etInterfac eStatusLis t().add(is ); | |
113 | } | |
114 | re turn retVa l; | |
115 | } | |
116 | ||
117 | // publ ic String getVLERSit eName(Stri ng hcid) { | |
118 | // String out put = ""; | |
119 | // String hci = ""; | |
120 | // if(hcid.st artsWith(" urn")) { | |
121 | // hci = hcid.subst ring(8, hc id.length( )); | |
122 | // } else { | |
123 | // hci = hcid; | |
124 | // } | |
125 | // if (VLERSi teCache.ge tCode("", hci, "") ! = null) { | |
126 | // output = VLERSit eCache.get Code("", h ci, "").ge tDisplay() ; | |
127 | // } | |
128 | // return out put; | |
129 | // } | |
130 | ||
131 | public VlerDocum ent getVLE RDocument( VlerDocume nt vDoc, Q ueryBean q ueryBean) throws JMe adowsExcep tion { | |
132 | Vl erDocument returnVal = null; | |
133 | tr y { | |
134 | VistaDat a port = g etVistaDat aPort(); | |
135 | returnVa l = port. getPatient Document(v Doc, query Bean); | |
136 | } catch (Exc eption e) { | |
137 | logError (e); | |
138 | throw ne w JMeadows Exception( e); | |
139 | } | |
140 | re turn retur nVal; | |
141 | } | |
142 | ||
143 | public JMedResul tCollectio n getDASVL ERAllergie s(QueryBea n queryBea n) throws JMeadowsEx ception { | |
144 | JM edResultCo llection r eturnVal = null; | |
145 | tr y { | |
146 | VistaDat a port = g etVistaDat aPort(); | |
147 | returnVa l = new JM edResultCo llection(p ort.getVLE RPatientAl lergies(qu eryBean)); | |
148 | } catch (Exc eption e){ | |
149 | logError (e); | |
150 | throw ne w JMeadows Exception( e); | |
151 | } | |
152 | re turn retur nVal; | |
153 | } | |
154 | ||
155 | public JMedResul tCollectio n getDASVL ERProblems (QueryBean queryBean ) throws J MeadowsExc eption { | |
156 | JM edResultCo llection r eturnVal = null; | |
157 | tr y { | |
158 | VistaDat a port = g etVistaDat aPort(); | |
159 | returnVa l = new JM edResultCo llection(p ort.getVLE RPatientPr oblems(que ryBean)); | |
160 | } catch (Exc eption e){ | |
161 | logError (e); | |
162 | throw ne w JMeadows Exception( e); | |
163 | } | |
164 | re turn retur nVal; | |
165 | } | |
166 | ||
167 | public JMedResul tCollectio n getDASVL ERVitals(Q ueryBean q ueryBean) throws JMe adowsExcep tion { | |
168 | JM edResultCo llection r eturnVal = null; | |
169 | tr y { | |
170 | VistaDat a port = g etVistaDat aPort(); | |
171 | returnVa l = new JM edResultCo llection(p ort.getVLE RPatientVi tals(query Bean)); | |
172 | } catch (Exc eption e){ | |
173 | logError (e); | |
174 | throw ne w JMeadows Exception( e); | |
175 | } | |
176 | re turn retur nVal; | |
177 | } | |
178 | ||
179 | public JMedResul tCollectio n getDASVL ERProcedur es(QueryBe an queryBe an) throws JMeadowsE xception { | |
180 | JM edResultCo llection r eturnVal = null; | |
181 | tr y { | |
182 | VistaDat a port = g etVistaDat aPort(); | |
183 | returnVa l = new JM edResultCo llection(p ort.getVLE RPatientPr ocedures(q ueryBean)) ; | |
184 | } catch (Exc eption e){ | |
185 | logError (e); | |
186 | throw ne w JMeadows Exception( e); | |
187 | } | |
188 | re turn retur nVal; | |
189 | } | |
190 | ||
191 | public JMedResul tCollectio n getDASVL ERImmuniza tions(Quer yBean quer yBean) thr ows JMeado wsExceptio n { | |
192 | JM edResultCo llection r eturnVal = null; | |
193 | tr y { | |
194 | VistaDat a port = g etVistaDat aPort(); | |
195 | returnVa l = new JM edResultCo llection(p ort.getVLE RPatientIm munization s(queryBea n)); | |
196 | } catch (Exc eption e){ | |
197 | logError (e); | |
198 | throw ne w JMeadows Exception( e); | |
199 | } | |
200 | re turn retur nVal; | |
201 | } | |
202 | ||
203 | public JMedResul tCollectio n getDASVL ERDemograp hics(Query Bean query Bean) thro ws JMeadow sException { | |
204 | JM edResultCo llection r eturnVal = null; | |
205 | tr y { | |
206 | VistaDat a port = g etVistaDat aPort(); | |
207 | returnVa l = new JM edResultCo llection(p ort.getVLE RPatientDe mographics (queryBean )); | |
208 | } catch (Exc eption e){ | |
209 | logError (e); | |
210 | throw ne w JMeadows Exception( e); | |
211 | } | |
212 | re turn retur nVal; | |
213 | } | |
214 | ||
215 | privat e void log Error(Exce ption e){ | |
216 | LO GGER.error ("VistaDat aService E RROR: " + e.getMessa ge(), e); | |
217 | } | |
218 | ||
219 | } |
Araxis Merge (but not the data content of this report) is Copyright © 1993-2016 Araxis Ltd (www.araxis.com). All rights reserved.