Current Path : /usr/lib/python2.7/ |
Current File : //usr/lib/python2.7/dircache.pyc |
ó ÿ–|_c @ sr d Z d d l m Z e d d d ƒ[ d d l Z d d d d g Z i a d „ Z d „ Z e Z d „ Z d S( së Read and cache directory listings. The listdir() routine returns a sorted list of the files in a directory, using a cache to avoid reading the directory more often than necessary. The annotate() routine appends slashes to directories.iÿÿÿÿ( t warnpy3ks2 the dircache module has been removed in Python 3.0t stackleveli Nt listdirt opendirt annotatet resetc C s i a d S( s Reset the cache completely.N( t cache( ( ( s /usr/lib/python2.7/dircache.pyR s c C sŠ y t | \ } } t | =Wn t k r; d g } } n Xt j | ƒ j } | | k rv t j | ƒ } | j ƒ n | | f t | <| S( s% List directory contents, using cache.iÿÿÿÿ( R t KeyErrort ost statt st_mtimeR t sort( t patht cached_mtimet listt mtime( ( s /usr/lib/python2.7/dircache.pyR s c C s[ xT t t | ƒ ƒ D]@ } t j j t j j | | | ƒ ƒ r | | d | | <q q Wd S( s Add '/' suffixes to directories.t /N( t ranget lenR R t isdirt join( t headR t i( ( s /usr/lib/python2.7/dircache.pyR % s %( t __doc__t warningsR R t __all__R R R R R ( ( ( s /usr/lib/python2.7/dircache.pyt <module> s