RE: cvs commit: ant/src/main/org/apache/tools/ant/util JavaEnvUti ls.java

2005-04-12 Thread Shatzer, Larry
> -Original Message-
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, April 12, 2005 1:59 PM
> To: [EMAIL PROTECTED]
> Subject: cvs commit: ant/src/main/org/apache/tools/ant/util
> JavaEnvUtils.java
> 
> 
> stevel  2005/04/12 13:59:06
> 
>   Modified:src/main/org/apache/tools/ant/util JavaEnvUtils.java
>   Log:
>   Java1.5 has different classes in the parent. i've blocked 
> off the xml parser stuff; i worry if that is the right thing 
> to do, but it adheres to the spec.
>   This may be something to go into 1.6.3
>   
>   Revision  ChangesPath
>   1.28  +16 -8 
> ant/src/main/org/apache/tools/ant/util/JavaEnvUtils.java
>   
> [snip]

Your change added leading tabs. Was this on purpose?

-- Larry


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



cvs commit: ant/src/main/org/apache/tools/ant/util JavaEnvUtils.java

2005-04-12 Thread stevel
stevel  2005/04/12 13:59:06

  Modified:src/main/org/apache/tools/ant/util JavaEnvUtils.java
  Log:
  Java1.5 has different classes in the parent. i've blocked off the xml parser 
stuff; i worry if that is the right thing to do, but it adheres to the spec.
  This may be something to go into 1.6.3
  
  Revision  ChangesPath
  1.28  +16 -8 ant/src/main/org/apache/tools/ant/util/JavaEnvUtils.java
  
  Index: JavaEnvUtils.java
  ===
  RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/util/JavaEnvUtils.java,v
  retrieving revision 1.27
  retrieving revision 1.28
  diff -u -r1.27 -r1.28
  --- JavaEnvUtils.java 29 Mar 2005 18:35:45 -  1.27
  +++ JavaEnvUtils.java 12 Apr 2005 20:59:06 -  1.28
  @@ -285,11 +285,16 @@
   jrePackages = new Vector();
   switch(javaVersionNumber) {
   case 15:
  + //In Java1.5, the apache stuff moved. 
  + jrePackages.addElement("com.sun.org.apache");
  + //fall through. 
   case 14:
  -jrePackages.addElement("org.apache.crimson");
  -jrePackages.addElement("org.apache.xalan");
  -jrePackages.addElement("org.apache.xml");
  -jrePackages.addElement("org.apache.xpath");
  + if(javaVersionNumber == 14) {
  + jrePackages.addElement("org.apache.crimson");
  + jrePackages.addElement("org.apache.xalan");
  + jrePackages.addElement("org.apache.xml");
  + jrePackages.addElement("org.apache.xpath");
  + }
   jrePackages.addElement("org.ietf.jgss");
   jrePackages.addElement("org.w3c.dom");
   jrePackages.addElement("org.xml.sax");
  @@ -329,12 +334,15 @@
   tests.addElement("java.lang.Object");
   switch(javaVersionNumber) {
   case 15:
  + 
tests.addElement("com.sun.org.apache.xerces.internal.jaxp.datatype.DatatypeFactoryImpl
 ");
   case 14:
   tests.addElement("sun.audio.AudioPlayer");
  -tests.addElement("org.apache.crimson.parser.ContentModel");
  -
tests.addElement("org.apache.xalan.processor.ProcessorImport");
  -tests.addElement("org.apache.xml.utils.URI");
  -tests.addElement("org.apache.xpath.XPathFactory");
  + if(javaVersionNumber == 14) {
  + 
tests.addElement("org.apache.crimson.parser.ContentModel");
  + 
tests.addElement("org.apache.xalan.processor.ProcessorImport");
  + tests.addElement("org.apache.xml.utils.URI");
  + tests.addElement("org.apache.xpath.XPathFactory");
  + }
   tests.addElement("org.ietf.jgss.Oid");
   tests.addElement("org.w3c.dom.Attr");
   tests.addElement("org.xml.sax.XMLReader");
  
  
  

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



cvs commit: ant/docs/manual/CoreTasks rmic.html

2005-04-12 Thread stevel
stevel  2005/04/12 13:57:02

  Modified:docs/manual/CoreTasks rmic.html
  Log:
  close a 
  
  Revision  ChangesPath
  1.19  +1 -1  ant/docs/manual/CoreTasks/rmic.html
  
  Index: rmic.html
  ===
  RCS file: /home/cvs/ant/docs/manual/CoreTasks/rmic.html,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -r1.18 -r1.19
  --- rmic.html 7 Mar 2005 18:09:09 -   1.18
  +++ rmic.html 12 Apr 2005 20:57:02 -  1.19
  @@ -42,7 +42,7 @@
 weblogic
 forking - the sun compiler forked into a separate process
  "" (empty string). This has the same behaviour as not setting the 
compiler attribute.
  -First the value of build.rmic is used if defined, and if not, 
the default
  +First the value of build.rmic is used if defined, and if not, 
the default
   for the platform is chosen. If build.rmic is set to this, you get the 
default.
   
   
  
  
  

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 34419] - Zip Task - Replace option when duplicate found.

2005-04-12 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=34419


[EMAIL PROTECTED] changed:

   What|Removed |Added

 Status|REOPENED|RESOLVED
 Resolution||INVALID




-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug, or are watching the assignee.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 34419] - Zip Task - Replace option when duplicate found.

2005-04-12 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=34419


[EMAIL PROTECTED] changed:

   What|Removed |Added

 Status|RESOLVED|REOPENED
 Resolution|FIXED   |




-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug, or are watching the assignee.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 34419] - Zip Task - Replace option when duplicate found.

