Class: ConvenientService::Examples::Standard::V1::RequestParams::Services::MergeParams
- Inherits:
-
Object
- Object
- ConvenientService::Examples::Standard::V1::RequestParams::Services::MergeParams
- Includes:
- Service::Configs::Standard::V1
- Defined in:
- lib/convenient_service/examples/standard/v1/request_params/services/merge_params.rb
Instance Attribute Summary collapse
-
#params_from_body ⇒ Object
readonly
Returns the value of attribute params_from_body.
-
#params_from_path ⇒ Object
readonly
Returns the value of attribute params_from_path.
Instance Method Summary collapse
-
#initialize(params_from_path:, params_from_body:) ⇒ MergeParams
constructor
A new instance of MergeParams.
- #result ⇒ Object
Constructor Details
#initialize(params_from_path:, params_from_body:) ⇒ MergeParams
Returns a new instance of MergeParams.
14 15 16 17 |
# File 'lib/convenient_service/examples/standard/v1/request_params/services/merge_params.rb', line 14 def initialize(params_from_path:, params_from_body:) @params_from_path = params_from_path @params_from_body = params_from_body end |
Instance Attribute Details
#params_from_body ⇒ Object (readonly)
Returns the value of attribute params_from_body.
12 13 14 |
# File 'lib/convenient_service/examples/standard/v1/request_params/services/merge_params.rb', line 12 def params_from_body @params_from_body end |
#params_from_path ⇒ Object (readonly)
Returns the value of attribute params_from_path.
12 13 14 |
# File 'lib/convenient_service/examples/standard/v1/request_params/services/merge_params.rb', line 12 def params_from_path @params_from_path end |
Instance Method Details
#result ⇒ Object
19 20 21 |
# File 'lib/convenient_service/examples/standard/v1/request_params/services/merge_params.rb', line 19 def result success(params: params_from_path.merge(params_from_body)) end |