utilities for nice object reprs
Project description
i created reprtools, because i was annoyed by how i have to write __repr__ in my simple classes
usage:
from reprtools import FormatRepr
class User(object):
__repr__ = FormatRepr("<User {name}>")
def __init__(self, name):
self.name = name
>>> User('test')
<User test>
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
reprtools-0.1.tar.gz
(1.5 kB
view details)
File details
Details for the file reprtools-0.1.tar.gz.
File metadata
- Download URL: reprtools-0.1.tar.gz
- Upload date:
- Size: 1.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
36af2a280521375d1715760f7175066d45a02d739776df35e5aa1741bbde6b2c
|
|
| MD5 |
811f205ce25bbd0a534d1186f974ffcb
|
|
| BLAKE2b-256 |
9840188ca28ddaa99e26dfcf7f6ae88034732783162a3312c7ca3f76ab6887ad
|