
    j"                     z    d dl Z d dlmZ d dlmZ d dlmZ d dlmZ d dl	m
Z
 d dlmZ  G d d	          Z	 ddZdS )    N)
xform_name)OrderedDict)DocumentStructure)document_model_driven_method)DocumentedShape)get_service_module_namec                   &    e Zd Zd Zd Zd Zd ZdS )PaginatorDocumenterc                     || _         | j         j        j        | _        | j         j        j        j        | _        || _        || _	        d| _
        d S )Nz>https://docs.aws.amazon.com/boto3/latest/guide/paginators.html)_client	__class____name___client_class_namemetaservice_modelservice_name_service_name_service_paginator_model_root_docs_path_USER_GUIDE_LINK)selfclientservice_paginator_modelroot_docs_paths       X/usr/local/lib/hermes-agent/venv/lib/python3.11/site-packages/botocore/docs/paginator.py__init__zPaginatorDocumenter.__init__   sM    "&,"8"A!\.<I(?%-L 	    c                 F   |j                             d           |                     |           |j                                          |                    d           |j                                          t          | j        j                  }|D ]}|j         	                    | j
         d|            t          |d          }|                     ||           t          j                            | j        | j
        d          }|                    ||           dS )zhDocuments the various paginators for a service

        param section: The section to write to.
        
PaginatorszThe available paginators are:z/paginator/html)target	paginatorN)styleh2_add_overviewnew_linewritelntoctreesortedr   _paginator_configtocitemr   r   _add_paginatorospathjoinr   write_to_file)r   sectionpaginator_namespaginator_namepaginator_doc_structurepaginator_dir_paths         r   document_paginatorsz'PaginatorDocumenter.document_paginators"   sH   
 	&&&7###   7888 );
 

 . 	 	NM!!%BB.BB   '8v' ' '#  7HHH "$$d&8+" " $11"N   	 	r   c                    |                     d          }|j                            | j        d| j                    |                    d|            |                    |           |                     |          }|j                            | j         d|            |j                                         |j        	                                 |                    dt          |           d           |j                                         |j        	                                 | j                            |          }t          ||| j        j        j        | j        j        j        |           d S )	N
breadcrumbz../../z / Paginator / z.Paginator.)
class_namez"paginator = client.get_paginator('z'))r1   r3   event_emitterr   paginator_config)add_new_sectionr#   refr   r   writeadd_title_sectionstart_sphinx_py_classstart_codeblockr&   r   end_codeblockr   get_paginatordocument_paginate_methodr   r   eventsr   )r   r1   r3   breadcrumb_sectionpaginator_sectionr;   s         r   r,   z"PaginatorDocumenter._add_paginatorD   s   $44\BB $$#%Bd.@%B%B	
 	
 	
 	  !C>!C!CDDD!!.111 $33NCC55*GG~GG 	6 	
 	
 	

 	//111((*** 	ON1K1KOOO	
 	
 	
 	--///((***8FF
 
 	!%),+2,+9-	
 	
 	
 	
 	
 	
r   c                     |j                                          |                    d           |j                             d| j                   |                    d           |j                                          d S )NzPaginators are available on a client instance via the ``get_paginator`` method. For more detailed instructions and examples on the usage of paginators, see the paginators z
user guide)titlelink.)r#   r&   r>   external_linkr   )r   r1   s     r   r%   z!PaginatorDocumenter._add_overviewh   s       	
 	
 	
 	##& 	$ 	
 	
 	
 	c     r   N)r   
__module____qualname__r   r6   r,   r%    r   r   r
   r
      sR        
 
 
     D"
 "
 "
H! ! ! ! !r   r
   Tc                 0   |                     |          }t                      }t          ddd          |d<   |                    dd          rt          ddd          |d<   t          d	d
d          |d	<   t          ddd|          g}t          dd
d          g}	g }
t	          |d         t
                    r|
|d         z  }
n|
                    |d                    |                    dd          r|
                    |d                    g }t	          |d         t
                    r||d         z  }n|                    |d                    dt          |           dt          |           d}t          | d|||d||	|
||           dS )a  Documents the paginate method of a paginator

    :param section: The section to write to

    :param paginator_name: The name of the paginator. It is snake cased.

    :param event_emitter: The event emitter to use to emit events

    :param service_model: The service model

    :param paginator_config: The paginator config associated to a particular
        paginator.

    :param include_signature: Whether or not to include the signature.
        It is useful for generating docstrings.
    MaxItemsintegerz<p>The total number of items to return. If the total number of items available is more than the value specified in max-items then a <code>NextToken</code> will be provided in the output that you can use to resume pagination.</p>)name	type_namedocumentation	limit_keyNPageSizez<p>The size of each page.<p>StartingTokenstringzq<p>A token to specify where to start paginating. This is the <code>NextToken</code> from a previous response.</p>PaginationConfig	structurezC<p>A dictionary that provides parameters to control pagination.</p>)rS   rT   rU   members	NextTokenz$<p>A token to resume pagination.</p>input_tokenoutput_tokenzHCreates an iterator that will paginate through responses from :py:meth:`z.Client.z`.paginatez&response_iterator = paginator.paginate)r:   method_descriptionexample_prefixinclude_inputinclude_outputexclude_inputexclude_outputinclude_signature)
operation_modelr   r   get
isinstancelistappendr   r   r   )r1   r3   r:   r   r;   rg   rh   pagination_config_membersbotocore_pagination_params#botocore_pagination_response_paramsservice_pagination_params"service_pagination_response_paramspaginate_descriptions                r   rD   rD   x   s\   2 $33NCCO
 !,,;%	
- 
- 
-j) K.. 
0?81
 1
 1
!*- 2A	2 2 2o. 	#!" .	
 	
 	

" 	A	
 	
 	
+' !# "=1488 J!%5m%DD!!!(()9-)HIII K.. H!(()9+)FGGG *,&">2D99 
*.>~.NN***11^,	
 	
 	

	i1-@@	i 	iJTUcJdJd	i 	i 	i 
 !#/?0:/9+     r   )T)r-   botocorer   botocore.compatr   botocore.docs.bcdoc.restdocr   botocore.docs.methodr   botocore.docs.utilsr   botocore.utilsr   r
   rD   rO   r   r   <module>ry      s    
			       ' ' ' ' ' ' 9 9 9 9 9 9 = = = = = = / / / / / / 2 2 2 2 2 2^! ^! ^! ^! ^! ^! ^! ^!N x x x x x xr   