Interface PermissionRepo

All Superinterfaces:
org.springframework.data.repository.CrudRepository<Permission,UUID>, GenericRepo<Permission,UUID>, org.springframework.data.jpa.repository.JpaRepository<Permission,UUID>, org.springframework.data.repository.ListCrudRepository<Permission,UUID>, org.springframework.data.repository.ListPagingAndSortingRepository<Permission,UUID>, org.springframework.data.repository.PagingAndSortingRepository<Permission,UUID>, org.springframework.data.repository.query.QueryByExampleExecutor<Permission>, org.springframework.data.repository.Repository<Permission,UUID>

@Repository public interface PermissionRepo extends GenericRepo<Permission,UUID>
Repository interface for managing Permission entities.

Extends GenericRepo to inherit common CRUD operations and defines additional queries for permission-specific operations.

See Also:
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    Checks whether a permission with the specified name exists.
    findByPermissionName(String permissionName)
    Retrieves a permission by their permission name.

    Methods inherited from interface org.springframework.data.repository.CrudRepository

    count, delete, deleteAll, deleteAll, deleteAllById, deleteById, existsById, findById, save

    Methods inherited from interface com.alpaca.repository.GenericRepo

    countByIds

    Methods inherited from interface org.springframework.data.jpa.repository.JpaRepository

    deleteAllByIdInBatch, deleteAllInBatch, deleteAllInBatch, findAll, findAll, flush, getReferenceById, saveAllAndFlush, saveAndFlush

    Methods inherited from interface org.springframework.data.repository.ListCrudRepository

    findAll, findAllById, saveAll

    Methods inherited from interface org.springframework.data.repository.ListPagingAndSortingRepository

    findAll

    Methods inherited from interface org.springframework.data.repository.PagingAndSortingRepository

    findAll

    Methods inherited from interface org.springframework.data.repository.query.QueryByExampleExecutor

    count, exists, findAll, findBy, findOne
  • Method Details

    • existsByPermissionName

      boolean existsByPermissionName(String permissionName)
      Checks whether a permission with the specified name exists.
      Parameters:
      permissionName - The name of the permission - must not be null.
      Returns:
      true if a permission with the given name exists, false otherwise.
    • findByPermissionName

      Optional<Permission> findByPermissionName(String permissionName)
      Retrieves a permission by their permission name.
      Parameters:
      permissionName - The permission name of the permission - must not be null.
      Returns:
      An Optional containing the permission if found, otherwise empty.