public static ArrayList<Class<?>> getEnumClasses(Model<?> model)
{
HashSet<Class<?>> enumClasses = new HashSet<Class<?>>();
for(Property p : model.getProperties())
{
PropertyMeta pm = p.getPropertyMeta();
if(pm.isRepeated())
{
if(pm.getComponentTypeClass().isEnum())
enumClasses.add(pm.getComponentTypeClass());
}
else if(pm.getTypeClass().isEnum())
enumClasses.add(pm.getTypeClass());
}
ArrayList<Class<?>> classes = new ArrayList<Class<?>>(enumClasses);
Collections.sort(classes, new Comparator<Class<?>>(){
public int compare(Class<?> c, Class<?> c2)
{