Win a copy of The Way of the Web Tester: A Beginner's Guide to Automating Tests this week in the Testing forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

XDoclet (EJBDoclet) - value of VO / DAO tasks?

Tim West
Ranch Hand
Posts: 539
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all,

I'm currently using XDoclet for EJB artefact generation to keep myself sane. I'm a big fan of code generation where practical - and the EJB area is certainly a prime candidate.

I'm wondering if anyone actually uses the VO/DAO tasks. In my current project (a small uni research project, so I'm free to use whatever technology I want), I've used the VO task. However, I'm now considering removing this, as I want my VOs to have some internal business logic. This would be nothing complex, just things like 'isAdult()', 'isDrivableAge()' on a customer - things that really (in a pure OO sense) must be part of the customer object. Using EJBDoclet to generate the VOs prevents me from doing this.

Has anyone else encountered this? Any recommendations? My current plan is to hand write my VO classes, and then manually write the setVO() and getVO() methods in the entity bean implementation class. It's more handwritten code, but it allows me to keep my VOs (which are used throughout the system) exactly how I want them.

I'd love to buy a book on XDoclet, as the online doco is rather scarce, but I'm a student... :-\. I should also add that I've checked out the only decent online document I've found, here:


  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic