Hi.
Is there a spec-compliant way to map simple collections?
Like this one:
public List<String> anyURI;
Currently I have to simulate a collection of entities:
@OneToMany(cascade = {
CascadeType.ALL
})
public List<SimpleCollectionTypesType.AnyURIItem> anyURIItems;
@Entity
@Inheritance(strategy = InheritanceType.JOINED)
public static class AnyURIItem
implements Item<String> , Equals, HashCode
{
@Basic
public String value;
@Id
@GeneratedValue(strategy = GenerationType.SEQUENCE)
public Long hjid;
public boolean equals(Object object) { ... }
public void hashCode(HashCodeBuilder hashCodeBuilder) {
hashCodeBuilder.append(this.getValue());
}
public int hashCode() { ... }
}
But this is quite awkward.
Bye.
/lexi