Class TokenInfoRecordMap


  • public class TokenInfoRecordMap
    extends Object
    This tracks TokenInfoRecord by their client and transaction id, since we need to manage them both ways. This is intended to be used by the token info endpoint to accumulate

    Created by Jeff Gaynor
    on 3/21/22 at 8:28 AM

    • Constructor Detail

      • TokenInfoRecordMap

        public TokenInfoRecordMap()
    • Method Detail

      • getByTID

        public List<TokenInfoRecord> getByTID​(edu.uiuc.ncsa.security.core.Identifier transactionID)
        For a given transaction id, get all of the token records.
        Parameters:
        transactionID -
        Returns:
      • getByClientID

        public List<TokenInfoRecord> getByClientID​(edu.uiuc.ncsa.security.core.Identifier clientID)
        Get all of the token records associated with this client id. You must separate them out by transaction id.
        Parameters:
        clientID -
        Returns:
      • containsClient

        public boolean containsClient​(edu.uiuc.ncsa.security.core.Identifier clientID)
        Returns true if this client has a TokenInfoRecord.
        Parameters:
        clientID -
        Returns:
      • getClientIDs

        public Set<edu.uiuc.ncsa.security.core.Identifier> getClientIDs()
        get the set of all client ids
        Returns:
      • getTransactionIDs

        public Set<edu.uiuc.ncsa.security.core.Identifier> getTransactionIDs()
        Gets the set of all transaction ids.
        Returns:
      • getClientID

        public edu.uiuc.ncsa.security.core.Identifier getClientID​(edu.uiuc.ncsa.security.core.Identifier tID)
        Given the transaction id, find the corresponding token id.
        Parameters:
        tID -
        Returns:
      • remove

        public void remove​(edu.uiuc.ncsa.security.core.Identifier clientID)
        removes all the token info records associated with this client.
        Parameters:
        clientID -
      • reduceTo

        public void reduceTo​(Set<edu.uiuc.ncsa.security.core.Identifier> clientIDs)
        Remove all identifiers except the ones in the list
        Parameters:
        clientIDs -
      • sortByClientID

        public Map<edu.uiuc.ncsa.security.core.Identifier,​List<TokenInfoRecord>> sortByClientID​(edu.uiuc.ncsa.security.core.Identifier clientID)
        returns a map of all tokens associated with the transaction id. The key is the transaction ID.
        Parameters:
        clientID -
        Returns: