Browse Source

Made tasks receive contexts directly rather than through Contextualizable interface as all tasks will most likely use the context in some fashion

Also fixed up misnamed error message


git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@270839 13f79535-47bb-0310-9956-ffa450edef68
master
Peter Donald 24 years ago
parent
commit
6b70878e0b
2 changed files with 3 additions and 6 deletions
  1. +2
    -5
      proposal/myrmidon/src/java/org/apache/myrmidon/components/executor/DefaultExecutor.java
  2. +1
    -1
      proposal/myrmidon/src/java/org/apache/myrmidon/components/executor/Resources.properties

+ 2
- 5
proposal/myrmidon/src/java/org/apache/myrmidon/components/executor/DefaultExecutor.java View File

@@ -143,15 +143,12 @@ public class DefaultExecutor
{
try
{
if( task instanceof Contextualizable )
{
( (Contextualizable)task ).contextualize( context );
}
task.contextualize( context );
}
catch( final Throwable throwable )
{
final String message =
REZ.getString( "compose.error",
REZ.getString( "contextualize.error",
taskModel.getName(),
taskModel.getLocation(),
throwable.getMessage() );


+ 1
- 1
proposal/myrmidon/src/java/org/apache/myrmidon/components/executor/Resources.properties View File

@@ -10,7 +10,7 @@ disposing.notice=Disposing.
no-create.error=Unable to create task {0}.
config.error=Error configuring task {0} at {1} (Reason: {2}).
compose.error=Error composing task {0} at {1} (Reason: {2}).
context.error=Error contextualizing task {0} at {1} (Reason: {2}).
contextualize.error=Error contextualizing task {0} at {1} (Reason: {2}).
dispose.error=Error disposing task {0} at {1} (Reason: {2}).
init.error=Error initializing task {0} at {1} (Reason: {2}).
logger.error=Error setting logger for task {0} at {1} (Reason: {2}).


Loading…
Cancel
Save