MCPcopy Index your code
hub / github.com/aws/aws-cli / is_json_value_header

Function is_json_value_header

awscli/botocore/utils.py:192–206  ·  view source on GitHub ↗

Determines if the provided shape is the special header type jsonvalue. :type shape: botocore.shape :param shape: Shape to be inspected for the jsonvalue trait. :return: True if this type is a jsonvalue, False otherwise :rtype: Bool

(shape)

Source from the content-addressed store, hash-verified

190
191
192def is_json_value_header(shape):
193 """Determines if the provided shape is the special header type jsonvalue.
194
195 :type shape: botocore.shape
196 :param shape: Shape to be inspected for the jsonvalue trait.
197
198 :return: True if this type is a jsonvalue, False otherwise
199 :rtype: Bool
200 """
201 return (
202 hasattr(shape, 'serialization')
203 and shape.serialization.get('jsonvalue', False)
204 and shape.serialization.get('location') == 'header'
205 and shape.type_name == 'string'
206 )
207
208
209def has_header(header_name, headers):

Calls

no outgoing calls