2005-04-12 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=34419


[EMAIL PROTECTED] changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution||FIXED




--- Additional Comments From [EMAIL PROTECTED]  2005-04-12 20:34 ---
Gosh, I dont know why I never tried that.  It works as you described.

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug, or are watching the assignee.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [patch] javadoc, name-hiding, if/else nesting

2005-04-12 Thread Martijn Kruithof
Thanks Kev,
Committed the  vs  part.
I do not really see the benefit of having
if (condition)
{
   return a;
}
return b;
over:
if (condition)
{
   return a;
} else {
   return b;
}
so I didn't apply those patches.
I did apply the destDir -> baseDir one, but it left the javadoc in an 
inconsistent state (one would set destDir, but would get something based 
on baseDir), so I didn't commit that one.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


cvs commit: ant/src/main/org/apache/tools/ant/util ContainerMapper.java

2005-04-12 Thread jkf
jkf 2005/04/12 10:49:37

  Modified:src/main/org/apache/tools/ant/util ContainerMapper.java
  Log:
  Obtained from: Kev Jackson
  
  Javadoc in ContainerMapper to contain lowercase code instead of uppercase 
code.
  
  Revision  ChangesPath
  1.6   +13 -11
ant/src/main/org/apache/tools/ant/util/ContainerMapper.java
  
  Index: ContainerMapper.java
  ===
  RCS file: 
/home/cvs/ant/src/main/org/apache/tools/ant/util/ContainerMapper.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- ContainerMapper.java  24 Jan 2005 18:13:20 -  1.5
  +++ ContainerMapper.java  12 Apr 2005 17:49:37 -  1.6
  @@ -25,7 +25,7 @@
   
   /**
* A FileNameMapper that contains
  - * other FileNameMappers.
  + * other FileNameMappers.
* @see FileNameMapper
*/
   public abstract class ContainerMapper implements FileNameMapper {
  @@ -42,11 +42,11 @@
   
   /**
* Add a FileNameMapper.
  - * @param fileNameMapper a FileNameMapper.
  + * @param fileNameMapper a FileNameMapper.
* @throws IllegalArgumentException if attempting to add this
  - * ContainerMapper to itself, or if the specified
  - * FileNameMapper is itself a 
ContainerMapper
  - * that contains this ContainerMapper.
  + * ContainerMapper to itself, or if the specified
  + * FileNameMapper is itself a 
ContainerMapper
  + * that contains this ContainerMapper.
*/
   public synchronized void add(FileNameMapper fileNameMapper) {
   if (this == fileNameMapper
  @@ -60,10 +60,10 @@
   }
   
   /**
  - * Return true if this ContainerMapper or any 
of
  - * its sub-elements contains the specified FileNameMapper.
  - * @param fileNameMapper   the FileNameMapper to search for.
  - * @return boolean.
  + * Return true if this ContainerMapper or any 
of
  + * its sub-elements contains the specified FileNameMapper.
  + * @param fileNameMapper   the FileNameMapper to search for.
  + * @return boolean.
*/
   protected synchronized boolean contains(FileNameMapper fileNameMapper) {
   boolean foundit = false;
  @@ -77,8 +77,8 @@
   }
   
   /**
  - * Get the List of FileNameMappers.
  - * @return List.
  + * Get the List of FileNameMappers.
  + * @return List.
*/
   public synchronized List getMappers() {
   return Collections.unmodifiableList(mappers);
  @@ -89,6 +89,7 @@
* @param ignore ignored.
*/
   public void setFrom(String ignore) {
  +//Empty
   }
   
   /**
  @@ -96,6 +97,7 @@
* @param ignore ignored.
*/
   public void setTo(String ignore) {
  +//Empty
   }
   
   }
  
  
  

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 34411] - Task.init() gets called twice

2005-04-12 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=34411


[EMAIL PROTECTED] changed:

   What|Removed |Added

   Target Milestone|--- |1.7




--- Additional Comments From [EMAIL PROTECTED]  2005-04-12 19:21 ---
Please verify this is fixed in CVS HEAD.

Thanks

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug, or are watching the assignee.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



cvs commit: ant WHATSNEW

2005-04-12 Thread mbenson
mbenson 2005/04/12 10:19:41

  Modified:.WHATSNEW
  Log:
  Task.init() was called twice for most tasks.
  PR: 34411
  
  Revision  ChangesPath
  1.804 +2 -0  ant/WHATSNEW
  
  Index: WHATSNEW
  ===
  RCS file: /home/cvs/ant/WHATSNEW,v
  retrieving revision 1.803
  retrieving revision 1.804
  diff -u -r1.803 -r1.804
  --- WHATSNEW  11 Apr 2005 09:31:01 -  1.803
  +++ WHATSNEW  12 Apr 2005 17:19:41 -  1.804
  @@ -86,6 +86,8 @@
 return any, causing problems with Informix IDS 9.2 and IBM DB2 8.1
 FixPak 6 (or later). Bugzilla Reports 27162 and 29954.
   
  +* Task.init() was called twice for most tasks.  Bugzilla Report 34411.
  +
   Other changes:
   --
   
  
  
  

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



cvs commit: ant/src/main/org/apache/tools/ant UnknownElement.java

2005-04-12 Thread mbenson
mbenson 2005/04/12 10:18:30

  Modified:src/main/org/apache/tools/ant UnknownElement.java
  Log:
  When getting the real object from UE, do not call Task.init() on the Object
  returned from ComponentHelper as init() has been called in createComponent().
  PR: 34411
  
  Revision  ChangesPath
  1.89  +2 -3  ant/src/main/org/apache/tools/ant/UnknownElement.java
  
  Index: UnknownElement.java
  ===
  RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/UnknownElement.java,v
  retrieving revision 1.88
  retrieving revision 1.89
  diff -u -r1.88 -r1.89
  --- UnknownElement.java   29 Mar 2005 21:47:59 -  1.88
  +++ UnknownElement.java   12 Apr 2005 17:18:29 -  1.89
  @@ -414,15 +414,14 @@
   Task task = (Task) o;
   task.setTaskType(ue.getTaskType());
   task.setTaskName(ue.getTaskName());
  +task.init();
   }
   }
   if (o instanceof UnknownElement) {
   o = ((UnknownElement) o).makeObject((UnknownElement) o, w);
   }
   if (o instanceof Task) {
  -Task task = (Task) o;
  -task.setOwningTarget(getOwningTarget());
  -task.init();
  +((Task) o).setOwningTarget(getOwningTarget());
   }
   return o;
   }
  
  
  

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 34419] - Zip Task - Replace option when duplicate found.

