ó T!¶\c@soddlZddlZddlmZddlmZejdƒZd„Zddd„Z dd„Z dS( iÿÿÿÿN(t xform_namei(tResourceLoadExceptions \[(.*)\]$cCsb|jjdkrLt|dƒr.|jƒqLtdj|jjƒƒ‚nt j ||jjƒS(sE Get a data member from a parent using a JMESPath search query, loading the parent if required. If the parent cannot be loaded and no data is present then an exception is raised. :type parent: ServiceResource :param parent: The resource instance to which contains data we are interested in. :type path: string :param path: The JMESPath expression to query :raises ResourceLoadException: When no data is present and the resource cannot be loaded. :returns: The queried data or ``None``. tloads{0} has no load method!N( tmetatdatatNonethasattrRRtformatt __class__t__name__tjmespathtsearch(tparenttpath((s7/tmp/pip-install-usGedi/boto3/boto3/resources/params.pytget_data_members  cCsÙ|dkri}nx½|jD]²}|j}|j}|dkr^t|t|jƒƒ}n`|dkrt||jƒ}n?|d kr—|j }n'|dkr©qnt dj |ƒƒ‚t ||||ƒqW|S( sX Handle request parameters that can be filled in from identifiers, resource data members or constants. By passing ``params``, you can invoke this method multiple times and build up a parameter dict over time, which is particularly useful for reverse JMESPath expressions that append to lists. :type parent: ServiceResource :param parent: The resource instance to which this action is attached. :type request_model: :py:class:`~boto3.resources.model.Request` :param request_model: The action request model. :type params: dict :param params: If set, then add to this existing dict. It is both edited in-place and returned. :type index: int :param index: The position of an item within a list :rtype: dict :return: Pre-filled parameters to be sent to the request operation. t identifierRtstringtintegertbooleantinputsUnsupported source type: {0}N(sstringsintegersboolean( RtparamstsourcettargettgetattrRtnameRR tvaluetNotImplementedErrorRtbuild_param_structure(R t request_modelRtindextparamRRR((s7/tmp/pip-install-usGedi/boto3/boto3/resources/params.pytcreate_request_parameters3s"         c Cs·|}|jdƒ}x›t|ƒD]\}}tj|ƒ}|ri|jdƒr§|jdƒdkrt|d }q·t|jdƒƒ}|tt|ƒdƒ }nd}|d }||ks×t ||t ƒ räg||>> build_param_structure(params, 'test[0]', 1) >>> print(params) {'test': [1]} >>> build_param_structure(params, 'foo.bar[0].baz', 'hello world') >>> print(params) {'test': [1], 'foo': {'bar': [{'baz': 'hello, world'}]}} t.it*iýÿÿÿs[]iþÿÿÿN( tsplitt enumeratetINDEX_RER tgrouptinttlentstrRt isinstancetlisttappend( RRRRtpostpartstitparttresult((s7/tmp/pip-install-usGedi/boto3/boto3/resources/params.pyRes4        ( treR tbotocoreRt exceptionsRtcompileR$RRRR(((s7/tmp/pip-install-usGedi/boto3/boto3/resources/params.pyts   2