Interface DataStore


public interface DataStore
Interface which needs to be implemented to use with OAuthClient implementations. Wraps whatever mechanism the implementing product chooses to support storage of state information for the lifespan of an OAuth-based session.
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns the provider that the associated DataStore implementation has been instantiated for.
    Returns the stored data.
    void
    Stores the data.
  • Method Details

    • getProvider

      String getProvider() throws OAuthException
      Returns the provider that the associated DataStore implementation has been instantiated for.
      Returns:
      provider name.
      Throws:
      OAuthException - when an error occurs while retrieving the provider name.
    • storeData

      void storeData(JsonValue data) throws OAuthException
      Stores the data.
      Parameters:
      data - the data to be stored.
      Throws:
      OAuthException - when an error occurs while trying to store the data.
    • retrieveData

      JsonValue retrieveData() throws OAuthException
      Returns the stored data.
      Returns:
      the data that is currently stored in the the data store.
      Throws:
      OAuthException - when an error occurs while retrieving the data.