2005-04-12 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=34419





--- Additional Comments From [EMAIL PROTECTED]  2005-04-12 19:10 ---
does 
not already do what you want ?

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug, or are watching the assignee.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Suggested change to Move.java to check failonerror flag when unable to delete source file as part of move

2005-04-12 Thread Matt Benson
You can submit a RFE on Ant's bugzilla.  A possible
name for this theoretical attribute might be
keepgoing, since that term has been used in Ant
before.

-Matt

--- [EMAIL PROTECTED] wrote:
> 
> Thanks again for your response and patience.
> 
> I see what you are saying - and therefore copy
> has the same issue.  That is to say if you pass
> a list of files to copy and an exception is thrown
> copying one of the files - then the task will not
> attempt to copy the rest of the files in the list.
> 
> failonerror has no impact on this - all it does is
> prevent the build from failing.
> 
> Perhaps what it needed is an additional attribute
> that controls whether or not the Copy/Move tasks
> suspend the processing remaining files when an error
> occurs.
> 
> If this is appropriate - how would one go about
> requesting / implementing this additional
> functionality.
> 
> Gary
> 
> >
> > Move is a subclass of Copy.  Move has no execute
> > method of its own; it inherits that of Copy.  Copy
> > checks failonerror within its execute method, so
> Move
> > treats failonerror exactly as does Copy.
> >
> > -Matt
> 
> 
> 
>
-
> To unsubscribe, e-mail:
> [EMAIL PROTECTED]
> For additional commands, e-mail:
> [EMAIL PROTECTED]
> 
> 



__ 
Do you Yahoo!? 
Yahoo! Small Business - Try our new resources site!
http://smallbusiness.yahoo.com/resources/

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Suggested change to Move.java to check failonerror flag when unable to delete source file as part of move

2005-04-12 Thread GBartlett

Thanks again for your response and patience.

I see what you are saying - and therefore copy
has the same issue.  That is to say if you pass
a list of files to copy and an exception is thrown
copying one of the files - then the task will not
attempt to copy the rest of the files in the list.

failonerror has no impact on this - all it does is
prevent the build from failing.

Perhaps what it needed is an additional attribute
that controls whether or not the Copy/Move tasks
suspend the processing remaining files when an error
occurs.

If this is appropriate - how would one go about
requesting / implementing this additional functionality.

Gary

>
> Move is a subclass of Copy.  Move has no execute
> method of its own; it inherits that of Copy.  Copy
> checks failonerror within its execute method, so Move
> treats failonerror exactly as does Copy.
>
> -Matt



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: junit test runner enhancements

2005-04-12 Thread Phil Weighill Smith
Steve,

I've not written any code to help here, but thought the following issue
could also be considered:

When executing a test class that has no test methods what-so-ever (e.g.
someone comments out all tests for some reason) the runner currently
barfs instead of ignoring the test class.

Phil :n.

On Tue, 2005-04-12 at 16:54 +0100, Steve Loughran wrote:
> I'm thinking of what would it take to modify JUnitTestRunner to
> 
> -skip anything that is abstract
> -skip anything that is not a test case
> 
> I know there are bugs on this; has anyone done the code to do it, and if 
> not, where should I start.
> 
> I could tweak JUnitTestRunner.run() to probe classes and then just 
> return if they werent there.
> -Should I still fire events, or just skip everything
> -Should we print everything (I say, yes, warn but continue)
> 
> -Steve
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



junit test runner enhancements

2005-04-12 Thread Steve Loughran
I'm thinking of what would it take to modify JUnitTestRunner to
-skip anything that is abstract
-skip anything that is not a test case
I know there are bugs on this; has anyone done the code to do it, and if 
not, where should I start.

I could tweak JUnitTestRunner.run() to probe classes and then just 
return if they werent there.
-Should I still fire events, or just skip everything
-Should we print everything (I say, yes, warn but continue)

-Steve
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


DO NOT REPLY [Bug 34411] - Task.init() gets called twice

2005-04-12 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=34411





--- Additional Comments From [EMAIL PROTECTED]  2005-04-12 17:12 ---
ah, to refine that assessment:  UE should call init only if its result is not
the same Object created by the ComponentHelper.

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug, or are watching the assignee.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 34411] - Task.init() gets called twice

2005-04-12 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=34411





