o d@sddlZddlmZddlmZddlmZmZddlm Z ddl m Z ddl m Z ddlmZdd lmZmZmZGd d d e Z dd dZ dddZdS)N) xform_name)DocumentStructure)document_custom_methoddocument_model_driven_method)OperationModel)get_service_module_name)NestedDocumenter)%document_model_driven_resource_method)add_resource_type_overviewget_resource_ignore_paramsget_resource_public_actionsc@seZdZddZdS)ActionDocumenterc Cs|jj}i}|D]}|||j<qt|jj}t||jd<t|ddddt|D]`}t |dd}| || |}|dvrW|jj rWt |||j|jjjjj|jj |jd n||vrnt||j|jjjjj|||jd nt||||tj|j|j|j} || |q)dS) NactionsZActionszActions call operations on resources. They may automatically handle the passing in of arguments set from identifiers and some attributes.Z actions_intro)sectionZ resource_type descriptionZ intro_linkhtml)target)loadreload)r action_name resource_name event_emitter load_model service_model)rrr action_modelr)Z_resource_modelrnamer Z _resource __class__sorted member_mapr rZadd_title_sectionZadd_new_sectionrdocument_load_reload_actionZ_resource_namemetaclienteventsZ_service_modeldocument_actionrospathjoinZ_root_docs_pathZ _service_nameZ_resource_sub_pathZ write_to_file) selfrZmodeled_actions_listZmodeled_actionsZmodeled_actionZresource_actionsrZ action_docZaction_sectionZactions_dir_pathr(l/private/var/folders/v1/_jykv66s6qd26_69j1njbrl80000gr/T/pip-target-p1gutpg6/lib/python/boto3/docs/action.pydocument_actions"sZ       z!ActionDocumenter.document_actionsN)__name__ __module__ __qualname__r*r(r(r(r)r !s r Tc Csx||jj}t|jj}d}|jrt|jj}t|} |j|kr#|} d || |j } t ||j |||j | |||d dS)aDocuments a resource action :param section: The section to write to :param resource_name: The name of the resource :param event_emitter: The event emitter to use to emit events :param action_model: The model of the action :param service_model: The model of the service :param include_signature: Whether or not to include the signature. It is useful for generating docstrings. responsez {} = {}.{}) r method_nameoperation_modelrmethod_descriptionexample_prefixZ exclude_inputZresource_action_modelinclude_signatureN) r0request operationr paramsresourcertype service_nameformatrr Z documentation) rrrrrr3r0Z ignore_paramsZexample_return_valueexample_resource_namer2r(r(r)r#Zs0    r#c Cs^dt|t|jj|}t|}|j|kr|}|d|} t||ti|||| |ddS)aDocuments the resource load action :param section: The section to write to :param action_name: The name of the loading action should be load or reload :param resource_name: The name of the resource :param event_emitter: The event emitter to use to emit events :param load_model: The model of the load action :param service_model: The model of the service :param include_signature: Whether or not to include the signature. It is useful for generating docstrings. zCalls :py:meth:`{}.Client.{}` to update the attributes of the {} resource. Note that the load and reload methods are the same method and can be used interchangeably..)rr/r0rr1r2r3N)r:rrr4r5r9rr) rrrrrrr3rr;r2r(r(r)rs(   r)T)r$ZbotocorerZbotocore.docs.bcdoc.restdocrZbotocore.docs.methodrrZbotocore.modelrZbotocore.utilsrZboto3.docs.baserZboto3.docs.methodr Zboto3.docs.utilsr r r r r#rr(r(r(r)s      ? 9