1 8 package org.codehaus.aspectwerkz.reflect.impl.java; 9 10 import org.codehaus.aspectwerkz.reflect.ClassInfo; 11 import org.codehaus.aspectwerkz.reflect.MemberInfo; 12 13 import java.lang.reflect.Member ; 14 import java.util.List ; 15 16 19 public abstract class JavaMemberInfo implements MemberInfo { 20 23 protected final Member m_member; 24 25 28 protected final ClassInfo m_declaringType; 29 30 33 protected List m_annotations = null; 34 35 38 protected final JavaClassInfoRepository m_classInfoRepository; 39 40 46 JavaMemberInfo(final Member member, final JavaClassInfo declaringType) { 47 if (member == null) { 48 throw new IllegalArgumentException ("member can not be null"); 49 } 50 if (declaringType == null) { 51 throw new IllegalArgumentException ("declaring type can not be null"); 52 } 53 m_member = member; 54 m_declaringType = declaringType; 55 m_classInfoRepository = JavaClassInfoRepository.getRepository(member.getDeclaringClass().getClassLoader()); 56 } 57 58 63 public String getName() { 64 return m_member.getName(); 65 } 66 67 72 public int getModifiers() { 73 return m_member.getModifiers(); 74 } 75 76 81 public ClassInfo getDeclaringType() { 82 return m_declaringType; 83 } 84 } | Popular Tags |