Class: Aws::Rest::Request::QuerystringBuilder Private

Inherits:
Object
  • Object
show all
Includes:
Seahorse::Model::Shapes
Defined in:
lib/aws-sdk-core/rest/request/querystring_builder.rb

This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.

Constant Summary collapse

SUPPORTED_TYPES =

This constant is part of a private API. You should avoid using this constant if possible, as it may be removed or be changed in the future.

[
  BooleanShape,
  FloatShape,
  IntegerShape,
  StringShape,
  TimestampShape
].freeze

Instance Method Summary collapse

Instance Method Details

#build(params) ⇒ String

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Provide shape references and param values:

[
  [shape_ref1, 123],
  [shape_ref2, "text"]
]

Returns a querystring:

"Count=123&Words=text"

Parameters:

  • params (Array<Array<Seahorse::Model::ShapeRef, Object>>)

    An array of model shape references and request parameter value pairs.

Returns:

  • (String)

    Returns a built querystring



32
33
34
35
36
37
38
# File 'lib/aws-sdk-core/rest/request/querystring_builder.rb', line 32

def build(params)
  # keys in query maps must NOT override other keys
  query_keys = query_keys(params)
  params.map do |(shape_ref, param_value)|
    build_part(shape_ref, param_value, query_keys)
  end.reject { |p| p.nil? || p.empty? }.join('&')
end