Class: ActiveGraphql::Client::Actions::Action::FormatVariableInputs
- Inherits:
-
Object
- Object
- ActiveGraphql::Client::Actions::Action::FormatVariableInputs
- Includes:
- VariableDetectable
- Defined in:
- lib/active_graphql/client/actions/action/format_variable_inputs.rb
Overview
converts ruby object in to varbiable stype grapqhl input
Instance Method Summary collapse
- #call ⇒ Object
-
#initialize(inputs) ⇒ FormatVariableInputs
constructor
A new instance of FormatVariableInputs.
Methods included from VariableDetectable
#variable_attributes, #variable_value?
Constructor Details
#initialize(inputs) ⇒ FormatVariableInputs
Returns a new instance of FormatVariableInputs.
11 12 13 |
# File 'lib/active_graphql/client/actions/action/format_variable_inputs.rb', line 11 def initialize(inputs) @initial_inputs = inputs end |
Instance Method Details
#call ⇒ Object
15 16 17 18 19 |
# File 'lib/active_graphql/client/actions/action/format_variable_inputs.rb', line 15 def call return '' if inputs.empty? formatted_attributes(inputs) end |