Debian Codegraph @

rhino/src/org/mozilla/javascript/ast/EmptyStatement.java

raw symbols SCIP
1 /* -*- Mode: java; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 4 -*-
2 *
3 * This Source Code Form is subject to the terms of the Mozilla Public
4 * License, v. 2.0. If a copy of the MPL was not distributed with this
5 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
6
7 package org.mozilla.javascript.ast;
8
9 import org.mozilla.javascript.Token;
10
11 /**
12 * AST node for an empty statement. Node type is {@link Token#EMPTY}.<p>
13 *
14 */
15 public class EmptyStatement extends AstNode {
16
17 {
18 type = Token.EMPTY;
19 }
20
21 public EmptyStatement() {
22 }
23
24 public EmptyStatement(int pos) {
25 super(pos);
26 }
27
28 public EmptyStatement(int pos, int len) {
29 super(pos, len);
30 }
31
32 @Override
33 public String toSource(int depth) {
34 StringBuilder sb = new StringBuilder();
35 sb.append(makeIndent(depth)).append(";\n");
36 return sb.toString();
37 }
38
39 /**
40 * Visits this node. There are no children.
41 */
42 @Override
43 public void visit(NodeVisitor v) {
44 v.visit(this);
45 }
46 }