code: public static <T extends AccessibleObject> T accessible(T accessible) {
          if (accessible == null) {
              return null;
          }
  
          if (accessible instanceof Member) {
              Member member = (Member) accessible;
  
              // check the modifier is public
              // if the AccessibleObject is can use then return
              if (Modifier.isPublic(member.getModifiers()) &&
                      Modifier.isPublic(member.getDeclaringClass().getModifiers())) {
  
                  return accessible;
              }
          }
  
          // check the AccessibleObject isAccessible attr
          if (!accessible.isAccessible()) {
              // set accessible flag is true
              accessible.setAccessible(true);
          }
  
          return accessible;
      }
docs: Let{@link AccessibleObject} Accessible flag is true
  
  @param accessible AccessibleObject
  @param <T>        AccessibleObject
  @return AccessibleObject