Console input validator for python, allows for any condition to be checked in a clean and consice syntax
Project description
# validin Console input validator for python, allows for any condition to be checked in a clean and consice syntax
## Docs (temporary): ` from validin import get_input import validin.validators as valid `
Use get_input to get valid user input
Example get_input() use: - name = get_input(“What’s your name? “, valid.IsLetters()) - age = get_input(“How old are you? “, valid.IsNaturalNumGreaterThan(18))
Input Validators: - IsNaturalNum - IsNaturalNumLessThan - IsLetters - IsLettersAndSymbols - IsAlphanumeric - IsAlphanumericAndSymbols - IsOption
- To create a new validator,
create a NewValidator() class with the condition and invalid input message wanted.
- For a validator with more advanced functionality (such as dynamic invalid input messages),
create an InputValidator subclass (see the docs)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file validin-0.9.3.tar.gz.
File metadata
- Download URL: validin-0.9.3.tar.gz
- Upload date:
- Size: 14.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.26.0 requests-toolbelt/0.9.1 urllib3/1.26.7 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3636c81a56b9276e3fcbb2ee6a513e83304688c845ac8cbe203f2710cd4a5a2e
|
|
| MD5 |
07ddc3c46cff831f8b243d147177e70b
|
|
| BLAKE2b-256 |
dbb09f064e8ecc0d434d837d1746c3819b7fb194e31e837291261af478d0910b
|
File details
Details for the file validin-0.9.3-py3-none-any.whl.
File metadata
- Download URL: validin-0.9.3-py3-none-any.whl
- Upload date:
- Size: 14.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.26.0 requests-toolbelt/0.9.1 urllib3/1.26.7 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
69a7bbfc40b6b023bbea52d7ec810feed37461a025aa8598ffad29adc41aa8d2
|
|
| MD5 |
43e50549c6677cb7b57cda969b8dc0a5
|
|
| BLAKE2b-256 |
48c4752584e863bf23f8634049ae45e04a51036460d740d069a3358fbe93e8b9
|