source: josm/trunk/src/org/openstreetmap/josm/io/OsmApi.java@ 2480

Last change on this file since 2480 was 2480, checked in by Gubaer, 14 years ago

fixed #3937: Closed changeset (due to timeout) remains in the upload dialog

File size: 26.0 KB
Line 
1//License: GPL. See README for details.
2package org.openstreetmap.josm.io;
3
4import static org.openstreetmap.josm.tools.I18n.tr;
5
6import java.io.BufferedReader;
7import java.io.BufferedWriter;
8import java.io.IOException;
9import java.io.InputStream;
10import java.io.InputStreamReader;
11import java.io.OutputStream;
12import java.io.OutputStreamWriter;
13import java.io.PrintWriter;
14import java.io.StringReader;
15import java.io.StringWriter;
16import java.net.ConnectException;
17import java.net.HttpURLConnection;
18import java.net.SocketTimeoutException;
19import java.net.URL;
20import java.net.UnknownHostException;
21import java.util.ArrayList;
22import java.util.Collection;
23import java.util.Collections;
24import java.util.HashMap;
25
26import javax.xml.parsers.SAXParserFactory;
27
28import org.openstreetmap.josm.Main;
29import org.openstreetmap.josm.data.osm.Changeset;
30import org.openstreetmap.josm.data.osm.OsmPrimitive;
31import org.openstreetmap.josm.data.osm.OsmPrimitiveType;
32import org.openstreetmap.josm.data.osm.visitor.CreateOsmChangeVisitor;
33import org.openstreetmap.josm.gui.progress.NullProgressMonitor;
34import org.openstreetmap.josm.gui.progress.ProgressMonitor;
35import org.xml.sax.Attributes;
36import org.xml.sax.InputSource;
37import org.xml.sax.SAXException;
38import org.xml.sax.helpers.DefaultHandler;
39
40/**
41 * Class that encapsulates the communications with the OSM API.
42 *
43 * All interaction with the server-side OSM API should go through this class.
44 *
45 * It is conceivable to extract this into an interface later and create various
46 * classes implementing the interface, to be able to talk to various kinds of servers.
47 *
48 */
49public class OsmApi extends OsmConnection {
50 /** max number of retries to send a request in case of HTTP 500 errors or timeouts */
51 static public final int DEFAULT_MAX_NUM_RETRIES = 5;
52
53 /** the collection of instantiated OSM APIs */
54 private static HashMap<String, OsmApi> instances = new HashMap<String, OsmApi>();
55
56 /**
57 * replies the {@see OsmApi} for a given server URL
58 *
59 * @param serverUrl the server URL
60 * @return the OsmApi
61 * @throws IllegalArgumentException thrown, if serverUrl is null
62 *
63 */
64 static public OsmApi getOsmApi(String serverUrl) {
65 OsmApi api = instances.get(serverUrl);
66 if (api == null) {
67 api = new OsmApi(serverUrl);
68 instances.put(serverUrl,api);
69 }
70 return api;
71 }
72 /**
73 * replies the {@see OsmApi} for the URL given by the preference <code>osm-server.url</code>
74 *
75 * @return the OsmApi
76 * @exception IllegalStateException thrown, if the preference <code>osm-server.url</code> is not set
77 *
78 */
79 static public OsmApi getOsmApi() {
80 String serverUrl = Main.pref.get("osm-server.url", "http://api.openstreetmap.org/api");
81 if (serverUrl == null)
82 throw new IllegalStateException(tr("Preference ''{0}'' missing. Can't initialize OsmApi.", "osm-server.url"));
83 return getOsmApi(serverUrl);
84 }
85
86 /** the server URL */
87 private String serverUrl;
88
89 /**
90 * Object describing current changeset
91 */
92 private Changeset changeset;
93
94 /**
95 * API version used for server communications
96 */
97 private String version = null;
98
99 /** the api capabilities */
100 private Capabilities capabilities = new Capabilities();
101
102 /**
103 * true if successfully initialized
104 */
105 private boolean initialized = false;
106
107 private StringWriter swriter = new StringWriter();
108 private OsmWriter osmWriter = new OsmWriter(new PrintWriter(swriter), true, null);
109
110 /**
111 * A parser for the "capabilities" response XML
112 */
113 private class CapabilitiesParser extends DefaultHandler {
114 @Override
115 public void startDocument() throws SAXException {
116 capabilities.clear();
117 }
118
119 @Override public void startElement(String namespaceURI, String localName, String qName, Attributes atts) throws SAXException {
120 for (int i=0; i< qName.length(); i++) {
121 capabilities.put(qName, atts.getQName(i), atts.getValue(i));
122 }
123 }
124 }
125
126 /**
127 * creates an OSM api for a specific server URL
128 *
129 * @param serverUrl the server URL. Must not be null
130 * @exception IllegalArgumentException thrown, if serverUrl is null
131 */
132 protected OsmApi(String serverUrl) {
133 if (serverUrl == null)
134 throw new IllegalArgumentException(tr("Parameter ''{0}'' must not be null.", "serverUrl"));
135 this.serverUrl = serverUrl;
136 }
137
138 /**
139 * Returns the OSM protocol version we use to talk to the server.
140 * @return protocol version, or null if not yet negotiated.
141 */
142 public String getVersion() {
143 return version;
144 }
145
146 /**
147 * Returns true if the negotiated version supports diff uploads.
148 * @return true if the negotiated version supports diff uploads
149 */
150 public boolean hasSupportForDiffUploads() {
151 return ((version != null) && (version.compareTo("0.6")>=0));
152 }
153
154 /**
155 * Initializes this component by negotiating a protocol version with the server.
156 *
157 * @exception OsmApiInitializationException thrown, if an exception occurs
158 */
159 public void initialize(ProgressMonitor monitor) throws OsmApiInitializationException {
160 if (initialized)
161 return;
162 cancel = false;
163 initAuthentication();
164 try {
165 String s = sendRequest("GET", "capabilities", null,monitor, false);
166 InputSource inputSource = new InputSource(new StringReader(s));
167 SAXParserFactory.newInstance().newSAXParser().parse(inputSource, new CapabilitiesParser());
168 if (capabilities.supportsVersion("0.6")) {
169 version = "0.6";
170 } else if (capabilities.supportsVersion("0.5")) {
171 version = "0.5";
172 } else {
173 System.err.println(tr("This version of JOSM is incompatible with the configured server."));
174 System.err.println(tr("It supports protocol versions 0.5 and 0.6, while the server says it supports {0} to {1}.",
175 capabilities.get("version", "minimum"), capabilities.get("version", "maximum")));
176 initialized = false;
177 }
178 System.out.println(tr("Communications with {0} established using protocol version {1}.",
179 serverUrl,
180 version));
181 osmWriter.setVersion(version);
182 initialized = true;
183 } catch (Exception ex) {
184 initialized = false;
185 throw new OsmApiInitializationException(ex);
186 }
187 }
188
189 /**
190 * Makes an XML string from an OSM primitive. Uses the OsmWriter class.
191 * @param o the OSM primitive
192 * @param addBody true to generate the full XML, false to only generate the encapsulating tag
193 * @return XML string
194 */
195 private String toXml(OsmPrimitive o, boolean addBody) {
196 swriter.getBuffer().setLength(0);
197 osmWriter.setWithBody(addBody);
198 osmWriter.setChangeset(changeset);
199 osmWriter.header();
200 o.visit(osmWriter);
201 osmWriter.footer();
202 osmWriter.out.flush();
203 return swriter.toString();
204 }
205
206 /**
207 * Makes an XML string from an OSM primitive. Uses the OsmWriter class.
208 * @param o the OSM primitive
209 * @param addBody true to generate the full XML, false to only generate the encapsulating tag
210 * @return XML string
211 */
212 private String toXml(Changeset s) {
213 swriter.getBuffer().setLength(0);
214 osmWriter.header();
215 s.visit(osmWriter);
216 osmWriter.footer();
217 osmWriter.out.flush();
218 return swriter.toString();
219 }
220
221 /**
222 * Returns the base URL for API requests, including the negotiated version number.
223 * @return base URL string
224 */
225 public String getBaseUrl() {
226 StringBuffer rv = new StringBuffer(serverUrl);
227 if (version != null) {
228 rv.append("/");
229 rv.append(version);
230 }
231 rv.append("/");
232 // this works around a ruby (or lighttpd) bug where two consecutive slashes in
233 // an URL will cause a "404 not found" response.
234 int p; while ((p = rv.indexOf("//", 6)) > -1) { rv.delete(p, p + 1); }
235 return rv.toString();
236 }
237
238 /**
239 * Creates an OSM primitive on the server. The OsmPrimitive object passed in
240 * is modified by giving it the server-assigned id.
241 *
242 * @param osm the primitive
243 * @throws OsmTransferException if something goes wrong
244 */
245 public void createPrimitive(OsmPrimitive osm, ProgressMonitor monitor) throws OsmTransferException {
246 String ret = "";
247 try {
248 ensureValidChangeset();
249 initialize(monitor);
250 ret = sendRequest("PUT", OsmPrimitiveType.from(osm).getAPIName()+"/create", toXml(osm, true),monitor);
251 osm.setOsmId(Long.parseLong(ret.trim()), 1);
252 } catch(NumberFormatException e){
253 throw new OsmTransferException(tr("Unexpected format of ID replied by the server. Got ''{0}''.", ret));
254 }
255 }
256
257 /**
258 * Modifies an OSM primitive on the server. For protocols greater than 0.5,
259 * the OsmPrimitive object passed in is modified by giving it the server-assigned
260 * version.
261 *
262 * @param osm the primitive. Must not be null
263 * @throws OsmTransferException if something goes wrong
264 */
265 public void modifyPrimitive(OsmPrimitive osm, ProgressMonitor monitor) throws OsmTransferException {
266 String ret = null;
267 try {
268 ensureValidChangeset();
269 initialize(monitor);
270 if (version.equals("0.5")) {
271 // legacy mode does not return the new object version.
272 sendRequest("PUT", OsmPrimitiveType.from(osm).getAPIName()+"/" + osm.getId(), toXml(osm, true),monitor);
273 } else {
274 // normal mode (0.6 and up) returns new object version.
275 ret = sendRequest("PUT", OsmPrimitiveType.from(osm).getAPIName()+"/" + osm.getId(), toXml(osm, true), monitor);
276 osm.setOsmId(osm.getId(), Integer.parseInt(ret.trim()));
277 }
278 } catch(NumberFormatException e) {
279 throw new OsmTransferException(tr("Unexpected format of new version of modified primitive ''{0}''. Got ''{1}''.", osm.getId(), ret));
280 }
281 }
282
283 /**
284 * Deletes an OSM primitive on the server.
285 * @param osm the primitive
286 * @throws OsmTransferException if something goes wrong
287 */
288 public void deletePrimitive(OsmPrimitive osm, ProgressMonitor monitor) throws OsmTransferException {
289 ensureValidChangeset();
290 initialize(monitor);
291 // can't use a the individual DELETE method in the 0.6 API. Java doesn't allow
292 // submitting a DELETE request with content, the 0.6 API requires it, however. Falling back
293 // to diff upload.
294 //
295 uploadDiff(Collections.singleton(osm), monitor.createSubTaskMonitor(ProgressMonitor.ALL_TICKS, false));
296 }
297
298
299 /**
300 * Creates a new changeset based on the keys in <code>changeset</code>. If this
301 * method succeeds, changeset.getId() replies the id the server assigned to the new
302 * changeset
303 *
304 * The changeset must not be null, but its key/value-pairs may be empty.
305 *
306 * @param changeset the changeset toe be created. Must not be null.
307 * @param progressMonitor the progress monitor
308 * @throws OsmTransferException signifying a non-200 return code, or connection errors
309 * @throws IllegalArgumentException thrown if changeset is null
310 */
311 public void openChangeset(Changeset changeset, ProgressMonitor progressMonitor) throws OsmTransferException {
312 if (changeset == null)
313 throw new IllegalArgumentException(tr("Parameter ''{0}'' must not be null.", "changeset"));
314 try {
315 progressMonitor.beginTask((tr("Creating changeset...")));
316 initialize(progressMonitor);
317 String ret = "";
318 try {
319 ret = sendRequest("PUT", "changeset/create", toXml(changeset),progressMonitor);
320 changeset.setId(Long.parseLong(ret.trim()));
321 changeset.setOpen(true);
322 } catch(NumberFormatException e){
323 throw new OsmTransferException(tr("Unexpected format of ID replied by the server. Got ''{0}''.", ret));
324 }
325 progressMonitor.setCustomText((tr("Successfully opened changeset {0}",changeset.getId())));
326 } finally {
327 progressMonitor.finishTask();
328 }
329 }
330
331 /**
332 * Updates a changeset with the keys in <code>changesetUpdate</code>. The changeset must not
333 * be null and id > 0 must be true.
334 *
335 * @param changeset the changeset to update. Must not be null.
336 * @param monitor the progress monitor. If null, uses the {@see NullProgressMonitor#INSTANCE}.
337 *
338 * @throws OsmTransferException if something goes wrong.
339 * @throws IllegalArgumentException if changeset is null
340 * @throws IllegalArgumentException if changeset.getId() <= 0
341 *
342 */
343 public void updateChangeset(Changeset changeset, ProgressMonitor monitor) throws OsmTransferException {
344 if (changeset == null)
345 throw new IllegalArgumentException(tr("Parameter ''{0}'' must not be null.", "changeset"));
346 if (monitor == null) {
347 monitor = NullProgressMonitor.INSTANCE;
348 }
349 if (changeset.getId() <= 0)
350 throw new IllegalArgumentException(tr("Changeset ID > 0 expected. Got {0}.", changeset.getId()));
351 try {
352 monitor.beginTask(tr("Updating changeset..."));
353 initialize(monitor);
354 monitor.setCustomText(tr("Updating changeset {0}...", changeset.getId()));
355 sendRequest(
356 "PUT",
357 "changeset/" + changeset.getId(),
358 toXml(changeset),
359 monitor
360 );
361 } catch(OsmApiException e) {
362 if (e.getResponseCode() == HttpURLConnection.HTTP_CONFLICT)
363 throw new ChangesetClosedException(e.getErrorHeader());
364 throw e;
365 } finally {
366 monitor.finishTask();
367 }
368 }
369
370
371 /**
372 * Closes a changeset on the server. Sets changeset.setOpen(false) if this operation
373 * succeeds.
374 *
375 * @param changeset the changeset to be closed. Must not be null. changeset.getId() > 0 required.
376 * @param monitor the progress monitor. If null, uses {@see NullProgressMonitor#INSTANCE}
377 *
378 * @throws OsmTransferException if something goes wrong.
379 * @throws IllegalArgumentException thrown if changeset is null
380 * @throws IllegalArgumentException thrown if changeset.getId() <= 0
381 */
382 public void closeChangeset(Changeset changeset, ProgressMonitor monitor) throws OsmTransferException {
383 if (changeset == null)
384 throw new IllegalArgumentException(tr("Parameter ''{0}'' must not be null.", "changeset"));
385 if (monitor == null) {
386 monitor = NullProgressMonitor.INSTANCE;
387 }
388 if (changeset.getId() <= 0)
389 throw new IllegalArgumentException(tr("Changeset ID > 0 expected. Got {0}.", changeset.getId()));
390 try {
391 monitor.beginTask(tr("Closing changeset..."));
392 initialize(monitor);
393 sendRequest("PUT", "changeset" + "/" + changeset.getId() + "/close", null, monitor);
394 changeset.setOpen(false);
395 } finally {
396 monitor.finishTask();
397 }
398 }
399
400 /**
401 * Uploads a list of changes in "diff" form to the server.
402 *
403 * @param list the list of changed OSM Primitives
404 * @param monitor the progress monitor
405 * @return list of processed primitives
406 * @throws OsmTransferException if something is wrong
407 */
408 public Collection<OsmPrimitive> uploadDiff(Collection<OsmPrimitive> list, ProgressMonitor monitor) throws OsmTransferException {
409 try {
410 monitor.beginTask("", list.size() * 2);
411 if (changeset == null)
412 throw new OsmTransferException(tr("No changeset present for diff upload."));
413
414 initialize(monitor);
415 final ArrayList<OsmPrimitive> processed = new ArrayList<OsmPrimitive>();
416
417 CreateOsmChangeVisitor duv = new CreateOsmChangeVisitor(changeset, OsmApi.this);
418
419 monitor.subTask(tr("Preparing..."));
420 for (OsmPrimitive osm : list) {
421 osm.visit(duv);
422 monitor.worked(1);
423 }
424 monitor.indeterminateSubTask(tr("Uploading..."));
425
426 String diff = duv.getDocument();
427 String diffresult = sendRequest("POST", "changeset/" + changeset.getId() + "/upload", diff,monitor);
428 DiffResultReader.parseDiffResult(diffresult, list, processed, duv.getNewIdMap(),
429 monitor.createSubTaskMonitor(ProgressMonitor.ALL_TICKS, false));
430 return processed;
431 } catch(OsmTransferException e) {
432 throw e;
433 } catch(Exception e) {
434 throw new OsmTransferException(e);
435 } finally {
436 monitor.finishTask();
437 }
438 }
439
440 private void sleepAndListen(int retry, ProgressMonitor monitor) throws OsmTransferCancelledException {
441 System.out.print(tr("Waiting 10 seconds ... "));
442 for(int i=0; i < 10; i++) {
443 if (monitor != null) {
444 monitor.setCustomText(tr("Starting retry {0} of {1} in {2} seconds ...", getMaxRetries() - retry,getMaxRetries(), 10-i));
445 }
446 if (cancel || isAuthCancelled())
447 throw new OsmTransferCancelledException();
448 try {
449 Thread.sleep(1000);
450 } catch (InterruptedException ex) {}
451 }
452 System.out.println(tr("OK - trying again."));
453 }
454
455 /**
456 * Replies the max. number of retries in case of 5XX errors on the server
457 *
458 * @return the max number of retries
459 */
460 protected int getMaxRetries() {
461 int ret = Main.pref.getInteger("osm-server.max-num-retries", DEFAULT_MAX_NUM_RETRIES);
462 return Math.max(ret,0);
463 }
464
465 private String sendRequest(String requestMethod, String urlSuffix,String requestBody, ProgressMonitor monitor) throws OsmTransferException {
466 return sendRequest(requestMethod, urlSuffix, requestBody, monitor, true);
467 }
468
469 /**
470 * Generic method for sending requests to the OSM API.
471 *
472 * This method will automatically re-try any requests that are answered with a 5xx
473 * error code, or that resulted in a timeout exception from the TCP layer.
474 *
475 * @param requestMethod The http method used when talking with the server.
476 * @param urlSuffix The suffix to add at the server url, not including the version number,
477 * but including any object ids (e.g. "/way/1234/history").
478 * @param requestBody the body of the HTTP request, if any.
479 * @param monitor the progress monitor
480 * @param doAuthenticate set to true, if the request sent to the server shall include authentication
481 * credentials;
482 *
483 * @return the body of the HTTP response, if and only if the response code was "200 OK".
484 * @exception OsmTransferException if the HTTP return code was not 200 (and retries have
485 * been exhausted), or rewrapping a Java exception.
486 */
487 private String sendRequest(String requestMethod, String urlSuffix,String requestBody, ProgressMonitor monitor, boolean doAuthenticate) throws OsmTransferException {
488 StringBuffer responseBody = new StringBuffer();
489 int retries = getMaxRetries();
490
491 while(true) { // the retry loop
492 try {
493 URL url = new URL(new URL(getBaseUrl()), urlSuffix);
494 System.out.print(requestMethod + " " + url + "... ");
495 activeConnection = (HttpURLConnection)url.openConnection();
496 activeConnection.setConnectTimeout(15000);
497 activeConnection.setRequestMethod(requestMethod);
498 if (doAuthenticate) {
499 addAuth(activeConnection);
500 }
501
502 if (requestMethod.equals("PUT") || requestMethod.equals("POST") || requestMethod.equals("DELETE")) {
503 activeConnection.setDoOutput(true);
504 activeConnection.setRequestProperty("Content-type", "text/xml");
505 OutputStream out = activeConnection.getOutputStream();
506
507 // It seems that certain bits of the Ruby API are very unhappy upon
508 // receipt of a PUT/POST message without a Content-length header,
509 // even if the request has no payload.
510 // Since Java will not generate a Content-length header unless
511 // we use the output stream, we create an output stream for PUT/POST
512 // even if there is no payload.
513 if (requestBody != null) {
514 BufferedWriter bwr = new BufferedWriter(new OutputStreamWriter(out, "UTF-8"));
515 bwr.write(requestBody);
516 bwr.flush();
517 }
518 out.close();
519 }
520
521 activeConnection.connect();
522 System.out.println(activeConnection.getResponseMessage());
523 int retCode = activeConnection.getResponseCode();
524
525 if (retCode >= 500) {
526 if (retries-- > 0) {
527 sleepAndListen(retries, monitor);
528 System.out.println(tr("Starting retry {0} of {1}.", getMaxRetries() - retries,getMaxRetries()));
529 continue;
530 }
531 }
532
533 // populate return fields.
534 responseBody.setLength(0);
535
536 // If the API returned an error code like 403 forbidden, getInputStream
537 // will fail with an IOException.
538 InputStream i = null;
539 try {
540 i = activeConnection.getInputStream();
541 } catch (IOException ioe) {
542 i = activeConnection.getErrorStream();
543 }
544 if (i != null) {
545 // the input stream can be null if both the input and the error stream
546 // are null. Seems to be the case if the OSM server replies a 401
547 // Unauthorized, see #3887.
548 //
549 BufferedReader in = new BufferedReader(new InputStreamReader(i));
550 String s;
551 while((s = in.readLine()) != null) {
552 responseBody.append(s);
553 responseBody.append("\n");
554 }
555 }
556 String errorHeader = null;
557 // Look for a detailed error message from the server
558 if (activeConnection.getHeaderField("Error") != null) {
559 errorHeader = activeConnection.getHeaderField("Error");
560 System.err.println("Error header: " + errorHeader);
561 } else if (retCode != 200 && responseBody.length()>0) {
562 System.err.println("Error body: " + responseBody);
563 }
564 activeConnection.disconnect();
565
566 errorHeader = errorHeader == null? null : errorHeader.trim();
567 String errorBody = responseBody.length() == 0? null : responseBody.toString().trim();
568 switch(retCode) {
569 case HttpURLConnection.HTTP_OK:
570 return responseBody.toString();
571 case HttpURLConnection.HTTP_GONE:
572 throw new OsmApiPrimitiveGoneException(errorHeader, errorBody);
573 default:
574 throw new OsmApiException(retCode, errorHeader, errorBody);
575 }
576 } catch (UnknownHostException e) {
577 throw new OsmTransferException(e);
578 } catch (SocketTimeoutException e) {
579 if (retries-- > 0) {
580 continue;
581 }
582 throw new OsmTransferException(e);
583 } catch (ConnectException e) {
584 if (retries-- > 0) {
585 continue;
586 }
587 throw new OsmTransferException(e);
588 } catch(OsmTransferException e) {
589 throw e;
590 } catch (Exception e) {
591 throw new OsmTransferException(e);
592 }
593 }
594 }
595
596 /**
597 * returns the API capabilities; null, if the API is not initialized yet
598 *
599 * @return the API capabilities
600 */
601 public Capabilities getCapabilities() {
602 return capabilities;
603 }
604
605
606 /**
607 * Ensures that the current changeset can be used for uploading data
608 *
609 * @throws OsmTransferException thrown if the current changeset can't be used for
610 * uploading data
611 */
612 protected void ensureValidChangeset() throws OsmTransferException {
613 if (changeset == null)
614 throw new OsmTransferException(tr("Current changeset is null. Can't upload data."));
615 if (changeset.getId() <= 0)
616 throw new OsmTransferException(tr("ID of current changeset > 0 required. Current ID is {0}.", changeset.getId()));
617 }
618 /**
619 * Replies the changeset data uploads are currently directed to
620 *
621 * @return the changeset data uploads are currently directed to
622 */
623 public Changeset getChangeset() {
624 return changeset;
625 }
626
627 /**
628 * Sets the changesets to which further data uploads are directed. The changeset
629 * can be null. If it isn't null it must have been created, i.e. id > 0 is required. Furthermore,
630 * it must be open.
631 *
632 * @param changeset the changeset
633 * @throws IllegalArgumentException thrown if changeset.getId() <= 0
634 * @throws IllegalArgumentException thrown if !changeset.isOpen()
635 */
636 public void setChangeset(Changeset changeset) {
637 if (changeset == null) {
638 this.changeset = null;
639 return;
640 }
641 if (changeset.getId() <= 0)
642 throw new IllegalArgumentException(tr("Changeset ID > 0 expected. Got {0}.", changeset.getId()));
643 if (!changeset.isOpen())
644 throw new IllegalArgumentException(tr("Open changeset expected. Got closed changeset with id {0}.", changeset.getId()));
645 this.changeset = changeset;
646 }
647
648}
Note: See TracBrowser for help on using the repository browser.