• 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
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Doubt about Self Test Chapter 10, Question 8 (CH10Q8, K&B7)

 
Ranch Hand
Posts: 41
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
chapter 10, self-test question 8
the class doesn't have a plain get() method only findAll(). in this form is this a complete DAO pattern? in my understanding statement III is correct, so eventually the answer should be E?

(This post originated in the K&B7 errata thread)
 
Sheriff
Posts: 11604
178
Hibernate jQuery Eclipse IDE Spring MySQL Database AngularJS Tomcat Server Chrome Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

J Deckarm wrote:the class doesn't have a plain get() method only findAll(). in this form is this a complete DAO pattern? in my understanding statement III is correct, so eventually the answer should be E?


I don't think a DAO must have a specific set of methods. A DAO is about retrieving and storing data. It provides some specific data operations, but there is no requirement about which data operations it should have. And using this class you can retrieve data (using findAll) and manipulate data (using create, update, and delete methods), so that's valid for a data access object. So although most interfaces will have a get method, it's not a requirement.

Hope it helps!
Kind regards,
Roel
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic