Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

pythonÄ£¿éÖ®poplib: ÓÃpop3ÊÕÈ¡Óʼþ

 
À´Ô´£º ×÷Õߣºzhaoweikid ·¢²¼Ê±¼ä£º2007-07-04 ÔĶÁ´ÎÊý£º
    pythonµÄpoplibÄ£¿éÊÇÓÃÀ´´Ópop3ÊÕÈ¡ÓʼþµÄ£¬Ò²¿ÉÒÔ˵ËüÊÇ´¦ÀíÓʼþµÄµÚÒ»²½¡£
    POP3ЭÒé²¢²»¸´ÔÓ£¬ËüÒ²ÊDzÉÓõÄÒ»ÎÊÒ»´ðʽµÄ·½Ê½£¬ÄãÏò·þÎñÆ÷·¢ËÍÒ»¸öÃüÁ·þÎñÆ÷±ØÈ»»á»Ø¸´Ò»¸öÐÅÏ¢¡£pop3ÃüÁîÂëÈçÏ£º
¡¡ÃüÁî¡¡poplib·½·¨¡¡¡¡¡¡¡¡²ÎÊý¡¡¡¡¡¡ ״̬¡¡¡¡¡¡¡¡¡¡ÃèÊö
-----------------------------------------------------------------------------------------------
USER¡¡¡¡user ¡¡ username¡¡¡¡ÈÏ¿É¡¡¡¡Óû§Ãû£¬´ËÃüÁîÓëÏÂÃæµÄpassÃüÁîÈô³É¹¦£¬½«µ¼ÖÂ״̬ת»»
PASS¡¡¡¡pass_ ¡¡¡¡password¡¡¡¡ÈÏ¿É¡¡¡¡Óû§ÃÜÂë¡¡¡¡¡¡
APOP¡¡¡¡apop¡¡¡¡¡¡Name,Digest ÈÏ¿É¡¡ DigestÊÇMD5ÏûÏ¢ÕªÒª
-----------------------------------------------------------------------------------------------
STAT¡¡¡¡stat ¡¡¡¡None¡¡¡¡¡¡ ´¦Àí¡¡¡¡ÇëÇó·þÎñÆ÷·¢»Ø¹ØÓÚÓÊÏäµÄͳ¼Æ×ÊÁÏ£¬ÈçÓʼþ×ÜÊýºÍ×Ü×Ö½ÚÊý
UIDL¡¡¡¡uidl¡¡¡¡¡¡[Msg#]¡¡¡¡ ´¦Àí¡¡¡¡·µ»ØÓʼþµÄΨһ±êʶ·û£¬POP3»á»°µÄÿ¸ö±êʶ·û¶¼½«ÊÇΨһµÄ
LIST¡¡¡¡list¡¡¡¡¡¡[Msg#]¡¡¡¡ ´¦Àí¡¡¡¡·µ»ØÓʼþÊýÁ¿ºÍÿ¸öÓʼþµÄ´óС
RETR¡¡¡¡retr¡¡¡¡¡¡[Msg#]¡¡    ´¦Àí¡¡¡¡·µ»ØÓɲÎÊý±êʶµÄÓʼþµÄÈ«²¿Îı¾
DELE¡¡¡¡dele¡¡¡¡¡¡[Msg#]¡¡    ´¦Àí¡¡¡¡·þÎñÆ÷½«ÓɲÎÊý±êʶµÄÓʼþ±ê¼ÇΪɾ³ý£¬ÓÉquitÃüÁîÖ´ÐÐ
RSET¡¡¡¡rset¡¡¡¡¡¡None¡¡¡¡    ´¦Àí¡¡ ·þÎñÆ÷½«ÖØÖÃËùÓбê¼ÇΪɾ³ýµÄÓʼþ£¬ÓÃÓÚ³·ÏûDELEÃüÁî
TOP¡¡¡¡ top ¡¡¡¡ [Msg#]¡¡¡¡ ´¦Àí¡¡ ·þÎñÆ÷½«·µ»ØÓɲÎÊý±êʶµÄÓʼþÇ°nÐÐÄÚÈÝ£¬n±ØÐëÊÇÕýÕûÊý
NOOP¡¡¡¡noop¡¡¡¡¡¡None¡¡¡¡¡¡¡¡´¦Àí¡¡¡¡·þÎñÆ÷·µ»ØÒ»¸ö¿Ï¶¨µÄÏìÓ¦
----------------------------------------------------------------------------------------------
QUIT¡¡¡¡quit¡¡    None¡¡¡¡¡¡¡¡¸üС¡¡¡¡¡¡¡¡¡
    pythonµÄpoplibÒ²Õë¶ÔÕâЩÃüÁî·Ö±ðÌṩÁ˶ÔÓ¦µÄ·½·¨,ÉÏÃæÔÚµÚ¶þÁÐÀïÒѾ­±ê³öÀ´¡£ÊÕÈ¡ÓʼþµÄ¹ý³ÌÒ»°ãÊÇ£º
1. Á¬½Ópop3·þÎñÆ÷ (poplib.POP3.__init__)
2. ·¢ËÍÓû§ÃûºÍÃÜÂë½øÐÐÑéÖ¤ (poplib.POP3.user poplib.POP3.pass_)
3. »ñÈ¡ÓÊÏäÖÐÐżþÐÅÏ¢ (poplib.POP3.stat)
4. ÊÕÈ¡Óʼþ (poplib.POP3.retr)
5. ɾ³ýÓʼþ (poplib.POP3.dele)
6. Í˳ö (poplib.POP3.quit)
    ×¢ÒâµÄÊÇ£¬É


Ïà¹ØÎĵµ£º

Python IDE±È½ÏÓëÍƼö¡¾z¡¿

 ÎÒÏȸøÒ»¸ö³õ²½µÄ±í¸ñ°É£¬´ó¼ÒÈç¹ûÓÐʲôÒâ¼û£¬»òÓв¹³ä£¬»¶Ó­Ìá³ö¡£ÓÐЩÎÒûÓÐÓùý£¬ÏȲ»Ð´ÁË¡£
ÒÔÏÂÊÇÎÒʹÓùýµÄpython IDE:
     
³ýÁËPythonWin, VisualPythonÖ»Ö§³ÖWindows£¬ÆäËü¶¼ÖÁÉÙÖ§³ÖWin/Linux/Mac¡£
¸÷ÏÒ壺
×Ô¶¯²¹È«£º±äÁ¿/º¯ÊýÃû´òµ½Ò»°ëʱ£¬Ìáʾ¿ÉÄܵÄÍêÕûµÄ±äÁ¿/º¯ÊýÃû¡ ......

PythonÓÐÓõÄÄ£¿é

http://chardet.feedparser.org/  ×Ô¶¯¼ì²â±àÂë
http://effbot.org/zone/celementtree.htm  cElementTree
http://github.com/jaybaird/python-bloomfilter bloomfilter
http://docs.python.org/library/threading.html#threading.activeCount threading ......

[¶À¼Ò]Google½«ÏÞÖÆPythonÓïÑÔµÄÓ¦Óà ¿ª·¢ÉçÇøÈÈÒé

2009-11-16 
Collin WinterÊÇPythonÉçÇøһλÆľßÓ°ÏìÁ¦µÄ¿ª·¢Õߣ¬ËûÔøÊÇCPythonÏîÄ¿µÄºËÐÄ¿ª·¢ÕßÖ®Ò»¡¢Ò²ÔøÊÇUnladen Swallow£¨¼ûÎÄĩעÊÍ£©µÄºËÐÄ¿ª·¢Õߣ¬²ÎÓëÁ˺ܶàPythonÏîÄ¿µÄ¿ª·¢¡£½üÀ´´«ÎÅGoogle½«ÔÚÆäÐÂÏîÄ¿ÖÐÏÞÖÆPythonµÄʹÓã¬Îª´ËÓпª·¢Õߣ¨ÒÔK±íʾ£©ÔÚGoogle ÂÛ̳Öй«¿ªÑ¯ÎÊÁËCollin Winter£¬Collin Winte ......

Python¼¸ÖÖ²¢·¢ÊµÏÖ·½°¸µÄÐÔÄܱȽÏ

 
#!/Library/Frameworks/Python.framework/Versions/2.5/bin/python
# encoding: utf-8
import sys, time
import thread
 
SLEEP_TIME = 0.0001
 
def run_benchmark(n, m):
    # print(">> Python 2.5.1, stackless 3.1b3 here (N=%d, M=%d)!\n" % (n, m))
    lock ......

Eclipse+PyDev = Python±à¼­Æ÷£¬

http://www.ibm.com/developerworks/cn/opensource/os-cn-ecl-pydev/Á¬½ÓÕâ¸öÍøÖ·£¬²»»áÈÃÄãʧÍûµÄ¡£
PyDev ¼ò½é
2003Äê7ÔÂ16ÈÕ£¬ÒÔ Fabio Zadrozny ΪÊ×µÄÈýÈË¿ª·¢Ð¡×éÔÚÈ«Çò×î´óµÄ¿ª·ÅÔ´´úÂëÈí¼þ¿ª·¢Æ½Ì¨ºÍ²Ö¿â SourceForge ÉÏ×¢²áÁËÒ»¿îеÄÏîÄ¿£¬¸ÃÏîĿʵÏÖÁËÒ»¸ö¹¦ÄÜÇ¿´óµÄ Eclipse²å¼þ£¬Óû§¿ÉÒÔÍêÈ«ÀûÓà Eclipse À ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