Hi anyone!
I consider this a common problem, yet i could not find any answers so far.
I want to map a class which has a member that is declared as an association to a 3rd party interface:
Code:
public class MyClass {
public Unmapped3rdPartyInterface getMember() {...}
}
That interface is not mapped but my custom implementations of that interface are. I know that this is somehow dangerous because that member could possibly reference an unmapped implementation. But this is how the design is, independent from any persistence considerations.
The only solution I could find so far is using 'any' but the documentation of the @Any-Annotation somehow discourages the usage. Is there a common approach to such kind of problems?
Thanks a lot in advance!