deleted: export="true"
[phpeclipse.git] / net.sourceforge.phpeclipse / src / net / sourceforge / phpdt / internal / compiler / ast / AbstractVariableDeclaration.java
1 /*******************************************************************************
2  * Copyright (c) 2000, 2001, 2002 International Business Machines Corp. and others.
3  * All rights reserved. This program and the accompanying materials 
4  * are made available under the terms of the Common Public License v0.5 
5  * which accompanies this distribution, and is available at
6  * http://www.eclipse.org/legal/cpl-v05.html
7  * 
8  * Contributors:
9  *     IBM Corporation - initial API and implementation
10  ******************************************************************************/
11 package net.sourceforge.phpdt.internal.compiler.ast;
12
13 public abstract class AbstractVariableDeclaration extends Statement {
14         public int modifiers;
15
16         public TypeReference type;
17         public Expression initialization;
18
19         public char[] name;
20         public int declarationEnd;
21         public int declarationSourceStart;
22         public int declarationSourceEnd;
23         public int modifiersSourceStart;
24         public AbstractVariableDeclaration() {
25         }
26         public abstract String name();
27         
28         public String toString(int tab) {
29
30                 String s = tabString(tab);
31                 if (modifiers != AccDefault) {
32                         s += modifiersString(modifiers);
33                 }
34                 s += type.toString(0) + " " + new String(name()); //$NON-NLS-1$
35                 if (initialization != null)
36                         s += " = " + initialization.toStringExpression(tab); //$NON-NLS-1$
37                 return s;
38         }
39 }