The moose likes Struts and the fly likes Struts2 annotation validation Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Java Interview Guide this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Struts2 annotation validation" Watch "Struts2 annotation validation" New topic

Struts2 annotation validation

Mohammed Ali Khan

Joined: Apr 20, 2010
Posts: 1
Dear All
i want to ask a simple question
struts2 says that any POJO can be an action class but when we use any validation technique provided by struts2 we have to extend ActionSupport class which makes our POJO framework dependent and we all know that in almost every case when we develope a screen we require validation if is it so then we have to make our POJO extend ActionSupport class then what is the mean "any POJO can be action class" is there any alternative of instead of extending ActionSupport and i can use validation


Muhammad Ali Khan
Associate Software Engineer
i2c inc. Lahore, Pakistan
92-42-111000911, ext. 155
Mobile: +92 3214335049

David Newton

Joined: Sep 29, 2008
Posts: 12617

Any action *can* be a POJO--with the caveat that you'll lose out on the default implementation of framework functionality.

You could implement the parts you need yourself.
I agree. Here's the link:
subject: Struts2 annotation validation
jQuery in Action, 3rd edition