CodabarNumber::calculateCheckDigit
Calculates the checksum digit, start with the total set to zero and scan the 13 digits from left to right:
- If the digit is in an even-numbered position (2, 4, 6...) add it to the total. - If the digit is in an odd-numbered position (1, 3, 5...) multiply the digit by 2. If the product is equal to or greater than 10, subtract 9 from the product. Then add the product to the total. - After all digits have been processed, divide the total by 10 and take the remainder. - If the remainder = 0, that is the check digit. If the remainder is not zero, the check digit is 10 minus the remainder.
Signature
private function calculateCheckDigit()