source: josm/trunk/src/org/openstreetmap/josm/command/PseudoCommand.java@ 8910

Last change on this file since 8910 was 8447, checked in by Don-vip, 9 years ago

fix #11508 - fix bad behaviour of Move Node onto way with overlapping ways

  • Property svn:eol-style set to native
File size: 1.3 KB
Line 
1// License: GPL. For details, see LICENSE file.
2package org.openstreetmap.josm.command;
3
4import java.util.Collection;
5
6import javax.swing.Icon;
7
8import org.openstreetmap.josm.data.osm.OsmPrimitive;
9
10/**
11 * PseudoCommand is a reduced form of a command. It can be presented in a tree view
12 * as subcommand of real commands but it is just an empty shell and can not be
13 * executed or undone.
14 */
15public abstract class PseudoCommand {
16
17 /**
18 * Provides a description text representing this command.
19 * @return description text representing this command
20 */
21 public abstract String getDescriptionText();
22
23 /**
24 * Provides a descriptive icon of this command.
25 * @return descriptive icon of this command
26 */
27 public Icon getDescriptionIcon() {
28 return null;
29 }
30
31 /**
32 * Return the primitives that take part in this command.
33 * @return primitives that take part in this command
34 */
35 public abstract Collection<? extends OsmPrimitive> getParticipatingPrimitives();
36
37 /**
38 * Returns the subcommands of this command.
39 * Override for subclasses that have child commands.
40 * @return the subcommands, null if there are no child commands
41 */
42 public Collection<PseudoCommand> getChildren() {
43 return null;
44 }
45}
Note: See TracBrowser for help on using the repository browser.