Implemented BarCode with unit tests.