A variable description (like PHPFunctionDeclaration)
[phpeclipse.git] / net.sourceforge.phpeclipse / src / net / sourceforge / phpeclipse / phpeditor / phpparser / PHPVarDeclaration.java
1 package net.sourceforge.phpeclipse.phpeditor.phpparser;
2
3 import net.sourceforge.phpdt.internal.ui.PHPUiImages;
4 import org.eclipse.jface.resource.ImageDescriptor;
5
6 /**
7  * A php variable declaration strongly inspired by the PHPFunctionDeclaration of Khartlage (:.
8  * @author khartlage, Matthieu Casanova
9  */
10 public class PHPVarDeclaration extends PHPSegment {
11
12     /**
13      * Create a php variable declaration.
14      * @param parent the parent object (it should be a php class)
15      * @param name the name of the variable
16      * @param index where the variable is in the file
17      */
18     public PHPVarDeclaration(Object parent, String name, int index) {
19         super(parent, name, index);
20     }
21
22     /**
23      * Get the image of a variable.
24      * @return the image that represents a php variable
25      */
26     public ImageDescriptor getImage() {
27         return PHPUiImages.DESC_VAR;
28     }
29 }