Map map = new HashMap();
Method[] methods = clazz.getMethods();
for (Method method : methods) {
// assumes that the properties are unique within a frame
Property property = method.getAnnotation(Property.class);
if (property != null && method.getName().startsWith("get")) {
map.put(property.value(), method.invoke(obj, null));
}
}
extensionResponse = ExtensionResponse.ok(map);
} catch (Exception x) {