Lines Matching refs:refc

57      * to the member ({@code refc}).  If this latter class is not distinguished,
58 * the defining class should be passed for both arguments ({@code defc == refc}).
78 * @param refc the class used in the symbolic reference to the proposed member
84 public static boolean isMemberAccessible(Class<?> refc, // symbolic ref class
92 // Usually refc and defc are the same, but if they differ, verify them both.
93 if (refc != defc) {
94 if (!isClassAccessible(refc, lookupClass, allowedModes)) {
100 // Apply the special rules for refc here.
101 if (!isRelatedClass(refc, lookupClass))
103 // If refc == defc, the call to isPublicSuperClass will do
104 // the whole job, since in that case refc (as defc) will be
113 if (refc != defc) return true; // already checked above
114 return isClassAccessible(refc, lookupClass, allowedModes);
136 static boolean isRelatedClass(Class<?> refc, Class<?> lookupClass) {
137 return (refc == lookupClass ||
138 refc.isAssignableFrom(lookupClass) ||
139 lookupClass.isAssignableFrom(refc));
154 * @param refc the symbolic reference class to which access is being checked (C)
157 public static boolean isClassAccessible(Class<?> refc, Class<?> lookupClass,
162 int mods = refc.getModifiers();
166 isSamePackage(lookupClass, refc))
174 * @param type the supposed type of a member or symbolic reference of refc
175 * @param refc
177 public static boolean isTypeVisible(Class<?> type, Class<?> refc) {
178 if (type == refc) return true; // easy check
183 ClassLoader child = refc.getClassLoader();
187 // Do it the hard way: Look up the type name from the refc loader.
199 * @param type the supposed type of a member or symbolic reference of refc
200 * @param refc
202 public static boolean isTypeVisible(java.lang.invoke.MethodType type, Class<?> refc) {
205 if (!isTypeVisible(ptype, refc))