Current Path : /usr/lib/python2.7/dist-packages/zope/interface/ |
Current File : //usr/lib/python2.7/dist-packages/zope/interface/ro.pyc |
ó ÔËÞKc @ s. d Z d Z d „ Z d d „ Z d „ Z d S( si Compute a resolution order for an object and its bases $Id: ro.py 110536 2010-04-06 02:59:44Z tseaver $ t restructuredtextc C s t t | ƒ g ƒ S( s/ Compute a "resolution order" for an object ( t mergeOrderingst _flatten( t object( ( s5 /usr/lib/python2.7/dist-packages/zope/interface/ro.pyt ro s c C s‘ | d k r i } n g } | j ƒ x[ | D]S } t | ƒ } | j ƒ x4 | D], } | | k rO d | | <| j | ƒ qO qO Wq, W| j ƒ | S( s¡ Merge multiple orderings so that within-ordering order is preserved Orderings are constrained in such a way that if an object appears in two or more orderings, then the suffix that begins with the object must be in both orderings. For example: >>> _mergeOrderings([ ... ['x', 'y', 'z'], ... ['q', 'z'], ... [1, 3, 5], ... ['z'] ... ]) ['x', 'y', 'q', 1, 3, 5, 'z'] i N( t Nonet reverset listt append( t orderingst seent resultt orderingt o( ( s5 /usr/lib/python2.7/dist-packages/zope/interface/ro.pyR s c C sD | g } d } x. t | ƒ D] } | d 7} | j | | | +q W| S( Ni i ( t itert __bases__( t obR t i( ( s5 /usr/lib/python2.7/dist-packages/zope/interface/ro.pyR <