1 package net.sourceforge.phpdt.internal.compiler.ast;
4 * A default case for a switch.
5 * it's default : .....;
6 * @author Matthieu Casanova
8 public final class DefaultCase extends AbstractCase {
11 * Create a default case.
13 * @param statements the statements
14 * @param sourceStart the starting offset
15 * @param sourceEnd the ending offset
17 public DefaultCase(final Statement[] statements, final int sourceStart, final int sourceEnd) {
18 super(statements, sourceStart, sourceEnd);
22 * Return the object into String.
24 * @param tab how many tabs (not used here
27 public String toString(final int tab) {
28 final StringBuffer buff = new StringBuffer(tabString(tab));
29 buff.append("default : \n"); //$NON-NLS-1$
30 for (int i = 0; i < statements.length; i++) {
31 final Statement statement = statements[i];
32 buff.append(statement.toString(tab + 9));
34 return buff.toString();