Class: EPlat::Shopify::GraphQL::V202407::Input
- Inherits:
-
Object
- Object
- EPlat::Shopify::GraphQL::V202407::Input
- Defined in:
- lib/e_plat/resource/platform_specific/shopify/graph_q_l/v_2024_07/input.rb
Direct Known Subclasses
Constant Summary collapse
- SUPPORTED_FIELDS =
[]
- SUPPORTED_NAMED_ARGUMENT_FIELDS =
{}
Instance Attribute Summary collapse
-
#input ⇒ Object
Returns the value of attribute input.
-
#named_arguments ⇒ Object
Returns the value of attribute named_arguments.
Instance Method Summary collapse
-
#initialize(input = {}, **named_arguments) ⇒ Input
constructor
A new instance of Input.
- #to_graphql_args ⇒ Object
Constructor Details
#initialize(input = {}, **named_arguments) ⇒ Input
Returns a new instance of Input.
7 8 9 10 |
# File 'lib/e_plat/resource/platform_specific/shopify/graph_q_l/v_2024_07/input.rb', line 7 def initialize(input = {}, **named_arguments) @input = input.deep_transform_keys { |key| key.to_s.camelize(:lower) } @named_arguments = named_arguments.deep_transform_keys { |key| key.to_s.camelize(:lower) } end |
Instance Attribute Details
#input ⇒ Object
Returns the value of attribute input.
2 3 4 |
# File 'lib/e_plat/resource/platform_specific/shopify/graph_q_l/v_2024_07/input.rb', line 2 def input @input end |
#named_arguments ⇒ Object
Returns the value of attribute named_arguments.
2 3 4 |
# File 'lib/e_plat/resource/platform_specific/shopify/graph_q_l/v_2024_07/input.rb', line 2 def named_arguments @named_arguments end |
Instance Method Details
#to_graphql_args ⇒ Object
12 13 14 15 |
# File 'lib/e_plat/resource/platform_specific/shopify/graph_q_l/v_2024_07/input.rb', line 12 def to_graphql_args args = named_arguments.present? ? named_arguments_with_allowed_fields(named_arguments) : { input: allowed_fields } format_graphql_args(args) end |