Class SongsServiceImpl
java.lang.Object
info.ejava.examples.db.jpa.songs.svc.SongsServiceImpl
- All Implemented Interfaces:
SongsService
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncreateSong
(SongDTO songDTO) void
void
deleteSong
(int id) org.springframework.data.domain.Page
<SongDTO> findReleasedAfter
(LocalDate afterDate, org.springframework.data.domain.Pageable pageable) org.springframework.data.domain.Page
<SongDTO> findSongsMatchingAll
(SongDTO probeDTO, org.springframework.data.domain.Pageable pageable) getSong
(int id) org.springframework.data.domain.Page
<SongDTO> getSongs
(org.springframework.data.domain.Pageable pageable) void
updateSong
(int id, SongDTO songDTO)
-
Field Details
-
mapper
-
songsRepo
-
-
Constructor Details
-
SongsServiceImpl
public SongsServiceImpl()
-
-
Method Details
-
createSong
- Specified by:
createSong
in interfaceSongsService
-
getSongs
public org.springframework.data.domain.Page<SongDTO> getSongs(org.springframework.data.domain.Pageable pageable) - Specified by:
getSongs
in interfaceSongsService
-
getSong
- Specified by:
getSong
in interfaceSongsService
-
getRandomSong
- Specified by:
getRandomSong
in interfaceSongsService
-
updateSong
- Specified by:
updateSong
in interfaceSongsService
-
deleteSong
@Transactional(propagation=REQUIRED) public void deleteSong(int id) - Specified by:
deleteSong
in interfaceSongsService
-
findReleasedAfter
public org.springframework.data.domain.Page<SongDTO> findReleasedAfter(LocalDate afterDate, org.springframework.data.domain.Pageable pageable) - Specified by:
findReleasedAfter
in interfaceSongsService
-
deleteAllSongs
@Transactional(propagation=REQUIRED) public void deleteAllSongs()- Specified by:
deleteAllSongs
in interfaceSongsService
-
findSongsMatchingAll
@Transactional(propagation=SUPPORTS) public org.springframework.data.domain.Page<SongDTO> findSongsMatchingAll(SongDTO probeDTO, org.springframework.data.domain.Pageable pageable) - Specified by:
findSongsMatchingAll
in interfaceSongsService
-