Changeset 10378 in josm for trunk/src/org/openstreetmap/josm/io
- Timestamp:
- 2016-06-15T10:30:37+02:00 (10 years ago)
- Location:
- trunk/src/org/openstreetmap/josm/io
- Files:
-
- 13 edited
-
Capabilities.java (modified) (1 diff)
-
ChangesetQuery.java (modified) (3 diffs)
-
DefaultProxySelector.java (modified) (1 diff)
-
DiffResultProcessor.java (modified) (3 diffs)
-
GpxReader.java (modified) (1 diff)
-
MultiFetchServerObjectReader.java (modified) (2 diffs)
-
NoteReader.java (modified) (1 diff)
-
OsmApi.java (modified) (1 diff)
-
OsmChangeImporter.java (modified) (1 diff)
-
OsmServerBackreferenceReader.java (modified) (2 diffs)
-
OsmServerReader.java (modified) (2 diffs)
-
auth/AbstractCredentialsAgent.java (modified) (1 diff)
-
remotecontrol/AddTagsDialog.java (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/io/Capabilities.java
r8510 r10378 131 131 } 132 132 } else { 133 if (!capabilities.containsKey(element)) {133 if (!capabilities.containsKey(element)) { 134 134 Map<String, String> h = new HashMap<>(); 135 135 capabilities.put(element, h); -
trunk/src/org/openstreetmap/josm/io/ChangesetQuery.java
r10300 r10378 157 157 CheckParameterUtil.ensureParameterNotNull(min, "min"); 158 158 CheckParameterUtil.ensureParameterNotNull(max, "max"); 159 this.bounds = new Bounds(min, max);159 this.bounds = new Bounds(min, max); 160 160 return this; 161 161 } … … 215 215 */ 216 216 public ChangesetQuery beingOpen(boolean isOpen) { 217 this.open = isOpen;217 this.open = isOpen; 218 218 return this; 219 219 } … … 474 474 475 475 protected Map<String, String> createMapFromQueryString(String query) { 476 Map<String, String> queryParams = new HashMap<>();476 Map<String, String> queryParams = new HashMap<>(); 477 477 String[] keyValuePairs = query.split("&"); 478 478 for (String keyValuePair: keyValuePairs) { -
trunk/src/org/openstreetmap/josm/io/DefaultProxySelector.java
r9078 r10378 97 97 return 0; 98 98 } 99 if (port <= 0 || port > 65535) {99 if (port <= 0 || port > 65535) { 100 100 Main.error(tr("Illegal port number in preference ''{0}''. Got {1}.", property, port)); 101 101 Main.error(tr("The proxy will not be used.")); -
trunk/src/org/openstreetmap/josm/io/DiffResultProcessor.java
r9078 r10378 32 32 import org.xml.sax.helpers.DefaultHandler; 33 33 34 public class DiffResultProcessor {34 public class DiffResultProcessor { 35 35 36 36 private static class DiffResultEntry { … … 76 76 * 77 77 */ 78 public void parse(String diffUploadResponse, ProgressMonitor progressMonitor) throws XmlParsingException {78 public void parse(String diffUploadResponse, ProgressMonitor progressMonitor) throws XmlParsingException { 79 79 if (progressMonitor == null) { 80 80 progressMonitor = NullProgressMonitor.INSTANCE; … … 168 168 case "way": 169 169 case "relation": 170 PrimitiveId id = new SimplePrimitiveId(170 PrimitiveId id = new SimplePrimitiveId( 171 171 Long.parseLong(atts.getValue("old_id")), 172 172 OsmPrimitiveType.fromApiTypeName(qName) -
trunk/src/org/openstreetmap/josm/io/GpxReader.java
r10216 r10378 504 504 505 505 @Override 506 public void endDocument() throws SAXException {506 public void endDocument() throws SAXException { 507 507 if (!states.empty()) 508 508 throw new SAXException(tr("Parse error: invalid document structure for GPX document.")); -
trunk/src/org/openstreetmap/josm/io/MultiFetchServerObjectReader.java
r10217 r10378 314 314 final String baseUrl = getBaseUrl(); 315 315 switch (type) { 316 // CHECKSTYLE.OFF: SingleSpaceSeparator 316 317 case NODE: msg = tr("Fetching a package of nodes from ''{0}''", baseUrl); break; 317 318 case WAY: msg = tr("Fetching a package of ways from ''{0}''", baseUrl); break; 318 319 case RELATION: msg = tr("Fetching a package of relations from ''{0}''", baseUrl); break; 320 // CHECKSTYLE.ON: SingleSpaceSeparator 319 321 default: throw new AssertionError(); 320 322 } … … 584 586 String msg; 585 587 switch (type) { 588 // CHECKSTYLE.OFF: SingleSpaceSeparator 586 589 case NODE: msg = tr("Fetching node with id {0} from ''{1}''", id, baseUrl); break; 587 590 case WAY: msg = tr("Fetching way with id {0} from ''{1}''", id, baseUrl); break; 588 591 case RELATION: msg = tr("Fetching relation with id {0} from ''{1}''", id, baseUrl); break; 592 // CHECKSTYLE.ON: SingleSpaceSeparator 589 593 default: throw new AssertionError(); 590 594 } -
trunk/src/org/openstreetmap/josm/io/NoteReader.java
r10216 r10378 194 194 195 195 @Override 196 public void endDocument() throws SAXException {196 public void endDocument() throws SAXException { 197 197 parsedNotes = notes; 198 198 } -
trunk/src/org/openstreetmap/josm/io/OsmApi.java
r10373 r10378 133 133 * @throws IllegalArgumentException if serverUrl is null 134 134 */ 135 protected OsmApi(String serverUrl) {135 protected OsmApi(String serverUrl) { 136 136 CheckParameterUtil.ensureParameterNotNull(serverUrl, "serverUrl"); 137 137 this.serverUrl = serverUrl; -
trunk/src/org/openstreetmap/josm/io/OsmChangeImporter.java
r8895 r10378 44 44 } 45 45 46 protected void importData(InputStream in, final File associatedFile, ProgressMonitor progressMonitor) throws IllegalDataException {46 protected void importData(InputStream in, final File associatedFile, ProgressMonitor progressMonitor) throws IllegalDataException { 47 47 final DataSet dataSet = OsmChangeReader.parseDataSet(in, progressMonitor); 48 48 final OsmDataLayer layer = new OsmDataLayer(dataSet, associatedFile.getName(), associatedFile); -
trunk/src/org/openstreetmap/josm/io/OsmServerBackreferenceReader.java
r10212 r10378 98 98 * @throws IllegalArgumentException if type is null 99 99 */ 100 public OsmServerBackreferenceReader(long id, OsmPrimitiveType type, boolean readFull) {100 public OsmServerBackreferenceReader(long id, OsmPrimitiveType type, boolean readFull) { 101 101 this(id, type); 102 102 this.readFull = readFull; … … 202 202 } 203 203 if (isReadFull()) { 204 Collection<Relation> relationsToCheck = new ArrayList<>(ds.getRelations());204 Collection<Relation> relationsToCheck = new ArrayList<>(ds.getRelations()); 205 205 for (Relation relation: relationsToCheck) { 206 206 if (!relation.isNew() && relation.hasIncompleteMembers()) { -
trunk/src/org/openstreetmap/josm/io/OsmServerReader.java
r10212 r10378 41 41 * @throws OsmTransferException if data transfer errors occur 42 42 */ 43 protected InputStream getInputStream(String urlStr, ProgressMonitor progressMonitor) throws OsmTransferException {43 protected InputStream getInputStream(String urlStr, ProgressMonitor progressMonitor) throws OsmTransferException { 44 44 return getInputStream(urlStr, progressMonitor, null); 45 45 } … … 55 55 * @throws OsmTransferException if data transfer errors occur 56 56 */ 57 protected InputStream getInputStream(String urlStr, ProgressMonitor progressMonitor, String reason) throws OsmTransferException {57 protected InputStream getInputStream(String urlStr, ProgressMonitor progressMonitor, String reason) throws OsmTransferException { 58 58 try { 59 59 api.initialize(progressMonitor); -
trunk/src/org/openstreetmap/josm/io/auth/AbstractCredentialsAgent.java
r10308 r10378 20 20 if (requestorType == null) 21 21 return null; 22 PasswordAuthentication credentials = lookup(requestorType, host);22 PasswordAuthentication credentials = lookup(requestorType, host); 23 23 final String username = (credentials == null || credentials.getUserName() == null) ? "" : credentials.getUserName(); 24 24 final String password = (credentials == null || credentials.getPassword() == null) ? "" : String.valueOf(credentials.getPassword()); -
trunk/src/org/openstreetmap/josm/io/remotecontrol/AddTagsDialog.java
r10308 r10378 150 150 ExistingValues old = new ExistingValues(key); 151 151 for (OsmPrimitive osm : sel) { 152 oldValue = osm.get(key);152 oldValue = osm.get(key); 153 153 if (oldValue != null) { 154 154 old.addValue(oldValue); … … 209 209 propertyTable.getInputMap().put(KeyStroke.getKeyStroke(KeyEvent.VK_ENTER, KeyEvent.SHIFT_MASK), "shiftenter"); 210 210 propertyTable.getActionMap().put("shiftenter", new AbstractAction() { 211 @Override public void actionPerformed(ActionEvent e) {211 @Override public void actionPerformed(ActionEvent e) { 212 212 buttonAction(1, e); // add all tags on Shift-Enter 213 213 } … … 242 242 protected void buttonAction(int buttonIndex, ActionEvent evt) { 243 243 // if layer all layers were closed, ignore all actions 244 if (Main.main.getCurrentDataSet() != null && buttonIndex != 2) {244 if (Main.main.getCurrentDataSet() != null && buttonIndex != 2) { 245 245 TableModel tm = propertyTable.getModel(); 246 246 for (int i = 0; i < tm.getRowCount(); i++) {
Note:
See TracChangeset
for help on using the changeset viewer.
