is_dataclass
No overview available.
def is_dataclass(
obj: object
) - > boolean
Checks if an object or class is a dataclass or an instance of a dataclass. Use this to distinguish dataclass types from regular classes or other data structures during runtime type inspection.
Parameters
| Name | Type | Description |
|---|---|---|
| obj | object | The class or instance to be inspected for dataclass properties |
Returns
| Type | Description |
|---|---|
boolean | True if the provided object is a dataclass or an instance of one, False otherwise |