Completed
Push — master ( 6d6efd...4d43de )
by Joram van den
04:34
created
lib/Ajde/Resource/Qrcode/lib/phpqrcode.php 1 patch
Doc Comments   +111 added lines patch added patch discarded remove patch
@@ -89,6 +89,9 @@  discard block
 block discarded – undo
89 89
 
90 90
 class qrstr
91 91
 {
92
+    /**
93
+     * @param string $repl
94
+     */
92 95
     public static function set(&$srctab, $x, $y, $repl, $replLen = false)
93 96
     {
94 97
         $srctab[$y] = substr_replace($srctab[$y], ($replLen !== false) ? substr($repl, 0, $replLen) : $repl, $x,
@@ -219,6 +222,11 @@  discard block
 block discarded – undo
219 222
     }
220 223
 
221 224
     //----------------------------------------------------------------------
225
+
226
+    /**
227
+     * @param boolean $outfile
228
+     * @param string $err
229
+     */
222 230
     public static function log($outfile, $err)
223 231
     {
224 232
         if (QR_LOG_DIR !== false) {
@@ -245,6 +253,10 @@  discard block
 block discarded – undo
245 253
     }
246 254
 
247 255
     //----------------------------------------------------------------------
256
+
257
+    /**
258
+     * @param string $markerId
259
+     */
248 260
     public static function markTime($markerId)
249 261
     {
250 262
         list($usec, $sec) = explode(" ", microtime());
@@ -397,18 +409,30 @@  discard block
 block discarded – undo
397 409
     }
398 410
 
399 411
     //----------------------------------------------------------------------
412
+
413
+    /**
414
+     * @param integer $version
415
+     */
400 416
     public static function getWidth($version)
401 417
     {
402 418
         return self::$capacity[$version][QRCAP_WIDTH];
403 419
     }
404 420
 
405 421
     //----------------------------------------------------------------------
422
+
423
+    /**
424
+     * @param integer $version
425
+     */
406 426
     public static function getRemainder($version)
407 427
     {
408 428
         return self::$capacity[$version][QRCAP_REMINDER];
409 429
     }
410 430
 
411 431
     //----------------------------------------------------------------------
432
+
433
+    /**
434
+     * @param integer $size
435
+     */
412 436
     public static function getMinimumVersion($size, $level)
413 437
     {
414 438
 
@@ -529,6 +553,9 @@  discard block
 block discarded – undo
529 553
     //----------------------------------------------------------------------
530 554
     // CACHEABLE!!!
531 555
 
556
+    /**
557
+     * @param integer $version
558
+     */
532 559
     public static function getEccSpec($version, $level, array &$spec)
533 560
     {
534 561
         if (count($spec) < 5) {
@@ -935,12 +962,20 @@  discard block
 block discarded – undo
935 962
     }
936 963
 
937 964
     //----------------------------------------------------------------------
965
+
966
+    /**
967
+     * @param string $code
968
+     */
938 969
     public static function unserial($code)
939 970
     {
940 971
         return explode("\n", gzuncompress($code));
941 972
     }
942 973
 
943 974
     //----------------------------------------------------------------------
975
+
976
+    /**
977
+     * @param integer $version
978
+     */
944 979
     public static function newFrame($version)
945 980
     {
946 981
         if ($version < 1 || $version > QRSPEC_VERSION_MAX) {
@@ -1354,6 +1389,10 @@  discard block
 block discarded – undo
1354 1389
     }
1355 1390
 
1356 1391
     //----------------------------------------------------------------------
1392
+
1393
+    /**
1394
+     * @param integer $version
1395
+     */
1357 1396
     public function encodeBitStream($version)
1358 1397
     {
1359 1398
         try {
@@ -1444,6 +1483,10 @@  discard block
 block discarded – undo
1444 1483
     }
1445 1484
 
1446 1485
     //----------------------------------------------------------------------
1486
+
1487
+    /**
1488
+     * @param integer $version
1489
+     */
1447 1490
     public function setVersion($version)
1448 1491
     {
1449 1492
         if ($version < 0 || $version > QRSPEC_VERSION_MAX) {
@@ -1484,6 +1527,12 @@  discard block
 block discarded – undo
1484 1527
     }
1485 1528
 
1486 1529
     //----------------------------------------------------------------------
1530
+
1531
+    /**
1532
+     * @param QRinput $mode
1533
+     * @param integer $size
1534
+     * @param integer $data
1535
+     */
1487 1536
     public function append($mode, $size, $data)
1488 1537
     {
1489 1538
         try {
@@ -1701,6 +1750,10 @@  discard block
 block discarded – undo
1701 1750
     ];
1702 1751
 
1703 1752
     //----------------------------------------------------------------------
1753
+
1754
+    /**
1755
+     * @param integer $c
1756
+     */
1704 1757
     public static function lookAnTable($c)
1705 1758
     {
1706 1759
         return (($c > 127) ? -1 : self::$anTable[$c]);
@@ -1798,6 +1851,10 @@  discard block
 block discarded – undo
1798 1851
     }
1799 1852
 
1800 1853
     //----------------------------------------------------------------------
1854
+
1855
+    /**
1856
+     * @param integer $version
1857
+     */
1801 1858
     public function estimateBitStreamSize($version)
1802 1859
     {
1803 1860
         $bits = 0;
@@ -1927,6 +1984,10 @@  discard block
 block discarded – undo
1927 1984
     }
1928 1985
 
1929 1986
     //----------------------------------------------------------------------
1987
+
1988
+    /**
1989
+     * @param QRbitstream $bstream
1990
+     */
1930 1991
     public function appendPaddingBit(&$bstream)
1931 1992
     {
1932 1993
         $bits = $bstream->size();
@@ -2252,6 +2313,10 @@  discard block
 block discarded – undo
2252 2313
     public $modeHint;
2253 2314
 
2254 2315
     //----------------------------------------------------------------------
2316
+
2317
+    /**
2318
+     * @param QRinput $input
2319
+     */
2255 2320
     public function __construct($dataStr, $input, $modeHint)
2256 2321
     {
2257 2322
         $this->dataStr = $dataStr;
@@ -2260,6 +2325,10 @@  discard block
 block discarded – undo
2260 2325
     }
2261 2326
 
2262 2327
     //----------------------------------------------------------------------
2328
+
2329
+    /**
2330
+     * @param string $str
2331
+     */
2263 2332
     public static function isdigitat($str, $pos)
2264 2333
     {
2265 2334
         if ($pos >= strlen($str)) {
@@ -2270,6 +2339,10 @@  discard block
 block discarded – undo
2270 2339
     }
2271 2340
 
2272 2341
     //----------------------------------------------------------------------
2342
+
2343
+    /**
2344
+     * @param string $str
2345
+     */
2273 2346
     public static function isalnumat($str, $pos)
2274 2347
     {
2275 2348
         if ($pos >= strlen($str)) {
@@ -2397,6 +2470,10 @@  discard block
 block discarded – undo
2397 2470
     }
2398 2471
 
2399 2472
     //----------------------------------------------------------------------
2473
+
2474
+    /**
2475
+     * @return integer
2476
+     */
2400 2477
     public function eatKanji()
2401 2478
     {
2402 2479
         $p = 0;
@@ -2756,6 +2833,13 @@  discard block
 block discarded – undo
2756 2833
     public static $items = [];
2757 2834
 
2758 2835
     //----------------------------------------------------------------------
2836
+
2837
+    /**
2838
+     * @param integer $symsize
2839
+     * @param integer $gfpoly
2840
+     * @param integer $fcr
2841
+     * @param integer $prim
2842
+     */
2759 2843
     public static function init_rs($symsize, $gfpoly, $fcr, $prim, $nroots, $pad)
2760 2844
     {
2761 2845
         foreach (self::$items as $rs) {
@@ -2949,6 +3033,10 @@  discard block
 block discarded – undo
2949 3033
     }
2950 3034
 
2951 3035
     //----------------------------------------------------------------------
3036
+
3037
+    /**
3038
+     * @param string $code
3039
+     */
2952 3040
     public static function unserial($code)
2953 3041
     {
2954 3042
         $codeArr = [];
@@ -3012,6 +3100,10 @@  discard block
 block discarded – undo
3012 3100
     }
3013 3101
 
3014 3102
     //----------------------------------------------------------------------
3103
+
3104
+    /**
3105
+     * @param integer $length
3106
+     */
3015 3107
     public function calcN1N3($length)
3016 3108
     {
3017 3109
         $demerit = 0;
@@ -3333,6 +3425,10 @@  discard block
 block discarded – undo
3333 3425
     public $data;
3334 3426
 
3335 3427
     //----------------------------------------------------------------------
3428
+
3429
+    /**
3430
+     * @param integer $mask
3431
+     */
3336 3432
     public function encodeMask(QRinput $input, $mask)
3337 3433
     {
3338 3434
         if ($input->getVersion() < 0 || $input->getVersion() > QRSPEC_VERSION_MAX) {
@@ -3414,6 +3510,11 @@  discard block
 block discarded – undo
3414 3510
     }
3415 3511
 
3416 3512
     //----------------------------------------------------------------------
3513
+
3514
+    /**
3515
+     * @param integer $version
3516
+     * @param integer $level
3517
+     */
3417 3518
     public function encodeString8bit($string, $version, $level)
3418 3519
     {
3419 3520
         if (string == null) {
@@ -3438,6 +3539,12 @@  discard block
 block discarded – undo
3438 3539
     }
3439 3540
 
3440 3541
     //----------------------------------------------------------------------
3542
+
3543
+    /**
3544
+     * @param integer $version
3545
+     * @param integer $level
3546
+     * @param boolean $casesensitive
3547
+     */
3441 3548
     public function encodeString($string, $version, $level, $hint, $casesensitive)
3442 3549
     {
3443 3550
 
@@ -3461,6 +3568,10 @@  discard block
 block discarded – undo
3461 3568
     }
3462 3569
 
3463 3570
     //----------------------------------------------------------------------
3571
+
3572
+    /**
3573
+     * @param integer $level
3574
+     */
3464 3575
     public static function png(
3465 3576
         $text,
3466 3577
         $outfile = false,
Please login to merge, or discard this patch.