1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17 package org.apache.jdo.model.java;
18
19 /***
20 * This is the super interface for named JavaModel elements having a declaring
21 * class such as JavaField, JavaMethod, etc.
22 *
23 * @author Michael Bouschen
24 * @since JDO 2.0
25 */
26 public interface JavaMember extends JavaElement
27 {
28 /***
29 * Returns the name of the member.
30 * @return member name
31 */
32 public String getName();
33
34 /***
35 * Returns the JavaType instance representing the class or interface
36 * that declares the member represented by this JavaMember instance.
37 * @return the JavaType instance of the declaring class.
38 */
39 public JavaType getDeclaringClass();
40
41 /***
42 * Returns the Java language modifiers for the field represented by
43 * this JavaMember, as an integer. The java.lang.reflect.Modifier class
44 * should be used to decode the modifiers.
45 * @return the Java language modifiers for this JavaMember
46 * @see java.lang.reflect.Modifier
47 */
48 public int getModifiers();
49
50 /***
51 * Returns the JavaType representation of the type of the member.
52 * @return type of the member
53 */
54 public JavaType getType();
55
56 /***
57 * Returns the JavaType representation of the component type of the type
58 * of the member, if the field type is an array or collection. The
59 * method returns <code>null</code>, if the member type is not an array
60 * or collection.
61 * @return the component type of the member type in case of an array or
62 * collection.
63 */
64 public JavaType getComponentType();
65 }