Loading…

Flash Player 9 (or above) is needed to view presentations.
We have detected that you do not have it on your computer. To install it, go here.

Like this presentation? Why not share!

Generic DAOs With Hades

on

  • 5,168 views

Slides from the talk on the open source project Hades - http://hades.synyx.org

Slides from the talk on the open source project Hades - http://hades.synyx.org

Statistics

Views

Total Views
5,168
Views on SlideShare
4,923
Embed Views
245

Actions

Likes
3
Downloads
59
Comments
0

6 Embeds 245

http://rtiweb.net 126
http://revolucaojava.rtiweb.net 80
http://www.slideshare.net 32
http://www.linkedin.com 4
url_unknown 2
http://translate.googleusercontent.com 1

Accessibility

Categories

Upload Details

Uploaded via as Adobe PDF

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment

    Generic DAOs With Hades Generic DAOs With Hades Presentation Transcript

    • Hades Oliver Gierke - Synyx GmbH & Co. KG „Simple things should be simple, complex things should be possible.“ Alan Kay
    • Speaker ■ Oliver Gierke - gierke@synyx.de ■ Software Architect @ Synyx GmbH & Co. KG ■ JavaEE, Spring (beyond the obvious) ■ Financial industry, automotive ■ Hades project lead www.devoxx.com ■ olivergierke
    • Java Persistence API
    • CRUD GenericDao GenericJpaDao www.devoxx.com
    • Demo I www.devoxx.com
    • Query methods
    • 1. Create interface 2. Declare methods 3. Tune queries www.devoxx.com
    • CRUD Query methods GenericDao UserDao GenericJpaDao GenericDaoFactory / GenericDaoFactoryBean www.devoxx.com
    • User findByUsername( String username); Derive
    • @NamedQuery (name=“User.findByLastname“ query=“...“) List<User> findByLastname(...); Named Query
    • @Query(„from User u where ...“) List<User> findByLastname(...); @Query
    • Demo II www.devoxx.com
    • Pagination Sorting
    • @Query(„from User u where u.lastname = ?“) Page<User> findByLastname( String lastname, Pageable pageable);
    • @Param(„name“)
    • @Query(„from User u where u.lastname = :lastname or u.firstname = :firstname“) List<User> findByLastOrFirstname( @Param(„lastname“) String lname, @Param(„firstname“) String fname)
    • @Modifying
    • @Modifying @Query(„...“) int undefaultAllBut(Role role);
    • Spring integration
    • <hades:dao-config base-package=“foo.**.dao“ />
    • Spring IDE Plugin
    • Custom DAO code
    • Custom CRUD Query methods implementation GenericDao UserDao UserDaoCustom GenericJpaDao UserDaoImpl GenericDaoFactory / GenericDaoFactoryBean www.devoxx.com
    • Demo III www.devoxx.com
    • Additional support
    • Auditing
    • Created? Modified? Who? When?
    • Domain base classes
    • WTF Questions?
    • Meta stuff ■ Current version: 1.0 (stable 1.1-snapshot) ■ Apache license 2.0 ■ http://hades.synyx.org www.devoxx.com