Docs4dev
Docs
Docs4dev
  • Tools
  • Privacy
  • GitHub

Search

Loading search index…

No recent searches

No results for "Query here"

  • to select
  • to navigate
  • to close

Search by FlexSearch

On this page

On this page
python / 2.7.15 / all / library-filesys.html

10. 文件和目录访问

本章描述的模块处理磁盘文件和目录。例如,有一些模块用于读取文件的属性,以可移植的方式操作路径以及创建临时文件。本章中模块的完整列表为:

  • 10 .1. os.path —通用路径名操作

  • 10 .2. fileinput —遍历来自多个 Importing 流的行

  • 10 .3. stat —解释 stat()结果

  • 10 .4. statvfs —与 os.statvfs()一起使用的常量

  • 10 .5. filecmp —文件和目录比较

  • 10 .5.1. dircmp 类

  • 10 .6. tempfile —生成临时文件和目录

  • 10 .7. glob — Unix 样式路径名模式扩展

  • 10 .8. fnmatch — Unix 文件名模式匹配

  • 10 .9. linecache —随机访问文本行

  • 10 .10. shutil —高级文件操作

  • 10 .10.1. 目录和文件操作

  • 10 .10.1.1. 复制树示例

    • 10 .10.2. 归档操作
  • 10 .10.2.1. 存档示例

  • 10 .11. dircache —缓存的目录列表

  • 10 .12. macpath — Mac OS 9 路径操作Function

See also

  • Section File Objects

  • Python 内置文件对象的描述。

  • Module os

  • os 界面,包括用于以比内置文件对象低的级别处理文件的Function。

  • Privacy Policy
  • 蜀ICP备14021783号-6
  • Brought to you by Docs4dev