Changes:
[phpeclipse.git] / net.sourceforge.phpeclipse / src / net / sourceforge / phpdt / core / IField.java
1 /*******************************************************************************
2  * Copyright (c) 2000, 2003 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 field declared in a type.
15  * <p>
16  * This interface is not intended to be implemented by clients.
17  * </p>
18  */
19 public interface IField extends IMember {
20 /**
21  * Returns the constant value associated with this field
22  * or <code>null</code> if this field has none.
23  * Returns either a subclass of <code>Number</code>, or a <code>String</code>,
24  * depending on the type of the field.
25  * For example, if the field is of type <code>short</code>, this returns
26  * a <code>Short</code>.
27  *
28  * @return  the constant value associated with this field or <code>null</code> if this field has none.
29  * @exception JavaModelException if this element does not exist or if an
30  *      exception occurs while accessing its corresponding resource
31  */
32 public Object getConstant() throws JavaModelException;
33 /**
34  * Returns the simple name of this field.
35  * @return the simple name of this field.
36  */
37 String getElementName();
38 /**
39  * Returns the type signature of this field.
40  *
41  * @see Signature
42  * @return the type signature of this field.
43  * @exception JavaModelException if this element does not exist or if an
44  *      exception occurs while accessing its corresponding resource
45  */
46 String getTypeSignature() throws JavaModelException;
47 }