Class: Services::UpdatePublicKeyContext
- Inherits:
-
Object
- Object
- Services::UpdatePublicKeyContext
- Defined in:
- app/contexts/services/update_public_key_context.rb
Instance Attribute Summary collapse
-
#params ⇒ Object
Returns the value of attribute params.
-
#public_key ⇒ Object
Returns the value of attribute public_key.
Class Method Summary collapse
Instance Method Summary collapse
- #call ⇒ Object
-
#initialize(public_key, params) ⇒ UpdatePublicKeyContext
constructor
A new instance of UpdatePublicKeyContext.
Constructor Details
#initialize(public_key, params) ⇒ UpdatePublicKeyContext
Returns a new instance of UpdatePublicKeyContext.
11 12 13 14 15 |
# File 'app/contexts/services/update_public_key_context.rb', line 11 def initialize(public_key, params) @public_key = public_key @params = params @public_key.extend Services::PublicKeyUpdater end |
Instance Attribute Details
#params ⇒ Object
Returns the value of attribute params.
5 6 7 |
# File 'app/contexts/services/update_public_key_context.rb', line 5 def params @params end |
#public_key ⇒ Object
Returns the value of attribute public_key.
5 6 7 |
# File 'app/contexts/services/update_public_key_context.rb', line 5 def public_key @public_key end |
Class Method Details
.call(public_key, params) ⇒ Object
7 8 9 |
# File 'app/contexts/services/update_public_key_context.rb', line 7 def self.call(public_key, params) UpdatePublicKeyContext.new(public_key, params).call end |
Instance Method Details
#call ⇒ Object
17 18 19 |
# File 'app/contexts/services/update_public_key_context.rb', line 17 def call public_key.update(params) end |