mò )á¸Ec@sPdklZdklZlZlZdklZlZdfd„ƒYZdS((sIIBucket(sweightedIntersections weightedUnions difference(sOOSetsuniont ResultListcBsktZefƒd„Zd„Zd„Zd„Zd„Zd„Zd„Z d„Z d „Z d „Z RS( NcCs½||_t|ƒtj ot|ƒ}n||_t|ƒ|jot |fƒ}n$t|ƒt j ot |ƒ}n||_ |i |_ y|i |_ WnnX|i |_ dS(N(tindextselft_indexttypetwordstOOSett_wordstdt TupleTypetIIBuckett_dictt __getitem__t __nonzero__tget(RRRRR ((tG/data/zmath/zope/lib/python/Products/PluginIndexes/common/ResultList.pyt__init__s    cCs |i S(N(RR (R((RR %scCs|iS(N(RR (R((Rtbucket(scCs |iiƒS(N(RR tkeys(R((RR*scCs|ii|ƒS(N(RR thas_keytkey(RR((RR,scCs |iiƒS(N(RR titems(R((RR.scCs8|it|i|iƒdt|i|iƒ|iƒS(Ni(Rt __class__tweightedIntersectionR txtunionRR(RR((Rt__and__0scCs(|it|i|iƒ|i|iƒS(N(RRt differenceR RRR(RR((Rtand_not7scCs8|it|i|iƒdt|i|iƒ|iƒS(Ni(RRt weightedUnionR RRRR(RR((Rt__or__>scCstƒ} |i} |i}|i}|i i }x)| i ƒD]\}} ||ƒpq=ntd„|||iƒƒtd„|||iƒƒ} | iƒd}} d}d}x^| D]V\}}||j o1||j o$|dj ot|||ƒ}n|}|}q¾W|| jot| ||ƒ} n| |||} | | |NscCs |dfS(Ni(R(R((RR Osi'(R tresultRR tdictRtxdictRtxhasRt positionsRtidtscoretmapRtptsortRtlptNonetlitlsrcRtsrctminRR(RRRR/RR%R.R$R&R)R'R"R!R+R-R#((RtnearFs2       :   '  ( t__name__t __module__RRR RRRRRRRR1(((RRs        N( tBTrees.IIBTreeR RRRtBTrees.OOBTreeRRR(RRRRR RR((Rt?s