Interface LicenseKeyPermissionRepository
- All Superinterfaces:
org.springframework.data.repository.CrudRepository<LicenseKeyPermission,,LicenseKeyPermissionID> org.springframework.data.jpa.repository.JpaRepository<LicenseKeyPermission,,LicenseKeyPermissionID> org.springframework.data.repository.ListCrudRepository<LicenseKeyPermission,,LicenseKeyPermissionID> org.springframework.data.repository.ListPagingAndSortingRepository<LicenseKeyPermission,,LicenseKeyPermissionID> org.springframework.data.repository.PagingAndSortingRepository<LicenseKeyPermission,,LicenseKeyPermissionID> org.springframework.data.repository.query.QueryByExampleExecutor<LicenseKeyPermission>,org.springframework.data.repository.Repository<LicenseKeyPermission,LicenseKeyPermissionID>
@Repository
public interface LicenseKeyPermissionRepository
extends org.springframework.data.jpa.repository.JpaRepository<LicenseKeyPermission,LicenseKeyPermissionID>
Repository class for
LicenseKeyPermission.- Since:
- 1.0.0
- Author:
- Sagar Mahapatra
-
Method Summary
Modifier and TypeMethodDescriptionfindByLicenseKey(String licenseKey) Method to find license key permissions by license key.intupdatePermissionList(String updatedPermissionString, String licenseKey, LocalDateTime updationTime, String updatedBy) Method to update license key permissions.Methods inherited from interface org.springframework.data.repository.CrudRepository
count, delete, deleteAll, deleteAll, deleteAllById, deleteById, existsById, findById, saveMethods inherited from interface org.springframework.data.jpa.repository.JpaRepository
deleteAllByIdInBatch, deleteAllInBatch, deleteAllInBatch, deleteInBatch, findAll, findAll, flush, getById, getOne, getReferenceById, saveAllAndFlush, saveAndFlushMethods inherited from interface org.springframework.data.repository.ListCrudRepository
findAll, findAllById, saveAllMethods inherited from interface org.springframework.data.repository.ListPagingAndSortingRepository
findAllMethods inherited from interface org.springframework.data.repository.PagingAndSortingRepository
findAllMethods inherited from interface org.springframework.data.repository.query.QueryByExampleExecutor
count, exists, findAll, findBy, findOne
-
Method Details
-
findByLicenseKey
Method to find license key permissions by license key.- Parameters:
licenseKey- the license key for which permission needs to be fetched.- Returns:
- the license key entity.
-
updatePermissionList
@Modifying @Query("UPDATE LicenseKeyPermission p SET p.permission =?1, p.updatedDateTimes =?3, p.updatedBy=?4 WHERE p.licenseKey =?2") int updatePermissionList(String updatedPermissionString, String licenseKey, LocalDateTime updationTime, String updatedBy) Method to update license key permissions.- Parameters:
updatedPermissionString- the updated permission list.licenseKey- the license key.updationTime- the time at which the list is updated.updatedBy- the list updated by.- Returns:
- the permission entity response.
-