I'm having problems trying to map certain properties.
Having a class with a property named
nChilds and public getter/setter:
Code:
public class Test {
private int nChilds;
....
public int getNChilds() { return nChilds; }
public void setNChilds(int nChilds) { this.nChilds = nChilds; }
....
}
The property is mapped as:
Code:
<property name="nChilds" not-null="true"/>
And I get the exception:
Code:
org.hibernate.PropertyNotFoundException: Could not find a getter for nChilds in class ar.com.itboss.Test
When I replace all occurrences of
nChilds to other name, like
numberChilds it works. It seems the problem is when the property name is composed of several words and the first one is only a letter long. Why can't I map a property named like this?
The hibernate version I'm using is 3.0.5.