/usr/lib/rads/venv/lib/python3.13/site-packages/boto3/resources/__pycache__
Edit: /usr/lib/rads/venv/lib/python3.13/site-packages/boto3/resources/__pycache__/model.cpython-313.pyc (21746B)
jpO S r SSKrSSKJr \R " \5 r " S S5 r " S S5 r " S S 5 r " S
S5 r
" S S
\ 5 r " S S\ 5 r " S S5 r
" S S\5 r " S S5 rg)a
The models defined in this file represent the resource JSON description
format and provide a layer of abstraction from the raw JSON. The advantages
of this are:
* Pythonic interface (e.g. ``action.request.operation``)
* Consumers need not change for minor JSON changes (e.g. renamed field)
These models are used both by the resource factory to generate resource
classes as well as by the documentation generator.
N)
xform_namec " \ rS rSrSrSS jrSrg)
Identifier! zg
A resource identifier, given by its name.
:type name: string
:param name: The name of the identifier
Nc Xl X l g N)namemember_name)selfr r
s H/usr/lib/rads/venv/lib/python3.13/site-packages/boto3/resources/model.py__init__Identifier.__init__) s
& )r
r r __name__
__module____qualname____firstlineno____doc__r
__static_attributes__ r r r r ! s 'r r c \ rS rSrSrS rSrg)Action/ z
A service operation action.
:type name: string
:param name: The name of the action
:type definition: dict
:param definition: The JSON definition
:type resource_defs: dict
:param resource_defs: All resources defined in the service
c X l Xl S U l SU; a [ UR S0 5 5 U l S U l SU; a! [
UR S0 5 U5 U l UR S5 U l g )Nrequestresourcepath)_definitionr r Requestgetr ResponseResourcer r r
definition
resource_defss r r
Action.__init__; sr %
"":>>)R#@ADL
#,z2.
DM NN6* r )r r r r r Nr r r r r r / s +r r c . \ rS rSrSrS r\S 5 rSrg)DefinitionWithParamsN z
An item which has parameters exposed via the ``params`` property.
A request has an operation and parameters, while a waiter has
a name, a low-level waiter name and parameters.
:type definition: dict
:param definition: The JSON definition
c Xl g r r )r r$ s r r
DefinitionWithParams.__init__X s %r c / nU R R S/ 5 H nUR [ S0 UD65 M U$ )z\
Get a list of auto-filled parameters for this request.
:type: list(:py:class:`Parameter`)
paramsr r r! append Parameter)r r. items r r. DefinitionWithParams.params[ sA $$((26DMM)+d+, 7
r r+ N) r r r r r r
propertyr. r r r r r( r( N s & r r( c $ \ rS rSrSr SS jrSrg)r1 j a
An auto-filled parameter which has a source and target. For example,
the ``QueueUrl`` may be auto-filled from a resource's ``url`` identifier
when making calls to ``queue.receive_messages``.
:type target: string
:param target: The destination parameter name, e.g. ``QueueUrl``
:type source_type: string
:param source_type: Where the source is defined.
:type source: string
:param source: The source name, e.g. ``Url``
Nc | Xl X l X0l X@l XPl U( a [
R
SU5 g g )Nz#Unknown parameter options found: %s)targetsourcer r valueloggerwarning)r r8 r9 r r r: kwargss r r
Parameter.__init__x s6
NN@&I r )r r r9 r8 r: )NNNr r r r r1 r1 j s ;?Jr r1 c , ^ \ rS rSrSrU 4S jrSrU =r$ )r zd
A service operation action request.
:type definition: dict
:param definition: The JSON definition
c P > [ TU ] U5 UR S5 U l g )N operation)superr
r! rB )r r$ __class__s r r
Request.__init__ s"
$ $4r )rB )r r r r r r
r
__classcell__rD s @r r r s 5 5r r c 0 ^ \ rS rSrSrSrU 4S jrSrU =r$ )Waiter z
An event waiter specification.
:type name: string
:param name: Name of the waiter
:type definition: dict
:param definition: The JSON definition
WaitUntilc \ > [ TU ] U5 Xl UR S5 U l g )N
waiterName)rC r
r r! waiter_name)r r r$ rD s r r
Waiter.__init__ s*
$ &>>,7r )r rN ) r r r r r PREFIXr
r rF rG s @r rI rI s F8 8r rI c > \ rS rSrSrS r\S 5 r\S 5 rSr g)r" z
A resource response to create after performing an action.
:type definition: dict
:param definition: The JSON definition
:type resource_defs: dict
:param resource_defs: All resources defined in the service
c t Xl X l UR S5 U l UR S5 U l g )Ntyper )r _resource_defsr! rT r )r r$ r% s r r
ResponseResource.__init__ s2 %+ NN6* NN6* r c / nU R R S/ 5 H nUR [ S0 UD65 M U$ )zF
A list of resource identifiers.
:type: list(:py:class:`Identifier`)
identifiersr r/ )r rX r2 s r rX ResponseResource.identifiers sD $$((;Dy0401 < r c r [ U R U R U R U R 5 $ )zU
Get the resource model for the response resource.
:type: :py:class:`ResourceModel`
)
ResourceModelrT rU r s r modelResponseResource.model s1 IIt**4995t7J7J
r )r rU r rT N)
r r r r r r
r4 rX r] r r r r r" r" s4 +
r r" c ( \ rS rSrSr\S 5 rSrg)
Collection z
A group of resources. See :py:class:`Action`.
:type name: string
:param name: The name of the collection
:type definition: dict
:param definition: The JSON definition
:type resource_defs: dict
:param resource_defs: All resources defined in the service
c B U R R R $ )z
Get a list of batch actions supported by the resource type
contained in this action. This is a shortcut for accessing
the same information through the resource model.
:rtype: list(:py:class:`Action`)
)r r]
batch_actionsr\ s r rc Collection.batch_actions s }}""000r r N)r r r r r r4 rc r r r r r` r` s 1 1r r` c \ rS rSrSrS rSS jrSS jrSS jrS r \
S 5 r\
S
5 r\
S 5 r
\
S 5 rS
rS r\
S 5 r\
S 5 r\
S 5 r\
S 5 rSrg)r[ a
A model representing a resource, defined via a JSON description
format. A resource has identifiers, attributes, actions,
sub-resources, references and collections. For more information
on resources, see :ref:`guide_resources`.
:type name: string
:param name: The name of this resource, e.g. ``sqs`` or ``Queue``
:type definition: dict
:param definition: The JSON definition
:type resource_defs: dict
:param resource_defs: All resources defined in the service
c b X l X0l 0 U l Xl UR S5 U l g )Nshape)r rU _renamedr r! rh r# s r r
ResourceModel.__init__ s, %+
^^G,
r Nc S1n0 U l U R R S5 ( a UR S5 U R R S/ 5 H nU R X#S S5 M U R R S0 5 H nU R X$S5 M U R 5 R
5 HO u pESnUS S H nUS
S:X d M Sn O U( d U R X$S
SS9 M= U R X$S5 MQ U R R S0 5 H nU R X$S5 M U R R S0 5 H' nU R U[ R U- S5 M) Ub4 UR R 5 H nU R X$S5 M gg)a
Load a name translation map given a shape. This will set
up renamed values for any collisions, e.g. if the shape,
an action, and a subresource all are all named ``foo``
then the resource will have an action ``foo``, a subresource
named ``Foo`` and a property named ``foo_attribute``.
This is the order of precedence, from most important to
least important:
* Load action (resource.load)
* Identifiers
* Actions
* Subresources
* References
* Collections
* Waiters
* Attributes (shape members)
Batch actions are only exposed on collections, so do not
get modified here. Subresources use upper camel casing, so
are unlikely to collide with anything but other subresources.
Creates a structure like this::
renames = {
('action', 'id'): 'id_action',
('collection', 'id'): 'id_collection',
('attribute', 'id'): 'id_attribute'
}
# Get the final name for an action named 'id'
name = renames.get(('action', 'id'), 'id')
:type shape: botocore.model.Shape
:param shape: The underlying shape for this resource.
metaloadrX r
identifieractionsactionFr r9 dataTsubresource
snake_case referencehasMany
collectionwaiterswaiterN attribute)ri r r! add_load_name_with_category_get_has_definitionitemsrI rP memberskeys)r rh namesr2 r ref
data_requiredrn s r load_rename_mapResourceModel.load_rename_map s L
''IIf$$((;D))%f|L < $$((B7D))%x@ 8 11399;ID "M!*om<
h'61$(M =
!--5 . --e;G < $$((B7D))%|D 8 $$((B7D))v}}t+X
8
**,--e;G - r c ( U( a [ U5 nX!; aj [ R SU R SU SU 35 US- U- U R X24' USU- -
nX!; a [ SU R SU SU S35 eUR
U5 g)a
Load a name with a given category, possibly renaming it
if that name is already in use. The name will be stored
in ``names`` and possibly be set up in ``self._renamed``.
:type names: set
:param names: Existing names (Python attributes, properties, or
methods) on the resource.
:type name: string
:param name: The original name of the value.
:type category: string
:param category: The value type, such as 'identifier' or 'action'
:type snake_case: bool
:param snake_case: True (default) if the name should be snake cased.
z Renaming _zProblem renaming z to !N)r r; debugr ri
ValueErrorr{ )r r r categoryrt s r r| &ResourceModel._load_name_with_category] s d#D=LL9TYYKq
!D6BC.2Sj8.CDMM8*+C(N"D} !' {!H:T$qI $r c ` U( a [ U5 nU R R X4U5 $ )a
Get a possibly renamed value given a category and name. This
uses the rename map set up in ``load_rename_map``, so that
method must be called once first.
:type category: string
:param category: The value type, such as 'identifier' or 'action'
:type name: string
:param name: The original name of the value
:type snake_case: bool
:param snake_case: True (default) if the name should be snake cased.
:rtype: string
:return: Either the renamed value if it is set, otherwise the
original name.
)r ri r! )r r r rt s r _get_nameResourceModel._get_name~ s+ d#D}} (!1488r c 0 nU R Vs/ s H o3R PM nnUR R 5 H- u pV[ U5 nXt; a M U R SUSS9nXV4X'' M/ U$ s snf )a[
Get a dictionary of attribute names to original name and shape
models that represent the attributes of this resource. Looks
like the following:
{
'some_name': ('SomeName',
)
}
:type shape: botocore.model.Shape
:param shape: The underlying shape for this resource.
:rtype: dict
:return: Mapping of resource attributes.
rz Frs )rX r r r~ r r )r rh
attributesiidentifier_namesr membersnake_caseds r get_attributesResourceModel.get_attributes s
,0,<,<=,