mirror of
https://github.com/davidhalter/django-stubs.git
synced 2026-02-19 00:04:52 +08:00
59 lines
1.8 KiB
Python
59 lines
1.8 KiB
Python
from typing import (
|
|
Callable,
|
|
List,
|
|
Tuple,
|
|
Union,
|
|
)
|
|
|
|
|
|
class Columns:
|
|
def __init__(
|
|
self,
|
|
table: str,
|
|
columns: List[str],
|
|
quote_name: Callable,
|
|
col_suffixes: Union[List[str], Tuple] = ...
|
|
) -> None: ...
|
|
def __str__(self) -> str: ...
|
|
|
|
|
|
class ForeignKeyName:
|
|
def __init__(
|
|
self,
|
|
from_table: str,
|
|
from_columns: List[str],
|
|
to_table: str,
|
|
to_columns: List[str],
|
|
suffix_template: str,
|
|
create_fk_name: Callable
|
|
) -> None: ...
|
|
def __str__(self) -> str: ...
|
|
def references_column(self, table: str, column: str) -> bool: ...
|
|
def references_table(self, table: str) -> bool: ...
|
|
def rename_column_references(self, table: str, old_column: str, new_column: str) -> None: ...
|
|
|
|
|
|
class IndexName:
|
|
def __init__(self, table: str, columns: List[str], suffix: str, create_index_name: Callable) -> None: ...
|
|
def __str__(self) -> str: ...
|
|
|
|
|
|
class Statement:
|
|
def __init__(self, template: str, **parts) -> None: ...
|
|
def __str__(self) -> str: ...
|
|
def references_column(self, table: str, column: str) -> bool: ...
|
|
def references_table(self, table: str) -> bool: ...
|
|
def rename_table_references(self, old_table: str, new_table: str) -> None: ...
|
|
|
|
|
|
class Table:
|
|
def __init__(self, table: str, quote_name: Callable) -> None: ...
|
|
def __str__(self) -> str: ...
|
|
def references_table(self, table: str) -> bool: ...
|
|
def rename_table_references(self, old_table: str, new_table: str) -> None: ...
|
|
|
|
|
|
class TableColumns:
|
|
def __init__(self, table: str, columns: List[str]) -> None: ...
|
|
def references_column(self, table: str, column: str) -> bool: ...
|
|
def rename_column_references(self, table: str, old_column: str, new_column: str) -> None: ... |