Confusion about DAO in Three-Tier Architecture!

engineering , dao , three , tier , architecture , software Karāchi, Pakistan
  • 7 years ago

    Hello all! Dear Members my question is related to Software-engineering approach about DAO (Data Access Object) in three tier architecture. Am a student and as for the final project of my course I had to develop a three tier web based application.. the approach I choose for my project was I divided my classes into three layers as required by the architecture including a DAO Control class. and my DAO class has only one function which takes query as in string format from Entity classes and then return the result Set of that query in return.

    ->* public ResultSet getConnected(String query, int qType) { ... }*

    but one of my supervisor said that architecture demands the DAO should be independent from any external interference and the way you are providing query from outside is violating that rule so either store all the queries inside DAO or inherit all the class from DAO.

    but I m still a bit confused about it that how it violates the rule and what is is ideal scenario in which DAO shld be used.

Post a reply

No one has replied yet! Why not be the first?

Sign in or Join us (it's free).

Contribute

Why not write for us? Or you could submit an event or a user group in your area. Alternatively just tell us what you think!

Our tools

We've got automatic conversion tools to convert C# to VB.NET, VB.NET to C#. Also you can compress javascript and compress css and generate sql connection strings.

“Some people, when confronted with a problem, think "I know, I’ll use regular expressions." Now they have two problems.” - Jamie Zawinski