Debian Codegraph @

source/io.h

raw symbols SCIP
1 #ifndef AWS_CRT_PYTHON_IO_H
2 #define AWS_CRT_PYTHON_IO_H
3 /**
4 * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
5 * SPDX-License-Identifier: Apache-2.0.
6 */
7
8 /**
9 * This file includes definitions for common aws-c-io functions.
10 */
11
12 #include "module.h"
13
14 struct aws_socket_options;
15
16 /**
17 * Init aws_socket_options from SocketOptions. Returns false and sets python exception if error occurred.
18 */
19 bool aws_py_socket_options_init(struct aws_socket_options *socket_options, PyObject *py_socket_options);
20
21 /**
22 * Returns a capsule for logging and starts the logging sub-system
23 */
24 PyObject *aws_py_init_logging(PyObject *self, PyObject *args);
25
26 /**
27 * Change logging level of the global logger.
28 */
29 PyObject *aws_py_set_log_level(PyObject *self, PyObject *args);
30 PyObject *aws_py_init_python_logging(PyObject *self, PyObject *args);
31
32 /**
33 * Returns True if ALPN is available, False if it is not.
34 */
35 PyObject *aws_py_is_alpn_available(PyObject *self, PyObject *args);
36
37 /**
38 * Returns True if the input TLS Cipher Preference Enum is supported on the current platform. False otherwise.
39 */
40 PyObject *aws_py_is_tls_cipher_supported(PyObject *self, PyObject *args);
41
42 /**
43 * Create a new event_loop_group to be managed by a Python Capsule.
44 */
45 PyObject *aws_py_event_loop_group_new(PyObject *self, PyObject *args);
46
47 /**
48 * Create a new default host_resolver to be managed by a Python Capsule.
49 */
50 PyObject *aws_py_host_resolver_new_default(PyObject *self, PyObject *args);
51
52 /**
53 * Create a new client_bootstrap to be managed by a Python Capsule.
54 */
55 PyObject *aws_py_client_bootstrap_new(PyObject *self, PyObject *args);
56
57 /**
58 * Create a new tls_ctx to be managed by a Python Capsule.
59 */
60 PyObject *aws_py_client_tls_ctx_new(PyObject *self, PyObject *args);
61
62 PyObject *aws_py_tls_connections_options_new_from_ctx(PyObject *self, PyObject *args);
63
64 PyObject *aws_py_tls_connection_options_set_alpn_list(PyObject *self, PyObject *args);
65
66 PyObject *aws_py_tls_connection_options_set_server_name(PyObject *self, PyObject *args);
67
68 /**
69 * Create a new aws_input_stream to be managed by a Python capsule.
70 */
71 PyObject *aws_py_input_stream_new(PyObject *self, PyObject *args);
72
73 /**
74 * Create a new aws_pkcs11_lib to be managed by a Python capsule.
75 */
76 PyObject *aws_py_pkcs11_lib_new(PyObject *self, PyObject *args);
77
78 /* Given a python object, return a pointer to its underlying native type.
79 * If NULL is returned, a python error has been set */
80
81 struct aws_event_loop_group *aws_py_get_event_loop_group(PyObject *event_loop_group);
82 struct aws_host_resolver *aws_py_get_host_resolver(PyObject *host_resolver);
83 struct aws_client_bootstrap *aws_py_get_client_bootstrap(PyObject *client_bootstrap);
84 struct aws_tls_ctx *aws_py_get_tls_ctx(PyObject *tls_ctx);
85 struct aws_tls_connection_options *aws_py_get_tls_connection_options(PyObject *tls_connection_options);
86 struct aws_input_stream *aws_py_get_input_stream(PyObject *input_stream);
87 struct aws_pkcs11_lib *aws_py_get_pkcs11_lib(PyObject *pkcs11_lib);
88
89 #endif /* AWS_CRT_PYTHON_IO_H */