Produced by Araxis Merge on 12/13/2018 10:35:24 AM 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 | v12.5_iter_7_build 51.zip\TRM_Upgrade\src\main\java\gov\va\med\ccht\service\report | StandardReportNameResolver.java | Fri Dec 7 17:36:30 2018 UTC |
| 2 | v12.5_iter_7_build 51.zip\TRM_Upgrade\src\main\java\gov\va\med\ccht\service\report | StandardReportNameResolver.java | Wed Dec 12 19:46:44 2018 UTC |
| Description | Between Files 1 and 2 |
|
|---|---|---|
| Text Blocks | Lines | |
| Unchanged | 2 | 214 |
| 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 | * Copyrig ht � 2010 VHA. All r ights rese rved | |
| 3 | ********* ********** ********** ********** ********** ********** *********/ | |
| 4 | // Package | |
| 5 | package go v.va.med.c cht.servic e.report; | |
| 6 | ||
| 7 | import org .springfra mework.ste reotype.Co mponent; | |
| 8 | ||
| 9 | import gov .va.med.cc ht.model.c ommon.DIRe portParame ters; | |
| 10 | import gov .va.med.cc ht.model.r eport.Repo rtParamete rs; | |
| 11 | import gov .va.med.cc ht.model.r eport.Repo rtSetup; | |
| 12 | import gov .va.med.fw .model.loo kup.Lookup ; | |
| 13 | import gov .va.med.fw .report.Re portConfig uration; | |
| 14 | import gov .va.med.fw .report.Si mpleReport NameResolv er; | |
| 15 | import gov .va.med.fw .report.da ta.QueryCr iteria; | |
| 16 | import gov .va.med.fw .util.Stri ngUtils; | |
| 17 | ||
| 18 | /** | |
| 19 | * | |
| 20 | * A Repor tNameResol ver that a ppends the report fo rmat (e.g. "detailed " or | |
| 21 | * "summar y") to the report na me. Before : "ID4Repo rt", After : | |
| 22 | * "ID4Rep ort.detail ed" | |
| 23 | * <p> | |
| 24 | * Project : Common<b r> | |
| 25 | * Created on: 4:19: 11 PM | |
| 26 | * | |
| 27 | * @author DN S
|
|
| 28 | */ | |
| 29 | @Component | |
| 30 | public cla ss Standar dReportNam eResolver extends Si mpleReport NameResolv er { | |
| 31 | ||
| 32 | /* * | |
| 33 | * An instan ce of seri alVersionU ID | |
| 34 | * / | |
| 35 | pr ivate stat ic final l ong serial VersionUID = 2619282 0709143441 90L; | |
| 36 | ||
| 37 | /* * | |
| 38 | * A default construct or | |
| 39 | * / | |
| 40 | pu blic Stand ardReportN ameResolve r() { | |
| 41 | supe r(); | |
| 42 | } | |
| 43 | ||
| 44 | /* * | |
| 45 | * @see gov. va.med.fw. report.Sim pleReportN ameResolve r#getRepor tName(gov. va.med.fw. report.Rep ortConfigu ration) | |
| 46 | * / | |
| 47 | pu blic Strin g getRepor tName(Repo rtConfigur ation conf ig) { | |
| 48 | Quer yCriteria criteria = config.ge tQueryCrit eria(); | |
| 49 | Stan dardReport Criteria r eportCrite ria = crit eria insta nceof Stan dardReport Criteria ? (Standard ReportCrit eria) crit eria | |
| 50 | : null; | |
| 51 | ||
| 52 | if ( reportCrit eria != nu ll) { | |
| 53 | Report Setup setu p = report Criteria.g etReportSe tup(); | |
| 54 | Report Parameters parameter Set = setu p != null ? setup.ge tReportPar ameters() : null; | |
| 55 | ||
| 56 | String reportFor mat = getL ookupName( parameterS et != null ? paramet erSet | |
| 57 | .getReport Format() : null); | |
| 58 | String Builder na me = new S tringBuild er(); | |
| 59 | name.a ppend(conf ig.getRepo rtName()); | |
| 60 | append ToName(nam e, reportF ormat); | |
| 61 | ||
| 62 | DIRepo rtParamete rs diRepor tParameter s = (DIRep ortParamet ers) param eterSet; | |
| 63 | String reportSum maryType = diReportP arameters != null ? diReportPa rameters.g etReportSu mmaryType( ) : null; | |
| 64 | if (re portSummar yType == n ull || Str ingUtils.i sEmpty(rep ortSummary Type) | |
| 65 | || "null". equals(rep ortSummary Type)) { | |
| 66 | // Do no t append a ny suffix to the nam e | |
| 67 | } else { | |
| 68 | if (Stri ngUtils.eq uals(repor tSummaryTy pe, | |
| 69 | Re portConsta nts.REPORT _SUMMARY_T YPE_FACILI TY)) { | |
| 70 | appendToNa me(name, " facility") ; | |
| 71 | } else i f (StringU tils.equal s(reportSu mmaryType, | |
| 72 | Re portConsta nts.REPORT _SUMMARY_T YPE_VISN)) { | |
| 73 | appendToNa me(name, " visn"); | |
| 74 | } else i f (StringU tils.equal s(reportSu mmaryType, | |
| 75 | Re portConsta nts.REPORT _SUMMARY_T YPE_NATION AL)) { | |
| 76 | appendToNa me(name, " national") ; | |
| 77 | } | |
| 78 | } | |
| 79 | //DI | |
| 80 | String subTotalT ype = diRe portParame ters!=null ? diRepor tParameter s.getSubTo talType(): null; | |
| 81 | if (su bTotalType == null | | StringUt ils.isEmpt y(subTotal Type) | |
| 82 | || "null". equals(sub TotalType) ) { | |
| 83 | // Do no t append a ny suffix to the nam e | |
| 84 | } else { | |
| 85 | if (Stri ngUtils.eq uals(subTo talType, | |
| 86 | Re portConsta nts.REPORT _SUB_TOTAL _TYPE_VEND OR)) { | |
| 87 | appendToNa me(name, " vendor"); | |
| 88 | } else i f (StringU tils.equal s(subTotal Type, | |
| 89 | Re portConsta nts.REPORT _SUB_TOTAL _TYPE_DEVI CE)) { | |
| 90 | appendToNa me(name, " device"); | |
| 91 | } | |
| 92 | } | |
| 93 | return name.toSt ring(); | |
| 94 | } | |
| 95 | retu rn super.g etReportNa me(config) ; | |
| 96 | } | |
| 97 | ||
| 98 | pr otected vo id appendT oName(Stri ngBuilder name, Stri ng desc) { | |
| 99 | if ( desc != nu ll) { | |
| 100 | name.a ppend(".") ; | |
| 101 | name.a ppend(Stri ngUtils.de leteWhites pace(desc) ); | |
| 102 | } | |
| 103 | } | |
| 104 | ||
| 105 | pr otected St ring getLo okupName(L ookup look up) { | |
| 106 | retu rn lookup != null ? lookup.get Name() : n ull; | |
| 107 | } | |
| 108 | } |
Araxis Merge (but not the data content of this report) is Copyright © 1993-2016 Araxis Ltd (www.araxis.com). All rights reserved.