Here it is
store collection basic types, custom types, components and references to other entities
Example:
Code:
public class Person {
private Long personId;
private Collection<String> names;
public Long setPersonId(Long personId){
this.personId = personId;
}
public Long getPersonId(Long personId){
return this.personId;
}
public Collection<String> getNames() {
return names;
}
public void setNames(Collection<String> names) {
this.names = names;
}
}
Mapping fileQuote:
<bag name="names"
table="name"
lazy="true"
<key column="personid"/>
<element column="name" type="string"/>
</bag>
POST is closed