�&ǐk�@'bJ�h�ۊL'}T� :��'2�Z#$��n�a��� �>a��`��_3d�Qpt�/�P -��#5�,�M��� �pA:©�q�����NW��ډ�A���� �9nʺج���� �TSM��{J6?7��r�@�\����D��� �׶���s�f�TJj?"��D��`?��̒� b�#�%�C*v�$�{�$����5Ծ�F�s��y�e/8��h-�f�̰&(����Gj�L:U� 2�� ����v�_k����Y��gp,�k�WF�R������_C�R��N@���R�@�ߔ?A�w9���F("iNa-S���Q�o�3tDMLh*�#4k�T/iQ��Y*�G��m����)��8�hBm/�I�,g�ﯖ���Z��}�Cz�q@´��d.����L�ŕ�,��1�Z�܌�: ̪���F+J-'��c�tvJ8��]Q-��b��y �6;*J`r_�d ��'�G ~p��)'�C,�%F��E(��2�k�����lР�z�!�=t ��_�0��f7��� ;�p�|�U �%Return the names of subfolders in a given folder, recursively.iit,i( R RRR2R3R+t isnumericRR,tislinkR<R-( RR/R0R4R5R6R7R8R9t subsubfolders((s/usr/lib64/python2.7/mhlib.pyR<s,         cCs t||S(s0Return a new Folder object for the named folder.(R(RR/((s/usr/lib64/python2.7/mhlib.pyt openfolderscCset|jd}|r6t|r6t|d}nt}tjtjj|j ||dS(s@Create a new folder (or raise os.error if it cannot be created).sFolder-ProtectiN( RRR?tinttFOLDER_PROTECTR tmkdirRRR!(RR/tprotecttmode((s/usr/lib64/python2.7/mhlib.pyt makefolders cCstjj|j|}xetj|D]T}tjj||}ytj|Wq+tjk r~|jd|q+Xq+Wtj|dS(sDelete a folder. This removes files in the folder but not subdirectories. Raise os.error if deleting the folder itself fails.s%s not deleted, continuing...N(R RRR!R+tunlinkRtrmdir(RR/R0R7R8((s/usr/lib64/python2.7/mhlib.pyt deletefolders N(RRt__doc__R RRRRR!R$R*R1R:R=R<RBRHRK(((s/usr/lib64/python2.7/mhlib.pyR_s           s ^[1-9][0-9]*$cCstj|dk S(N(t numericprogtmatchR (tstr((s/usr/lib64/python2.7/mhlib.pyR?scBseZdZdZdZdZdZdZdZdZ dZ d Z d Z d Z d Zd ZdZdZdZdZddZdZdZdZdZdZdZdZRS(s'Class representing a particular folder.cCs>||_||_tjj|js:td|ndS(s Constructor.s no folder %sN(tmhR/R RRt getfullnameR(RRPR/((s/usr/lib64/python2.7/mhlib.pyRs  cCsd|j|jfS(sString representation.sFolder(%r, %r)(RPR/(R((s/usr/lib64/python2.7/mhlib.pyRscGs|jj|dS(sError message handler.N(RPR(RR((s/usr/lib64/python2.7/mhlib.pyRscCstjj|jj|jS(s'Return the full pathname of the folder.(R RRRPR/(R((s/usr/lib64/python2.7/mhlib.pyRQscCstjj|jtS(s8Return the full pathname of the folder's sequences file.(R RRRQt MH_SEQUENCES(R((s/usr/lib64/python2.7/mhlib.pytgetsequencesfilenamescCstjj|jt|S(s4Return the full pathname of a message in the folder.(R RRRQRO(Rtn((s/usr/lib64/python2.7/mhlib.pytgetmessagefilename scCs|jj|jS(s!Return list of direct subfolders.(RPR:R/(R((s/usr/lib64/python2.7/mhlib.pyR:scCs|jj|jS(sReturn list of all subfolders.(RPR<R/(R((s/usr/lib64/python2.7/mhlib.pyR<scCsg}tj}|j}x6tj|jD]}||r.||q.q.Wtt|}|j|r|d|_ n d|_ |S(sReturn the list of messages currently present in the folder. As a side effect, set self.last to the last message (or 0).ii( RMRNR,R R+RQtmapRCR-tlast(RtmessagesRNR,R/((s/usr/lib64/python2.7/mhlib.pyt listmessagess     cCsi}|j}yt|d}Wntk r9|SXx|j}|sSPn|jd}t|dkr|jd||jfn|dj}t|djdj }|||iismultiple errors:N( RUROR RIRtrenameR,tremovefromallsequencesR`(RtlistterrorstdeletedRTRt commapathR((s/usr/lib64/python2.7/mhlib.pytremovemessagess( ic Csg}i}x|D]}|jd}|j|}|j|} ytj|| Wntjk ry!tj|| tj|Wqttjfk r} |j | ytj| Wqtjk rqXqqXnX|j ||||RxcCs5g|_||_||_|r1|j|ndS(N(tpairstseptrngt fromstring(RtdataRR((s/usr/lib64/python2.7/mhlib.pyRs    cCs g|_dS(N(R(R((s/usr/lib64/python2.7/mhlib.pytreset scCst|j|jS(N(tcmpR(Rtother((s/usr/lib64/python2.7/mhlib.pyt__cmp__#scCs t|jS(N(thashR(R((s/usr/lib64/python2.7/mhlib.pyt__hash__&scCsd|j|j|jfS(NsIntSet(%r, %r, %r)(RkRR(R((s/usr/lib64/python2.7/mhlib.pyR)scCs|jjd}x|t|jkr|j|d\}}|j|\}}||dkr|t||fg|j|d|d+q|d}qWdS(Ni(RR-R`Rp(RR~talotahitblotbhi((s/usr/lib64/python2.7/mhlib.pyt normalize,s -cCs|d}xo|jD]d\}}||kr7t|}nt||jt|}|rn||j|}q|}qW|S(NR;(RRRR(RRmtlothitt((s/usr/lib64/python2.7/mhlib.pyRk7s  cCsAg}x4|jD])\}}t||d}||}qW|S(Ni(Rtrange(RtlRRtm((s/usr/lib64/python2.7/mhlib.pyRc@s cCs"x|D]}|j|qWdS(N(R,(RRR~((s/usr/lib64/python2.7/mhlib.pyRjGs cCst}|j|_|S(N(RbR(RR((s/usr/lib64/python2.7/mhlib.pytcloneKs  cCs|jddS(Ni(R(R((s/usr/lib64/python2.7/mhlib.pytminPscCs|jddS(Ni(R(R((s/usr/lib64/python2.7/mhlib.pyRpSscCs>x7|jD],\}}||ko-|knr tSq WtS(N(RtTruetFalse(RtxRR((s/usr/lib64/python2.7/mhlib.pytcontainsVscCsqxtt|jD]}|j|\}}||kr|d|kra||f|j|/dev/nulls<-- picksf.listmessages()(RRWRoRRyRsfirst:3slast:3scur:3scur:-3sprev:3snext:3s1:3s1:-3s100:3s100:-3s10000:3s10000:-3Rw(R tsystemRRPRBR)RhRbRcRntreversedR$RtpopenRRVRCR_( Rt testfoldersRRsR"RlRtstuffR((s/usr/lib64/python2.7/mhlib.pyttestsP                      t__main__(RLtwarningsRR RRRRDR RRRRRRt__all__t ExceptionRRRRMR?RRRRbRRuRR(((s/usr/lib64/python2.7/mhlib.pyt6s<         M  " *