I think Oliver Hoffmann wrote:
[Charset iso-8859-1 unsupported, filtering to ASCII...]
> Ernest (and anyone else interested) ...
> 
> if (u == null)
>   u = Thread.currentThread().getContextClassLoader().getResource(filename);
> if (u == null)
>   throw new JessException("batch", "Cannot open file", e);

Interesting. Why, in general, does
getContextClassLoader().getResource()  return 
something different than getClass().getResource()? Is it just that
Class.getResource() massages the arguments? Can you get Jess to work
as-is by just reading the docs for Class.getResource() and tweaking
the path you're using for the .clp file?

I wonder if Thread.getContextClassLoader() returns null sometimes,
just as Class.getClassLoader() is allowed to do; if so this code needs
to check for that. The Javadoc aren't clear on what happens if
Class.getClassLoader() returns null.


---------------------------------------------------------
Ernest Friedman-Hill  
Distributed Systems Research        Phone: (925) 294-2154
Sandia National Labs                FAX:   (925) 294-2234
Org. 8920, MS 9012                  [EMAIL PROTECTED]
PO Box 969                  http://herzberg.ca.sandia.gov
Livermore, CA 94550

--------------------------------------------------------------------
To unsubscribe, send the words 'unsubscribe jess-users [EMAIL PROTECTED]'
in the BODY of a message to [EMAIL PROTECTED], NOT to the list
(use your own address!) List problems? Notify [EMAIL PROTECTED]
--------------------------------------------------------------------

Reply via email to