aa5841e844ab1122007316c98bdfafefc52b7792
[phpeclipse.git] / net.sourceforge.phpeclipse / src / net / sourceforge / phpdt / internal / compiler / ast / Expression.java
1 package net.sourceforge.phpdt.internal.compiler.ast;
2
3
4 /**
5  * An expression.
6  * @author Matthieu Casanova
7  */
8 public abstract class Expression extends Statement {
9
10   /**
11    * Create an expression giving starting and ending offset
12    * @param sourceStart starting offset
13    * @param sourceEnd ending offset
14    */
15   protected Expression(final int sourceStart, final int sourceEnd) {
16     super(sourceStart, sourceEnd);
17   }
18
19   /**
20    * Return the expression with a number of spaces before.
21    * @param tab how many spaces before the expression
22    * @return a string representing the expression
23    */
24   public final String toString(final int tab) {
25     return tabString(tab) + toStringExpression();
26   }
27
28   /**
29    * Return the expression as String.
30    * @return the expression
31    */
32   public abstract String toStringExpression();
33 }