MCPcopy Create free account
hub / github.com/DasyDong/developer-roadmap / __subclasscheck__

Method __subclasscheck__

code/interface.py:94–98  ·  view source on GitHub ↗
(cls, subclass)

Source from the content-addressed store, hash-verified

92 return cls.__subclasscheck__(type(instance))
93
94 def __subclasscheck__(cls, subclass):
95 return (hasattr(subclass, 'name') and
96 callable(subclass.name) and
97 hasattr(subclass, 'age') and
98 callable(subclass.age))
99# The base class PersonSuper
100class PersonSuper:
101 """A person superclass"""

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected