• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Tim Cooke
  • Paul Clapham
  • Jeanne Boyarsky
Sheriffs:
  • Ron McLeod
  • Frank Carver
  • Junilu Lacar
Saloon Keepers:
  • Stephan van Hulst
  • Tim Moores
  • Tim Holloway
  • Al Hobbs
  • Carey Brown
Bartenders:
  • Piet Souris
  • Frits Walraven
  • fred rosenberger

design patterns

 
Ranch Hand
Posts: 60
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
A developer has created a web application that includes a servlet for each use case int the application.These servlets have become rather difficult to maintain because the request processing methods have become very large.There is also common processing code in many servlets because these use cases are very similar.

Which two design patterns can be used together to refactor and simplify this web application?
A.Proxy
B.View Helper
C.Front Controller
D.Session facade
E.Business Delegate
F.MVC

I select C and F, correct?
 
Ranch Hand
Posts: 40
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Dear,
after read the question I saw that the answer is structural patterns: Front Controller to center the application control (struts suits good here) and MVC to divide the view to jsp instead in the servlet. I think you are right.
 
Ranch Hand
Posts: 1066
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Nothing has been mentioned about the view, so MVC can be left out.
1. Front Controller to route the different requests.
2. Business delegate as there is plenty of common code.

My answers would be : C and E

Rodrigo: We don't usually use both Front Controller and MVC patterns together. (MVC does Front Controller's job of routing the requests/actions and also has views associated with it).
 
Drove my Chevy to the levee but the levee was dry. A wrung this tiny ad and it was still dry.
Garden Master Course kickstarter
https://coderanch.com/t/754577/Garden-Master-kickstarter
reply
    Bookmark Topic Watch Topic
  • New Topic