mò &á¸Ec@shddd!ZdkZdkZdklZeZdeieifd„ƒYZdfd„ƒYZ dS( s $Revision$i iþÿÿÿN(s ConflictErrortAbstractCatalogBraincBsJtZdZd„Zd„Zdd„Zd„Zed„Zd„Z RS(sÎAbstract base brain that handles looking up attributes as required, and provides just enough smarts to let us get the URL, path, and cataloged object without having to ask the catalog directly. cCs|ii|ƒS(N(tselft__record_schema__thas_keytkey(RR((t>/data/zmath/zope/lib/python/Products/ZCatalog/CatalogBrains.pyRscCs|ii|iƒS(s%Get the physical path for this recordN(Rt aq_parenttgetpathtdata_record_id_(R((RtgetPathsicCs|ii|iƒ|ƒS(sGenerate a URL for this recordN(RtREQUESTtphysicalPathToURLR trelative(RR ((RtgetURL#scCsOy|ii|iƒƒSWn.tj o ‚nto‚ndSnXdS(sgReturn the object for this record Same as getObject, but does not do security checks. N(RRtunrestrictedTraverseR t ConflictErrortGETOBJECT_RAISEStNone(R((Rt_unrestrictedGetObject.scCsØ|iƒidƒ}|pdSn|i}t|ƒdjoLy|i|d ƒ}WqŒt j o ‚qŒt o‚ndSqŒXny|i |dƒ}Wn.t j o ‚nt o‚ndSnX|S(s­Return the object for this record Will return None if the object cannot be found via its cataloged path (i.e., it was deleted or moved without recataloging), or if the user is not authorized to access the object. This method mimicks a subset of what publisher's traversal does, so it allows access if the final object can be accessed even if intermediate objects cannot. t/iiÿÿÿÿN( RR tsplittpathRRtparenttlenRRRtrestrictedTraversettarget(RR RRR((Rt getObject<s.   cCs|iS(s%Return the record ID for this object.N(RR(R((RtgetRID`s( t__name__t __module__t__doc__RR R RRRR(((RRs     $t NoBrainercBstZdZRS(s; This is an empty class to use when no brain is specified. (RRR(((RRds ( t __version__t AcquisitiontRecordtZODB.POSExceptionRtTrueRtImplicitRR(RRRRR"R R!((Rt?s  M