database
AddDatabase
dataclass
Source code in zendriver/cdp/database.py
Database
dataclass
Database object.
Source code in zendriver/cdp/database.py
domain: str
instance-attribute
id_: DatabaseId
instance-attribute
name: str
instance-attribute
version: str
instance-attribute
__init__(id_, domain, name, version)
from_json(json)
classmethod
DatabaseId
Bases: str
Unique identifier of Database object.
Source code in zendriver/cdp/database.py
__repr__()
from_json(json)
classmethod
Error
dataclass
Database error.
Source code in zendriver/cdp/database.py
code: int
instance-attribute
message: str
instance-attribute
__init__(message, code)
from_json(json)
classmethod
disable()
Disables database tracking, prevents database events from being sent to the client.
Source code in zendriver/cdp/database.py
enable()
Enables database tracking, database events will now be delivered to the client.
Source code in zendriver/cdp/database.py
execute_sql(database_id, query)
Parameters:
Name | Type | Description | Default |
---|---|---|---|
database_id
|
DatabaseId
|
|
required |
query
|
str
|
|
required |
Returns:
Type | Description |
---|---|
Generator[T_JSON_DICT, T_JSON_DICT, Tuple[Optional[List[str]], Optional[List[Any]], Optional[Error]]]
|
A tuple with the following items: 0. columnNames - 1. values - 2. sqlError - |
Source code in zendriver/cdp/database.py
get_database_table_names(database_id)
Parameters:
Name | Type | Description | Default |
---|---|---|---|
database_id
|
DatabaseId
|
|
required |
Returns:
Type | Description |
---|---|
Generator[T_JSON_DICT, T_JSON_DICT, List[str]]
|
|