18. EPMO Open Source Coordination Office Redaction File Detail Report

Produced by Araxis Merge on 12/5/2017 12:06:34 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.

18.1 Files compared

# Location File Last Modified
1 IV-eHMP_CIF.zip\IMAG_Source\VISA\Java\AwivClientWebApp\main\src\java\gov\va\med\imaging\awiv\server\translator AwivClientTranslator.java Mon Dec 4 21:35:24 2017 UTC
2 IV-eHMP_CIF.zip\IMAG_Source\VISA\Java\AwivClientWebApp\main\src\java\gov\va\med\imaging\awiv\server\translator AwivClientTranslator.java Mon Dec 4 21:56:57 2017 UTC

18.2 Comparison summary

Description Between
Files 1 and 2
Text Blocks Lines
Unchanged 3 884
Changed 2 4
Inserted 0 0
Removed 0 0

18.3 Comparison options

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

18.4 Active regular expressions

No regular expressions were active.

18.5 Comparison detail

  1   /**
  2    * 
  3     Package:  MAG - Vis tA Imaging
  4     WARNING:  Per VHA D irective 2 004-038, t his routin e should n ot be modi fied.
  5     Date Cre ated: Jan  11, 2012
  6     Site Nam e:  Washin gton OI Fi eld Office , Silver S pring, MD
  7       Developer:          
WERFEJ
  8     Descript ion: 
  9  
  10           ;;  +-------- ---------- ---------- ---------- ---------- ---------- ---------- +
  11           ;;  Property  of the US  Government .
  12           ;;  No permis sion to co py or redi stribute t his softwa re is give n.
  13           ;;  Use of un released v ersions of  this soft ware requi res the us er
  14           ;;   to execu te a writt en test ag reement wi th the Vis tA Imaging
  15           ;;   Developm ent Office  of the De partment o f Veterans  Affairs,
  16           ;;   telephon e (301) 73 4-0100.
  17           ;;
  18           ;;  The Food  and Drug A dministrat ion classi fies this  software a s
  19           ;;  a Class I I medical  device.  A s such, it  may not b e changed
  20           ;;  in any wa y.  Modifi cations to  this soft ware may r esult in a n
  21           ;;  adulterat ed medical  device un der 21CFR8 20, the us e of which
  22           ;;  is consid ered to be  a violati on of US F ederal Sta tutes.
  23           ;;  +-------- ---------- ---------- ---------- ---------- ---------- ---------- +
  24  
  25    */
  26   package go v.va.med.i maging.awi v.server.t ranslator;
  27  
  28   import jav a.util.Arr ayList;
  29   import jav a.util.Cal endar;
  30   import jav a.util.Dat e;
  31   import jav a.util.Lis t;
  32   import jav a.util.Sor tedSet;
  33   import jav a.util.Tre eSet;
  34  
  35   import org .apache.lo gging.log4 j.LogManag er;
  36   import org .apache.lo gging.log4 j.Logger;
  37  
  38   import gov .va.med.SE RIALIZATIO N_FORMAT;
  39   import gov .va.med.We llKnownOID ;
  40   import gov .va.med.im aging.arti factsource .ResolvedA rtifactSou rce;
  41   import gov .va.med.im aging.awiv .business. AwivArtifa ctResults;
  42   import gov .va.med.im aging.awiv .business. AwivAuthen ticationSi tesInforma tion;
  43   import gov .va.med.im aging.awiv .business. AwivImage;
  44   import gov .va.med.im aging.awiv .business. AwivMeansT estResult;
  45   import gov .va.med.im aging.awiv .business. AwivPatien tSensitivi ty;
  46   import gov .va.med.im aging.awiv .business. AwivServer Informatio n;
  47   import gov .va.med.im aging.awiv .business. AwivSite;
  48   import gov .va.med.im aging.awiv .business. AwivStudy;
  49   import gov .va.med.im aging.awiv .business. AwivStudyD etails;
  50   import gov .va.med.im aging.awiv .business. AwivStudyS tatus;
  51   import gov .va.med.im aging.awiv .business. AwivWelcom eMessage;
  52   import gov .va.med.im aging.awiv .business. Patient;
  53   import gov .va.med.im aging.awiv .configura tion.AwivC lientConfi guration;
  54   import gov .va.med.im aging.core .interface s.exceptio ns.MethodE xception;
  55   import gov .va.med.im aging.exce ptions.URN FormatExce ption;
  56   import gov .va.med.im aging.exch ange.busin ess.Artifa ctResultEr ror;
  57   import gov .va.med.im aging.exch ange.busin ess.Artifa ctResultEr rorCompara tor;
  58   import gov .va.med.im aging.exch ange.busin ess.Artifa ctResults;
  59   import gov .va.med.im aging.exch ange.busin ess.Image;
  60   import gov .va.med.im aging.exch ange.busin ess.Patien tMeansTest Result;
  61   import gov .va.med.im aging.exch ange.busin ess.Patien tSensitive Value;
  62   import gov .va.med.im aging.exch ange.busin ess.Series ;
  63   import gov .va.med.im aging.exch ange.busin ess.Site;
  64   import gov .va.med.im aging.exch ange.busin ess.Study;
  65   import gov .va.med.im aging.exch ange.busin ess.StudyS etResult;
  66   import gov .va.med.im aging.exch ange.busin ess.Welcom eMessage;
  67   import gov .va.med.im aging.exch ange.busin ess.docume nts.Docume nt;
  68   import gov .va.med.im aging.exch ange.busin ess.docume nts.Docume ntSet;
  69   import gov .va.med.im aging.exch ange.busin ess.docume nts.Docume ntSetResul t;
  70   import gov .va.med.im aging.exch ange.busin ess.util.E xchangeUti l;
  71   import gov .va.med.im aging.exch ange.enums .ArtifactR esultError Code;
  72   import gov .va.med.im aging.exch ange.enums .ObjectSta tus;
  73   import gov .va.med.im aging.exch ange.enums .PatientSe nsitivityL evel;
  74   import gov .va.med.im aging.exch ange.enums .VistaImag eType;
  75   import gov .va.med.im aging.tran slator.Abs tractClini calTransla tor;
  76   import gov .va.med.im aging.webs ervices.cl inical.Abs tractClini calWebAppC onfigurati on;
  77  
  78   /**
  79    * Transla tor for co nverting V IX busines s objects  into AWIV  serializab le objects
  80    * 
  81    * @author         
WERFEJ
  82    *
  83    */
  84   public cla ss AwivCli entTransla tor
  85   extends Ab stractClin icalTransl ator
  86   {
  87           pr ivate fina l static L ogger logg er = LogMa nager.getL ogger(Awiv ClientTran slator.cla ss);
  88  
  89           pr otected st atic Logge r getLogge r()
  90           {
  91                    retu rn logger;
  92           }
  93           
  94           pu blic stati c AwivArti factResult s translat e(Artifact Results ar tifactResu lts) 
  95           th rows URNFo rmatExcept ion, Metho dException
  96           {
  97                    Awiv ArtifactRe sults resu lt = new A wivArtifac tResults() ;
  98                    List <AwivStudy > awivStud ies = new  ArrayList< AwivStudy> ();
  99                    
  100                    // f ix for TFS  #54876
  101                    if(a rtifactRes ults == nu ll)
  102                    {
  103                             getLog ger().warn ("Artifact Results is  null, thi s should n ot happen.  Returning  empty res ult with e rror.");
  104                             result .setAwivSt udies(new  AwivStudy[ 0]);
  105                             return  result;
  106                    }
  107                    
  108                    // f ix for TFS  #54876
  109                    if(a rtifactRes ults.getSt udySetResu lt() == nu ll && arti factResult s.getDocum entSetResu lt() == nu ll)
  110                    {
  111                             getLog ger().warn ("Both Stu dySetResul t and Docu mentSetRes ult of Art ifactResul ts are nul l, probabl y indicate s patient  not actual ly seen at  site. Ret urning emp ty result  without er ror.");
  112                             result .setAwivSt udies(new  AwivStudy[ 0]);
  113                             return  result;
  114                    }
  115                    
  116                    bool ean isPart ial = arti factResult s.isPartia lResult();
  117                    Stud ySetResult  studySetR esult = ar tifactResu lts.getStu dySetResul t();
  118                    bool ean gotARe sult = fal se;
  119                    Sort edSet<Arti factResult Error> err ors = 
  120                             new Tr eeSet<Arti factResult Error>(new  ArtifactR esultError Comparator ());
  121                    if(s tudySetRes ult != nul l)
  122                    {
  123                             if(stu dySetResul t.getArtif acts() !=  null)
  124                             {
  125                                      for(Stud y study :  studySetRe sult.getAr tifacts())
  126                                      {
  127                                               awivStudie s.add(tran slateStudy (study));
  128                                               gotAResult  = true;
  129                                      }
  130                             }
  131                             if(stu dySetResul t.getArtif actResultE rrors() !=  null)
  132                             {
  133                                      for(Arti factResult Error erro r : studyS etResult.g etArtifact ResultErro rs())
  134                                      {
  135                                               errors.add (error);
  136                                      }
  137                             }
  138                    }
  139                    Docu mentSetRes ult docume ntSetResul t = artifa ctResults. getDocumen tSetResult ();
  140                    if(d ocumentSet Result !=  null)
  141                    {
  142                             // thi s will onl y be popul ated if ge tting docu ments from  the DoD,  otherwise  VA documen ts 
  143                             // wil l be inclu ded in the  StudySetR esult
  144                             if(doc umentSetRe sult.getAr tifacts()  != null)
  145                             {
  146                                      for(Docu mentSet do cumentSet  : document SetResult. getArtifac ts())
  147                                      {
  148                                               awivStudie s.addAll(t ranslate(d ocumentSet ));
  149                                               gotAResult  = true;
  150                                      }
  151                             }
  152                             if(doc umentSetRe sult.getAr tifactResu ltErrors()  != null)
  153                             {
  154                                      for(Arti factResult Error erro r : docume ntSetResul t.getArtif actResultE rrors())
  155                                      {
  156                                               errors.add (error);
  157                                      }
  158                             }
  159                    }
  160                    Stri ngBuilder  partialRes ultErrorMe ssage = ne w StringBu ilder();
  161                    if(! gotAResult )
  162                    {
  163                             // if  no result  was includ ed, then s end an exc eption mes sage from  the error  code
  164                             if(err ors.size()  > 0)
  165                             {
  166                                      // takin g the high est priori ty error c ode to thr ow
  167                                      Artifact ResultErro r error =  errors.fir st();
  168                                      Artifact ResultErro rCode erro rCode = er ror.getErr orCode();
  169                                      if(error Code == Ar tifactResu ltErrorCod e.timeoutE xception)
  170                                               throw new  MethodExce ption("jav a.net.Sock etTimeoutE xception:  Read timed  out");
  171                                      else
  172                                              
  173                                               throw new  MethodExce ption(erro rCode.name () + ": "  + error.ge tCodeConte xt());
  174                             }                         
  175                    }
  176                    else
  177                    {
  178                             // got  a valid r esult but  want to in clude the  details of  the error  message
  179                             //if(( isPartial)  && ( erro rs.size()  > 0))
  180                             // JMW  5/23/2011  P104 - if  there are  any error s, include  them in t he error m essage
  181                             if(err ors.size()  > 0)
  182                             {
  183                                      partialR esultError Message.ap pend("Rece vieved '"  + errors.s ize() + "'  errors: " );
  184                                      for(Arti factResult Error erro r : errors )
  185                                      {                                           
  186                                               partialRes ultErrorMe ssage.appe nd(error.g etCodeCont ext());
  187                                               partialRes ultErrorMe ssage.appe nd("; ");
  188                                      }
  189                             }
  190                    }
  191                    
  192                    resu lt.setPart ialResult( isPartial) ;
  193                    resu lt.setPart ialResultM essage(par tialResult ErrorMessa ge.toStrin g());
  194                    resu lt.setAwiv Studies(aw ivStudies. toArray(ne w AwivStud y[result.s ize()]));
  195                    
  196                    retu rn result;
  197           }
  198           
  199           pr ivate stat ic AwivStu dy transla teStudy(
  200                             Study  study) 
  201           th rows URNFo rmatExcept ion 
  202           {
  203                    if(s tudy == nu ll)
  204                             return  null;
  205                    
  206                    Stri ng siteAbb r = study. getSiteAbb r();
  207                    if(E xchangeUti l.isSiteDO D(study.ge tSiteNumbe r()))
  208                    {
  209                             siteAb br = study .getSiteAb br()+ (stu dy.getSite Name() !=  null ? "-"  + study.g etSiteName () : "");                   
  210                    }
  211                    Stri ng studyCl ass = stud y.getStudy Class() ==  null ? ""  : study.g etStudyCla ss();
  212                    
  213                    
  214                    
  215                    Awiv Study resu lt = 
  216                             new Aw ivStudy(st udy.getStu dyUrn().to String(SER IALIZATION _FORMAT.CD TP), study .getSiteNu mber(), 
  217                                               study.getP atientId() , study.ge tPatientNa me(), stud y.getProce dure(), 
  218                                               study.getP rocedureDa te(), site Abbr, stud y.getImage Count(), s tudy.getDe scription( ), 
  219                                               study.getI magePackag e(), study Class, stu dy.getImag eType(), s tudy.getSp ecialty(),
  220                                               study.getF irstImage( ).getImage Urn().toSt ring(SERIA LIZATION_F ORMAT.CDTP ), false, 
  221                                               study.isSt udyImagesH aveAnnotat ions(), tr anslate(st udy.getStu dyViewStat us()),
  222                                               study.isSe nsitive(),  translate (study.get FirstImage ()));                   
  223                    retu rn result;
  224           }
  225           
  226           pr ivate stat ic AwivStu dyStatus t ranslate(O bjectStatu s objectSt atus)
  227           {
  228                    retu rn new Awi vStudyStat us(objectS tatus.getV alue(), ob jectStatus .getDescri ption());
  229           }
  230           
  231           pr ivate stat ic List<Aw ivStudy> t ranslate(D ocumentSet  documentS et)
  232           {
  233                    if(d ocumentSet  == null)
  234                             return  null;
  235                    
  236                    List <AwivStudy > result =  
  237                             new Ar rayList<Aw ivStudy>() ;
  238                    
  239                    for( Document d ocument :  documentSe t)
  240                    {
  241                             VistaI mageType v istaImageT ype = getI mageType(g etWebAppCo nfiguratio n(), docum ent);
  242                             if(vis taImageTyp e == null)
  243                             {
  244                                      vistaIma geType = V istaImageT ype.UNKNOW N_IMAGING_ TYPE;
  245                                      getLogge r().debug( "Document  with media  type '" +  document. getMediaTy pe() + "',  returning  VistaImag eType of ' " + vistaI mageType +  "' for Cl inical Dis play.");                                                 
  246                             }                
  247                             String  id = docu ment.getGl obalArtifa ctIdentifi er().toStr ing(SERIAL IZATION_FO RMAT.CDTP) ;
  248                             String  siteNumbe r = docume nt.getRepo sitoryId() ;
  249                             if((We llKnownOID .HAIMS_DOC UMENT.isAp plicable(d ocument.ge tGlobalArt ifactIdent ifier().ge tHomeCommu nityId())  || 
  250                                               (ncatRepos itoryId.eq uals(docum ent.getRep ositoryId( )))))
  251                             {
  252                                      siteNumb er = "200" ;
  253                             }
  254                             
  255                             String  procedure  = documen t.getName( );
  256                             String  descripti on = "";
  257                             if(vis taImageTyp e == Vista ImageType. NCAT)
  258                             {
  259                                      // NCAT  reports do n't have a  name valu e
  260                                      descript ion = "Neu rocognitiv e Assessme nt Tool";
  261                             }
  262                             AwivSt udy awivSt udy = new  AwivStudy( id, siteNu mber, docu mentSet.ge tPatientIc n(), 
  263                                               documentSe t.getPatie ntName(),  procedure,  
  264                                               documentSe t.getProce dureDate()  != null ?  documentS et.getProc edureDate( ) : docume nt.getCrea tionDate()
  265                                               "DoD", 1,  descriptio n, "", "",  "", "", i d, true, f alse, tran slate(Obje ctStatus.V IEWABLE),
  266                                               false, tra nslate(doc umentSet,  document,  vistaImage Type));
  267                             
  268                             result .add(awivS tudy);           
  269                    }
  270                    retu rn result;
  271           }
  272           
  273           pr ivate stat ic AwivIma ge transla te(Documen tSet docum entSet, 
  274                             Docume nt documen t, VistaIm ageType vi staImageTy pe)
  275           {
  276                    retu rn new Awi vImage(doc ument.getG lobalArtif actIdentif ier().toSt ring(SERIA LIZATION_F ORMAT.CDTP ),
  277                                      vistaIma geType.get ImageType( ), "", "") ;
  278           }
  279  
  280           pr ivate stat ic Abstrac tClinicalW ebAppConfi guration g etWebAppCo nfiguratio n()
  281           {
  282                    retu rn AwivCli entConfigu ration.get Configurat ion();
  283           }
  284           
  285           pu blic stati c AwivSite  [] transl atePatient SelectionS ites(List< ResolvedAr tifactSour ce> resolv edArtifact Sources)
  286           {
  287                    List <AwivSite>  result =  new ArrayL ist<AwivSi te>();
  288                    
  289                    for( ResolvedAr tifactSour ce resolve dArtifactS ource : re solvedArti factSource s)
  290                    {
  291                             if(res olvedArtif actSource. getArtifac tSource()  instanceof  Site)
  292                             {
  293                                      Site sit e = (Site) resolvedAr tifactSour ce.getArti factSource ();
  294                                      
  295                                      if(site. isSitePati entLookupa ble())
  296                                      {
  297                                               result.add (new AwivS ite(site.g etSiteName (), site.g etSiteNumb er()));
  298                                      }
  299                             }
  300                    }
  301                    retu rn result. toArray(ne w AwivSite [result.si ze()]);
  302           }
  303           
  304           pr ivate stat ic AwivSit e [] trans lateUserAu thenticati onSites(Li st<Resolve dArtifactS ource> res olvedArtif actSources )
  305           {
  306                    List <AwivSite>  result =  new ArrayL ist<AwivSi te>();
  307                    
  308                    for( ResolvedAr tifactSour ce resolve dArtifactS ource : re solvedArti factSource s)
  309                    {
  310                             if(res olvedArtif actSource. getArtifac tSource()  instanceof  Site)
  311                             {
  312                                      Site sit e = (Site) resolvedAr tifactSour ce.getArti factSource ();
  313                                      if(site. isSiteUser Authentica table())
  314                                      {
  315                                               result.add (new AwivS ite(site.g etSiteName (), site.g etSiteNumb er()));
  316                                      }
  317                             }
  318                    }
  319                    retu rn result. toArray(ne w AwivSite [result.si ze()]);
  320           }
  321           
  322           pu blic stati c AwivAuth entication SitesInfor mation tra nslate(Lis t<Resolved ArtifactSo urce> reso lvedArtifa ctSources,  
  323                             AwivCl ientConfig uration aw ivClientCo nfiguratio n, String  version)
  324           {
  325                    Awiv Site [] aw ivSites =  translateU serAuthent icationSit es(resolve dArtifactS ources);
  326                    Awiv ServerInfo rmation aw ivServerIn formation  = translat e(awivClie ntConfigur ation, ver sion);
  327                    
  328                    retu rn new Awi vAuthentic ationSites Informatio n(awivSite s, awivSer verInforma tion);
  329           }
  330           
  331           pu blic stati c AwivServ erInformat ion transl ate(AwivCl ientConfig uration aw ivClientCo nfiguratio n, String  version)
  332           {
  333                    int  idleTimeou tMinutes =  awivClien tConfigura tion.getId leTimeoutM inutes();
  334                    bool ean ieOnly  = awivCli entConfigu ration.isI eOnly();
  335                    bool ean checkM eansTest =  awivClien tConfigura tion.isChe ckMeansTes t();
  336                    retu rn new Awi vServerInf ormation(v ersion, id leTimeoutM inutes, ie Only, chec kMeansTest );
  337           }
  338           
  339           pu blic stati c Patient  [] transla tePatients (List<gov. va.med.ima ging.excha nge.busine ss.Patient > patients )
  340           {
  341                    Pati ent [] res ult = new  Patient[pa tients.siz e()];
  342                    for( int i = 0;  i < patie nts.size() ; i++)
  343                    {                         
  344                             gov.va .med.imagi ng.exchang e.business .Patient p atient = p atients.ge t(i);
  345                             result [i] = tran slate(pati ent);                           
  346                    }
  347                    retu rn result;
  348           }
  349           
  350           pu blic stati c Patient  translate( gov.va.med .imaging.e xchange.bu siness.Pat ient patie nt)
  351           {
  352                    if(p atient ==  null)
  353                             return  null;
  354                    Date  dob = pat ient.getDo b();
  355                    if(d ob.after(n ew Date()) )
  356                    {
  357                             getLog ger().debu g("DOB is  after toda y, subtrac ting 100 y ears from  DOB");
  358                             Calend ar dobCale ndar = Cal endar.getI nstance();
  359                             dobCal endar.setT ime(dob);
  360                             dobCal endar.add( Calendar.Y EAR, -100) ;
  361                             dob =  dobCalenda r.getTime( );
  362                    }
  363                    retu rn new Pat ient(patie nt.getPati entName(),  patient.g etPatientI cn(), 
  364                                      patient. getSsn(),  patient.ge tVeteranSt atus(), do b, patient .getSensit ive());
  365           }
  366           
  367           pu blic stati c AwivStud yDetails t ranslate(S tudy study )
  368           th rows URNFo rmatExcept ion
  369           {
  370                    if(s tudy == nu ll)
  371                             return  null;
  372                    
  373                    Awiv StudyDetai ls result  = new Awiv StudyDetai ls();
  374                    Awiv Study awiv Study = tr anslateStu dy(study);
  375                    
  376                    resu lt.setAwiv Study(awiv Study);
  377                    resu lt.setAwiv Images(tra nslateImag es(study)) ;
  378                    retu rn result;
  379           }
  380           
  381           pr ivate stat ic AwivIma ge[] trans lateImages (Study stu dy)
  382           {
  383                    List <AwivImage > result =  new Array List<AwivI mage>();
  384                    for( Series ser ies : stud y)
  385                    {
  386                             for(Im age image  : series)
  387                             {
  388                                      result.a dd(transla te(image)) ;
  389                             }
  390                    }
  391                    retu rn result. toArray(ne w AwivImag e[result.s ize()]);
  392           }
  393           
  394           pr ivate stat ic AwivIma ge transla te(Image i mage)
  395           {
  396                    if(i mage == nu ll)
  397                             return  null;
  398                    retu rn new Awi vImage(ima ge.getImag eUrn().toS tring(SERI ALIZATION_ FORMAT.CDT P),
  399                                      image.ge tImgType() , image.ge tAbsLocati on(), imag e.getFullL ocation()) ;
  400           }
  401           
  402           pu blic stati c AwivPati entSensiti vity trans late(Patie ntSensitiv eValue pat ientSensit ivityValue )
  403           {
  404                    int  code = pat ientSensit ivityValue .getSensit iveLevel() .getCode() ;
  405                    Stri ng warning Message =  translateN ewLinesToB reaks(pati entSensiti vityValue. getWarning Message()) ;
  406                    retu rn new Awi vPatientSe nsitivity( code, warn ingMessage );
  407           }
  408           
  409           pu blic stati c String t ranslateNe wLinesToBr eaks(Strin g msg)
  410           {
  411                    if(m sg == null )
  412                             return  "";
  413                    retu rn msg.rep lace(new S tring("\n" ), new Str ing("<br>" ));
  414           }
  415           
  416           pu blic stati c PatientS ensitivity Level tran slatePatie ntSensitiv eCode(int  code)
  417           {
  418                    retu rn Patient Sensitivit yLevel.get PatientSen sitivityLe vel(code);
  419           }
  420           
  421           pu blic stati c AwivWelc omeMessage  translate (WelcomeMe ssage welc omeMessage )
  422           {
  423                    if(w elcomeMess age == nul l)
  424                             return  null;
  425                    
  426                    Stri ng message  = welcome Message.ge tMessageTe xt();
  427                    mess age = mess age.replac e(new Stri ng("\n"),  new String ("<br>"));                  
  428                    
  429                    retu rn new Awi vWelcomeMe ssage(mess age);
  430           }
  431           
  432           pu blic stati c AwivMean sTestResul t translat e(PatientM eansTestRe sult patie ntMeansTes t)
  433           {
  434                    if(p atientMean sTest == n ull)
  435                             return  null;
  436                    Stri ng meansTe stMessage  = patientM eansTest.g etMessage( );
  437                    if(m eansTestMe ssage != n ull)
  438                    {
  439                             meansT estMessage  = meansTe stMessage. replace(ne w String(" \n"), new  String("<b r>"));
  440                    }
  441                    retu rn new Awi vMeansTest Result(pat ientMeansT est.getCod e(), 
  442                                      meansTes tMessage);
  443           }
  444   }