Metadata-Version: 2.1
Name: nested_type_checker
Version: 0.9.6
Summary: A runtime strict type-checking module for Python designed to validate parametrized (nested) types.
Home-page: https://github.com/JokeUrSelf/nested-type-checker
Author: JokeUrSelf
License: MIT
Platform: any
Classifier: Programming Language :: Python :: 3
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Requires-Python: >=3.5
Description-Content-Type: text/markdown

## Nested Type Checker (Beta)

A runtime strict type-checking module for Python, designed to validate parametrized (nested) types.
It supports both Python built-in types and custom types.

## Example Usage

To check if an object matches a specified parametrized type, use the function `is_object_of_type(your_obj, your_type)`:

```python
from nested_type_checker import is_object_of_type

obj = [123, ({"", True},)]

CorrectType = list[int | tuple[dict[str, bool]]]
WrongType = list[bool | tuple[dict[str, bool]]]

a = is_object_of_type(obj, CorrectType)
b = is_object_of_type(obj, WrongType)

print(a)  # outputs True
print(b)  # outputs False
```

## Support

The module can validate parametrized types of data, such as mappings, tuples, lists, sets, frozensets, callables, unions, optionals, as well as any other unparametrized types, including the custom ones.

## Installation

To install, use Python's `pip` package manager:

```sh
pip install nested_type_checker
```
