Interface TokenStore

All Known Implementing Classes:
MemoryTokensStorage

public interface TokenStore
Interface for long term storage of tokens
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    Remove the token data from storage for the given ID.
    Load the token data from storage for the given ID.
    void
    store(String id, String tokens)
    Put the token data into storage for the given ID.
  • Method Details

    • load

      String load(String id) throws IOException
      Load the token data from storage for the given ID.
      Parameters:
      id - ID of token data to load.
      Returns:
      The loaded token data.
      Throws:
      IOException - An error loading the token data from storage.
    • store

      void store(String id, String tokens) throws IOException
      Put the token data into storage for the given ID.
      Parameters:
      id - ID of token data to store.
      tokens - The token data to store.
      Throws:
      IOException - An error storing the token data.
    • delete

      void delete(String id) throws IOException
      Remove the token data from storage for the given ID.
      Parameters:
      id - ID of token data to store.
      Throws:
      IOException - An error storing the token data.