Den 29/07/10 22.39, Mike Cunningham skrev:
Shouldn't this
ADDENVVAR ENVVAR(CLASSPATH) VALUE('/JarFiles/datatelDatabaseUtility.jar:/JarFiles/sqljdbc.jar:/JarFiles/jt400.jar') REPLACE(*YES)

And this
ADDENVVAR ENVVAR(CLASSPATH) VALUE('/JarFiles/') REPLACE(*YES)

Work exactly the same?

Shouldn't the second way provide a path to all jar files in the /JarFiles directory in the IFS?
No. The classpath works with either specifying directories containing individual classfiles, or specifying individual jar files.

Recently, a wildcard syntax has been added to Java 6 which allows for specifying all files in a directory, but this means your code will not run under earlier versions of Java. Also the wildcard syntax does not work for runnable jars which is what we use.

Would it be hard to iterate over the files in the directory, and create the CLASSPATH string by joining the names?


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2025 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.