208. EPMO Open Source Coordination Office Redaction File Detail Report

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

208.1 Files compared

# Location File Last Modified
1 IV-eHMP_CIF.zip\IMAG_Source\VISA\Java\ImageConversion\main\src\java\gov\va\med\imaging\conversion\configuration ImageConversionConfiguration.java Mon Dec 4 21:35:16 2017 UTC
2 IV-eHMP_CIF.zip\IMAG_Source\VISA\Java\ImageConversion\main\src\java\gov\va\med\imaging\conversion\configuration ImageConversionConfiguration.java Mon Dec 4 22:01:05 2017 UTC

208.2 Comparison summary

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

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

208.4 Active regular expressions

No regular expressions were active.

208.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: Apr  17, 2008
  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.con version.co nfiguratio n;
  27  
  28   import jav a.beans.XM LDecoder;
  29   import jav a.beans.XM LEncoder;
  30   import jav a.io.Buffe redInputSt ream;
  31   import jav a.io.Buffe redOutputS tream;
  32   import jav a.io.File;
  33   import jav a.io.FileI nputStream ;
  34   import jav a.io.FileN otFoundExc eption;
  35   import jav a.io.FileO utputStrea m;
  36   import jav a.util.Arr ayList;
  37   import jav a.util.Lis t;
  38   import jav a.util.con current.lo cks.Lock;
  39   import jav a.util.con current.lo cks.Reentr antReadWri teLock;
  40  
  41   import org .apache.lo gging.log4 j.LogManag er;
  42   import org .apache.lo gging.log4 j.Logger;
  43  
  44   import gov .va.med.im aging.core .interface s.IImageCo nversionCo nfiguratio n;
  45   import gov .va.med.im aging.core .interface s.exceptio ns.Applica tionConfig urationExc eption;
  46   import gov .va.med.im aging.exch ange.busin ess.ImageF ormatAllow ableConver sionList;
  47   import gov .va.med.im aging.exch ange.enums .ImageForm at;
  48  
  49   /**
  50    * Image c onversion  configurat ion. Conta ins option s for usin g in Image  conversio n.
  51    * 
  52    * @author         
WERFEJ
  53    *
  54    */
  55   public cla ss ImageCo nversionCo nfiguratio
  56   implements  IImageCon versionCon figuration  
  57   {
  58           pr ivate stat ic final S tring IMAG E_CONVERSI ON_CONFIG_ FILENAME =  "ImageCon versionCon fig.xml";
  59           pr ivate fina l static L ogger logg er = LogMa nager.getL ogger(Imag eConversio nConfigura tion.class );
  60  
  61           pr otected bo olean down SamplingEn abled = fa lse;
  62           pr otected bo olean noLo sslessComp ression =  false;
  63           pr otected bo olean deco mpressionE nabled = f alse;
  64           
  65           pr otected Li st<ImageFo rmatAllowa bleConvers ionList> f ormatConfi gurations  = new Arra yList<Imag eFormatAll owableConv ersionList >();
  66           
  67           pr ivate Stri ng vixConf igurationD irectory =  null;
  68           pr ivate Stri ng imageCo nversionCo nfiguratio nFilespec  = null;
  69           
  70           pr ivate fina l Reentran tReadWrite Lock rwl =  new Reent rantReadWr iteLock();
  71           pr otected fi nal Lock r eadLock =  rwl.readLo ck();
  72       protec ted final  Lock write Lock = rwl .writeLock ();   
  73           
  74           pu blic Image Conversion Configurat ion()
  75           {
  76                    supe r();
  77           }
  78           
  79           pu blic void  init() 
  80           th rows Appli cationConf igurationE xception
  81           {
  82                    getI mageConver sionConfig urationFil espec();
  83           }
  84           
  85           @O verride
  86           pu blic boole an loadIma geConversi onConfigur ationFromF ile() 
  87           {
  88                    bool ean succes s = false;
  89                    try
  90                    {
  91                             succes s = this.l oadAppConf igurationF romFile(th is.getImag eConversio nConfigura tionFilesp ec()); //  uses read  lock
  92                    }
  93                    catc h (Applica tionConfig urationExc eption ex)  
  94                    {
  95                             logger .error("Er ror in Ima geConversi onConfigur ation.load ImageConve rsionConfi gurationFi le", ex);
  96                    }
  97                    retu rn success ;
  98           }        
  99  
  100           /* *
  101            *  @param fi leSpec - t he file th at contain s the appl ication co nfiguratio n
  102            *  @return t rue if the  configura tion was s ucessfully  loaded fr om the fil e specifie d by appCo nfiguratio nFilespec
  103            * /
  104           pr ivate bool ean loadAp pConfigura tionFromFi le(String  fileSpec) 
  105           {
  106                    logg er.info("L oading ima ge convers ion config uration fr om '" + fi leSpec + " '.");
  107                    
  108                    bool ean succes s = false;
  109                    XMLD ecoder xml Decoder =  null;
  110                    Imag eConversio nConfigura tion image Conversion Configurat ion = null ;
  111  
  112                    if ( fileSpec ! = null)
  113                    {
  114                             File c onfigFile  = new File (fileSpec) ;
  115                             if (co nfigFile.e xists())
  116                             {
  117                                      try
  118                                      {
  119                                               xmlDecoder  = new XML Decoder(ne w Buffered InputStrea m(new File InputStrea m(fileSpec ))); // th rows FileN otFoundExc eption
  120                                               imageConve rsionConfi guration =  (ImageCon versionCon figuration ) xmlDecod er.readObj ect();
  121                                               if (imageC onversionC onfigurati on != null )
  122                                               {
  123                                                       th is.assignS tate(image Conversion Configurat ion); // t his method  obtains a  write loc k
  124                                                       lo gger.info( "ImageConv ersionConf iguration:  loaded Im ageConvers ion config uration fr om: " + fi leSpec);
  125                                                       su ccess = tr ue;
  126                                               }
  127                                      }
  128                                      catch (F ileNotFoun dException  ex)
  129                                      {
  130                                               logger.err or(ex.getM essage());
  131                                      }
  132                                      catch (A rrayIndexO utOfBounds Exception  ex)
  133                                      {
  134                                               logger.err or("ImageC onversionC onfigurati on.loadApp Configurat ionFromFil e: ArrayIn dexOutOfBo undsExcept ion : " +  ex.getMess age());
  135                                      }
  136                                      finally
  137                                      {
  138                                               if (xmlDec oder != nu ll)
  139                                               {
  140                                                       xm lDecoder.c lose();
  141                                               }
  142                                      }
  143                             }
  144                    }
  145                    logg er.info("I mage conve rsion conf iguration  from file  '" + fileS pec + "' l oaded.");
  146                    retu rn success ;
  147           }
  148           
  149           /* *
  150            *  @param im ageConvers ionConfigu ration - t he AppConf iguration  object tha t contains  the state  to use
  151            *  This publ ic method  takes the  state of t he passed  appConfigu ration par am and ove rlays it o nto the cu rrent inst ance
  152            * /
  153           pr ivate void  assignSta te(ImageCo nversionCo nfiguratio n imageCon versionCon figuration )
  154           {
  155                    if ( imageConve rsionConfi guration ! = null)
  156                    {
  157                             this.w riteLock.l ock();
  158                             imageC onversionC onfigurati on.readLoc k.lock();
  159                             try
  160                             {
  161                                      this.dow nSamplingE nabled = i mageConver sionConfig uration.do wnSampling Enabled;
  162                                      this.noL osslessCom pression =  imageConv ersionConf iguration. noLossless Compressio n;
  163                                      this.dec ompression Enabled =  imageConve rsionConfi guration.d ecompressi onEnabled;
  164                                      
  165                                      this.for matConfigu rations.ad dAll(image Conversion Configurat ion.format Configurat ions);
  166                             }
  167                             finall y
  168                             {
  169                                      this.wri teLock.unl ock();
  170                                      imageCon versionCon figuration .readLock. unlock();
  171                             }
  172                    }
  173           }
  174           
  175           pr ivate Stri ng getImag eConversio nConfigura tionFilesp ec() 
  176           th rows Appli cationConf igurationE xception
  177           {
  178                    Stri ng fileSpe c = null;
  179                    this .readLock. lock();
  180                    try  {fileSpec  = this.ima geConversi onConfigur ationFiles pec;}
  181                    fina lly {this. readLock.u nlock();}
  182  
  183                    if ( fileSpec = = null)
  184                    {
  185                             fileSp ec = this. getVixConf igurationD irectory() ;
  186                             // add  the trail ing file s eparator c haracter i f necessar y
  187                             if (!f ileSpec.en dsWith("\\ ") || !fil eSpec.ends With("/"))
  188                             {
  189                                      fileSpec  += "/";
  190                             }
  191                             fileSp ec += IMAG E_CONVERSI ON_CONFIG_ FILENAME;
  192  
  193                             this.s etAppConfi gurationFi lespec(fil eSpec);
  194                    }
  195                    
  196                    retu rn fileSpe c;
  197           }
  198           
  199           pr ivate void  setAppCon figuration Filespec(S tring file Spec) {
  200                    this .writeLock .lock();
  201                    try  {this.imag eConversio nConfigura tionFilesp ec = fileS pec;}
  202                    fina lly {this. writeLock. unlock();}
  203           }
  204           
  205           pr ivate Stri ng getVixC onfigurati onDirector y() 
  206           th rows Appli cationConf igurationE xception
  207           {
  208                    Stri ng configD ir = null;
  209                    this .readLock. lock();
  210                    try  {configDir  = this.vi xConfigura tionDirect ory;}
  211                    fina lly {this. readLock.u nlock();}
  212                    
  213                    if ( configDir  == null)
  214                    {
  215                             config Dir = Syst em.getenv( "vixconfig ");
  216                             if (co nfigDir ==  null)
  217                             {
  218                                      throw ne w Applicat ionConfigu rationExce ption("The  vixconfig  has not b een set.") ;
  219                             }
  220  
  221                             this.s etVixConfi gurationDi rectory(co nfigDir);
  222                    }
  223                    retu rn configD ir;
  224           }
  225           
  226           pr ivate void  setVixCon figuration Directory( String vix Configurat ionDirecto ry) 
  227           {
  228                    this .writeLock .lock();
  229                    try  {this.vixC onfigurati onDirector y = vixCon figuration Directory; }
  230                    fina lly {this. writeLock. unlock();}
  231           }
  232           
  233           
  234           /*  (non-Java doc)
  235            *  @see gov. va.med.ima ging.core. interfaces .IImageCon versionCon figuration #isDecompr essionEnab led()
  236            * /
  237           @O verride
  238           pu blic boole an isDecom pressionEn abled() 
  239           {
  240                    this .readLock. lock();
  241                    try  {return th is.decompr essionEnab led;}
  242                    fina lly {this. readLock.u nlock();}
  243           }
  244           
  245           /*  (non-Java doc)
  246            *  @see gov. va.med.ima ging.core. interfaces .IImageCon versionCon figuration #isDownSam plingEnabl ed()
  247            * /
  248           @O verride
  249           pu blic boole an isDownS amplingEna bled() 
  250           {
  251                    this .readLock. lock();
  252                    try  {return th is.downSam plingEnabl ed;}
  253                    fina lly {this. readLock.u nlock();}
  254           }
  255  
  256           /*  (non-Java doc)
  257            *  @see gov. va.med.ima ging.core. interfaces .IImageCon versionCon figuration #isNoLossl essCompres sion()
  258            * /
  259           @O verride
  260           pu blic boole an isNoLos slessCompr ession() 
  261           {
  262                    this .readLock. lock();
  263                    try  {return th is.noLossl essCompres sion;}
  264                    fina lly {this. readLock.u nlock();}
  265           }
  266  
  267           /*  (non-Java doc)
  268            *  @see gov. va.med.ima ging.core. interfaces .IImageCon versionCon figuration #setDecomp ressionEna bled(boole an)
  269            * /
  270           @O verride
  271           pu blic void  setDecompr essionEnab led(boolea n enabled)  
  272           {
  273                    this .writeLock .lock();
  274                    try  {this.deco mpressionE nabled = e nabled;}
  275                    fina lly {this. writeLock. unlock();}
  276           }
  277  
  278           /*  (non-Java doc)
  279            *  @see gov. va.med.ima ging.core. interfaces .IImageCon versionCon figuration #setDownSa mplingEnab led(boolea n)
  280            * /
  281           @O verride
  282           pu blic void  setDownSam plingEnabl ed(boolean  enabled) 
  283           {
  284                    this .writeLock .lock();
  285                    try  {this.down SamplingEn abled = en abled;}
  286                    fina lly {this. writeLock. unlock();}
  287           }        
  288  
  289           @O verride
  290           pu blic List< ImageForma tAllowable Conversion List> getF ormatConfi gurations(
  291           {
  292                    this .readLock. lock();
  293                    try  {return th is.formatC onfigurati ons;}
  294                    fina lly {this. readLock.u nlock();}                 
  295           }
  296  
  297           /*  (non-Java doc)
  298            *  @see gov. va.med.ima ging.core. interfaces .IImageCon versionCon figuration #setNoLoss lessCompre ssion(bool ean)
  299            * /
  300           @O verride
  301           pu blic void  setNoLossl essCompres sion(boole an enabled
  302           {
  303                    this .writeLock .lock();
  304                    try  {this.noLo sslessComp ression =  enabled;}
  305                    fina lly {this. writeLock. unlock();}
  306           }
  307           
  308           pu blic void  setFormatC onfigurati ons(
  309                             List<I mageFormat AllowableC onversionL ist> forma tConfigura tions) 
  310           {
  311                    this .writeLock .lock();           
  312                    try  {this.form atConfigur ations = f ormatConfi gurations; }
  313                    fina lly {this. writeLock. unlock();}
  314           }
  315           
  316           
  317  
  318           @O verride
  319           pu blic Image FormatAllo wableConve rsionList  getFormatC onfigurati on(
  320                             ImageF ormat form at) 
  321           {        
  322                    
  323                    this .readLock. lock();
  324                    if(f ormat == n ull)
  325                    {
  326                             logger .warn("Sea rching for  conversio n format f or null im age format , returnin g null con version li st");
  327                             return  null;
  328                    }
  329                    logg er.info("S earching f or convers ion format  for store d image fo rmat [" +  format + " ]");
  330                    try 
  331                    {                         
  332                             for(Im ageFormatA llowableCo nversionLi st list :  formatConf igurations )
  333                             {
  334                                      if(list. getImageFo rmat() ==  format)
  335                                               return lis t;
  336                             }
  337                             return  null;
  338                    }
  339                    fina lly {this. readLock.u nlock();}
  340           }
  341  
  342           @O verride
  343           pu blic boole an saveIma geConversi onConfigur ationToFil e() {
  344                    bool ean succes s = false;
  345                    XMLE ncoder xml Encoder =  null;
  346  
  347                    this .readLock. lock();
  348                    try
  349                    {
  350                             xmlEnc oder = new  XMLEncode r(new Buff eredOutput Stream(new  FileOutpu tStream(th is.getImag eConversio nConfigura tionFilesp ec())));
  351                             xmlEnc oder.write Object(thi s);
  352                             logger .info("Ima geConversi onConfigur ation: con figuration  saved to:  " + this. getImageCo nversionCo nfiguratio nFilespec( ));
  353                             succes s = true;
  354                    }
  355                    catc h (Applica tionConfig urationExc eption ex)
  356                    {
  357                             logger .error(ex. getMessage ());
  358                    }
  359                    catc h (FileNot FoundExcep tion ex)
  360                    {
  361                             logger .error("Im ageConvers ionConfigu ration.sav eAppConfig urationToF ile: " + e x.getMessa ge());
  362                    }
  363                    fina lly
  364                    {
  365                             this.r eadLock.un lock();
  366                             if (xm lEncoder ! = null)
  367                             {
  368                                      xmlEncod er.close() ;
  369                             }
  370                    }
  371                    retu rn success ;
  372           }
  373           
  374           pu blic stati c void mai n(String [ ] args)
  375           {
  376                    Imag eConversio nConfigura tion confi g = new Im ageConvers ionConfigu ration();
  377                    try
  378                    {
  379                             config .init();
  380                    }
  381                    catc h(Applicat ionConfigu rationExce ption acX)
  382                    {
  383                             acX.pr intStackTr ace();
  384                    }
  385                    setB asicConfig uration(co nfig);
  386                    conf ig.saveIma geConversi onConfigur ationToFil e();
  387           }
  388           
  389           pr ivate stat ic void se tBasicConf iguration( ImageConve rsionConfi guration c onfig)
  390           {
  391                    conf ig.setDeco mpressionE nabled(tru e);
  392                    conf ig.setDown SamplingEn abled(fals e);
  393                    conf ig.setNoLo sslessComp ression(fa lse);
  394                    
  395                    // C reate the  default co nversion o ptions all owed for e ach format
  396                    // T he order o f items in  these lis ts is NOT  relevant
  397                    
  398                    // J MW 8/18/08  - can't a ctually co mpress a T GA into a  compressed  TGA
  399                    Imag eFormatAll owableConv ersionList  tgaList =  
  400                             new Im ageFormatA llowableCo nversionLi st(ImageFo rmat.TGA,  false);
  401                    tgaL ist.add(Im ageFormat. DICOM);
  402                    tgaL ist.add(Im ageFormat. DICOMJPEG) ;
  403                    tgaL ist.add(Im ageFormat. DICOMJPEG2 000);
  404                    tgaL ist.add(Im ageFormat. J2K);
  405                    tgaL ist.add(Im ageFormat. TGA);
  406                    tgaL ist.add(Im ageFormat. JPEG);           
  407                    conf ig.formatC onfigurati ons.add(tg aList);
  408                    
  409                    Imag eFormatAll owableConv ersionList  dicomList  = 
  410                             new Im ageFormatA llowableCo nversionLi st(ImageFo rmat.DICOM , true);
  411                    dico mList.add( ImageForma t.DICOM);
  412                    dico mList.add( ImageForma t.DICOMJPE G);
  413                    dico mList.add( ImageForma t.DICOMJPE G2000);
  414                    dico mList.add( ImageForma t.TGA);
  415                    dico mList.add( ImageForma t.J2K);
  416                    dico mList.add( ImageForma t.JPEG);                  
  417                    conf ig.formatC onfigurati ons.add(di comList);
  418                    
  419                    Imag eFormatAll owableConv ersionList  dicomJpgL ist = 
  420                             new Im ageFormatA llowableCo nversionLi st(ImageFo rmat.DICOM JPEG, true );
  421                    dico mJpgList.a dd(ImageFo rmat.DICOM );
  422                    dico mJpgList.a dd(ImageFo rmat.DICOM JPEG);
  423                    dico mJpgList.a dd(ImageFo rmat.DICOM JPEG2000);
  424                    dico mJpgList.a dd(ImageFo rmat.TGA);
  425                    dico mJpgList.a dd(ImageFo rmat.J2K);
  426                    dico mJpgList.a dd(ImageFo rmat.JPEG) ;              
  427                    conf ig.formatC onfigurati ons.add(di comJpgList );
  428                    
  429                    Imag eFormatAll owableConv ersionList  dicomJ2kL ist = 
  430                             new Im ageFormatA llowableCo nversionLi st(ImageFo rmat.DICOM JPEG2000,  true);
  431                    dico mJ2kList.a dd(ImageFo rmat.DICOM );
  432                    dico mJ2kList.a dd(ImageFo rmat.DICOM JPEG);
  433                    dico mJ2kList.a dd(ImageFo rmat.DICOM JPEG2000);
  434                    dico mJ2kList.a dd(ImageFo rmat.TGA);
  435                    dico mJ2kList.a dd(ImageFo rmat.J2K);
  436                    dico mJ2kList.a dd(ImageFo rmat.JPEG) ;              
  437                    conf ig.formatC onfigurati ons.add(di comJ2kList );
  438                    
  439                    Imag eFormatAll owableConv ersionList  j2kList =  
  440                             new Im ageFormatA llowableCo nversionLi st(ImageFo rmat.J2K,  true);
  441                    j2kL ist.add(Im ageFormat. DICOM);
  442                    j2kL ist.add(Im ageFormat. DICOMJPEG) ;
  443                    j2kL ist.add(Im ageFormat. DICOMJPEG2 000);
  444                    j2kL ist.add(Im ageFormat. TGA);
  445                    j2kL ist.add(Im ageFormat. J2K);
  446                    j2kL ist.add(Im ageFormat. JPEG);           
  447                    conf ig.formatC onfigurati ons.add(j2 kList);
  448                    
  449                    Imag eFormatAll owableConv ersionList  dicomPdfL ist = 
  450                             new Im ageFormatA llowableCo nversionLi st(ImageFo rmat.DICOM PDF, false );
  451                    dico mPdfList.a dd(ImageFo rmat.DICOM PDF);
  452                    conf ig.formatC onfigurati ons.add(di comPdfList );
  453                    
  454                    Imag eFormatAll owableConv ersionList  jpgList =  
  455                             new Im ageFormatA llowableCo nversionLi st(ImageFo rmat.JPEG,  false);
  456                    jpgL ist.add(Im ageFormat. JPEG);
  457                    jpgL ist.add(Im ageFormat. BMP);
  458                    conf ig.formatC onfigurati ons.add(jp gList);
  459                    
  460                    Imag eFormatAll owableConv ersionList  pdfList =  
  461                             new Im ageFormatA llowableCo nversionLi st(ImageFo rmat.PDF,  false);
  462                    pdfL ist.add(Im ageFormat. PDF);
  463                    conf ig.formatC onfigurati ons.add(pd fList);
  464                    
  465                    Imag eFormatAll owableConv ersionList  docList =  
  466                             new Im ageFormatA llowableCo nversionLi st(ImageFo rmat.DOC,  false);
  467                    docL ist.add(Im ageFormat. DOC);
  468                    conf ig.formatC onfigurati ons.add(do cList);
  469                    
  470                    Imag eFormatAll owableConv ersionList  aviList =  
  471                             new Im ageFormatA llowableCo nversionLi st(ImageFo rmat.AVI,  false);
  472                    aviL ist.add(Im ageFormat. AVI);
  473                    conf ig.formatC onfigurati ons.add(av iList);
  474                    
  475                    Imag eFormatAll owableConv ersionList  bmpList =  
  476                             new Im ageFormatA llowableCo nversionLi st(ImageFo rmat.BMP,  false);
  477                    bmpL ist.add(Im ageFormat. BMP);
  478                    bmpL ist.add(Im ageFormat. JPEG);
  479                    conf ig.formatC onfigurati ons.add(bm pList);
  480                    
  481                    Imag eFormatAll owableConv ersionList  htmlList 
  482                             new Im ageFormatA llowableCo nversionLi st(ImageFo rmat.HTML,  false);
  483                    html List.add(I mageFormat .HTML);
  484                    conf ig.formatC onfigurati ons.add(ht mlList);
  485                    
  486                    Imag eFormatAll owableConv ersionList  mp3List =  
  487                             new Im ageFormatA llowableCo nversionLi st(ImageFo rmat.MP3,  false);
  488                    mp3L ist.add(Im ageFormat. MP3);
  489                    conf ig.formatC onfigurati ons.add(mp 3List);
  490                    
  491                    Imag eFormatAll owableConv ersionList  mpgList =  
  492                             new Im ageFormatA llowableCo nversionLi st(ImageFo rmat.MPG,  false);
  493                    mpgL ist.add(Im ageFormat. MPG);
  494                    conf ig.formatC onfigurati ons.add(mp gList);
  495                    
  496                    Imag eFormatAll owableConv ersionList  rtfList =  
  497                             new Im ageFormatA llowableCo nversionLi st(ImageFo rmat.RTF,  false);
  498                    rtfL ist.add(Im ageFormat. RTF);
  499                    conf ig.formatC onfigurati ons.add(rt fList);
  500                    
  501                    Imag eFormatAll owableConv ersionList  txtList =  
  502                             new Im ageFormatA llowableCo nversionLi st(ImageFo rmat.TEXT_ PLAIN, fal se);
  503                    txtL ist.add(Im ageFormat. TEXT_PLAIN );
  504                    conf ig.formatC onfigurati ons.add(tx tList);
  505                    
  506                    Imag eFormatAll owableConv ersionList  tiffList 
  507                             new Im ageFormatA llowableCo nversionLi st(ImageFo rmat.TIFF,  false);
  508                    tiff List.add(I mageFormat .TIFF);
  509                    conf ig.formatC onfigurati ons.add(ti ffList);
  510                    
  511                    Imag eFormatAll owableConv ersionList  wavList =  
  512                             new Im ageFormatA llowableCo nversionLi st(ImageFo rmat.WAV,  false);
  513                    wavL ist.add(Im ageFormat. WAV);
  514                    conf ig.formatC onfigurati ons.add(wa vList);
  515                    
  516                    Imag eFormatAll owableConv ersionList  docXList 
  517                             new Im ageFormatA llowableCo nversionLi st(ImageFo rmat.DOCX,  false);
  518                    docX List.add(I mageFormat .DOCX);
  519                    conf ig.formatC onfigurati ons.add(do cXList);
  520                    
  521                    Imag eFormatAll owableConv ersionList  xmlList =  
  522                                      new Imag eFormatAll owableConv ersionList (ImageForm at.XML, fa lse);
  523                    xmlL ist.add(Im ageFormat. XML);
  524                    conf ig.formatC onfigurati ons.add(xm lList);
  525           }
  526   }