--- Additional Comments From [EMAIL PROTECTED]  2005-04-12 17:05 ---
Since init is called by UE both explicitly and via a call to
ComponentHelper.createComponent() in the same method, I think we can and should
remove the explicit call from UE.makeObject().

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug, or are watching the assignee.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: BCEL change (was Re: [EMAIL PROTECTED]: Project dist-ant (in module ant) failed)

2005-04-12 Thread Conor MacNeill
Matt Benson wrote:
--- Stefan Bodewig <[EMAIL PROTECTED]> wrote:
  [javac] Compiling 57 source files to

/home/gump/workspaces2/public/workspace/ant/build/classes
  [javac]

/home/gump/workspaces2/public/workspace/ant/src/main/org/apache/tools/ant/util/depend/bcel/AncestorAnalyzer.java:44:
exception java.io.IOException is never thrown in
body of corresponding try statement
  [javac] } catch (IOException e) {
  [javac]   ^
  [javac] 1 error
looks like a backwards-incompatible change in BCEL.
Anybody with ties to the BCEL community who could
pick up the ball?

Such as Conor?  All it is is a change to
org.apache.bcel.classfile.ClassParser by dbrosius
whereby IOException was removed from two constructors.
Yeah, I'll check it out in about 18 hours :)
Conor
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: BCEL change (was Re: [EMAIL PROTECTED]: Project dist-ant (in module ant) failed)

2005-04-12 Thread Matt Benson
--- Stefan Bodewig <[EMAIL PROTECTED]> wrote:
> >[javac] Compiling 57 source files to
>
/home/gump/workspaces2/public/workspace/ant/build/classes
> >[javac]
>
/home/gump/workspaces2/public/workspace/ant/src/main/org/apache/tools/ant/util/depend/bcel/AncestorAnalyzer.java:44:
> exception java.io.IOException is never thrown in
> body of corresponding try statement
> >[javac] } catch (IOException e) {
> >[javac]   ^
> >[javac] 1 error
> 
> looks like a backwards-incompatible change in BCEL.
> 
> Anybody with ties to the BCEL community who could
> pick up the ball?

Such as Conor?  All it is is a change to
org.apache.bcel.classfile.ClassParser by dbrosius
whereby IOException was removed from two constructors.

-Matt

> 
> Stefan
> 
>
-
> To unsubscribe, e-mail:
> [EMAIL PROTECTED]
> For additional commands, e-mail:
> [EMAIL PROTECTED]
> 
> 



__ 
Do you Yahoo!? 
Make Yahoo! your home page 
http://www.yahoo.com/r/hs

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 34411] - Task.init() gets called twice

2005-04-12 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=34411





--- Additional Comments From [EMAIL PROTECTED]  2005-04-12 16:15 ---
My bad. I stumbled on that one also, and didn't report it. I was in a hurry, 
and then forgot. I just worked around it in my code. It was the first time the 
double init() call created a bug for me. Usually I don't have an init(), or it 
doesn't add things to a list as in this case. Double creation of a var is 
wasteful but usually benign, while double add to a list was a bug. --DD

  public void init()
  throws BuildException {
// necessary, since init() is called twice!
if (_implicit == null) {
  // Configure and add the implicit folder
  _implicit = new Folder();
  ...
}
  }

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug, or are watching the assignee.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



DO NOT REPLY [Bug 34419] New: - Zip Task - Replace option when duplicate found.

2005-04-12 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=34419

   Summary: Zip Task - Replace option when duplicate found.
   Product: Ant
   Version: 1.6.2
  Platform: All
OS/Version: other
Status: NEW
  Severity: enhancement
  Priority: P2
 Component: Core tasks
AssignedTo: [EMAIL PROTECTED]
ReportedBy: [EMAIL PROTECTED]


It would be extremely helpful at least to me, if the duplicate attribute
supported a replace option in the zip task.  I often have to rebuild zip files
for one reason or another and it make much more sense to just replace a single
file inside the zip instead of rebuilding the whole thing.

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug, or are watching the assignee.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: References

2005-04-12 Thread Conor MacNeill
Matt Benson wrote:
So the rule becomes, "when writing a custom type, IF
you extend DataType, and IF those who program to your
custom type only use addXXX and/or add(Type), then the
refid attribute will be handled for you
automatically."  That's all well and good, but
basically I don't see what it gains us.  In a rewrite
I think it would be possible to have everything a form
of add() or addXXX(), the latter serving only to give
a specific element name to an instantiable type.  But
given the responsibility of supporting all historical
subelement creation patterns I don't see that
reference processing in the core stops authors of new
DataTypes (including us) having to support refid
through code.  I'd love to be wrong, though.
No, you are right, I think. The processing of refs in the types 
themselves is unfortunate.

Conor
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: Ant Jar doubt

2005-04-12 Thread Conor MacNeill
Raja Nagendra Kumar wrote:
Raja Nagendra Kumar wrote:
Hi,
When ever we jar I see in the manifest 'Ant-Version: Apache Ant 1.6.2'
this
line. Could any one tell me how to avoid this.
I dont know if there is a way to do this (yet)

Is there any custom tasks written by any one which could be used for this
purpose.
You should be able to use the  task and place your manifest in 
manually.


And also I want to put few
properties of mine in a way the squence of these properties are
maintinated
in manifest. My observation here is sqence is altered.
The manifest code will maintain the order of sections in the manifest 
and also the order of attributes within each section, including the main 
section. The only changes Ant will make is to ensure the manifest 
complies with the spec, which states:

