Created
March 22, 2016 20:11
-
-
Save MafaldaLandeiro/d6f33780197959c23f2a to your computer and use it in GitHub Desktop.
Country repository
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package org.CachingDataSpring; | |
| import java.util.List; | |
| import org.springframework.cache.annotation.Cacheable; | |
| import org.springframework.data.repository.CrudRepository; | |
| public interface CountryRepository extends CrudRepository<Country, Integer> { | |
| @Cacheable("countries") | |
| List<Country> findByCurrency(String currency); | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment