Andrew Stevens wrote
> include a class-level @ejb.finder for findByPrimaryKey and set
> its transaction-type parameter.

I finally got around to trying this, and presto. Magic.

Thanks Andrew!

David Harkness
Sony Pictures Digital Networks
(310) 482-4756


-----Original Message-----
From: Andrew Stevens [mailto:[EMAIL PROTECTED] 
Sent: Saturday, August 09, 2003 12:37 AM
To: [EMAIL PROTECTED]
Subject: Re: [Xdoclet-user] Entity Beans, findByPrimaryKey
andtransaction-type


On Sat, 2003-08-09 at 01:39, Harkness, David wrote:
> If you specify a transaction-type class-level tag for an entity bean, 
> it applies the type to the findByPrimaryKey method. I'd like to have a

> default type of "Mandatory", but I want all finders to have type 
> "Supports".
> 
> Is there a method to apply a specific transaction-type to 
> findByPrimaryKey? Since you don't declare a finder for this (it's 
> created automatically), is there another way? Should I add a new tag 
> @ejb.find-by-pk transaction-type="Supports"? Any other suggestions?

A couple that spring to mind; do either of these work for you?
- create an abstract findByPrimaryKey method put an @ejb.transaction on
it.
- include a class-level @ejb.finder for findByPrimaryKey and set its
transaction-type parameter.

Just because the findByPK is auto-generated when it's not there, doesn't
mean you can't include one...


Andrew.



-------------------------------------------------------
This SF.Net email sponsored by: Free pre-built ASP.NET sites including
Data Reports, E-commerce, Portals, and Forums are available now.
Download today and enter to win an XBOX or Visual Studio .NET.
http://aspnet.click-url.com/go/psa00100003ave/direct;at.aspnet_072303_01
/01
_______________________________________________
xdoclet-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/xdoclet-user


-------------------------------------------------------
This SF.Net email sponsored by: Free pre-built ASP.NET sites including
Data Reports, E-commerce, Portals, and Forums are available now.
Download today and enter to win an XBOX or Visual Studio .NET.
http://aspnet.click-url.com/go/psa00100003ave/direct;at.aspnet_072303_01/01
_______________________________________________
xdoclet-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/xdoclet-user

Reply via email to