Package org.openstreetmap.josm.io
Class OsmChangeReader
java.lang.Object
org.openstreetmap.josm.io.AbstractReader
org.openstreetmap.josm.io.OsmReader
org.openstreetmap.josm.io.OsmChangeReader
Reader for OsmChange file format.
-
Nested Class Summary
Nested classes/interfaces inherited from class org.openstreetmap.josm.io.OsmReader
OsmReader.OptionsNested classes/interfaces inherited from class org.openstreetmap.josm.io.AbstractReader
AbstractReader.BinaryParserWorker, AbstractReader.CommonReader, AbstractReader.NodeReader, AbstractReader.ParserWorker, AbstractReader.RelationReader, AbstractReader.WayReader -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final String[]List of possible actions.protected final NoteDataFields inherited from class org.openstreetmap.josm.io.AbstractReader
cancel, ds, externalIdMap, relations, uploadChangeset, ways -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedconstructor (for private and subclasses use only) -
Method Summary
Modifier and TypeMethodDescriptionfinal NoteDataReplies the parsed notes data.private voidparseCommon(String action) static DataSetparseDataSet(InputStream source, ProgressMonitor progressMonitor) Parse the given input source and return the dataset.parseDataSetAndNotes(InputStream source, ProgressMonitor progressMonitor) Parse the given input source and return the dataset and notes, if any (OsmAnd extends the osmChange format by adding notes).private voidprivate voidprotected voidMethods inherited from class org.openstreetmap.josm.io.OsmReader
doParseDataSet, jumpToEnd, jumpToEnd, parse, parseDataSet, parseNode, parseRelation, parseUnknown, parseUnknown, parseWay, setParser, throwException, throwException, throwExceptionMethods inherited from class org.openstreetmap.josm.io.AbstractReader
buildPrimitive, callPostProcessors, deregisterPostprocessor, doParseDataSet, doParseDataSet, getDataSet, getLong, parseAction, parseBounds, parseChangeset, parseChangeset, parseDownloadPolicy, parseId, parseLocked, parseNode, parseNode, parseRelation, parseRelationMember, parseRelationMember, parseTag, parseTimestamp, parseUploadPolicy, parseUser, parseUser, parseVersion, parseVersion, parseVersion, parseVisible, parseWay, prepareDataSet, processChangesetAfterParsing, processNodesAfterParsing, processRelationsAfterParsing, processWaysAfterParsing, registerPostprocessor
-
Field Details
-
ACTIONS
List of possible actions. -
noteData
-
-
Constructor Details
-
OsmChangeReader
protected OsmChangeReader()constructor (for private and subclasses use only)
-
-
Method Details
-
parseRoot
- Overrides:
parseRootin classOsmReader- Throws:
XMLStreamException
-
parseOsmChange
- Throws:
XMLStreamException
-
parseCommon
- Throws:
XMLStreamException
-
parseNote
- Throws:
XMLStreamException
-
getNoteData
Replies the parsed notes data.- Returns:
- the parsed notes data
- Since:
- 14101
-
parseDataSet
public static DataSet parseDataSet(InputStream source, ProgressMonitor progressMonitor) throws IllegalDataException Parse the given input source and return the dataset.- Parameters:
source- the source input stream. Must not benull.progressMonitor- the progress monitor. Ifnull,NullProgressMonitor.INSTANCEis assumed- Returns:
- the dataset with the parsed data
- Throws:
IllegalDataException- if the an error was found while parsing the data from the sourceIllegalArgumentException- if source isnull
-
parseDataSetAndNotes
public static Pair<DataSet,NoteData> parseDataSetAndNotes(InputStream source, ProgressMonitor progressMonitor) throws IllegalDataException Parse the given input source and return the dataset and notes, if any (OsmAnd extends the osmChange format by adding notes).- Parameters:
source- the source input stream. Must not benull.progressMonitor- the progress monitor. Ifnull,NullProgressMonitor.INSTANCEis assumed- Returns:
- the dataset with the parsed data
- Throws:
IllegalDataException- if the an error was found while parsing the data from the sourceIllegalArgumentException- if source isnull- Since:
- 14101
-