Class UploadNotesTask.UploadTask
java.lang.Object
org.openstreetmap.josm.gui.PleaseWaitRunnable
org.openstreetmap.josm.actions.upload.UploadNotesTask.UploadTask
- All Implemented Interfaces:
Runnable,ProgressMonitor.CancelListener
- Enclosing class:
- UploadNotesTask
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate booleanFields inherited from class org.openstreetmap.josm.gui.PleaseWaitRunnable
progressMonitor -
Constructor Summary
ConstructorsConstructorDescriptionUploadTask(String title, ProgressMonitor monitor) Constructs a newUploadTask. -
Method Summary
Modifier and TypeMethodDescriptionprotected voidcancel()User pressed cancel button.protected voidfinish()Updates the note layer with uploaded notes and notifies the user of any upload failuresprivate voidprocessNoteComment(ProgressMonitor monitor, OsmApi api, Note note, NoteComment comment) protected voidrealRun()Called in the worker thread to do the actual work.Methods inherited from class org.openstreetmap.josm.gui.PleaseWaitRunnable
afterFinish, canRunInBackground, getProgressMonitor, operationCanceled, run
-
Field Details
-
isCanceled
-
updatedNotes
-
failedNotes
-
-
Constructor Details
-
UploadTask
UploadTask(String title, ProgressMonitor monitor) Constructs a newUploadTask.- Parameters:
title- message for the usermonitor- progress monitor
-
-
Method Details
-
cancel
Description copied from class:PleaseWaitRunnableUser pressed cancel button.- Specified by:
cancelin classPleaseWaitRunnable
-
realRun
Description copied from class:PleaseWaitRunnableCalled in the worker thread to do the actual work. When any of the exception is thrown, a message box will be displayed and closeDialog is called. finish() is called in any case.- Specified by:
realRunin classPleaseWaitRunnable- Throws:
SAXException- if a SAX error occursIOException- if an I/O error occursOsmTransferException- if a communication error with the OSM server occurs
-
processNoteComment
private void processNoteComment(ProgressMonitor monitor, OsmApi api, Note note, NoteComment comment) -
finish
Updates the note layer with uploaded notes and notifies the user of any upload failures- Specified by:
finishin classPleaseWaitRunnable
-