Class UIClientService


  • @Component
    public class UIClientService
    extends java.lang.Object
    UI Service to handle IRIDA Clients
    • Constructor Detail

      • UIClientService

        public UIClientService​(IridaClientDetailsService clientDetailsService,
                               org.springframework.context.MessageSource messageSource)
    • Method Detail

      • getClientList

        public TableResponse<ClientTableModel> getClientList​(ClientTableRequest tableRequest)
        Get a listing of clients based on the table request.
        Parameters:
        tableRequest - Information about the sort and page of the table.
        Returns:
        Current status of the table
      • deleteClientTokens

        public void deleteClientTokens​(java.lang.Long id)
        Revoke all tokens for a specific client
        Parameters:
        id - Identifier for a client
      • validateClientId

        public void validateClientId​(java.lang.String clientId)
                              throws EntityNotFoundException
        Validate a client identifier for a new client
        Parameters:
        clientId - Identifier to check to see if it exists
        Throws:
        EntityNotFoundException - thrown if a client does not exist with the given client id.
      • createOrUpdateClient

        public java.lang.String createOrUpdateClient​(CreateUpdateClientDetails request,
                                                     java.util.Locale locale)
                                              throws EntityExistsException,
                                                     javax.validation.ConstraintViolationException
        Create a new client
        Parameters:
        request - Details about the new client
        locale - Current users Locale
        Returns:
        A message to the user about the result of the create/update
        Throws:
        EntityExistsException - thrown if the client id already is used.
        javax.validation.ConstraintViolationException - thrown if the client id violates any of its constraints
      • deleteClient

        public void deleteClient​(java.lang.Long id)
        Delete a client
        Parameters:
        id - Identifier for the client to delete
      • regenerateClientSecret

        public void regenerateClientSecret​(java.lang.Long id)
        Generate a new client secret
        Parameters:
        id - identifier for a client