Closed spring-projects-issues closed 11 years ago
Michael Hunger commented
Does this workaround work for you? I think we don't support extending collection classes as entities which is a dangerous design anyway. Better encapsulate the set in a "Collections" object
Michael Hunger commented
Oh and indexed collections are not supported / represented in the graph (aka we don't store any order right now). That's why the set semantics is the maximum you can get. And List support is only there for convenience
Michael Hunger commented
See comments
David Gommeren opened DATAGRAPH-373 and commented
If I have:
@RelationshipEntity
public class IndexedRelation\@EndNode
@Fetch
private E endNode; ...and
public class IndexedCollection\ extends LinkedHashSet<IndexedRelation\> { ...
I can't do:
@RelatedToVia
(type = "attributes")@Fetch
private IndexedCollection\Runtime error: Caused by: org.springframework.data.mapping.model.MappingException: Relationship field with RelationshipEntity class nl.abacus.pim.meta.core.model.blueprint.AttributeDef annotated with
@RelatedToVia
I have to add the RelationshipEntity in the generics, e.g.: public class IndexedCollection<IndexedRelation,E> extends LinkedHashSet ...
Affects: 2.2.1