"Manifest-Version and Signature-Version must be first, and in exactly 
that case (so that they can be recognized easily as magic strings). 
Other than that, the order of attributes within a main section is not 
significant. "

If you use the  task you should be able to put whatever you want in 
the manifest, including something which is invalid. You will lose all 
manifest validation logic.


I dont believe that code should depend on the order; its part of the
manifest specification. We'd only be encouraging bad practices if enabled.

This is because, my client (J2ME Game publisher) is asking for this order..
Any case why should the oder be manipulated by the jar command. Why does it
not take the things in way it has been provided ..
You're in a little bind there since the spec specifically says that 
order is not significant. Nevertheless, the code does attempt to 
maintain the order of things. Can you tell us what you are seeing? A 
little example?

Is it worth asking your client why they require a specific order?
Conor
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: References

2005-04-12 Thread Matt Benson

--- Conor MacNeill <[EMAIL PROTECTED]> wrote:
> I support moving reference processing into the core.
> This is how mutant 
> worked. It is certainly a core responsibility.
> 
> It should only be done for addXXX methods. By the
> core-task contract 
> those are the elements for which the task has given
> the core the 
> responsibility for creating the element instance.
> For createXXX, the 
> task is saying that it is in control and it needs to
> do its own refid 
> processing.

So the rule becomes, "when writing a custom type, IF
you extend DataType, and IF those who program to your
custom type only use addXXX and/or add(Type), then the
refid attribute will be handled for you
automatically."  That's all well and good, but
basically I don't see what it gains us.  In a rewrite
I think it would be possible to have everything a form
of add() or addXXX(), the latter serving only to give
a specific element name to an instantiable type.  But
given the responsibility of supporting all historical
subelement creation patterns I don't see that
reference processing in the core stops authors of new
DataTypes (including us) having to support refid
through code.  I'd love to be wrong, though.

-Matt

> 
> Conor
> 
>
-
> To unsubscribe, e-mail:
> [EMAIL PROTECTED]
> For additional commands, e-mail:
> [EMAIL PROTECTED]
> 
> 



__ 
Do you Yahoo!? 
Yahoo! Small Business - Try our new resources site!
http://smallbusiness.yahoo.com/resources/

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Ant Jar doubt

2005-04-12 Thread Steve Loughran
Raja Nagendra Kumar wrote:
Hi,
Thanks for the reply. My reply in-line
- Original Message - 
From: "Steve Loughran" <[EMAIL PROTECTED]>
To: "Ant Developers List" <[EMAIL PROTECTED]>
Sent: Tuesday, April 12, 2005 4:41 PM
Subject: Re: Ant Jar doubt


Raja Nagendra Kumar wrote:
Hi,
When ever we jar I see in the manifest 'Ant-Version: Apache Ant 1.6.2'
this
line. Could any one tell me how to avoid this.
I dont know if there is a way to do this (yet)

Is there any custom tasks written by any one which could be used for this
purpose.
no, but it isnt needed,

in manifest. My observation here is sqence is altered.
I dont believe that code should depend on the order; its part of the
manifest specification. We'd only be encouraging bad practices if enabled.

This is because, my client (J2ME Game publisher) is asking for this order..

Well, they -or the telephone provider- are not using the specification 
correctly:
http://java.sun.com/j2se/1.5.0/docs/guide/jar/jar.html#Notes%20on%20Manifest%20and%20Signature%20Files

"The order of individual manifest entries is not significant."
If it is their code, their code is broken. If it is a particular phone. 
I'd like to know which one. Is it a motorola phone?

Any case why should the oder be manipulated by the jar command. Why does it
not take the things in way it has been provided ..
Because there are lots of things the task does with manifest fixup, such 
as correcting over-long lines using the official wrapping rules, and 
other aspects of the manifest specification. We intermittently get 
complaints about the ant code not understanding how to wrap lines or 
otherwise set up JAR files, but you have to remember: Ant probably 
creates the majority of the JAR files on the planet for production 
applications. We follow the specs to the letter, and have to be strict.

Also, re-ordering entries stops people writing code which makes 
assumptions about manifest entry order. Clearly, someone downstream from 
you has done exactly that, which is why you are suffering. But  we don't 
do it deliberatetly, it's probably just hashTable at work.

If you don't want Ant to do your manifest
1. write it by hand
2. use the  task to create the JAR
3. import the manifest at META-INF/manifest.mf
That's all. no need for custom tasks.  I'd recommend you use  
to create a stub manifest that you patch by hand. That reduces the 
likelihood of the manifest being wrong.

There are some extra ant tasks for j2me listed on our external task list:
http://ant.apache.org/external.html
The antic one looks like it does special J2ME stuff.
-Steve
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: Ant Jar doubt

2005-04-12 Thread Raja Nagendra Kumar
Hi,

Thanks for the reply. My reply in-line


- Original Message - 
From: "Steve Loughran" <[EMAIL PROTECTED]>
To: "Ant Developers List" <[EMAIL PROTECTED]>
Sent: Tuesday, April 12, 2005 4:41 PM
Subject: Re: Ant Jar doubt


> Raja Nagendra Kumar wrote:
> > Hi,
> >
> > When ever we jar I see in the manifest 'Ant-Version: Apache Ant 1.6.2'
this
> > line. Could any one tell me how to avoid this.
>
> I dont know if there is a way to do this (yet)
>

Is there any custom tasks written by any one which could be used for this
purpose.


> > And also I want to put few
> > properties of mine in a way the squence of these properties are
maintinated
> > in manifest. My observation here is sqence is altered.
>
> I dont believe that code should depend on the order; its part of the
> manifest specification. We'd only be encouraging bad practices if enabled.

