Why would you desing a J2EE application so user data is
entered by way of a JSP page and managed by an underlying
Java Beans class?

Answer Posted / tarun tyagi

See if you are still writing applications that use
data-aware GUI components to interface directly with the
database, you might want to reconsider. Applications built
in this manner are not object oriented. Such two-layer
(GUI/Database) applications violate one of the primary
principles of object-oriented design: encapsulation.

Encapsulation is what allows a client to interact with an
object without knowledge of its implementation details, a
primary premise for loose coupling. In applications that use
data-aware widgets, the opposite is the case. The client and
the database are very tightly coupled. GUI code, business
logic, and SQL statements are all interwoven throughout the
application source code. As a result, the application can
become a maintenance nightmare. Any changes in the database
schema will surely cascade into unexpected failures.

Thats why we design a J2EE application so user data is
entered by way of a JSP page and managed by an underlying
Java Beans class

Is This Answer Correct ?    10 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Under what conditions is an object’s finalize() method invoked by the garbage collector?

583


Describe how to implement singleton design pattern in struts.

539


What is a top level class in java?

543


How can you write a loop indefinitely in java programming?

562


Can one thread block the other thread?

615






Why is a string immutable?

550


How to sort list of list in java?

673


Write code to implement bubble sort in java?

564


Will the compiler creates a default constructor if I have a parameterized constructor in the class?

589


What is the purpose of finalization in java programming?

574


How do I remove a character from a string in java?

514


what is the difference between thread and runnable types? : Java thread

554


Is array synchronized in java?

561


What is an array length?

510


Explain the features of interfaces in java?

561