dblevins    2005/07/09 04:51:00

  Modified:    modules/webadmin/src/java/org/openejb/webadmin/httpd
                        DefaultHttpBean.java
  Log:

  I can't fix this Tomcat integration issue with all the silly statics.  
Killing the statics.  Death to the statics!
  Added a class called SystemInstance, which is a singleton and hopefully the 
only important static for the 1.0 codebase someday.
  Changed FileUtils to get its instances from SystemInstance, then inlined all 
that code.
  Changed ClasspathUtils to get its Loader instance from SystemInstance and 
managed to inline all the remaining code.
  
  Revision  Changes    Path
  1.3       +4 -3      
openejb1/modules/webadmin/src/java/org/openejb/webadmin/httpd/DefaultHttpBean.java
  
  Index: DefaultHttpBean.java
  ===================================================================
  RCS file: 
/home/projects/openejb/scm/openejb1/modules/webadmin/src/java/org/openejb/webadmin/httpd/DefaultHttpBean.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- DefaultHttpBean.java      16 Jun 2005 22:29:56 -0000      1.2
  +++ DefaultHttpBean.java      9 Jul 2005 08:51:00 -0000       1.3
  @@ -60,6 +60,7 @@
   import org.openejb.webadmin.HttpRequest;
   import org.openejb.webadmin.HttpResponse;
   import org.openejb.util.FileUtils;
  +import org.openejb.loader.SystemInstance;
   
   /** This is a webadmin bean which has default functionality such as 
genderating
    * error pages and setting page content.
  @@ -79,8 +80,8 @@
   
           try {
               //OpenEJB Home and Base folders
  -            URL base = FileUtils.getBase().getDirectory().toURL();
  -            URL home = FileUtils.getHome().getDirectory().toURL();
  +            URL base = SystemInstance.get().getBase().getDirectory().toURL();
  +            URL home = SystemInstance.get().getHome().getDirectory().toURL();
   
               
               if (!base.sameFile(home)){
  
  
  

Reply via email to