ó FuÚ_c@sÌddlZddlmZddlmZddlmZddlmZddlmZddl m Z ddl m Z dd lm Z dd lmZd efd „ƒYZd efd„ƒYZdS(iÿÿÿÿN(tget_official_service_name(tdocument_custom_method(tdocument_model_driven_method(tget_instance_public_methods(tdocument_shared_examples(tResponseExampleDocumenter(tResponseParamsDocumenter(tDocumentedShape(t OrderedDicttClientDocumentercBsweZd d„Zd„Zd„Zd„Zd„Zd„Zd„Z d„Z d„Z d „Z d „Z d „ZRS( cCsF||_||_|jdkr-i|_n|jjjj|_dS(N(t_clientt_shared_examplestNonetmetat service_modelt service_namet _service_name(tselftclienttshared_examples((s?/opt/awscli/lib/python2.7/site-packages/botocore/docs/client.pyt__init__s    cCsM|j|ƒ|j|ƒt|jƒ}|j||ƒ|j||ƒdS(s]Documents a client and its methods :param section: The section to write to. N(t _add_titlet_add_class_signatureRR t_add_client_introt_add_client_methods(Rtsectiontclient_methods((s?/opt/awscli/lib/python2.7/site-packages/botocore/docs/client.pytdocument_client"s   cCs|jjdƒdS(NtClient(tstyleth2(RR((s?/opt/awscli/lib/python2.7/site-packages/botocore/docs/client.pyR-scCsÓ|jdƒ}t|jjjƒ}|jd|ƒ|jjƒ|j|jjjj ƒ|j |ƒ|jjƒ|jdƒ|jjƒ|jj j }x.t |ƒD] }|jjd||fƒq«WdS(Ntintros"A low-level client representing %ss These are the available methods:s:py:meth:`~%s.Client.%s`(tadd_new_sectionRR R RtwriteRtnew_linetinclude_doc_stringt documentationt_add_client_creation_examplet __class__t__name__tsortedtli(RRRtofficial_service_namet class_namet method_name((s?/opt/awscli/lib/python2.7/site-packages/botocore/docs/client.pyR0s       cCs$|jjdd|jjjƒdS(NR+s %s.Client(Rtstart_sphinx_py_classR R&R'(RR((s?/opt/awscli/lib/python2.7/site-packages/botocore/docs/client.pyRFs cCsG|jjƒ|jjƒ|jdjd|jƒƒ|jjƒdS(Ns+client = session.create_client('{service}')tservice(Rtstart_codeblockR"R!tformatRt end_codeblock(RR((s?/opt/awscli/lib/python2.7/site-packages/botocore/docs/client.pyR%Js     cCsA|jdƒ}x+t|ƒD]}|j||||ƒqWdS(Ntmethods(R R(t_add_client_method(RRRR,((s?/opt/awscli/lib/python2.7/site-packages/botocore/docs/client.pyRSscCsH|j|ƒ}|j|ƒr4|j|||ƒn|j||ƒdS(N(R t_is_custom_methodt_add_custom_methodt_add_model_driven_method(RRR,tmethod((s?/opt/awscli/lib/python2.7/site-packages/botocore/docs/client.pyR3YscCs||jjjkS(N(R R tmethod_to_api_mapping(RR,((s?/opt/awscli/lib/python2.7/site-packages/botocore/docs/client.pyR4`scCst|||ƒdS(N(R(RRR,R7((s?/opt/awscli/lib/python2.7/site-packages/botocore/docs/client.pyR5cscCs‡|jdƒ}|jjƒ|jjdƒ|jjƒ|jjj}x8|jD]-}d||jf}|jj d|ƒqRWdS(Nt exceptionst Exceptionss%s.Client.exceptions.%ss:py:class:`%s`( R RR"tboldR R&R't error_shapestnameR)(RRtoperation_modelt error_sectiont client_nameterrorR+((s?/opt/awscli/lib/python2.7/site-packages/botocore/docs/client.pyt_add_method_exceptions_listfs  c Cs·|jjj}|jjj|}|j|ƒ}d|}t|||d|jjjd|jd|ƒ|jr…|j ||ƒn|j j |ƒ}|r³t ||||ƒndS(Nsresponse = client.%st event_emittertmethod_descriptiontexample_prefix( R R RR8R>RteventsR$R<RBR tgetR(RRR,Rtoperation_nameR>RER((s?/opt/awscli/lib/python2.7/site-packages/botocore/docs/client.pyR6ps    N(R't __module__R RRRRRR%RR3R4R5RBR6(((s?/opt/awscli/lib/python2.7/site-packages/botocore/docs/client.pyR s         tClientExceptionsDocumentercBsïeZdZedddddddededddd dd ƒfd edd dd dd ƒfgƒƒZd „Zd„Zd„Zd„Z d„Z d„Z d„Z d„Z d„Zd„Zd„Zd„Zd„Zd„ZRS(sQhttps://boto3.amazonaws.com/v1/documentation/api/latest/guide/error-handling.htmlR=tErrort type_namet structureR$s1Normalized access to common exception attributes.tmemberstCodetstrings,An identifier specifying the exception type.tMessages;A descriptive message explaining why the exception occured.cCs"||_|jjjj|_dS(N(R R RRR(RR((s?/opt/awscli/lib/python2.7/site-packages/botocore/docs/client.pyR¦s cCs8|j|ƒ|j|ƒ|j|ƒ|j|ƒdS(N(Rt _add_overviewt_add_exceptions_listt_add_exception_classes(RR((s?/opt/awscli/lib/python2.7/site-packages/botocore/docs/client.pytdocument_exceptionsªs   cCs|jjdƒdS(NsClient Exceptions(RR(RR((s?/opt/awscli/lib/python2.7/site-packages/botocore/docs/client.pyR°scCsT|jjƒ|jdƒ|jjddd|jƒ|jdƒ|jjƒdS(NsÂClient exceptions are available on a client instance via the ``exceptions`` property. For more detailed instructions and examples on the exact usage of client exceptions, see the error handling ttitles user guidetlinkt.(RR"R!t external_linkt_USER_GUIDE_LINK(RR((s?/opt/awscli/lib/python2.7/site-packages/botocore/docs/client.pyRR³s    cCs |jjj}d||jfS(Ns%s.Client.exceptions.%s(R R&R'R=(Rtshapetcls_name((s?/opt/awscli/lib/python2.7/site-packages/botocore/docs/client.pyt_exception_class_nameÂscCs¢|jjjj}|sC|jjƒ|jdƒ|jjƒdS|jjƒ|jdƒ|jjƒx1|D])}|j|ƒ}|jjd|ƒqqWdS(Ns-This client has no modeled exception classes.s$The available client exceptions are:s:py:class:`%s`( R R RR<RR"R!R]R)(RRR<R[R+((s?/opt/awscli/lib/python2.7/site-packages/botocore/docs/client.pyRSÆs       cCs1x*|jjjjD]}|j||ƒqWdS(N(R R RR<t_add_exception_class(RRR[((s?/opt/awscli/lib/python2.7/site-packages/botocore/docs/client.pyRTÔscCsu|j|jƒ}|j|ƒ}|jjd|ƒ|j||ƒ|j||ƒ|j||ƒ|jjƒdS(NR+( R R=R]RR-t_add_top_level_documentationt_add_exception_catch_examplet_add_response_attrtend_sphinx_py_class(RRR[t class_sectionR+((s?/opt/awscli/lib/python2.7/site-packages/botocore/docs/client.pyR^ØscCs:|jr6|jjƒ|j|jƒ|jjƒndS(N(R$RR"R#(RRR[((s?/opt/awscli/lib/python2.7/site-packages/botocore/docs/client.pyR_ás  cCsÑ|jjƒ|jjdƒ|jjƒ|jdƒ|jjƒ|jjƒ|jdƒ|jjƒ|jjƒ|jd|jƒ|jjƒ|jjƒ|jdƒ|jjƒ|jjƒdS(NtExamplestry:s...s!except client.exceptions.%s as e:sprint(e.response)( RR"R;R/R!tindenttdedentR=R1(RRR[((s?/opt/awscli/lib/python2.7/site-packages/botocore/docs/client.pyR`çs            cCs]|jdƒ}|jjdƒ|j|ƒ|j||ƒ|j||ƒ|jjƒdS(Ntresponse(R Rtstart_sphinx_py_attrt_add_response_attr_descriptiont_add_response_examplet_add_response_paramstend_sphinx_py_attr(RRR[tresponse_section((s?/opt/awscli/lib/python2.7/site-packages/botocore/docs/client.pyRaøs  cCs+|jjƒ|jdƒ|jjƒdS(NsÈThe parsed error response. All exceptions have a top level ``Error`` key that provides normalized access to common exception atrributes. All other keys are specific to this service or exception class.(RR"R#(RR((s?/opt/awscli/lib/python2.7/site-packages/botocore/docs/client.pyRis cCs€|jdƒ}|jjƒ|jjdƒ|jjƒtd|jddd|jj j ƒ}|j ||d|j gƒdS(NtsyntaxtSyntaxRRHRCtinclude( R RR"R;t new_paragraphRRR R R RFtdocument_examplet_GENERIC_ERROR_SHAPE(RRR[texample_sectiont documenter((s?/opt/awscli/lib/python2.7/site-packages/botocore/docs/client.pyRj s   cCs€|jdƒ}|jjƒ|jjdƒ|jjƒtd|jddd|jj j ƒ}|j ||d|j gƒdS(Nt StructureRRHRCRp( R RR"R;RqRRR R R RFtdocument_paramsRs(RRR[tparams_sectionRu((s?/opt/awscli/lib/python2.7/site-packages/botocore/docs/client.pyRks   (R'RIRZRRRsRRURRRR]RSRTR^R_R`RaRiRjRk(((s?/opt/awscli/lib/python2.7/site-packages/botocore/docs/client.pyRJˆs8              (tinspecttbotocore.docs.utilsRtbotocore.docs.methodRRRtbotocore.docs.sharedexampleRtbotocore.docs.exampleRtbotocore.docs.paramsRRtbotocore.compatRtobjectR RJ(((s?/opt/awscli/lib/python2.7/site-packages/botocore/docs/client.pyt s n