This is because, my client (J2ME Game publisher) is asking for this order..
Any case why should the oder be manipulated by the jar command. Why does it
not take the things in way it has been provided ..

Regards,
Nagendra

>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Ant Jar doubt

2005-04-12 Thread Steve Loughran
Raja Nagendra Kumar wrote:
Hi,
When ever we jar I see in the manifest 'Ant-Version: Apache Ant 1.6.2' this
line. Could any one tell me how to avoid this. 
I dont know if there is a way to do this (yet)
And also I want to put few
properties of mine in a way the squence of these properties are maintinated
in manifest. My observation here is sqence is altered.
I dont believe that code should depend on the order; its part of the 
manifest specification. We'd only be encouraging bad practices if enabled.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Ant Jar doubt

2005-04-12 Thread Raja Nagendra Kumar
Hi,

When ever we jar I see in the manifest 'Ant-Version: Apache Ant 1.6.2' this
line. Could any one tell me how to avoid this. And also I want to put few
properties of mine in a way the squence of these properties are maintinated
in manifest. My observation here is sqence is altered.

Thank you in advance

Regards,
Nagendra


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: regression in handling of failures

2005-04-12 Thread Kev Jackson
Looks like it was there in Ant 1.5 final (Java.run()), but now it's missing
Here's a patch to fix this.
Kev
I have it on reliable authority (chapter 5 of java development with 
ant), that Ant1.5 would fail with a location error when you tried to 
run  without a class on the classpath. But now I see a stack 
trace and not a location:

 [echo] running the diary program
 [java] Could not find d1.core.DiaryMain. Make sure you have it in 
your classpath
 [java] at 
org.apache.tools.ant.taskdefs.ExecuteJava.execute(ExecuteJava.java:178)
 [java] at org.apache.tools.ant.taskdefs.Java.run(Java.java:731)
 [java] at 
org.apache.tools.ant.taskdefs.Java.executeJava(Java.java:190) 
[java] at org.apache.tools.ant.taskdefs.Java.execute(Java.java:100)
 [java] at 
org.apache.tools.ant.UnknownElement.execute(UnknownElement.jav

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Index: Java.java
===
RCS file: /home/cvspublic/ant/src/main/org/apache/tools/ant/taskdefs/Java.java,v
retrieving revision 1.103
diff -u -r1.103 Java.java
--- Java.java   18 Mar 2005 17:32:14 -  1.103
+++ Java.java   12 Apr 2005 10:20:39 -
@@ -734,7 +734,7 @@
 throw new BuildException("Timeout: killed the sub-process");
 }
 } catch (IOException e) {
-throw new BuildException(e);
+throw new BuildException(e, getLocation());
 }
 }
 
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

regression in handling of failures

2005-04-12 Thread Steve Loughran
I have it on reliable authority (chapter 5 of java development with 
ant), that Ant1.5 would fail with a location error when you tried to run 
 without a class on the classpath. But now I see a stack trace and 
not a location:

 [echo] running the diary program
 [java] Could not find d1.core.DiaryMain. Make sure you have it in 
your classpath
 [java] at 
org.apache.tools.ant.taskdefs.ExecuteJava.execute(ExecuteJava.java:178)
 [java] at org.apache.tools.ant.taskdefs.Java.run(Java.java:731)
 [java] at 
org.apache.tools.ant.taskdefs.Java.executeJava(Java.java:190) [java] 
at org.apache.tools.ant.taskdefs.Java.execute(Java.java:100)
 [java] at 
