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

Method lengthIndicator

text-to-qr/lib/phpqrcode/qrspec.php:135–149  ·  view source on GitHub ↗

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

($mode, $version)

Source from the content-addressed store, hash-verified

133
134 //----------------------------------------------------------------------
135 public static function lengthIndicator($mode, $version)
136 {
137 if ($mode == QR_MODE_STRUCTURE)
138 return 0;
139
140 if ($version <= 9) {
141 $l = 0;
142 } else if ($version <= 26) {
143 $l = 1;
144 } else {
145 $l = 2;
146 }
147
148 return self::$lengthTableBits[$mode][$l];
149 }
150
151 //----------------------------------------------------------------------
152 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