massive update, probably broken
[dotfiles/.git] / .config / coc / extensions / coc-python-data / languageServer.0.5.59 / Typeshed / third_party / 2and3 / pymysql / connections.pyi
1 from typing import Any, Optional, Type\r
2 from .charset import MBLENGTH as MBLENGTH, charset_by_name as charset_by_name, charset_by_id as charset_by_id\r
3 from .cursors import Cursor as Cursor\r
4 from .constants import FIELD_TYPE as FIELD_TYPE, FLAG as FLAG\r
5 from .constants import SERVER_STATUS as SERVER_STATUS\r
6 from .constants import CLIENT as CLIENT\r
7 from .constants import COMMAND as COMMAND\r
8 from .util import join_bytes as join_bytes, byte2int as byte2int, int2byte as int2byte\r
9 from .converters import escape_item as escape_item, encoders as encoders, decoders as decoders\r
10 from .err import raise_mysql_exception as raise_mysql_exception, Warning as Warning, Error as Error, InterfaceError as InterfaceError, DataError as DataError, DatabaseError as DatabaseError, OperationalError as OperationalError, IntegrityError as IntegrityError, InternalError as InternalError, NotSupportedError as NotSupportedError, ProgrammingError as ProgrammingError\r
11 \r
12 sha_new = ...  # type: Any\r
13 SSL_ENABLED = ...  # type: Any\r
14 DEFAULT_USER = ...  # type: Any\r
15 DEBUG = ...  # type: Any\r
16 NULL_COLUMN = ...  # type: Any\r
17 UNSIGNED_CHAR_COLUMN = ...  # type: Any\r
18 UNSIGNED_SHORT_COLUMN = ...  # type: Any\r
19 UNSIGNED_INT24_COLUMN = ...  # type: Any\r
20 UNSIGNED_INT64_COLUMN = ...  # type: Any\r
21 UNSIGNED_CHAR_LENGTH = ...  # type: Any\r
22 UNSIGNED_SHORT_LENGTH = ...  # type: Any\r
23 UNSIGNED_INT24_LENGTH = ...  # type: Any\r
24 UNSIGNED_INT64_LENGTH = ...  # type: Any\r
25 DEFAULT_CHARSET = ...  # type: Any\r
26 \r
27 def dump_packet(data): ...\r
28 \r
29 SCRAMBLE_LENGTH_323 = ...  # type: Any\r
30 \r
31 class RandStruct_323:\r
32     max_value = ...  # type: Any\r
33     seed1 = ...  # type: Any\r
34     seed2 = ...  # type: Any\r
35     def __init__(self, seed1, seed2): ...\r
36     def my_rnd(self): ...\r
37 \r
38 def pack_int24(n): ...\r
39 def unpack_uint16(n): ...\r
40 def unpack_int24(n): ...\r
41 def unpack_int32(n): ...\r
42 def unpack_int64(n): ...\r
43 def defaulterrorhandler(connection, cursor, errorclass, errorvalue): ...\r
44 \r
45 class MysqlPacket:\r
46     connection = ...  # type: Any\r
47     def __init__(self, connection): ...\r
48     def packet_number(self): ...\r
49     def get_all_data(self): ...\r
50     def read(self, size): ...\r
51     def read_all(self): ...\r
52     def advance(self, length): ...\r
53     def rewind(self, position=0): ...\r
54     def peek(self, size): ...\r
55     def get_bytes(self, position, length=1): ...\r
56     def read_length_coded_binary(self): ...\r
57     def read_length_coded_string(self): ...\r
58     def is_ok_packet(self): ...\r
59     def is_eof_packet(self): ...\r
60     def is_resultset_packet(self): ...\r
61     def is_error_packet(self): ...\r
62     def check_error(self): ...\r
63     def dump(self): ...\r
64 \r
65 class FieldDescriptorPacket(MysqlPacket):\r
66     def __init__(self, *args): ...\r
67     def description(self): ...\r
68     def get_column_length(self): ...\r
69 \r
70 class Connection:\r
71     errorhandler = ...  # type: Any\r
72     ssl = ...  # type: Any\r
73     host = ...  # type: Any\r
74     port = ...  # type: Any\r
75     user = ...  # type: Any\r
76     password = ...  # type: Any\r
77     db = ...  # type: Any\r
78     unix_socket = ...  # type: Any\r
79     charset = ...  # type: Any\r
80     use_unicode = ...  # type: Any\r
81     client_flag = ...  # type: Any\r
82     cursorclass = ...  # type: Any\r
83     connect_timeout = ...  # type: Any\r
84     messages = ...  # type: Any\r
85     encoders = ...  # type: Any\r
86     decoders = ...  # type: Any\r
87     host_info = ...  # type: Any\r
88     def __init__(self, host='', user=None, passwd='', db=None, port=3306, unix_socket=None, charset='', sql_mode=None, read_default_file=None, conv=..., use_unicode=None, client_flag=0, cursorclass=..., init_command=None, connect_timeout=None, ssl=None, read_default_group=None, compress=None, named_pipe=None): ...\r
89     socket = ...  # type: Any\r
90     rfile = ...  # type: Any\r
91     wfile = ...  # type: Any\r
92     def close(self): ...\r
93     def autocommit(self, value): ...\r
94     def commit(self): ...\r
95     def begin(self) -> None: ...\r
96     def rollback(self): ...\r
97     def escape(self, obj): ...\r
98     def literal(self, obj): ...\r
99     def cursor(self, cursor: Optional[Type[Cursor]] = ...): ...\r
100     def __enter__(self): ...\r
101     def __exit__(self, exc, value, traceback): ...\r
102     def query(self, sql): ...\r
103     def next_result(self, unbuffered: bool = ...): ...\r
104     def affected_rows(self): ...\r
105     def kill(self, thread_id): ...\r
106     def ping(self, reconnect: bool = ...): ...\r
107     def set_charset(self, charset): ...\r
108     def read_packet(self, packet_type=...): ...\r
109     def insert_id(self): ...\r
110     def thread_id(self): ...\r
111     def character_set_name(self): ...\r
112     def get_host_info(self): ...\r
113     def get_proto_info(self): ...\r
114     def get_server_info(self): ...\r
115     def show_warnings(self): ...\r
116     Warning = ...  # type: Any\r
117     Error = ...  # type: Any\r
118     InterfaceError = ...  # type: Any\r
119     DatabaseError = ...  # type: Any\r
120     DataError = ...  # type: Any\r
121     OperationalError = ...  # type: Any\r
122     IntegrityError = ...  # type: Any\r
123     InternalError = ...  # type: Any\r
124     ProgrammingError = ...  # type: Any\r
125     NotSupportedError = ...  # type: Any\r
126 \r
127 class MySQLResult:\r
128     connection = ...  # type: Any\r
129     affected_rows = ...  # type: Any\r
130     insert_id = ...  # type: Any\r
131     server_status = ...  # type: Any\r
132     warning_count = ...  # type: Any\r
133     message = ...  # type: Any\r
134     field_count = ...  # type: Any\r
135     description = ...  # type: Any\r
136     rows = ...  # type: Any\r
137     has_next = ...  # type: Any\r
138     def __init__(self, connection): ...\r
139     first_packet = ...  # type: Any\r
140     def read(self): ...\r