Файловый менеджер - Редактировать - /opt/imh-python/lib/python3.9/site-packages/boto3/resources/__pycache__/params.cpython-39.pyc
Ðазад
a v�h� � @ sR d dl Z d dlZd dlmZ ddlmZ e �d�Zdd� Zddd �Z d d d�Z dS )� N)� xform_name� )�ResourceLoadExceptionz \[(.*)\]$c C sB | j jdu r2t| d�r | �� ntd�| jj���t� || j j�S )aE 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``. N�loadz{0} has no load method!) �meta�data�hasattrr r �format� __class__�__name__�jmespath�search)�parent�path� r ��/root/rpmbuild/BUILDROOT/imh-python39-modules-3.9.7-92.el8.x86_64/opt/imh-python/lib/python3.9/site-packages/boto3/resources/params.py�get_data_member s �r c C s� |du ri }|j D ]x}|j}|j}|dkr<t| t|j��}n@|dkrRt| |j�}n*|dv rb|j}n|dkrnqnt d� |���t||||� q|S )aX 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. N� identifierr )�string�integer�boolean�inputzUnsupported source type: {0})�params�source�target�getattrr �namer r �value�NotImplementedErrorr �build_param_structure)r Z request_modelr �index�paramr r r r r r �create_request_parameters3 s$ �r"