From 654c43efea685099cfabd174eba78f03a22f9a54 Mon Sep 17 00:00:00 2001 From: kpouer Date: Thu, 23 Jan 2003 16:54:50 +0000 Subject: [PATCH 1/1] A variable description (like PHPFunctionDeclaration) --- .../phpeditor/phpparser/PHPVarDeclaration.java | 29 ++++++++++++++++++++ 1 files changed, 29 insertions(+), 0 deletions(-) create mode 100644 net.sourceforge.phpeclipse/src/net/sourceforge/phpeclipse/phpeditor/phpparser/PHPVarDeclaration.java diff --git a/net.sourceforge.phpeclipse/src/net/sourceforge/phpeclipse/phpeditor/phpparser/PHPVarDeclaration.java b/net.sourceforge.phpeclipse/src/net/sourceforge/phpeclipse/phpeditor/phpparser/PHPVarDeclaration.java new file mode 100644 index 0000000..2f81a61 --- /dev/null +++ b/net.sourceforge.phpeclipse/src/net/sourceforge/phpeclipse/phpeditor/phpparser/PHPVarDeclaration.java @@ -0,0 +1,29 @@ +package net.sourceforge.phpeclipse.phpeditor.phpparser; + +import net.sourceforge.phpdt.internal.ui.PHPUiImages; +import org.eclipse.jface.resource.ImageDescriptor; + +/** + * A php variable declaration strongly inspired by the PHPFunctionDeclaration of Khartlage (:. + * @author khartlage, Matthieu Casanova + */ +public class PHPVarDeclaration extends PHPSegment { + + /** + * Create a php variable declaration. + * @param parent the parent object (it should be a php class) + * @param name the name of the variable + * @param index where the variable is in the file + */ + public PHPVarDeclaration(Object parent, String name, int index) { + super(parent, name, index); + } + + /** + * Get the image of a variable. + * @return the image that represents a php variable + */ + public ImageDescriptor getImage() { + return PHPUiImages.DESC_VAR; + } +} -- 1.7.1