Return the nested config stored under *attr* if it matches the expected type.
(self, expected_type: type[TConfig], *, attr: str = "config")
| 175 | return None |
| 176 | |
| 177 | def as_config(self, expected_type: type[TConfig], *, attr: str = "config") -> TConfig | None: |
| 178 | """Return the nested config stored under *attr* if it matches the expected type.""" |
| 179 | value = getattr(self, attr, None) |
| 180 | if isinstance(value, expected_type): |
| 181 | return value |
| 182 | return None |
| 183 | |
| 184 | @classmethod |
| 185 | def collect_schema(cls) -> SchemaNode: |
no outgoing calls
no test coverage detected