Class Structure for Barcodes

Extracted the work from the request driven approach in the original repo
to a class-driven approach.