Move 2.7 to 2 (#635)

Closes #579.
This commit is contained in:
Guido van Rossum
2016-10-26 16:24:49 -07:00
committed by GitHub
parent d60bea14f6
commit cb97bb54c0
338 changed files with 0 additions and 0 deletions

View File

@@ -0,0 +1,8 @@
# Stubs for email.MIMEText (Python 2)
#
# NOTE: This dynamically typed stub was automatically generated by stubgen.
from email.mime.nonmultipart import MIMENonMultipart
class MIMEText(MIMENonMultipart):
def __init__(self, _text, _subtype=..., _charset=...) -> None: ...

View File

@@ -0,0 +1,6 @@
from typing import IO, Any, AnyStr
def message_from_string(s: AnyStr, *args, **kwargs): ...
def message_from_bytes(s: str, *args, **kwargs): ...
def message_from_file(fp: IO[AnyStr], *args, **kwargs): ...
def message_from_binary_file(fp: IO[str], *args, **kwargs): ...

View File

@@ -0,0 +1,44 @@
# Stubs for email._parseaddr (Python 2)
#
# NOTE: This dynamically typed stub was automatically generated by stubgen.
from typing import Any
def parsedate_tz(data): ...
def parsedate(data): ...
def mktime_tz(data): ...
def quote(str): ...
class AddrlistClass:
specials = ... # type: Any
pos = ... # type: Any
LWS = ... # type: Any
CR = ... # type: Any
FWS = ... # type: Any
atomends = ... # type: Any
phraseends = ... # type: Any
field = ... # type: Any
commentlist = ... # type: Any
def __init__(self, field): ...
def gotonext(self): ...
def getaddrlist(self): ...
def getaddress(self): ...
def getrouteaddr(self): ...
def getaddrspec(self): ...
def getdomain(self): ...
def getdelimited(self, beginchar, endchars, allowcomments=True): ...
def getquote(self): ...
def getcomment(self): ...
def getdomainliteral(self): ...
def getatom(self, atomends=None): ...
def getphraselist(self): ...
class AddressList(AddrlistClass):
addresslist = ... # type: Any
def __init__(self, field): ...
def __len__(self): ...
def __add__(self, other): ...
def __iadd__(self, other): ...
def __sub__(self, other): ...
def __isub__(self, other): ...
def __getitem__(self, index): ...

View File

View File

@@ -0,0 +1,10 @@
# Stubs for email.mime.base (Python 2)
#
# NOTE: This dynamically typed stub was automatically generated by stubgen.
# import message
# TODO
#class MIMEBase(message.Message):
class MIMEBase:
def __init__(self, _maintype, _subtype, **_params) -> None: ...

View File

@@ -0,0 +1,8 @@
# Stubs for email.mime.multipart (Python 2)
#
# NOTE: This dynamically typed stub was automatically generated by stubgen.
from email.mime.base import MIMEBase
class MIMEMultipart(MIMEBase):
def __init__(self, _subtype=..., boundary=..., _subparts=..., **_params) -> None: ...

View File

@@ -0,0 +1,8 @@
# Stubs for email.mime.nonmultipart (Python 2)
#
# NOTE: This dynamically typed stub was automatically generated by stubgen.
from email.mime.base import MIMEBase
class MIMENonMultipart(MIMEBase):
def attach(self, payload): ...

View File

@@ -0,0 +1,8 @@
# Stubs for email.mime.text (Python 2)
#
# NOTE: This dynamically typed stub was automatically generated by stubgen.
from email.mime.nonmultipart import MIMENonMultipart
class MIMEText(MIMENonMultipart):
def __init__(self, _text, _subtype=..., _charset=...) -> None: ...

22
stdlib/2/email/utils.pyi Normal file
View File

@@ -0,0 +1,22 @@
# Stubs for email.utils (Python 2)
#
# Derived from stub automatically generated by stubgen.
from email._parseaddr import AddressList as _AddressList
from email._parseaddr import mktime_tz as mktime_tz
from email._parseaddr import parsedate as _parsedate
from email._parseaddr import parsedate_tz as _parsedate_tz
from quopri import decodestring as _qdecode
def formataddr(pair): ...
def getaddresses(fieldvalues): ...
def formatdate(timeval=None, localtime=False, usegmt=False): ...
def make_msgid(idstring=None): ...
def parsedate(data): ...
def parsedate_tz(data): ...
def parseaddr(addr): ...
def unquote(str): ...
def decode_rfc2231(s): ...
def encode_rfc2231(s, charset=None, language=None): ...
def decode_params(params): ...
def collapse_rfc2231_value(value, errors=..., fallback_charset=...): ...