MCPcopy
hub / github.com/zxing-js/library / getVersionForNumber

Method getVersionForNumber

src/core/qrcode/decoder/Version.ts:438–443  ·  view source on GitHub ↗
(versionNumber: number /*int*/)

Source from the content-addressed store, hash-verified

436 }
437
438 public static getVersionForNumber(versionNumber: number /*int*/): Version {
439 if (versionNumber < 1 || versionNumber > 40) {
440 throw new IllegalArgumentException();
441 }
442 return Version.VERSIONS[versionNumber - 1];
443 }
444
445 public static decodeVersionInformation(versionBits: number /*int*/): Version {
446 let bestDifference = Number.MAX_SAFE_INTEGER;

Callers 14

encodeMethod · 0.80
recommendVersionMethod · 0.80
chooseVersionMethod · 0.80
readVersionMethod · 0.80
Encoder.spec.tsFile · 0.80
MatrixUtil.spec.tsFile · 0.80
QRCode.spec.tsFile · 0.80
Version.spec.tsFile · 0.80
testEciOneEncodingFunction · 0.80

Calls

no outgoing calls

Tested by 2

testEciOneEncodingFunction · 0.64
testEciCombonedFunction · 0.64