Class Version


  • public final class Version
    extends Object
    See ISO 18004:2006 Annex D
    Author:
    Sean Owen
    • Method Detail

      • getVersionNumber

        public int getVersionNumber()
      • getAlignmentPatternCenters

        public int[] getAlignmentPatternCenters()
      • getTotalCodewords

        public int getTotalCodewords()
      • getDimensionForVersion

        public int getDimensionForVersion()
      • getProvisionalVersionForDimension

        public static Version getProvisionalVersionForDimension​(int dimension)
                                                         throws FormatException

        Deduces version information purely from QR Code dimensions.

        Parameters:
        dimension - dimension in modules
        Returns:
        Version for a QR Code of that dimension
        Throws:
        FormatException - if dimension is not 1 mod 4
      • getVersionForNumber

        public static Version getVersionForNumber​(int versionNumber)
      • decodeVersionInformation

        static Version decodeVersionInformation​(int versionBits)
      • buildFunctionPattern

        BitMatrix buildFunctionPattern()
        See ISO 18004:2006 Annex E