Spring web app tutorial 17: Spring Data JPA Paging and sorting

How to use Spring Data JPA for paging, sorting and top-n processing? This will generate SQL "SELECT ... ORDER BY ... LIMIT ...".

How to use Spring Data JPA for paging, sorting and top-n processing? This will generate SQL "SELECT ... ORDER BY ... LIMIT ...".