概述
系统学习
参见[:PyBooks:Python图书概览]
- 对于语言特性的学习来说,特别推荐以下几本
- 《Python Tutorial》 -- 最新,最权威,公开文档
- 《A Byte of Python》 -- 简洁明了,浅显易懂,公开文档
- 《Learning Python》 -- 讲解最细致,最深入
《Text Process in Python》的附录A :[:TPiP/AppendixA:选择性的令人印象深刻的 python 简短回顾] -- “对 python 的超精简的但绝不失深度的介绍” from 译者 HuangYi
专题剖析
内置类型和操作符
[http://www.voidspace.org.uk/python/articles/python_datatypes.shtml A Very Brief Introduction to Python And its Data-Types]
语句和语法
[:PyBatteriesIncluded:内省的威力]
[http://www.python.org/dev/peps/pep-0318/ PEP318 : Decorators for Functions and Methods]
[:WeiZhong/DecoratorsInPython24:Python2.4中的新东西(1):函数和方法的修饰符] by WeiZhong
[http://www.donews.net/limodou/archive/2004/12/20/208356.aspx Decorator 应用:使用decorator的线程同步] -- by limodou
[:Py25yieldNote:Py2.5 yield 详说] -- shhgs 和 limodou 关于 yield 在2.5中语法加强的探讨
名字空间与对象模型
概述
Python官方网站上的[http://www.python.org/doc/newstyle.html New-style Classes经典文档汇集]
- 两篇系统讲解的精彩文档
[http://www.cafepy.com/article/python_types_and_objects Python Types and Objects]
[http://www.cafepy.com/article/python_attributes_and_methods/ Python Attributes and Methods]
[:PyNewStyleClass:Python中的新型类及其实例详解] -- WeiZhong 节译自《Python in a Nutshell》(第一版)
Metaclass
[:MetaClassInPython:Python中的元类(metaclass)] -- WeiZhong 节译自《Python in a Nutshell》(第一版)
[http://www.python.org/pycon/dc2004/papers/24/metaclasses-pycon.pdf Python Metaclasses: Who? Why? When?] -- 2004年 PyCon 上的一篇讲稿
[http://www.voidspace.org.uk/python/articles/metaclasses.shtml Eliminating self with Metaclasses]
- Python 在成员方法中对 self 的显式声明往往会令初学者困惑和不习惯,Michael Foord在这篇文章中利用 metaclass 和 bytecode 实现了一种不需要显式声明 self 参数的类定义方式。
HuangYi 的心得,发表于[http://codeplayer.blogspot.com 他的blog]
[http://codeplayer.blogspot.com/2006/12/metaclass-in-python.html metaclass in python (part 1)]
[http://codeplayer.blogspot.com/2006/12/metaclass-in-python-part-2.html metaclass in python (part 1)]
Descriptor
[http://users.rcn.com/python/download/Descriptor.htm How-To Guide for Descriptors] -- descriptor 机制详解,by Raymond Hettinger
[http://codeplayer.blogspot.com/2006/12/python-method-function-descriptor.html 理解 python 的 method 和 function 兼谈 descriptor] by HuangYi
异常机制
语言进化
[http://docs.python.org/dev/whatsnew/whatsnew25.html What's New in Python 2.5]
[http://www.aleax.it/Python/py25.pdf Python 2.5 Slides by Alex Martelli]
[http://docs.python.org/dev/whatsnew/ What's New in Python 2.6]
其它
[http://codeplayer.blogspot.com/2006/09/getcaller.html 意外收获:get_caller]
[http://www.donews.net/limodou/archive/2004/12/28/218443.aspx Python中的Lazy计算]
参考
["ThinkIntoPython"]
["PythonZhDoc"]
["PythoNology"]
[http://blog.donews.com/limodou/ limodou 的学习记录] limodou 的 blog
[http://codeplayer.blogspot.com 白菜] -- HuangYi 的 blog