GS1 structure data parsing using the ZXing barcode library

2.6k views Asked by At

I am looking to use the ZXing library to decode GS1 DataBar barcode symbols. I will not be getting the barcode bitmap, all I receive is the content of the barcode, e.g.: 8110106141416543213500110000310123196000.

Can you tell me whether ZXing has a method that can decode the barcode's structured data? I have tried looking at all the methods out there but I didn't find anything appropriate.

1

There are 1 answers

1
Terry Burton On

As far as I know Zxing does not provide a GS1 structured data parsing feature.

You may need to write you own code for this. This answer explains how to extract and lookup GS1 structured data:

https://stackoverflow.com/a/31760872/2568535

Separating a GTIN into its components - GS1 Prefix (national Member Organisation), Company Prefix and Item Identifier - isn't always possible.

GS1 provides a list of Member Organisation prefix assignments however it is up to each Member to decide how they further partition their number space. Whilst some national GS1 Members provide an online API to lookup the company data (e.g. GS1US has GEPIR) most do not. Again, some Members have rigid rules about the length of the Company Prefix based on its initial digits but others do not.

With that in mind the answers to this question provide some examples of free product information platforms.