//
http://forums.hibernate.org/viewtopic.p ... 190cfc4e60
// Danger Will Robinson... this does not support multiple
// class references across the OneToOne relationship, Dr. Hack
Class returnType = readMethod.getReturnType();
String ognlUsableProperty = "";
for ( int i = 0; i < returnType.getDeclaredMethods().length; i++ ) {
if ( returnType.getDeclaredMethods()[i].getReturnType().equals(propertyField.getDeclaringClass()) ) {
Method theProperty = returnType.getDeclaredMethods()[i];
ognlUsableProperty = org.trails.component.Utils.unCamelCase(theProperty.getName()).substring(3); // strips preceding 'get'
break;
}
}