I have been googling for the “Differences between fileset and path” article for some time, but have found nothing useful.
For example, what is the difference between the following (say, there is a someDir directory, which contains .jar files and has no subdirectories):
<path id="somePathId">
<pathelement path="someDir"/>
</path>
<path id="someId">
<path refid="somePathId" />
</path>
and
<path id="someId">
<fileset dir="someDir">
<include name="*.*">
</fileset>
</path>
?
They are used in different situations.
filesetis used to specify a group of files. You can useselectors andpatternsets to get only the files you want.classpathis used to specify classpath references.classpathcan be specified with a single jar (location="..."), a;or:separated list of jars (path="...") or with nested resource collections (likefileset).Also if you want to debug them, it is different:
vs
As for your scripts,
I did not test it but according to the documentation
path=expects a;or:separated list of jars. This is not the same as your second example.