Class ReflectionUtils
java.lang.Object
mg.emberframework.utils.reflection.ReflectionUtils
-
Method Summary
Modifier and TypeMethodDescriptionstatic ObjectexecuteClassMethod(Class<?> clazz, String methodName, Object... args) static ObjectexecuteMethod(Object object, String methodName, Object... args) static ObjectexecuteRequestMethod(Mapping mapping, jakarta.servlet.http.HttpServletRequest request, String verb) static voidsetObjectAttributesValues(Object instance, Field field, String value) static voidsetSessionAttribute(Object object, jakarta.servlet.http.HttpServletRequest request)
-
Method Details
-
setObjectAttributesValues
public static void setObjectAttributesValues(Object instance, Field field, String value) throws SecurityException, NoSuchMethodException, IllegalAccessException, IllegalArgumentException, InvocationTargetException -
setSessionAttribute
public static void setSessionAttribute(Object object, jakarta.servlet.http.HttpServletRequest request) throws NoSuchMethodException, SecurityException, IllegalAccessException, IllegalArgumentException, InvocationTargetException -
executeRequestMethod
public static Object executeRequestMethod(Mapping mapping, jakarta.servlet.http.HttpServletRequest request, String verb) throws NoSuchMethodException, SecurityException, IllegalAccessException, IllegalArgumentException, InvocationTargetException, InstantiationException, AnnotationNotPresentException, InvalidRequestException, IOException, jakarta.servlet.ServletException - Throws:
NoSuchMethodExceptionSecurityExceptionIllegalAccessExceptionIllegalArgumentExceptionInvocationTargetExceptionInstantiationExceptionAnnotationNotPresentExceptionInvalidRequestExceptionIOExceptionjakarta.servlet.ServletException
-
executeMethod
public static Object executeMethod(Object object, String methodName, Object... args) throws NoSuchMethodException, SecurityException, IllegalAccessException, IllegalArgumentException, InvocationTargetException -
executeClassMethod
public static Object executeClassMethod(Class<?> clazz, String methodName, Object... args) throws NoSuchMethodException, SecurityException, IllegalAccessException, IllegalArgumentException, InvocationTargetException, InstantiationException
-