org.apache.tools.ant.UnknownElement.execute(UnknownElement.jav

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


[EMAIL PROTECTED]: Project dist-ant (in module ant) failed

2005-04-12 Thread Gump Integration Build
To whom it may engage...

This is an automated request, but not an unsolicited one. For 
more information please visit http://gump.apache.org/nagged.html, 
and/or contact the folk at [EMAIL PROTECTED]

Project dist-ant has an issue affecting its community integration.
This issue affects 8 projects,
 and has been outstanding for 4 runs.
The current state of this project is 'Failed', with reason 'Build Failed'.
For reference only, the following projects are affected by this:
- JacORB :  The free Java implementation of the OMG's CORBA standard.
- JacORB-idllib :  The free Java implementation of the OMG's CORBA standard.
- dist-ant :  Java based build tool
- dist-xalan2 :  Release 2.x of the Xalan-Java XSLT processor
- dist-xerces1 :  Java XML Parser
- slide-webdavclient :  Content Management System based on WebDAV technology
- test-ant :  Java based build tool
- test-ant-no-xerces :  Java based build tool


Full details are available at:
http://brutus.apache.org/gump/public/ant/dist-ant/index.html

That said, some information snippets are provided here.

The following annotations (debug/informational/warning/error messages) were 
provided:
 -WARNING- Bad *Optional* Dependency. Project: jai unknown to *this* workspace
 -INFO- Failed with reason build failed
 -INFO- Failed to extract fallback artifacts from Gump Repository



The following work was performed:
http://brutus.apache.org/gump/public/ant/dist-ant/gump_work/build_ant_dist-ant.html
Work Name: build_ant_dist-ant (Type: Build)
Work ended in a state of : Failed
Elapsed: 8 secs
Command Line: java -Djava.awt.headless=true 
-Xbootclasspath/p:/usr/local/gump/public/workspace/xml-xerces2/java/build/xercesImpl.jar:/usr/local/gump/public/workspace/xml-commons/java/external/build/xml-apis.jar:/usr/local/gump/public/workspace/xml-xalan/java/build/xalan-unbundled.jar
 org.apache.tools.ant.Main 
-Dgump.merge=/home/gump/workspaces2/public/gump/work/merge.xml 
-Dbuild.sysclasspath=only -Dchmod.fail=false distribution 
[Working Directory: /usr/local/gump/public/workspace/ant]
CLASSPATH: 
/opt/jdk1.4/lib/tools.jar:/usr/local/gump/public/workspace/ant/dist/lib/ant-jmf.jar:/usr/local/gump/public/workspace/ant/dist/lib/ant-swing.jar:/usr/local/gump/public/workspace/ant/dist/lib/ant-apache-resolver.jar:/usr/local/gump/public/workspace/ant/dist/lib/ant-trax.jar:/usr/local/gump/public/workspace/ant/dist/lib/ant-junit.jar:/usr/local/gump/public/workspace/ant/dist/lib/ant-launcher.jar:/usr/local/gump/public/workspace/ant/dist/lib/ant-nodeps.jar:/usr/local/gump/public/workspace/ant/dist/lib/ant.jar:/usr/local/gump/public/workspace/dist/junit/junit.jar:/usr/local/gump/public/workspace/xml-commons/java/build/resolver.jar:/usr/local/gump/packages/antlr-2.7.3/antlr.jar:/usr/local/gump/public/workspace/jakarta-commons/logging/dist/commons-logging.jar:/usr/local/gump/public/workspace/jakarta-commons/logging/dist/commons-logging-api.jar:/usr/local/gump/public/workspace/jakarta-commons/net/dist/commons-net-12042005.jar:/usr/local/gump/packages/jaf-1.0.1/activation.jar:/usr/local/gump/public/workspace/jakarta-bcel/bin/bcel.jar:/usr/local/gump/public/workspace/jakarta-bsf/build/lib/bsf.jar:/usr/local/gump/public/workspace/logging-log4j/log4j-12042005.jar:/usr/local/gump/public/workspace/jakarta-oro/jakarta-oro-12042005.jar:/usr/local/gump/public/workspace/jakarta-regexp/build/jakarta-regexp-12042005.jar:/usr/local/gump/public/workspace/jakarta-servletapi-4/lib/servlet.jar:/usr/local/gump/packages/javamail-1.3.2/mail.jar:/usr/local/gump/packages/javamail-1.3.2/lib/mailapi.jar:/usr/local/gump/packages/jdepend-2.6/lib/jdepend.jar:/usr/local/gump/packages/jsch-0.1.18/dist/lib/jsch-gump.jar:/usr/local/gump/public/workspace/xml-stylebook/bin/stylebook-1.0-b3_xalan-2.jar
-
Buildfile: build.xml

main_distribution:
[mkdir] Created dir: 
/home/gump/workspaces2/public/workspace/ant/distribution
[mkdir] Created dir: 
/home/gump/workspaces2/public/workspace/ant/distribution/src
[mkdir] Created dir: 
/home/gump/workspaces2/public/workspace/ant/distribution/bin

prepare:

check_for_optional_packages:

build:
[javac] Compiling 58 source files to 
/home/gump/workspaces2/public/workspace/ant/build/classes
[javac] 
/home/gump/workspaces2/public/workspace/ant/src/main/org/apache/tools/ant/util/depend/bcel/AncestorAnalyzer.java:44:
 exception java.io.IOException is never thrown in body of corresponding try 
statement
[javac] } catch (IOException e) {
[javac]   ^
[javac] 1 error

BUILD FAILED
/home/gump/workspaces2/public/workspace/ant/build.xml:1195: The following error 
occurred while executing this line:
/home/gump/workspaces2/public/workspace/ant/build.xml:660: Compile failed; see 
the compiler error output for details.

Total time: 8 seconds
-

To subscribe to this information via syndicated feeds:
- RSS: http://brutus.apache.o

[patch] javadoc, name-hiding, if/else nesting

2005-04-12 Thread Kev Jackson
some tweaks, nothing major
Kev
Index: CollectionUtils.java
===
RCS file: 
/home/cvspublic/ant/src/main/org/apache/tools/ant/util/CollectionUtils.java,v
retrieving revision 1.18
diff -u -r1.18 CollectionUtils.java
--- CollectionUtils.java14 Mar 2005 09:14:56 -  1.18
+++ CollectionUtils.java12 Apr 2005 07:13:47 -
@@ -191,11 +191,8 @@
 public Object nextElement() throws NoSuchElementException {
 if (e1.hasMoreElements()) {
 return e1.nextElement();
-} else {
-return e2.nextElement();
-}
+} 
+return e2.nextElement();
 }
-
 }
-
 }
