Read about EAN 13 on wikipedia.
Implement se.vbgt.ean13.EAN13
so it passes the tests below (and it will be a start for generating barcode images).
Modules, in text, will be represented with a bar |
and absence of modules with a space
.
- Must be 13 digits
- Must be correct check digit
- Test of grouping of first part of modules
- Test encoding digit to modules, depending on group
- Testing length
- Testing markers
- start
- end
- middle
- Test of actual complete modules of barcodes
Actually generate a PNG image of the barcode, remember the quiet zone! (Barcodes are introverts)