01: package abbot.script;
02:
03: import java.util.Map;
04:
05: import org.jdom.Element;
06:
07: /** Represents a comment. No other function. */
08: public class Comment extends Step {
09:
10: private static final String USAGE = "<!-- [text] -->";
11:
12: public Comment(Resolver resolver, Map attributes) {
13: super (resolver, attributes);
14: }
15:
16: public Comment(Resolver resolver, String description) {
17: super (resolver, description);
18: }
19:
20: /** Default to whitespace. */
21: public String getDefaultDescription() {
22: return "";
23: }
24:
25: public String toString() {
26: return "# " + getDescription();
27: }
28:
29: public String getUsage() {
30: return USAGE;
31: }
32:
33: /** This is only used to generate the title label for the editor. */
34: public String getXMLTag() {
35: return TAG_COMMENT;
36: }
37:
38: public Element toXML() {
39: throw new RuntimeException("Comments are not elements");
40: }
41:
42: /** Main run step. */
43: protected void runStep() {
44: }
45: }
|