Interface JpaDao

All Known Implementing Classes:
JpaDaoImpl

public interface JpaDao
  • Method Details

    • findById

      @Deprecated <T extends BaseEntity> T findById(String type, Long id)
      Deprecated.
    • findById

      <T extends BaseEntity> T findById(Class<T> clazz, Long id)
    • getEntityGraph

      <T> jakarta.persistence.EntityGraph<? super T> getEntityGraph(Class<T> clazz, String name)
    • applyGraph

      <T> void applyGraph(jakarta.persistence.criteria.Root<T> root, jakarta.persistence.EntityGraph<? super T> fetchGraph)
    • applyGraph

      <T> void applyGraph(Class<T> clazz, jakarta.persistence.criteria.Root<T> root, String fetchGraph)
    • getCount

      Long getCount(Class<?> clazz)
    • getCount

      <T> Long getCount(Class<T> entityClass, org.springframework.data.jpa.domain.Specification<T> specification)
    • save

      <T> T save(Object entity)
    • saveAll

      <T> List<T> saveAll(List<T> entities)
    • evict

      <T extends BaseEntity> T evict(T o)
    • flush

      void flush()
    • refresh

      void refresh(AbstractEntity o)
    • delete

      void delete(AbstractEntity o)
    • delete

      <T extends BaseEntity> T delete(Class<T> clazz, Long id)
    • delete

      <T> int delete(Class<T> entityClass, org.springframework.data.jpa.domain.Specification<T> spec)
    • update

      <T> int update(Class<T> entityClass, org.springframework.data.jpa.domain.Specification<T> spec, UpdateSpecification<T> updateSpec)
    • getList

      <T> List<T> getList(Class<T> clazz)
    • getList

      @Deprecated <T, X> List<T> getList(Class<T> clazz, jakarta.persistence.metamodel.SingularAttribute<T,X> name, X value)
      Deprecated.
    • getList

      <T> List<T> getList(Class<T> entityClass, org.springframework.data.jpa.domain.Specification<T> specification)
    • getPage

      <R, T> ResultPage<T> getPage(Class<R> rootClass, Class<T> targetClass, Selector<R,T> selector, org.springframework.data.jpa.domain.Specification<R> specification, PageSpecification page)
    • getPage

      <T> ResultPage<T> getPage(Class<T> entityClass, org.springframework.data.jpa.domain.Specification<T> specification, PageSpecification page)
    • getStream

      <T> Stream<T> getStream(Class<T> entityClass, org.springframework.data.jpa.domain.Specification<T> specification)
    • getStream

      <R, T> Stream<T> getStream(Class<R> rootClass, Class<T> targetClass, Selector<R,T> selector, org.springframework.data.jpa.domain.Specification<R> specification)
    • getList

      <R, T> List<T> getList(Class<R> rootClass, Class<T> targetClass, Selector<R,T> selector, org.springframework.data.jpa.domain.Specification<R> specification)
    • getSingleResult

      <T> T getSingleResult(Class<T> entityClass, org.springframework.data.jpa.domain.Specification<T> specification)
    • fetchBySpecification

      <T extends BaseEntity> T fetchBySpecification(Class<T> entityClass, org.springframework.data.jpa.domain.Specification<T> specification)
    • getSingleResult

      <R, T> T getSingleResult(Class<R> rootClass, Class<T> targetClass, Selector<R,T> selector, org.springframework.data.jpa.domain.Specification<R> specification)
    • getSingleResultOrNull

      <T> T getSingleResultOrNull(Class<T> entityClass, org.springframework.data.jpa.domain.Specification<T> specification)
    • getSingleResultOrNull

      <R, T> T getSingleResultOrNull(Class<R> rootClass, Class<T> targetClass, Selector<R,T> selector, org.springframework.data.jpa.domain.Specification<R> specification)
    • getFirstResultOrNull

      <T> T getFirstResultOrNull(Class<T> entityClass, org.springframework.data.jpa.domain.Specification<T> specification)
    • getFirstResultOrNull

      <R, T> T getFirstResultOrNull(Class<R> rootClass, Class<T> targetClass, Selector<R,T> selector, org.springframework.data.jpa.domain.Specification<R> specification)
    • exists

      <T> boolean exists(Class<T> entityClass, org.springframework.data.jpa.domain.Specification<T> specification)
    • getListByIds

      <T> List<T> getListByIds(Class<T> clazz, List<Long> ids)
    • saveWithCompositeKey

      @Deprecated void saveWithCompositeKey(EmbeddedKeyable o)
      Deprecated.
    • deleteWithCompositeKey

      @Deprecated void deleteWithCompositeKey(EmbeddedKeyable o)
      Deprecated.
    • getIds

      @Deprecated <T> List<Long> getIds(Class<T> entityClazz, org.springframework.data.jpa.domain.Specification<T> searchSpec)
      Deprecated.
    • clear

      void clear()
    • lock

      void lock(AbstractEntity entity, jakarta.persistence.LockModeType lockMode, int timeout)
    • lockAndRefresh

      void lockAndRefresh(AbstractEntity entity, int timeout)
    • revert

      void revert(AbstractEntity entity)
    • selectNativeQuery

      @Deprecated <T> List<T> selectNativeQuery(Class<T> entityClazz, String sql, Map<String,Object> params)
      Deprecated.
    • getEntityType

      <T> jakarta.persistence.metamodel.EntityType<T> getEntityType(Class<T> cls)