1) Moved net.sourceforge.phpeclipse.ui\src\net\sourceforge\phpdt back to net.sourcefo...
[phpeclipse.git] / net.sourceforge.phpeclipse / src / net / sourceforge / phpdt / core / ILocalVariable.java
1 /*******************************************************************************
2  * Copyright (c) 2000, 2004 IBM Corporation and others.
3  * All rights reserved. This program and the accompanying materials 
4  * are made available under the terms of the Common Public License v1.0
5  * which accompanies this distribution, and is available at
6  * http://www.eclipse.org/legal/cpl-v10.html
7  * 
8  * Contributors:
9  *     IBM Corporation - initial API and implementation
10  *******************************************************************************/
11 package net.sourceforge.phpdt.core;
12
13 /**
14  * Represents a local variable declared in a method or an initializer.
15  * <code>ILocalVariable</code> are pseudo-elements created as the result of a
16  * <code>ICodeAssist.codeSelect(...)</code> operation. They are not part of
17  * the Java model (<code>exists()</code> returns whether the parent exists
18  * rather than whether the local variable exists in the parent) and they are not
19  * included in the children of an <code>IMethod</code> or an
20  * <code>IInitializer</code>.
21  * <p>
22  * In particular such a pseudo-element should not be used as a handle. For
23  * example its name range won't be updated if the underlying source changes.
24  * </p>
25  * <p>
26  * This interface is not intended to be implemented by clients.
27  * </p>
28  * 
29  * @since 3.0
30  */
31 public interface ILocalVariable extends IJavaElement, ISourceReference {
32
33         /**
34          * Returns the name of this local variable.
35          * 
36          * @return the name of this local variable.
37          */
38         String getElementName();
39
40         /**
41          * Returns the source range of this local variable's name.
42          * 
43          * @return the source range of this local variable's name
44          */
45         ISourceRange getNameRange();
46
47         /**
48          * Returns the type signature of this local variable.
49          * <p>
50          * The type signature may be either unresolved (for source types) or
51          * resolved (for binary types), and either basic (for basic types) or rich
52          * (for parameterized types). See {@link Signature} for details.
53          * </p>
54          * 
55          * @return the type signature of this local variable.
56          * @see Signature
57          */
58         String getTypeSignature();
59 }