< prev index next >

src/java.base/share/classes/jdk/internal/access/JavaLangReflectAccess.java

Print this page

47     public Class<?>[] getExecutableSharedExceptionTypes(Executable ex);
48 
49     // Copying routines, needed to quickly fabricate new Field,
50     // Method, and Constructor objects from templates
51 
52     /** Makes a "child" copy of a Method */
53     public Method      copyMethod(Method arg);
54 
55     /** Makes a "child" copy of a Field */
56     public Field       copyField(Field arg);
57 
58     /** Makes a "child" copy of a Constructor */
59     public <T> Constructor<T> copyConstructor(Constructor<T> arg);
60 
61     /** Gets the root of the given AccessibleObject object; null if arg is the root */
62     public <T extends AccessibleObject> T getRoot(T obj);
63 
64     /** Tests if this is a trusted final field */
65     public boolean isTrustedFinalField(Field f);
66 



67     /** Returns a new instance created by the given constructor with access check */
68     public <T> T newInstance(Constructor<T> ctor, Object[] args, Class<?> caller)
69         throws IllegalAccessException, InstantiationException, InvocationTargetException;
70 
71     /**
72      * Check that the caller is allowed to unreflect for mutation a final instance field
73      * in a class that is not a record or hidden class.
74      */
75     void checkAllowedToUnreflectFinalSetter(Class<?> caller, Field f) throws IllegalAccessException;
76 }

47     public Class<?>[] getExecutableSharedExceptionTypes(Executable ex);
48 
49     // Copying routines, needed to quickly fabricate new Field,
50     // Method, and Constructor objects from templates
51 
52     /** Makes a "child" copy of a Method */
53     public Method      copyMethod(Method arg);
54 
55     /** Makes a "child" copy of a Field */
56     public Field       copyField(Field arg);
57 
58     /** Makes a "child" copy of a Constructor */
59     public <T> Constructor<T> copyConstructor(Constructor<T> arg);
60 
61     /** Gets the root of the given AccessibleObject object; null if arg is the root */
62     public <T extends AccessibleObject> T getRoot(T obj);
63 
64     /** Tests if this is a trusted final field */
65     public boolean isTrustedFinalField(Field f);
66 
67     /** Tests if this is a null-restricted field */
68     public boolean isNullRestrictedField(Field f);
69 
70     /** Returns a new instance created by the given constructor with access check */
71     public <T> T newInstance(Constructor<T> ctor, Object[] args, Class<?> caller)
72         throws IllegalAccessException, InstantiationException, InvocationTargetException;
73 
74     /**
75      * Check that the caller is allowed to unreflect for mutation a final instance field
76      * in a class that is not a record or hidden class.
77      */
78     void checkAllowedToUnreflectFinalSetter(Class<?> caller, Field f) throws IllegalAccessException;
79 }
< prev index next >