Created
January 4, 2017 18:40
-
-
Save netodevel/2f5493d4b239ad20a0ff08fdbe40aeb4 to your computer and use it in GitHub Desktop.
This file contains 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 br.com.paydomestic.service; | |
import java.io.Serializable; | |
import java.util.List; | |
public abstract class AbstractService<E, idEntity extends Serializable> implements CrudService<E, idEntity> { | |
@Override | |
public List<E> findAll() { | |
return getRepository().findAll(); | |
} | |
@Override | |
public E findOne(idEntity id) { | |
return getRepository().findOne(id); | |
} | |
@Override | |
public E save(E entity) { | |
return getRepository().save(entity); | |
} | |
@Override | |
public void delete(E entity) { | |
getRepository().delete(entity); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment