Sha256: da5e540906db69c4629e6d42eddb21805128d304c8d771eaa23b3c986a6c1d73

Contents?: true

Size: 524 Bytes

Versions: 66

Compression:

Stored size: 524 Bytes

Contents

module SparkApi
  module Authentication

    class SingleSessionProvider < BaseOAuth2Provider

      def initialize(credentials)
        @access_token = credentials.delete(:access_token)
        super(credentials)
      end

      def load_session
        @session ||= SparkApi::Authentication::OAuthSession.new({
          :access_token => @access_token
        })
      end

      def save_session session
        @session = session
      end

      def destroy_session
        @session = nil
      end

    end
  end
end

Version data entries

66 entries across 66 versions & 1 rubygems

Version Path
spark_api-1.6.3 lib/spark_api/authentication/oauth2_impl/single_session_provider.rb
spark_api-1.6.2 lib/spark_api/authentication/oauth2_impl/single_session_provider.rb
spark_api-1.6.1 lib/spark_api/authentication/oauth2_impl/single_session_provider.rb
spark_api-1.5.7 lib/spark_api/authentication/oauth2_impl/single_session_provider.rb
spark_api-1.6.0 lib/spark_api/authentication/oauth2_impl/single_session_provider.rb
spark_api-1.5.6 lib/spark_api/authentication/oauth2_impl/single_session_provider.rb
spark_api-1.5.5 lib/spark_api/authentication/oauth2_impl/single_session_provider.rb
spark_api-1.5.4 lib/spark_api/authentication/oauth2_impl/single_session_provider.rb
spark_api-1.5.3 lib/spark_api/authentication/oauth2_impl/single_session_provider.rb
spark_api-1.5.2 lib/spark_api/authentication/oauth2_impl/single_session_provider.rb
spark_api-1.5.1 lib/spark_api/authentication/oauth2_impl/single_session_provider.rb
spark_api-1.5.0 lib/spark_api/authentication/oauth2_impl/single_session_provider.rb
spark_api-1.4.34 lib/spark_api/authentication/oauth2_impl/single_session_provider.rb
spark_api-1.4.32 lib/spark_api/authentication/oauth2_impl/single_session_provider.rb
spark_api-1.4.31 lib/spark_api/authentication/oauth2_impl/single_session_provider.rb
spark_api-1.4.29 lib/spark_api/authentication/oauth2_impl/single_session_provider.rb
spark_api-1.4.28 lib/spark_api/authentication/oauth2_impl/single_session_provider.rb
spark_api-1.4.27 lib/spark_api/authentication/oauth2_impl/single_session_provider.rb
spark_api-1.4.26 lib/spark_api/authentication/oauth2_impl/single_session_provider.rb
spark_api-1.4.25 lib/spark_api/authentication/oauth2_impl/single_session_provider.rb