re.pyi 1.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677
  1. from PikaObj import *
  2. A: int
  3. ASCII: int
  4. I: int
  5. IGNORECASE: int
  6. M: int
  7. MULTILINE: int
  8. S: int
  9. DOTALL: int
  10. # here, not as in python, there is no 'UNICODE' flags,
  11. # cause this version only support UTF-8 characters
  12. def __init__(): ...
  13. class Pattern:
  14. def __init__(self):
  15. pass
  16. def __del__(self):
  17. pass
  18. def findall(self, subject: str, *flags) -> list:
  19. pass
  20. def sub(self, repl: str, subjet: str, *count__flags) -> str:
  21. pass
  22. def subn(self, repl: str, subjet: str, *count__flags) -> list:
  23. pass
  24. def match(self, subject: str, *flags) -> Match:
  25. pass
  26. def fullmatch(self, subject: str, *flags) -> Match:
  27. pass
  28. def search(self, subject: str, *flags) -> Match:
  29. pass
  30. def split(self, subject: str, *maxsplit__flags) -> list:
  31. pass
  32. class Match:
  33. def __init__(self):
  34. pass
  35. def __del__(self):
  36. pass
  37. def group(self, *n) -> str:
  38. pass
  39. def groups(self) -> list:
  40. pass
  41. # ! may returns wrong offset when subject contains widechar, like Chinese
  42. # this function returns exactly memory offset between the begin of string and the target substring
  43. def span(self, *group_n) -> list:
  44. pass
  45. def findall(pattern: str, subject: str, *flags) -> list: ...
  46. # def sub(pattern, repl, string, count=0, flags=0)
  47. def sub(pattern: str, repl: str, subjet: str, *count__flags) -> str: ...
  48. def match(pattern: str, subject: str, *flags) -> Match: ...
  49. def fullmatch(pattern: str, subject: str, *flags) -> Match: ...
  50. def search(pattern: str, subject: str, *flags) -> Match: ...
  51. def compile(pattern: str, *flags) -> Pattern: ...
  52. def escape(pattern: str) -> str: ...
  53. # def subn(pattern, repl, string, count=0, flags=0)
  54. def subn(pattern: str, repl: str, subjet: str, *count__flags) -> list: ...
  55. # def finditer(pattern: str, subject: str, *flags):
  56. def split(pattern: str, subject: str, *maxsplit__flags) -> list: ...