List<JMethod> getterMethods = JClassUtils.getGetterMethods(objectStoreTarget);
for (JMethod method : getterMethods)
{
if (JClassUtils.isSimpleType(method.getReturnType()))
{
Indexed indexed = method.getAnnotation(Indexed.class);
if (indexed != null)
{
String property = JClassUtils.getPropertyForGetterOrSetterMethod(method);
if (!isValidTypeForKey(method.getReturnType()))
{
throw new CruxGeneratorException("Invalid index type for index on method ["+method.getReadableDeclaration()+"]. Crux databases only support Strings, integers, double or dates as part of a key or index");
}
result.add(new IndexData(new String[]{prefix+property}, indexed.unique(), false, prefix+property));
}
}
else
{
String property = JClassUtils.getPropertyForGetterOrSetterMethod(method);