openjpa-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From stlecho <stle...@gmail.com>
Subject Re: ArgumentException when using generics
Date Wed, 19 May 2010 10:39:46 GMT

When using OpenJPA v2.0.0 and the OpenJPA Agent for Runtime Enhancement, I've
been able to make it work :o). The modifications I had to do are listed
below.

When switching back to OpenJPA v1.2.2 and leaving out the OpenJPA Agent for
Runtime Enhancement the modified code does not work :o(.

Unfortunately, the v2.0.0 is not (yet) a standard within the company I'm
working so I can not use it.
Would it be possible to fix this issue in the v1.2.x version of OpenJPA ?

Non-working version
[code]
public class ViesMessage<RESP extends ViesResponse> extends IdentityObject {
	@OneToMany(cascade=CascadeType.ALL,
mappedBy="message",targetEntity=VATRResponse.class)
	protected List<RESP> responses;
[/code]

Working version
[code]
public abstract class ViesMessage<RESP extends ViesResponse> extends
IdentityObject {
	@OneToMany(cascade=CascadeType.ALL)
	protected List<RESP> responses;
[/code]

-- 
View this message in context: http://openjpa.208410.n2.nabble.com/ArgumentException-when-using-generics-tp5073975p5074351.html
Sent from the OpenJPA Users mailing list archive at Nabble.com.

Mime
View raw message