My orm.xml file despite that listing and allowing me to use the `transient` tag to a method, the transient state is not being applied to this method, as it would be if it was on the @Transient. Due to that and I'm getting an error: ``` HHH000474: Ambiguous persistent property methods detected on model.Test; mark one as @Transient : [public java.lang.Boolean model.Test.getDefaultProfile()] and [public java.lang.Boolean model.Test.isDefaultProfile()] : origin(model.Test) ``` And also a warning: ``` WARN: HHH000207: Property model.Test.getDefaultProfile not found in class but described in <mapping-file/> (possible typo error) ``` This is how is my orml.xml, which I was expecting to solve the error with the <transient> tag
<?xml version="1.0" encoding="UTF-8"?>
<entity-mappings version="2.1"
xmlns="http://xmlns.jcp.org/xml/ns/persistence/orm"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://xmlns.jcp.org http://xmlns.jcp.org/xml/ns/persistence/orm_2_1.xsd">
<entity class="model.Test">
<attributes>
<id name="id"/>
<transient name="getDefaultProfile"/>
</attributes>
</entity>
</entity-mappings>
And this is the class, that has a Boolean object on it and has the `get` and `is` implemented on it. And on the real scenario due to being a class from an external dependency, I'm using XML mapping over it:
public class Test {
protected Integer id;
protected Boolean defaultProfile;
public Integer getId() {
return id;
}
public void setId(Integer id) {
this.id = id;
}
public Boolean getDefaultProfile() {
return this.defaultProfile;
}
public Boolean isDefaultProfile() {
return this.defaultProfile;
}
public void setDefaultProfile(Boolean value) {
this.defaultProfile = value;
}
}
And the very off from this is that if I just annotate the class with @Entity that error will not be shown |