Changeset 3052


Ignore:
Timestamp:
Jan 9, 2007, 9:12:06 AM (17 years ago)
Author:
Martin Svensson
Message:

Fixes #459 Better error message if plugin jar can't be found

Location:
trunk/src/core/net/sf/basedb
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/core/net/sf/basedb/core/PluginDefinition.java

    r3050 r3052  
    3939import net.sf.basedb.util.JarClassLoader;
    4040
     41import java.io.IOException;
    4142import java.util.Collection;
    4243import java.util.Collections;
     
    969970      return (Plugin)c.newInstance();
    970971    }
     972    catch (IOException ioex)
     973    {
     974      throw new BaseException(ioex);
     975    }
    971976    catch (Exception ex)
    972977    {
  • trunk/src/core/net/sf/basedb/util/JarClassLoader.java

    r2723 r3052  
    141141    super(Thread.currentThread().getContextClassLoader());
    142142    mainJarFile = new File(jarPath);
     143    if (!mainJarFile.exists()) throw new IOException("Couldn't find jar-file: \"" + jarPath + "\"");
    143144    classPath = new HashMap<String, File>();
    144145    loadJarFile(mainJarFile, true);
     
    210211      JarEntry jarEntry = entries.nextElement();
    211212      String name = jarEntry.getName();
    212       //System.out.println(name);
     213     
    213214      if (!classPath.containsKey(name))
    214215      {
Note: See TracChangeset for help on using the changeset viewer.