114. EPMO Open Source Coordination Office Redaction File Detail Report

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

114.1 Files compared

# Location File Last Modified
1 IV-eHMP_CIF.zip\IMAG_Source\VISA\Java\CoreValueObjects\main\src\java\gov\va\med\imaging\exchange\business\dicom DicomServerConfiguration.java Mon Dec 4 21:35:18 2017 UTC
2 IV-eHMP_CIF.zip\IMAG_Source\VISA\Java\CoreValueObjects\main\src\java\gov\va\med\imaging\exchange\business\dicom DicomServerConfiguration.java Tue Dec 5 12:40:57 2017 UTC

114.2 Comparison summary

Description Between
Files 1 and 2
Text Blocks Lines
Unchanged 2 1618
Changed 1 2
Inserted 0 0
Removed 0 0

114.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

114.4 Active regular expressions

No regular expressions were active.

114.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: May  11, 2009
  6     Site Nam e:  Washin gton OI Fi eld Office , Silver S pring, MD
  7     Develope r:  vhaisw louthj
  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.exc hange.busi ness.dicom ;
  27  
  28   import gov .va.med.Ro utingToken ;
  29   import gov .va.med.Ro utingToken Impl;
  30   import gov .va.med.ex ceptions.R outingToke nFormatExc eption;
  31   import gov .va.med.im aging.Stri ngUtil;
  32   import gov .va.med.im aging.exch ange.busin ess.dicom. exceptions .DicomExce ption;
  33   import gov .va.med.im aging.faca de.configu ration.Abs tractBaseF acadeConfi guration;
  34   import gov .va.med.im aging.faca de.configu ration.Enc ryptedConf igurationP ropertyStr ing;
  35   import gov .va.med.im aging.faca de.configu ration.Fac adeConfigu rationFact ory;
  36   import gov .va.med.im aging.faca de.configu ration.Hid denBoolean Configurat ionField;
  37   import gov .va.med.im aging.faca de.configu ration.Hid denConfigu rationFiel d;
  38   import gov .va.med.im aging.faca de.configu ration.Hid denStringC onfigurati onField;
  39   import gov .va.med.im aging.faca de.configu ration.exc eptions.Ca nnotLoadCo nfiguratio nException ;
  40  
  41   import jav a.io.File;
  42   import jav a.net.Inet Address;
  43   import jav a.util.Arr ayList;
  44   import jav a.util.Has hMap;
  45   import jav a.util.Lis t;
  46  
  47   import org .apache.lo gging.log4 j.LogManag er;
  48   import org .apache.lo gging.log4 j.Logger;
  49  
  50   public cla ss DicomSe rverConfig uration 
  51   extends Ab stractBase FacadeConf iguration 
  52   {
  53           fi nal static  Logger lo gger = Log Manager.ge tLogger(Di comServerC onfigurati on.class);
  54  
  55           //  These cou ld be made  new param eters for  P116 -- se e main met hod; Note:  new param eters requ ire VixIns taller (GU I) change  too
  56           pr ivate fina l static S tring theV AImplement ationClass UID = "1.2 .840.11375 4.2.1.3.0" ; // This  value is a ssigned by  ISO organ izations
  57           pr ivate fina l static S tring theV AImplement ationVersi onName = " VA_DICOM V 3.0"; // T his value  assigned b y VistA Im aging
  58           pr ivate fina l static i nt theDico mListenerP ort =  PORT ; // port  for non St ore SCP li stener (li ke Q/R SCP )
  59           pr ivate fina l static i nt thePDUT imeout = 3 00;
  60           pr ivate fina l static i nt theMove QueueCapac ity = 16;
  61           pr ivate fina l static S tring theQ ueryLimit  = "500";
  62           
  63           @H iddenConfi gurationFi eld
  64           pr ivate List <Instrumen tConfig> i nstruments  = new Arr ayList<Ins trumentCon fig>();
  65  
  66           @H iddenConfi gurationFi eld
  67           pr ivate List <ModalityC onfig> mod alities =  new ArrayL ist<Modali tyConfig>( );
  68  
  69           @H iddenConfi gurationFi eld
  70           pr ivate DGWE mailInfo d gwEmailInf o = new DG WEmailInfo ("", "", " ", "", nul l,"");
  71  
  72           @H iddenConfi gurationFi eld
  73           pr ivate List <UIDAction Config> ui dActions =  new Array List<UIDAc tionConfig >();
  74  
  75           @H iddenConfi gurationFi eld
  76           pr ivate Hash Map<String , Instrume ntConfig>  instrument ByPort = n ew HashMap <String, I nstrumentC onfig>();
  77  
  78           @H iddenConfi gurationFi eld
  79           pr ivate Hash Map<String , UIDActio nConfig> o ldSOPClass es = new H ashMap<Str ing, UIDAc tionConfig >();
  80           
  81           @H iddenConfi gurationFi eld
  82           pr ivate Hash Map<String , UIDActio nConfig> n ewSOPClass es = new H ashMap<Str ing, UIDAc tionConfig >();
  83  
  84           @H iddenConfi gurationFi eld
  85           pr ivate Hash Map<String , UIDActio nConfig> u nknownSOPC lasses = n ew HashMap <String, U IDActionCo nfig>();
  86           
  87           // Note: Even tually, th is object  is passed  to XMLEnco der to cre ate and sa ve a XML e ncoded con figuration  file
  88           //       that  represent s this obj ect.  Foun d issue wi th XMLEnco der.  The  XMLEncoder  does not  pass boole an propert ies
  89           //       assi gned to a  default va lue before  the confi g file cre ation.  If  you want  to make su re your ne w property
  90           //       appe ars in the  config fi le, test i t with the  main().
  91       privat e String s iteId;
  92       privat e Encrypte dConfigura tionProper tyString a ccessCode;
  93       privat e Encrypte dConfigura tionProper tyString v erifyCode;
  94           pr ivate bool ean dicomE nabled = f alse;
  95           pr ivate bool ean archiv eEnabled =  false;
  96           pr ivate bool ean iconPr ocessingEn abled = fa lse;
  97       privat e String d icomCorrec tFolder;   // {"vixca che"}  or  "c:/temp/"  + "DCorre ct";
  98       privat e String d icomDebugF older;     // {"vixca che"}  or  "c:/temp/"  + "DDebug ";
  99       privat e String c annedIconF older;     // {"vixco nfig"}/Ima ges ;
  100           pr ivate bool ean dicomD ebugDumpEn abled = tr ue; // mak e sure its  auto off  in x minut es if on!!
  101           pr ivate Inte ger dicomD ebugDumpMi nutes; //  number of  minutes af ter which  debug enab led must b e auto shu toff
  102           pr ivate Long  dicomDebu gDumpStart Millies; / / Millies  stamp when  system st arted
  103           
  104           @H iddenConfi gurationFi eld
  105       privat e volatile  String ho stName;
  106           
  107           @H iddenStrin gConfigura tionField
  108       privat e String f akeHostNam e;
  109       privat e int move QueueCapac ity = theM oveQueueCa pacity;
  110       privat e ArrayLis t<String>  removedEle ments;
  111       privat e ArrayLis t<String>  addedQuery Elements;
  112       privat e String q ueryLimit  = theQuery Limit;
  113       privat e String l egacyGatew ayAddress;
  114       privat e int lega cyGatewayP ort;
  115           pr ivate Hash Map<String , VistaCre dentials>  aeTitleToV istaCreden tialsMap;
  116  
  117           @H iddenConfi gurationFi eld
  118           pr ivate bool ean dicomS tarted = f alse;
  119           
  120           @H iddenBoole anConfigur ationField
  121           pr ivate bool ean ignore SopSwitch  = false; / / for test ing purpos es only: i f true sen ds all SOP s to new D B! (defaul t False)
  122           
  123           @H iddenBoole anConfigur ationField
  124           pr ivate bool ean loadFa lseStats =  false;
  125           pr ivate bool ean format PatientIDw ithDashes  = true;
  126           pr ivate bool ean moveSu bOperation sEnabled =  true;
  127           pr ivate Stri ng impleme ntationCla ssUID;
  128           pr ivate Stri ng impleme ntationVer sionName;
  129           pr ivate bool ean authen ticateAETi tles = tru e;
  130           pr ivate Stri ng applica tionName;
  131           pr ivate int  pduTimeout ;
  132           pr ivate int  dicomListe nerPort;
  133  
  134           pr ivate Impo rterPurgeD elays impo rterPurgeD elays = ne w Importer PurgeDelay s();
  135           
  136           pr ivate Obje ct readRes olve() 
  137           {
  138                    inst ruments =  new ArrayL ist<Instru mentConfig >();
  139                    moda lities = n ew ArrayLi st<Modalit yConfig>() ;
  140                    dgwE mailInfo =  new DGWEm ailInfo("" , "", "",  "", null," ");
  141                    uidA ctions = n ew ArrayLi st<UIDActi onConfig>( );
  142                    inst rumentByPo rt = new H ashMap<Str ing, Instr umentConfi g>();
  143                    oldS OPClasses  = new Hash Map<String , UIDActio nConfig>() ;
  144                    newS OPClasses  = new Hash Map<String , UIDActio nConfig>() ;
  145                    unkn ownSOPClas ses = new  HashMap<St ring, UIDA ctionConfi g>();
  146                    
  147                    if ( importerPu rgeDelays= =null)
  148                    {
  149                             import erPurgeDel ays = new  ImporterPu rgeDelays( );
  150                    }
  151                    
  152                return t his;
  153           }
  154  
  155           @O verride
  156           pu blic Abstr actBaseFac adeConfigu ration loa dDefaultCo nfiguratio n()
  157           {
  158                    this .dicomEnab led = fals e;
  159                    this .archiveEn abled = fa lse;
  160                    this .iconProce ssingEnabl ed = false ;
  161                    this .dicomDebu gDumpEnabl ed = false ;
  162                    this .dicomDebu gDumpMinut es = 30;
  163                    this .dicomDebu gDumpStart Millies =  System.cur rentTimeMi llis(); //  set in se rverLifecy cleEvent o f  DicomLi fecycleLis tener
  164                this.fak eHostName  = null;
  165                this.rem ovedElemen ts = null;
  166                this.add edQueryEle ments = nu ll;
  167                this.dic omStarted  = false;
  168                    this .ignoreSop Switch = f alse;
  169                    this .loadFalse Stats = fa lse;
  170                    this .formatPat ientIDwith Dashes = f alse;
  171                    this .moveSubOp erationsEn abled = fa lse;
  172                    this .implement ationClass UID = theV AImplement ationClass UID;
  173                    this .implement ationVersi onName = t heVAImplem entationVe rsionName;
  174                    this .dicomList enerPort =  theDicomL istenerPor t;
  175                    this .pduTimeou t = thePDU Timeout;
  176                    this .applicati onName = " HDIG";
  177                    this .importerP urgeDelays  = new Imp orterPurge Delays();
  178  
  179                    retu rn this;
  180           }
  181           
  182           pu blic stati c synchron ized Dicom ServerConf iguration  getConfigu ration()
  183           {
  184                    try
  185                    {
  186                             return  FacadeCon figuration Factory.ge tConfigura tionFactor y().getCon figuration (
  187                                               DicomServe rConfigura tion.class );
  188                    }
  189                    catc h(CannotLo adConfigur ationExcep tion clcX)
  190                    {
  191                             // no  need to lo g, already  logged
  192                             return  null;
  193                    }
  194           }
  195  
  196       public  static vo id main(St ring[] arg s) {
  197           //  Run this  from ...\T omcat 6.0\ lib\ folde r:
  198           //  java -cp  ./*; CoreV alueObject s-0.1.jar  gov.va.med .imaging.e xchange.bu siness.dic om.DicomSe rverConfig uration
  199           //                 “<sit eID>” "loc alhost" "6 0100" "<ac cessCode>"  "<verifyC ode>" “DLE =true” “AE =true” “IP E=true”
  200           //  input exa mple: "660 " "localho st" "60100 " "boating 1" "boatin g1." "DLE= true" "AE= false" "IP E=true"
  201           if  (args.len gth != 8)
  202           {
  203                printUsa ge();
  204                return;
  205           }
  206           Di comServerC onfigurati on config  = getConfi guration() ;
  207           co nfig.setSi teId(args[ 0]);
  208           co nfig.setLe gacyGatewa yAddress(a rgs[1]);
  209           co nfig.setLe gacyGatewa yPort(Inte ger.parseI nt(args[2] ));
  210           co nfig.setAc cessCode(n ew Encrypt edConfigur ationPrope rtyString( args[3]));
  211           co nfig.setVe rifyCode(n ew Encrypt edConfigur ationPrope rtyString( args[4]));
  212           St ring path=  System.ge tenv("vixc ache");                   // <x: /vixcache>
  213           if  (path.len gth() < 4)
  214                    path  = "c:/tem p/";
  215           if  (!(path.e ndsWith("/ ") || path .endsWith( "\\")))
  216                    path  += "/";
  217           co nfig.setDi comCorrect Folder(pat h + "DCorr ect");
  218           co nfig.setDi comDebugFo lder(path  + "DDebug" );
  219           co nfig.setDi comDebugDu mpEnabled( false);
  220           ch eckAndMake Dirs(confi g.getDicom CorrectFol der());
  221           ch eckAndMake Dirs(confi g.getDicom DebugFolde r());
  222  
  223           St ring canne dIconPath=  System.ge tenv("vixc onfig");       // <x: /vixconfig />
  224           if  (cannedIc onPath.len gth() < 4)
  225                    path  = "c:/vix config/";
  226           if  (!(canned IconPath.e ndsWith("/ ") || cann edIconPath .endsWith( "\\")))
  227                    cann edIconPath  += "/";
  228           ca nnedIconPa th += "Ima ges/";
  229           co nfig.setCa nnedIconFo lder(canne dIconPath) ;
  230           
  231                    conf ig.setDico mEnabled(! args[5].co ntains("DL E=false")) ;
  232                    conf ig.setArch iveEnabled (!args[6]. contains(" AE=false") );
  233                    conf ig.setIcon Processing Enabled(!a rgs[7].con tains("IPE =false"));
  234                    // T hese could  be made n ew paramet ers for P1 16, Note:  new parame ters requi re VixInst aller (GUI ) change
  235                    conf ig.setImpl ementation ClassUID(t heVAImplem entationCl assUID); 
  236                    conf ig.setImpl ementation VersionNam e(theVAImp lementatio nVersionNa me); 
  237                    conf ig.setDico mListenerP ort(theDic omListener Port);
  238                    conf ig.setForm atPatientI DwithDashe s(false);
  239                    conf ig.setMove SubOperati onsEnabled (true);
  240                    
  241           //  Store the  configura tion
  242           co nfig.store Configurat ion();
  243       }
  244  
  245       privat e static v oid checkA ndMakeDirs (String fo lderPath)
  246       {
  247                    File  folder =  new File(f olderPath) ;
  248                    if ( !folder.ex ists())
  249                    {
  250                             folder .mkdirs();
  251                    }
  252           
  253       }
  254       privat e static v oid printU sage() {
  255           Sy stem.out.p rintln("Th is program  requires  eight argu ments:");
  256           Sy stem.out.p rintln("   * The site  ID");
  257           Sy stem.out.p rintln("   * The lega cy gateway  address") ;
  258           Sy stem.out.p rintln("   * The lega cy gateway  port");
  259           Sy stem.out.p rintln("   * The acce ss code fo r the gate way servic e account" );
  260           Sy stem.out.p rintln("   * The veri fy code fo r the gate way servic e account" );
  261           Sy stem.out.p rintln("   * DICOM Li stener Ena bled setti ng ('DLE=t rue')");
  262           Sy stem.out.p rintln("   * Archival  Enabled s etting ('A E=true')") ;
  263           Sy stem.out.p rintln("   * Icon Pro cessing En abled sett ing ('IPE= true')");
  264  
  265        }
  266  
  267           pu blic boole an isDicom Started()
  268           {
  269                    retu rn dicomSt arted;
  270           }
  271  
  272           pu blic void  setDicomSt arted(bool ean dicomS tarted)
  273           {
  274                    this .dicomStar ted = dico mStarted;
  275           }
  276           
  277           pu blic Strin g getSiteI d()
  278           {
  279                    retu rn siteId;
  280           }
  281  
  282           pu blic void  setSiteId( String sit eId)
  283           {
  284                    this .siteId =  siteId;
  285           }
  286  
  287           pu blic Encry ptedConfig urationPro pertyStrin g getAcces sCode()
  288           {
  289                    retu rn accessC ode;
  290           }
  291  
  292           pu blic void  setAccessC ode(Encryp tedConfigu rationProp ertyString  accessCod e)
  293           {
  294                    this .accessCod e = access Code;
  295           }
  296  
  297           pu blic Encry ptedConfig urationPro pertyStrin g getVerif yCode()
  298           {
  299                    retu rn verifyC ode;
  300           }
  301  
  302           pu blic void  setVerifyC ode(Encryp tedConfigu rationProp ertyString  verifyCod e)
  303           {
  304                    this .verifyCod e = verify Code;
  305           }
  306           
  307  
  308           pu blic boole an isDicom Enabled()  {
  309                    retu rn this.di comEnabled ;
  310           }
  311           pu blic void  setDicomEn abled(bool ean dicomE nabled)
  312           {
  313                    this .dicomEnab led = dico mEnabled;
  314           }
  315           
  316           /* *
  317            *  Get Fake  hostname v alue from  applicatio n.properti es file.
  318            *
  319            *  @return r epresents  a hostname  to a diff erent mach ine that i s known by  the VistA  HIS.  Thi
  320            *  is create d for a te sting envi ronment on ly.
  321            * /
  322       public  String ge tFakeHostN ame(){
  323           re turn this. fakeHostNa me;
  324       }
  325           pu blic void  setFakeHos tName(Stri ng fakeHos tName)
  326           {
  327                    this .fakeHostN ame = fake HostName;
  328           }
  329           
  330           pu blic Strin g getHostN ame()
  331           {
  332                    if ( hostName = = null)
  333                    {
  334                             if (ge tFakeHostN ame() != n ull && !ge tFakeHostN ame().equa ls(""))
  335                             {
  336                                      hostName  = getFake HostName() ;
  337                             }
  338                             else
  339                             {
  340                                      try
  341                                      {
  342                                               InetAddres s localMac hine = Ine tAddress.g etLocalHos t();  
  343                                               hostName =  localMach ine.getHos tName();
  344                                      }
  345                                      catch(ja va.net.Unk nownHostEx ception uh e)
  346                                      {
  347                                               logger.err or("Couldn 't retriev e host nam e: ", uhe) ;
  348                                      }
  349                             }
  350                    }
  351                    
  352                    retu rn (hostNa me + "").t rim();
  353           }
  354       
  355           /* *
  356            *  Get the M oveQueueCa pacity val ue from ap plication. properties  file.  Th e C-Move p rocess
  357            *  uses a Pr oducer/Con sumer patt ern.  Ther e is a Que ue between  the produ cer and co nsumer.
  358            *  Changing  this value  changes t he size of  the Queue .  This op tional val ue can aff ect the 
  359            *  performan ce the app lication.
  360            *
  361            *  @return r epresents  a configur ed value f or the Mov eQueueCapa city.  If  this value  is not se t, 
  362            *  there is  a default  value in t he code.
  363            *  
  364            * /
  365           pu blic int g etMoveQueu eCapacity( ) {
  366                    retu rn this.mo veQueueCap acity;
  367           }
  368           pu blic void  setMoveQue ueCapacity (int moveQ ueueCapaci ty)
  369           {
  370                    this .moveQueue Capacity =  moveQueue Capacity;
  371           }
  372  
  373           /* *
  374            *  @return t he removeE lements
  375            * /
  376           pu blic Array List<Strin g> getRemo vedElement s() {
  377                    retu rn this.re movedEleme nts;
  378           }        
  379           pu blic void  setRemoved Elements(A rrayList<S tring> rem oveElement s)
  380           {
  381                    this .removedEl ements = r emoveEleme nts;
  382           }
  383  
  384           /* *
  385            *  @return t he added q uery eleme nts
  386            * /
  387           pu blic Array List<Strin g> getAdde dQueryElem ents(){
  388                    retu rn this.ad dedQueryEl ements;
  389           }
  390           pu blic void  setAddedQu eryElement s(ArrayLis t<String>  addQueryEl ements)
  391           {
  392                    this .addedQuer yElements  = addQuery Elements;
  393           }
  394           
  395           pu blic Dicom ServerConf iguration( )
  396           {
  397                    aeTi tleToVista Credential sMap = new  HashMap<S tring, Vis taCredenti als>();
  398           }
  399  
  400           pu blic Strin g getLegac yGatewayAd dress()
  401           {
  402                    retu rn legacyG atewayAddr ess;
  403           }
  404  
  405           pu blic void  setLegacyG atewayAddr ess(String  legacyGat ewayAddres s)
  406           {
  407                    this .legacyGat ewayAddres s = legacy GatewayAdd ress;
  408           }
  409  
  410           pu blic int g etLegacyGa tewayPort( )
  411           {
  412                    retu rn legacyG atewayPort ;
  413           }
  414  
  415           pu blic void  setLegacyG atewayPort (int legac yGatewayPo rt)
  416           {
  417                    this .legacyGat ewayPort =  legacyGat ewayPort;
  418           }
  419  
  420           pu blic List< Instrument Config> ge tInstrumen ts()
  421           {
  422                    retu rn instrum ents;
  423           }
  424  
  425           pu blic void  setInstrum ents(List< Instrument Config> in struments)
  426           {
  427                    this .instrumen ts = instr uments;
  428                    
  429                    // C lear any p revious da ta, then b uild our l ookup of i nstrument  nicknames  by port he re
  430                    inst rumentByPo rt.clear() ;
  431                    
  432                    for  (Instrumen tConfig in strument :  instrumen ts)
  433                    {
  434                             instru mentByPort .put(Strin g.valueOf( instrument .getPort() ), instrum ent);
  435                    }
  436           }
  437           
  438           pu blic Instr umentConfi g getInstr umentByPor t(int port )
  439           {
  440                    retu rn instrum entByPort. get(String .valueOf(p ort));
  441           }
  442  
  443           pu blic List< ModalityCo nfig> getM odalities( )
  444           {
  445                    retu rn modalit ies;
  446           }
  447  
  448           pu blic void  setModalit ies(List<M odalityCon fig> modal ities)
  449           {
  450                    this .modalitie s = modali ties;
  451           }
  452           pu blic DGWEm ailInfo ge tDgwEmailI nfo()
  453           {
  454                    retu rn dgwEmai lInfo;
  455           }
  456  
  457           pu blic void  setDgwEmai lInfo(DGWE mailInfo d gwEI)
  458           {
  459                    this .dgwEmailI nfo = dgwE I;
  460           }
  461           
  462           pu blic boole an isCurre ntStorageS OPClass(St ring sopCl assUid) th rows Dicom Exception
  463           {
  464                    retu rn oldSOPC lasses.con tainsKey(s opClassUid );
  465           }
  466  
  467           pu blic boole an isNewSt orageSOPCl ass(String  sopClassU id) throws  DicomExce ption
  468           {
  469                    retu rn newSOPC lasses.con tainsKey(s opClassUid );
  470           }
  471  
  472           pu blic boole an isUnkno wnStorageS OPClass(St ring sopCl assUid) th rows Dicom Exception
  473           {
  474                    retu rn unknown SOPClasses .containsK ey(sopClas sUid);
  475           }
  476  
  477           pu blic void  setUidActi ons(List<U IDActionCo nfig> uidA ctions)
  478           {
  479                    this .uidAction s = uidAct ions;
  480                    
  481                    // C lear any p revious da ta, then b uild our l ookup of o ld and new  SOP class es here
  482                    oldS OPClasses. clear();
  483                    newS OPClasses. clear();
  484                    unkn ownSOPClas ses.clear( );
  485                    
  486                    for  (UIDAction Config act ion : uidA ctions)
  487                    {
  488                             String  actionUid  = action. getUid();
  489                             String  actionCod e = action .getAction Code();
  490                             
  491                             if ("1 ".equals(a ctionCode) )
  492                             {
  493                                      this.old SOPClasses .put(actio nUid, acti on);
  494                             }
  495                             else i f ("2".equ als(action Code))
  496                             {
  497                                      this.new SOPClasses .put(actio nUid, acti on);
  498                             }
  499                             else / / "3"
  500                             {
  501                                      this.unk nownSOPCla sses.put(a ctionUid,  action);
  502                             }
  503                             String  aComment  = action.g etActionCo mment();
  504                             if (aC omment==nu ll || (aCo mment.leng th()==0))  {
  505                                      action.s etActionCo mment("Unk nown");
  506                                      action.s etIconFile name("mags ensitive.J PG"); // n eutral for  all -- ju st in lack  of real g eneric ico n!
  507                             } else  {
  508                                      String[]  acomfield s = String Util.split (aComment,  StringUti l.STICK);
  509                                      action.s etActionCo mment(acom fields[0]) ;
  510                                      if (acom fields.len gth>1) {
  511                                               action.set IconFilena me(acomfie lds[1]);
  512                                      } else
  513                                               action.set IconFilena me("create Icon");
  514                             }
  515                    }
  516           }
  517           pu blic UIDAc tionConfig  getSopUID ActionConf iguration  (String so pClassUID)  {
  518  
  519                    for  (UIDAction Config act ion : uidA ctions)
  520                    {
  521                             if (so pClassUID. equals(act ion.getUid ())) {
  522                                      return a ction;
  523                             }
  524                    }
  525                    retu rn null;
  526           }
  527  
  528           pu blic Strin g getDicom CorrectFol der() {
  529                    retu rn dicomCo rrectFolde r;
  530           }
  531  
  532           pu blic void  setDicomCo rrectFolde r(String d icomCorrec tFolder) {
  533                    this .dicomCorr ectFolder  = dicomCor rectFolder ;
  534           }
  535  
  536           pu blic Strin g getDicom DebugFolde r() {
  537                    retu rn dicomDe bugFolder;
  538           }
  539  
  540           pu blic void  setDicomDe bugFolder( String dic omDebugFol der) {
  541                    this .dicomDebu gFolder =  dicomDebug Folder;
  542           }
  543  
  544           pu blic boole an isDicom DebugDumpE nabled() {
  545                    retu rn dicomDe bugDumpEna bled;
  546           }
  547  
  548           pu blic void  setDicomDe bugDumpEna bled(boole an dicomDe bugDumpEna bled) {
  549                    this .dicomDebu gDumpEnabl ed = dicom DebugDumpE nabled;
  550           }
  551  
  552           pu blic boole an isArchi veEnabled( ) {
  553                    retu rn archive Enabled;
  554           }
  555  
  556           pu blic void  setArchive Enabled(bo olean arch iveEnabled ) {
  557                    this .archiveEn abled = ar chiveEnabl ed;
  558           }
  559  
  560           pu blic boole an isIconP rocessingE nabled() {
  561                    retu rn iconPro cessingEna bled;
  562           }
  563  
  564           pu blic void  setIconPro cessingEna bled(boole an iconPro cessingEna bled) {
  565                    this .iconProce ssingEnabl ed = iconP rocessingE nabled;
  566           }
  567  
  568           pu blic Strin g getCanne dIconFolde r() {
  569                    retu rn cannedI conFolder;
  570           }
  571  
  572           pu blic void  setCannedI conFolder( String can nedIconFol der) {
  573                    this .cannedIco nFolder =  cannedIcon Folder;
  574           }
  575  
  576           pu blic Routi ngToken ge tRoutingTo ken() {
  577                    Rout ingToken r outingToke n = null;
  578                    try 
  579                    {
  580                             routin gToken = R outingToke nImpl.crea teVARadiol ogySite(Di comServerC onfigurati on.getConf iguration( ).getSiteI d());
  581                    } 
  582                    catc h (Routing TokenForma tException  e) 
  583                    {
  584                             // TOD O Auto-gen erated cat ch block
  585                             e.prin tStackTrac e();
  586                    }
  587                    retu rn routing Token;
  588           }
  589  
  590           pu blic Integ er isDicom DebugDumpM inutes() {
  591                    retu rn dicomDe bugDumpMin utes;
  592           }
  593  
  594           pu blic void  setDicomDe bugDumpMin utes(Integ er dicomDe bugDumpMin utes) {
  595                    this .dicomDebu gDumpMinut es = dicom DebugDumpM inutes;
  596           }
  597  
  598           pu blic Long  getDicomDe bugDumpSta rtMillies( ) {
  599                    retu rn dicomDe bugDumpSta rtMillies;
  600           }
  601  
  602           pu blic void  setDicomDe bugDumpSta rtMillies( Long dicom DebugDumpS tartMillie s) {
  603                    this .dicomDebu gDumpStart Millies =  dicomDebug DumpStartM illies;
  604           }
  605  
  606           pu blic Integ er getDico mDebugDump Minutes()  {
  607                    retu rn dicomDe bugDumpMin utes;
  608           }
  609  
  610           pu blic boole an isIgnor eSopSwitch () {
  611                    retu rn ignoreS opSwitch;
  612           }
  613           pu blic void  setIgnoreS opSwitch(B oolean iSS witch) {
  614                    this .ignoreSop Switch=iSS witch;
  615           }
  616           
  617           /* *
  618            *  @return t he loadFal seStats
  619            * /
  620           pu blic boole an isLoadF alseStats( ) {
  621                    retu rn loadFal seStats;
  622           }
  623  
  624           /* *
  625            *  @param lo adFalseSta ts the loa dFalseStat s to set
  626            * /
  627           pu blic void  setLoadFal seStats(bo olean load FalseStats ) {
  628                    this .loadFalse Stats = lo adFalseSta ts;
  629           }
  630  
  631           /* *
  632            *  @return t he formatS SNwithDash es
  633            * /
  634           pu blic boole an isForma tPatientID withDashes () {
  635                    retu rn formatP atientIDwi thDashes;
  636           }
  637  
  638           /* *
  639            *  @param fo rmatSSNwit hDashes th e formatSS NwithDashe s to set
  640            * /
  641           pu blic void  setFormatP atientIDwi thDashes(b oolean for matPatient IDwithDash es) {
  642                    this .formatPat ientIDwith Dashes = f ormatPatie ntIDwithDa shes;
  643           }
  644           
  645           /* *
  646            *  @return t he impleme ntationCla ssUID
  647            * /
  648           pu blic Strin g getImple mentationC lassUID()  {
  649                    retu rn impleme ntationCla ssUID;
  650           }
  651  
  652           /* *
  653            *  @param im plementati onClassUID  the imple mentationC lassUID to  set
  654            * /
  655           pu blic void  setImpleme ntationCla ssUID(Stri ng impleme ntationCla ssUID) {
  656                    this .implement ationClass UID = impl ementation ClassUID;
  657           }
  658  
  659           /* *
  660            *  @return t he impleme ntationVer sionName
  661            * /
  662           pu blic Strin g getImple mentationV ersionName () {
  663                    retu rn impleme ntationVer sionName;
  664           }
  665  
  666           /* *
  667            *  @param im plementati onVersionN ame the im plementati onVersionN ame to set
  668            * /
  669           pu blic void  setImpleme ntationVer sionName(S tring impl ementation VersionNam e) {
  670                    this .implement ationVersi onName = i mplementat ionVersion Name;
  671           }
  672  
  673           /* *
  674            *  @return t he pduTime out
  675            * /
  676           pu blic int g etPduTimeo ut() {
  677                    retu rn pduTime out;
  678           }
  679  
  680           /* *
  681            *  @param pd uTimeout t he pduTime out to set
  682            * /
  683           pu blic void  setPduTime out(int pd uTimeout)  {
  684                    this .pduTimeou t = pduTim eout;
  685           }
  686  
  687           /* *
  688            *  @return t he applica tionName
  689            * /
  690           pu blic Strin g getAppli cationName () {
  691                    retu rn applica tionName;
  692           }
  693  
  694           /* *
  695            *  @param ap plicationN ame the ap plicationN ame to set
  696            * /
  697           pu blic void  setApplica tionName(S tring appl icationNam e) {
  698                    this .applicati onName = a pplication Name;
  699           }
  700  
  701           /* *
  702            *  @return t he authent icateAETit les
  703            * /
  704           pu blic boole an isAuthe nticateAET itles() {
  705                    retu rn authent icateAETit les;
  706           }
  707  
  708           /* *
  709            *  @param au thenticate AETitles t he authent icateAETit les to set
  710            * /
  711           pu blic void  setAuthent icateAETit les(boolea n authenti cateAETitl es) {
  712                    this .authentic ateAETitle s = authen ticateAETi tles;
  713           }
  714  
  715           /* *
  716            *  @return t he dicomLi stenerPort
  717            * /
  718           pu blic int g etDicomLis tenerPort( ) {
  719                    retu rn dicomLi stenerPort ;
  720           }
  721  
  722           /* *
  723            *  @param di comListene rPort the  dicomListe nerPort to  set
  724            * /
  725           pu blic void  setDicomLi stenerPort (int dicom ListenerPo rt) {
  726                    this .dicomList enerPort =  dicomList enerPort;
  727           }
  728  
  729           /* *
  730            *  @return t he queryLi mit
  731            * /
  732           pu blic Strin g getQuery Limit() {
  733                    retu rn queryLi mit;
  734           }
  735  
  736           /* *
  737            *  @param qu eryLimit t he queryLi mit to set
  738            * /
  739           pu blic void  setQueryLi mit(String  queryLimi t) {
  740                    this .queryLimi t = queryL imit;
  741           }
  742  
  743           /* *
  744            *  @return t he moveSub Operations Enabled
  745            * /
  746           pu blic boole an isMoveS ubOperatio nsEnabled( ) {
  747                    retu rn moveSub Operations Enabled;
  748           }
  749  
  750           /* *
  751            *  @param mo veSubOpera tionsEnabl ed the mov eSubOperat ionsEnable d to set
  752            * /
  753           pu blic void  setMoveSub Operations Enabled(bo olean move SubOperati onsEnabled ) {
  754                    this .moveSubOp erationsEn abled = mo veSubOpera tionsEnabl ed;
  755           }
  756  
  757           /* *
  758            *  
  759            *  @return r epresents  the identi fier of th e HDIG.  T he identif ier is bas ed on the  hostname o nly and co ntains
  760            *  a _hdig e xtension.   The hostn ame is fil tered from  the FQDN  if necessa ry.  This  is used wh en it is n ecessary 
  761            *  to avoid  confusion  with the L egacy DICO M Gateway  that is ru nning on t he same ma chine.  
  762            *  An exampl e would be  vhaiswimg test_hdig.
  763            * /
  764           pu blic Strin g getHDIGS pecificHos tIdentifie r(){
  765                    Stri ng[] fqdn  = StringUt il.split(t his.hostNa me, String Util.PERIO D);
  766                    Stri ng hdigHos t = fqdn[0 ];
  767                    if(h digHost !=  null){
  768                             hdigHo st = hdigH ost.trim() ;
  769                             hdigHo st = hdigH ost.concat ("_hdig");
  770                    }
  771                    retu rn hdigHos t;
  772           }
  773  
  774  
  775           pu blic Strin g getAcces sCodeStrin g()
  776           {
  777                    Stri ng accessC odeString  = "";
  778                    if ( getAccessC ode() != n ull)
  779                    {
  780                             access CodeString  = getAcce ssCode().t oString()  + "";
  781                    }
  782                    
  783                    retu rn accessC odeString;
  784           }
  785  
  786           pu blic Strin g getVerif yCodeStrin g()
  787           {
  788                    Stri ng verifyC odeString  = "";
  789                    if ( getVerifyC ode() != n ull)
  790                    {
  791                             verify CodeString  = getVeri fyCode().t oString()  + "";
  792                    }
  793                    
  794                    retu rn verifyC odeString;
  795           }
  796  
  797           pu blic void  setImporte rPurgeDela ys(Importe rPurgeDela ys importe rPurgeDela ys) {
  798                    this .importerP urgeDelays  = importe rPurgeDela ys;
  799           }
  800  
  801           pu blic Impor terPurgeDe lays getIm porterPurg eDelays()  {
  802                    retu rn importe rPurgeDela ys;
  803           }
  804  
  805           pu blic void  setHostNam e(String h ostName) {
  806                    this .hostName  = hostName ;
  807           }
  808  
  809           
  810   }