Produced by Araxis Merge on 2/7/2017 12:14:08 PM Eastern 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 | cpss.zip\cpss\src\main\java\gov\va\cpss\service | VistaAccountService.java | Wed Feb 1 21:07:26 2017 UTC |
2 | cpss.zip\cpss\src\main\java\gov\va\cpss\service | VistaAccountService.java | Mon Feb 6 15:19:41 2017 UTC |
Description | Between Files 1 and 2 |
|
---|---|---|
Text Blocks | Lines | |
Unchanged | 2 | 196 |
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.cpss. service; | |
2 | ||
3 | import jav a.util.Lis t; | |
4 | ||
5 | import org .apache.lo g4j.Logger ; | |
6 | import org .springfra mework.ste reotype.Se rvice; | |
7 | ||
8 | import gov .va.cpss.d ao.CBSAcco untDAO; | |
9 | import gov .va.cpss.d ao.Process StatusDAO; | |
10 | import gov .va.cpss.d ao.VistaAc countDAO; | |
11 | import gov .va.cpss.m odel.Proce ssStatus; | |
12 | import gov .va.cpss.m odel.icn.V istaAccoun t; | |
13 | ||
14 | /** | |
15 | * Service class for handling activities relating to consoli dating a p atient | |
16 | * stateme nt. | |
17 | * | |
18 | * @author DN S D N S | |
19 | */ | |
20 | @Service | |
21 | public cla ss VistaAc countServi ce { | |
22 | ||
23 | pr ivate stat ic final L ogger logg er = Logge r.getLogge r(VistaAcc ountServic e.class.ge tCanonical Name()); | |
24 | ||
25 | pr ivate CBSA ccountDAO cbsAccount DAO; | |
26 | ||
27 | pr ivate Vist aAccountDA O vistaAcc ountDAO; | |
28 | ||
29 | pr ivate Proc essStatusD AO process StatusDAO; | |
30 | ||
31 | pu blic CBSAc countDAO g etCbsAccou ntDAO() { | |
32 | retu rn cbsAcco untDAO; | |
33 | } | |
34 | ||
35 | pu blic void setCbsAcco untDAO(CBS AccountDAO cbsAccoun tDAO) { | |
36 | this .cbsAccoun tDAO = cbs AccountDAO ; | |
37 | } | |
38 | ||
39 | pu blic Vista AccountDAO getVistaA ccountDAO( ) { | |
40 | retu rn vistaAc countDAO; | |
41 | } | |
42 | ||
43 | pu blic void setVistaAc countDAO(V istaAccoun tDAO vista AccountDAO ) { | |
44 | this .vistaAcco untDAO = v istaAccoun tDAO; | |
45 | } | |
46 | ||
47 | pu blic Proce ssStatusDA O getProce ssStatusDA O() { | |
48 | retu rn process StatusDAO; | |
49 | } | |
50 | ||
51 | pu blic void setProcess StatusDAO( ProcessSta tusDAO pro cessStatus DAO) { | |
52 | this .processSt atusDAO = processSta tusDAO; | |
53 | } | |
54 | ||
55 | pu blic Vista Account ge tAccountRe cord(final long dfn, final Str ing statio nNum) { | |
56 | retu rn vistaAc countDAO.g etVistaAcc ount(dfn, stationNum ); | |
57 | } | |
58 | ||
59 | /* * | |
60 | * Get the a ccount num ber associ ated with this ICN. | |
61 | * | |
62 | * @param ic n | |
63 | * The ICN to associa te with an account n umber. | |
64 | * @return T he existin g or new a ccount num ber. | |
65 | * / | |
66 | pu blic long getAccount NumberForI CN(final S tring icn) { | |
67 | ||
68 | retu rn cbsAcco untDAO.get ByICN(icn) ; | |
69 | } | |
70 | ||
71 | pu blic Strin g getICNFo rAccountNu mber(final long cbss AcntId) { | |
72 | ||
73 | retu rn cbsAcco untDAO.sel ectICNById (cbssAcntI d); | |
74 | } | |
75 | ||
76 | /* * | |
77 | * Register the accoun t for the specified vista reco rd. | |
78 | * | |
79 | * @param ps Patient | |
80 | * The pati ent to reg ister. | |
81 | * @return F lag indica ting if su ccessfully registere d or not. | |
82 | * / | |
83 | pu blic boole an registe rAccount(f inal Vista Account vi staAccount ) { | |
84 | ||
85 | bool ean succes sful = fal se; | |
86 | ||
87 | Inte ger newSta tus = proc essStatusD AO.getStat usFromEnum (ProcessSt atus.Statu s.NEW); | |
88 | ||
89 | if ( newStatus != null) { | |
90 | succes sful = vis taAccountD AO.save(ne wStatus, v istaAccoun t.getDfn() , vistaAcc ount.getSt ationNum() , | |
91 | vistaAccou nt.getIcn( ), vistaAc count.getC bssAcntId( )); | |
92 | } el se { | |
93 | ||
94 | logger .error("Un able to ob tain statu s mapping for: " + P rocessStat us.Status. NEW); | |
95 | } | |
96 | ||
97 | retu rn success ful; | |
98 | } | |
99 | } |
Araxis Merge (but not the data content of this report) is Copyright © 1993-2016 Araxis Ltd (www.araxis.com). All rights reserved.