Linux worldls-302.fr.planethoster.net 4.18.0-553.8.1.lve.el7h.x86_64 #1 SMP Thu Jul 4 15:19:33 UTC 2024 x86_64
LiteSpeed
Server IP : 10.185.0.203 & Your IP : 216.73.217.14
Domains :
Cant Read [ /etc/named.conf ]
User : gerathty
Terminal
Auto Root
Create File
Create Folder
Localroot Suggester
Backdoor Destroyer
Readme
/
lib /
python2.7 /
site-packages /
botocore /
docs /
Delete
Unzip
Name
Size
Permission
Date
Action
bcdoc
[ DIR ]
drwxr-xr-x
2017-04-04 16:40
__init__.py
1.51
KB
-rw-r--r--
2017-04-04 16:39
__init__.pyc
1.18
KB
-rw-r--r--
2017-04-04 16:40
client.py
4.56
KB
-rw-r--r--
2017-04-04 16:39
client.pyc
4.5
KB
-rw-r--r--
2017-04-04 16:40
docstring.py
3.61
KB
-rw-r--r--
2017-04-04 16:39
docstring.pyc
4.47
KB
-rw-r--r--
2017-04-04 16:40
example.py
8.14
KB
-rw-r--r--
2017-04-04 16:39
example.pyc
7.19
KB
-rw-r--r--
2017-04-04 16:40
method.py
10.1
KB
-rw-r--r--
2017-04-04 16:39
method.pyc
7.63
KB
-rw-r--r--
2017-04-04 16:40
paginator.py
6.82
KB
-rw-r--r--
2017-04-04 16:39
paginator.pyc
4.89
KB
-rw-r--r--
2017-04-04 16:40
params.py
9.14
KB
-rw-r--r--
2017-04-04 16:39
params.pyc
8.15
KB
-rw-r--r--
2017-04-04 16:40
service.py
3.4
KB
-rw-r--r--
2017-04-04 16:39
service.pyc
3.8
KB
-rw-r--r--
2017-04-04 16:40
shape.py
4.65
KB
-rw-r--r--
2017-04-04 16:39
shape.pyc
3.65
KB
-rw-r--r--
2017-04-04 16:40
sharedexample.py
9.01
KB
-rw-r--r--
2017-04-04 16:39
sharedexample.pyc
8.17
KB
-rw-r--r--
2017-04-04 16:40
utils.py
6.54
KB
-rw-r--r--
2017-04-04 16:39
utils.pyc
6.66
KB
-rw-r--r--
2017-04-04 16:40
waiter.py
3.74
KB
-rw-r--r--
2017-04-04 16:39
waiter.pyc
3.31
KB
-rw-r--r--
2017-04-04 16:40
Save
Rename
# Copyright 2015 Amazon.com, Inc. or its affiliates. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"). You # may not use this file except in compliance with the License. A copy of # the License is located at # # http://aws.amazon.com/apache2.0/ # # or in the "license" file accompanying this file. This file is # distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF # ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. import inspect from botocore.docs.utils import get_official_service_name from botocore.docs.method import document_custom_method from botocore.docs.method import document_model_driven_method from botocore.docs.method import get_instance_public_methods from botocore.docs.sharedexample import document_shared_examples class ClientDocumenter(object): def __init__(self, client, shared_examples=None): self._client = client self._shared_examples = shared_examples if self._shared_examples is None: self._shared_examples = {} self._service_name = self._client.meta.service_model.service_name def document_client(self, section): """Documents a client and its methods :param section: The section to write to. """ self._add_title(section) self._add_class_signature(section) client_methods = get_instance_public_methods(self._client) self._add_client_intro(section, client_methods) self._add_client_methods(section, client_methods) def _add_title(self, section): section.style.h2('Client') def _add_client_intro(self, section, client_methods): section = section.add_new_section('intro') # Write out the top level description for the client. official_service_name = get_official_service_name( self._client.meta.service_model) section.write( 'A low-level client representing %s' % official_service_name) # Write out the client example instantiation. self._add_client_creation_example(section) # List out all of the possible client methods. section.style.new_line() section.write('These are the available methods:') section.style.new_line() class_name = self._client.__class__.__name__ for method_name in sorted(client_methods): section.style.li(':py:meth:`~%s.Client.%s`' % ( class_name, method_name)) def _add_class_signature(self, section): section.style.start_sphinx_py_class( class_name='%s.Client' % self._client.__class__.__name__) def _add_client_creation_example(self, section): section.style.start_codeblock() section.style.new_line() section.write( 'client = session.create_client(\'{service}\')'.format( service=self._service_name) ) section.style.end_codeblock() def _add_client_methods(self, section, client_methods): section = section.add_new_section('methods') for method_name in sorted(client_methods): self._add_client_method( section, method_name, client_methods[method_name]) def _add_client_method(self, section, method_name, method): section = section.add_new_section(method_name) if self._is_custom_method(method_name): self._add_custom_method(section, method_name, method) else: self._add_model_driven_method(section, method_name) def _is_custom_method(self, method_name): return method_name not in self._client.meta.method_to_api_mapping def _add_custom_method(self, section, method_name, method): document_custom_method(section, method_name, method) def _add_model_driven_method(self, section, method_name): service_model = self._client.meta.service_model operation_name = self._client.meta.method_to_api_mapping[method_name] operation_model = service_model.operation_model(operation_name) example_prefix = 'response = client.%s' % method_name document_model_driven_method( section, method_name, operation_model, event_emitter=self._client.meta.events, method_description=operation_model.documentation, example_prefix=example_prefix, ) # Add the shared examples shared_examples = self._shared_examples.get(operation_name) if shared_examples: document_shared_examples( section, operation_model, example_prefix, shared_examples)