Example #1
0
 /**
  * Set a private field to a value using reflection {@link ReflectionHelper#setPrivateValue(Class,
  * Object, String, Object)}
  *
  * @param instanceclass
  * @param instance
  * @param field
  * @param value
  */
 public static <T, E> void setPrivateValue(
     Class<? super T> instanceclass, T instance, String field, E value) {
   ReflectionHelper.setPrivateValue(instanceclass, instance, field, value);
 }
Example #2
0
 /**
  * Get a value from a field using reflection {@link ReflectionHelper#getPrivateValue(Class,
  * Object, String)}
  *
  * @param instanceclass
  * @param instance
  * @param field
  * @return
  */
 public static <T, E> T getPrivateValue(Class<? super E> instanceclass, E instance, String field) {
   return ReflectionHelper.getPrivateValue(instanceclass, instance, field);
 }