Interface CredentialRepository

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

@Repository public interface CredentialRepository extends org.springframework.data.jpa.repository.JpaRepository<CredentialEntity, Long>
Repository for Credential entities.
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    Check if credential with name exists.
    Find credential by name.
    Find credentials by name containing (search).
    findByType(ai.nervemind.common.enums.CredentialType type)
    Find credentials by type.

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

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

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

    deleteAllByIdInBatch, deleteAllInBatch, deleteAllInBatch, deleteInBatch, findAll, findAll, flush, getById, getOne, 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

    • findByName

      Optional<CredentialEntity> findByName(String name)
      Find credential by name.
      Parameters:
      name - The unique name of the credential
      Returns:
      an Optional containing the entity if found
    • findByType

      List<CredentialEntity> findByType(ai.nervemind.common.enums.CredentialType type)
      Find credentials by type.
      Parameters:
      type - The type of credentials to search for
      Returns:
      a list of matching credentials
    • findByNameContainingIgnoreCase

      List<CredentialEntity> findByNameContainingIgnoreCase(String name)
      Find credentials by name containing (search).
      Parameters:
      name - The name fragment to search for
      Returns:
      a list of matching credentials
    • existsByName

      boolean existsByName(String name)
      Check if credential with name exists.
      Parameters:
      name - The name to check
      Returns:
      true if a credential with this name exists