mirror of
https://github.com/python/cpython.git
synced 2025-08-04 08:59:19 +00:00
__all__ for several more modules
This commit is contained in:
parent
81b6ae7ef7
commit
c62c81e013
12 changed files with 35 additions and 0 deletions
|
@ -14,6 +14,8 @@ Based on the J. Myers POP3 draft, Jan. 96
|
||||||
|
|
||||||
import re, socket
|
import re, socket
|
||||||
|
|
||||||
|
__all__ = ["POP3","error_proto"]
|
||||||
|
|
||||||
# Exception raised when an error or invalid response is received:
|
# Exception raised when an error or invalid response is received:
|
||||||
|
|
||||||
class error_proto(Exception): pass
|
class error_proto(Exception): pass
|
||||||
|
|
|
@ -53,6 +53,8 @@ f.lock(mode [, len [, start [, whence]]])
|
||||||
query only
|
query only
|
||||||
"""
|
"""
|
||||||
|
|
||||||
|
__all__ = ["open","fileopen","SEEK_SET","SEEK_CUR","SEEK_END"]
|
||||||
|
|
||||||
class _posixfile_:
|
class _posixfile_:
|
||||||
"""File wrapper class that provides extra POSIX file routines."""
|
"""File wrapper class that provides extra POSIX file routines."""
|
||||||
|
|
||||||
|
|
|
@ -13,6 +13,11 @@ for manipulation of the pathname component of URLs.
|
||||||
import os
|
import os
|
||||||
import stat
|
import stat
|
||||||
|
|
||||||
|
__all__ = ["normcase","isabs","join","splitdrive","split","splitext",
|
||||||
|
"basename","dirname","commonprefix","getsize","getmtime",
|
||||||
|
"getatime","islink","exists","isdir","isfile","ismount",
|
||||||
|
"walk","expanduser","expandvars","normpath","abspath",
|
||||||
|
"samefile","sameopenfile","samestat"]
|
||||||
|
|
||||||
# Normalize the case of a pathname. Trivial in Posix, string.lower on Mac.
|
# Normalize the case of a pathname. Trivial in Posix, string.lower on Mac.
|
||||||
# On MS-DOS this may also turn slashes into backslashes; however, other
|
# On MS-DOS this may also turn slashes into backslashes; however, other
|
||||||
|
|
|
@ -41,6 +41,8 @@ try:
|
||||||
except ImportError:
|
except ImportError:
|
||||||
from StringIO import StringIO
|
from StringIO import StringIO
|
||||||
|
|
||||||
|
__all__ = ["pprint","pformat","isreadable","isrecursive","saferepr",
|
||||||
|
"PrettyPrinter"]
|
||||||
|
|
||||||
def pprint(object, stream=None):
|
def pprint(object, stream=None):
|
||||||
"""Pretty-print a Python object to a stream [default is sys.sydout]."""
|
"""Pretty-print a Python object to a stream [default is sys.sydout]."""
|
||||||
|
|
|
@ -87,6 +87,8 @@ This module also defines an exception 'error'.
|
||||||
import sys
|
import sys
|
||||||
from pcre import *
|
from pcre import *
|
||||||
|
|
||||||
|
__all__ = ["match","search","sub","subn","split","findall","escape","compile"]
|
||||||
|
|
||||||
#
|
#
|
||||||
# First, the public part of the interface:
|
# First, the public part of the interface:
|
||||||
#
|
#
|
||||||
|
|
|
@ -40,6 +40,7 @@ import os
|
||||||
import time
|
import time
|
||||||
import marshal
|
import marshal
|
||||||
|
|
||||||
|
__all__ = ["run","help","Profile"]
|
||||||
|
|
||||||
# Sample timer for use with
|
# Sample timer for use with
|
||||||
#i_count = 0
|
#i_count = 0
|
||||||
|
|
|
@ -39,6 +39,8 @@ import re
|
||||||
|
|
||||||
import fpformat
|
import fpformat
|
||||||
|
|
||||||
|
__all__ = ["Stats"]
|
||||||
|
|
||||||
class Stats:
|
class Stats:
|
||||||
"""This class is used for creating reports from data generated by the
|
"""This class is used for creating reports from data generated by the
|
||||||
Profile class. It is a "friend" of that class, and imports data either
|
Profile class. It is a "friend" of that class, and imports data either
|
||||||
|
|
|
@ -10,6 +10,8 @@ from select import select
|
||||||
import os, FCNTL
|
import os, FCNTL
|
||||||
import tty
|
import tty
|
||||||
|
|
||||||
|
__all__ = ["openpty","fork","spawn"]
|
||||||
|
|
||||||
STDIN_FILENO = 0
|
STDIN_FILENO = 0
|
||||||
STDOUT_FILENO = 1
|
STDOUT_FILENO = 1
|
||||||
STDERR_FILENO = 2
|
STDERR_FILENO = 2
|
||||||
|
|
|
@ -6,6 +6,8 @@ This module has intimate knowledge of the format of .pyc files.
|
||||||
import imp
|
import imp
|
||||||
MAGIC = imp.get_magic()
|
MAGIC = imp.get_magic()
|
||||||
|
|
||||||
|
__all__ = ["compile"]
|
||||||
|
|
||||||
def wr_long(f, x):
|
def wr_long(f, x):
|
||||||
"""Internal; write a 32-bit int to a file in little-endian order."""
|
"""Internal; write a 32-bit int to a file in little-endian order."""
|
||||||
f.write(chr( x & 0xff))
|
f.write(chr( x & 0xff))
|
||||||
|
|
|
@ -59,6 +59,8 @@ import imp
|
||||||
import re
|
import re
|
||||||
import string
|
import string
|
||||||
|
|
||||||
|
__all__ = ["readmodule"]
|
||||||
|
|
||||||
TABWIDTH = 8
|
TABWIDTH = 8
|
||||||
|
|
||||||
_getnext = re.compile(r"""
|
_getnext = re.compile(r"""
|
||||||
|
|
|
@ -4,6 +4,8 @@
|
||||||
|
|
||||||
# (Dec 1991 version).
|
# (Dec 1991 version).
|
||||||
|
|
||||||
|
__all__ = ["encode","decode"]
|
||||||
|
|
||||||
ESCAPE = '='
|
ESCAPE = '='
|
||||||
MAXLINESIZE = 76
|
MAXLINESIZE = 76
|
||||||
HEX = '0123456789ABCDEF'
|
HEX = '0123456789ABCDEF'
|
||||||
|
|
|
@ -99,4 +99,15 @@ check_all("pdb")
|
||||||
check_all("pickle")
|
check_all("pickle")
|
||||||
check_all("pipes")
|
check_all("pipes")
|
||||||
check_all("popen2")
|
check_all("popen2")
|
||||||
|
check_all("poplib")
|
||||||
|
check_all("posixfile")
|
||||||
|
check_all("posixpath")
|
||||||
|
check_all("pprint")
|
||||||
|
check_all("pre")
|
||||||
|
check_all("profile")
|
||||||
|
check_all("pstats")
|
||||||
|
check_all("pty")
|
||||||
|
check_all("py_compile")
|
||||||
|
check_all("pyclbr")
|
||||||
|
check_all("quopri")
|
||||||
check_all("robotparser")
|
check_all("robotparser")
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue