Produced by Araxis Merge on 6/18/2018 3:36:59 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 | CTT_DM2_v7.zip\CTT_ISAAC\hl7-messaging\src\main\java\gov\vha\isaac\ochre\deployment\hapi\extension | VetsMfrM01Mfezxx.java | Tue Jun 12 16:42:49 2018 UTC |
| 2 | CTT_DM2_v7.zip\CTT_ISAAC\hl7-messaging\src\main\java\gov\vha\isaac\ochre\deployment\hapi\extension | VetsMfrM01Mfezxx.java | Thu Jun 14 16:07:31 2018 UTC |
| Description | Between Files 1 and 2 |
|
|---|---|---|
| Text Blocks | Lines | |
| Unchanged | 2 | 294 |
| 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 Notice | |
| 3 | * | |
| 4 | * This is a work of the U.S. Government and is no t subject to copyrig ht | |
| 5 | * protect ion in the United St ates. Fore ign copyri ghts may a pply. | |
| 6 | * | |
| 7 | * License d under th e Apache L icense, Ve rsion 2.0 (the "Lice nse"); | |
| 8 | * you may not use t his file e xcept in c ompliance with the L icense. | |
| 9 | * You may obtain a copy of th e License at | |
| 10 | * | |
| 11 | * http:// www.apache .org/licen ses/LICENS E-2.0 | |
| 12 | * | |
| 13 | * Unless required b y applicab le law or agreed to in writing , software | |
| 14 | * distrib uted under the Licen se is dist ributed on an "AS IS " BASIS, | |
| 15 | * WITHOUT WARRANTIE S OR CONDI TIONS OF A NY KIND, e ither expr ess or imp lied. | |
| 16 | * See the License f or the spe cific lang uage gover ning permi ssions and | |
| 17 | * limitat ions under the Licen se. | |
| 18 | */ | |
| 19 | package go v.vha.isaa c.ochre.de ployment.h api.extens ion; | |
| 20 | ||
| 21 | import org .apache.lo gging.log4 j.LogManag er; | |
| 22 | import org .apache.lo gging.log4 j.Logger; | |
| 23 | ||
| 24 | import ca. uhn.hl7v2. HL7Excepti on; | |
| 25 | import ca. uhn.hl7v2. model.Data TypeExcept ion; | |
| 26 | import ca. uhn.hl7v2. model.Grou p; | |
| 27 | import ca. uhn.hl7v2. model.Mess age; | |
| 28 | import ca. uhn.hl7v2. model.v24. datatype.C E; | |
| 29 | import ca. uhn.hl7v2. model.v24. group.MFR_ M01_MF_QUE RY; | |
| 30 | import ca. uhn.hl7v2. model.v24. segment.Zx x; | |
| 31 | import ca. uhn.hl7v2. parser.Mod elClassFac tory; | |
| 32 | import gov .vha.isaac .ochre.ser vices.dto. publish.Me ssagePrope rties; | |
| 33 | import gov .vha.isaac .ochre.ser vices.dto. publish.Na meValueDTO ; | |
| 34 | ||
| 35 | /** | |
| 36 | * @author PII | |
| 37 | */ | |
| 38 | ||
| 39 | public cla ss VetsMfr M01Mfezxx extends MF R_M01_MF_Q UERY | |
| 40 | { | |
| 41 | pr ivate stat ic Logger log = LogM anager.get Logger(Vet sMfrM01Mfe zxx.class) ; | |
| 42 | ||
| 43 | /* * | |
| 44 | * Creates a new VetsM fnM01Mfezx x Group. | |
| 45 | * / | |
| 46 | pu blic VetsM frM01Mfezx x(Group pa rent, Mode lClassFact ory factor y) { | |
| 47 | supe r(parent, factory); | |
| 48 | try { | |
| 49 | this.a dd(ZRT.cla ss, true, true); | |
| 50 | this.a dd(Zxx.cla ss, false, false); | |
| 51 | } ca tch (HL7Ex ception e) { | |
| 52 | log.er ror( | |
| 53 | "Unexpecte d error cr eating Vet sMfnM01Mfe zxx - this is probab ly a bug i n the sour ce code ge nerator.", | |
| 54 | e); | |
| 55 | } | |
| 56 | } | |
| 57 | ||
| 58 | /* * | |
| 59 | * Returns Z RT - creat es it if n ecessary | |
| 60 | * / | |
| 61 | pu blic ZRT g etZrt() { | |
| 62 | ZRT ret = null ; | |
| 63 | try { | |
| 64 | ret = (ZRT) this .get("ZRT" ); | |
| 65 | } ca tch (HL7Ex ception e) { | |
| 66 | log.er ror("Unexp ected erro r accessin g data - t his is pro bably a bu g in the s ource code generator .", e); | |
| 67 | } | |
| 68 | retu rn ret; | |
| 69 | } | |
| 70 | ||
| 71 | /* * | |
| 72 | * Populates the ZRT s egments un der each M FE segment | |
| 73 | * | |
| 74 | * @param mf eGroup | |
| 75 | * MFE segm ent to shi ch ZRT seg ments will be added | |
| 76 | * @param na meValueObj ect | |
| 77 | * Data to be added i n the ZRT segment, s uch as Pro perties or | |
| 78 | * Relation ships name /value pai rs | |
| 79 | * @param zr tCounter | |
| 80 | * Ordinal ranking of this ZRT segment un der the cu rrent MFE | |
| 81 | * segment | |
| 82 | * @throws H L7Exceptio n | |
| 83 | * / | |
| 84 | pu blic void addZrtSegm ent(VetsMf rM01Mfezxx mfeGroup, NameValue DTO nameVa lueObject, int zrtCo unter) | |
| 85 | throws HL7Except ion { | |
| 86 | mfeG roup.addNo nstandardS egment("ZR T"); | |
| 87 | ZRT zrt = (ZRT ) mfeGroup .get("ZRT" , zrtCount er); | |
| 88 | zrt. getFieldNa me().setVa lue(nameVa lueObject. getName()) ; | |
| 89 | ||
| 90 | Stri ng zrtFiel dValue = n ameValueOb ject.getVa lue(); | |
| 91 | if ( zrtFieldVa lue.length () > 0) { | |
| 92 | zrt.ge tFieldValu e().setVal ue(zrtFiel dValue); | |
| 93 | } el se { | |
| 94 | zrt.ge tFieldValu e().setVal ue("\"\"") ; | |
| 95 | } | |
| 96 | } | |
| 97 | ||
| 98 | /* * | |
| 99 | * Creates a nd populat es a CE ob ject that may be pas sed as a p arameter t o | |
| 100 | * MFE.getPr imaryKeyVa lueMFE() i n an MFE s egment. Th is method does not t ake | |
| 101 | * the VUID as a param eter for c oncepts th at do not have a VUI D - | |
| 102 | * specifica lly for th e case of updating t he standar d terminol ogy versio n | |
| 103 | * file. | |
| 104 | * | |
| 105 | * @param su bset | |
| 106 | * Name of the subset for which the recor d is being created | |
| 107 | * @param co nceptName | |
| 108 | * Name of the concep t for whic h the reco rd is bein g created | |
| 109 | * @return C E datatype object | |
| 110 | * @throws D ataTypeExc eption | |
| 111 | * / | |
| 112 | pu blic CE ge tCeObject( String sub set, Messa ge message ) throws D ataTypeExc eption { | |
| 113 | CE c e = new CE (message); | |
| 114 | ||
| 115 | // g 1R.MFE.4.1 - This is two piece s: File Fl ag '@' VUI D | |
| 116 | ce.g etIdentifi er().setVa lue(subset ); | |
| 117 | ||
| 118 | retu rn ce; | |
| 119 | } | |
| 120 | ||
| 121 | /* * | |
| 122 | * Creates a nd populat es a CE ob ject that may be pas sed as a p arameter t o | |
| 123 | * MFE.getPr imaryKeyVa lueMFE() i n an MFE s egment. | |
| 124 | * | |
| 125 | * @param su bset | |
| 126 | * Name of the subset for which the recor d is being created | |
| 127 | * @param co nceptVuid | |
| 128 | * VUID of the concep t for whic h the reco rd is bein g created | |
| 129 | * @param co nceptName | |
| 130 | * Name of the concep t for whic h the reco rd is bein g created | |
| 131 | * @return C E datatype object | |
| 132 | * @throws D ataTypeExc eption | |
| 133 | * / | |
| 134 | pu blic CE ge tCeObject( String sub set, Strin g conceptV uidString, Message m essage, | |
| 135 | Messag ePropertie s messageP roperties) throws Da taTypeExce ption { | |
| 136 | Stri ng subFiel dSeparator ; | |
| 137 | Stri ng identif ier = null ; | |
| 138 | ||
| 139 | CE c e = new CE (message); | |
| 140 | ||
| 141 | // g 1R.MFE.4.1 - This is two piece s: File Fl ag '@' VUI D | |
| 142 | subF ieldSepara tor = mess agePropert ies.getSub FieldSepar ator(); | |
| 143 | iden tifier = s ubset.conc at(subFiel dSeparator ).concat(c onceptVuid String); | |
| 144 | ce.g etIdentifi er().setVa lue(identi fier); | |
| 145 | ||
| 146 | retu rn ce; | |
| 147 | } | |
| 148 | } |
Araxis Merge (but not the data content of this report) is Copyright © 1993-2016 Araxis Ltd (www.araxis.com). All rights reserved.