Python implementation of a polymorphic list
Project description
py-polymorphic-list
Python implementation of a polymorphic list
View on PyPI / Documentation / GitHub Source Code
What is a Polymorphic List?
A polymorphic list is a data abstraction similar to LinkedLists where objects of two classes, NonEmptyList, and EmptyList, are employed to cleanly handle edge cases where a LinkedList would be null. In a LinkedList, the last node's next reference is null; however, for a PolymorphicList, the last node's next reference is an EmptyList, allowing the EmptyList object to override methods defined in a PolymorphicList.
This means that every method is overridden to have a version for a NonEmptyList and for an EmptyList.
Installation
pip install py-polymorphic-list
Or install with pip3, accordingly.
Documentation
Check out the documentation for full details on usage.
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 py_polymorphic_list-1.0.0.tar.gz.
File metadata
- Download URL: py_polymorphic_list-1.0.0.tar.gz
- Upload date:
- Size: 5.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.5.0 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5a0c3dba6a9a4001050fa53159f3a5bc10835e2043c7f04488320898d379f36f
|
|
| MD5 |
0951841a97d4b88a2ae8f76e9fad1f1a
|
|
| BLAKE2b-256 |
242c4c015b5cb2dce8f85dd36d71611918e82a0effa4dbbdc14460e4bee67e55
|
File details
Details for the file py_polymorphic_list-1.0.0-py3-none-any.whl.
File metadata
- Download URL: py_polymorphic_list-1.0.0-py3-none-any.whl
- Upload date:
- Size: 5.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.5.0 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
26a9c4e93e84e62fa641d26a15e0c492cafc7e98f30da7d625e4026f0d0c835f
|
|
| MD5 |
21ff3a7df70fcd5fb4ce27f3acef48ca
|
|
| BLAKE2b-256 |
9156c76439a5e69236bc41cea42a497b279593d20889219a6f712e722a83fc59
|