class Aws::ParamValidator
def shape(ref, value, errors, context)
def shape(ref, value, errors, context) case ref.shape when StructureShape then structure(ref, value, errors, context) when ListShape then list(ref, value, errors, context) when MapShape then map(ref, value, errors, context) when StringShape unless value.is_a?(String) errors << expected_got(context, "a String", value) end when IntegerShape unless value.is_a?(Integer) errors << expected_got(context, "an Integer", value) end when FloatShape unless value.is_a?(Float) errors << expected_got(context, "a Float", value) end when TimestampShape unless value.is_a?(Time) errors << expected_got(context, "a Time object", value) end when BooleanShape unless [true, false].include?(value) errors << expected_got(context, "true or false", value) end when BlobShape unless io_like?(value) or value.is_a?(String) errors << expected_got(context, "a String or IO object", value) end else raise "unhandled shape type: #{ref.shape.class.name}" end end