Class MemberInfoBase
java.lang.Object
org.glassfish.pfl.dynamic.codegen.impl.MemberInfoBase
- All Implemented Interfaces:
MemberInfo
- Direct Known Subclasses:
FieldInfoImpl,MethodInfoBase
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleaninthashCode()booleanisAccessibleInContext(ClassInfo definingClass, ClassInfo accessClass) Returns true iff this member is accessible in the context defined by definingClass (the class containing the reference to the member) and accessClass (the type of the expression used to access this member).intReturn the modifiers on this memberReturn the ClassInfo of the class that contains this member.name()Return the name of this member.toString()
-
Constructor Details
-
MemberInfoBase
-
-
Method Details
-
myClassInfo
Description copied from interface:MemberInfoReturn the ClassInfo of the class that contains this member.- Specified by:
myClassInfoin interfaceMemberInfo
-
modifiers
public int modifiers()Description copied from interface:MemberInfoReturn the modifiers on this member- Specified by:
modifiersin interfaceMemberInfo
-
name
Description copied from interface:MemberInfoReturn the name of this member.- Specified by:
namein interfaceMemberInfo
-
isAccessibleInContext
Description copied from interface:MemberInfoReturns true iff this member is accessible in the context defined by definingClass (the class containing the reference to the member) and accessClass (the type of the expression used to access this member). This works as follows:- If modifiers() contains PUBLIC, the access is permitted.
- If modifiers() contains PRIVATE, the access is permitted iff myClassInfo().name() is the same as definingClass.name().
- If modifiers() contains PROTECTED, the access is permitted as follows:
- If myClassInfo().pkgName() is the same as definingClass.pkgName(), the access is permitted.
- Otherwise, the access is permitted iff definingClass is a subclass of myClassInfo(), and accessClass is a subclass of definingClass.
- Otherwise, the access is permitted iff myClassInfo().pkgName is the same as definingClass.pkgName().
- Specified by:
isAccessibleInContextin interfaceMemberInfo- Parameters:
definingClass- the ClassInfo of the class in which the access occurs.accessClass- the ClassInfo of the class used to access the member.
-
hashCode
public int hashCode() -
equals
-
toString
-