Files
ServerSync/lib/jaraco/classes/__pycache__/ancestry.cpython-314.pyc

47 lines
2.8 KiB
Plaintext
Raw Normal View History

2026-02-19 00:55:27 +02:00
+
<00>;<3B>i<EFBFBD><00><01><><00>Rt^RIHt^RIHtHt^RIHt]'d ^RIH t ^RIH
t
RRlt RR lt R
R lt R R ltR#)zM
Routines for obtaining the class names
of an object and its parent classes.
)<01> annotations)<02> TYPE_CHECKING<4E>cast)<01>unique_everseen)<01>Iterator)<01>Anyc<01> <00>V^8<>dQhRRRR/#<00><05><00>c<> type[object]<5D>returnzlist[type[Any]]<5D>)<01>formats"<22>>/tmp/pip-target-ugtna5l2/lib/python/jaraco/classes/ancestry.py<70> __annotate__rs<00><00><17><17><1C><17>/<2F><17>c<05>0<00>VP4R,#)zd
return a tuple of all base classes the class c has as a parent.
>>> object in all_bases(list)
True
:<3A>NN<4E><01>mro<72>r s&r<00> all_basesrs<00><00> <0A>5<EFBFBD>5<EFBFBD>7<EFBFBD>2<EFBFBD>;<3B>rc<01> <00>V^8<>dQhRRRR/#r r)rs"rrrs<00><00><13><13><<3C><13>O<EFBFBD>rc<05>"<00>VP4#)zU
return a tuple of all classes to which c belongs
>>> list in all_classes(list)
True
rrs&r<00> all_classesrs<00><00> <0A>5<EFBFBD>5<EFBFBD>7<EFBFBD>Nrc<01> <00>V^8<>dQhRRRR/#<00>r
<00>clsr r zIterator[type[Any]]r)rs"rrr's<00><00>6<>6<><1C>6<>*=<3D>6rc<05>*<00>\\V44#)a<>
Generator over all subclasses of a given class, in depth-first order.
>>> bool in list(iter_subclasses(int))
True
>>> class A(object): pass
>>> class B(A): pass
>>> class C(A): pass
>>> class D(B,C): pass
>>> class E(D): pass
>>>
>>> for cls in iter_subclasses(A):
... print(cls.__name__)
B
D
E
C
>>> # get ALL classes currently defined
>>> res = [cls.__name__ for cls in iter_subclasses(object)]
>>> 'type' in res
True
>>> 'tuple' in res
True
>>> len(res) > 100
True
)r<00>_iter_all_subclasses)rs&r<00>iter_subclassesr!'s<00><00>6 <1B>/<2F><03>4<> 5<>5rc<01> <00>V^8<>dQhRRRR/#rr)rs"rrrEs<00><00>(<28>(<28>l<EFBFBD>(<28>/B<>(rc#<01><>"<00>VP4pVFpVx<00>\V4Rjx<01>L
K R# \d\RT4PT4pLJi;iL65i)z
type[type]N)<04>__subclasses__<5F> TypeErrorrr!)r<00>subs<62>subs& rr r Esd<00><00><00>;<3B><12>!<21>!<21>#<23><04><14><03><11> <09>"<22>3<EFBFBD>'<27>'<27>'<27><14><> <15>;<3B><13>L<EFBFBD>#<23>&<26>5<>5<>c<EFBFBD>:<3A><04>;<3B><> (<28>s/<00>A$<01>6<00>A$<01>A"<06>
A$<01>&A<03>A$<01>A<03>A$N)<0F>__doc__<5F>
__future__r<00>typingrr<00>more_itertoolsr<00>collections.abcrrrrr!r rrr<00><module>r-s2<00><01><04>
#<23>&<26>*<2A><10>(<28><1A><17><13>6<><(r