Index: ContainerMapper.java
===
RCS file: 
/home/cvspublic/ant/src/main/org/apache/tools/ant/util/ContainerMapper.java,v
retrieving revision 1.5
diff -u -r1.5 ContainerMapper.java
--- ContainerMapper.java24 Jan 2005 18:13:20 -  1.5
+++ ContainerMapper.java12 Apr 2005 07:13:48 -
@@ -25,7 +25,7 @@
 
 /**
  * A FileNameMapper that contains
- * other FileNameMappers.
+ * other FileNameMappers.
  * @see FileNameMapper
  */
 public abstract class ContainerMapper implements FileNameMapper {
@@ -42,11 +42,11 @@
 
 /**
  * Add a FileNameMapper.
- * @param fileNameMapper a FileNameMapper.
+ * @param fileNameMapper a FileNameMapper.
  * @throws IllegalArgumentException if attempting to add this
- * ContainerMapper to itself, or if the specified
- * FileNameMapper is itself a 
ContainerMapper
- * that contains this ContainerMapper.
+ * ContainerMapper to itself, or if the specified
+ * FileNameMapper is itself a 
ContainerMapper
+ * that contains this ContainerMapper.
  */
 public synchronized void add(FileNameMapper fileNameMapper) {
 if (this == fileNameMapper
@@ -60,10 +60,10 @@
 }
 
 /**
- * Return true if this ContainerMapper or any of
- * its sub-elements contains the specified FileNameMapper.
- * @param fileNameMapper   the FileNameMapper to search for.
- * @return boolean.
+ * Return true if this ContainerMapper or any of
+ * its sub-elements contains the specified FileNameMapper.
+ * @param fileNameMapper   the FileNameMapper to search for.
+ * @return boolean.
  */
 protected synchronized boolean contains(FileNameMapper fileNameMapper) {
 boolean foundit = false;
@@ -77,8 +77,8 @@
 }
 
 /**
- * Get the List of FileNameMappers.
- * @return List.
+ * Get the List of FileNameMappers.
+ * @return List.
  */
 public synchronized List getMappers() {
 return Collections.unmodifiableList(mappers);
Index: FileUtils.java
===
RCS file: 
/home/cvspublic/ant/src/main/org/apache/tools/ant/util/FileUtils.java,v
retrieving revision 1.93
diff -u -r1.93 FileUtils.java
--- FileUtils.java  7 Apr 2005 23:42:46 -   1.93
+++ FileUtils.java  12 Apr 2005 07:13:57 -
@@ -891,9 +891,8 @@
 index = path.indexOf(File.separatorChar, 1);
 if (index == -1) {
 return path.substring(1) + ":[00]";
-} else {
-device = path.substring(1, index++);
 }
+device = path.substring(1, index++);
 }
 if (isDirectory) {
 directory = new StringBuffer(path.substring(index).
Index: SourceFileScanner.java
===
RCS file: 
/home/cvspublic/ant/src/main/org/apache/tools/ant/util/SourceFileScanner.java,v
retrieving revision 1.30
diff -u -r1.30 SourceFileScanner.java
--- SourceFileScanner.java  24 Jan 2005 22:08:32 -  1.30
+++ SourceFileScanner.java  12 Apr 2005 07:13:58 -
@@ -37,7 +37,7 @@
 protected Task task;
 
 private static final FileUtils FILE_UTILS = FileUtils.getFileUtils();
-private File destDir; // base directory of the fileset
+private File baseDir; // base directory of the fileset
 
 /**
  * Construct a new SourceFileScanner.
@@ -84,7 +84,7 @@
 public String[] restrict(String[] files, File srcDir, File destDir,
  FileNameMapper mapper, long granularity) {
 // record destdir for later use in getResource
-this.destDir = destDir;
+this.baseDir = destDir;
 Vector v = new Vector();
 for (int i = 0; i < files.length; i++) {
 File src = FILE_UTILS.resolveFile(srcDir, files[i]);
@@ -153,12 +153,12 @@
 /**
  * Returns resource information for a file at destination.
  * @param name relative path of file at destination.
- * @return data concerning a file whose relative path to destDir is name.
+ * @return data concerning a file whose 

Re: References

2005-04-12 Thread Conor MacNeill

Matt Benson wrote:
Ha, I think we've been stonewalled.  What we're
talking about is great for add* methods, but I think
we're out of luck for create* methods.  Although I
never use these anymore either.  Seems kind of bad to
say "refid works on all datatypes automatically,
unless you use createXXX methods"... :(  I may keep
messing around with this just to see what happens
though.
-Matt
 
I support moving reference processing into the core. This is how mutant 
worked. It is certainly a core responsibility.

It should only be done for addXXX methods. By the core-task contract 
those are the elements for which the task has given the core the 
responsibility for creating the element instance. For createXXX, the 
task is saying that it is in control and it needs to do its own refid 
processing.

Conor
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


DO NOT REPLY [Bug 34411] New: - Task.init() gets called twice

2005-04-12 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=34411

   Summary: Task.init() gets called twice
   Product: Ant
   Version: 1.7Alpha (nightly)
  Platform: All
OS/Version: All
Status: NEW
  Severity: normal
  Priority: P2
 Component: Core
AssignedTo: [EMAIL PROTECTED]
ReportedBy: [EMAIL PROTECTED]


The init() method of a custom task that I am working on apparently gets called
twice. This is probably not intended and the specification does not state that
this would be the case.

When looking at the source code of UnknownElement.java and ComponentHelper.java
I get the impression that this behavior still exists in the current HEAD stream.
UnknownElement.makeObject(...) initially calls
ComponentHelper.createComponent(...) to create a new task or type.
ComponentHelper.createComponent(...), in turn, calls Task.init() and adds the
new task. However, at the end of method UnknownElement.makeObject(...) there is
another invocation of Task.init(), which calls the init() method of the task for
the second time.

I hope I'm not misunderstanding or overlooking something here; I would expect
that other custom Ant tasks would have stumbled over this problem before, so I'm
somewhat surprised to be the first person to report this problem. Still, the
problems that I am encountering with my own task and a look at the current CVS
(UnknownElement rev. 1.88, ComponentHelper rev. 1.52) suggests that this is
what's happening.

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
--- You are receiving this mail because: ---
You are the assignee for the bug, or are watching the assignee.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]