Changeset 9983 in josm for trunk/src/org/openstreetmap/josm/plugins
- Timestamp:
- 2016-03-13T21:36:47+01:00 (9 years ago)
- Location:
- trunk/src/org/openstreetmap/josm/plugins
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/plugins/PluginException.java
r8308 r9983 13 13 public class PluginException extends Exception { 14 14 public final transient PluginProxy plugin; 15 public final String name;16 15 17 16 public PluginException(PluginProxy plugin, String name, Throwable cause) { 18 17 super(tr("An error occurred in plugin {0}", name), cause); 19 18 this.plugin = plugin; 20 this.name = name;21 19 } 22 20 23 public PluginException(String name, Stringmessage) {21 public PluginException(String message) { 24 22 super(message); 25 23 this.plugin = null; 26 this.name = name;27 24 } 28 25 … … 30 27 super(tr("An error occurred in plugin {0}", name), cause); 31 28 this.plugin = null; 32 this.name = name;33 29 } 34 30 } -
trunk/src/org/openstreetmap/josm/plugins/PluginInformation.java
r8943 r9983 111 111 public PluginInformation(File file, String name) throws PluginException { 112 112 if (!PluginHandler.isValidJar(file)) { 113 throw new PluginException( name,tr("Invalid jar file ''{0}''", file));113 throw new PluginException(tr("Invalid jar file ''{0}''", file)); 114 114 } 115 115 this.name = name; … … 121 121 Manifest manifest = jar.getManifest(); 122 122 if (manifest == null) 123 throw new PluginException( name,tr("The plugin file ''{0}'' does not include a Manifest.", file.toString()));123 throw new PluginException(tr("The plugin file ''{0}'' does not include a Manifest.", file.toString())); 124 124 scanManifest(manifest, false); 125 125 libraries.add(0, Utils.fileToURL(file));
Note:
See TracChangeset
for help on using the changeset viewer.