ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dona...@apache.org
Subject cvs commit: jakarta-ant/proposal/myrmidon/src/java/org/apache/myrmidon/libs/selftest ConfigurationTest.java
Date Sun, 08 Jul 2001 07:21:01 GMT
donaldp     01/07/08 00:21:01

  Modified:    proposal/myrmidon/src/java/org/apache/myrmidon/libs/selftest
                        ConfigurationTest.java
  Log:
  Change to reflect fact that context no longer resolves propertys.
  
  Thus extends AbstractContainerTask to implement functionality.
  
  Revision  Changes    Path
  1.2       +4 -10     jakarta-ant/proposal/myrmidon/src/java/org/apache/myrmidon/libs/selftest/ConfigurationTest.java
  
  Index: ConfigurationTest.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/proposal/myrmidon/src/java/org/apache/myrmidon/libs/selftest/ConfigurationTest.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ConfigurationTest.java	2001/06/16 03:35:24	1.1
  +++ ConfigurationTest.java	2001/07/08 07:21:00	1.2
  @@ -12,6 +12,7 @@
   import org.apache.avalon.framework.configuration.ConfigurationException;
   import org.apache.myrmidon.api.AbstractTask;
   import org.apache.myrmidon.api.TaskException;
  +import org.apache.myrmidon.framework.AbstractContainerTask;
   
   /**
    * This is to test self interpretation of configuration.
  @@ -19,7 +20,7 @@
    * @author <a href="mailto:donaldp@apache.org">Peter Donald</a>
    */
   public class ConfigurationTest
  -    extends AbstractTask
  +    extends AbstractContainerTask
       implements Configurable
   {
       private String              m_message;
  @@ -27,15 +28,8 @@
       public void configure( final Configuration configuration )
           throws ConfigurationException
       {
  -        String message = configuration.getAttribute( "message" );
  -
  -        Object object = null;
  -
  -        try { object = getContext().resolveValue( message ); }
  -        catch( final TaskException ae )
  -        {
  -            throw new ConfigurationException( "Error resolving : " + message, ae );
  -        }
  +        final String message = configuration.getAttribute( "message" );
  +        final Object object = resolve( message );
   
           if( object instanceof String )
           {
  
  
  

Mime
View raw message