MCPcopy Create free account
hub / github.com/codemistic/Web-Development / lengthIndicator

Method lengthIndicator

text-to-qr/lib/phpqrcode/phpqrcode.php:447–461  ·  view source on GitHub ↗

----------------------------------------------------------------------

($mode, $version)

Source from the content-addressed store, hash-verified

445
446 //----------------------------------------------------------------------
447 public static function lengthIndicator($mode, $version)
448 {
449 if ($mode == QR_MODE_STRUCTURE)
450 return 0;
451
452 if ($version <= 9) {
453 $l = 0;
454 } else if ($version <= 26) {
455 $l = 1;
456 } else {
457 $l = 2;
458 }
459
460 return self::$lengthTableBits[$mode][$l];
461 }
462
463 //----------------------------------------------------------------------
464 public static function maximumWords($mode, $version)

Callers 9

encodeModeNumMethod · 0.45
encodeModeAnMethod · 0.45
encodeMode8Method · 0.45
encodeModeKanjiMethod · 0.45
lengthOfCodeMethod · 0.45
eatNumMethod · 0.45
eatAnMethod · 0.45
eat8Method · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected