You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@xmlbeans.apache.org by pc...@apache.org on 2004/05/13 02:23:32 UTC
cvs commit: xml-xmlbeans/v2/src/jeti/org/apache/xmlbeans/impl/jeti/parameter ParameterService.java
pcal 2004/05/12 17:23:32
Modified: v2/src/binding/org/apache/xmlbeans/impl/binding/tylar
DefaultTylarLoader.java
Removed: v2/src/jeti/org/apache/xmlbeans/impl/jeti ToolContext.java
v2/src/jeti/org/apache/xmlbeans/impl/jeti/logging
Logger.java LoggingService.java
v2/src/jeti/org/apache/xmlbeans/impl/jeti/logging/provider
Message.java MessageConsumer.java package.html
v2/src/jeti/org/apache/xmlbeans/impl/jeti/output
OutputService.java
v2/src/jeti/org/apache/xmlbeans/impl/jeti/parameter
ParameterService.java
Log:
fix for DefaultTylarLoader so that it works with nested jar
remove old jeti stuff
Revision Changes Path
1.14 +4 -9 xml-xmlbeans/v2/src/binding/org/apache/xmlbeans/impl/binding/tylar/DefaultTylarLoader.java
Index: DefaultTylarLoader.java
===================================================================
RCS file: /home/cvs/xml-xmlbeans/v2/src/binding/org/apache/xmlbeans/impl/binding/tylar/DefaultTylarLoader.java,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -r1.13 -r1.14
--- DefaultTylarLoader.java 15 Apr 2004 22:58:45 -0000 1.13
+++ DefaultTylarLoader.java 13 May 2004 00:23:32 -0000 1.14
@@ -104,19 +104,14 @@
if (uri == null) throw new IllegalArgumentException("null uri");
String scheme = uri.getScheme();
if (scheme.equals(FILE_SCHEME)) {
- File file;
+ File file = null;
try {
file = new File(uri);
- } catch(Exception e) {
- //sometimes File can't deal for some reason, so as a last ditch
- //we assume it's a jar and read the stream directly
- return loadFromJar(new JarInputStream(uri.toURL().openStream()),uri);
- }
- if (!file.exists()) throw new FileNotFoundException(uri.toString());
- if (file.isDirectory()) {
+ } catch(Exception ignore) {}
+ if (file != null && file.exists() && file.isDirectory()) {
return ExplodedTylarImpl.load(file);
} else {
- return loadFromJar(new JarInputStream(new FileInputStream(file)),uri);
+ return loadFromJar(new JarInputStream(uri.toURL().openStream()),uri);
}
} else {
throw new IOException("Sorry, the '"+scheme+
---------------------------------------------------------------------
To unsubscribe, e-mail: xmlbeans-cvs-unsubscribe@xml.apache.org
For additional commands, e-mail: xmlbeans-cvs-help@xml.apache.org