Changeset 2512 in josm for trunk/src/org/openstreetmap/josm/actions/ExtensionFileFilter.java
- Timestamp:
- 2009-11-24T10:45:04+01:00 (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/actions/ExtensionFileFilter.java
r2367 r2512 38 38 */ 39 39 public static ArrayList<FileImporter> importers; 40 40 41 41 public static ArrayList<FileExporter> exporters; 42 42 43 43 // add some file types only if the relevant classes are there; 44 44 // this gives us the option to painlessly drop them from the .jar … … 48 48 49 49 importers = new ArrayList<FileImporter>(); 50 50 51 51 String[] importerNames = { 52 52 "org.openstreetmap.josm.io.OsmImporter", … … 62 62 Class klass = Class.forName(classname); 63 63 importers.add((FileImporter)klass.newInstance()); 64 } catch (Exception e) {} 64 } catch (Exception e) {} 65 65 } 66 66 … … 78 78 Class klass = Class.forName(classname); 79 79 exporters.add((FileExporter)klass.newInstance()); 80 } catch (Exception e) {} 80 } catch (Exception e) {} 81 81 } 82 82 } … … 85 85 private final String description; 86 86 private final String defaultExtension; 87 88 87 89 88 static protected void sort(List<ExtensionFileFilter> filters) { … … 105 104 * The list is ordered according to their description, an {@see AllFormatsImporter} 106 105 * is append at the end. 107 * 106 * 108 107 * @return an ordered list of {@see ExtensionFileFilter}s for importing. 109 108 */ … … 124 123 * The list is ordered according to their description, an {@see AllFormatsImporter} 125 124 * is append at the end. 126 * 125 * 127 126 * @return an ordered list of {@see ExtensionFileFilter}s for exporting. 128 127 */ … … 141 140 /** 142 141 * Replies the default {@see ExtensionFileFilter} for a given extension 143 * 142 * 144 143 * @param extension the extension 145 144 * @return the default {@see ExtensionFileFilter} for a given extension … … 156 155 /** 157 156 * Replies the default {@see ExtensionFileFilter} for a given extension 158 * 157 * 159 158 * @param extension the extension 160 159 * @return the default {@see ExtensionFileFilter} for a given extension … … 172 171 * Applies the choosable {@see FileFilter} to a {@see JFileChooser} before using the 173 172 * file chooser for selecting a file for reading. 174 * 173 * 175 174 * @param fileChooser the file chooser 176 175 * @param extension the default extension … … 186 185 * Applies the choosable {@see FileFilter} to a {@see JFileChooser} before using the 187 186 * file chooser for selecting a file for writing. 188 * 187 * 189 188 * @param fileChooser the file chooser 190 189 * @param extension the default extension
Note:
See TracChangeset
for help on using the changeset viewer.