KGRKJGETMRETU895U-589TY5MIGM5JGB5SDFESFREWTGR54TY
Server : Apache/2.2.17 (Unix) mod_ssl/2.2.17 OpenSSL/0.9.8e-fips-rhel5 DAV/2 PHP/5.2.17
System : Linux localhost 2.6.18-419.el5 #1 SMP Fri Feb 24 22:47:42 UTC 2017 x86_64
User : nobody ( 99)
PHP Version : 5.2.17
Disable Function : NONE
Directory :  /usr/lib64/python2.4/bsddb/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : //usr/lib64/python2.4/bsddb/__init__.pyo
mò
‚=5Dc@s¶dZy-edjodkZeZn
dkZWn)ej
odkZeie=‚nXeZZei	Z	ei
ZdkZdkZei
djo"dkZdklZddUndfd„ƒYZdefd	„ƒYZd
dddddddd
„Zd
dddddddd„Zd
dddddddddd„
Zd„Zd„Zy0dkZ[ei
ƒdjo
de_nWnej
ode_nXdS(s(Support for BerkeleyDB 3.2 through 4.2.
tbsddb3Ns2.3(srefsç	
class _iter_mixin(UserDict.DictMixin):
    def _make_iter_cursor(self):
        cur = self.db.cursor()
        key = id(cur)
        self._cursor_refs[key] = ref(cur, self._gen_cref_cleaner(key))
        return cur

    def _gen_cref_cleaner(self, key):
        # use generate the function for the weakref callback here
        # to ensure that we do not hold a strict reference to cur
        # in the callback.
        return lambda ref: self._cursor_refs.pop(key, None)

    def __iter__(self):
        try:
            cur = self._make_iter_cursor()

            # FIXME-20031102-greg: race condition.  cursor could
            # be closed by another thread before this call.

            # since we're only returning keys, we call the cursor
            # methods with flags=0, dlen=0, dofs=0
            key = cur.first(0,0,0)[0]
            yield key

            next = cur.next
            while 1:
                try:
                    key = next(0,0,0)[0]
                    yield key
                except _bsddb.DBCursorClosedError:
                    cur = self._make_iter_cursor()
                    # FIXME-20031101-greg: race condition.  cursor could
                    # be closed by another thread before this call.
                    cur.set(key,0,0,0)
                    next = cur.next
        except _bsddb.DBNotFoundError:
            return
        except _bsddb.DBCursorClosedError:
            # the database was modified during iteration.  abort.
            return

    def iteritems(self):
        try:
            try:
                cur = self._make_iter_cursor()
            except AttributeError:
                return

            # FIXME-20031102-greg: race condition.  cursor could
            # be closed by another thread before this call.

            kv = cur.first()
            key = kv[0]
            yield kv

            next = cur.next
            while 1:
                try:
                    kv = next()
                    key = kv[0]
                    yield kv
                except _bsddb.DBCursorClosedError:
                    cur = self._make_iter_cursor()
                    # FIXME-20031101-greg: race condition.  cursor could
                    # be closed by another thread before this call.
                    cur.set(key,0,0,0)
                    next = cur.next
        except _bsddb.DBNotFoundError:
            return
        except _bsddb.DBCursorClosedError:
            # the database was modified during iteration.  abort.
            return
t_iter_mixincBstZRS(N(t__name__t
__module__(((t&/usr/lib64/python2.4/bsddb/__init__.pyR’st
_DBWithCursorcBs¼tZdZd„Zd„Zd„Zdd„Zd„Zd„Zd„Z	d	„Z
d
„Zd„Zd„Z
d
„Zd„Zd„Zd„Zd„Zd„Zd„Zd„ZRS(s˜
    A simple wrapper around DB that makes it look like the bsddbobject in
    the old module.  It uses a cursor as needed to provide DB traversal.
    cCs8||_|iidƒd|_d|_h|_dS(Ni(tdbtselftset_get_returns_nonetNonetdbct
saved_dbc_keyt_cursor_refs(RR((Rt__init__šs
	
		cCs|iƒdS(N(Rtclose(R((Rt__del__°scCsZ|idjoF|iiƒ|_|idj	o |ii|iƒd|_qVndS(N(RR
R	RtcursorRtset(R((Rt_checkCursor³s
icCs³|iog|i}d|_|o=y |idddƒd|_Wq`tij
oq`Xn|i	ƒ~nx;|i
iƒD]*}|ƒ}|dj	o|i	ƒqqWdS(Ni(
RR
tcR	tsavetcurrentRRtDBErrorRRtvaluestcref(RRRR((Rt
_closeCursors¾s
		 	
	
cCs!|idjo
td‚ndS(Ns$BSDDB object has already been closed(RRR	terror(R((Rt
_checkOpenÎscCs
|idj	S(N(RRR	(R((RtisOpenÒscCs|iƒt|iƒS(N(RRtlenR(R((Rt__len__Õs
cCs|iƒ|i|S(N(RRRtkey(RR((Rt__getitem__Ùs
cCs%|iƒ|iƒ||i|<dS(N(RRRtvalueRR(RRR!((Rt__setitem__Ýs

cCs"|iƒ|iƒ|i|=dS(N(RRRRR(RR((Rt__delitem__âs

cCsp|iddƒ|idj	o|iiƒnd}|idj	o|iiƒ}nd|_d|_|S(NRi(RRR
R	RtvR(RR$((RRçs		cCs|iƒ|iiƒS(N(RRRtkeys(R((RR%òs
cCs|iƒ|ii|ƒS(N(RRRthas_keyR(RR((RR&ös
cCs$|iƒ|iƒ|ii|ƒS(N(RRRR
t	set_rangeR(RR((Rtset_locationús

cCs'|iƒ|iƒ|iiƒ}|S(N(RRRR
tnexttrv(RR*((RR)ÿs

cCs'|iƒ|iƒ|iiƒ}|S(N(RRRR
tprevR*(RR*((Rtpreviouss

cCs'|iƒ|iƒ|iiƒ}|S(N(RRRR
tfirstR*(RR*((RR-s

cCs'|iƒ|iƒ|iiƒ}|S(N(RRRR
tlastR*(RR*((RR.s

cCs|iƒ|iiƒS(N(RRRtsync(R((RR/s
(RRt__doc__R
RRRRRRR R"R#RR%R&R(R)R,R-R.R/(((RR•s(																	Ri¶ic	Csðt||ƒ}tƒ}	ti|	ƒ}
|
i	|ƒ|dj	o|
i
d|ƒn|dj	o|
i|ƒn|dj	o|
i|ƒn|dj	o|
i|ƒn|dj	o|
i|ƒn|
i|ti||ƒt|
ƒS(Ni(t
_checkflagtflagtfiletflagst
_openDBEnvteRtDBtdt	set_flagsthflagst	cachesizeR	t
set_cachesizetpgsizetset_pagesizetlordert
set_lordertffactort
set_h_ffactortnelemtset_h_nelemtopentDB_HASHtmodeR(R3R2RGR=RARCR;R?R:R6R8R4((Rthashopens 	





c	Csðt||ƒ}tƒ}	ti|	ƒ}
|dj	o|
id|ƒn|dj	o|
i
|ƒn|dj	o|
i|ƒn|
i|ƒ|dj	o|
i|ƒn|dj	o|
i|ƒn|
i|ti||ƒt|
ƒS(Ni(R1R2R3R4R5R6RR7R8R;R	R<R=R>R?R@R9tbtflagst
minkeypaget
set_bt_minkeyt
maxkeypaget
set_bt_maxkeyREtDB_BTREERGR(R3R2RGRIR;RLRJR=R?R6R8R4((Rtbtopen0s 	





cCs,t||ƒ}
tƒ}ti|ƒ}|dj	o|id|ƒn|dj	o|i
|ƒn|dj	o|i|ƒn|i|ƒ|dj	o|i|ƒn|dj	o|i|ƒn|	dj	o|i|	ƒn|
dj	o|i|
ƒn|i|ti|
|ƒt|ƒS(Ni(R1R2R3R4R5R6RR7R8R;R	R<R=R>R?R@R9trnflagstdelimtset_re_delimtrlent
set_re_lentsourcet
set_re_sourcetpadt
set_re_padREtDB_RECNORGR(R3R2RGRPR;R=R?RSRQRURWR6R8R4((RtrnopenCs(	







cCs?tiƒ}|idtitiBtiBtiBtiBƒ|S(Nt.(	RtDBEnvR6REt
DB_PRIVATEt	DB_CREATEt	DB_THREADtDB_INIT_LOCKt
DB_INIT_MPOOL(R6((RR5Ws/cCs·|djo
ti}n“|djo
d}n||djo
ti}nb|djo
ti}nH|djo1ti}tii|ƒoti	|ƒq¬n
t
d‚|tiBS(NtrtrwitwRtns+flags should be one of 'r', 'w', 'c' or 'n'(R2Rt	DB_RDONLYR4R^tostpathtisfileR3tunlinkRR_(R2R3R4((RR1\s








		i(iii(R0Rt_pybsddbt_bsddbtImportErrortsystmodulesRt_dbt__version__RRRgtversiontUserDicttweakreftrefRRR	RHRORZR5R1tthreadR_(RHRqR5RZRuR1RsRpRRlRnRRvRORRRkRg((Rt?%s>
	

	

			
LŠ!!'			

Anon7 - 2021