How leoneville/pyboleto works
pyboleto is a Python library for creating Brazilian bank boletos. An application creates a bank-specific boleto object, whose adapter supplies bank rules on top of shared boleto data; an HTML or PDF renderer then formats that object for output. The tree includes adapters for multiple banks and both output formats. The README content is empty, so capabilities and relationships here are based on the sampled source and SOURCE INDEX; the bank package is grouped because several adapters were not excerpted.
Main entry points: bank Bank adapters · html.py HTML renderer · pdf.py PDF renderer · data.py Shared boleto data
Components 9
Bank rules
- Bank adapters
pyboleto/bank
Boleto data
- Shared boleto data
pyboleto/data.py
Output rendering
- HTML renderer
pyboleto/html.py - PDF renderer
pyboleto/pdf.py - HTML templates
pyboleto/templates
Usage examples
- HTML sample
bin/html_pyboleto_sample.py - PDF sample
bin/pdf_pyboleto_sample.py - In-memory PDF sample
bin/pdf_pyboleto_in_memory_sample.py
Other components
- Application code
Connections 12
- Bank adapters → Shared boleto data: inherit and extend
pyboleto/bank/bancodobrasil.py - Shared boleto data → HTML renderer: provides fields
pyboleto/html.py - Shared boleto data → PDF renderer: provides fields
pyboleto/pdf.py - HTML renderer → HTML templates: loads templates
pyboleto/html.py - Application code → Bank adapters: creates boleto
- Application code → HTML renderer: renders HTML
- Application code → PDF renderer: renders PDF
- HTML sample → Bank adapters: instantiates
bin/html_pyboleto_sample.py - HTML sample → HTML renderer: calls renderer
bin/html_pyboleto_sample.py - PDF sample → Bank adapters: instantiates
bin/pdf_pyboleto_sample.py - PDF sample → PDF renderer: calls renderer
bin/pdf_pyboleto_sample.py - In-memory PDF sample → PDF renderer: uses renderer
bin/pdf_pyboleto_in_memory_sample.py