001// License: GPL. For details, see LICENSE file.
002package org.openstreetmap.josm.data.osm.visitor;
003
004import org.openstreetmap.josm.data.osm.Changeset;
005import org.openstreetmap.josm.data.osm.Node;
006import org.openstreetmap.josm.data.osm.Relation;
007import org.openstreetmap.josm.data.osm.Way;
008
009/**
010 * Implementation of the visitor scheme. Every @{link org.openstreetmap.josm.data.OsmPrimitive}
011 * can be visited by several different visitors.
012 * @since 8
013 */
014public interface Visitor {
015    /**
016     * Visiting call for points.
017     * @param n The node to inspect.
018     */
019    void visit(Node n);
020    /**
021     * Visiting call for lines.
022     * @param w The way to inspect.
023     * @since 64
024     */
025    void visit(Way w);
026    /**
027     * Visiting call for relations.
028     * @param r The relation to inspect.
029     * @since 343
030     */
031    void visit(Relation r);
032    /**
033     * Visiting call for changesets.
034     * @param cs The changeset to inspect.
035     * @since 1523
036     */
037    void visit(Changeset cs);
038}