Hibernate version:
3.0.3
Mapping documents:
Code:
...
<property
name="eMail"
column="eMail"
type="string"
not-null="true"
>
</property>
...
Full stack trace of any exception that occurs:18:44:16,234 ERROR [STDERR] org.hibernate.PropertyNotFoundException: Could not find a getter for eMail in class suporte.Contato
at org.hibernate.property.BasicPropertyAccessor.createGetter(BasicPropertyAccessor.java:213)
problemthe cvs version is generating the class code as:
Code:
public String getEMail() {
return this.eMail;
}
public void setEMail(String eMail) {
this.eMail = eMail;
}
But it can't be found by hibernate, becouse it doesn't follow an obscure catch in the java beans specification, that a property that has the first letter lowercase and the second letter uppercase should have set/get methods starting by lowercase too.
So I just rewrite my class with
geteMail instead of
getEMail ...
Code:
public String geteMail() {
return this.eMail;
}
public void seteMail(String eMail) {
this.eMail = eMail;
}
Them all works. If I'm right, I can fill a bug request :)
Thanks