ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From adammurd...@apache.org
Subject cvs commit: jakarta-ant/proposal/myrmidon/src/java/org/apache/antlib/nativelib LoadEnvironment.java
Date Thu, 14 Feb 2002 01:57:47 GMT
adammurdoch    02/02/13 17:57:47

  Modified:    proposal/myrmidon/src/java/org/apache/antlib/nativelib
                        LoadEnvironment.java
  Log:
  Use getService() to find the ExecManager, rather than instantiating it.
  
  Revision  Changes    Path
  1.7       +1 -9      jakarta-ant/proposal/myrmidon/src/java/org/apache/antlib/nativelib/LoadEnvironment.java
  
  Index: LoadEnvironment.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/proposal/myrmidon/src/java/org/apache/antlib/nativelib/LoadEnvironment.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- LoadEnvironment.java	2 Feb 2002 15:43:46 -0000	1.6
  +++ LoadEnvironment.java	14 Feb 2002 01:57:47 -0000	1.7
  @@ -15,8 +15,6 @@
   import org.apache.avalon.excalibur.i18n.Resources;
   import org.apache.myrmidon.api.AbstractTask;
   import org.apache.myrmidon.api.TaskException;
  -import org.apache.myrmidon.framework.factorys.ExecManagerFactory;
  -import org.apache.myrmidon.services.ServiceException;
   
   /**
    * This task is responsible for loading that OS-specific environment
  @@ -90,14 +88,8 @@
       {
           try
           {
  -            final ExecManagerFactory factory = new ExecManagerFactory();
  -            final ExecManager manager = (ExecManager)factory.createService();
  -
  +            final ExecManager manager = (ExecManager)getService( ExecManager.class );
               return manager.getNativeEnvironment();
  -        }
  -        catch( final ServiceException se )
  -        {
  -            throw new TaskException( se.getMessage(), se );
           }
           catch( final ExecException ee )
           {
  
  
  

--
To unsubscribe, e-mail:   <mailto:ant-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-dev-help@jakarta.apache.org>


Mime
View raw message