Class: OAuth2::Storages::Strategy

Inherits:
Object
  • Object
show all
Defined in:
lib/oauth20/storages/strategy.rb

Direct Known Subclasses

RedisStrategy

Instance Method Summary collapse

Instance Method Details

#access_token_find_by_key(key) ⇒ Object

Find access token by given key.

Parameters:

  • Access (String)

    token key to search.

Raises:

  • (NotImplementedError)


17
18
19
# File 'lib/oauth20/storages/strategy.rb', line 17

def access_token_find_by_key(key)
  raise NotImplementedError        
end

#access_token_save(access_token) ⇒ Object

Save new access token.

Parameters:

  • Access (Auth2::AccessToken)

    token instance.

Raises:

  • (NotImplementedError)


9
10
11
# File 'lib/oauth20/storages/strategy.rb', line 9

def access_token_save(access_token)
  raise NotImplementedError
end

#auth_code_find_by_key(key) ⇒ Object

Find authorization code by the given key.

Parameters:

  • Authorization (String)

    code key.

Raises:

  • (NotImplementedError)


33
34
35
# File 'lib/oauth20/storages/strategy.rb', line 33

def auth_code_find_by_key(key)
  raise NotImplementedError
end

#auth_code_save(auth_code) ⇒ Object

Save new authorization code.

Parameters:

  • Authorization (Auth2::AuthCode)

    code instance.

Raises:

  • (NotImplementedError)


25
26
27
# File 'lib/oauth20/storages/strategy.rb', line 25

def auth_code_save(auth_code)
  raise NotImplementedError
end

#client_find_by_key(key) ⇒ Object

Raises:

  • (NotImplementedError)


46
47
48
# File 'lib/oauth20/storages/strategy.rb', line 46

def client_find_by_key(key)
  raise NotImplementedError
end

#client_find_by_secret(secret) ⇒ Object

Raises:

  • (NotImplementedError)


50
51
52
# File 'lib/oauth20/storages/strategy.rb', line 50

def client_find_by_secret(secret)
  raise NotImplementedError
end

#client_save(client) ⇒ Object

Save new client.

Parameters:

  • Client (Auth2::Client)

    instance.

Raises:

  • (NotImplementedError)


42
43
44
# File 'lib/oauth20/storages/strategy.rb', line 42

def client_save(client)
  raise NotImplementedError
end