File: locks.pyi

package info (click to toggle)
python-django-stubs 5.2.9-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 4,832 kB
  • sloc: python: 5,185; makefile: 15; sh: 8
file content (19 lines) | stat: -rw-r--r-- 418 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
import sys
from ctypes import Structure, Union
from typing import Any

LOCK_SH: int
LOCK_NB: int
LOCK_EX: int

if sys.platform == "win32":
    ULONG_PTR: Any
    PVOID: Any
    class _OFFSET(Structure): ...
    class _OFFSET_UNION(Union): ...
    class OVERLAPPED(Structure): ...

def lock(f: Any, flags: int) -> bool: ...
def unlock(f: Any) -> bool: ...

__all__ = ("LOCK_EX", "LOCK_NB", "LOCK_SH", "lock", "unlock")