@Override public Object read(Object serviceImpl) throws Exception { return Reflections.get(field, serviceImpl); }
@Override public Object read(Object serviceImpl) throws Exception { return Reflections.get(field, serviceImpl); }
@Override public Object read(Object serviceImpl) throws Exception { return Reflections.get(field, serviceImpl); }
public static Object getAndWrap(Field field, Object target) { boolean accessible = field.isAccessible(); try { field.setAccessible(true); return get(field, target); } catch (Exception e) { if (e instanceof RuntimeException) { throw (RuntimeException) e; } else { throw new IllegalArgumentException("exception setting: " + field.getName(), e); } } finally { field.setAccessible(accessible); } }