wood burning stoves*
The moose likes Struts and the fly likes Struts 1 VS Struts 2 Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Struts 1 VS Struts 2" Watch "Struts 1 VS Struts 2" New topic
Author

Struts 1 VS Struts 2

vipul bondugula
Ranch Hand

Joined: Oct 14, 2010
Posts: 218
Hi ranchers,

Strus1 Vs Struts 2

The above URL tells about struts 1 vs struts 2.

First difference i did not get...

It is given "Struts 1 requires Action classes to extend an abstract base class. A common problem in Struts 1 is programming to abstract classes instead of interfaces"

I never coded by extending abstract classes. ActionServlet , Action, ActionForm etc are not abstract classes.. why did the person mention abstract classes , i don't get it.

Do any of ranchers have any explanation for this.

Thanks BVR.


Thanks
Vipul Kumar
Joe Ess
Bartender

Joined: Oct 29, 2001
Posts: 8708
    
    6

vipul bondugula wrote:
Do any of ranchers have any explanation for this.


I can't explain why they used the term "abstract". Suffice to say, Struts 1 requires an action class to extend Action. Struts 2 allows one to use any POJO.


"blabbing like a narcissistic fool with a superiority complex" ~ N.A.
[How To Ask Questions On JavaRanch]
vipul bondugula
Ranch Hand

Joined: Oct 14, 2010
Posts: 218
Thanks for your reply Joe.

In the apache site also they did mention the same. They simply don't use the term abstract. There must be some explanation..

why do they mislead us...

Thanks
BVR.
Mohana Rao Sv
Ranch Hand

Joined: Aug 01, 2007
Posts: 485

IMHO Struts 1.2 is class driven but the framework should be an interface driven(according to the proper design) so that we can extend some other classes

Struts 2.0 is interface driven we can write without using interface or with interface or with a class


ocjp 6 — Feeding a person with food is a great thing in this world. Feeding the same person by transferring the knowledge is far more better thing. The reason is the amount of satisfaction which we get through food is of only one minute or two. But the satisfaction which we can get through the knowledge is of life long.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Struts 1 VS Struts 2
 
Similar Threads
Abstract vs. Interface
Struts Vs Spring
abstract Vs interface
JSF Vs JSP Vs JSTL
struts vs spring framework