ofs | hex dump | ascii |
---|
0000 | 23 21 2f 75 73 72 2f 62 69 6e 2f 65 6e 76 20 70 68 70 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 | #!/usr/bin/env.php.<?php../*..*. |
0020 | 47 65 6e 65 72 61 74 65 64 20 62 79 20 48 75 6d 62 75 67 20 42 6f 78 20 33 2e 31 31 2e 31 40 38 | Generated.by.Humbug.Box.3.11.1@8 |
0040 | 33 35 36 37 63 34 2e 0a 20 2a 0a 20 2a 20 40 6c 69 6e 6b 20 68 74 74 70 73 3a 2f 2f 67 69 74 68 | 3567c4...*..*.@link.https://gith |
0060 | 75 62 2e 63 6f 6d 2f 68 75 6d 62 75 67 2f 62 6f 78 0a 20 2a 2f 0a 0a 50 68 61 72 3a 3a 6d 61 70 | ub.com/humbug/box..*/..Phar::map |
0080 | 50 68 61 72 28 27 62 6f 78 2d 61 75 74 6f 2d 67 65 6e 65 72 61 74 65 64 2d 61 6c 69 61 73 2d 35 | Phar('box-auto-generated-alias-5 |
00a0 | 38 61 65 62 63 36 39 61 35 33 34 2e 70 68 61 72 27 29 3b 0a 0a 72 65 71 75 69 72 65 20 27 70 68 | 8aebc69a534.phar');..require.'ph |
00c0 | 61 72 3a 2f 2f 62 6f 78 2d 61 75 74 6f 2d 67 65 6e 65 72 61 74 65 64 2d 61 6c 69 61 73 2d 35 38 | ar://box-auto-generated-alias-58 |
00e0 | 61 65 62 63 36 39 61 35 33 34 2e 70 68 61 72 2f 2e 62 6f 78 2f 62 69 6e 2f 63 68 65 63 6b 2d 72 | aebc69a534.phar/.box/bin/check-r |
0100 | 65 71 75 69 72 65 6d 65 6e 74 73 2e 70 68 70 27 3b 0a 0a 72 65 71 75 69 72 65 20 27 70 68 61 72 | equirements.php';..require.'phar |
0120 | 3a 2f 2f 62 6f 78 2d 61 75 74 6f 2d 67 65 6e 65 72 61 74 65 64 2d 61 6c 69 61 73 2d 35 38 61 65 | ://box-auto-generated-alias-58ae |
0140 | 62 63 36 39 61 35 33 34 2e 70 68 61 72 2f 75 70 64 61 74 65 72 2e 70 68 70 27 3b 0a 0a 5f 5f 48 | bc69a534.phar/updater.php';..__H |
0160 | 41 4c 54 5f 43 4f 4d 50 49 4c 45 52 28 29 3b 20 3f 3e 0d 0a 93 2a 00 00 96 00 00 00 11 00 00 00 | ALT_COMPILER();.?>...*.......... |
0180 | 01 00 00 00 00 00 00 00 00 00 29 00 00 00 76 65 6e 64 6f 72 2f 70 73 72 2f 6c 6f 67 2f 50 73 72 | ..........)...vendor/psr/log/Psr |
01a0 | 2f 4c 6f 67 2f 41 62 73 74 72 61 63 74 4c 6f 67 67 65 72 2e 70 68 70 10 0c 00 00 c5 58 4f 62 10 | /Log/AbstractLogger.php.....XOb. |
01c0 | 0c 00 00 0f 9a 47 6c a4 01 00 00 00 00 00 00 2b 00 00 00 76 65 6e 64 6f 72 2f 70 73 72 2f 6c 6f | .....Gl........+...vendor/psr/lo |
01e0 | 67 2f 50 73 72 2f 4c 6f 67 2f 4c 6f 67 67 65 72 41 77 61 72 65 54 72 61 69 74 2e 70 68 70 8d 01 | g/Psr/Log/LoggerAwareTrait.php.. |
0200 | 00 00 c5 58 4f 62 8d 01 00 00 7a 25 d4 07 a4 01 00 00 00 00 00 00 26 00 00 00 76 65 6e 64 6f 72 | ...XOb....z%..........&...vendor |
0220 | 2f 70 73 72 2f 6c 6f 67 2f 50 73 72 2f 4c 6f 67 2f 4c 6f 67 67 65 72 54 72 61 69 74 2e 70 68 70 | /psr/log/Psr/Log/LoggerTrait.php |
0240 | 1f 0d 00 00 c5 58 4f 62 1f 0d 00 00 9b c3 bd f5 a4 01 00 00 00 00 00 00 33 00 00 00 76 65 6e 64 | .....XOb................3...vend |
0260 | 6f 72 2f 70 73 72 2f 6c 6f 67 2f 50 73 72 2f 4c 6f 67 2f 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 | or/psr/log/Psr/Log/InvalidArgume |
0280 | 6e 74 45 78 63 65 70 74 69 6f 6e 2e 70 68 70 60 00 00 00 c5 58 4f 62 60 00 00 00 20 88 58 31 a4 | ntException.php`....XOb`.....X1. |
02a0 | 01 00 00 00 00 00 00 2f 00 00 00 76 65 6e 64 6f 72 2f 70 73 72 2f 6c 6f 67 2f 50 73 72 2f 4c 6f | ......./...vendor/psr/log/Psr/Lo |
02c0 | 67 2f 4c 6f 67 67 65 72 41 77 61 72 65 49 6e 74 65 72 66 61 63 65 2e 70 68 70 29 01 00 00 c5 58 | g/LoggerAwareInterface.php)....X |
02e0 | 4f 62 29 01 00 00 c8 6a 0c b1 a4 01 00 00 00 00 00 00 33 00 00 00 76 65 6e 64 6f 72 2f 70 73 72 | Ob)....j..........3...vendor/psr |
0300 | 2f 6c 6f 67 2f 50 73 72 2f 4c 6f 67 2f 54 65 73 74 2f 4c 6f 67 67 65 72 49 6e 74 65 72 66 61 63 | /log/Psr/Log/Test/LoggerInterfac |
0320 | 65 54 65 73 74 2e 70 68 70 f5 11 00 00 c5 58 4f 62 f5 11 00 00 ea d0 24 73 a4 01 00 00 00 00 00 | eTest.php.....XOb......$s....... |
0340 | 00 23 00 00 00 76 65 6e 64 6f 72 2f 70 73 72 2f 6c 6f 67 2f 50 73 72 2f 4c 6f 67 2f 4c 6f 67 4c | .#...vendor/psr/log/Psr/Log/LogL |
0360 | 65 76 65 6c 2e 70 68 70 50 01 00 00 c5 58 4f 62 50 01 00 00 9d f2 ba 14 a4 01 00 00 00 00 00 00 | evel.phpP....XObP............... |
0380 | 25 00 00 00 76 65 6e 64 6f 72 2f 70 73 72 2f 6c 6f 67 2f 50 73 72 2f 4c 6f 67 2f 4e 75 6c 6c 4c | %...vendor/psr/log/Psr/Log/NullL |
03a0 | 6f 67 67 65 72 2e 70 68 70 8b 02 00 00 c5 58 4f 62 8b 02 00 00 9a f6 5a 66 a4 01 00 00 00 00 00 | ogger.php.....XOb......Zf....... |
03c0 | 00 2a 00 00 00 76 65 6e 64 6f 72 2f 70 73 72 2f 6c 6f 67 2f 50 73 72 2f 4c 6f 67 2f 4c 6f 67 67 | .*...vendor/psr/log/Psr/Log/Logg |
03e0 | 65 72 49 6e 74 65 72 66 61 63 65 2e 70 68 70 df 0b 00 00 c5 58 4f 62 df 0b 00 00 16 0f 3f 7d a4 | erInterface.php.....XOb......?}. |
0400 | 01 00 00 00 00 00 00 17 00 00 00 76 65 6e 64 6f 72 2f 63 6f 6d 70 6f 73 65 72 2f 4c 49 43 45 4e | ...........vendor/composer/LICEN |
0420 | 53 45 2e 04 00 00 c5 58 4f 62 2e 04 00 00 20 d5 08 03 a4 01 00 00 00 00 00 00 22 00 00 00 76 65 | SE.....XOb................"...ve |
0440 | 6e 64 6f 72 2f 63 6f 6d 70 6f 73 65 72 2f 61 75 74 6f 6c 6f 61 64 5f 66 69 6c 65 73 2e 70 68 70 | ndor/composer/autoload_files.php |
0460 | f3 00 00 00 c5 58 4f 62 f3 00 00 00 14 3c f5 cd a4 01 00 00 00 00 00 00 27 00 00 00 76 65 6e 64 | .....XOb.....<..........'...vend |
0480 | 6f 72 2f 63 6f 6d 70 6f 73 65 72 2f 61 75 74 6f 6c 6f 61 64 5f 6e 61 6d 65 73 70 61 63 65 73 2e | or/composer/autoload_namespaces. |
04a0 | 70 68 70 95 00 00 00 c5 58 4f 62 95 00 00 00 74 db 21 d7 a4 01 00 00 00 00 00 00 22 00 00 00 76 | php.....XOb....t.!........."...v |
04c0 | 65 6e 64 6f 72 2f 63 6f 6d 70 6f 73 65 72 2f 70 6c 61 74 66 6f 72 6d 5f 63 68 65 63 6b 2e 70 68 | endor/composer/platform_check.ph |
04e0 | 70 9d 03 00 00 c5 58 4f 62 9d 03 00 00 69 fb 20 4f a4 01 00 00 00 00 00 00 21 00 00 00 76 65 6e | p.....XOb....i..O........!...ven |
0500 | 64 6f 72 2f 63 6f 6d 70 6f 73 65 72 2f 61 75 74 6f 6c 6f 61 64 5f 72 65 61 6c 2e 70 68 70 0e 09 | dor/composer/autoload_real.php.. |
0520 | 00 00 c5 58 4f 62 0e 09 00 00 df 92 81 5c a4 01 00 00 00 00 00 00 23 00 00 00 76 65 6e 64 6f 72 | ...XOb.......\........#...vendor |
0540 | 2f 63 6f 6d 70 6f 73 65 72 2f 61 75 74 6f 6c 6f 61 64 5f 73 74 61 74 69 63 2e 70 68 70 7d 3a 00 | /composer/autoload_static.php}:. |
0560 | 00 c5 58 4f 62 7d 3a 00 00 12 1f d0 3c a4 01 00 00 00 00 00 00 25 00 00 00 76 65 6e 64 6f 72 2f | ..XOb}:.....<........%...vendor/ |
0580 | 63 6f 6d 70 6f 73 65 72 2f 61 75 74 6f 6c 6f 61 64 5f 63 6c 61 73 73 6d 61 70 2e 70 68 70 fc 2f | composer/autoload_classmap.php./ |
05a0 | 00 00 c5 58 4f 62 fc 2f 00 00 75 89 4f cd a4 01 00 00 00 00 00 00 21 00 00 00 76 65 6e 64 6f 72 | ...XOb./..u.O.........!...vendor |
05c0 | 2f 63 6f 6d 70 6f 73 65 72 2f 61 75 74 6f 6c 6f 61 64 5f 70 73 72 34 2e 70 68 70 ef 01 00 00 c5 | /composer/autoload_psr4.php..... |
05e0 | 58 4f 62 ef 01 00 00 62 75 f7 54 a4 01 00 00 00 00 00 00 1f 00 00 00 76 65 6e 64 6f 72 2f 63 6f | XOb....bu.T............vendor/co |
0600 | 6d 70 6f 73 65 72 2f 43 6c 61 73 73 4c 6f 61 64 65 72 2e 70 68 70 c4 3e 00 00 c5 58 4f 62 c4 3e | mposer/ClassLoader.php.>...XOb.> |
0620 | 00 00 c6 35 4b 79 a4 01 00 00 00 00 00 00 28 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 | ...5Ky........(...vendor/symfony |
0640 | 2f 64 65 62 75 67 2f 42 75 66 66 65 72 69 6e 67 4c 6f 67 67 65 72 2e 70 68 70 f0 02 00 00 c5 58 | /debug/BufferingLogger.php.....X |
0660 | 4f 62 f0 02 00 00 4d 30 09 3d a4 01 00 00 00 00 00 00 25 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d | Ob....M0.=........%...vendor/sym |
0680 | 66 6f 6e 79 2f 64 65 62 75 67 2f 45 72 72 6f 72 48 61 6e 64 6c 65 72 2e 70 68 70 a1 60 00 00 c5 | fony/debug/ErrorHandler.php.`... |
06a0 | 58 4f 62 a1 60 00 00 b7 f2 76 4e a4 01 00 00 00 00 00 00 1e 00 00 00 76 65 6e 64 6f 72 2f 73 79 | XOb.`....vN............vendor/sy |
06c0 | 6d 66 6f 6e 79 2f 64 65 62 75 67 2f 44 65 62 75 67 2e 70 68 70 fd 06 00 00 c5 58 4f 62 fd 06 00 | mfony/debug/Debug.php.....XOb... |
06e0 | 00 f6 90 08 66 a4 01 00 00 00 00 00 00 29 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f | ....f........)...vendor/symfony/ |
0700 | 64 65 62 75 67 2f 45 78 63 65 70 74 69 6f 6e 48 61 6e 64 6c 65 72 2e 70 68 70 5b 3f 00 00 c5 58 | debug/ExceptionHandler.php[?...X |
0720 | 4f 62 5b 3f 00 00 03 f9 b3 40 a4 01 00 00 00 00 00 00 29 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d | Ob[?.....@........)...vendor/sym |
0740 | 66 6f 6e 79 2f 64 65 62 75 67 2f 44 65 62 75 67 43 6c 61 73 73 4c 6f 61 64 65 72 2e 70 68 70 9c | fony/debug/DebugClassLoader.php. |
0760 | 2e 00 00 c5 58 4f 62 9c 2e 00 00 58 96 03 93 a4 01 00 00 00 00 00 00 4d 00 00 00 76 65 6e 64 6f | ....XOb....X...........M...vendo |
0780 | 72 2f 73 79 6d 66 6f 6e 79 2f 64 65 62 75 67 2f 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 | r/symfony/debug/FatalErrorHandle |
07a0 | 72 2f 55 6e 64 65 66 69 6e 65 64 46 75 6e 63 74 69 6f 6e 46 61 74 61 6c 45 72 72 6f 72 48 61 6e | r/UndefinedFunctionFatalErrorHan |
07c0 | 64 6c 65 72 2e 70 68 70 f5 0b 00 00 c5 58 4f 62 f5 0b 00 00 cc 67 fd 90 a4 01 00 00 00 00 00 00 | dler.php.....XOb.....g.......... |
07e0 | 49 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 64 65 62 75 67 2f 46 61 74 61 6c 45 72 | I...vendor/symfony/debug/FatalEr |
0800 | 72 6f 72 48 61 6e 64 6c 65 72 2f 43 6c 61 73 73 4e 6f 74 46 6f 75 6e 64 46 61 74 61 6c 45 72 72 | rorHandler/ClassNotFoundFatalErr |
0820 | 6f 72 48 61 6e 64 6c 65 72 2e 70 68 70 ca 1c 00 00 c5 58 4f 62 ca 1c 00 00 74 e3 d0 1f a4 01 00 | orHandler.php.....XOb....t...... |
0840 | 00 00 00 00 00 4b 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 64 65 62 75 67 2f 46 61 | .....K...vendor/symfony/debug/Fa |
0860 | 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 2f 55 6e 64 65 66 69 6e 65 64 4d 65 74 68 6f 64 46 | talErrorHandler/UndefinedMethodF |
0880 | 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 2e 70 68 70 3e 07 00 00 c5 58 4f 62 3e 07 00 00 | atalErrorHandler.php>....XOb>... |
08a0 | f2 ef a1 cb a4 01 00 00 00 00 00 00 45 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 64 | ............E...vendor/symfony/d |
08c0 | 65 62 75 67 2f 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 2f 46 61 74 61 6c 45 72 72 6f | ebug/FatalErrorHandler/FatalErro |
08e0 | 72 48 61 6e 64 6c 65 72 49 6e 74 65 72 66 61 63 65 2e 70 68 70 bf 03 00 00 c5 58 4f 62 bf 03 00 | rHandlerInterface.php.....XOb... |
0900 | 00 c7 69 41 bc a4 01 00 00 00 00 00 00 36 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f | ..iA.........6...vendor/symfony/ |
0920 | 64 65 62 75 67 2f 45 78 63 65 70 74 69 6f 6e 2f 46 61 74 61 6c 54 68 72 6f 77 61 62 6c 65 45 72 | debug/Exception/FatalThrowableEr |
0940 | 72 6f 72 2e 70 68 70 34 04 00 00 c5 58 4f 62 34 04 00 00 00 c3 1c ec a4 01 00 00 00 00 00 00 37 | ror.php4....XOb4...............7 |
0960 | 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 64 65 62 75 67 2f 45 78 63 65 70 74 69 6f | ...vendor/symfony/debug/Exceptio |
0980 | 6e 2f 4f 75 74 4f 66 4d 65 6d 6f 72 79 45 78 63 65 70 74 69 6f 6e 2e 70 68 70 a8 01 00 00 c5 58 | n/OutOfMemoryException.php.....X |
09a0 | 4f 62 a8 01 00 00 aa f8 0b 68 a4 01 00 00 00 00 00 00 33 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d | Ob.......h........3...vendor/sym |
09c0 | 66 6f 6e 79 2f 64 65 62 75 67 2f 45 78 63 65 70 74 69 6f 6e 2f 46 6c 61 74 74 65 6e 45 78 63 65 | fony/debug/Exception/FlattenExce |
09e0 | 70 74 69 6f 6e 2e 70 68 70 b6 1a 00 00 c5 58 4f 62 b6 1a 00 00 82 37 aa 1b a4 01 00 00 00 00 00 | ption.php.....XOb.....7......... |
0a00 | 00 3d 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 64 65 62 75 67 2f 45 78 63 65 70 74 | .=...vendor/symfony/debug/Except |
0a20 | 69 6f 6e 2f 55 6e 64 65 66 69 6e 65 64 46 75 6e 63 74 69 6f 6e 45 78 63 65 70 74 69 6f 6e 2e 70 | ion/UndefinedFunctionException.p |
0a40 | 68 70 2b 03 00 00 c5 58 4f 62 2b 03 00 00 db 1f 4f f9 a4 01 00 00 00 00 00 00 39 00 00 00 76 65 | hp+....XOb+.....O.........9...ve |
0a60 | 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 64 65 62 75 67 2f 45 78 63 65 70 74 69 6f 6e 2f 43 6c 61 | ndor/symfony/debug/Exception/Cla |
0a80 | 73 73 4e 6f 74 46 6f 75 6e 64 45 78 63 65 70 74 69 6f 6e 2e 70 68 70 3c 03 00 00 c5 58 4f 62 3c | ssNotFoundException.php<....XOb< |
0aa0 | 03 00 00 27 44 bb 8d a4 01 00 00 00 00 00 00 3b 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e | ...'D..........;...vendor/symfon |
0ac0 | 79 2f 64 65 62 75 67 2f 45 78 63 65 70 74 69 6f 6e 2f 55 6e 64 65 66 69 6e 65 64 4d 65 74 68 6f | y/debug/Exception/UndefinedMetho |
0ae0 | 64 45 78 63 65 70 74 69 6f 6e 2e 70 68 70 26 03 00 00 c5 58 4f 62 26 03 00 00 c3 af 79 df a4 01 | dException.php&....XOb&.....y... |
0b00 | 00 00 00 00 00 00 36 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 64 65 62 75 67 2f 45 | ......6...vendor/symfony/debug/E |
0b20 | 78 63 65 70 74 69 6f 6e 2f 46 61 74 61 6c 45 72 72 6f 72 45 78 63 65 70 74 69 6f 6e 2e 70 68 70 | xception/FatalErrorException.php |
0b40 | 18 0b 00 00 c5 58 4f 62 18 0b 00 00 55 b9 ae 6c a4 01 00 00 00 00 00 00 38 00 00 00 76 65 6e 64 | .....XOb....U..l........8...vend |
0b60 | 6f 72 2f 73 79 6d 66 6f 6e 79 2f 64 65 62 75 67 2f 45 78 63 65 70 74 69 6f 6e 2f 43 6f 6e 74 65 | or/symfony/debug/Exception/Conte |
0b80 | 78 74 45 72 72 6f 72 45 78 63 65 70 74 69 6f 6e 2e 70 68 70 6b 03 00 00 c5 58 4f 62 6b 03 00 00 | xtErrorException.phpk....XObk... |
0ba0 | 47 01 0d 18 a4 01 00 00 00 00 00 00 40 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 70 | G...........@...vendor/symfony/p |
0bc0 | 6f 6c 79 66 69 6c 6c 2d 6d 62 73 74 72 69 6e 67 2f 52 65 73 6f 75 72 63 65 73 2f 75 6e 69 64 61 | olyfill-mbstring/Resources/unida |
0be0 | 74 61 2f 6c 6f 77 65 72 43 61 73 65 2e 70 68 70 ba 49 00 00 c5 58 4f 62 ba 49 00 00 ea 90 d2 88 | ta/lowerCase.php.I...XOb.I...... |
0c00 | a4 01 00 00 00 00 00 00 40 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 70 6f 6c 79 66 | ........@...vendor/symfony/polyf |
0c20 | 69 6c 6c 2d 6d 62 73 74 72 69 6e 67 2f 52 65 73 6f 75 72 63 65 73 2f 75 6e 69 64 61 74 61 2f 75 | ill-mbstring/Resources/unidata/u |
0c40 | 70 70 65 72 43 61 73 65 2e 70 68 70 39 4a 00 00 c5 58 4f 62 39 4a 00 00 7c 18 51 f9 a4 01 00 00 | pperCase.php9J...XOb9J..|.Q..... |
0c60 | 00 00 00 00 2d 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 70 6f 6c 79 66 69 6c 6c 2d | ....-...vendor/symfony/polyfill- |
0c80 | 6d 62 73 74 72 69 6e 67 2f 4d 62 73 74 72 69 6e 67 2e 70 68 70 fc 4c 00 00 c5 58 4f 62 fc 4c 00 | mbstring/Mbstring.php.L...XOb.L. |
0ca0 | 00 8c eb f1 e8 a4 01 00 00 00 00 00 00 2e 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f | .................vendor/symfony/ |
0cc0 | 70 6f 6c 79 66 69 6c 6c 2d 6d 62 73 74 72 69 6e 67 2f 62 6f 6f 74 73 74 72 61 70 2e 70 68 70 d9 | polyfill-mbstring/bootstrap.php. |
0ce0 | 0f 00 00 c5 58 4f 62 d9 0f 00 00 57 38 20 cf a4 01 00 00 00 00 00 00 36 00 00 00 76 65 6e 64 6f | ....XOb....W8..........6...vendo |
0d00 | 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 45 76 65 6e 74 2f 43 6f 6e 73 6f 6c 65 45 | r/symfony/console/Event/ConsoleE |
0d20 | 78 63 65 70 74 69 6f 6e 45 76 65 6e 74 2e 70 68 70 3d 06 00 00 c5 58 4f 62 3d 06 00 00 b7 a6 16 | xceptionEvent.php=....XOb=...... |
0d40 | c5 a4 01 00 00 00 00 00 00 36 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 | .........6...vendor/symfony/cons |
0d60 | 6f 6c 65 2f 45 76 65 6e 74 2f 43 6f 6e 73 6f 6c 65 54 65 72 6d 69 6e 61 74 65 45 76 65 6e 74 2e | ole/Event/ConsoleTerminateEvent. |
0d80 | 70 68 70 1a 05 00 00 c5 58 4f 62 1a 05 00 00 7b 65 f0 13 a4 01 00 00 00 00 00 00 2d 00 00 00 76 | php.....XOb....{e..........-...v |
0da0 | 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 45 76 65 6e 74 2f 43 6f 6e 73 | endor/symfony/console/Event/Cons |
0dc0 | 6f 6c 65 45 76 65 6e 74 2e 70 68 70 b8 05 00 00 c5 58 4f 62 b8 05 00 00 be f5 0a 9e a4 01 00 00 | oleEvent.php.....XOb............ |
0de0 | 00 00 00 00 34 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 45 | ....4...vendor/symfony/console/E |
0e00 | 76 65 6e 74 2f 43 6f 6e 73 6f 6c 65 43 6f 6d 6d 61 6e 64 45 76 65 6e 74 2e 70 68 70 3d 05 00 00 | vent/ConsoleCommandEvent.php=... |
0e20 | c5 58 4f 62 3d 05 00 00 06 25 6d 66 a4 01 00 00 00 00 00 00 2c 00 00 00 76 65 6e 64 6f 72 2f 73 | .XOb=....%mf........,...vendor/s |
0e40 | 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 53 74 79 6c 65 2f 4f 75 74 70 75 74 53 74 79 6c 65 | ymfony/console/Style/OutputStyle |
0e60 | 2e 70 68 70 24 0b 00 00 c5 58 4f 62 24 0b 00 00 e9 03 7f 38 a4 01 00 00 00 00 00 00 2f 00 00 00 | .php$....XOb$......8......../... |
0e80 | 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 53 74 79 6c 65 2f 53 74 79 | vendor/symfony/console/Style/Sty |
0ea0 | 6c 65 49 6e 74 65 72 66 61 63 65 2e 70 68 70 b5 0c 00 00 c5 58 4f 62 b5 0c 00 00 33 a8 f5 5a a4 | leInterface.php.....XOb....3..Z. |
0ec0 | 01 00 00 00 00 00 00 2d 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c | .......-...vendor/symfony/consol |
0ee0 | 65 2f 53 74 79 6c 65 2f 53 79 6d 66 6f 6e 79 53 74 79 6c 65 2e 70 68 70 3e 2f 00 00 c5 58 4f 62 | e/Style/SymfonyStyle.php>/...XOb |
0f00 | 3e 2f 00 00 99 03 b8 0b a4 01 00 00 00 00 00 00 38 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f | >/..............8...vendor/symfo |
0f20 | 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 4f 75 74 70 75 74 2f 43 6f 6e 73 6f 6c 65 4f 75 74 70 75 74 49 | ny/console/Output/ConsoleOutputI |
0f40 | 6e 74 65 72 66 61 63 65 2e 70 68 70 4b 03 00 00 c5 58 4f 62 4b 03 00 00 ec c5 30 9e a4 01 00 00 | nterface.phpK....XObK.....0..... |
0f60 | 00 00 00 00 2e 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 4f | ........vendor/symfony/console/O |
0f80 | 75 74 70 75 74 2f 53 74 72 65 61 6d 4f 75 74 70 75 74 2e 70 68 70 12 0d 00 00 c5 58 4f 62 12 0d | utput/StreamOutput.php.....XOb.. |
0fa0 | 00 00 b8 57 ae ea a4 01 00 00 00 00 00 00 30 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 | ...W..........0...vendor/symfony |
0fc0 | 2f 63 6f 6e 73 6f 6c 65 2f 4f 75 74 70 75 74 2f 42 75 66 66 65 72 65 64 4f 75 74 70 75 74 2e 70 | /console/Output/BufferedOutput.p |
0fe0 | 68 70 68 03 00 00 c5 58 4f 62 68 03 00 00 74 7c 58 34 a4 01 00 00 00 00 00 00 2c 00 00 00 76 65 | hph....XObh...t|X4........,...ve |
1000 | 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 4f 75 74 70 75 74 2f 4e 75 6c 6c | ndor/symfony/console/Output/Null |
1020 | 4f 75 74 70 75 74 2e 70 68 70 6e 08 00 00 c5 58 4f 62 6e 08 00 00 74 8f 44 bb a4 01 00 00 00 00 | Output.phpn....XObn...t.D....... |
1040 | 00 00 28 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 4f 75 74 | ..(...vendor/symfony/console/Out |
1060 | 70 75 74 2f 4f 75 74 70 75 74 2e 70 68 70 96 11 00 00 c5 58 4f 62 96 11 00 00 c2 84 97 9f a4 01 | put/Output.php.....XOb.......... |
1080 | 00 00 00 00 00 00 2f 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 | ....../...vendor/symfony/console |
10a0 | 2f 4f 75 74 70 75 74 2f 43 6f 6e 73 6f 6c 65 4f 75 74 70 75 74 2e 70 68 70 ee 0f 00 00 c5 58 4f | /Output/ConsoleOutput.php.....XO |
10c0 | 62 ee 0f 00 00 86 a3 da 5c a4 01 00 00 00 00 00 00 31 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 | b.......\........1...vendor/symf |
10e0 | 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 4f 75 74 70 75 74 2f 4f 75 74 70 75 74 49 6e 74 65 72 66 61 | ony/console/Output/OutputInterfa |
1100 | 63 65 2e 70 68 70 72 0d 00 00 c5 58 4f 62 72 0d 00 00 e9 cb 3e 5a a4 01 00 00 00 00 00 00 30 00 | ce.phpr....XObr.....>Z........0. |
1120 | 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 49 6e 70 75 74 2f 49 | ..vendor/symfony/console/Input/I |
1140 | 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 2e 70 68 70 32 2d 00 00 c5 58 4f 62 32 2d 00 00 59 9b | nputDefinition.php2-...XOb2-..Y. |
1160 | bb 2c a4 01 00 00 00 00 00 00 34 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e | .,........4...vendor/symfony/con |
1180 | 73 6f 6c 65 2f 49 6e 70 75 74 2f 49 6e 70 75 74 41 77 61 72 65 49 6e 74 65 72 66 61 63 65 2e 70 | sole/Input/InputAwareInterface.p |
11a0 | 68 70 5e 02 00 00 c5 58 4f 62 5e 02 00 00 39 4b e8 68 a4 01 00 00 00 00 00 00 2c 00 00 00 76 65 | hp^....XOb^...9K.h........,...ve |
11c0 | 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 49 6e 70 75 74 2f 53 74 72 69 6e | ndor/symfony/console/Input/Strin |
11e0 | 67 49 6e 70 75 74 2e 70 68 70 72 09 00 00 c5 58 4f 62 72 09 00 00 fd 66 49 79 a4 01 00 00 00 00 | gInput.phpr....XObr....fIy...... |
1200 | 00 00 2a 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 49 6e 70 | ..*...vendor/symfony/console/Inp |
1220 | 75 74 2f 41 72 67 76 49 6e 70 75 74 2e 70 68 70 52 28 00 00 c5 58 4f 62 52 28 00 00 9c 89 08 f1 | ut/ArgvInput.phpR(...XObR(...... |
1240 | a4 01 00 00 00 00 00 00 2b 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f | ........+...vendor/symfony/conso |
1260 | 6c 65 2f 49 6e 70 75 74 2f 41 72 72 61 79 49 6e 70 75 74 2e 70 68 70 3f 15 00 00 c5 58 4f 62 3f | le/Input/ArrayInput.php?....XOb? |
1280 | 15 00 00 75 39 33 7a a4 01 00 00 00 00 00 00 2e 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e | ...u93z............vendor/symfon |
12a0 | 79 2f 63 6f 6e 73 6f 6c 65 2f 49 6e 70 75 74 2f 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 2e 70 68 | y/console/Input/InputArgument.ph |
12c0 | 70 17 0d 00 00 c5 58 4f 62 17 0d 00 00 e6 17 6d 42 a4 01 00 00 00 00 00 00 2c 00 00 00 76 65 6e | p.....XOb......mB........,...ven |
12e0 | 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 49 6e 70 75 74 2f 49 6e 70 75 74 4f | dor/symfony/console/Input/InputO |
1300 | 70 74 69 6f 6e 2e 70 68 70 77 17 00 00 c5 58 4f 62 77 17 00 00 a3 0e 38 73 a4 01 00 00 00 00 00 | ption.phpw....XObw.....8s....... |
1320 | 00 26 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 49 6e 70 75 | .&...vendor/symfony/console/Inpu |
1340 | 74 2f 49 6e 70 75 74 2e 70 68 70 fe 12 00 00 c5 58 4f 62 fe 12 00 00 8d ee 30 a8 a4 01 00 00 00 | t/Input.php.....XOb......0...... |
1360 | 00 00 00 2f 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 49 6e | .../...vendor/symfony/console/In |
1380 | 70 75 74 2f 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 2e 70 68 70 6e 12 00 00 c5 58 4f 62 6e 12 | put/InputInterface.phpn....XObn. |
13a0 | 00 00 6c 8a 8a 7a a4 01 00 00 00 00 00 00 28 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 | ..l..z........(...vendor/symfony |
13c0 | 2f 63 6f 6e 73 6f 6c 65 2f 43 6f 6e 73 6f 6c 65 45 76 65 6e 74 73 2e 70 68 70 7b 05 00 00 c5 58 | /console/ConsoleEvents.php{....X |
13e0 | 4f 62 7b 05 00 00 f9 7f 36 3e a4 01 00 00 00 00 00 00 26 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d | Ob{.....6>........&...vendor/sym |
1400 | 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 41 70 70 6c 69 63 61 74 69 6f 6e 2e 70 68 70 1c 93 00 00 | fony/console/Application.php.... |
1420 | c5 58 4f 62 1c 93 00 00 b6 4b f0 46 a4 01 00 00 00 00 00 00 37 00 00 00 76 65 6e 64 6f 72 2f 73 | .XOb.....K.F........7...vendor/s |
1440 | 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 48 65 6c 70 65 72 2f 53 79 6d 66 6f 6e 79 51 75 65 | ymfony/console/Helper/SymfonyQue |
1460 | 73 74 69 6f 6e 48 65 6c 70 65 72 2e 70 68 70 ba 0e 00 00 c5 58 4f 62 ba 0e 00 00 ce 51 09 22 a4 | stionHelper.php.....XOb.....Q.". |
1480 | 01 00 00 00 00 00 00 33 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c | .......3...vendor/symfony/consol |
14a0 | 65 2f 48 65 6c 70 65 72 2f 50 72 6f 67 72 65 73 73 49 6e 64 69 63 61 74 6f 72 2e 70 68 70 92 21 | e/Helper/ProgressIndicator.php.! |
14c0 | 00 00 c5 58 4f 62 92 21 00 00 e6 2b 9e c1 a4 01 00 00 00 00 00 00 2d 00 00 00 76 65 6e 64 6f 72 | ...XOb.!...+..........-...vendor |
14e0 | 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 48 65 6c 70 65 72 2f 50 72 6f 67 72 65 73 73 | /symfony/console/Helper/Progress |
1500 | 42 61 72 2e 70 68 70 2e 41 00 00 c5 58 4f 62 2e 41 00 00 11 d0 58 10 a4 01 00 00 00 00 00 00 30 | Bar.php.A...XOb.A....X.........0 |
1520 | 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 48 65 6c 70 65 72 | ...vendor/symfony/console/Helper |
1540 | 2f 51 75 65 73 74 69 6f 6e 48 65 6c 70 65 72 2e 70 68 70 b6 34 00 00 c5 58 4f 62 b6 34 00 00 02 | /QuestionHelper.php.4...XOb.4... |
1560 | f3 69 cf a4 01 00 00 00 00 00 00 2b 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f | .i.........+...vendor/symfony/co |
1580 | 6e 73 6f 6c 65 2f 48 65 6c 70 65 72 2f 48 65 6c 70 65 72 53 65 74 2e 70 68 70 67 0a 00 00 c5 58 | nsole/Helper/HelperSet.phpg....X |
15a0 | 4f 62 67 0a 00 00 06 66 d6 f4 a4 01 00 00 00 00 00 00 2c 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d | Obg....f..........,...vendor/sym |
15c0 | 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 48 65 6c 70 65 72 2f 54 61 62 6c 65 53 74 79 6c 65 2e 70 | fony/console/Helper/TableStyle.p |
15e0 | 68 70 b5 14 00 00 c5 58 4f 62 b5 14 00 00 6b 84 12 95 a4 01 00 00 00 00 00 00 36 00 00 00 76 65 | hp.....XOb....k...........6...ve |
1600 | 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 48 65 6c 70 65 72 2f 44 65 62 75 | ndor/symfony/console/Helper/Debu |
1620 | 67 46 6f 72 6d 61 74 74 65 72 48 65 6c 70 65 72 2e 70 68 70 56 10 00 00 c5 58 4f 62 56 10 00 00 | gFormatterHelper.phpV....XObV... |
1640 | 98 dd 94 aa a4 01 00 00 00 00 00 00 2f 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 | ............/...vendor/symfony/c |
1660 | 6f 6e 73 6f 6c 65 2f 48 65 6c 70 65 72 2f 50 72 6f 63 65 73 73 48 65 6c 70 65 72 2e 70 68 70 87 | onsole/Helper/ProcessHelper.php. |
1680 | 13 00 00 c5 58 4f 62 87 13 00 00 8c ae 41 1b a4 01 00 00 00 00 00 00 30 00 00 00 76 65 6e 64 6f | ....XOb......A.........0...vendo |
16a0 | 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 48 65 6c 70 65 72 2f 54 61 62 6c 65 53 65 | r/symfony/console/Helper/TableSe |
16c0 | 70 61 72 61 74 6f 72 2e 70 68 70 45 02 00 00 c5 58 4f 62 45 02 00 00 1e 70 7c d5 a4 01 00 00 00 | parator.phpE....XObE....p|...... |
16e0 | 00 00 00 32 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 48 65 | ...2...vendor/symfony/console/He |
1700 | 6c 70 65 72 2f 49 6e 70 75 74 41 77 61 72 65 48 65 6c 70 65 72 2e 70 68 70 eb 02 00 00 c5 58 4f | lper/InputAwareHelper.php.....XO |
1720 | 62 eb 02 00 00 ec 93 eb cb a4 01 00 00 00 00 00 00 28 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 | b................(...vendor/symf |
1740 | 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 48 65 6c 70 65 72 2f 48 65 6c 70 65 72 2e 70 68 70 c2 0c 00 | ony/console/Helper/Helper.php... |
1760 | 00 c5 58 4f 62 c2 0c 00 00 8c f6 ad 02 a4 01 00 00 00 00 00 00 31 00 00 00 76 65 6e 64 6f 72 2f | ..XOb................1...vendor/ |
1780 | 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 48 65 6c 70 65 72 2f 46 6f 72 6d 61 74 74 65 72 | symfony/console/Helper/Formatter |
17a0 | 48 65 6c 70 65 72 2e 70 68 70 92 0b 00 00 c5 58 4f 62 92 0b 00 00 b5 ed b7 ff a4 01 00 00 00 00 | Helper.php.....XOb.............. |
17c0 | 00 00 27 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 48 65 6c | ..'...vendor/symfony/console/Hel |
17e0 | 70 65 72 2f 54 61 62 6c 65 2e 70 68 70 79 4c 00 00 c5 58 4f 62 79 4c 00 00 84 a8 cb 8e a4 01 00 | per/Table.phpyL...XObyL......... |
1800 | 00 00 00 00 00 2b 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f | .....+...vendor/symfony/console/ |
1820 | 48 65 6c 70 65 72 2f 54 61 62 6c 65 43 65 6c 6c 2e 70 68 70 56 06 00 00 c5 58 4f 62 56 06 00 00 | Helper/TableCell.phpV....XObV... |
1840 | 01 25 11 14 a4 01 00 00 00 00 00 00 32 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 | .%..........2...vendor/symfony/c |
1860 | 6f 6e 73 6f 6c 65 2f 48 65 6c 70 65 72 2f 44 65 73 63 72 69 70 74 6f 72 48 65 6c 70 65 72 2e 70 | onsole/Helper/DescriptorHelper.p |
1880 | 68 70 60 0a 00 00 c5 58 4f 62 60 0a 00 00 2b 37 2a c5 a4 01 00 00 00 00 00 00 31 00 00 00 76 65 | hp`....XOb`...+7*.........1...ve |
18a0 | 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 48 65 6c 70 65 72 2f 48 65 6c 70 | ndor/symfony/console/Helper/Help |
18c0 | 65 72 49 6e 74 65 72 66 61 63 65 2e 70 68 70 af 03 00 00 c5 58 4f 62 af 03 00 00 ef cb e8 f6 a4 | erInterface.php.....XOb......... |
18e0 | 01 00 00 00 00 00 00 42 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c | .......B...vendor/symfony/consol |
1900 | 65 2f 46 6f 72 6d 61 74 74 65 72 2f 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c 65 | e/Formatter/OutputFormatterStyle |
1920 | 49 6e 74 65 72 66 61 63 65 2e 70 68 70 5b 05 00 00 c5 58 4f 62 5b 05 00 00 66 40 86 b3 a4 01 00 | Interface.php[....XOb[...f@..... |
1940 | 00 00 00 00 00 34 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f | .....4...vendor/symfony/console/ |
1960 | 46 6f 72 6d 61 74 74 65 72 2f 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 2e 70 68 70 3f 1a 00 | Formatter/OutputFormatter.php?.. |
1980 | 00 c5 58 4f 62 3f 1a 00 00 e8 1d bd 85 a4 01 00 00 00 00 00 00 39 00 00 00 76 65 6e 64 6f 72 2f | ..XOb?...............9...vendor/ |
19a0 | 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 46 6f 72 6d 61 74 74 65 72 2f 4f 75 74 70 75 74 | symfony/console/Formatter/Output |
19c0 | 46 6f 72 6d 61 74 74 65 72 53 74 79 6c 65 2e 70 68 70 c0 1a 00 00 c5 58 4f 62 c0 1a 00 00 44 31 | FormatterStyle.php.....XOb....D1 |
19e0 | a9 f0 a4 01 00 00 00 00 00 00 3d 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e | ..........=...vendor/symfony/con |
1a00 | 73 6f 6c 65 2f 46 6f 72 6d 61 74 74 65 72 2f 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 49 6e | sole/Formatter/OutputFormatterIn |
1a20 | 74 65 72 66 61 63 65 2e 70 68 70 5d 06 00 00 c5 58 4f 62 5d 06 00 00 fc 79 09 4c a4 01 00 00 00 | terface.php]....XOb]....y.L..... |
1a40 | 00 00 00 3e 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 46 6f | ...>...vendor/symfony/console/Fo |
1a60 | 72 6d 61 74 74 65 72 2f 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c 65 53 74 61 63 | rmatter/OutputFormatterStyleStac |
1a80 | 6b 2e 70 68 70 26 0b 00 00 c5 58 4f 62 26 0b 00 00 5d b6 34 bb a4 01 00 00 00 00 00 00 2c 00 00 | k.php&....XOb&...].4.........,.. |
1aa0 | 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 51 75 65 73 74 69 6f 6e | .vendor/symfony/console/Question |
1ac0 | 2f 51 75 65 73 74 69 6f 6e 2e 70 68 70 18 17 00 00 c5 58 4f 62 18 17 00 00 6e 4a 82 55 a4 01 00 | /Question.php.....XOb....nJ.U... |
1ae0 | 00 00 00 00 00 32 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f | .....2...vendor/symfony/console/ |
1b00 | 51 75 65 73 74 69 6f 6e 2f 43 68 6f 69 63 65 51 75 65 73 74 69 6f 6e 2e 70 68 70 c2 13 00 00 c5 | Question/ChoiceQuestion.php..... |
1b20 | 58 4f 62 c2 13 00 00 6e 02 1d 78 a4 01 00 00 00 00 00 00 38 00 00 00 76 65 6e 64 6f 72 2f 73 79 | XOb....n..x........8...vendor/sy |
1b40 | 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 51 75 65 73 74 69 6f 6e 2f 43 6f 6e 66 69 72 6d 61 74 | mfony/console/Question/Confirmat |
1b60 | 69 6f 6e 51 75 65 73 74 69 6f 6e 2e 70 68 70 37 06 00 00 c5 58 4f 62 37 06 00 00 e2 9c 26 83 a4 | ionQuestion.php7....XOb7.....&.. |
1b80 | 01 00 00 00 00 00 00 2e 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c | ...........vendor/symfony/consol |
1ba0 | 65 2f 43 6f 6d 6d 61 6e 64 2f 48 65 6c 70 43 6f 6d 6d 61 6e 64 2e 70 68 70 ab 09 00 00 c5 58 4f | e/Command/HelpCommand.php.....XO |
1bc0 | 62 ab 09 00 00 d9 71 83 a6 a4 01 00 00 00 00 00 00 2a 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 | b.....q..........*...vendor/symf |
1be0 | 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 43 6f 6d 6d 61 6e 64 2f 43 6f 6d 6d 61 6e 64 2e 70 68 70 30 | ony/console/Command/Command.php0 |
1c00 | 47 00 00 c5 58 4f 62 30 47 00 00 38 d6 cf 95 a4 01 00 00 00 00 00 00 2e 00 00 00 76 65 6e 64 6f | G...XOb0G..8...............vendo |
1c20 | 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 43 6f 6d 6d 61 6e 64 2f 4c 69 73 74 43 6f | r/symfony/console/Command/ListCo |
1c40 | 6d 6d 61 6e 64 2e 70 68 70 09 0a 00 00 c5 58 4f 62 09 0a 00 00 ea c2 0c 34 a4 01 00 00 00 00 00 | mmand.php.....XOb.......4....... |
1c60 | 00 33 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 44 65 73 63 | .3...vendor/symfony/console/Desc |
1c80 | 72 69 70 74 6f 72 2f 58 6d 6c 44 65 73 63 72 69 70 74 6f 72 2e 70 68 70 53 25 00 00 c5 58 4f 62 | riptor/XmlDescriptor.phpS%...XOb |
1ca0 | 53 25 00 00 a2 e0 4e 90 a4 01 00 00 00 00 00 00 39 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f | S%....N.........9...vendor/symfo |
1cc0 | 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 44 65 73 63 72 69 70 74 6f 72 2f 44 65 73 63 72 69 70 74 6f 72 | ny/console/Descriptor/Descriptor |
1ce0 | 49 6e 74 65 72 66 61 63 65 2e 70 68 70 e1 02 00 00 c5 58 4f 62 e1 02 00 00 4a 5a 30 3c a4 01 00 | Interface.php.....XOb....JZ0<... |
1d00 | 00 00 00 00 00 3c 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f | .....<...vendor/symfony/console/ |
1d20 | 44 65 73 63 72 69 70 74 6f 72 2f 41 70 70 6c 69 63 61 74 69 6f 6e 44 65 73 63 72 69 70 74 69 6f | Descriptor/ApplicationDescriptio |
1d40 | 6e 2e 70 68 70 03 0f 00 00 c5 58 4f 62 03 0f 00 00 19 a3 93 ef a4 01 00 00 00 00 00 00 38 00 00 | n.php.....XOb................8.. |
1d60 | 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 44 65 73 63 72 69 70 74 | .vendor/symfony/console/Descript |
1d80 | 6f 72 2f 4d 61 72 6b 64 6f 77 6e 44 65 73 63 72 69 70 74 6f 72 2e 70 68 70 bd 13 00 00 c5 58 4f | or/MarkdownDescriptor.php.....XO |
1da0 | 62 bd 13 00 00 44 79 89 cb a4 01 00 00 00 00 00 00 34 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 | b....Dy..........4...vendor/symf |
1dc0 | 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 44 65 73 63 72 69 70 74 6f 72 2f 4a 73 6f 6e 44 65 73 63 72 | ony/console/Descriptor/JsonDescr |
1de0 | 69 70 74 6f 72 2e 70 68 70 89 13 00 00 c5 58 4f 62 89 13 00 00 74 5b ef cb a4 01 00 00 00 00 00 | iptor.php.....XOb....t[......... |
1e00 | 00 34 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 44 65 73 63 | .4...vendor/symfony/console/Desc |
1e20 | 72 69 70 74 6f 72 2f 54 65 78 74 44 65 73 63 72 69 70 74 6f 72 2e 70 68 70 96 27 00 00 c5 58 4f | riptor/TextDescriptor.php.'...XO |
1e40 | 62 96 27 00 00 82 b6 e4 f2 a4 01 00 00 00 00 00 00 30 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 | b.'..............0...vendor/symf |
1e60 | 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 44 65 73 63 72 69 70 74 6f 72 2f 44 65 73 63 72 69 70 74 6f | ony/console/Descriptor/Descripto |
1e80 | 72 2e 70 68 70 0d 0e 00 00 c5 58 4f 62 0d 0e 00 00 f5 e4 b8 ff a4 01 00 00 00 00 00 00 33 00 00 | r.php.....XOb................3.. |
1ea0 | 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 54 65 73 74 65 72 2f 41 | .vendor/symfony/console/Tester/A |
1ec0 | 70 70 6c 69 63 61 74 69 6f 6e 54 65 73 74 65 72 2e 70 68 70 0c 16 00 00 c5 58 4f 62 0c 16 00 00 | pplicationTester.php.....XOb.... |
1ee0 | 13 04 65 35 a4 01 00 00 00 00 00 00 2f 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 | ..e5......../...vendor/symfony/c |
1f00 | 6f 6e 73 6f 6c 65 2f 54 65 73 74 65 72 2f 43 6f 6d 6d 61 6e 64 54 65 73 74 65 72 2e 70 68 70 4a | onsole/Tester/CommandTester.phpJ |
1f20 | 0e 00 00 c5 58 4f 62 4a 0e 00 00 79 5a 96 9d a4 01 00 00 00 00 00 00 2f 00 00 00 76 65 6e 64 6f | ....XObJ...yZ........../...vendo |
1f40 | 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 4c 6f 67 67 65 72 2f 43 6f 6e 73 6f 6c 65 | r/symfony/console/Logger/Console |
1f60 | 4c 6f 67 67 65 72 2e 70 68 70 ea 0e 00 00 c5 58 4f 62 ea 0e 00 00 e1 fd b4 9c a4 01 00 00 00 00 | Logger.php.....XOb.............. |
1f80 | 00 00 37 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 45 78 63 | ..7...vendor/symfony/console/Exc |
1fa0 | 65 70 74 69 6f 6e 2f 45 78 63 65 70 74 69 6f 6e 49 6e 74 65 72 66 61 63 65 2e 70 68 70 96 01 00 | eption/ExceptionInterface.php... |
1fc0 | 00 c5 58 4f 62 96 01 00 00 e3 eb da 55 a4 01 00 00 00 00 00 00 33 00 00 00 76 65 6e 64 6f 72 2f | ..XOb.......U........3...vendor/ |
1fe0 | 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 45 78 63 65 70 74 69 6f 6e 2f 4c 6f 67 69 63 45 | symfony/console/Exception/LogicE |
2000 | 78 63 65 70 74 69 6f 6e 2e 70 68 70 aa 01 00 00 c5 58 4f 62 aa 01 00 00 53 4d 4c 8f a4 01 00 00 | xception.php.....XOb....SML..... |
2020 | 00 00 00 00 3d 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 45 | ....=...vendor/symfony/console/E |
2040 | 78 63 65 70 74 69 6f 6e 2f 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f | xception/InvalidArgumentExceptio |
2060 | 6e 2e 70 68 70 be 01 00 00 c5 58 4f 62 be 01 00 00 ee 75 20 69 a4 01 00 00 00 00 00 00 35 00 00 | n.php.....XOb.....u.i........5.. |
2080 | 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 45 78 63 65 70 74 69 6f | .vendor/symfony/console/Exceptio |
20a0 | 6e 2f 52 75 6e 74 69 6d 65 45 78 63 65 70 74 69 6f 6e 2e 70 68 70 ae 01 00 00 c5 58 4f 62 ae 01 | n/RuntimeException.php.....XOb.. |
20c0 | 00 00 17 b6 2a 62 a4 01 00 00 00 00 00 00 3d 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 | ....*b........=...vendor/symfony |
20e0 | 2f 63 6f 6e 73 6f 6c 65 2f 45 78 63 65 70 74 69 6f 6e 2f 43 6f 6d 6d 61 6e 64 4e 6f 74 46 6f 75 | /console/Exception/CommandNotFou |
2100 | 6e 64 45 78 63 65 70 74 69 6f 6e 2e 70 68 70 be 04 00 00 c5 58 4f 62 be 04 00 00 de f8 b5 ec a4 | ndException.php.....XOb......... |
2120 | 01 00 00 00 00 00 00 3b 00 00 00 76 65 6e 64 6f 72 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c | .......;...vendor/symfony/consol |
2140 | 65 2f 45 78 63 65 70 74 69 6f 6e 2f 49 6e 76 61 6c 69 64 4f 70 74 69 6f 6e 45 78 63 65 70 74 69 | e/Exception/InvalidOptionExcepti |
2160 | 6f 6e 2e 70 68 70 fc 01 00 00 c5 58 4f 62 fc 01 00 00 ed 93 3b 13 a4 01 00 00 00 00 00 00 13 00 | on.php.....XOb......;........... |
2180 | 00 00 76 65 6e 64 6f 72 2f 61 75 74 6f 6c 6f 61 64 2e 70 68 70 b2 00 00 00 c5 58 4f 62 b2 00 00 | ..vendor/autoload.php.....XOb... |
21a0 | 00 a7 99 38 35 a4 01 00 00 00 00 00 00 1a 00 00 00 6c 69 62 2f 43 6f 6d 6d 61 6e 64 41 70 70 6c | ...85............lib/CommandAppl |
21c0 | 69 63 61 74 69 6f 6e 2e 70 68 70 6b 08 00 00 c5 58 4f 62 6b 08 00 00 09 97 9b 3f a4 01 00 00 00 | ication.phpk....XObk......?..... |
21e0 | 00 00 00 17 00 00 00 6c 69 62 2f 55 70 64 61 74 65 45 78 63 65 70 74 69 6f 6e 2e 70 68 70 3d 04 | .......lib/UpdateException.php=. |
2200 | 00 00 c5 58 4f 62 3d 04 00 00 4a 86 11 d7 a4 01 00 00 00 00 00 00 2d 00 00 00 6c 69 62 2f 52 65 | ...XOb=...J...........-...lib/Re |
2220 | 63 75 72 73 69 76 65 44 69 72 65 63 74 6f 72 79 49 74 65 72 61 74 6f 72 57 69 74 68 6f 75 74 44 | cursiveDirectoryIteratorWithoutD |
2240 | 61 74 61 2e 70 68 70 c8 04 00 00 c5 58 4f 62 c8 04 00 00 46 77 76 31 a4 01 00 00 00 00 00 00 0f | ata.php.....XOb....Fwv1......... |
2260 | 00 00 00 6c 69 62 2f 55 70 64 61 74 65 72 2e 70 68 70 a6 86 00 00 c5 58 4f 62 a6 86 00 00 bb 9b | ...lib/Updater.php.....XOb...... |
2280 | bb f7 a4 01 00 00 00 00 00 00 0f 00 00 00 6c 69 62 2f 56 65 72 73 69 6f 6e 2e 70 68 70 6f 00 00 | ..............lib/Version.phpo.. |
22a0 | 00 c5 58 4f 62 6f 00 00 00 a6 b7 96 ab a4 01 00 00 00 00 00 00 14 00 00 00 6c 69 62 2f 4c 6f 67 | ..XObo...................lib/Log |
22c0 | 45 78 63 65 70 74 69 6f 6e 2e 70 68 70 b0 03 00 00 c5 58 4f 62 b0 03 00 00 f4 2b 9f c0 a4 01 00 | Exception.php.....XOb.....+..... |
22e0 | 00 00 00 00 00 15 00 00 00 6c 69 62 2f 55 70 64 61 74 65 43 6f 6d 6d 61 6e 64 2e 70 68 70 7f 36 | .........lib/UpdateCommand.php.6 |
2300 | 00 00 c5 58 4f 62 7f 36 00 00 b4 05 c9 1a a4 01 00 00 00 00 00 00 0b 00 00 00 76 65 72 73 69 6f | ...XOb.6..................versio |
2320 | 6e 2e 70 68 70 66 00 00 00 c5 58 4f 62 66 00 00 00 c9 b9 28 48 a4 01 00 00 00 00 00 00 31 00 00 | n.phpf....XObf.....(H........1.. |
2340 | 00 2e 62 6f 78 2f 76 65 6e 64 6f 72 2f 63 6f 6d 70 6f 73 65 72 2f 73 65 6d 76 65 72 2f 73 72 63 | ..box/vendor/composer/semver/src |
2360 | 2f 56 65 72 73 69 6f 6e 50 61 72 73 65 72 2e 70 68 70 3a 3c 00 00 c5 58 4f 62 3a 3c 00 00 bd 42 | /VersionParser.php:<...XOb:<...B |
2380 | 0b 51 a4 01 00 00 00 00 00 00 2a 00 00 00 2e 62 6f 78 2f 76 65 6e 64 6f 72 2f 63 6f 6d 70 6f 73 | .Q........*....box/vendor/compos |
23a0 | 65 72 2f 73 65 6d 76 65 72 2f 73 72 63 2f 53 65 6d 76 65 72 2e 70 68 70 2a 09 00 00 c5 58 4f 62 | er/semver/src/Semver.php*....XOb |
23c0 | 2a 09 00 00 e9 78 2c f8 a4 01 00 00 00 00 00 00 2d 00 00 00 2e 62 6f 78 2f 76 65 6e 64 6f 72 2f | *....x,.........-....box/vendor/ |
23e0 | 63 6f 6d 70 6f 73 65 72 2f 73 65 6d 76 65 72 2f 73 72 63 2f 49 6e 74 65 72 76 61 6c 73 2e 70 68 | composer/semver/src/Intervals.ph |
2400 | 70 ca 44 00 00 c5 58 4f 62 ca 44 00 00 bb 7e e0 82 a4 01 00 00 00 00 00 00 2c 00 00 00 2e 62 6f | p.D...XOb.D...~..........,....bo |
2420 | 78 2f 76 65 6e 64 6f 72 2f 63 6f 6d 70 6f 73 65 72 2f 73 65 6d 76 65 72 2f 73 72 63 2f 49 6e 74 | x/vendor/composer/semver/src/Int |
2440 | 65 72 76 61 6c 2e 70 68 70 78 05 00 00 c5 58 4f 62 78 05 00 00 4b 44 19 59 a4 01 00 00 00 00 00 | erval.phpx....XObx...KD.Y....... |
2460 | 00 3e 00 00 00 2e 62 6f 78 2f 76 65 6e 64 6f 72 2f 63 6f 6d 70 6f 73 65 72 2f 73 65 6d 76 65 72 | .>....box/vendor/composer/semver |
2480 | 2f 73 72 63 2f 43 6f 6e 73 74 72 61 69 6e 74 2f 4d 75 6c 74 69 43 6f 6e 73 74 72 61 69 6e 74 2e | /src/Constraint/MultiConstraint. |
24a0 | 70 68 70 7a 18 00 00 c5 58 4f 62 7a 18 00 00 6c 52 59 02 a4 01 00 00 00 00 00 00 42 00 00 00 2e | phpz....XObz...lRY.........B.... |
24c0 | 62 6f 78 2f 76 65 6e 64 6f 72 2f 63 6f 6d 70 6f 73 65 72 2f 73 65 6d 76 65 72 2f 73 72 63 2f 43 | box/vendor/composer/semver/src/C |
24e0 | 6f 6e 73 74 72 61 69 6e 74 2f 4d 61 74 63 68 4e 6f 6e 65 43 6f 6e 73 74 72 61 69 6e 74 2e 70 68 | onstraint/MatchNoneConstraint.ph |
2500 | 70 fd 03 00 00 c5 58 4f 62 fd 03 00 00 c5 56 2e 74 a4 01 00 00 00 00 00 00 41 00 00 00 2e 62 6f | p.....XOb.....V.t........A....bo |
2520 | 78 2f 76 65 6e 64 6f 72 2f 63 6f 6d 70 6f 73 65 72 2f 73 65 6d 76 65 72 2f 73 72 63 2f 43 6f 6e | x/vendor/composer/semver/src/Con |
2540 | 73 74 72 61 69 6e 74 2f 4d 61 74 63 68 41 6c 6c 43 6f 6e 73 74 72 61 69 6e 74 2e 70 68 70 df 03 | straint/MatchAllConstraint.php.. |
2560 | 00 00 c5 58 4f 62 df 03 00 00 95 10 29 a7 a4 01 00 00 00 00 00 00 42 00 00 00 2e 62 6f 78 2f 76 | ...XOb......).........B....box/v |
2580 | 65 6e 64 6f 72 2f 63 6f 6d 70 6f 73 65 72 2f 73 65 6d 76 65 72 2f 73 72 63 2f 43 6f 6e 73 74 72 | endor/composer/semver/src/Constr |
25a0 | 61 69 6e 74 2f 43 6f 6e 73 74 72 61 69 6e 74 49 6e 74 65 72 66 61 63 65 2e 70 68 70 b3 01 00 00 | aint/ConstraintInterface.php.... |
25c0 | c5 58 4f 62 b3 01 00 00 1d 21 4b 89 a4 01 00 00 00 00 00 00 39 00 00 00 2e 62 6f 78 2f 76 65 6e | .XOb.....!K.........9....box/ven |
25e0 | 64 6f 72 2f 63 6f 6d 70 6f 73 65 72 2f 73 65 6d 76 65 72 2f 73 72 63 2f 43 6f 6e 73 74 72 61 69 | dor/composer/semver/src/Constrai |
2600 | 6e 74 2f 43 6f 6e 73 74 72 61 69 6e 74 2e 70 68 70 f1 28 00 00 c5 58 4f 62 f1 28 00 00 96 3d 8c | nt/Constraint.php.(...XOb.(...=. |
2620 | e1 a4 01 00 00 00 00 00 00 34 00 00 00 2e 62 6f 78 2f 76 65 6e 64 6f 72 2f 63 6f 6d 70 6f 73 65 | .........4....box/vendor/compose |
2640 | 72 2f 73 65 6d 76 65 72 2f 73 72 63 2f 43 6f 6e 73 74 72 61 69 6e 74 2f 42 6f 75 6e 64 2e 70 68 | r/semver/src/Constraint/Bound.ph |
2660 | 70 ed 06 00 00 c5 58 4f 62 ed 06 00 00 24 e0 4b ac a4 01 00 00 00 00 00 00 34 00 00 00 2e 62 6f | p.....XOb....$.K.........4....bo |
2680 | 78 2f 76 65 6e 64 6f 72 2f 63 6f 6d 70 6f 73 65 72 2f 73 65 6d 76 65 72 2f 73 72 63 2f 43 6f 6d | x/vendor/composer/semver/src/Com |
26a0 | 70 69 6c 69 6e 67 4d 61 74 63 68 65 72 2e 70 68 70 d1 06 00 00 c5 58 4f 62 d1 06 00 00 65 33 b5 | pilingMatcher.php.....XOb....e3. |
26c0 | 04 a4 01 00 00 00 00 00 00 2e 00 00 00 2e 62 6f 78 2f 76 65 6e 64 6f 72 2f 63 6f 6d 70 6f 73 65 | ..............box/vendor/compose |
26e0 | 72 2f 73 65 6d 76 65 72 2f 73 72 63 2f 43 6f 6d 70 61 72 61 74 6f 72 2e 70 68 70 c9 04 00 00 c5 | r/semver/src/Comparator.php..... |
2700 | 58 4f 62 c9 04 00 00 b5 b9 21 14 a4 01 00 00 00 00 00 00 23 00 00 00 2e 62 6f 78 2f 76 65 6e 64 | XOb......!.........#....box/vend |
2720 | 6f 72 2f 63 6f 6d 70 6f 73 65 72 2f 73 65 6d 76 65 72 2f 4c 49 43 45 4e 53 45 1c 04 00 00 c5 58 | or/composer/semver/LICENSE.....X |
2740 | 4f 62 1c 04 00 00 06 42 68 ed a4 01 00 00 00 00 00 00 28 00 00 00 2e 62 6f 78 2f 76 65 6e 64 6f | Ob.....Bh.........(....box/vendo |
2760 | 72 2f 63 6f 6d 70 6f 73 65 72 2f 61 75 74 6f 6c 6f 61 64 5f 73 74 61 74 69 63 2e 70 68 70 4b 0f | r/composer/autoload_static.phpK. |
2780 | 00 00 c5 58 4f 62 4b 0f 00 00 c0 51 cb 92 a4 01 00 00 00 00 00 00 26 00 00 00 2e 62 6f 78 2f 76 | ...XObK....Q..........&....box/v |
27a0 | 65 6e 64 6f 72 2f 63 6f 6d 70 6f 73 65 72 2f 61 75 74 6f 6c 6f 61 64 5f 72 65 61 6c 2e 70 68 70 | endor/composer/autoload_real.php |
27c0 | e4 05 00 00 c5 58 4f 62 e4 05 00 00 ff f4 ab ea a4 01 00 00 00 00 00 00 26 00 00 00 2e 62 6f 78 | .....XOb................&....box |
27e0 | 2f 76 65 6e 64 6f 72 2f 63 6f 6d 70 6f 73 65 72 2f 61 75 74 6f 6c 6f 61 64 5f 70 73 72 34 2e 70 | /vendor/composer/autoload_psr4.p |
2800 | 68 70 36 01 00 00 c5 58 4f 62 36 01 00 00 3f d4 4b 9e a4 01 00 00 00 00 00 00 2c 00 00 00 2e 62 | hp6....XOb6...?.K.........,....b |
2820 | 6f 78 2f 76 65 6e 64 6f 72 2f 63 6f 6d 70 6f 73 65 72 2f 61 75 74 6f 6c 6f 61 64 5f 6e 61 6d 65 | ox/vendor/composer/autoload_name |
2840 | 73 70 61 63 65 73 2e 70 68 70 95 00 00 00 c5 58 4f 62 95 00 00 00 74 db 21 d7 a4 01 00 00 00 00 | spaces.php.....XOb....t.!....... |
2860 | 00 00 2a 00 00 00 2e 62 6f 78 2f 76 65 6e 64 6f 72 2f 63 6f 6d 70 6f 73 65 72 2f 61 75 74 6f 6c | ..*....box/vendor/composer/autol |
2880 | 6f 61 64 5f 63 6c 61 73 73 6d 61 70 2e 70 68 70 2c 0a 00 00 c5 58 4f 62 2c 0a 00 00 1c 13 d0 55 | oad_classmap.php,....XOb,......U |
28a0 | a4 01 00 00 00 00 00 00 1c 00 00 00 2e 62 6f 78 2f 76 65 6e 64 6f 72 2f 63 6f 6d 70 6f 73 65 72 | .............box/vendor/composer |
28c0 | 2f 4c 49 43 45 4e 53 45 2e 04 00 00 c5 58 4f 62 2e 04 00 00 20 d5 08 03 a4 01 00 00 00 00 00 00 | /LICENSE.....XOb................ |
28e0 | 2a 00 00 00 2e 62 6f 78 2f 76 65 6e 64 6f 72 2f 63 6f 6d 70 6f 73 65 72 2f 49 6e 73 74 61 6c 6c | *....box/vendor/composer/Install |
2900 | 65 64 56 65 72 73 69 6f 6e 73 2e 70 68 70 da 25 00 00 c5 58 4f 62 da 25 00 00 71 b2 6b e8 a4 01 | edVersions.php.%...XOb.%..q.k... |
2920 | 00 00 00 00 00 00 24 00 00 00 2e 62 6f 78 2f 76 65 6e 64 6f 72 2f 63 6f 6d 70 6f 73 65 72 2f 43 | ......$....box/vendor/composer/C |
2940 | 6c 61 73 73 4c 6f 61 64 65 72 2e 70 68 70 a3 34 00 00 c5 58 4f 62 a3 34 00 00 3f c1 54 a8 a4 01 | lassLoader.php.4...XOb.4..?.T... |
2960 | 00 00 00 00 00 00 18 00 00 00 2e 62 6f 78 2f 76 65 6e 64 6f 72 2f 61 75 74 6f 6c 6f 61 64 2e 70 | ...........box/vendor/autoload.p |
2980 | 68 70 b2 00 00 00 c5 58 4f 62 b2 00 00 00 88 5a 6d 85 a4 01 00 00 00 00 00 00 15 00 00 00 2e 62 | hp.....XOb.....Zm..............b |
29a0 | 6f 78 2f 73 72 63 2f 54 65 72 6d 69 6e 61 6c 2e 70 68 70 b8 0d 00 00 c5 58 4f 62 b8 0d 00 00 0c | ox/src/Terminal.php.....XOb..... |
29c0 | ad bf 46 a4 01 00 00 00 00 00 00 22 00 00 00 2e 62 6f 78 2f 73 72 63 2f 52 65 71 75 69 72 65 6d | ..F........"....box/src/Requirem |
29e0 | 65 6e 74 43 6f 6c 6c 65 63 74 69 6f 6e 2e 70 68 70 ef 04 00 00 c5 58 4f 62 ef 04 00 00 72 8c 7d | entCollection.php.....XOb....r.} |
2a00 | 57 a4 01 00 00 00 00 00 00 18 00 00 00 2e 62 6f 78 2f 73 72 63 2f 52 65 71 75 69 72 65 6d 65 6e | W.............box/src/Requiremen |
2a20 | 74 2e 70 68 70 6d 03 00 00 c5 58 4f 62 6d 03 00 00 a8 46 af c8 a4 01 00 00 00 00 00 00 14 00 00 | t.phpm....XObm....F............. |
2a40 | 00 2e 62 6f 78 2f 73 72 63 2f 50 72 69 6e 74 65 72 2e 70 68 70 16 0d 00 00 c5 58 4f 62 16 0d 00 | ..box/src/Printer.php.....XOb... |
2a60 | 00 ac 81 e6 5c a4 01 00 00 00 00 00 00 22 00 00 00 2e 62 6f 78 2f 73 72 63 2f 49 73 50 68 70 56 | ....\........"....box/src/IsPhpV |
2a80 | 65 72 73 69 6f 6e 46 75 6c 66 69 6c 6c 65 64 2e 70 68 70 43 02 00 00 c5 58 4f 62 43 02 00 00 6e | ersionFulfilled.phpC....XObC...n |
2aa0 | 85 2c 0b a4 01 00 00 00 00 00 00 18 00 00 00 2e 62 6f 78 2f 73 72 63 2f 49 73 46 75 6c 66 69 6c | .,..............box/src/IsFulfil |
2ac0 | 6c 65 64 2e 70 68 70 76 00 00 00 c5 58 4f 62 76 00 00 00 4c 99 e8 16 a4 01 00 00 00 00 00 00 21 | led.phpv....XObv...L...........! |
2ae0 | 00 00 00 2e 62 6f 78 2f 73 72 63 2f 49 73 45 78 74 65 6e 73 69 6f 6e 46 75 6c 66 69 6c 6c 65 64 | ....box/src/IsExtensionFulfilled |
2b00 | 2e 70 68 70 a0 01 00 00 c5 58 4f 62 a0 01 00 00 19 5a 09 e5 a4 01 00 00 00 00 00 00 0f 00 00 00 | .php.....XOb.....Z.............. |
2b20 | 2e 62 6f 78 2f 73 72 63 2f 49 4f 2e 70 68 70 20 0f 00 00 c5 58 4f 62 20 0f 00 00 3d 43 0e d0 a4 | .box/src/IO.php.....XOb....=C... |
2b40 | 01 00 00 00 00 00 00 14 00 00 00 2e 62 6f 78 2f 73 72 63 2f 43 68 65 63 6b 65 72 2e 70 68 70 8e | ............box/src/Checker.php. |
2b60 | 12 00 00 c5 58 4f 62 8e 12 00 00 fd 9b bc ac a4 01 00 00 00 00 00 00 1f 00 00 00 2e 62 6f 78 2f | ....XOb.....................box/ |
2b80 | 62 69 6e 2f 63 68 65 63 6b 2d 72 65 71 75 69 72 65 6d 65 6e 74 73 2e 70 68 70 15 02 00 00 c5 58 | bin/check-requirements.php.....X |
2ba0 | 4f 62 15 02 00 00 08 0b f0 e1 a4 01 00 00 00 00 00 00 16 00 00 00 2e 62 6f 78 2f 2e 72 65 71 75 | Ob.....................box/.requ |
2bc0 | 69 72 65 6d 65 6e 74 73 2e 70 68 70 5b 04 00 00 c5 58 4f 62 5b 04 00 00 b0 2c 66 fd a4 01 00 00 | irements.php[....XOb[....,f..... |
2be0 | 00 00 00 00 0b 00 00 00 75 70 64 61 74 65 72 2e 70 68 70 d9 00 00 00 c5 58 4f 62 d9 00 00 00 13 | ........updater.php.....XOb..... |
2c00 | 1f 93 8f a4 01 00 00 00 00 00 00 3c 3f 70 68 70 0a 0a 6e 61 6d 65 73 70 61 63 65 20 50 73 72 5c | ...........<?php..namespace.Psr\ |
2c20 | 4c 6f 67 3b 0a 0a 2f 2a 2a 0a 20 2a 20 54 68 69 73 20 69 73 20 61 20 73 69 6d 70 6c 65 20 4c 6f | Log;../**..*.This.is.a.simple.Lo |
2c40 | 67 67 65 72 20 69 6d 70 6c 65 6d 65 6e 74 61 74 69 6f 6e 20 74 68 61 74 20 6f 74 68 65 72 20 4c | gger.implementation.that.other.L |
2c60 | 6f 67 67 65 72 73 20 63 61 6e 20 69 6e 68 65 72 69 74 20 66 72 6f 6d 2e 0a 20 2a 0a 20 2a 20 49 | oggers.can.inherit.from...*..*.I |
2c80 | 74 20 73 69 6d 70 6c 79 20 64 65 6c 65 67 61 74 65 73 20 61 6c 6c 20 6c 6f 67 2d 6c 65 76 65 6c | t.simply.delegates.all.log-level |
2ca0 | 2d 73 70 65 63 69 66 69 63 20 6d 65 74 68 6f 64 73 20 74 6f 20 74 68 65 20 60 6c 6f 67 60 20 6d | -specific.methods.to.the.`log`.m |
2cc0 | 65 74 68 6f 64 20 74 6f 0a 20 2a 20 72 65 64 75 63 65 20 62 6f 69 6c 65 72 70 6c 61 74 65 20 63 | ethod.to..*.reduce.boilerplate.c |
2ce0 | 6f 64 65 20 74 68 61 74 20 61 20 73 69 6d 70 6c 65 20 4c 6f 67 67 65 72 20 74 68 61 74 20 64 6f | ode.that.a.simple.Logger.that.do |
2d00 | 65 73 20 74 68 65 20 73 61 6d 65 20 74 68 69 6e 67 20 77 69 74 68 0a 20 2a 20 6d 65 73 73 61 67 | es.the.same.thing.with..*.messag |
2d20 | 65 73 20 72 65 67 61 72 64 6c 65 73 73 20 6f 66 20 74 68 65 20 65 72 72 6f 72 20 6c 65 76 65 6c | es.regardless.of.the.error.level |
2d40 | 20 68 61 73 20 74 6f 20 69 6d 70 6c 65 6d 65 6e 74 2e 0a 20 2a 2f 0a 61 62 73 74 72 61 63 74 20 | .has.to.implement...*/.abstract. |
2d60 | 63 6c 61 73 73 20 41 62 73 74 72 61 63 74 4c 6f 67 67 65 72 20 69 6d 70 6c 65 6d 65 6e 74 73 20 | class.AbstractLogger.implements. |
2d80 | 4c 6f 67 67 65 72 49 6e 74 65 72 66 61 63 65 0a 7b 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a | LoggerInterface.{...../**......* |
2da0 | 20 53 79 73 74 65 6d 20 69 73 20 75 6e 75 73 61 62 6c 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 | .System.is.unusable.......*..... |
2dc0 | 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6d 65 73 73 61 67 65 0a 20 20 20 20 20 2a | .*.@param.string.$message......* |
2de0 | 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 20 24 63 6f 6e 74 65 78 74 0a 20 20 20 20 20 2a 0a 20 | .@param.array..$context......*.. |
2e00 | 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 76 6f 69 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 | ....*.@return.void......*/.....p |
2e20 | 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 65 6d 65 72 67 65 6e 63 79 28 24 6d 65 73 73 61 67 | ublic.function.emergency($messag |
2e40 | 65 2c 20 61 72 72 61 79 20 24 63 6f 6e 74 65 78 74 20 3d 20 61 72 72 61 79 28 29 29 0a 20 20 20 | e,.array.$context.=.array()).... |
2e60 | 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6c 6f 67 28 4c 6f 67 4c 65 76 65 6c 3a 3a | .{.........$this->log(LogLevel:: |
2e80 | 45 4d 45 52 47 45 4e 43 59 2c 20 24 6d 65 73 73 61 67 65 2c 20 24 63 6f 6e 74 65 78 74 29 3b 0a | EMERGENCY,.$message,.$context);. |
2ea0 | 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 41 63 74 69 6f 6e 20 6d 75 73 | ....}....../**......*.Action.mus |
2ec0 | 74 20 62 65 20 74 61 6b 65 6e 20 69 6d 6d 65 64 69 61 74 65 6c 79 2e 0a 20 20 20 20 20 2a 0a 20 | t.be.taken.immediately.......*.. |
2ee0 | 20 20 20 20 2a 20 45 78 61 6d 70 6c 65 3a 20 45 6e 74 69 72 65 20 77 65 62 73 69 74 65 20 64 6f | ....*.Example:.Entire.website.do |
2f00 | 77 6e 2c 20 64 61 74 61 62 61 73 65 20 75 6e 61 76 61 69 6c 61 62 6c 65 2c 20 65 74 63 2e 20 54 | wn,.database.unavailable,.etc..T |
2f20 | 68 69 73 20 73 68 6f 75 6c 64 0a 20 20 20 20 20 2a 20 74 72 69 67 67 65 72 20 74 68 65 20 53 4d | his.should......*.trigger.the.SM |
2f40 | 53 20 61 6c 65 72 74 73 20 61 6e 64 20 77 61 6b 65 20 79 6f 75 20 75 70 2e 0a 20 20 20 20 20 2a | S.alerts.and.wake.you.up.......* |
2f60 | 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6d 65 73 73 61 67 65 0a 20 | ......*.@param.string.$message.. |
2f80 | 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 20 24 63 6f 6e 74 65 78 74 0a 20 20 20 | ....*.@param.array..$context.... |
2fa0 | 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 76 6f 69 64 0a 20 20 20 20 20 2a 2f 0a | ..*......*.@return.void......*/. |
2fc0 | 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 61 6c 65 72 74 28 24 6d 65 73 73 61 | ....public.function.alert($messa |
2fe0 | 67 65 2c 20 61 72 72 61 79 20 24 63 6f 6e 74 65 78 74 20 3d 20 61 72 72 61 79 28 29 29 0a 20 20 | ge,.array.$context.=.array())... |
3000 | 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6c 6f 67 28 4c 6f 67 4c 65 76 65 6c 3a | ..{.........$this->log(LogLevel: |
3020 | 3a 41 4c 45 52 54 2c 20 24 6d 65 73 73 61 67 65 2c 20 24 63 6f 6e 74 65 78 74 29 3b 0a 20 20 20 | :ALERT,.$message,.$context);.... |
3040 | 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 43 72 69 74 69 63 61 6c 20 63 6f 6e 64 | .}....../**......*.Critical.cond |
3060 | 69 74 69 6f 6e 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 45 78 61 6d 70 6c 65 3a 20 41 | itions.......*......*.Example:.A |
3080 | 70 70 6c 69 63 61 74 69 6f 6e 20 63 6f 6d 70 6f 6e 65 6e 74 20 75 6e 61 76 61 69 6c 61 62 6c 65 | pplication.component.unavailable |
30a0 | 2c 20 75 6e 65 78 70 65 63 74 65 64 20 65 78 63 65 70 74 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 | ,.unexpected.exception.......*.. |
30c0 | 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6d 65 73 73 61 67 65 0a 20 20 20 | ....*.@param.string.$message.... |
30e0 | 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 20 24 63 6f 6e 74 65 78 74 0a 20 20 20 20 20 | ..*.@param.array..$context...... |
3100 | 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 76 6f 69 64 0a 20 20 20 20 20 2a 2f 0a 20 20 | *......*.@return.void......*/... |
3120 | 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 63 72 69 74 69 63 61 6c 28 24 6d 65 73 73 | ..public.function.critical($mess |
3140 | 61 67 65 2c 20 61 72 72 61 79 20 24 63 6f 6e 74 65 78 74 20 3d 20 61 72 72 61 79 28 29 29 0a 20 | age,.array.$context.=.array()).. |
3160 | 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6c 6f 67 28 4c 6f 67 4c 65 76 65 6c | ...{.........$this->log(LogLevel |
3180 | 3a 3a 43 52 49 54 49 43 41 4c 2c 20 24 6d 65 73 73 61 67 65 2c 20 24 63 6f 6e 74 65 78 74 29 3b | ::CRITICAL,.$message,.$context); |
31a0 | 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 75 6e 74 69 6d 65 20 65 | .....}....../**......*.Runtime.e |
31c0 | 72 72 6f 72 73 20 74 68 61 74 20 64 6f 20 6e 6f 74 20 72 65 71 75 69 72 65 20 69 6d 6d 65 64 69 | rrors.that.do.not.require.immedi |
31e0 | 61 74 65 20 61 63 74 69 6f 6e 20 62 75 74 20 73 68 6f 75 6c 64 20 74 79 70 69 63 61 6c 6c 79 0a | ate.action.but.should.typically. |
3200 | 20 20 20 20 20 2a 20 62 65 20 6c 6f 67 67 65 64 20 61 6e 64 20 6d 6f 6e 69 74 6f 72 65 64 2e 0a | .....*.be.logged.and.monitored.. |
3220 | 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6d 65 73 | .....*......*.@param.string.$mes |
3240 | 73 61 67 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 20 24 63 6f 6e 74 65 | sage......*.@param.array..$conte |
3260 | 78 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 76 6f 69 64 0a 20 20 | xt......*......*.@return.void... |
3280 | 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 65 72 72 6f 72 28 | ...*/.....public.function.error( |
32a0 | 24 6d 65 73 73 61 67 65 2c 20 61 72 72 61 79 20 24 63 6f 6e 74 65 78 74 20 3d 20 61 72 72 61 79 | $message,.array.$context.=.array |
32c0 | 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6c 6f 67 28 4c 6f 67 | ()).....{.........$this->log(Log |
32e0 | 4c 65 76 65 6c 3a 3a 45 52 52 4f 52 2c 20 24 6d 65 73 73 61 67 65 2c 20 24 63 6f 6e 74 65 78 74 | Level::ERROR,.$message,.$context |
3300 | 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 45 78 63 65 70 74 69 | );.....}....../**......*.Excepti |
3320 | 6f 6e 61 6c 20 6f 63 63 75 72 72 65 6e 63 65 73 20 74 68 61 74 20 61 72 65 20 6e 6f 74 20 65 72 | onal.occurrences.that.are.not.er |
3340 | 72 6f 72 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 45 78 61 6d 70 6c 65 3a 20 55 73 65 | rors.......*......*.Example:.Use |
3360 | 20 6f 66 20 64 65 70 72 65 63 61 74 65 64 20 41 50 49 73 2c 20 70 6f 6f 72 20 75 73 65 20 6f 66 | .of.deprecated.APIs,.poor.use.of |
3380 | 20 61 6e 20 41 50 49 2c 20 75 6e 64 65 73 69 72 61 62 6c 65 20 74 68 69 6e 67 73 0a 20 20 20 20 | .an.API,.undesirable.things..... |
33a0 | 20 2a 20 74 68 61 74 20 61 72 65 20 6e 6f 74 20 6e 65 63 65 73 73 61 72 69 6c 79 20 77 72 6f 6e | .*.that.are.not.necessarily.wron |
33c0 | 67 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 | g.......*......*.@param.string.$ |
33e0 | 6d 65 73 73 61 67 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 20 24 63 6f | message......*.@param.array..$co |
3400 | 6e 74 65 78 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 76 6f 69 64 | ntext......*......*.@return.void |
3420 | 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 77 61 72 | ......*/.....public.function.war |
3440 | 6e 69 6e 67 28 24 6d 65 73 73 61 67 65 2c 20 61 72 72 61 79 20 24 63 6f 6e 74 65 78 74 20 3d 20 | ning($message,.array.$context.=. |
3460 | 61 72 72 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6c 6f | array()).....{.........$this->lo |
3480 | 67 28 4c 6f 67 4c 65 76 65 6c 3a 3a 57 41 52 4e 49 4e 47 2c 20 24 6d 65 73 73 61 67 65 2c 20 24 | g(LogLevel::WARNING,.$message,.$ |
34a0 | 63 6f 6e 74 65 78 74 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 | context);.....}....../**......*. |
34c0 | 4e 6f 72 6d 61 6c 20 62 75 74 20 73 69 67 6e 69 66 69 63 61 6e 74 20 65 76 65 6e 74 73 2e 0a 20 | Normal.but.significant.events... |
34e0 | 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6d 65 73 73 | ....*......*.@param.string.$mess |
3500 | 61 67 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 20 24 63 6f 6e 74 65 78 | age......*.@param.array..$contex |
3520 | 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 76 6f 69 64 0a 20 20 20 | t......*......*.@return.void.... |
3540 | 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 6e 6f 74 69 63 65 28 | ..*/.....public.function.notice( |
3560 | 24 6d 65 73 73 61 67 65 2c 20 61 72 72 61 79 20 24 63 6f 6e 74 65 78 74 20 3d 20 61 72 72 61 79 | $message,.array.$context.=.array |
3580 | 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6c 6f 67 28 4c 6f 67 | ()).....{.........$this->log(Log |
35a0 | 4c 65 76 65 6c 3a 3a 4e 4f 54 49 43 45 2c 20 24 6d 65 73 73 61 67 65 2c 20 24 63 6f 6e 74 65 78 | Level::NOTICE,.$message,.$contex |
35c0 | 74 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 49 6e 74 65 72 65 | t);.....}....../**......*.Intere |
35e0 | 73 74 69 6e 67 20 65 76 65 6e 74 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 45 78 61 6d | sting.events.......*......*.Exam |
3600 | 70 6c 65 3a 20 55 73 65 72 20 6c 6f 67 73 20 69 6e 2c 20 53 51 4c 20 6c 6f 67 73 2e 0a 20 20 20 | ple:.User.logs.in,.SQL.logs..... |
3620 | 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6d 65 73 73 61 67 | ..*......*.@param.string.$messag |
3640 | 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 20 24 63 6f 6e 74 65 78 74 0a | e......*.@param.array..$context. |
3660 | 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 76 6f 69 64 0a 20 20 20 20 20 | .....*......*.@return.void...... |
3680 | 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 69 6e 66 6f 28 24 6d 65 73 | */.....public.function.info($mes |
36a0 | 73 61 67 65 2c 20 61 72 72 61 79 20 24 63 6f 6e 74 65 78 74 20 3d 20 61 72 72 61 79 28 29 29 0a | sage,.array.$context.=.array()). |
36c0 | 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6c 6f 67 28 4c 6f 67 4c 65 76 65 | ....{.........$this->log(LogLeve |
36e0 | 6c 3a 3a 49 4e 46 4f 2c 20 24 6d 65 73 73 61 67 65 2c 20 24 63 6f 6e 74 65 78 74 29 3b 0a 20 20 | l::INFO,.$message,.$context);... |
3700 | 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 44 65 74 61 69 6c 65 64 20 64 65 62 | ..}....../**......*.Detailed.deb |
3720 | 75 67 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 | ug.information.......*......*.@p |
3740 | 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6d 65 73 73 61 67 65 0a 20 20 20 20 20 2a 20 40 70 61 72 | aram.string.$message......*.@par |
3760 | 61 6d 20 61 72 72 61 79 20 20 24 63 6f 6e 74 65 78 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a | am.array..$context......*......* |
3780 | 20 40 72 65 74 75 72 6e 20 76 6f 69 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 | .@return.void......*/.....public |
37a0 | 20 66 75 6e 63 74 69 6f 6e 20 64 65 62 75 67 28 24 6d 65 73 73 61 67 65 2c 20 61 72 72 61 79 20 | .function.debug($message,.array. |
37c0 | 24 63 6f 6e 74 65 78 74 20 3d 20 61 72 72 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 | $context.=.array()).....{....... |
37e0 | 20 20 24 74 68 69 73 2d 3e 6c 6f 67 28 4c 6f 67 4c 65 76 65 6c 3a 3a 44 45 42 55 47 2c 20 24 6d | ..$this->log(LogLevel::DEBUG,.$m |
3800 | 65 73 73 61 67 65 2c 20 24 63 6f 6e 74 65 78 74 29 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 | essage,.$context);.....}.}.<?php |
3820 | 0a 0a 6e 61 6d 65 73 70 61 63 65 20 50 73 72 5c 4c 6f 67 3b 0a 0a 2f 2a 2a 0a 20 2a 20 42 61 73 | ..namespace.Psr\Log;../**..*.Bas |
3840 | 69 63 20 49 6d 70 6c 65 6d 65 6e 74 61 74 69 6f 6e 20 6f 66 20 4c 6f 67 67 65 72 41 77 61 72 65 | ic.Implementation.of.LoggerAware |
3860 | 49 6e 74 65 72 66 61 63 65 2e 0a 20 2a 2f 0a 74 72 61 69 74 20 4c 6f 67 67 65 72 41 77 61 72 65 | Interface...*/.trait.LoggerAware |
3880 | 54 72 61 69 74 0a 7b 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 54 68 65 20 6c 6f 67 67 65 | Trait.{...../**......*.The.logge |
38a0 | 72 20 69 6e 73 74 61 6e 63 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 76 61 72 20 4c | r.instance.......*......*.@var.L |
38c0 | 6f 67 67 65 72 49 6e 74 65 72 66 61 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 6f 74 65 | oggerInterface......*/.....prote |
38e0 | 63 74 65 64 20 24 6c 6f 67 67 65 72 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 | cted.$logger;....../**......*.Se |
3900 | 74 73 20 61 20 6c 6f 67 67 65 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 | ts.a.logger.......*......*.@para |
3920 | 6d 20 4c 6f 67 67 65 72 49 6e 74 65 72 66 61 63 65 20 24 6c 6f 67 67 65 72 0a 20 20 20 20 20 2a | m.LoggerInterface.$logger......* |
3940 | 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 4c 6f 67 67 65 72 28 | /.....public.function.setLogger( |
3960 | 4c 6f 67 67 65 72 49 6e 74 65 72 66 61 63 65 20 24 6c 6f 67 67 65 72 29 0a 20 20 20 20 7b 0a 20 | LoggerInterface.$logger).....{.. |
3980 | 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6c 6f 67 67 65 72 20 3d 20 24 6c 6f 67 67 65 72 3b 0a | .......$this->logger.=.$logger;. |
39a0 | 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 6e 61 6d 65 73 70 61 63 65 20 50 73 72 5c 4c 6f 67 | ....}.}.<?php..namespace.Psr\Log |
39c0 | 3b 0a 0a 2f 2a 2a 0a 20 2a 20 54 68 69 73 20 69 73 20 61 20 73 69 6d 70 6c 65 20 4c 6f 67 67 65 | ;../**..*.This.is.a.simple.Logge |
39e0 | 72 20 74 72 61 69 74 20 74 68 61 74 20 63 6c 61 73 73 65 73 20 75 6e 61 62 6c 65 20 74 6f 20 65 | r.trait.that.classes.unable.to.e |
3a00 | 78 74 65 6e 64 20 41 62 73 74 72 61 63 74 4c 6f 67 67 65 72 0a 20 2a 20 28 62 65 63 61 75 73 65 | xtend.AbstractLogger..*.(because |
3a20 | 20 74 68 65 79 20 65 78 74 65 6e 64 20 61 6e 6f 74 68 65 72 20 63 6c 61 73 73 2c 20 65 74 63 29 | .they.extend.another.class,.etc) |
3a40 | 20 63 61 6e 20 69 6e 63 6c 75 64 65 2e 0a 20 2a 0a 20 2a 20 49 74 20 73 69 6d 70 6c 79 20 64 65 | .can.include...*..*.It.simply.de |
3a60 | 6c 65 67 61 74 65 73 20 61 6c 6c 20 6c 6f 67 2d 6c 65 76 65 6c 2d 73 70 65 63 69 66 69 63 20 6d | legates.all.log-level-specific.m |
3a80 | 65 74 68 6f 64 73 20 74 6f 20 74 68 65 20 60 6c 6f 67 60 20 6d 65 74 68 6f 64 20 74 6f 0a 20 2a | ethods.to.the.`log`.method.to..* |
3aa0 | 20 72 65 64 75 63 65 20 62 6f 69 6c 65 72 70 6c 61 74 65 20 63 6f 64 65 20 74 68 61 74 20 61 20 | .reduce.boilerplate.code.that.a. |
3ac0 | 73 69 6d 70 6c 65 20 4c 6f 67 67 65 72 20 74 68 61 74 20 64 6f 65 73 20 74 68 65 20 73 61 6d 65 | simple.Logger.that.does.the.same |
3ae0 | 20 74 68 69 6e 67 20 77 69 74 68 0a 20 2a 20 6d 65 73 73 61 67 65 73 20 72 65 67 61 72 64 6c 65 | .thing.with..*.messages.regardle |
3b00 | 73 73 20 6f 66 20 74 68 65 20 65 72 72 6f 72 20 6c 65 76 65 6c 20 68 61 73 20 74 6f 20 69 6d 70 | ss.of.the.error.level.has.to.imp |
3b20 | 6c 65 6d 65 6e 74 2e 0a 20 2a 2f 0a 74 72 61 69 74 20 4c 6f 67 67 65 72 54 72 61 69 74 0a 7b 0a | lement...*/.trait.LoggerTrait.{. |
3b40 | 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 79 73 74 65 6d 20 69 73 20 75 6e 75 73 61 62 6c | ..../**......*.System.is.unusabl |
3b60 | 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 | e.......*......*.@param.string.$ |
3b80 | 6d 65 73 73 61 67 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 20 24 63 6f | message......*.@param.array..$co |
3ba0 | 6e 74 65 78 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 76 6f 69 64 | ntext......*......*.@return.void |
3bc0 | 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 65 6d 65 | ......*/.....public.function.eme |
3be0 | 72 67 65 6e 63 79 28 24 6d 65 73 73 61 67 65 2c 20 61 72 72 61 79 20 24 63 6f 6e 74 65 78 74 20 | rgency($message,.array.$context. |
3c00 | 3d 20 61 72 72 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e | =.array()).....{.........$this-> |
3c20 | 6c 6f 67 28 4c 6f 67 4c 65 76 65 6c 3a 3a 45 4d 45 52 47 45 4e 43 59 2c 20 24 6d 65 73 73 61 67 | log(LogLevel::EMERGENCY,.$messag |
3c40 | 65 2c 20 24 63 6f 6e 74 65 78 74 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 | e,.$context);.....}....../**.... |
3c60 | 20 20 2a 20 41 63 74 69 6f 6e 20 6d 75 73 74 20 62 65 20 74 61 6b 65 6e 20 69 6d 6d 65 64 69 61 | ..*.Action.must.be.taken.immedia |
3c80 | 74 65 6c 79 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 45 78 61 6d 70 6c 65 3a 20 45 6e 74 | tely.......*......*.Example:.Ent |
3ca0 | 69 72 65 20 77 65 62 73 69 74 65 20 64 6f 77 6e 2c 20 64 61 74 61 62 61 73 65 20 75 6e 61 76 61 | ire.website.down,.database.unava |
3cc0 | 69 6c 61 62 6c 65 2c 20 65 74 63 2e 20 54 68 69 73 20 73 68 6f 75 6c 64 0a 20 20 20 20 20 2a 20 | ilable,.etc..This.should......*. |
3ce0 | 74 72 69 67 67 65 72 20 74 68 65 20 53 4d 53 20 61 6c 65 72 74 73 20 61 6e 64 20 77 61 6b 65 20 | trigger.the.SMS.alerts.and.wake. |
3d00 | 79 6f 75 20 75 70 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 | you.up.......*......*.@param.str |
3d20 | 69 6e 67 20 24 6d 65 73 73 61 67 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 | ing.$message......*.@param.array |
3d40 | 20 20 24 63 6f 6e 74 65 78 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e | ..$context......*......*.@return |
3d60 | 20 76 6f 69 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f | .void......*/.....public.functio |
3d80 | 6e 20 61 6c 65 72 74 28 24 6d 65 73 73 61 67 65 2c 20 61 72 72 61 79 20 24 63 6f 6e 74 65 78 74 | n.alert($message,.array.$context |
3da0 | 20 3d 20 61 72 72 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d | .=.array()).....{.........$this- |
3dc0 | 3e 6c 6f 67 28 4c 6f 67 4c 65 76 65 6c 3a 3a 41 4c 45 52 54 2c 20 24 6d 65 73 73 61 67 65 2c 20 | >log(LogLevel::ALERT,.$message,. |
3de0 | 24 63 6f 6e 74 65 78 74 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a | $context);.....}....../**......* |
3e00 | 20 43 72 69 74 69 63 61 6c 20 63 6f 6e 64 69 74 69 6f 6e 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 | .Critical.conditions.......*.... |
3e20 | 20 20 2a 20 45 78 61 6d 70 6c 65 3a 20 41 70 70 6c 69 63 61 74 69 6f 6e 20 63 6f 6d 70 6f 6e 65 | ..*.Example:.Application.compone |
3e40 | 6e 74 20 75 6e 61 76 61 69 6c 61 62 6c 65 2c 20 75 6e 65 78 70 65 63 74 65 64 20 65 78 63 65 70 | nt.unavailable,.unexpected.excep |
3e60 | 74 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e | tion.......*......*.@param.strin |
3e80 | 67 20 24 6d 65 73 73 61 67 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 20 | g.$message......*.@param.array.. |
3ea0 | 24 63 6f 6e 74 65 78 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 76 | $context......*......*.@return.v |
3ec0 | 6f 69 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 | oid......*/.....public.function. |
3ee0 | 63 72 69 74 69 63 61 6c 28 24 6d 65 73 73 61 67 65 2c 20 61 72 72 61 79 20 24 63 6f 6e 74 65 78 | critical($message,.array.$contex |
3f00 | 74 20 3d 20 61 72 72 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 | t.=.array()).....{.........$this |
3f20 | 2d 3e 6c 6f 67 28 4c 6f 67 4c 65 76 65 6c 3a 3a 43 52 49 54 49 43 41 4c 2c 20 24 6d 65 73 73 61 | ->log(LogLevel::CRITICAL,.$messa |
3f40 | 67 65 2c 20 24 63 6f 6e 74 65 78 74 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 | ge,.$context);.....}....../**... |
3f60 | 20 20 20 2a 20 52 75 6e 74 69 6d 65 20 65 72 72 6f 72 73 20 74 68 61 74 20 64 6f 20 6e 6f 74 20 | ...*.Runtime.errors.that.do.not. |
3f80 | 72 65 71 75 69 72 65 20 69 6d 6d 65 64 69 61 74 65 20 61 63 74 69 6f 6e 20 62 75 74 20 73 68 6f | require.immediate.action.but.sho |
3fa0 | 75 6c 64 20 74 79 70 69 63 61 6c 6c 79 0a 20 20 20 20 20 2a 20 62 65 20 6c 6f 67 67 65 64 20 61 | uld.typically......*.be.logged.a |
3fc0 | 6e 64 20 6d 6f 6e 69 74 6f 72 65 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 | nd.monitored.......*......*.@par |
3fe0 | 61 6d 20 73 74 72 69 6e 67 20 24 6d 65 73 73 61 67 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d | am.string.$message......*.@param |
4000 | 20 61 72 72 61 79 20 20 24 63 6f 6e 74 65 78 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 | .array..$context......*......*.@ |
4020 | 72 65 74 75 72 6e 20 76 6f 69 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 | return.void......*/.....public.f |
4040 | 75 6e 63 74 69 6f 6e 20 65 72 72 6f 72 28 24 6d 65 73 73 61 67 65 2c 20 61 72 72 61 79 20 24 63 | unction.error($message,.array.$c |
4060 | 6f 6e 74 65 78 74 20 3d 20 61 72 72 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | ontext.=.array()).....{......... |
4080 | 24 74 68 69 73 2d 3e 6c 6f 67 28 4c 6f 67 4c 65 76 65 6c 3a 3a 45 52 52 4f 52 2c 20 24 6d 65 73 | $this->log(LogLevel::ERROR,.$mes |
40a0 | 73 61 67 65 2c 20 24 63 6f 6e 74 65 78 74 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a | sage,.$context);.....}....../**. |
40c0 | 20 20 20 20 20 2a 20 45 78 63 65 70 74 69 6f 6e 61 6c 20 6f 63 63 75 72 72 65 6e 63 65 73 20 74 | .....*.Exceptional.occurrences.t |
40e0 | 68 61 74 20 61 72 65 20 6e 6f 74 20 65 72 72 6f 72 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 | hat.are.not.errors.......*...... |
4100 | 2a 20 45 78 61 6d 70 6c 65 3a 20 55 73 65 20 6f 66 20 64 65 70 72 65 63 61 74 65 64 20 41 50 49 | *.Example:.Use.of.deprecated.API |
4120 | 73 2c 20 70 6f 6f 72 20 75 73 65 20 6f 66 20 61 6e 20 41 50 49 2c 20 75 6e 64 65 73 69 72 61 62 | s,.poor.use.of.an.API,.undesirab |
4140 | 6c 65 20 74 68 69 6e 67 73 0a 20 20 20 20 20 2a 20 74 68 61 74 20 61 72 65 20 6e 6f 74 20 6e 65 | le.things......*.that.are.not.ne |
4160 | 63 65 73 73 61 72 69 6c 79 20 77 72 6f 6e 67 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 | cessarily.wrong.......*......*.@ |
4180 | 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6d 65 73 73 61 67 65 0a 20 20 20 20 20 2a 20 40 70 61 | param.string.$message......*.@pa |
41a0 | 72 61 6d 20 61 72 72 61 79 20 20 24 63 6f 6e 74 65 78 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 | ram.array..$context......*...... |
41c0 | 2a 20 40 72 65 74 75 72 6e 20 76 6f 69 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 | *.@return.void......*/.....publi |
41e0 | 63 20 66 75 6e 63 74 69 6f 6e 20 77 61 72 6e 69 6e 67 28 24 6d 65 73 73 61 67 65 2c 20 61 72 72 | c.function.warning($message,.arr |
4200 | 61 79 20 24 63 6f 6e 74 65 78 74 20 3d 20 61 72 72 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 | ay.$context.=.array()).....{.... |
4220 | 20 20 20 20 20 24 74 68 69 73 2d 3e 6c 6f 67 28 4c 6f 67 4c 65 76 65 6c 3a 3a 57 41 52 4e 49 4e | .....$this->log(LogLevel::WARNIN |
4240 | 47 2c 20 24 6d 65 73 73 61 67 65 2c 20 24 63 6f 6e 74 65 78 74 29 3b 0a 20 20 20 20 7d 0a 0a 20 | G,.$message,.$context);.....}... |
4260 | 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 4e 6f 72 6d 61 6c 20 62 75 74 20 73 69 67 6e 69 66 69 | .../**......*.Normal.but.signifi |
4280 | 63 61 6e 74 20 65 76 65 6e 74 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 | cant.events.......*......*.@para |
42a0 | 6d 20 73 74 72 69 6e 67 20 24 6d 65 73 73 61 67 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 | m.string.$message......*.@param. |
42c0 | 61 72 72 61 79 20 20 24 63 6f 6e 74 65 78 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 | array..$context......*......*.@r |
42e0 | 65 74 75 72 6e 20 76 6f 69 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 | eturn.void......*/.....public.fu |
4300 | 6e 63 74 69 6f 6e 20 6e 6f 74 69 63 65 28 24 6d 65 73 73 61 67 65 2c 20 61 72 72 61 79 20 24 63 | nction.notice($message,.array.$c |
4320 | 6f 6e 74 65 78 74 20 3d 20 61 72 72 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | ontext.=.array()).....{......... |
4340 | 24 74 68 69 73 2d 3e 6c 6f 67 28 4c 6f 67 4c 65 76 65 6c 3a 3a 4e 4f 54 49 43 45 2c 20 24 6d 65 | $this->log(LogLevel::NOTICE,.$me |
4360 | 73 73 61 67 65 2c 20 24 63 6f 6e 74 65 78 74 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a | ssage,.$context);.....}....../** |
4380 | 0a 20 20 20 20 20 2a 20 49 6e 74 65 72 65 73 74 69 6e 67 20 65 76 65 6e 74 73 2e 0a 20 20 20 20 | ......*.Interesting.events...... |
43a0 | 20 2a 0a 20 20 20 20 20 2a 20 45 78 61 6d 70 6c 65 3a 20 55 73 65 72 20 6c 6f 67 73 20 69 6e 2c | .*......*.Example:.User.logs.in, |
43c0 | 20 53 51 4c 20 6c 6f 67 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 | .SQL.logs.......*......*.@param. |
43e0 | 73 74 72 69 6e 67 20 24 6d 65 73 73 61 67 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 | string.$message......*.@param.ar |
4400 | 72 61 79 20 20 24 63 6f 6e 74 65 78 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 | ray..$context......*......*.@ret |
4420 | 75 72 6e 20 76 6f 69 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 | urn.void......*/.....public.func |
4440 | 74 69 6f 6e 20 69 6e 66 6f 28 24 6d 65 73 73 61 67 65 2c 20 61 72 72 61 79 20 24 63 6f 6e 74 65 | tion.info($message,.array.$conte |
4460 | 78 74 20 3d 20 61 72 72 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 | xt.=.array()).....{.........$thi |
4480 | 73 2d 3e 6c 6f 67 28 4c 6f 67 4c 65 76 65 6c 3a 3a 49 4e 46 4f 2c 20 24 6d 65 73 73 61 67 65 2c | s->log(LogLevel::INFO,.$message, |
44a0 | 20 24 63 6f 6e 74 65 78 74 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 | .$context);.....}....../**...... |
44c0 | 2a 20 44 65 74 61 69 6c 65 64 20 64 65 62 75 67 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2e 0a 20 20 | *.Detailed.debug.information.... |
44e0 | 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6d 65 73 73 61 | ...*......*.@param.string.$messa |
4500 | 67 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 20 24 63 6f 6e 74 65 78 74 | ge......*.@param.array..$context |
4520 | 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 76 6f 69 64 0a 20 20 20 20 | ......*......*.@return.void..... |
4540 | 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 64 65 62 75 67 28 24 6d | .*/.....public.function.debug($m |
4560 | 65 73 73 61 67 65 2c 20 61 72 72 61 79 20 24 63 6f 6e 74 65 78 74 20 3d 20 61 72 72 61 79 28 29 | essage,.array.$context.=.array() |
4580 | 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6c 6f 67 28 4c 6f 67 4c 65 | ).....{.........$this->log(LogLe |
45a0 | 76 65 6c 3a 3a 44 45 42 55 47 2c 20 24 6d 65 73 73 61 67 65 2c 20 24 63 6f 6e 74 65 78 74 29 3b | vel::DEBUG,.$message,.$context); |
45c0 | 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 4c 6f 67 73 20 77 69 74 68 | .....}....../**......*.Logs.with |
45e0 | 20 61 6e 20 61 72 62 69 74 72 61 72 79 20 6c 65 76 65 6c 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 | .an.arbitrary.level.......*..... |
4600 | 20 2a 20 40 70 61 72 61 6d 20 6d 69 78 65 64 20 20 24 6c 65 76 65 6c 0a 20 20 20 20 20 2a 20 40 | .*.@param.mixed..$level......*.@ |
4620 | 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6d 65 73 73 61 67 65 0a 20 20 20 20 20 2a 20 40 70 61 | param.string.$message......*.@pa |
4640 | 72 61 6d 20 61 72 72 61 79 20 20 24 63 6f 6e 74 65 78 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 | ram.array..$context......*...... |
4660 | 2a 20 40 72 65 74 75 72 6e 20 76 6f 69 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 61 62 73 74 72 | *.@return.void......*/.....abstr |
4680 | 61 63 74 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 6c 6f 67 28 24 6c 65 76 65 6c 2c 20 | act.public.function.log($level,. |
46a0 | 24 6d 65 73 73 61 67 65 2c 20 61 72 72 61 79 20 24 63 6f 6e 74 65 78 74 20 3d 20 61 72 72 61 79 | $message,.array.$context.=.array |
46c0 | 28 29 29 3b 0a 7d 0a 3c 3f 70 68 70 0a 0a 6e 61 6d 65 73 70 61 63 65 20 50 73 72 5c 4c 6f 67 3b | ());.}.<?php..namespace.Psr\Log; |
46e0 | 0a 0a 63 6c 61 73 73 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e | ..class.InvalidArgumentException |
4700 | 20 65 78 74 65 6e 64 73 20 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 | .extends.\InvalidArgumentExcepti |
4720 | 6f 6e 0a 7b 0a 7d 0a 3c 3f 70 68 70 0a 0a 6e 61 6d 65 73 70 61 63 65 20 50 73 72 5c 4c 6f 67 3b | on.{.}.<?php..namespace.Psr\Log; |
4740 | 0a 0a 2f 2a 2a 0a 20 2a 20 44 65 73 63 72 69 62 65 73 20 61 20 6c 6f 67 67 65 72 2d 61 77 61 72 | ../**..*.Describes.a.logger-awar |
4760 | 65 20 69 6e 73 74 61 6e 63 65 2e 0a 20 2a 2f 0a 69 6e 74 65 72 66 61 63 65 20 4c 6f 67 67 65 72 | e.instance...*/.interface.Logger |
4780 | 41 77 61 72 65 49 6e 74 65 72 66 61 63 65 0a 7b 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 | AwareInterface.{...../**......*. |
47a0 | 53 65 74 73 20 61 20 6c 6f 67 67 65 72 20 69 6e 73 74 61 6e 63 65 20 6f 6e 20 74 68 65 20 6f 62 | Sets.a.logger.instance.on.the.ob |
47c0 | 6a 65 63 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 4c 6f 67 67 65 | ject.......*......*.@param.Logge |
47e0 | 72 49 6e 74 65 72 66 61 63 65 20 24 6c 6f 67 67 65 72 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a | rInterface.$logger......*......* |
4800 | 20 40 72 65 74 75 72 6e 20 76 6f 69 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 | .@return.void......*/.....public |
4820 | 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 4c 6f 67 67 65 72 28 4c 6f 67 67 65 72 49 6e 74 65 72 66 | .function.setLogger(LoggerInterf |
4840 | 61 63 65 20 24 6c 6f 67 67 65 72 29 3b 0a 7d 0a 3c 3f 70 68 70 0a 0a 6e 61 6d 65 73 70 61 63 65 | ace.$logger);.}.<?php..namespace |
4860 | 20 50 73 72 5c 4c 6f 67 5c 54 65 73 74 3b 0a 0a 75 73 65 20 50 73 72 5c 4c 6f 67 5c 4c 6f 67 67 | .Psr\Log\Test;..use.Psr\Log\Logg |
4880 | 65 72 49 6e 74 65 72 66 61 63 65 3b 0a 75 73 65 20 50 73 72 5c 4c 6f 67 5c 4c 6f 67 4c 65 76 65 | erInterface;.use.Psr\Log\LogLeve |
48a0 | 6c 3b 0a 0a 2f 2a 2a 0a 20 2a 20 50 72 6f 76 69 64 65 73 20 61 20 62 61 73 65 20 74 65 73 74 20 | l;../**..*.Provides.a.base.test. |
48c0 | 63 6c 61 73 73 20 66 6f 72 20 65 6e 73 75 72 69 6e 67 20 63 6f 6d 70 6c 69 61 6e 63 65 20 77 69 | class.for.ensuring.compliance.wi |
48e0 | 74 68 20 74 68 65 20 4c 6f 67 67 65 72 49 6e 74 65 72 66 61 63 65 2e 0a 20 2a 0a 20 2a 20 49 6d | th.the.LoggerInterface...*..*.Im |
4900 | 70 6c 65 6d 65 6e 74 6f 72 73 20 63 61 6e 20 65 78 74 65 6e 64 20 74 68 65 20 63 6c 61 73 73 20 | plementors.can.extend.the.class. |
4920 | 61 6e 64 20 69 6d 70 6c 65 6d 65 6e 74 20 61 62 73 74 72 61 63 74 20 6d 65 74 68 6f 64 73 20 74 | and.implement.abstract.methods.t |
4940 | 6f 20 72 75 6e 20 74 68 69 73 0a 20 2a 20 61 73 20 70 61 72 74 20 6f 66 20 74 68 65 69 72 20 74 | o.run.this..*.as.part.of.their.t |
4960 | 65 73 74 20 73 75 69 74 65 2e 0a 20 2a 2f 0a 61 62 73 74 72 61 63 74 20 63 6c 61 73 73 20 4c 6f | est.suite...*/.abstract.class.Lo |
4980 | 67 67 65 72 49 6e 74 65 72 66 61 63 65 54 65 73 74 20 65 78 74 65 6e 64 73 20 5c 50 48 50 55 6e | ggerInterfaceTest.extends.\PHPUn |
49a0 | 69 74 5f 46 72 61 6d 65 77 6f 72 6b 5f 54 65 73 74 43 61 73 65 0a 7b 0a 20 20 20 20 2f 2a 2a 0a | it_Framework_TestCase.{...../**. |
49c0 | 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 4c 6f 67 67 65 72 49 6e 74 65 72 66 61 63 65 0a 20 | .....*.@return.LoggerInterface.. |
49e0 | 20 20 20 20 2a 2f 0a 20 20 20 20 61 62 73 74 72 61 63 74 20 70 75 62 6c 69 63 20 66 75 6e 63 74 | ....*/.....abstract.public.funct |
4a00 | 69 6f 6e 20 67 65 74 4c 6f 67 67 65 72 28 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a | ion.getLogger();....../**......* |
4a20 | 20 54 68 69 73 20 6d 75 73 74 20 72 65 74 75 72 6e 20 74 68 65 20 6c 6f 67 20 6d 65 73 73 61 67 | .This.must.return.the.log.messag |
4a40 | 65 73 20 69 6e 20 6f 72 64 65 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 54 68 65 20 73 | es.in.order.......*......*.The.s |
4a60 | 69 6d 70 6c 65 20 66 6f 72 6d 61 74 74 69 6e 67 20 6f 66 20 74 68 65 20 6d 65 73 73 61 67 65 73 | imple.formatting.of.the.messages |
4a80 | 20 69 73 3a 20 22 3c 4c 4f 47 20 4c 45 56 45 4c 3e 20 3c 4d 45 53 53 41 47 45 3e 22 2e 0a 20 20 | .is:."<LOG.LEVEL>.<MESSAGE>".... |
4aa0 | 20 20 20 2a 0a 20 20 20 20 20 2a 20 45 78 61 6d 70 6c 65 20 2d 3e 65 72 72 6f 72 28 27 46 6f 6f | ...*......*.Example.->error('Foo |
4ac0 | 27 29 20 77 6f 75 6c 64 20 79 69 65 6c 64 20 22 65 72 72 6f 72 20 46 6f 6f 22 2e 0a 20 20 20 20 | ').would.yield."error.Foo"...... |
4ae0 | 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 5b 5d 0a 20 20 20 20 20 | .*......*.@return.string[]...... |
4b00 | 2a 2f 0a 20 20 20 20 61 62 73 74 72 61 63 74 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 | */.....abstract.public.function. |
4b20 | 67 65 74 4c 6f 67 73 28 29 3b 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 | getLogs();......public.function. |
4b40 | 74 65 73 74 49 6d 70 6c 65 6d 65 6e 74 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 | testImplements().....{.........$ |
4b60 | 74 68 69 73 2d 3e 61 73 73 65 72 74 49 6e 73 74 61 6e 63 65 4f 66 28 27 50 73 72 5c 4c 6f 67 5c | this->assertInstanceOf('Psr\Log\ |
4b80 | 4c 6f 67 67 65 72 49 6e 74 65 72 66 61 63 65 27 2c 20 24 74 68 69 73 2d 3e 67 65 74 4c 6f 67 67 | LoggerInterface',.$this->getLogg |
4ba0 | 65 72 28 29 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 64 61 | er());.....}....../**......*.@da |
4bc0 | 74 61 50 72 6f 76 69 64 65 72 20 70 72 6f 76 69 64 65 4c 65 76 65 6c 73 41 6e 64 4d 65 73 73 61 | taProvider.provideLevelsAndMessa |
4be0 | 67 65 73 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 | ges......*/.....public.function. |
4c00 | 74 65 73 74 4c 6f 67 73 41 74 41 6c 6c 4c 65 76 65 6c 73 28 24 6c 65 76 65 6c 2c 20 24 6d 65 73 | testLogsAtAllLevels($level,.$mes |
4c20 | 73 61 67 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 6c 6f 67 67 65 72 20 3d 20 24 74 | sage).....{.........$logger.=.$t |
4c40 | 68 69 73 2d 3e 67 65 74 4c 6f 67 67 65 72 28 29 3b 0a 20 20 20 20 20 20 20 20 24 6c 6f 67 67 65 | his->getLogger();.........$logge |
4c60 | 72 2d 3e 7b 24 6c 65 76 65 6c 7d 28 24 6d 65 73 73 61 67 65 2c 20 61 72 72 61 79 28 27 75 73 65 | r->{$level}($message,.array('use |
4c80 | 72 27 20 3d 3e 20 27 42 6f 62 27 29 29 3b 0a 20 20 20 20 20 20 20 20 24 6c 6f 67 67 65 72 2d 3e | r'.=>.'Bob'));.........$logger-> |
4ca0 | 6c 6f 67 28 24 6c 65 76 65 6c 2c 20 24 6d 65 73 73 61 67 65 2c 20 61 72 72 61 79 28 27 75 73 65 | log($level,.$message,.array('use |
4cc0 | 72 27 20 3d 3e 20 27 42 6f 62 27 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 65 78 70 65 63 74 65 | r'.=>.'Bob'));..........$expecte |
4ce0 | 64 20 3d 20 61 72 72 61 79 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 65 76 65 6c 2e 27 20 | d.=.array(.............$level.'. |
4d00 | 6d 65 73 73 61 67 65 20 6f 66 20 6c 65 76 65 6c 20 27 2e 24 6c 65 76 65 6c 2e 27 20 77 69 74 68 | message.of.level.'.$level.'.with |
4d20 | 20 63 6f 6e 74 65 78 74 3a 20 42 6f 62 27 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 65 76 | .context:.Bob',.............$lev |
4d40 | 65 6c 2e 27 20 6d 65 73 73 61 67 65 20 6f 66 20 6c 65 76 65 6c 20 27 2e 24 6c 65 76 65 6c 2e 27 | el.'.message.of.level.'.$level.' |
4d60 | 20 77 69 74 68 20 63 6f 6e 74 65 78 74 3a 20 42 6f 62 27 2c 0a 20 20 20 20 20 20 20 20 29 3b 0a | .with.context:.Bob',.........);. |
4d80 | 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 61 73 73 65 72 74 45 71 75 61 6c 73 28 24 65 78 70 | ........$this->assertEquals($exp |
4da0 | 65 63 74 65 64 2c 20 24 74 68 69 73 2d 3e 67 65 74 4c 6f 67 73 28 29 29 3b 0a 20 20 20 20 7d 0a | ected,.$this->getLogs());.....}. |
4dc0 | 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 70 72 6f 76 69 64 65 4c 65 76 65 | .....public.function.provideLeve |
4de0 | 6c 73 41 6e 64 4d 65 73 73 61 67 65 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 | lsAndMessages().....{.........re |
4e00 | 74 75 72 6e 20 61 72 72 61 79 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 4c 6f 67 4c 65 76 65 6c | turn.array(.............LogLevel |
4e20 | 3a 3a 45 4d 45 52 47 45 4e 43 59 20 3d 3e 20 61 72 72 61 79 28 4c 6f 67 4c 65 76 65 6c 3a 3a 45 | ::EMERGENCY.=>.array(LogLevel::E |
4e40 | 4d 45 52 47 45 4e 43 59 2c 20 27 6d 65 73 73 61 67 65 20 6f 66 20 6c 65 76 65 6c 20 65 6d 65 72 | MERGENCY,.'message.of.level.emer |
4e60 | 67 65 6e 63 79 20 77 69 74 68 20 63 6f 6e 74 65 78 74 3a 20 7b 75 73 65 72 7d 27 29 2c 0a 20 20 | gency.with.context:.{user}'),... |
4e80 | 20 20 20 20 20 20 20 20 20 20 4c 6f 67 4c 65 76 65 6c 3a 3a 41 4c 45 52 54 20 3d 3e 20 61 72 72 | ..........LogLevel::ALERT.=>.arr |
4ea0 | 61 79 28 4c 6f 67 4c 65 76 65 6c 3a 3a 41 4c 45 52 54 2c 20 27 6d 65 73 73 61 67 65 20 6f 66 20 | ay(LogLevel::ALERT,.'message.of. |
4ec0 | 6c 65 76 65 6c 20 61 6c 65 72 74 20 77 69 74 68 20 63 6f 6e 74 65 78 74 3a 20 7b 75 73 65 72 7d | level.alert.with.context:.{user} |
4ee0 | 27 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 4c 6f 67 4c 65 76 65 6c 3a 3a 43 52 49 54 49 43 | '),.............LogLevel::CRITIC |
4f00 | 41 4c 20 3d 3e 20 61 72 72 61 79 28 4c 6f 67 4c 65 76 65 6c 3a 3a 43 52 49 54 49 43 41 4c 2c 20 | AL.=>.array(LogLevel::CRITICAL,. |
4f20 | 27 6d 65 73 73 61 67 65 20 6f 66 20 6c 65 76 65 6c 20 63 72 69 74 69 63 61 6c 20 77 69 74 68 20 | 'message.of.level.critical.with. |
4f40 | 63 6f 6e 74 65 78 74 3a 20 7b 75 73 65 72 7d 27 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 4c | context:.{user}'),.............L |
4f60 | 6f 67 4c 65 76 65 6c 3a 3a 45 52 52 4f 52 20 3d 3e 20 61 72 72 61 79 28 4c 6f 67 4c 65 76 65 6c | ogLevel::ERROR.=>.array(LogLevel |
4f80 | 3a 3a 45 52 52 4f 52 2c 20 27 6d 65 73 73 61 67 65 20 6f 66 20 6c 65 76 65 6c 20 65 72 72 6f 72 | ::ERROR,.'message.of.level.error |
4fa0 | 20 77 69 74 68 20 63 6f 6e 74 65 78 74 3a 20 7b 75 73 65 72 7d 27 29 2c 0a 20 20 20 20 20 20 20 | .with.context:.{user}'),........ |
4fc0 | 20 20 20 20 20 4c 6f 67 4c 65 76 65 6c 3a 3a 57 41 52 4e 49 4e 47 20 3d 3e 20 61 72 72 61 79 28 | .....LogLevel::WARNING.=>.array( |
4fe0 | 4c 6f 67 4c 65 76 65 6c 3a 3a 57 41 52 4e 49 4e 47 2c 20 27 6d 65 73 73 61 67 65 20 6f 66 20 6c | LogLevel::WARNING,.'message.of.l |
5000 | 65 76 65 6c 20 77 61 72 6e 69 6e 67 20 77 69 74 68 20 63 6f 6e 74 65 78 74 3a 20 7b 75 73 65 72 | evel.warning.with.context:.{user |
5020 | 7d 27 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 4c 6f 67 4c 65 76 65 6c 3a 3a 4e 4f 54 49 43 | }'),.............LogLevel::NOTIC |
5040 | 45 20 3d 3e 20 61 72 72 61 79 28 4c 6f 67 4c 65 76 65 6c 3a 3a 4e 4f 54 49 43 45 2c 20 27 6d 65 | E.=>.array(LogLevel::NOTICE,.'me |
5060 | 73 73 61 67 65 20 6f 66 20 6c 65 76 65 6c 20 6e 6f 74 69 63 65 20 77 69 74 68 20 63 6f 6e 74 65 | ssage.of.level.notice.with.conte |
5080 | 78 74 3a 20 7b 75 73 65 72 7d 27 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 4c 6f 67 4c 65 76 | xt:.{user}'),.............LogLev |
50a0 | 65 6c 3a 3a 49 4e 46 4f 20 3d 3e 20 61 72 72 61 79 28 4c 6f 67 4c 65 76 65 6c 3a 3a 49 4e 46 4f | el::INFO.=>.array(LogLevel::INFO |
50c0 | 2c 20 27 6d 65 73 73 61 67 65 20 6f 66 20 6c 65 76 65 6c 20 69 6e 66 6f 20 77 69 74 68 20 63 6f | ,.'message.of.level.info.with.co |
50e0 | 6e 74 65 78 74 3a 20 7b 75 73 65 72 7d 27 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 4c 6f 67 | ntext:.{user}'),.............Log |
5100 | 4c 65 76 65 6c 3a 3a 44 45 42 55 47 20 3d 3e 20 61 72 72 61 79 28 4c 6f 67 4c 65 76 65 6c 3a 3a | Level::DEBUG.=>.array(LogLevel:: |
5120 | 44 45 42 55 47 2c 20 27 6d 65 73 73 61 67 65 20 6f 66 20 6c 65 76 65 6c 20 64 65 62 75 67 20 77 | DEBUG,.'message.of.level.debug.w |
5140 | 69 74 68 20 63 6f 6e 74 65 78 74 3a 20 7b 75 73 65 72 7d 27 29 2c 0a 20 20 20 20 20 20 20 20 29 | ith.context:.{user}'),.........) |
5160 | 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 65 78 70 65 63 74 65 | ;.....}....../**......*.@expecte |
5180 | 64 45 78 63 65 70 74 69 6f 6e 20 5c 50 73 72 5c 4c 6f 67 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d | dException.\Psr\Log\InvalidArgum |
51a0 | 65 6e 74 45 78 63 65 70 74 69 6f 6e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 | entException......*/.....public. |
51c0 | 66 75 6e 63 74 69 6f 6e 20 74 65 73 74 54 68 72 6f 77 73 4f 6e 49 6e 76 61 6c 69 64 4c 65 76 65 | function.testThrowsOnInvalidLeve |
51e0 | 6c 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 6c 6f 67 67 65 72 20 3d 20 24 74 68 69 | l().....{.........$logger.=.$thi |
5200 | 73 2d 3e 67 65 74 4c 6f 67 67 65 72 28 29 3b 0a 20 20 20 20 20 20 20 20 24 6c 6f 67 67 65 72 2d | s->getLogger();.........$logger- |
5220 | 3e 6c 6f 67 28 27 69 6e 76 61 6c 69 64 20 6c 65 76 65 6c 27 2c 20 27 46 6f 6f 27 29 3b 0a 20 20 | >log('invalid.level',.'Foo');... |
5240 | 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 74 65 73 74 43 6f 6e | ..}......public.function.testCon |
5260 | 74 65 78 74 52 65 70 6c 61 63 65 6d 65 6e 74 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | textReplacement().....{......... |
5280 | 24 6c 6f 67 67 65 72 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 4c 6f 67 67 65 72 28 29 3b 0a 20 20 | $logger.=.$this->getLogger();... |
52a0 | 20 20 20 20 20 20 24 6c 6f 67 67 65 72 2d 3e 69 6e 66 6f 28 27 7b 4d 65 73 73 61 67 65 20 7b 6e | ......$logger->info('{Message.{n |
52c0 | 6f 74 68 69 6e 67 7d 20 7b 75 73 65 72 7d 20 7b 66 6f 6f 2e 62 61 72 7d 20 61 7d 27 2c 20 61 72 | othing}.{user}.{foo.bar}.a}',.ar |
52e0 | 72 61 79 28 27 75 73 65 72 27 20 3d 3e 20 27 42 6f 62 27 2c 20 27 66 6f 6f 2e 62 61 72 27 20 3d | ray('user'.=>.'Bob',.'foo.bar'.= |
5300 | 3e 20 27 42 61 72 27 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 65 78 70 65 63 74 65 64 20 3d 20 | >.'Bar'));..........$expected.=. |
5320 | 61 72 72 61 79 28 27 69 6e 66 6f 20 7b 4d 65 73 73 61 67 65 20 7b 6e 6f 74 68 69 6e 67 7d 20 42 | array('info.{Message.{nothing}.B |
5340 | 6f 62 20 42 61 72 20 61 7d 27 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 61 73 73 65 | ob.Bar.a}');.........$this->asse |
5360 | 72 74 45 71 75 61 6c 73 28 24 65 78 70 65 63 74 65 64 2c 20 24 74 68 69 73 2d 3e 67 65 74 4c 6f | rtEquals($expected,.$this->getLo |
5380 | 67 73 28 29 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f | gs());.....}......public.functio |
53a0 | 6e 20 74 65 73 74 4f 62 6a 65 63 74 43 61 73 74 54 6f 53 74 72 69 6e 67 28 29 0a 20 20 20 20 7b | n.testObjectCastToString().....{ |
53c0 | 0a 20 20 20 20 20 20 20 20 69 66 20 28 6d 65 74 68 6f 64 5f 65 78 69 73 74 73 28 24 74 68 69 73 | .........if.(method_exists($this |
53e0 | 2c 20 27 63 72 65 61 74 65 50 61 72 74 69 61 6c 4d 6f 63 6b 27 29 29 20 7b 0a 20 20 20 20 20 20 | ,.'createPartialMock')).{....... |
5400 | 20 20 20 20 20 20 24 64 75 6d 6d 79 20 3d 20 24 74 68 69 73 2d 3e 63 72 65 61 74 65 50 61 72 74 | ......$dummy.=.$this->createPart |
5420 | 69 61 6c 4d 6f 63 6b 28 27 50 73 72 5c 4c 6f 67 5c 54 65 73 74 5c 44 75 6d 6d 79 54 65 73 74 27 | ialMock('Psr\Log\Test\DummyTest' |
5440 | 2c 20 61 72 72 61 79 28 27 5f 5f 74 6f 53 74 72 69 6e 67 27 29 29 3b 0a 20 20 20 20 20 20 20 20 | ,.array('__toString'));......... |
5460 | 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 64 75 6d 6d 79 20 3d 20 24 74 | }.else.{.............$dummy.=.$t |
5480 | 68 69 73 2d 3e 67 65 74 4d 6f 63 6b 28 27 50 73 72 5c 4c 6f 67 5c 54 65 73 74 5c 44 75 6d 6d 79 | his->getMock('Psr\Log\Test\Dummy |
54a0 | 54 65 73 74 27 2c 20 61 72 72 61 79 28 27 5f 5f 74 6f 53 74 72 69 6e 67 27 29 29 3b 0a 20 20 20 | Test',.array('__toString'));.... |
54c0 | 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 24 64 75 6d 6d 79 2d 3e 65 78 70 65 63 74 73 28 24 | .....}.........$dummy->expects($ |
54e0 | 74 68 69 73 2d 3e 6f 6e 63 65 28 29 29 0a 20 20 20 20 20 20 20 20 20 20 20 20 2d 3e 6d 65 74 68 | this->once()).............->meth |
5500 | 6f 64 28 27 5f 5f 74 6f 53 74 72 69 6e 67 27 29 0a 20 20 20 20 20 20 20 20 20 20 20 20 2d 3e 77 | od('__toString').............->w |
5520 | 69 6c 6c 28 24 74 68 69 73 2d 3e 72 65 74 75 72 6e 56 61 6c 75 65 28 27 44 55 4d 4d 59 27 29 29 | ill($this->returnValue('DUMMY')) |
5540 | 3b 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 67 65 74 4c 6f 67 67 65 72 28 29 2d 3e 77 | ;..........$this->getLogger()->w |
5560 | 61 72 6e 69 6e 67 28 24 64 75 6d 6d 79 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 65 78 70 65 63 74 | arning($dummy);..........$expect |
5580 | 65 64 20 3d 20 61 72 72 61 79 28 27 77 61 72 6e 69 6e 67 20 44 55 4d 4d 59 27 29 3b 0a 20 20 20 | ed.=.array('warning.DUMMY');.... |
55a0 | 20 20 20 20 20 24 74 68 69 73 2d 3e 61 73 73 65 72 74 45 71 75 61 6c 73 28 24 65 78 70 65 63 74 | .....$this->assertEquals($expect |
55c0 | 65 64 2c 20 24 74 68 69 73 2d 3e 67 65 74 4c 6f 67 73 28 29 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 | ed,.$this->getLogs());.....}.... |
55e0 | 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 74 65 73 74 43 6f 6e 74 65 78 74 43 61 6e | ..public.function.testContextCan |
5600 | 43 6f 6e 74 61 69 6e 41 6e 79 74 68 69 6e 67 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | ContainAnything().....{......... |
5620 | 24 63 6f 6e 74 65 78 74 20 3d 20 61 72 72 61 79 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 62 | $context.=.array(.............'b |
5640 | 6f 6f 6c 27 20 3d 3e 20 74 72 75 65 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 6e 75 6c 6c 27 | ool'.=>.true,.............'null' |
5660 | 20 3d 3e 20 6e 75 6c 6c 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 73 74 72 69 6e 67 27 20 3d | .=>.null,.............'string'.= |
5680 | 3e 20 27 46 6f 6f 27 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 69 6e 74 27 20 3d 3e 20 30 2c | >.'Foo',.............'int'.=>.0, |
56a0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 66 6c 6f 61 74 27 20 3d 3e 20 30 2e 35 2c 0a 20 20 20 | .............'float'.=>.0.5,.... |
56c0 | 20 20 20 20 20 20 20 20 20 27 6e 65 73 74 65 64 27 20 3d 3e 20 61 72 72 61 79 28 27 77 69 74 68 | .........'nested'.=>.array('with |
56e0 | 20 6f 62 6a 65 63 74 27 20 3d 3e 20 6e 65 77 20 44 75 6d 6d 79 54 65 73 74 29 2c 0a 20 20 20 20 | .object'.=>.new.DummyTest),..... |
5700 | 20 20 20 20 20 20 20 20 27 6f 62 6a 65 63 74 27 20 3d 3e 20 6e 65 77 20 5c 44 61 74 65 54 69 6d | ........'object'.=>.new.\DateTim |
5720 | 65 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 72 65 73 6f 75 72 63 65 27 20 3d 3e 20 66 6f 70 | e,.............'resource'.=>.fop |
5740 | 65 6e 28 27 70 68 70 3a 2f 2f 6d 65 6d 6f 72 79 27 2c 20 27 72 27 29 2c 0a 20 20 20 20 20 20 20 | en('php://memory',.'r'),........ |
5760 | 20 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 67 65 74 4c 6f 67 67 65 72 28 29 2d | .);..........$this->getLogger()- |
5780 | 3e 77 61 72 6e 69 6e 67 28 27 43 72 61 7a 79 20 63 6f 6e 74 65 78 74 20 64 61 74 61 27 2c 20 24 | >warning('Crazy.context.data',.$ |
57a0 | 63 6f 6e 74 65 78 74 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 65 78 70 65 63 74 65 64 20 3d 20 61 | context);..........$expected.=.a |
57c0 | 72 72 61 79 28 27 77 61 72 6e 69 6e 67 20 43 72 61 7a 79 20 63 6f 6e 74 65 78 74 20 64 61 74 61 | rray('warning.Crazy.context.data |
57e0 | 27 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 61 73 73 65 72 74 45 71 75 61 6c 73 28 | ');.........$this->assertEquals( |
5800 | 24 65 78 70 65 63 74 65 64 2c 20 24 74 68 69 73 2d 3e 67 65 74 4c 6f 67 73 28 29 29 3b 0a 20 20 | $expected,.$this->getLogs());... |
5820 | 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 74 65 73 74 43 6f 6e | ..}......public.function.testCon |
5840 | 74 65 78 74 45 78 63 65 70 74 69 6f 6e 4b 65 79 43 61 6e 42 65 45 78 63 65 70 74 69 6f 6e 4f 72 | textExceptionKeyCanBeExceptionOr |
5860 | 4f 74 68 65 72 56 61 6c 75 65 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 6c 6f 67 | OtherValues().....{.........$log |
5880 | 67 65 72 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 4c 6f 67 67 65 72 28 29 3b 0a 20 20 20 20 20 20 | ger.=.$this->getLogger();....... |
58a0 | 20 20 24 6c 6f 67 67 65 72 2d 3e 77 61 72 6e 69 6e 67 28 27 52 61 6e 64 6f 6d 20 6d 65 73 73 61 | ..$logger->warning('Random.messa |
58c0 | 67 65 27 2c 20 61 72 72 61 79 28 27 65 78 63 65 70 74 69 6f 6e 27 20 3d 3e 20 27 6f 6f 70 73 27 | ge',.array('exception'.=>.'oops' |
58e0 | 29 29 3b 0a 20 20 20 20 20 20 20 20 24 6c 6f 67 67 65 72 2d 3e 63 72 69 74 69 63 61 6c 28 27 55 | ));.........$logger->critical('U |
5900 | 6e 63 61 75 67 68 74 20 45 78 63 65 70 74 69 6f 6e 21 27 2c 20 61 72 72 61 79 28 27 65 78 63 65 | ncaught.Exception!',.array('exce |
5920 | 70 74 69 6f 6e 27 20 3d 3e 20 6e 65 77 20 5c 4c 6f 67 69 63 45 78 63 65 70 74 69 6f 6e 28 27 46 | ption'.=>.new.\LogicException('F |
5940 | 61 69 6c 27 29 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 65 78 70 65 63 74 65 64 20 3d 20 61 72 | ail')));..........$expected.=.ar |
5960 | 72 61 79 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 77 61 72 6e 69 6e 67 20 52 61 6e 64 6f 6d | ray(.............'warning.Random |
5980 | 20 6d 65 73 73 61 67 65 27 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 63 72 69 74 69 63 61 6c | .message',.............'critical |
59a0 | 20 55 6e 63 61 75 67 68 74 20 45 78 63 65 70 74 69 6f 6e 21 27 0a 20 20 20 20 20 20 20 20 29 3b | .Uncaught.Exception!'.........); |
59c0 | 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 61 73 73 65 72 74 45 71 75 61 6c 73 28 24 65 78 | .........$this->assertEquals($ex |
59e0 | 70 65 63 74 65 64 2c 20 24 74 68 69 73 2d 3e 67 65 74 4c 6f 67 73 28 29 29 3b 0a 20 20 20 20 7d | pected,.$this->getLogs());.....} |
5a00 | 0a 7d 0a 0a 63 6c 61 73 73 20 44 75 6d 6d 79 54 65 73 74 0a 7b 0a 20 20 20 20 70 75 62 6c 69 63 | .}..class.DummyTest.{.....public |
5a20 | 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 74 6f 53 74 72 69 6e 67 28 29 0a 20 20 20 20 7b 0a 20 20 20 | .function.__toString().....{.... |
5a40 | 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 6e 61 6d 65 73 70 61 63 65 20 50 73 72 5c 4c 6f 67 3b 0a 0a | .}.}.<?php..namespace.Psr\Log;.. |
5a60 | 2f 2a 2a 0a 20 2a 20 44 65 73 63 72 69 62 65 73 20 6c 6f 67 20 6c 65 76 65 6c 73 2e 0a 20 2a 2f | /**..*.Describes.log.levels...*/ |
5a80 | 0a 63 6c 61 73 73 20 4c 6f 67 4c 65 76 65 6c 0a 7b 0a 20 20 20 20 63 6f 6e 73 74 20 45 4d 45 52 | .class.LogLevel.{.....const.EMER |
5aa0 | 47 45 4e 43 59 20 3d 20 27 65 6d 65 72 67 65 6e 63 79 27 3b 0a 20 20 20 20 63 6f 6e 73 74 20 41 | GENCY.=.'emergency';.....const.A |
5ac0 | 4c 45 52 54 20 20 20 20 20 3d 20 27 61 6c 65 72 74 27 3b 0a 20 20 20 20 63 6f 6e 73 74 20 43 52 | LERT.....=.'alert';.....const.CR |
5ae0 | 49 54 49 43 41 4c 20 20 3d 20 27 63 72 69 74 69 63 61 6c 27 3b 0a 20 20 20 20 63 6f 6e 73 74 20 | ITICAL..=.'critical';.....const. |
5b00 | 45 52 52 4f 52 20 20 20 20 20 3d 20 27 65 72 72 6f 72 27 3b 0a 20 20 20 20 63 6f 6e 73 74 20 57 | ERROR.....=.'error';.....const.W |
5b20 | 41 52 4e 49 4e 47 20 20 20 3d 20 27 77 61 72 6e 69 6e 67 27 3b 0a 20 20 20 20 63 6f 6e 73 74 20 | ARNING...=.'warning';.....const. |
5b40 | 4e 4f 54 49 43 45 20 20 20 20 3d 20 27 6e 6f 74 69 63 65 27 3b 0a 20 20 20 20 63 6f 6e 73 74 20 | NOTICE....=.'notice';.....const. |
5b60 | 49 4e 46 4f 20 20 20 20 20 20 3d 20 27 69 6e 66 6f 27 3b 0a 20 20 20 20 63 6f 6e 73 74 20 44 45 | INFO......=.'info';.....const.DE |
5b80 | 42 55 47 20 20 20 20 20 3d 20 27 64 65 62 75 67 27 3b 0a 7d 0a 3c 3f 70 68 70 0a 0a 6e 61 6d 65 | BUG.....=.'debug';.}.<?php..name |
5ba0 | 73 70 61 63 65 20 50 73 72 5c 4c 6f 67 3b 0a 0a 2f 2a 2a 0a 20 2a 20 54 68 69 73 20 4c 6f 67 67 | space.Psr\Log;../**..*.This.Logg |
5bc0 | 65 72 20 63 61 6e 20 62 65 20 75 73 65 64 20 74 6f 20 61 76 6f 69 64 20 63 6f 6e 64 69 74 69 6f | er.can.be.used.to.avoid.conditio |
5be0 | 6e 61 6c 20 6c 6f 67 20 63 61 6c 6c 73 2e 0a 20 2a 0a 20 2a 20 4c 6f 67 67 69 6e 67 20 73 68 6f | nal.log.calls...*..*.Logging.sho |
5c00 | 75 6c 64 20 61 6c 77 61 79 73 20 62 65 20 6f 70 74 69 6f 6e 61 6c 2c 20 61 6e 64 20 69 66 20 6e | uld.always.be.optional,.and.if.n |
5c20 | 6f 20 6c 6f 67 67 65 72 20 69 73 20 70 72 6f 76 69 64 65 64 20 74 6f 20 79 6f 75 72 0a 20 2a 20 | o.logger.is.provided.to.your..*. |
5c40 | 6c 69 62 72 61 72 79 20 63 72 65 61 74 69 6e 67 20 61 20 4e 75 6c 6c 4c 6f 67 67 65 72 20 69 6e | library.creating.a.NullLogger.in |
5c60 | 73 74 61 6e 63 65 20 74 6f 20 68 61 76 65 20 73 6f 6d 65 74 68 69 6e 67 20 74 6f 20 74 68 72 6f | stance.to.have.something.to.thro |
5c80 | 77 20 6c 6f 67 73 20 61 74 0a 20 2a 20 69 73 20 61 20 67 6f 6f 64 20 77 61 79 20 74 6f 20 61 76 | w.logs.at..*.is.a.good.way.to.av |
5ca0 | 6f 69 64 20 6c 69 74 74 65 72 69 6e 67 20 79 6f 75 72 20 63 6f 64 65 20 77 69 74 68 20 60 69 66 | oid.littering.your.code.with.`if |
5cc0 | 20 28 24 74 68 69 73 2d 3e 6c 6f 67 67 65 72 29 20 7b 20 7d 60 0a 20 2a 20 62 6c 6f 63 6b 73 2e | .($this->logger).{.}`..*.blocks. |
5ce0 | 0a 20 2a 2f 0a 63 6c 61 73 73 20 4e 75 6c 6c 4c 6f 67 67 65 72 20 65 78 74 65 6e 64 73 20 41 62 | ..*/.class.NullLogger.extends.Ab |
5d00 | 73 74 72 61 63 74 4c 6f 67 67 65 72 0a 7b 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 4c 6f | stractLogger.{...../**......*.Lo |
5d20 | 67 73 20 77 69 74 68 20 61 6e 20 61 72 62 69 74 72 61 72 79 20 6c 65 76 65 6c 2e 0a 20 20 20 20 | gs.with.an.arbitrary.level...... |
5d40 | 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 6d 69 78 65 64 20 20 24 6c 65 76 65 6c 0a 20 | .*......*.@param.mixed..$level.. |
5d60 | 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6d 65 73 73 61 67 65 0a 20 20 20 | ....*.@param.string.$message.... |
5d80 | 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 20 24 63 6f 6e 74 65 78 74 0a 20 20 20 20 20 | ..*.@param.array..$context...... |
5da0 | 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 76 6f 69 64 0a 20 20 20 20 20 2a 2f 0a 20 20 | *......*.@return.void......*/... |
5dc0 | 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 6c 6f 67 28 24 6c 65 76 65 6c 2c 20 24 6d | ..public.function.log($level,.$m |
5de0 | 65 73 73 61 67 65 2c 20 61 72 72 61 79 20 24 63 6f 6e 74 65 78 74 20 3d 20 61 72 72 61 79 28 29 | essage,.array.$context.=.array() |
5e00 | 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 2f 2f 20 6e 6f 6f 70 0a 20 20 20 20 7d 0a 7d 0a | ).....{.........//.noop.....}.}. |
5e20 | 3c 3f 70 68 70 0a 0a 6e 61 6d 65 73 70 61 63 65 20 50 73 72 5c 4c 6f 67 3b 0a 0a 2f 2a 2a 0a 20 | <?php..namespace.Psr\Log;../**.. |
5e40 | 2a 20 44 65 73 63 72 69 62 65 73 20 61 20 6c 6f 67 67 65 72 20 69 6e 73 74 61 6e 63 65 2e 0a 20 | *.Describes.a.logger.instance... |
5e60 | 2a 0a 20 2a 20 54 68 65 20 6d 65 73 73 61 67 65 20 4d 55 53 54 20 62 65 20 61 20 73 74 72 69 6e | *..*.The.message.MUST.be.a.strin |
5e80 | 67 20 6f 72 20 6f 62 6a 65 63 74 20 69 6d 70 6c 65 6d 65 6e 74 69 6e 67 20 5f 5f 74 6f 53 74 72 | g.or.object.implementing.__toStr |
5ea0 | 69 6e 67 28 29 2e 0a 20 2a 0a 20 2a 20 54 68 65 20 6d 65 73 73 61 67 65 20 4d 41 59 20 63 6f 6e | ing()...*..*.The.message.MAY.con |
5ec0 | 74 61 69 6e 20 70 6c 61 63 65 68 6f 6c 64 65 72 73 20 69 6e 20 74 68 65 20 66 6f 72 6d 3a 20 7b | tain.placeholders.in.the.form:.{ |
5ee0 | 66 6f 6f 7d 20 77 68 65 72 65 20 66 6f 6f 0a 20 2a 20 77 69 6c 6c 20 62 65 20 72 65 70 6c 61 63 | foo}.where.foo..*.will.be.replac |
5f00 | 65 64 20 62 79 20 74 68 65 20 63 6f 6e 74 65 78 74 20 64 61 74 61 20 69 6e 20 6b 65 79 20 22 66 | ed.by.the.context.data.in.key."f |
5f20 | 6f 6f 22 2e 0a 20 2a 0a 20 2a 20 54 68 65 20 63 6f 6e 74 65 78 74 20 61 72 72 61 79 20 63 61 6e | oo"...*..*.The.context.array.can |
5f40 | 20 63 6f 6e 74 61 69 6e 20 61 72 62 69 74 72 61 72 79 20 64 61 74 61 2e 20 54 68 65 20 6f 6e 6c | .contain.arbitrary.data..The.onl |
5f60 | 79 20 61 73 73 75 6d 70 74 69 6f 6e 20 74 68 61 74 0a 20 2a 20 63 61 6e 20 62 65 20 6d 61 64 65 | y.assumption.that..*.can.be.made |
5f80 | 20 62 79 20 69 6d 70 6c 65 6d 65 6e 74 6f 72 73 20 69 73 20 74 68 61 74 20 69 66 20 61 6e 20 45 | .by.implementors.is.that.if.an.E |
5fa0 | 78 63 65 70 74 69 6f 6e 20 69 6e 73 74 61 6e 63 65 20 69 73 20 67 69 76 65 6e 0a 20 2a 20 74 6f | xception.instance.is.given..*.to |
5fc0 | 20 70 72 6f 64 75 63 65 20 61 20 73 74 61 63 6b 20 74 72 61 63 65 2c 20 69 74 20 4d 55 53 54 20 | .produce.a.stack.trace,.it.MUST. |
5fe0 | 62 65 20 69 6e 20 61 20 6b 65 79 20 6e 61 6d 65 64 20 22 65 78 63 65 70 74 69 6f 6e 22 2e 0a 20 | be.in.a.key.named."exception"... |
6000 | 2a 0a 20 2a 20 53 65 65 20 68 74 74 70 73 3a 2f 2f 67 69 74 68 75 62 2e 63 6f 6d 2f 70 68 70 2d | *..*.See.https://github.com/php- |
6020 | 66 69 67 2f 66 69 67 2d 73 74 61 6e 64 61 72 64 73 2f 62 6c 6f 62 2f 6d 61 73 74 65 72 2f 61 63 | fig/fig-standards/blob/master/ac |
6040 | 63 65 70 74 65 64 2f 50 53 52 2d 33 2d 6c 6f 67 67 65 72 2d 69 6e 74 65 72 66 61 63 65 2e 6d 64 | cepted/PSR-3-logger-interface.md |
6060 | 0a 20 2a 20 66 6f 72 20 74 68 65 20 66 75 6c 6c 20 69 6e 74 65 72 66 61 63 65 20 73 70 65 63 69 | ..*.for.the.full.interface.speci |
6080 | 66 69 63 61 74 69 6f 6e 2e 0a 20 2a 2f 0a 69 6e 74 65 72 66 61 63 65 20 4c 6f 67 67 65 72 49 6e | fication...*/.interface.LoggerIn |
60a0 | 74 65 72 66 61 63 65 0a 7b 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 79 73 74 65 6d 20 | terface.{...../**......*.System. |
60c0 | 69 73 20 75 6e 75 73 61 62 6c 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 | is.unusable.......*......*.@para |
60e0 | 6d 20 73 74 72 69 6e 67 20 24 6d 65 73 73 61 67 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 | m.string.$message......*.@param. |
6100 | 61 72 72 61 79 20 20 24 63 6f 6e 74 65 78 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 | array..$context......*......*.@r |
6120 | 65 74 75 72 6e 20 76 6f 69 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 | eturn.void......*/.....public.fu |
6140 | 6e 63 74 69 6f 6e 20 65 6d 65 72 67 65 6e 63 79 28 24 6d 65 73 73 61 67 65 2c 20 61 72 72 61 79 | nction.emergency($message,.array |
6160 | 20 24 63 6f 6e 74 65 78 74 20 3d 20 61 72 72 61 79 28 29 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 | .$context.=.array());....../**.. |
6180 | 20 20 20 20 2a 20 41 63 74 69 6f 6e 20 6d 75 73 74 20 62 65 20 74 61 6b 65 6e 20 69 6d 6d 65 64 | ....*.Action.must.be.taken.immed |
61a0 | 69 61 74 65 6c 79 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 45 78 61 6d 70 6c 65 3a 20 45 | iately.......*......*.Example:.E |
61c0 | 6e 74 69 72 65 20 77 65 62 73 69 74 65 20 64 6f 77 6e 2c 20 64 61 74 61 62 61 73 65 20 75 6e 61 | ntire.website.down,.database.una |
61e0 | 76 61 69 6c 61 62 6c 65 2c 20 65 74 63 2e 20 54 68 69 73 20 73 68 6f 75 6c 64 0a 20 20 20 20 20 | vailable,.etc..This.should...... |
6200 | 2a 20 74 72 69 67 67 65 72 20 74 68 65 20 53 4d 53 20 61 6c 65 72 74 73 20 61 6e 64 20 77 61 6b | *.trigger.the.SMS.alerts.and.wak |
6220 | 65 20 79 6f 75 20 75 70 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 | e.you.up.......*......*.@param.s |
6240 | 74 72 69 6e 67 20 24 6d 65 73 73 61 67 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 | tring.$message......*.@param.arr |
6260 | 61 79 20 20 24 63 6f 6e 74 65 78 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 | ay..$context......*......*.@retu |
6280 | 72 6e 20 76 6f 69 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 | rn.void......*/.....public.funct |
62a0 | 69 6f 6e 20 61 6c 65 72 74 28 24 6d 65 73 73 61 67 65 2c 20 61 72 72 61 79 20 24 63 6f 6e 74 65 | ion.alert($message,.array.$conte |
62c0 | 78 74 20 3d 20 61 72 72 61 79 28 29 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 43 | xt.=.array());....../**......*.C |
62e0 | 72 69 74 69 63 61 6c 20 63 6f 6e 64 69 74 69 6f 6e 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 | ritical.conditions.......*...... |
6300 | 2a 20 45 78 61 6d 70 6c 65 3a 20 41 70 70 6c 69 63 61 74 69 6f 6e 20 63 6f 6d 70 6f 6e 65 6e 74 | *.Example:.Application.component |
6320 | 20 75 6e 61 76 61 69 6c 61 62 6c 65 2c 20 75 6e 65 78 70 65 63 74 65 64 20 65 78 63 65 70 74 69 | .unavailable,.unexpected.excepti |
6340 | 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 | on.......*......*.@param.string. |
6360 | 24 6d 65 73 73 61 67 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 20 24 63 | $message......*.@param.array..$c |
6380 | 6f 6e 74 65 78 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 76 6f 69 | ontext......*......*.@return.voi |
63a0 | 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 63 72 | d......*/.....public.function.cr |
63c0 | 69 74 69 63 61 6c 28 24 6d 65 73 73 61 67 65 2c 20 61 72 72 61 79 20 24 63 6f 6e 74 65 78 74 20 | itical($message,.array.$context. |
63e0 | 3d 20 61 72 72 61 79 28 29 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 75 6e 74 | =.array());....../**......*.Runt |
6400 | 69 6d 65 20 65 72 72 6f 72 73 20 74 68 61 74 20 64 6f 20 6e 6f 74 20 72 65 71 75 69 72 65 20 69 | ime.errors.that.do.not.require.i |
6420 | 6d 6d 65 64 69 61 74 65 20 61 63 74 69 6f 6e 20 62 75 74 20 73 68 6f 75 6c 64 20 74 79 70 69 63 | mmediate.action.but.should.typic |
6440 | 61 6c 6c 79 0a 20 20 20 20 20 2a 20 62 65 20 6c 6f 67 67 65 64 20 61 6e 64 20 6d 6f 6e 69 74 6f | ally......*.be.logged.and.monito |
6460 | 72 65 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 | red.......*......*.@param.string |
6480 | 20 24 6d 65 73 73 61 67 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 20 24 | .$message......*.@param.array..$ |
64a0 | 63 6f 6e 74 65 78 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 76 6f | context......*......*.@return.vo |
64c0 | 69 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 65 | id......*/.....public.function.e |
64e0 | 72 72 6f 72 28 24 6d 65 73 73 61 67 65 2c 20 61 72 72 61 79 20 24 63 6f 6e 74 65 78 74 20 3d 20 | rror($message,.array.$context.=. |
6500 | 61 72 72 61 79 28 29 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 45 78 63 65 70 74 | array());....../**......*.Except |
6520 | 69 6f 6e 61 6c 20 6f 63 63 75 72 72 65 6e 63 65 73 20 74 68 61 74 20 61 72 65 20 6e 6f 74 20 65 | ional.occurrences.that.are.not.e |
6540 | 72 72 6f 72 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 45 78 61 6d 70 6c 65 3a 20 55 73 | rrors.......*......*.Example:.Us |
6560 | 65 20 6f 66 20 64 65 70 72 65 63 61 74 65 64 20 41 50 49 73 2c 20 70 6f 6f 72 20 75 73 65 20 6f | e.of.deprecated.APIs,.poor.use.o |
6580 | 66 20 61 6e 20 41 50 49 2c 20 75 6e 64 65 73 69 72 61 62 6c 65 20 74 68 69 6e 67 73 0a 20 20 20 | f.an.API,.undesirable.things.... |
65a0 | 20 20 2a 20 74 68 61 74 20 61 72 65 20 6e 6f 74 20 6e 65 63 65 73 73 61 72 69 6c 79 20 77 72 6f | ..*.that.are.not.necessarily.wro |
65c0 | 6e 67 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 | ng.......*......*.@param.string. |
65e0 | 24 6d 65 73 73 61 67 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 20 24 63 | $message......*.@param.array..$c |
6600 | 6f 6e 74 65 78 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 76 6f 69 | ontext......*......*.@return.voi |
6620 | 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 77 61 | d......*/.....public.function.wa |
6640 | 72 6e 69 6e 67 28 24 6d 65 73 73 61 67 65 2c 20 61 72 72 61 79 20 24 63 6f 6e 74 65 78 74 20 3d | rning($message,.array.$context.= |
6660 | 20 61 72 72 61 79 28 29 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 4e 6f 72 6d 61 | .array());....../**......*.Norma |
6680 | 6c 20 62 75 74 20 73 69 67 6e 69 66 69 63 61 6e 74 20 65 76 65 6e 74 73 2e 0a 20 20 20 20 20 2a | l.but.significant.events.......* |
66a0 | 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6d 65 73 73 61 67 65 0a 20 | ......*.@param.string.$message.. |
66c0 | 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 20 24 63 6f 6e 74 65 78 74 0a 20 20 20 | ....*.@param.array..$context.... |
66e0 | 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 76 6f 69 64 0a 20 20 20 20 20 2a 2f 0a | ..*......*.@return.void......*/. |
6700 | 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 6e 6f 74 69 63 65 28 24 6d 65 73 73 | ....public.function.notice($mess |
6720 | 61 67 65 2c 20 61 72 72 61 79 20 24 63 6f 6e 74 65 78 74 20 3d 20 61 72 72 61 79 28 29 29 3b 0a | age,.array.$context.=.array());. |
6740 | 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 49 6e 74 65 72 65 73 74 69 6e 67 20 65 76 65 6e | ...../**......*.Interesting.even |
6760 | 74 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 45 78 61 6d 70 6c 65 3a 20 55 73 65 72 20 | ts.......*......*.Example:.User. |
6780 | 6c 6f 67 73 20 69 6e 2c 20 53 51 4c 20 6c 6f 67 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a | logs.in,.SQL.logs.......*......* |
67a0 | 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6d 65 73 73 61 67 65 0a 20 20 20 20 20 2a 20 40 | .@param.string.$message......*.@ |
67c0 | 70 61 72 61 6d 20 61 72 72 61 79 20 20 24 63 6f 6e 74 65 78 74 0a 20 20 20 20 20 2a 0a 20 20 20 | param.array..$context......*.... |
67e0 | 20 20 2a 20 40 72 65 74 75 72 6e 20 76 6f 69 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 | ..*.@return.void......*/.....pub |
6800 | 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 69 6e 66 6f 28 24 6d 65 73 73 61 67 65 2c 20 61 72 72 61 | lic.function.info($message,.arra |
6820 | 79 20 24 63 6f 6e 74 65 78 74 20 3d 20 61 72 72 61 79 28 29 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a | y.$context.=.array());....../**. |
6840 | 20 20 20 20 20 2a 20 44 65 74 61 69 6c 65 64 20 64 65 62 75 67 20 69 6e 66 6f 72 6d 61 74 69 6f | .....*.Detailed.debug.informatio |
6860 | 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 | n.......*......*.@param.string.$ |
6880 | 6d 65 73 73 61 67 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 20 24 63 6f | message......*.@param.array..$co |
68a0 | 6e 74 65 78 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 76 6f 69 64 | ntext......*......*.@return.void |
68c0 | 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 64 65 62 | ......*/.....public.function.deb |
68e0 | 75 67 28 24 6d 65 73 73 61 67 65 2c 20 61 72 72 61 79 20 24 63 6f 6e 74 65 78 74 20 3d 20 61 72 | ug($message,.array.$context.=.ar |
6900 | 72 61 79 28 29 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 4c 6f 67 73 20 77 69 74 | ray());....../**......*.Logs.wit |
6920 | 68 20 61 6e 20 61 72 62 69 74 72 61 72 79 20 6c 65 76 65 6c 2e 0a 20 20 20 20 20 2a 0a 20 20 20 | h.an.arbitrary.level.......*.... |
6940 | 20 20 2a 20 40 70 61 72 61 6d 20 6d 69 78 65 64 20 20 24 6c 65 76 65 6c 0a 20 20 20 20 20 2a 20 | ..*.@param.mixed..$level......*. |
6960 | 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6d 65 73 73 61 67 65 0a 20 20 20 20 20 2a 20 40 70 | @param.string.$message......*.@p |
6980 | 61 72 61 6d 20 61 72 72 61 79 20 20 24 63 6f 6e 74 65 78 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 | aram.array..$context......*..... |
69a0 | 20 2a 20 40 72 65 74 75 72 6e 20 76 6f 69 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c | .*.@return.void......*/.....publ |
69c0 | 69 63 20 66 75 6e 63 74 69 6f 6e 20 6c 6f 67 28 24 6c 65 76 65 6c 2c 20 24 6d 65 73 73 61 67 65 | ic.function.log($level,.$message |
69e0 | 2c 20 61 72 72 61 79 20 24 63 6f 6e 74 65 78 74 20 3d 20 61 72 72 61 79 28 29 29 3b 0a 7d 0a 0a | ,.array.$context.=.array());.}.. |
6a00 | 43 6f 70 79 72 69 67 68 74 20 28 63 29 20 4e 69 6c 73 20 41 64 65 72 6d 61 6e 6e 2c 20 4a 6f 72 | Copyright.(c).Nils.Adermann,.Jor |
6a20 | 64 69 20 42 6f 67 67 69 61 6e 6f 0a 0a 50 65 72 6d 69 73 73 69 6f 6e 20 69 73 20 68 65 72 65 62 | di.Boggiano..Permission.is.hereb |
6a40 | 79 20 67 72 61 6e 74 65 64 2c 20 66 72 65 65 20 6f 66 20 63 68 61 72 67 65 2c 20 74 6f 20 61 6e | y.granted,.free.of.charge,.to.an |
6a60 | 79 20 70 65 72 73 6f 6e 20 6f 62 74 61 69 6e 69 6e 67 20 61 20 63 6f 70 79 0a 6f 66 20 74 68 69 | y.person.obtaining.a.copy.of.thi |
6a80 | 73 20 73 6f 66 74 77 61 72 65 20 61 6e 64 20 61 73 73 6f 63 69 61 74 65 64 20 64 6f 63 75 6d 65 | s.software.and.associated.docume |
6aa0 | 6e 74 61 74 69 6f 6e 20 66 69 6c 65 73 20 28 74 68 65 20 22 53 6f 66 74 77 61 72 65 22 29 2c 20 | ntation.files.(the."Software"),. |
6ac0 | 74 6f 20 64 65 61 6c 0a 69 6e 20 74 68 65 20 53 6f 66 74 77 61 72 65 20 77 69 74 68 6f 75 74 20 | to.deal.in.the.Software.without. |
6ae0 | 72 65 73 74 72 69 63 74 69 6f 6e 2c 20 69 6e 63 6c 75 64 69 6e 67 20 77 69 74 68 6f 75 74 20 6c | restriction,.including.without.l |
6b00 | 69 6d 69 74 61 74 69 6f 6e 20 74 68 65 20 72 69 67 68 74 73 0a 74 6f 20 75 73 65 2c 20 63 6f 70 | imitation.the.rights.to.use,.cop |
6b20 | 79 2c 20 6d 6f 64 69 66 79 2c 20 6d 65 72 67 65 2c 20 70 75 62 6c 69 73 68 2c 20 64 69 73 74 72 | y,.modify,.merge,.publish,.distr |
6b40 | 69 62 75 74 65 2c 20 73 75 62 6c 69 63 65 6e 73 65 2c 20 61 6e 64 2f 6f 72 20 73 65 6c 6c 0a 63 | ibute,.sublicense,.and/or.sell.c |
6b60 | 6f 70 69 65 73 20 6f 66 20 74 68 65 20 53 6f 66 74 77 61 72 65 2c 20 61 6e 64 20 74 6f 20 70 65 | opies.of.the.Software,.and.to.pe |
6b80 | 72 6d 69 74 20 70 65 72 73 6f 6e 73 20 74 6f 20 77 68 6f 6d 20 74 68 65 20 53 6f 66 74 77 61 72 | rmit.persons.to.whom.the.Softwar |
6ba0 | 65 20 69 73 20 66 75 72 6e 69 73 68 65 64 0a 74 6f 20 64 6f 20 73 6f 2c 20 73 75 62 6a 65 63 74 | e.is.furnished.to.do.so,.subject |
6bc0 | 20 74 6f 20 74 68 65 20 66 6f 6c 6c 6f 77 69 6e 67 20 63 6f 6e 64 69 74 69 6f 6e 73 3a 0a 0a 54 | .to.the.following.conditions:..T |
6be0 | 68 65 20 61 62 6f 76 65 20 63 6f 70 79 72 69 67 68 74 20 6e 6f 74 69 63 65 20 61 6e 64 20 74 68 | he.above.copyright.notice.and.th |
6c00 | 69 73 20 70 65 72 6d 69 73 73 69 6f 6e 20 6e 6f 74 69 63 65 20 73 68 61 6c 6c 20 62 65 20 69 6e | is.permission.notice.shall.be.in |
6c20 | 63 6c 75 64 65 64 20 69 6e 20 61 6c 6c 0a 63 6f 70 69 65 73 20 6f 72 20 73 75 62 73 74 61 6e 74 | cluded.in.all.copies.or.substant |
6c40 | 69 61 6c 20 70 6f 72 74 69 6f 6e 73 20 6f 66 20 74 68 65 20 53 6f 66 74 77 61 72 65 2e 0a 0a 54 | ial.portions.of.the.Software...T |
6c60 | 48 45 20 53 4f 46 54 57 41 52 45 20 49 53 20 50 52 4f 56 49 44 45 44 20 22 41 53 20 49 53 22 2c | HE.SOFTWARE.IS.PROVIDED."AS.IS", |
6c80 | 20 57 49 54 48 4f 55 54 20 57 41 52 52 41 4e 54 59 20 4f 46 20 41 4e 59 20 4b 49 4e 44 2c 20 45 | .WITHOUT.WARRANTY.OF.ANY.KIND,.E |
6ca0 | 58 50 52 45 53 53 20 4f 52 0a 49 4d 50 4c 49 45 44 2c 20 49 4e 43 4c 55 44 49 4e 47 20 42 55 54 | XPRESS.OR.IMPLIED,.INCLUDING.BUT |
6cc0 | 20 4e 4f 54 20 4c 49 4d 49 54 45 44 20 54 4f 20 54 48 45 20 57 41 52 52 41 4e 54 49 45 53 20 4f | .NOT.LIMITED.TO.THE.WARRANTIES.O |
6ce0 | 46 20 4d 45 52 43 48 41 4e 54 41 42 49 4c 49 54 59 2c 0a 46 49 54 4e 45 53 53 20 46 4f 52 20 41 | F.MERCHANTABILITY,.FITNESS.FOR.A |
6d00 | 20 50 41 52 54 49 43 55 4c 41 52 20 50 55 52 50 4f 53 45 20 41 4e 44 20 4e 4f 4e 49 4e 46 52 49 | .PARTICULAR.PURPOSE.AND.NONINFRI |
6d20 | 4e 47 45 4d 45 4e 54 2e 20 49 4e 20 4e 4f 20 45 56 45 4e 54 20 53 48 41 4c 4c 20 54 48 45 0a 41 | NGEMENT..IN.NO.EVENT.SHALL.THE.A |
6d40 | 55 54 48 4f 52 53 20 4f 52 20 43 4f 50 59 52 49 47 48 54 20 48 4f 4c 44 45 52 53 20 42 45 20 4c | UTHORS.OR.COPYRIGHT.HOLDERS.BE.L |
6d60 | 49 41 42 4c 45 20 46 4f 52 20 41 4e 59 20 43 4c 41 49 4d 2c 20 44 41 4d 41 47 45 53 20 4f 52 20 | IABLE.FOR.ANY.CLAIM,.DAMAGES.OR. |
6d80 | 4f 54 48 45 52 0a 4c 49 41 42 49 4c 49 54 59 2c 20 57 48 45 54 48 45 52 20 49 4e 20 41 4e 20 41 | OTHER.LIABILITY,.WHETHER.IN.AN.A |
6da0 | 43 54 49 4f 4e 20 4f 46 20 43 4f 4e 54 52 41 43 54 2c 20 54 4f 52 54 20 4f 52 20 4f 54 48 45 52 | CTION.OF.CONTRACT,.TORT.OR.OTHER |
6dc0 | 57 49 53 45 2c 20 41 52 49 53 49 4e 47 20 46 52 4f 4d 2c 0a 4f 55 54 20 4f 46 20 4f 52 20 49 4e | WISE,.ARISING.FROM,.OUT.OF.OR.IN |
6de0 | 20 43 4f 4e 4e 45 43 54 49 4f 4e 20 57 49 54 48 20 54 48 45 20 53 4f 46 54 57 41 52 45 20 4f 52 | .CONNECTION.WITH.THE.SOFTWARE.OR |
6e00 | 20 54 48 45 20 55 53 45 20 4f 52 20 4f 54 48 45 52 20 44 45 41 4c 49 4e 47 53 20 49 4e 0a 54 48 | .THE.USE.OR.OTHER.DEALINGS.IN.TH |
6e20 | 45 20 53 4f 46 54 57 41 52 45 2e 0a 0a 3c 3f 70 68 70 0a 0a 2f 2f 20 61 75 74 6f 6c 6f 61 64 5f | E.SOFTWARE...<?php..//.autoload_ |
6e40 | 66 69 6c 65 73 2e 70 68 70 20 40 67 65 6e 65 72 61 74 65 64 20 62 79 20 43 6f 6d 70 6f 73 65 72 | files.php.@generated.by.Composer |
6e60 | 0a 0a 24 76 65 6e 64 6f 72 44 69 72 20 3d 20 64 69 72 6e 61 6d 65 28 64 69 72 6e 61 6d 65 28 5f | ..$vendorDir.=.dirname(dirname(_ |
6e80 | 5f 46 49 4c 45 5f 5f 29 29 3b 0a 24 62 61 73 65 44 69 72 20 3d 20 64 69 72 6e 61 6d 65 28 24 76 | _FILE__));.$baseDir.=.dirname($v |
6ea0 | 65 6e 64 6f 72 44 69 72 29 3b 0a 0a 72 65 74 75 72 6e 20 61 72 72 61 79 28 0a 20 20 20 20 27 30 | endorDir);..return.array(.....'0 |
6ec0 | 65 36 64 37 62 66 34 61 35 38 31 31 62 66 61 35 63 66 34 30 63 35 63 63 64 36 66 61 65 36 61 27 | e6d7bf4a5811bfa5cf40c5ccd6fae6a' |
6ee0 | 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 70 6f 6c 79 66 | .=>.$vendorDir...'/symfony/polyf |
6f00 | 69 6c 6c 2d 6d 62 73 74 72 69 6e 67 2f 62 6f 6f 74 73 74 72 61 70 2e 70 68 70 27 2c 0a 29 3b 0a | ill-mbstring/bootstrap.php',.);. |
6f20 | 3c 3f 70 68 70 0a 0a 2f 2f 20 61 75 74 6f 6c 6f 61 64 5f 6e 61 6d 65 73 70 61 63 65 73 2e 70 68 | <?php..//.autoload_namespaces.ph |
6f40 | 70 20 40 67 65 6e 65 72 61 74 65 64 20 62 79 20 43 6f 6d 70 6f 73 65 72 0a 0a 24 76 65 6e 64 6f | p.@generated.by.Composer..$vendo |
6f60 | 72 44 69 72 20 3d 20 64 69 72 6e 61 6d 65 28 64 69 72 6e 61 6d 65 28 5f 5f 46 49 4c 45 5f 5f 29 | rDir.=.dirname(dirname(__FILE__) |
6f80 | 29 3b 0a 24 62 61 73 65 44 69 72 20 3d 20 64 69 72 6e 61 6d 65 28 24 76 65 6e 64 6f 72 44 69 72 | );.$baseDir.=.dirname($vendorDir |
6fa0 | 29 3b 0a 0a 72 65 74 75 72 6e 20 61 72 72 61 79 28 0a 29 3b 0a 3c 3f 70 68 70 0a 0a 2f 2f 20 70 | );..return.array(.);.<?php..//.p |
6fc0 | 6c 61 74 66 6f 72 6d 5f 63 68 65 63 6b 2e 70 68 70 20 40 67 65 6e 65 72 61 74 65 64 20 62 79 20 | latform_check.php.@generated.by. |
6fe0 | 43 6f 6d 70 6f 73 65 72 0a 0a 24 69 73 73 75 65 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 0a 69 66 | Composer..$issues.=.array();..if |
7000 | 20 28 21 28 50 48 50 5f 56 45 52 53 49 4f 4e 5f 49 44 20 3e 3d 20 35 30 35 30 39 29 29 20 7b 0a | .(!(PHP_VERSION_ID.>=.50509)).{. |
7020 | 20 20 20 20 24 69 73 73 75 65 73 5b 5d 20 3d 20 27 59 6f 75 72 20 43 6f 6d 70 6f 73 65 72 20 64 | ....$issues[].=.'Your.Composer.d |
7040 | 65 70 65 6e 64 65 6e 63 69 65 73 20 72 65 71 75 69 72 65 20 61 20 50 48 50 20 76 65 72 73 69 6f | ependencies.require.a.PHP.versio |
7060 | 6e 20 22 3e 3d 20 35 2e 35 2e 39 22 2e 20 59 6f 75 20 61 72 65 20 72 75 6e 6e 69 6e 67 20 27 20 | n.">=.5.5.9"..You.are.running.'. |
7080 | 2e 20 50 48 50 5f 56 45 52 53 49 4f 4e 20 2e 20 27 2e 27 3b 0a 7d 0a 0a 69 66 20 28 24 69 73 73 | ..PHP_VERSION...'.';.}..if.($iss |
70a0 | 75 65 73 29 20 7b 0a 20 20 20 20 69 66 20 28 21 68 65 61 64 65 72 73 5f 73 65 6e 74 28 29 29 20 | ues).{.....if.(!headers_sent()). |
70c0 | 7b 0a 20 20 20 20 20 20 20 20 68 65 61 64 65 72 28 27 48 54 54 50 2f 31 2e 31 20 35 30 30 20 49 | {.........header('HTTP/1.1.500.I |
70e0 | 6e 74 65 72 6e 61 6c 20 53 65 72 76 65 72 20 45 72 72 6f 72 27 29 3b 0a 20 20 20 20 7d 0a 20 20 | nternal.Server.Error');.....}... |
7100 | 20 20 69 66 20 28 21 69 6e 69 5f 67 65 74 28 27 64 69 73 70 6c 61 79 5f 65 72 72 6f 72 73 27 29 | ..if.(!ini_get('display_errors') |
7120 | 29 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 50 48 50 5f 53 41 50 49 20 3d 3d 3d 20 27 63 6c | ).{.........if.(PHP_SAPI.===.'cl |
7140 | 69 27 20 7c 7c 20 50 48 50 5f 53 41 50 49 20 3d 3d 3d 20 27 70 68 70 64 62 67 27 29 20 7b 0a 20 | i'.||.PHP_SAPI.===.'phpdbg').{.. |
7160 | 20 20 20 20 20 20 20 20 20 20 20 66 77 72 69 74 65 28 53 54 44 45 52 52 2c 20 27 43 6f 6d 70 6f | ...........fwrite(STDERR,.'Compo |
7180 | 73 65 72 20 64 65 74 65 63 74 65 64 20 69 73 73 75 65 73 20 69 6e 20 79 6f 75 72 20 70 6c 61 74 | ser.detected.issues.in.your.plat |
71a0 | 66 6f 72 6d 3a 27 20 2e 20 50 48 50 5f 45 4f 4c 2e 50 48 50 5f 45 4f 4c 20 2e 20 69 6d 70 6c 6f | form:'...PHP_EOL.PHP_EOL...implo |
71c0 | 64 65 28 50 48 50 5f 45 4f 4c 2c 20 24 69 73 73 75 65 73 29 20 2e 20 50 48 50 5f 45 4f 4c 2e 50 | de(PHP_EOL,.$issues)...PHP_EOL.P |
71e0 | 48 50 5f 45 4f 4c 29 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 21 68 65 61 64 | HP_EOL);.........}.elseif.(!head |
7200 | 65 72 73 5f 73 65 6e 74 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 65 63 68 6f 20 27 | ers_sent()).{.............echo.' |
7220 | 43 6f 6d 70 6f 73 65 72 20 64 65 74 65 63 74 65 64 20 69 73 73 75 65 73 20 69 6e 20 79 6f 75 72 | Composer.detected.issues.in.your |
7240 | 20 70 6c 61 74 66 6f 72 6d 3a 27 20 2e 20 50 48 50 5f 45 4f 4c 2e 50 48 50 5f 45 4f 4c 20 2e 20 | .platform:'...PHP_EOL.PHP_EOL... |
7260 | 73 74 72 5f 72 65 70 6c 61 63 65 28 27 59 6f 75 20 61 72 65 20 72 75 6e 6e 69 6e 67 20 27 2e 50 | str_replace('You.are.running.'.P |
7280 | 48 50 5f 56 45 52 53 49 4f 4e 2e 27 2e 27 2c 20 27 27 2c 20 69 6d 70 6c 6f 64 65 28 50 48 50 5f | HP_VERSION.'.',.'',.implode(PHP_ |
72a0 | 45 4f 4c 2c 20 24 69 73 73 75 65 73 29 29 20 2e 20 50 48 50 5f 45 4f 4c 2e 50 48 50 5f 45 4f 4c | EOL,.$issues))...PHP_EOL.PHP_EOL |
72c0 | 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 20 20 20 20 74 72 69 67 67 65 72 5f 65 72 | ;.........}.....}.....trigger_er |
72e0 | 72 6f 72 28 0a 20 20 20 20 20 20 20 20 27 43 6f 6d 70 6f 73 65 72 20 64 65 74 65 63 74 65 64 20 | ror(.........'Composer.detected. |
7300 | 69 73 73 75 65 73 20 69 6e 20 79 6f 75 72 20 70 6c 61 74 66 6f 72 6d 3a 20 27 20 2e 20 69 6d 70 | issues.in.your.platform:.'...imp |
7320 | 6c 6f 64 65 28 27 20 27 2c 20 24 69 73 73 75 65 73 29 2c 0a 20 20 20 20 20 20 20 20 45 5f 55 53 | lode('.',.$issues),.........E_US |
7340 | 45 52 5f 45 52 52 4f 52 0a 20 20 20 20 29 3b 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2f 20 61 75 74 6f | ER_ERROR.....);.}.<?php..//.auto |
7360 | 6c 6f 61 64 5f 72 65 61 6c 2e 70 68 70 20 40 67 65 6e 65 72 61 74 65 64 20 62 79 20 43 6f 6d 70 | load_real.php.@generated.by.Comp |
7380 | 6f 73 65 72 0a 0a 63 6c 61 73 73 20 43 6f 6d 70 6f 73 65 72 41 75 74 6f 6c 6f 61 64 65 72 49 6e | oser..class.ComposerAutoloaderIn |
73a0 | 69 74 39 39 34 62 38 64 38 37 30 64 64 62 39 32 33 65 62 63 33 66 66 30 63 65 61 61 61 61 39 36 | it994b8d870ddb923ebc3ff0ceaaaa96 |
73c0 | 61 36 0a 7b 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 24 6c 6f 61 64 65 72 3b | a6.{.....private.static.$loader; |
73e0 | 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 6c 6f 61 | ......public.static.function.loa |
7400 | 64 43 6c 61 73 73 4c 6f 61 64 65 72 28 24 63 6c 61 73 73 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 | dClassLoader($class).....{...... |
7420 | 20 20 20 69 66 20 28 27 43 6f 6d 70 6f 73 65 72 5c 41 75 74 6f 6c 6f 61 64 5c 43 6c 61 73 73 4c | ...if.('Composer\Autoload\ClassL |
7440 | 6f 61 64 65 72 27 20 3d 3d 3d 20 24 63 6c 61 73 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | oader'.===.$class).{............ |
7460 | 20 72 65 71 75 69 72 65 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 43 6c 61 73 73 4c 6f 61 64 65 72 | .require.__DIR__...'/ClassLoader |
7480 | 2e 70 68 70 27 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a | .php';.........}.....}....../**. |
74a0 | 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 5c 43 6f 6d 70 6f 73 65 72 5c 41 75 74 6f 6c 6f 61 | .....*.@return.\Composer\Autoloa |
74c0 | 64 5c 43 6c 61 73 73 4c 6f 61 64 65 72 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 | d\ClassLoader......*/.....public |
74e0 | 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 4c 6f 61 64 65 72 28 29 0a 20 20 20 | .static.function.getLoader().... |
7500 | 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 21 3d 3d 20 73 65 6c 66 3a 3a 24 6c | .{.........if.(null.!==.self::$l |
7520 | 6f 61 64 65 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 | oader).{.............return.self |
7540 | 3a 3a 24 6c 6f 61 64 65 72 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 | ::$loader;.........}..........re |
7560 | 71 75 69 72 65 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 70 6c 61 74 66 6f 72 6d 5f 63 68 65 63 6b | quire.__DIR__...'/platform_check |
7580 | 2e 70 68 70 27 3b 0a 0a 20 20 20 20 20 20 20 20 73 70 6c 5f 61 75 74 6f 6c 6f 61 64 5f 72 65 67 | .php';..........spl_autoload_reg |
75a0 | 69 73 74 65 72 28 61 72 72 61 79 28 27 43 6f 6d 70 6f 73 65 72 41 75 74 6f 6c 6f 61 64 65 72 49 | ister(array('ComposerAutoloaderI |
75c0 | 6e 69 74 39 39 34 62 38 64 38 37 30 64 64 62 39 32 33 65 62 63 33 66 66 30 63 65 61 61 61 61 39 | nit994b8d870ddb923ebc3ff0ceaaaa9 |
75e0 | 36 61 36 27 2c 20 27 6c 6f 61 64 43 6c 61 73 73 4c 6f 61 64 65 72 27 29 2c 20 74 72 75 65 2c 20 | 6a6',.'loadClassLoader'),.true,. |
7600 | 74 72 75 65 29 3b 0a 20 20 20 20 20 20 20 20 73 65 6c 66 3a 3a 24 6c 6f 61 64 65 72 20 3d 20 24 | true);.........self::$loader.=.$ |
7620 | 6c 6f 61 64 65 72 20 3d 20 6e 65 77 20 5c 43 6f 6d 70 6f 73 65 72 5c 41 75 74 6f 6c 6f 61 64 5c | loader.=.new.\Composer\Autoload\ |
7640 | 43 6c 61 73 73 4c 6f 61 64 65 72 28 5c 64 69 72 6e 61 6d 65 28 5c 64 69 72 6e 61 6d 65 28 5f 5f | ClassLoader(\dirname(\dirname(__ |
7660 | 46 49 4c 45 5f 5f 29 29 29 3b 0a 20 20 20 20 20 20 20 20 73 70 6c 5f 61 75 74 6f 6c 6f 61 64 5f | FILE__)));.........spl_autoload_ |
7680 | 75 6e 72 65 67 69 73 74 65 72 28 61 72 72 61 79 28 27 43 6f 6d 70 6f 73 65 72 41 75 74 6f 6c 6f | unregister(array('ComposerAutolo |
76a0 | 61 64 65 72 49 6e 69 74 39 39 34 62 38 64 38 37 30 64 64 62 39 32 33 65 62 63 33 66 66 30 63 65 | aderInit994b8d870ddb923ebc3ff0ce |
76c0 | 61 61 61 61 39 36 61 36 27 2c 20 27 6c 6f 61 64 43 6c 61 73 73 4c 6f 61 64 65 72 27 29 29 3b 0a | aaaa96a6',.'loadClassLoader'));. |
76e0 | 0a 20 20 20 20 20 20 20 20 24 75 73 65 53 74 61 74 69 63 4c 6f 61 64 65 72 20 3d 20 50 48 50 5f | .........$useStaticLoader.=.PHP_ |
7700 | 56 45 52 53 49 4f 4e 5f 49 44 20 3e 3d 20 35 30 36 30 30 20 26 26 20 21 64 65 66 69 6e 65 64 28 | VERSION_ID.>=.50600.&&.!defined( |
7720 | 27 48 48 56 4d 5f 56 45 52 53 49 4f 4e 27 29 20 26 26 20 28 21 66 75 6e 63 74 69 6f 6e 5f 65 78 | 'HHVM_VERSION').&&.(!function_ex |
7740 | 69 73 74 73 28 27 7a 65 6e 64 5f 6c 6f 61 64 65 72 5f 66 69 6c 65 5f 65 6e 63 6f 64 65 64 27 29 | ists('zend_loader_file_encoded') |
7760 | 20 7c 7c 20 21 7a 65 6e 64 5f 6c 6f 61 64 65 72 5f 66 69 6c 65 5f 65 6e 63 6f 64 65 64 28 29 29 | .||.!zend_loader_file_encoded()) |
7780 | 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 75 73 65 53 74 61 74 69 63 4c 6f 61 64 65 72 29 20 | ;.........if.($useStaticLoader). |
77a0 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 71 75 69 72 65 20 5f 5f 44 49 52 5f 5f 20 2e 20 | {.............require.__DIR__... |
77c0 | 27 2f 61 75 74 6f 6c 6f 61 64 5f 73 74 61 74 69 63 2e 70 68 70 27 3b 0a 0a 20 20 20 20 20 20 20 | '/autoload_static.php';......... |
77e0 | 20 20 20 20 20 63 61 6c 6c 5f 75 73 65 72 5f 66 75 6e 63 28 5c 43 6f 6d 70 6f 73 65 72 5c 41 75 | .....call_user_func(\Composer\Au |
7800 | 74 6f 6c 6f 61 64 5c 43 6f 6d 70 6f 73 65 72 53 74 61 74 69 63 49 6e 69 74 39 39 34 62 38 64 38 | toload\ComposerStaticInit994b8d8 |
7820 | 37 30 64 64 62 39 32 33 65 62 63 33 66 66 30 63 65 61 61 61 61 39 36 61 36 3a 3a 67 65 74 49 6e | 70ddb923ebc3ff0ceaaaa96a6::getIn |
7840 | 69 74 69 61 6c 69 7a 65 72 28 24 6c 6f 61 64 65 72 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 | itializer($loader));.........}.e |
7860 | 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6c 61 73 73 4d 61 70 20 3d 20 72 65 | lse.{.............$classMap.=.re |
7880 | 71 75 69 72 65 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 61 75 74 6f 6c 6f 61 64 5f 63 6c 61 73 73 | quire.__DIR__...'/autoload_class |
78a0 | 6d 61 70 2e 70 68 70 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 63 6c 61 73 73 | map.php';.............if.($class |
78c0 | 4d 61 70 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 6f 61 64 65 72 2d 3e | Map).{.................$loader-> |
78e0 | 61 64 64 43 6c 61 73 73 4d 61 70 28 24 63 6c 61 73 73 4d 61 70 29 3b 0a 20 20 20 20 20 20 20 20 | addClassMap($classMap);......... |
7900 | 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 6c 6f 61 64 65 72 | ....}.........}..........$loader |
7920 | 2d 3e 73 65 74 43 6c 61 73 73 4d 61 70 41 75 74 68 6f 72 69 74 61 74 69 76 65 28 74 72 75 65 29 | ->setClassMapAuthoritative(true) |
7940 | 3b 0a 20 20 20 20 20 20 20 20 24 6c 6f 61 64 65 72 2d 3e 72 65 67 69 73 74 65 72 28 74 72 75 65 | ;.........$loader->register(true |
7960 | 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 75 73 65 53 74 61 74 69 63 4c 6f 61 64 65 72 | );..........if.($useStaticLoader |
7980 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 69 6e 63 6c 75 64 65 46 69 6c 65 73 20 3d 20 | ).{.............$includeFiles.=. |
79a0 | 43 6f 6d 70 6f 73 65 72 5c 41 75 74 6f 6c 6f 61 64 5c 43 6f 6d 70 6f 73 65 72 53 74 61 74 69 63 | Composer\Autoload\ComposerStatic |
79c0 | 49 6e 69 74 39 39 34 62 38 64 38 37 30 64 64 62 39 32 33 65 62 63 33 66 66 30 63 65 61 61 61 61 | Init994b8d870ddb923ebc3ff0ceaaaa |
79e0 | 39 36 61 36 3a 3a 24 66 69 6c 65 73 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 | 96a6::$files;.........}.else.{.. |
7a00 | 20 20 20 20 20 20 20 20 20 20 20 24 69 6e 63 6c 75 64 65 46 69 6c 65 73 20 3d 20 72 65 71 75 69 | ...........$includeFiles.=.requi |
7a20 | 72 65 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 61 75 74 6f 6c 6f 61 64 5f 66 69 6c 65 73 2e 70 68 | re.__DIR__...'/autoload_files.ph |
7a40 | 70 27 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 | p';.........}.........foreach.($ |
7a60 | 69 6e 63 6c 75 64 65 46 69 6c 65 73 20 61 73 20 24 66 69 6c 65 49 64 65 6e 74 69 66 69 65 72 20 | includeFiles.as.$fileIdentifier. |
7a80 | 3d 3e 20 24 66 69 6c 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 63 6f 6d 70 6f 73 65 72 | =>.$file).{.............composer |
7aa0 | 52 65 71 75 69 72 65 39 39 34 62 38 64 38 37 30 64 64 62 39 32 33 65 62 63 33 66 66 30 63 65 61 | Require994b8d870ddb923ebc3ff0cea |
7ac0 | 61 61 61 39 36 61 36 28 24 66 69 6c 65 49 64 65 6e 74 69 66 69 65 72 2c 20 24 66 69 6c 65 29 3b | aaa96a6($fileIdentifier,.$file); |
7ae0 | 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 6c 6f 61 64 | .........}..........return.$load |
7b00 | 65 72 3b 0a 20 20 20 20 7d 0a 7d 0a 0a 2f 2a 2a 0a 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e | er;.....}.}../**..*.@param.strin |
7b20 | 67 20 24 66 69 6c 65 49 64 65 6e 74 69 66 69 65 72 0a 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 | g.$fileIdentifier..*.@param.stri |
7b40 | 6e 67 20 24 66 69 6c 65 0a 20 2a 20 40 72 65 74 75 72 6e 20 76 6f 69 64 0a 20 2a 2f 0a 66 75 6e | ng.$file..*.@return.void..*/.fun |
7b60 | 63 74 69 6f 6e 20 63 6f 6d 70 6f 73 65 72 52 65 71 75 69 72 65 39 39 34 62 38 64 38 37 30 64 64 | ction.composerRequire994b8d870dd |
7b80 | 62 39 32 33 65 62 63 33 66 66 30 63 65 61 61 61 61 39 36 61 36 28 24 66 69 6c 65 49 64 65 6e 74 | b923ebc3ff0ceaaaa96a6($fileIdent |
7ba0 | 69 66 69 65 72 2c 20 24 66 69 6c 65 29 0a 7b 0a 20 20 20 20 69 66 20 28 65 6d 70 74 79 28 24 47 | ifier,.$file).{.....if.(empty($G |
7bc0 | 4c 4f 42 41 4c 53 5b 27 5f 5f 63 6f 6d 70 6f 73 65 72 5f 61 75 74 6f 6c 6f 61 64 5f 66 69 6c 65 | LOBALS['__composer_autoload_file |
7be0 | 73 27 5d 5b 24 66 69 6c 65 49 64 65 6e 74 69 66 69 65 72 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 | s'][$fileIdentifier])).{........ |
7c00 | 20 24 47 4c 4f 42 41 4c 53 5b 27 5f 5f 63 6f 6d 70 6f 73 65 72 5f 61 75 74 6f 6c 6f 61 64 5f 66 | .$GLOBALS['__composer_autoload_f |
7c20 | 69 6c 65 73 27 5d 5b 24 66 69 6c 65 49 64 65 6e 74 69 66 69 65 72 5d 20 3d 20 74 72 75 65 3b 0a | iles'][$fileIdentifier].=.true;. |
7c40 | 0a 20 20 20 20 20 20 20 20 72 65 71 75 69 72 65 20 24 66 69 6c 65 3b 0a 20 20 20 20 7d 0a 7d 0a | .........require.$file;.....}.}. |
7c60 | 3c 3f 70 68 70 0a 0a 2f 2f 20 61 75 74 6f 6c 6f 61 64 5f 73 74 61 74 69 63 2e 70 68 70 20 40 67 | <?php..//.autoload_static.php.@g |
7c80 | 65 6e 65 72 61 74 65 64 20 62 79 20 43 6f 6d 70 6f 73 65 72 0a 0a 6e 61 6d 65 73 70 61 63 65 20 | enerated.by.Composer..namespace. |
7ca0 | 43 6f 6d 70 6f 73 65 72 5c 41 75 74 6f 6c 6f 61 64 3b 0a 0a 63 6c 61 73 73 20 43 6f 6d 70 6f 73 | Composer\Autoload;..class.Compos |
7cc0 | 65 72 53 74 61 74 69 63 49 6e 69 74 39 39 34 62 38 64 38 37 30 64 64 62 39 32 33 65 62 63 33 66 | erStaticInit994b8d870ddb923ebc3f |
7ce0 | 66 30 63 65 61 61 61 61 39 36 61 36 0a 7b 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 | f0ceaaaa96a6.{.....public.static |
7d00 | 20 24 66 69 6c 65 73 20 3d 20 61 72 72 61 79 20 28 0a 20 20 20 20 20 20 20 20 27 30 65 36 64 37 | .$files.=.array.(.........'0e6d7 |
7d20 | 62 66 34 61 35 38 31 31 62 66 61 35 63 66 34 30 63 35 63 63 64 36 66 61 65 36 61 27 20 3d 3e 20 | bf4a5811bfa5cf40c5ccd6fae6a'.=>. |
7d40 | 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 70 6f 6c 79 | __DIR__...'/..'...'/symfony/poly |
7d60 | 66 69 6c 6c 2d 6d 62 73 74 72 69 6e 67 2f 62 6f 6f 74 73 74 72 61 70 2e 70 68 70 27 2c 0a 20 20 | fill-mbstring/bootstrap.php',... |
7d80 | 20 20 29 3b 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 24 70 72 65 66 69 78 4c | ..);......public.static.$prefixL |
7da0 | 65 6e 67 74 68 73 50 73 72 34 20 3d 20 61 72 72 61 79 20 28 0a 20 20 20 20 20 20 20 20 27 53 27 | engthsPsr4.=.array.(.........'S' |
7dc0 | 20 3d 3e 20 0a 20 20 20 20 20 20 20 20 61 72 72 61 79 20 28 0a 20 20 20 20 20 20 20 20 20 20 20 | .=>..........array.(............ |
7de0 | 20 27 53 79 6d 66 6f 6e 79 5c 5c 50 6f 6c 79 66 69 6c 6c 5c 5c 4d 62 73 74 72 69 6e 67 5c 5c 27 | .'Symfony\\Polyfill\\Mbstring\\' |
7e00 | 20 3d 3e 20 32 36 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f | .=>.26,.............'Symfony\\Co |
7e20 | 6d 70 6f 6e 65 6e 74 5c 5c 44 65 62 75 67 5c 5c 27 20 3d 3e 20 32 34 2c 0a 20 20 20 20 20 20 20 | mponent\\Debug\\'.=>.24,........ |
7e40 | 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c | .....'Symfony\\Component\\Consol |
7e60 | 65 5c 5c 27 20 3d 3e 20 32 36 2c 0a 20 20 20 20 20 20 20 20 29 2c 0a 20 20 20 20 20 20 20 20 27 | e\\'.=>.26,.........),.........' |
7e80 | 50 27 20 3d 3e 20 0a 20 20 20 20 20 20 20 20 61 72 72 61 79 20 28 0a 20 20 20 20 20 20 20 20 20 | P'.=>..........array.(.......... |
7ea0 | 20 20 20 27 50 73 72 5c 5c 4c 6f 67 5c 5c 27 20 3d 3e 20 38 2c 0a 20 20 20 20 20 20 20 20 29 2c | ...'Psr\\Log\\'.=>.8,.........), |
7ec0 | 0a 20 20 20 20 20 20 20 20 27 4e 27 20 3d 3e 20 0a 20 20 20 20 20 20 20 20 61 72 72 61 79 20 28 | .........'N'.=>..........array.( |
7ee0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 4e 43 5c 5c 55 70 64 61 74 65 72 5c 5c 27 20 3d 3e 20 | .............'NC\\Updater\\'.=>. |
7f00 | 31 31 2c 0a 20 20 20 20 20 20 20 20 29 2c 0a 20 20 20 20 29 3b 0a 0a 20 20 20 20 70 75 62 6c 69 | 11,.........),.....);......publi |
7f20 | 63 20 73 74 61 74 69 63 20 24 70 72 65 66 69 78 44 69 72 73 50 73 72 34 20 3d 20 61 72 72 61 79 | c.static.$prefixDirsPsr4.=.array |
7f40 | 20 28 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 50 6f 6c 79 66 69 6c 6c 5c 5c 4d | .(.........'Symfony\\Polyfill\\M |
7f60 | 62 73 74 72 69 6e 67 5c 5c 27 20 3d 3e 20 0a 20 20 20 20 20 20 20 20 61 72 72 61 79 20 28 0a 20 | bstring\\'.=>..........array.(.. |
7f80 | 20 20 20 20 20 20 20 20 20 20 20 30 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 | ...........0.=>.__DIR__...'/..'. |
7fa0 | 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 70 6f 6c 79 66 69 6c 6c 2d 6d 62 73 74 72 69 6e 67 27 2c 0a | ..'/symfony/polyfill-mbstring',. |
7fc0 | 20 20 20 20 20 20 20 20 29 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d | ........),.........'Symfony\\Com |
7fe0 | 70 6f 6e 65 6e 74 5c 5c 44 65 62 75 67 5c 5c 27 20 3d 3e 20 0a 20 20 20 20 20 20 20 20 61 72 72 | ponent\\Debug\\'.=>..........arr |
8000 | 61 79 20 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 30 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 | ay.(.............0.=>.__DIR__... |
8020 | 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 64 65 62 75 67 27 2c 0a 20 20 20 20 20 20 | '/..'...'/symfony/debug',....... |
8040 | 20 20 29 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 | ..),.........'Symfony\\Component |
8060 | 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 27 20 3d 3e 20 0a 20 20 20 20 20 20 20 20 61 72 72 61 79 20 28 | \\Console\\'.=>..........array.( |
8080 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 30 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e | .............0.=>.__DIR__...'/.. |
80a0 | 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 27 2c 0a 20 20 20 20 20 20 20 20 | '...'/symfony/console',......... |
80c0 | 29 2c 0a 20 20 20 20 20 20 20 20 27 50 73 72 5c 5c 4c 6f 67 5c 5c 27 20 3d 3e 20 0a 20 20 20 20 | ),.........'Psr\\Log\\'.=>...... |
80e0 | 20 20 20 20 61 72 72 61 79 20 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 30 20 3d 3e 20 5f 5f 44 | ....array.(.............0.=>.__D |
8100 | 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 70 73 72 2f 6c 6f 67 2f 50 73 72 2f 4c 6f 67 | IR__...'/..'...'/psr/log/Psr/Log |
8120 | 27 2c 0a 20 20 20 20 20 20 20 20 29 2c 0a 20 20 20 20 20 20 20 20 27 4e 43 5c 5c 55 70 64 61 74 | ',.........),.........'NC\\Updat |
8140 | 65 72 5c 5c 27 20 3d 3e 20 0a 20 20 20 20 20 20 20 20 61 72 72 61 79 20 28 0a 20 20 20 20 20 20 | er\\'.=>..........array.(....... |
8160 | 20 20 20 20 20 20 30 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 2f 2e 2e 27 20 2e 20 | ......0.=>.__DIR__...'/../..'... |
8180 | 27 2f 6c 69 62 27 2c 0a 20 20 20 20 20 20 20 20 29 2c 0a 20 20 20 20 29 3b 0a 0a 20 20 20 20 70 | '/lib',.........),.....);......p |
81a0 | 75 62 6c 69 63 20 73 74 61 74 69 63 20 24 63 6c 61 73 73 4d 61 70 20 3d 20 61 72 72 61 79 20 28 | ublic.static.$classMap.=.array.( |
81c0 | 0a 20 20 20 20 20 20 20 20 27 43 6f 6d 70 6f 73 65 72 5c 5c 49 6e 73 74 61 6c 6c 65 64 56 65 72 | .........'Composer\\InstalledVer |
81e0 | 73 69 6f 6e 73 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 63 6f | sions'.=>.__DIR__...'/..'...'/co |
8200 | 6d 70 6f 73 65 72 2f 49 6e 73 74 61 6c 6c 65 64 56 65 72 73 69 6f 6e 73 2e 70 68 70 27 2c 0a 20 | mposer/InstalledVersions.php',.. |
8220 | 20 20 20 20 20 20 20 27 4e 43 5c 5c 55 70 64 61 74 65 72 5c 5c 43 6f 6d 6d 61 6e 64 41 70 70 6c | .......'NC\\Updater\\CommandAppl |
8240 | 69 63 61 74 69 6f 6e 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 2f 2e 2e 27 20 2e | ication'.=>.__DIR__...'/../..'.. |
8260 | 20 27 2f 6c 69 62 2f 43 6f 6d 6d 61 6e 64 41 70 70 6c 69 63 61 74 69 6f 6e 2e 70 68 70 27 2c 0a | .'/lib/CommandApplication.php',. |
8280 | 20 20 20 20 20 20 20 20 27 4e 43 5c 5c 55 70 64 61 74 65 72 5c 5c 4c 6f 67 45 78 63 65 70 74 69 | ........'NC\\Updater\\LogExcepti |
82a0 | 6f 6e 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 2f 2e 2e 27 20 2e 20 27 2f 6c 69 | on'.=>.__DIR__...'/../..'...'/li |
82c0 | 62 2f 4c 6f 67 45 78 63 65 70 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 4e 43 | b/LogException.php',.........'NC |
82e0 | 5c 5c 55 70 64 61 74 65 72 5c 5c 52 65 63 75 72 73 69 76 65 44 69 72 65 63 74 6f 72 79 49 74 65 | \\Updater\\RecursiveDirectoryIte |
8300 | 72 61 74 6f 72 57 69 74 68 6f 75 74 44 61 74 61 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 | ratorWithoutData'.=>.__DIR__...' |
8320 | 2f 2e 2e 2f 2e 2e 27 20 2e 20 27 2f 6c 69 62 2f 52 65 63 75 72 73 69 76 65 44 69 72 65 63 74 6f | /../..'...'/lib/RecursiveDirecto |
8340 | 72 79 49 74 65 72 61 74 6f 72 57 69 74 68 6f 75 74 44 61 74 61 2e 70 68 70 27 2c 0a 20 20 20 20 | ryIteratorWithoutData.php',..... |
8360 | 20 20 20 20 27 4e 43 5c 5c 55 70 64 61 74 65 72 5c 5c 55 70 64 61 74 65 43 6f 6d 6d 61 6e 64 27 | ....'NC\\Updater\\UpdateCommand' |
8380 | 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 2f 2e 2e 27 20 2e 20 27 2f 6c 69 62 2f 55 | .=>.__DIR__...'/../..'...'/lib/U |
83a0 | 70 64 61 74 65 43 6f 6d 6d 61 6e 64 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 4e 43 5c 5c | pdateCommand.php',.........'NC\\ |
83c0 | 55 70 64 61 74 65 72 5c 5c 55 70 64 61 74 65 45 78 63 65 70 74 69 6f 6e 27 20 3d 3e 20 5f 5f 44 | Updater\\UpdateException'.=>.__D |
83e0 | 49 52 5f 5f 20 2e 20 27 2f 2e 2e 2f 2e 2e 27 20 2e 20 27 2f 6c 69 62 2f 55 70 64 61 74 65 45 78 | IR__...'/../..'...'/lib/UpdateEx |
8400 | 63 65 70 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 4e 43 5c 5c 55 70 64 61 74 | ception.php',.........'NC\\Updat |
8420 | 65 72 5c 5c 55 70 64 61 74 65 72 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 2f 2e | er\\Updater'.=>.__DIR__...'/../. |
8440 | 2e 27 20 2e 20 27 2f 6c 69 62 2f 55 70 64 61 74 65 72 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 | .'...'/lib/Updater.php',........ |
8460 | 20 27 4e 43 5c 5c 55 70 64 61 74 65 72 5c 5c 56 65 72 73 69 6f 6e 27 20 3d 3e 20 5f 5f 44 49 52 | .'NC\\Updater\\Version'.=>.__DIR |
8480 | 5f 5f 20 2e 20 27 2f 2e 2e 2f 2e 2e 27 20 2e 20 27 2f 6c 69 62 2f 56 65 72 73 69 6f 6e 2e 70 68 | __...'/../..'...'/lib/Version.ph |
84a0 | 70 27 2c 0a 20 20 20 20 20 20 20 20 27 50 73 72 5c 5c 4c 6f 67 5c 5c 41 62 73 74 72 61 63 74 4c | p',.........'Psr\\Log\\AbstractL |
84c0 | 6f 67 67 65 72 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 70 73 | ogger'.=>.__DIR__...'/..'...'/ps |
84e0 | 72 2f 6c 6f 67 2f 50 73 72 2f 4c 6f 67 2f 41 62 73 74 72 61 63 74 4c 6f 67 67 65 72 2e 70 68 70 | r/log/Psr/Log/AbstractLogger.php |
8500 | 27 2c 0a 20 20 20 20 20 20 20 20 27 50 73 72 5c 5c 4c 6f 67 5c 5c 49 6e 76 61 6c 69 64 41 72 67 | ',.........'Psr\\Log\\InvalidArg |
8520 | 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e | umentException'.=>.__DIR__...'/. |
8540 | 2e 27 20 2e 20 27 2f 70 73 72 2f 6c 6f 67 2f 50 73 72 2f 4c 6f 67 2f 49 6e 76 61 6c 69 64 41 72 | .'...'/psr/log/Psr/Log/InvalidAr |
8560 | 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 50 | gumentException.php',.........'P |
8580 | 73 72 5c 5c 4c 6f 67 5c 5c 4c 6f 67 4c 65 76 65 6c 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 | sr\\Log\\LogLevel'.=>.__DIR__... |
85a0 | 27 2f 2e 2e 27 20 2e 20 27 2f 70 73 72 2f 6c 6f 67 2f 50 73 72 2f 4c 6f 67 2f 4c 6f 67 4c 65 76 | '/..'...'/psr/log/Psr/Log/LogLev |
85c0 | 65 6c 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 50 73 72 5c 5c 4c 6f 67 5c 5c 4c 6f 67 67 | el.php',.........'Psr\\Log\\Logg |
85e0 | 65 72 41 77 61 72 65 49 6e 74 65 72 66 61 63 65 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 | erAwareInterface'.=>.__DIR__...' |
8600 | 2f 2e 2e 27 20 2e 20 27 2f 70 73 72 2f 6c 6f 67 2f 50 73 72 2f 4c 6f 67 2f 4c 6f 67 67 65 72 41 | /..'...'/psr/log/Psr/Log/LoggerA |
8620 | 77 61 72 65 49 6e 74 65 72 66 61 63 65 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 50 73 72 | wareInterface.php',.........'Psr |
8640 | 5c 5c 4c 6f 67 5c 5c 4c 6f 67 67 65 72 41 77 61 72 65 54 72 61 69 74 27 20 3d 3e 20 5f 5f 44 49 | \\Log\\LoggerAwareTrait'.=>.__DI |
8660 | 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 70 73 72 2f 6c 6f 67 2f 50 73 72 2f 4c 6f 67 2f | R__...'/..'...'/psr/log/Psr/Log/ |
8680 | 4c 6f 67 67 65 72 41 77 61 72 65 54 72 61 69 74 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 | LoggerAwareTrait.php',.........' |
86a0 | 50 73 72 5c 5c 4c 6f 67 5c 5c 4c 6f 67 67 65 72 49 6e 74 65 72 66 61 63 65 27 20 3d 3e 20 5f 5f | Psr\\Log\\LoggerInterface'.=>.__ |
86c0 | 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 70 73 72 2f 6c 6f 67 2f 50 73 72 2f 4c 6f | DIR__...'/..'...'/psr/log/Psr/Lo |
86e0 | 67 2f 4c 6f 67 67 65 72 49 6e 74 65 72 66 61 63 65 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 | g/LoggerInterface.php',......... |
8700 | 27 50 73 72 5c 5c 4c 6f 67 5c 5c 4c 6f 67 67 65 72 54 72 61 69 74 27 20 3d 3e 20 5f 5f 44 49 52 | 'Psr\\Log\\LoggerTrait'.=>.__DIR |
8720 | 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 70 73 72 2f 6c 6f 67 2f 50 73 72 2f 4c 6f 67 2f 4c | __...'/..'...'/psr/log/Psr/Log/L |
8740 | 6f 67 67 65 72 54 72 61 69 74 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 50 73 72 5c 5c 4c | oggerTrait.php',.........'Psr\\L |
8760 | 6f 67 5c 5c 4e 75 6c 6c 4c 6f 67 67 65 72 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e | og\\NullLogger'.=>.__DIR__...'/. |
8780 | 2e 27 20 2e 20 27 2f 70 73 72 2f 6c 6f 67 2f 50 73 72 2f 4c 6f 67 2f 4e 75 6c 6c 4c 6f 67 67 65 | .'...'/psr/log/Psr/Log/NullLogge |
87a0 | 72 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 50 73 72 5c 5c 4c 6f 67 5c 5c 54 65 73 74 5c | r.php',.........'Psr\\Log\\Test\ |
87c0 | 5c 4c 6f 67 67 65 72 49 6e 74 65 72 66 61 63 65 54 65 73 74 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f | \LoggerInterfaceTest'.=>.__DIR__ |
87e0 | 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 70 73 72 2f 6c 6f 67 2f 50 73 72 2f 4c 6f 67 2f 54 65 73 | ...'/..'...'/psr/log/Psr/Log/Tes |
8800 | 74 2f 4c 6f 67 67 65 72 49 6e 74 65 72 66 61 63 65 54 65 73 74 2e 70 68 70 27 2c 0a 20 20 20 20 | t/LoggerInterfaceTest.php',..... |
8820 | 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 | ....'Symfony\\Component\\Console |
8840 | 5c 5c 41 70 70 6c 69 63 61 74 69 6f 6e 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e | \\Application'.=>.__DIR__...'/.. |
8860 | 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 41 70 70 6c 69 63 61 74 69 6f | '...'/symfony/console/Applicatio |
8880 | 6e 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e | n.php',.........'Symfony\\Compon |
88a0 | 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 43 6f 6d 6d 61 6e 64 5c 5c 43 6f 6d 6d 61 6e 64 27 20 | ent\\Console\\Command\\Command'. |
88c0 | 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 | =>.__DIR__...'/..'...'/symfony/c |
88e0 | 6f 6e 73 6f 6c 65 2f 43 6f 6d 6d 61 6e 64 2f 43 6f 6d 6d 61 6e 64 2e 70 68 70 27 2c 0a 20 20 20 | onsole/Command/Command.php',.... |
8900 | 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c | .....'Symfony\\Component\\Consol |
8920 | 65 5c 5c 43 6f 6d 6d 61 6e 64 5c 5c 48 65 6c 70 43 6f 6d 6d 61 6e 64 27 20 3d 3e 20 5f 5f 44 49 | e\\Command\\HelpCommand'.=>.__DI |
8940 | 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f | R__...'/..'...'/symfony/console/ |
8960 | 43 6f 6d 6d 61 6e 64 2f 48 65 6c 70 43 6f 6d 6d 61 6e 64 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 | Command/HelpCommand.php',....... |
8980 | 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c | ..'Symfony\\Component\\Console\\ |
89a0 | 43 6f 6d 6d 61 6e 64 5c 5c 4c 69 73 74 43 6f 6d 6d 61 6e 64 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f | Command\\ListCommand'.=>.__DIR__ |
89c0 | 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 43 6f 6d | ...'/..'...'/symfony/console/Com |
89e0 | 6d 61 6e 64 2f 4c 69 73 74 43 6f 6d 6d 61 6e 64 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 | mand/ListCommand.php',.........' |
8a00 | 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 43 6f 6e | Symfony\\Component\\Console\\Con |
8a20 | 73 6f 6c 65 45 76 65 6e 74 73 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e | soleEvents'.=>.__DIR__...'/..'.. |
8a40 | 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 43 6f 6e 73 6f 6c 65 45 76 65 6e 74 73 | .'/symfony/console/ConsoleEvents |
8a60 | 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 | .php',.........'Symfony\\Compone |
8a80 | 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 44 65 73 63 72 69 70 74 6f 72 5c 5c 41 70 70 6c 69 63 61 | nt\\Console\\Descriptor\\Applica |
8aa0 | 74 69 6f 6e 44 65 73 63 72 69 70 74 69 6f 6e 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f | tionDescription'.=>.__DIR__...'/ |
8ac0 | 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 44 65 73 63 72 69 70 74 | ..'...'/symfony/console/Descript |
8ae0 | 6f 72 2f 41 70 70 6c 69 63 61 74 69 6f 6e 44 65 73 63 72 69 70 74 69 6f 6e 2e 70 68 70 27 2c 0a | or/ApplicationDescription.php',. |
8b00 | 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e | ........'Symfony\\Component\\Con |
8b20 | 73 6f 6c 65 5c 5c 44 65 73 63 72 69 70 74 6f 72 5c 5c 44 65 73 63 72 69 70 74 6f 72 27 20 3d 3e | sole\\Descriptor\\Descriptor'.=> |
8b40 | 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e | .__DIR__...'/..'...'/symfony/con |
8b60 | 73 6f 6c 65 2f 44 65 73 63 72 69 70 74 6f 72 2f 44 65 73 63 72 69 70 74 6f 72 2e 70 68 70 27 2c | sole/Descriptor/Descriptor.php', |
8b80 | 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f | .........'Symfony\\Component\\Co |
8ba0 | 6e 73 6f 6c 65 5c 5c 44 65 73 63 72 69 70 74 6f 72 5c 5c 44 65 73 63 72 69 70 74 6f 72 49 6e 74 | nsole\\Descriptor\\DescriptorInt |
8bc0 | 65 72 66 61 63 65 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 | erface'.=>.__DIR__...'/..'...'/s |
8be0 | 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 44 65 73 63 72 69 70 74 6f 72 2f 44 65 73 63 72 69 | ymfony/console/Descriptor/Descri |
8c00 | 70 74 6f 72 49 6e 74 65 72 66 61 63 65 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d | ptorInterface.php',.........'Sym |
8c20 | 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 44 65 73 63 72 69 | fony\\Component\\Console\\Descri |
8c40 | 70 74 6f 72 5c 5c 4a 73 6f 6e 44 65 73 63 72 69 70 74 6f 72 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f | ptor\\JsonDescriptor'.=>.__DIR__ |
8c60 | 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 44 65 73 | ...'/..'...'/symfony/console/Des |
8c80 | 63 72 69 70 74 6f 72 2f 4a 73 6f 6e 44 65 73 63 72 69 70 74 6f 72 2e 70 68 70 27 2c 0a 20 20 20 | criptor/JsonDescriptor.php',.... |
8ca0 | 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c | .....'Symfony\\Component\\Consol |
8cc0 | 65 5c 5c 44 65 73 63 72 69 70 74 6f 72 5c 5c 4d 61 72 6b 64 6f 77 6e 44 65 73 63 72 69 70 74 6f | e\\Descriptor\\MarkdownDescripto |
8ce0 | 72 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e | r'.=>.__DIR__...'/..'...'/symfon |
8d00 | 79 2f 63 6f 6e 73 6f 6c 65 2f 44 65 73 63 72 69 70 74 6f 72 2f 4d 61 72 6b 64 6f 77 6e 44 65 73 | y/console/Descriptor/MarkdownDes |
8d20 | 63 72 69 70 74 6f 72 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c | criptor.php',.........'Symfony\\ |
8d40 | 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 44 65 73 63 72 69 70 74 6f 72 5c 5c | Component\\Console\\Descriptor\\ |
8d60 | 54 65 78 74 44 65 73 63 72 69 70 74 6f 72 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e | TextDescriptor'.=>.__DIR__...'/. |
8d80 | 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 44 65 73 63 72 69 70 74 6f | .'...'/symfony/console/Descripto |
8da0 | 72 2f 54 65 78 74 44 65 73 63 72 69 70 74 6f 72 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 | r/TextDescriptor.php',.........' |
8dc0 | 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 44 65 73 | Symfony\\Component\\Console\\Des |
8de0 | 63 72 69 70 74 6f 72 5c 5c 58 6d 6c 44 65 73 63 72 69 70 74 6f 72 27 20 3d 3e 20 5f 5f 44 49 52 | criptor\\XmlDescriptor'.=>.__DIR |
8e00 | 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 44 | __...'/..'...'/symfony/console/D |
8e20 | 65 73 63 72 69 70 74 6f 72 2f 58 6d 6c 44 65 73 63 72 69 70 74 6f 72 2e 70 68 70 27 2c 0a 20 20 | escriptor/XmlDescriptor.php',... |
8e40 | 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f | ......'Symfony\\Component\\Conso |
8e60 | 6c 65 5c 5c 45 76 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 43 6f 6d 6d 61 6e 64 45 76 65 6e 74 27 20 | le\\Event\\ConsoleCommandEvent'. |
8e80 | 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 | =>.__DIR__...'/..'...'/symfony/c |
8ea0 | 6f 6e 73 6f 6c 65 2f 45 76 65 6e 74 2f 43 6f 6e 73 6f 6c 65 43 6f 6d 6d 61 6e 64 45 76 65 6e 74 | onsole/Event/ConsoleCommandEvent |
8ec0 | 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 | .php',.........'Symfony\\Compone |
8ee0 | 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 45 76 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 45 76 65 6e 74 | nt\\Console\\Event\\ConsoleEvent |
8f00 | 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 | '.=>.__DIR__...'/..'...'/symfony |
8f20 | 2f 63 6f 6e 73 6f 6c 65 2f 45 76 65 6e 74 2f 43 6f 6e 73 6f 6c 65 45 76 65 6e 74 2e 70 68 70 27 | /console/Event/ConsoleEvent.php' |
8f40 | 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 | ,.........'Symfony\\Component\\C |
8f60 | 6f 6e 73 6f 6c 65 5c 5c 45 76 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 45 78 63 65 70 74 69 6f 6e 45 | onsole\\Event\\ConsoleExceptionE |
8f80 | 76 65 6e 74 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d | vent'.=>.__DIR__...'/..'...'/sym |
8fa0 | 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 45 76 65 6e 74 2f 43 6f 6e 73 6f 6c 65 45 78 63 65 70 74 | fony/console/Event/ConsoleExcept |
8fc0 | 69 6f 6e 45 76 65 6e 74 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c | ionEvent.php',.........'Symfony\ |
8fe0 | 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 45 76 65 6e 74 5c 5c 43 6f 6e 73 | \Component\\Console\\Event\\Cons |
9000 | 6f 6c 65 54 65 72 6d 69 6e 61 74 65 45 76 65 6e 74 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 | oleTerminateEvent'.=>.__DIR__... |
9020 | 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 45 76 65 6e 74 2f | '/..'...'/symfony/console/Event/ |
9040 | 43 6f 6e 73 6f 6c 65 54 65 72 6d 69 6e 61 74 65 45 76 65 6e 74 2e 70 68 70 27 2c 0a 20 20 20 20 | ConsoleTerminateEvent.php',..... |
9060 | 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 | ....'Symfony\\Component\\Console |
9080 | 5c 5c 45 78 63 65 70 74 69 6f 6e 5c 5c 43 6f 6d 6d 61 6e 64 4e 6f 74 46 6f 75 6e 64 45 78 63 65 | \\Exception\\CommandNotFoundExce |
90a0 | 70 74 69 6f 6e 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 | ption'.=>.__DIR__...'/..'...'/sy |
90c0 | 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 45 78 63 65 70 74 69 6f 6e 2f 43 6f 6d 6d 61 6e 64 4e | mfony/console/Exception/CommandN |
90e0 | 6f 74 46 6f 75 6e 64 45 78 63 65 70 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 | otFoundException.php',.........' |
9100 | 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 45 78 63 | Symfony\\Component\\Console\\Exc |
9120 | 65 70 74 69 6f 6e 5c 5c 45 78 63 65 70 74 69 6f 6e 49 6e 74 65 72 66 61 63 65 27 20 3d 3e 20 5f | eption\\ExceptionInterface'.=>._ |
9140 | 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f | _DIR__...'/..'...'/symfony/conso |
9160 | 6c 65 2f 45 78 63 65 70 74 69 6f 6e 2f 45 78 63 65 70 74 69 6f 6e 49 6e 74 65 72 66 61 63 65 2e | le/Exception/ExceptionInterface. |
9180 | 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e | php',.........'Symfony\\Componen |
91a0 | 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 45 78 63 65 70 74 69 6f 6e 5c 5c 49 6e 76 61 6c 69 64 41 72 | t\\Console\\Exception\\InvalidAr |
91c0 | 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f | gumentException'.=>.__DIR__...'/ |
91e0 | 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 45 78 63 65 70 74 69 6f | ..'...'/symfony/console/Exceptio |
9200 | 6e 2f 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 2e 70 68 70 27 2c | n/InvalidArgumentException.php', |
9220 | 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f | .........'Symfony\\Component\\Co |
9240 | 6e 73 6f 6c 65 5c 5c 45 78 63 65 70 74 69 6f 6e 5c 5c 49 6e 76 61 6c 69 64 4f 70 74 69 6f 6e 45 | nsole\\Exception\\InvalidOptionE |
9260 | 78 63 65 70 74 69 6f 6e 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 | xception'.=>.__DIR__...'/..'...' |
9280 | 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 45 78 63 65 70 74 69 6f 6e 2f 49 6e 76 61 6c | /symfony/console/Exception/Inval |
92a0 | 69 64 4f 70 74 69 6f 6e 45 78 63 65 70 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 | idOptionException.php',......... |
92c0 | 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 45 78 | 'Symfony\\Component\\Console\\Ex |
92e0 | 63 65 70 74 69 6f 6e 5c 5c 4c 6f 67 69 63 45 78 63 65 70 74 69 6f 6e 27 20 3d 3e 20 5f 5f 44 49 | ception\\LogicException'.=>.__DI |
9300 | 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f | R__...'/..'...'/symfony/console/ |
9320 | 45 78 63 65 70 74 69 6f 6e 2f 4c 6f 67 69 63 45 78 63 65 70 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 | Exception/LogicException.php',.. |
9340 | 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 | .......'Symfony\\Component\\Cons |
9360 | 6f 6c 65 5c 5c 45 78 63 65 70 74 69 6f 6e 5c 5c 52 75 6e 74 69 6d 65 45 78 63 65 70 74 69 6f 6e | ole\\Exception\\RuntimeException |
9380 | 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 | '.=>.__DIR__...'/..'...'/symfony |
93a0 | 2f 63 6f 6e 73 6f 6c 65 2f 45 78 63 65 70 74 69 6f 6e 2f 52 75 6e 74 69 6d 65 45 78 63 65 70 74 | /console/Exception/RuntimeExcept |
93c0 | 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 | ion.php',.........'Symfony\\Comp |
93e0 | 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 46 6f 72 6d 61 74 74 65 72 5c 5c 4f 75 74 70 75 | onent\\Console\\Formatter\\Outpu |
9400 | 74 46 6f 72 6d 61 74 74 65 72 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e | tFormatter'.=>.__DIR__...'/..'.. |
9420 | 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 46 6f 72 6d 61 74 74 65 72 2f 4f 75 74 | .'/symfony/console/Formatter/Out |
9440 | 70 75 74 46 6f 72 6d 61 74 74 65 72 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 | putFormatter.php',.........'Symf |
9460 | 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 46 6f 72 6d 61 74 74 | ony\\Component\\Console\\Formatt |
9480 | 65 72 5c 5c 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 49 6e 74 65 72 66 61 63 65 27 20 3d 3e | er\\OutputFormatterInterface'.=> |
94a0 | 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e | .__DIR__...'/..'...'/symfony/con |
94c0 | 73 6f 6c 65 2f 46 6f 72 6d 61 74 74 65 72 2f 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 49 6e | sole/Formatter/OutputFormatterIn |
94e0 | 74 65 72 66 61 63 65 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c | terface.php',.........'Symfony\\ |
9500 | 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 46 6f 72 6d 61 74 74 65 72 5c 5c 4f | Component\\Console\\Formatter\\O |
9520 | 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c 65 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 | utputFormatterStyle'.=>.__DIR__. |
9540 | 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 46 6f 72 6d | ..'/..'...'/symfony/console/Form |
9560 | 61 74 74 65 72 2f 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c 65 2e 70 68 70 27 2c | atter/OutputFormatterStyle.php', |
9580 | 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f | .........'Symfony\\Component\\Co |
95a0 | 6e 73 6f 6c 65 5c 5c 46 6f 72 6d 61 74 74 65 72 5c 5c 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 | nsole\\Formatter\\OutputFormatte |
95c0 | 72 53 74 79 6c 65 49 6e 74 65 72 66 61 63 65 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f | rStyleInterface'.=>.__DIR__...'/ |
95e0 | 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 46 6f 72 6d 61 74 74 65 | ..'...'/symfony/console/Formatte |
9600 | 72 2f 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c 65 49 6e 74 65 72 66 61 63 65 2e | r/OutputFormatterStyleInterface. |
9620 | 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e | php',.........'Symfony\\Componen |
9640 | 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 46 6f 72 6d 61 74 74 65 72 5c 5c 4f 75 74 70 75 74 46 6f 72 | t\\Console\\Formatter\\OutputFor |
9660 | 6d 61 74 74 65 72 53 74 79 6c 65 53 74 61 63 6b 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 | matterStyleStack'.=>.__DIR__...' |
9680 | 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 46 6f 72 6d 61 74 74 | /..'...'/symfony/console/Formatt |
96a0 | 65 72 2f 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c 65 53 74 61 63 6b 2e 70 68 70 | er/OutputFormatterStyleStack.php |
96c0 | 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c | ',.........'Symfony\\Component\\ |
96e0 | 43 6f 6e 73 6f 6c 65 5c 5c 48 65 6c 70 65 72 5c 5c 44 65 62 75 67 46 6f 72 6d 61 74 74 65 72 48 | Console\\Helper\\DebugFormatterH |
9700 | 65 6c 70 65 72 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 | elper'.=>.__DIR__...'/..'...'/sy |
9720 | 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 48 65 6c 70 65 72 2f 44 65 62 75 67 46 6f 72 6d 61 74 | mfony/console/Helper/DebugFormat |
9740 | 74 65 72 48 65 6c 70 65 72 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 | terHelper.php',.........'Symfony |
9760 | 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 48 65 6c 70 65 72 5c 5c 44 65 | \\Component\\Console\\Helper\\De |
9780 | 73 63 72 69 70 74 6f 72 48 65 6c 70 65 72 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e | scriptorHelper'.=>.__DIR__...'/. |
97a0 | 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 48 65 6c 70 65 72 2f 44 65 | .'...'/symfony/console/Helper/De |
97c0 | 73 63 72 69 70 74 6f 72 48 65 6c 70 65 72 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 | scriptorHelper.php',.........'Sy |
97e0 | 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 48 65 6c 70 65 | mfony\\Component\\Console\\Helpe |
9800 | 72 5c 5c 46 6f 72 6d 61 74 74 65 72 48 65 6c 70 65 72 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e | r\\FormatterHelper'.=>.__DIR__.. |
9820 | 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 48 65 6c 70 65 | .'/..'...'/symfony/console/Helpe |
9840 | 72 2f 46 6f 72 6d 61 74 74 65 72 48 65 6c 70 65 72 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 | r/FormatterHelper.php',......... |
9860 | 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 48 65 | 'Symfony\\Component\\Console\\He |
9880 | 6c 70 65 72 5c 5c 48 65 6c 70 65 72 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 | lper\\Helper'.=>.__DIR__...'/..' |
98a0 | 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 48 65 6c 70 65 72 2f 48 65 6c 70 | ...'/symfony/console/Helper/Help |
98c0 | 65 72 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f | er.php',.........'Symfony\\Compo |
98e0 | 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 48 65 6c 70 65 72 5c 5c 48 65 6c 70 65 72 49 6e 74 | nent\\Console\\Helper\\HelperInt |
9900 | 65 72 66 61 63 65 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 | erface'.=>.__DIR__...'/..'...'/s |
9920 | 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 48 65 6c 70 65 72 2f 48 65 6c 70 65 72 49 6e 74 65 | ymfony/console/Helper/HelperInte |
9940 | 72 66 61 63 65 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f | rface.php',.........'Symfony\\Co |
9960 | 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 48 65 6c 70 65 72 5c 5c 48 65 6c 70 65 72 | mponent\\Console\\Helper\\Helper |
9980 | 53 65 74 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 | Set'.=>.__DIR__...'/..'...'/symf |
99a0 | 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 48 65 6c 70 65 72 2f 48 65 6c 70 65 72 53 65 74 2e 70 68 70 | ony/console/Helper/HelperSet.php |
99c0 | 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c | ',.........'Symfony\\Component\\ |
99e0 | 43 6f 6e 73 6f 6c 65 5c 5c 48 65 6c 70 65 72 5c 5c 49 6e 70 75 74 41 77 61 72 65 48 65 6c 70 65 | Console\\Helper\\InputAwareHelpe |
9a00 | 72 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e | r'.=>.__DIR__...'/..'...'/symfon |
9a20 | 79 2f 63 6f 6e 73 6f 6c 65 2f 48 65 6c 70 65 72 2f 49 6e 70 75 74 41 77 61 72 65 48 65 6c 70 65 | y/console/Helper/InputAwareHelpe |
9a40 | 72 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e | r.php',.........'Symfony\\Compon |
9a60 | 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 48 65 6c 70 65 72 5c 5c 50 72 6f 63 65 73 73 48 65 6c | ent\\Console\\Helper\\ProcessHel |
9a80 | 70 65 72 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 | per'.=>.__DIR__...'/..'...'/symf |
9aa0 | 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 48 65 6c 70 65 72 2f 50 72 6f 63 65 73 73 48 65 6c 70 65 72 | ony/console/Helper/ProcessHelper |
9ac0 | 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 | .php',.........'Symfony\\Compone |
9ae0 | 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 48 65 6c 70 65 72 5c 5c 50 72 6f 67 72 65 73 73 42 61 72 | nt\\Console\\Helper\\ProgressBar |
9b00 | 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 | '.=>.__DIR__...'/..'...'/symfony |
9b20 | 2f 63 6f 6e 73 6f 6c 65 2f 48 65 6c 70 65 72 2f 50 72 6f 67 72 65 73 73 42 61 72 2e 70 68 70 27 | /console/Helper/ProgressBar.php' |
9b40 | 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 | ,.........'Symfony\\Component\\C |
9b60 | 6f 6e 73 6f 6c 65 5c 5c 48 65 6c 70 65 72 5c 5c 50 72 6f 67 72 65 73 73 49 6e 64 69 63 61 74 6f | onsole\\Helper\\ProgressIndicato |
9b80 | 72 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e | r'.=>.__DIR__...'/..'...'/symfon |
9ba0 | 79 2f 63 6f 6e 73 6f 6c 65 2f 48 65 6c 70 65 72 2f 50 72 6f 67 72 65 73 73 49 6e 64 69 63 61 74 | y/console/Helper/ProgressIndicat |
9bc0 | 6f 72 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f | or.php',.........'Symfony\\Compo |
9be0 | 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 48 65 6c 70 65 72 5c 5c 51 75 65 73 74 69 6f 6e 48 | nent\\Console\\Helper\\QuestionH |
9c00 | 65 6c 70 65 72 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 | elper'.=>.__DIR__...'/..'...'/sy |
9c20 | 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 48 65 6c 70 65 72 2f 51 75 65 73 74 69 6f 6e 48 65 6c | mfony/console/Helper/QuestionHel |
9c40 | 70 65 72 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 | per.php',.........'Symfony\\Comp |
9c60 | 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 48 65 6c 70 65 72 5c 5c 53 79 6d 66 6f 6e 79 51 | onent\\Console\\Helper\\SymfonyQ |
9c80 | 75 65 73 74 69 6f 6e 48 65 6c 70 65 72 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e | uestionHelper'.=>.__DIR__...'/.. |
9ca0 | 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 48 65 6c 70 65 72 2f 53 79 6d | '...'/symfony/console/Helper/Sym |
9cc0 | 66 6f 6e 79 51 75 65 73 74 69 6f 6e 48 65 6c 70 65 72 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 | fonyQuestionHelper.php',........ |
9ce0 | 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 48 | .'Symfony\\Component\\Console\\H |
9d00 | 65 6c 70 65 72 5c 5c 54 61 62 6c 65 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 | elper\\Table'.=>.__DIR__...'/..' |
9d20 | 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 48 65 6c 70 65 72 2f 54 61 62 6c | ...'/symfony/console/Helper/Tabl |
9d40 | 65 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e | e.php',.........'Symfony\\Compon |
9d60 | 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 48 65 6c 70 65 72 5c 5c 54 61 62 6c 65 43 65 6c 6c 27 | ent\\Console\\Helper\\TableCell' |
9d80 | 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f | .=>.__DIR__...'/..'...'/symfony/ |
9da0 | 63 6f 6e 73 6f 6c 65 2f 48 65 6c 70 65 72 2f 54 61 62 6c 65 43 65 6c 6c 2e 70 68 70 27 2c 0a 20 | console/Helper/TableCell.php',.. |
9dc0 | 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 | .......'Symfony\\Component\\Cons |
9de0 | 6f 6c 65 5c 5c 48 65 6c 70 65 72 5c 5c 54 61 62 6c 65 53 65 70 61 72 61 74 6f 72 27 20 3d 3e 20 | ole\\Helper\\TableSeparator'.=>. |
9e00 | 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 | __DIR__...'/..'...'/symfony/cons |
9e20 | 6f 6c 65 2f 48 65 6c 70 65 72 2f 54 61 62 6c 65 53 65 70 61 72 61 74 6f 72 2e 70 68 70 27 2c 0a | ole/Helper/TableSeparator.php',. |
9e40 | 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e | ........'Symfony\\Component\\Con |
9e60 | 73 6f 6c 65 5c 5c 48 65 6c 70 65 72 5c 5c 54 61 62 6c 65 53 74 79 6c 65 27 20 3d 3e 20 5f 5f 44 | sole\\Helper\\TableStyle'.=>.__D |
9e80 | 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 | IR__...'/..'...'/symfony/console |
9ea0 | 2f 48 65 6c 70 65 72 2f 54 61 62 6c 65 53 74 79 6c 65 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 | /Helper/TableStyle.php',........ |
9ec0 | 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 49 | .'Symfony\\Component\\Console\\I |
9ee0 | 6e 70 75 74 5c 5c 41 72 67 76 49 6e 70 75 74 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f | nput\\ArgvInput'.=>.__DIR__...'/ |
9f00 | 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 49 6e 70 75 74 2f 41 72 | ..'...'/symfony/console/Input/Ar |
9f20 | 67 76 49 6e 70 75 74 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c | gvInput.php',.........'Symfony\\ |
9f40 | 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 49 6e 70 75 74 5c 5c 41 72 72 61 79 | Component\\Console\\Input\\Array |
9f60 | 49 6e 70 75 74 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 | Input'.=>.__DIR__...'/..'...'/sy |
9f80 | 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 49 6e 70 75 74 2f 41 72 72 61 79 49 6e 70 75 74 2e 70 | mfony/console/Input/ArrayInput.p |
9fa0 | 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 | hp',.........'Symfony\\Component |
9fc0 | 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 49 6e 70 75 74 5c 5c 49 6e 70 75 74 27 20 3d 3e 20 5f 5f 44 49 | \\Console\\Input\\Input'.=>.__DI |
9fe0 | 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f | R__...'/..'...'/symfony/console/ |
a000 | 49 6e 70 75 74 2f 49 6e 70 75 74 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f | Input/Input.php',.........'Symfo |
a020 | 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 49 6e 70 75 74 5c 5c 49 | ny\\Component\\Console\\Input\\I |
a040 | 6e 70 75 74 41 72 67 75 6d 65 6e 74 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 | nputArgument'.=>.__DIR__...'/..' |
a060 | 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 49 6e 70 75 74 2f 49 6e 70 75 74 | ...'/symfony/console/Input/Input |
a080 | 41 72 67 75 6d 65 6e 74 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c | Argument.php',.........'Symfony\ |
a0a0 | 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 49 6e 70 75 74 5c 5c 49 6e 70 75 | \Component\\Console\\Input\\Inpu |
a0c0 | 74 41 77 61 72 65 49 6e 74 65 72 66 61 63 65 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f | tAwareInterface'.=>.__DIR__...'/ |
a0e0 | 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 49 6e 70 75 74 2f 49 6e | ..'...'/symfony/console/Input/In |
a100 | 70 75 74 41 77 61 72 65 49 6e 74 65 72 66 61 63 65 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 | putAwareInterface.php',......... |
a120 | 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 49 6e | 'Symfony\\Component\\Console\\In |
a140 | 70 75 74 5c 5c 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f | put\\InputDefinition'.=>.__DIR__ |
a160 | 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 49 6e 70 | ...'/..'...'/symfony/console/Inp |
a180 | 75 74 2f 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 | ut/InputDefinition.php',........ |
a1a0 | 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 49 | .'Symfony\\Component\\Console\\I |
a1c0 | 6e 70 75 74 5c 5c 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f | nput\\InputInterface'.=>.__DIR__ |
a1e0 | 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 49 6e 70 | ...'/..'...'/symfony/console/Inp |
a200 | 75 74 2f 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 | ut/InputInterface.php',......... |
a220 | 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 49 6e | 'Symfony\\Component\\Console\\In |
a240 | 70 75 74 5c 5c 49 6e 70 75 74 4f 70 74 69 6f 6e 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 | put\\InputOption'.=>.__DIR__...' |
a260 | 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 49 6e 70 75 74 2f 49 | /..'...'/symfony/console/Input/I |
a280 | 6e 70 75 74 4f 70 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e | nputOption.php',.........'Symfon |
a2a0 | 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 49 6e 70 75 74 5c 5c 53 74 | y\\Component\\Console\\Input\\St |
a2c0 | 72 69 6e 67 49 6e 70 75 74 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 | ringInput'.=>.__DIR__...'/..'... |
a2e0 | 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 49 6e 70 75 74 2f 53 74 72 69 6e 67 49 6e | '/symfony/console/Input/StringIn |
a300 | 70 75 74 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 | put.php',.........'Symfony\\Comp |
a320 | 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 4c 6f 67 67 65 72 5c 5c 43 6f 6e 73 6f 6c 65 4c | onent\\Console\\Logger\\ConsoleL |
a340 | 6f 67 67 65 72 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 | ogger'.=>.__DIR__...'/..'...'/sy |
a360 | 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 4c 6f 67 67 65 72 2f 43 6f 6e 73 6f 6c 65 4c 6f 67 67 | mfony/console/Logger/ConsoleLogg |
a380 | 65 72 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f | er.php',.........'Symfony\\Compo |
a3a0 | 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 4f 75 74 70 75 74 5c 5c 42 75 66 66 65 72 65 64 4f | nent\\Console\\Output\\BufferedO |
a3c0 | 75 74 70 75 74 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 | utput'.=>.__DIR__...'/..'...'/sy |
a3e0 | 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 4f 75 74 70 75 74 2f 42 75 66 66 65 72 65 64 4f 75 74 | mfony/console/Output/BufferedOut |
a400 | 70 75 74 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 | put.php',.........'Symfony\\Comp |
a420 | 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 4f 75 74 70 75 74 5c 5c 43 6f 6e 73 6f 6c 65 4f | onent\\Console\\Output\\ConsoleO |
a440 | 75 74 70 75 74 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 | utput'.=>.__DIR__...'/..'...'/sy |
a460 | 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 4f 75 74 70 75 74 2f 43 6f 6e 73 6f 6c 65 4f 75 74 70 | mfony/console/Output/ConsoleOutp |
a480 | 75 74 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f | ut.php',.........'Symfony\\Compo |
a4a0 | 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 4f 75 74 70 75 74 5c 5c 43 6f 6e 73 6f 6c 65 4f 75 | nent\\Console\\Output\\ConsoleOu |
a4c0 | 74 70 75 74 49 6e 74 65 72 66 61 63 65 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e | tputInterface'.=>.__DIR__...'/.. |
a4e0 | 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 4f 75 74 70 75 74 2f 43 6f 6e | '...'/symfony/console/Output/Con |
a500 | 73 6f 6c 65 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 | soleOutputInterface.php',....... |
a520 | 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c | ..'Symfony\\Component\\Console\\ |
a540 | 4f 75 74 70 75 74 5c 5c 4e 75 6c 6c 4f 75 74 70 75 74 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e | Output\\NullOutput'.=>.__DIR__.. |
a560 | 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 4f 75 74 70 75 | .'/..'...'/symfony/console/Outpu |
a580 | 74 2f 4e 75 6c 6c 4f 75 74 70 75 74 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 | t/NullOutput.php',.........'Symf |
a5a0 | 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 4f 75 74 70 75 74 5c | ony\\Component\\Console\\Output\ |
a5c0 | 5c 4f 75 74 70 75 74 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f | \Output'.=>.__DIR__...'/..'...'/ |
a5e0 | 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 4f 75 74 70 75 74 2f 4f 75 74 70 75 74 2e 70 68 | symfony/console/Output/Output.ph |
a600 | 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c | p',.........'Symfony\\Component\ |
a620 | 5c 43 6f 6e 73 6f 6c 65 5c 5c 4f 75 74 70 75 74 5c 5c 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 | \Console\\Output\\OutputInterfac |
a640 | 65 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e | e'.=>.__DIR__...'/..'...'/symfon |
a660 | 79 2f 63 6f 6e 73 6f 6c 65 2f 4f 75 74 70 75 74 2f 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 | y/console/Output/OutputInterface |
a680 | 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 | .php',.........'Symfony\\Compone |
a6a0 | 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 4f 75 74 70 75 74 5c 5c 53 74 72 65 61 6d 4f 75 74 70 75 | nt\\Console\\Output\\StreamOutpu |
a6c0 | 74 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e | t'.=>.__DIR__...'/..'...'/symfon |
a6e0 | 79 2f 63 6f 6e 73 6f 6c 65 2f 4f 75 74 70 75 74 2f 53 74 72 65 61 6d 4f 75 74 70 75 74 2e 70 68 | y/console/Output/StreamOutput.ph |
a700 | 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c | p',.........'Symfony\\Component\ |
a720 | 5c 43 6f 6e 73 6f 6c 65 5c 5c 51 75 65 73 74 69 6f 6e 5c 5c 43 68 6f 69 63 65 51 75 65 73 74 69 | \Console\\Question\\ChoiceQuesti |
a740 | 6f 6e 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f | on'.=>.__DIR__...'/..'...'/symfo |
a760 | 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 51 75 65 73 74 69 6f 6e 2f 43 68 6f 69 63 65 51 75 65 73 74 69 | ny/console/Question/ChoiceQuesti |
a780 | 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f | on.php',.........'Symfony\\Compo |
a7a0 | 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 51 75 65 73 74 69 6f 6e 5c 5c 43 6f 6e 66 69 72 6d | nent\\Console\\Question\\Confirm |
a7c0 | 61 74 69 6f 6e 51 75 65 73 74 69 6f 6e 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e | ationQuestion'.=>.__DIR__...'/.. |
a7e0 | 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 51 75 65 73 74 69 6f 6e 2f 43 | '...'/symfony/console/Question/C |
a800 | 6f 6e 66 69 72 6d 61 74 69 6f 6e 51 75 65 73 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 | onfirmationQuestion.php',....... |
a820 | 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c | ..'Symfony\\Component\\Console\\ |
a840 | 51 75 65 73 74 69 6f 6e 5c 5c 51 75 65 73 74 69 6f 6e 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e | Question\\Question'.=>.__DIR__.. |
a860 | 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 51 75 65 73 74 | .'/..'...'/symfony/console/Quest |
a880 | 69 6f 6e 2f 51 75 65 73 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 | ion/Question.php',.........'Symf |
a8a0 | 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 53 74 79 6c 65 5c 5c | ony\\Component\\Console\\Style\\ |
a8c0 | 4f 75 74 70 75 74 53 74 79 6c 65 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 | OutputStyle'.=>.__DIR__...'/..'. |
a8e0 | 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 53 74 79 6c 65 2f 4f 75 74 70 75 74 | ..'/symfony/console/Style/Output |
a900 | 53 74 79 6c 65 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f | Style.php',.........'Symfony\\Co |
a920 | 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 53 74 79 6c 65 5c 5c 53 74 79 6c 65 49 6e | mponent\\Console\\Style\\StyleIn |
a940 | 74 65 72 66 61 63 65 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f | terface'.=>.__DIR__...'/..'...'/ |
a960 | 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 53 74 79 6c 65 2f 53 74 79 6c 65 49 6e 74 65 72 | symfony/console/Style/StyleInter |
a980 | 66 61 63 65 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d | face.php',.........'Symfony\\Com |
a9a0 | 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 53 74 79 6c 65 5c 5c 53 79 6d 66 6f 6e 79 53 | ponent\\Console\\Style\\SymfonyS |
a9c0 | 74 79 6c 65 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d | tyle'.=>.__DIR__...'/..'...'/sym |
a9e0 | 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 53 74 79 6c 65 2f 53 79 6d 66 6f 6e 79 53 74 79 6c 65 2e | fony/console/Style/SymfonyStyle. |
aa00 | 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e | php',.........'Symfony\\Componen |
aa20 | 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 54 65 73 74 65 72 5c 5c 41 70 70 6c 69 63 61 74 69 6f 6e 54 | t\\Console\\Tester\\ApplicationT |
aa40 | 65 73 74 65 72 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 | ester'.=>.__DIR__...'/..'...'/sy |
aa60 | 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 54 65 73 74 65 72 2f 41 70 70 6c 69 63 61 74 69 6f 6e | mfony/console/Tester/Application |
aa80 | 54 65 73 74 65 72 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 | Tester.php',.........'Symfony\\C |
aaa0 | 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 54 65 73 74 65 72 5c 5c 43 6f 6d 6d 61 | omponent\\Console\\Tester\\Comma |
aac0 | 6e 64 54 65 73 74 65 72 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 | ndTester'.=>.__DIR__...'/..'...' |
aae0 | 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 54 65 73 74 65 72 2f 43 6f 6d 6d 61 6e 64 54 | /symfony/console/Tester/CommandT |
ab00 | 65 73 74 65 72 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f | ester.php',.........'Symfony\\Co |
ab20 | 6d 70 6f 6e 65 6e 74 5c 5c 44 65 62 75 67 5c 5c 42 75 66 66 65 72 69 6e 67 4c 6f 67 67 65 72 27 | mponent\\Debug\\BufferingLogger' |
ab40 | 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f | .=>.__DIR__...'/..'...'/symfony/ |
ab60 | 64 65 62 75 67 2f 42 75 66 66 65 72 69 6e 67 4c 6f 67 67 65 72 2e 70 68 70 27 2c 0a 20 20 20 20 | debug/BufferingLogger.php',..... |
ab80 | 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 44 65 62 75 67 5c 5c | ....'Symfony\\Component\\Debug\\ |
aba0 | 44 65 62 75 67 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 | Debug'.=>.__DIR__...'/..'...'/sy |
abc0 | 6d 66 6f 6e 79 2f 64 65 62 75 67 2f 44 65 62 75 67 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 | mfony/debug/Debug.php',......... |
abe0 | 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 44 65 62 75 67 5c 5c 44 65 62 75 | 'Symfony\\Component\\Debug\\Debu |
ac00 | 67 43 6c 61 73 73 4c 6f 61 64 65 72 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 | gClassLoader'.=>.__DIR__...'/..' |
ac20 | 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 64 65 62 75 67 2f 44 65 62 75 67 43 6c 61 73 73 4c 6f 61 | ...'/symfony/debug/DebugClassLoa |
ac40 | 64 65 72 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 | der.php',.........'Symfony\\Comp |
ac60 | 6f 6e 65 6e 74 5c 5c 44 65 62 75 67 5c 5c 45 72 72 6f 72 48 61 6e 64 6c 65 72 27 20 3d 3e 20 5f | onent\\Debug\\ErrorHandler'.=>._ |
ac80 | 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 64 65 62 75 67 | _DIR__...'/..'...'/symfony/debug |
aca0 | 2f 45 72 72 6f 72 48 61 6e 64 6c 65 72 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d | /ErrorHandler.php',.........'Sym |
acc0 | 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 44 65 62 75 67 5c 5c 45 78 63 65 70 74 69 6f | fony\\Component\\Debug\\Exceptio |
ace0 | 6e 48 61 6e 64 6c 65 72 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 | nHandler'.=>.__DIR__...'/..'...' |
ad00 | 2f 73 79 6d 66 6f 6e 79 2f 64 65 62 75 67 2f 45 78 63 65 70 74 69 6f 6e 48 61 6e 64 6c 65 72 2e | /symfony/debug/ExceptionHandler. |
ad20 | 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e | php',.........'Symfony\\Componen |
ad40 | 74 5c 5c 44 65 62 75 67 5c 5c 45 78 63 65 70 74 69 6f 6e 5c 5c 43 6c 61 73 73 4e 6f 74 46 6f 75 | t\\Debug\\Exception\\ClassNotFou |
ad60 | 6e 64 45 78 63 65 70 74 69 6f 6e 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 | ndException'.=>.__DIR__...'/..'. |
ad80 | 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 64 65 62 75 67 2f 45 78 63 65 70 74 69 6f 6e 2f 43 6c 61 73 | ..'/symfony/debug/Exception/Clas |
ada0 | 73 4e 6f 74 46 6f 75 6e 64 45 78 63 65 70 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 | sNotFoundException.php',........ |
adc0 | 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 44 65 62 75 67 5c 5c 45 78 63 | .'Symfony\\Component\\Debug\\Exc |
ade0 | 65 70 74 69 6f 6e 5c 5c 43 6f 6e 74 65 78 74 45 72 72 6f 72 45 78 63 65 70 74 69 6f 6e 27 20 3d | eption\\ContextErrorException'.= |
ae00 | 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 64 65 | >.__DIR__...'/..'...'/symfony/de |
ae20 | 62 75 67 2f 45 78 63 65 70 74 69 6f 6e 2f 43 6f 6e 74 65 78 74 45 72 72 6f 72 45 78 63 65 70 74 | bug/Exception/ContextErrorExcept |
ae40 | 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 | ion.php',.........'Symfony\\Comp |
ae60 | 6f 6e 65 6e 74 5c 5c 44 65 62 75 67 5c 5c 45 78 63 65 70 74 69 6f 6e 5c 5c 46 61 74 61 6c 45 72 | onent\\Debug\\Exception\\FatalEr |
ae80 | 72 6f 72 45 78 63 65 70 74 69 6f 6e 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 | rorException'.=>.__DIR__...'/..' |
aea0 | 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 64 65 62 75 67 2f 45 78 63 65 70 74 69 6f 6e 2f 46 61 74 | ...'/symfony/debug/Exception/Fat |
aec0 | 61 6c 45 72 72 6f 72 45 78 63 65 70 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 | alErrorException.php',.........' |
aee0 | 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 44 65 62 75 67 5c 5c 45 78 63 65 70 | Symfony\\Component\\Debug\\Excep |
af00 | 74 69 6f 6e 5c 5c 46 61 74 61 6c 54 68 72 6f 77 61 62 6c 65 45 72 72 6f 72 27 20 3d 3e 20 5f 5f | tion\\FatalThrowableError'.=>.__ |
af20 | 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 64 65 62 75 67 2f | DIR__...'/..'...'/symfony/debug/ |
af40 | 45 78 63 65 70 74 69 6f 6e 2f 46 61 74 61 6c 54 68 72 6f 77 61 62 6c 65 45 72 72 6f 72 2e 70 68 | Exception/FatalThrowableError.ph |
af60 | 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c | p',.........'Symfony\\Component\ |
af80 | 5c 44 65 62 75 67 5c 5c 45 78 63 65 70 74 69 6f 6e 5c 5c 46 6c 61 74 74 65 6e 45 78 63 65 70 74 | \Debug\\Exception\\FlattenExcept |
afa0 | 69 6f 6e 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 | ion'.=>.__DIR__...'/..'...'/symf |
afc0 | 6f 6e 79 2f 64 65 62 75 67 2f 45 78 63 65 70 74 69 6f 6e 2f 46 6c 61 74 74 65 6e 45 78 63 65 70 | ony/debug/Exception/FlattenExcep |
afe0 | 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d | tion.php',.........'Symfony\\Com |
b000 | 70 6f 6e 65 6e 74 5c 5c 44 65 62 75 67 5c 5c 45 78 63 65 70 74 69 6f 6e 5c 5c 4f 75 74 4f 66 4d | ponent\\Debug\\Exception\\OutOfM |
b020 | 65 6d 6f 72 79 45 78 63 65 70 74 69 6f 6e 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e | emoryException'.=>.__DIR__...'/. |
b040 | 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 64 65 62 75 67 2f 45 78 63 65 70 74 69 6f 6e 2f 4f | .'...'/symfony/debug/Exception/O |
b060 | 75 74 4f 66 4d 65 6d 6f 72 79 45 78 63 65 70 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 | utOfMemoryException.php',....... |
b080 | 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 44 65 62 75 67 5c 5c 45 78 | ..'Symfony\\Component\\Debug\\Ex |
b0a0 | 63 65 70 74 69 6f 6e 5c 5c 55 6e 64 65 66 69 6e 65 64 46 75 6e 63 74 69 6f 6e 45 78 63 65 70 74 | ception\\UndefinedFunctionExcept |
b0c0 | 69 6f 6e 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 | ion'.=>.__DIR__...'/..'...'/symf |
b0e0 | 6f 6e 79 2f 64 65 62 75 67 2f 45 78 63 65 70 74 69 6f 6e 2f 55 6e 64 65 66 69 6e 65 64 46 75 6e | ony/debug/Exception/UndefinedFun |
b100 | 63 74 69 6f 6e 45 78 63 65 70 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 | ctionException.php',.........'Sy |
b120 | 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 44 65 62 75 67 5c 5c 45 78 63 65 70 74 69 | mfony\\Component\\Debug\\Excepti |
b140 | 6f 6e 5c 5c 55 6e 64 65 66 69 6e 65 64 4d 65 74 68 6f 64 45 78 63 65 70 74 69 6f 6e 27 20 3d 3e | on\\UndefinedMethodException'.=> |
b160 | 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 64 65 62 | .__DIR__...'/..'...'/symfony/deb |
b180 | 75 67 2f 45 78 63 65 70 74 69 6f 6e 2f 55 6e 64 65 66 69 6e 65 64 4d 65 74 68 6f 64 45 78 63 65 | ug/Exception/UndefinedMethodExce |
b1a0 | 70 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f | ption.php',.........'Symfony\\Co |
b1c0 | 6d 70 6f 6e 65 6e 74 5c 5c 44 65 62 75 67 5c 5c 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 | mponent\\Debug\\FatalErrorHandle |
b1e0 | 72 5c 5c 43 6c 61 73 73 4e 6f 74 46 6f 75 6e 64 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 | r\\ClassNotFoundFatalErrorHandle |
b200 | 72 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e | r'.=>.__DIR__...'/..'...'/symfon |
b220 | 79 2f 64 65 62 75 67 2f 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 2f 43 6c 61 73 73 4e | y/debug/FatalErrorHandler/ClassN |
b240 | 6f 74 46 6f 75 6e 64 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 2e 70 68 70 27 2c 0a 20 | otFoundFatalErrorHandler.php',.. |
b260 | 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 44 65 62 75 | .......'Symfony\\Component\\Debu |
b280 | 67 5c 5c 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 5c 5c 46 61 74 61 6c 45 72 72 6f 72 | g\\FatalErrorHandler\\FatalError |
b2a0 | 48 61 6e 64 6c 65 72 49 6e 74 65 72 66 61 63 65 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 | HandlerInterface'.=>.__DIR__...' |
b2c0 | 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 64 65 62 75 67 2f 46 61 74 61 6c 45 72 72 6f | /..'...'/symfony/debug/FatalErro |
b2e0 | 72 48 61 6e 64 6c 65 72 2f 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 49 6e 74 65 72 66 | rHandler/FatalErrorHandlerInterf |
b300 | 61 63 65 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 | ace.php',.........'Symfony\\Comp |
b320 | 6f 6e 65 6e 74 5c 5c 44 65 62 75 67 5c 5c 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 5c | onent\\Debug\\FatalErrorHandler\ |
b340 | 5c 55 6e 64 65 66 69 6e 65 64 46 75 6e 63 74 69 6f 6e 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 | \UndefinedFunctionFatalErrorHand |
b360 | 6c 65 72 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 | ler'.=>.__DIR__...'/..'...'/symf |
b380 | 6f 6e 79 2f 64 65 62 75 67 2f 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 2f 55 6e 64 65 | ony/debug/FatalErrorHandler/Unde |
b3a0 | 66 69 6e 65 64 46 75 6e 63 74 69 6f 6e 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 2e 70 | finedFunctionFatalErrorHandler.p |
b3c0 | 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 | hp',.........'Symfony\\Component |
b3e0 | 5c 5c 44 65 62 75 67 5c 5c 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 5c 5c 55 6e 64 65 | \\Debug\\FatalErrorHandler\\Unde |
b400 | 66 69 6e 65 64 4d 65 74 68 6f 64 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 27 20 3d 3e | finedMethodFatalErrorHandler'.=> |
b420 | 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 64 65 62 | .__DIR__...'/..'...'/symfony/deb |
b440 | 75 67 2f 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 2f 55 6e 64 65 66 69 6e 65 64 4d 65 | ug/FatalErrorHandler/UndefinedMe |
b460 | 74 68 6f 64 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 2e 70 68 70 27 2c 0a 20 20 20 20 | thodFatalErrorHandler.php',..... |
b480 | 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 50 6f 6c 79 66 69 6c 6c 5c 5c 4d 62 73 74 72 69 6e 67 | ....'Symfony\\Polyfill\\Mbstring |
b4a0 | 5c 5c 4d 62 73 74 72 69 6e 67 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e | \\Mbstring'.=>.__DIR__...'/..'.. |
b4c0 | 20 27 2f 73 79 6d 66 6f 6e 79 2f 70 6f 6c 79 66 69 6c 6c 2d 6d 62 73 74 72 69 6e 67 2f 4d 62 73 | .'/symfony/polyfill-mbstring/Mbs |
b4e0 | 74 72 69 6e 67 2e 70 68 70 27 2c 0a 20 20 20 20 29 3b 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 73 | tring.php',.....);......public.s |
b500 | 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 49 6e 69 74 69 61 6c 69 7a 65 72 28 43 6c | tatic.function.getInitializer(Cl |
b520 | 61 73 73 4c 6f 61 64 65 72 20 24 6c 6f 61 64 65 72 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 | assLoader.$loader).....{........ |
b540 | 20 72 65 74 75 72 6e 20 5c 43 6c 6f 73 75 72 65 3a 3a 62 69 6e 64 28 66 75 6e 63 74 69 6f 6e 20 | .return.\Closure::bind(function. |
b560 | 28 29 20 75 73 65 20 28 24 6c 6f 61 64 65 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 | ().use.($loader).{.............$ |
b580 | 6c 6f 61 64 65 72 2d 3e 70 72 65 66 69 78 4c 65 6e 67 74 68 73 50 73 72 34 20 3d 20 43 6f 6d 70 | loader->prefixLengthsPsr4.=.Comp |
b5a0 | 6f 73 65 72 53 74 61 74 69 63 49 6e 69 74 39 39 34 62 38 64 38 37 30 64 64 62 39 32 33 65 62 63 | oserStaticInit994b8d870ddb923ebc |
b5c0 | 33 66 66 30 63 65 61 61 61 61 39 36 61 36 3a 3a 24 70 72 65 66 69 78 4c 65 6e 67 74 68 73 50 73 | 3ff0ceaaaa96a6::$prefixLengthsPs |
b5e0 | 72 34 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 6f 61 64 65 72 2d 3e 70 72 65 66 69 78 44 | r4;.............$loader->prefixD |
b600 | 69 72 73 50 73 72 34 20 3d 20 43 6f 6d 70 6f 73 65 72 53 74 61 74 69 63 49 6e 69 74 39 39 34 62 | irsPsr4.=.ComposerStaticInit994b |
b620 | 38 64 38 37 30 64 64 62 39 32 33 65 62 63 33 66 66 30 63 65 61 61 61 61 39 36 61 36 3a 3a 24 70 | 8d870ddb923ebc3ff0ceaaaa96a6::$p |
b640 | 72 65 66 69 78 44 69 72 73 50 73 72 34 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 6f 61 64 | refixDirsPsr4;.............$load |
b660 | 65 72 2d 3e 63 6c 61 73 73 4d 61 70 20 3d 20 43 6f 6d 70 6f 73 65 72 53 74 61 74 69 63 49 6e 69 | er->classMap.=.ComposerStaticIni |
b680 | 74 39 39 34 62 38 64 38 37 30 64 64 62 39 32 33 65 62 63 33 66 66 30 63 65 61 61 61 61 39 36 61 | t994b8d870ddb923ebc3ff0ceaaaa96a |
b6a0 | 36 3a 3a 24 63 6c 61 73 73 4d 61 70 3b 0a 0a 20 20 20 20 20 20 20 20 7d 2c 20 6e 75 6c 6c 2c 20 | 6::$classMap;..........},.null,. |
b6c0 | 43 6c 61 73 73 4c 6f 61 64 65 72 3a 3a 63 6c 61 73 73 29 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 | ClassLoader::class);.....}.}.<?p |
b6e0 | 68 70 0a 0a 2f 2f 20 61 75 74 6f 6c 6f 61 64 5f 63 6c 61 73 73 6d 61 70 2e 70 68 70 20 40 67 65 | hp..//.autoload_classmap.php.@ge |
b700 | 6e 65 72 61 74 65 64 20 62 79 20 43 6f 6d 70 6f 73 65 72 0a 0a 24 76 65 6e 64 6f 72 44 69 72 20 | nerated.by.Composer..$vendorDir. |
b720 | 3d 20 64 69 72 6e 61 6d 65 28 64 69 72 6e 61 6d 65 28 5f 5f 46 49 4c 45 5f 5f 29 29 3b 0a 24 62 | =.dirname(dirname(__FILE__));.$b |
b740 | 61 73 65 44 69 72 20 3d 20 64 69 72 6e 61 6d 65 28 24 76 65 6e 64 6f 72 44 69 72 29 3b 0a 0a 72 | aseDir.=.dirname($vendorDir);..r |
b760 | 65 74 75 72 6e 20 61 72 72 61 79 28 0a 20 20 20 20 27 43 6f 6d 70 6f 73 65 72 5c 5c 49 6e 73 74 | eturn.array(.....'Composer\\Inst |
b780 | 61 6c 6c 65 64 56 65 72 73 69 6f 6e 73 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 | alledVersions'.=>.$vendorDir...' |
b7a0 | 2f 63 6f 6d 70 6f 73 65 72 2f 49 6e 73 74 61 6c 6c 65 64 56 65 72 73 69 6f 6e 73 2e 70 68 70 27 | /composer/InstalledVersions.php' |
b7c0 | 2c 0a 20 20 20 20 27 4e 43 5c 5c 55 70 64 61 74 65 72 5c 5c 43 6f 6d 6d 61 6e 64 41 70 70 6c 69 | ,.....'NC\\Updater\\CommandAppli |
b7e0 | 63 61 74 69 6f 6e 27 20 3d 3e 20 24 62 61 73 65 44 69 72 20 2e 20 27 2f 6c 69 62 2f 43 6f 6d 6d | cation'.=>.$baseDir...'/lib/Comm |
b800 | 61 6e 64 41 70 70 6c 69 63 61 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 27 4e 43 5c 5c 55 70 | andApplication.php',.....'NC\\Up |
b820 | 64 61 74 65 72 5c 5c 4c 6f 67 45 78 63 65 70 74 69 6f 6e 27 20 3d 3e 20 24 62 61 73 65 44 69 72 | dater\\LogException'.=>.$baseDir |
b840 | 20 2e 20 27 2f 6c 69 62 2f 4c 6f 67 45 78 63 65 70 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 | ...'/lib/LogException.php',..... |
b860 | 27 4e 43 5c 5c 55 70 64 61 74 65 72 5c 5c 52 65 63 75 72 73 69 76 65 44 69 72 65 63 74 6f 72 79 | 'NC\\Updater\\RecursiveDirectory |
b880 | 49 74 65 72 61 74 6f 72 57 69 74 68 6f 75 74 44 61 74 61 27 20 3d 3e 20 24 62 61 73 65 44 69 72 | IteratorWithoutData'.=>.$baseDir |
b8a0 | 20 2e 20 27 2f 6c 69 62 2f 52 65 63 75 72 73 69 76 65 44 69 72 65 63 74 6f 72 79 49 74 65 72 61 | ...'/lib/RecursiveDirectoryItera |
b8c0 | 74 6f 72 57 69 74 68 6f 75 74 44 61 74 61 2e 70 68 70 27 2c 0a 20 20 20 20 27 4e 43 5c 5c 55 70 | torWithoutData.php',.....'NC\\Up |
b8e0 | 64 61 74 65 72 5c 5c 55 70 64 61 74 65 43 6f 6d 6d 61 6e 64 27 20 3d 3e 20 24 62 61 73 65 44 69 | dater\\UpdateCommand'.=>.$baseDi |
b900 | 72 20 2e 20 27 2f 6c 69 62 2f 55 70 64 61 74 65 43 6f 6d 6d 61 6e 64 2e 70 68 70 27 2c 0a 20 20 | r...'/lib/UpdateCommand.php',... |
b920 | 20 20 27 4e 43 5c 5c 55 70 64 61 74 65 72 5c 5c 55 70 64 61 74 65 45 78 63 65 70 74 69 6f 6e 27 | ..'NC\\Updater\\UpdateException' |
b940 | 20 3d 3e 20 24 62 61 73 65 44 69 72 20 2e 20 27 2f 6c 69 62 2f 55 70 64 61 74 65 45 78 63 65 70 | .=>.$baseDir...'/lib/UpdateExcep |
b960 | 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 27 4e 43 5c 5c 55 70 64 61 74 65 72 5c 5c 55 70 64 | tion.php',.....'NC\\Updater\\Upd |
b980 | 61 74 65 72 27 20 3d 3e 20 24 62 61 73 65 44 69 72 20 2e 20 27 2f 6c 69 62 2f 55 70 64 61 74 65 | ater'.=>.$baseDir...'/lib/Update |
b9a0 | 72 2e 70 68 70 27 2c 0a 20 20 20 20 27 4e 43 5c 5c 55 70 64 61 74 65 72 5c 5c 56 65 72 73 69 6f | r.php',.....'NC\\Updater\\Versio |
b9c0 | 6e 27 20 3d 3e 20 24 62 61 73 65 44 69 72 20 2e 20 27 2f 6c 69 62 2f 56 65 72 73 69 6f 6e 2e 70 | n'.=>.$baseDir...'/lib/Version.p |
b9e0 | 68 70 27 2c 0a 20 20 20 20 27 50 73 72 5c 5c 4c 6f 67 5c 5c 41 62 73 74 72 61 63 74 4c 6f 67 67 | hp',.....'Psr\\Log\\AbstractLogg |
ba00 | 65 72 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 70 73 72 2f 6c 6f 67 2f 50 73 | er'.=>.$vendorDir...'/psr/log/Ps |
ba20 | 72 2f 4c 6f 67 2f 41 62 73 74 72 61 63 74 4c 6f 67 67 65 72 2e 70 68 70 27 2c 0a 20 20 20 20 27 | r/Log/AbstractLogger.php',.....' |
ba40 | 50 73 72 5c 5c 4c 6f 67 5c 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 | Psr\\Log\\InvalidArgumentExcepti |
ba60 | 6f 6e 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 70 73 72 2f 6c 6f 67 2f 50 73 | on'.=>.$vendorDir...'/psr/log/Ps |
ba80 | 72 2f 4c 6f 67 2f 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 2e 70 | r/Log/InvalidArgumentException.p |
baa0 | 68 70 27 2c 0a 20 20 20 20 27 50 73 72 5c 5c 4c 6f 67 5c 5c 4c 6f 67 4c 65 76 65 6c 27 20 3d 3e | hp',.....'Psr\\Log\\LogLevel'.=> |
bac0 | 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 70 73 72 2f 6c 6f 67 2f 50 73 72 2f 4c 6f 67 2f | .$vendorDir...'/psr/log/Psr/Log/ |
bae0 | 4c 6f 67 4c 65 76 65 6c 2e 70 68 70 27 2c 0a 20 20 20 20 27 50 73 72 5c 5c 4c 6f 67 5c 5c 4c 6f | LogLevel.php',.....'Psr\\Log\\Lo |
bb00 | 67 67 65 72 41 77 61 72 65 49 6e 74 65 72 66 61 63 65 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 | ggerAwareInterface'.=>.$vendorDi |
bb20 | 72 20 2e 20 27 2f 70 73 72 2f 6c 6f 67 2f 50 73 72 2f 4c 6f 67 2f 4c 6f 67 67 65 72 41 77 61 72 | r...'/psr/log/Psr/Log/LoggerAwar |
bb40 | 65 49 6e 74 65 72 66 61 63 65 2e 70 68 70 27 2c 0a 20 20 20 20 27 50 73 72 5c 5c 4c 6f 67 5c 5c | eInterface.php',.....'Psr\\Log\\ |
bb60 | 4c 6f 67 67 65 72 41 77 61 72 65 54 72 61 69 74 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 | LoggerAwareTrait'.=>.$vendorDir. |
bb80 | 2e 20 27 2f 70 73 72 2f 6c 6f 67 2f 50 73 72 2f 4c 6f 67 2f 4c 6f 67 67 65 72 41 77 61 72 65 54 | ..'/psr/log/Psr/Log/LoggerAwareT |
bba0 | 72 61 69 74 2e 70 68 70 27 2c 0a 20 20 20 20 27 50 73 72 5c 5c 4c 6f 67 5c 5c 4c 6f 67 67 65 72 | rait.php',.....'Psr\\Log\\Logger |
bbc0 | 49 6e 74 65 72 66 61 63 65 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 70 73 72 | Interface'.=>.$vendorDir...'/psr |
bbe0 | 2f 6c 6f 67 2f 50 73 72 2f 4c 6f 67 2f 4c 6f 67 67 65 72 49 6e 74 65 72 66 61 63 65 2e 70 68 70 | /log/Psr/Log/LoggerInterface.php |
bc00 | 27 2c 0a 20 20 20 20 27 50 73 72 5c 5c 4c 6f 67 5c 5c 4c 6f 67 67 65 72 54 72 61 69 74 27 20 3d | ',.....'Psr\\Log\\LoggerTrait'.= |
bc20 | 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 70 73 72 2f 6c 6f 67 2f 50 73 72 2f 4c 6f 67 | >.$vendorDir...'/psr/log/Psr/Log |
bc40 | 2f 4c 6f 67 67 65 72 54 72 61 69 74 2e 70 68 70 27 2c 0a 20 20 20 20 27 50 73 72 5c 5c 4c 6f 67 | /LoggerTrait.php',.....'Psr\\Log |
bc60 | 5c 5c 4e 75 6c 6c 4c 6f 67 67 65 72 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f | \\NullLogger'.=>.$vendorDir...'/ |
bc80 | 70 73 72 2f 6c 6f 67 2f 50 73 72 2f 4c 6f 67 2f 4e 75 6c 6c 4c 6f 67 67 65 72 2e 70 68 70 27 2c | psr/log/Psr/Log/NullLogger.php', |
bca0 | 0a 20 20 20 20 27 50 73 72 5c 5c 4c 6f 67 5c 5c 54 65 73 74 5c 5c 4c 6f 67 67 65 72 49 6e 74 65 | .....'Psr\\Log\\Test\\LoggerInte |
bcc0 | 72 66 61 63 65 54 65 73 74 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 70 73 72 | rfaceTest'.=>.$vendorDir...'/psr |
bce0 | 2f 6c 6f 67 2f 50 73 72 2f 4c 6f 67 2f 54 65 73 74 2f 4c 6f 67 67 65 72 49 6e 74 65 72 66 61 63 | /log/Psr/Log/Test/LoggerInterfac |
bd00 | 65 54 65 73 74 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e | eTest.php',.....'Symfony\\Compon |
bd20 | 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 41 70 70 6c 69 63 61 74 69 6f 6e 27 20 3d 3e 20 24 76 | ent\\Console\\Application'.=>.$v |
bd40 | 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 41 70 70 | endorDir...'/symfony/console/App |
bd60 | 6c 69 63 61 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d | lication.php',.....'Symfony\\Com |
bd80 | 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 43 6f 6d 6d 61 6e 64 5c 5c 43 6f 6d 6d 61 6e | ponent\\Console\\Command\\Comman |
bda0 | 64 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e | d'.=>.$vendorDir...'/symfony/con |
bdc0 | 73 6f 6c 65 2f 43 6f 6d 6d 61 6e 64 2f 43 6f 6d 6d 61 6e 64 2e 70 68 70 27 2c 0a 20 20 20 20 27 | sole/Command/Command.php',.....' |
bde0 | 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 43 6f 6d | Symfony\\Component\\Console\\Com |
be00 | 6d 61 6e 64 5c 5c 48 65 6c 70 43 6f 6d 6d 61 6e 64 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 | mand\\HelpCommand'.=>.$vendorDir |
be20 | 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 43 6f 6d 6d 61 6e 64 2f 48 65 6c | ...'/symfony/console/Command/Hel |
be40 | 70 43 6f 6d 6d 61 6e 64 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d | pCommand.php',.....'Symfony\\Com |
be60 | 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 43 6f 6d 6d 61 6e 64 5c 5c 4c 69 73 74 43 6f | ponent\\Console\\Command\\ListCo |
be80 | 6d 6d 61 6e 64 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 | mmand'.=>.$vendorDir...'/symfony |
bea0 | 2f 63 6f 6e 73 6f 6c 65 2f 43 6f 6d 6d 61 6e 64 2f 4c 69 73 74 43 6f 6d 6d 61 6e 64 2e 70 68 70 | /console/Command/ListCommand.php |
bec0 | 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 | ',.....'Symfony\\Component\\Cons |
bee0 | 6f 6c 65 5c 5c 43 6f 6e 73 6f 6c 65 45 76 65 6e 74 73 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 | ole\\ConsoleEvents'.=>.$vendorDi |
bf00 | 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 43 6f 6e 73 6f 6c 65 45 76 65 | r...'/symfony/console/ConsoleEve |
bf20 | 6e 74 73 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e | nts.php',.....'Symfony\\Componen |
bf40 | 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 44 65 73 63 72 69 70 74 6f 72 5c 5c 41 70 70 6c 69 63 61 74 | t\\Console\\Descriptor\\Applicat |
bf60 | 69 6f 6e 44 65 73 63 72 69 70 74 69 6f 6e 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 | ionDescription'.=>.$vendorDir... |
bf80 | 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 44 65 73 63 72 69 70 74 6f 72 2f 41 70 70 | '/symfony/console/Descriptor/App |
bfa0 | 6c 69 63 61 74 69 6f 6e 44 65 73 63 72 69 70 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 | licationDescription.php',.....'S |
bfc0 | 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 44 65 73 63 | ymfony\\Component\\Console\\Desc |
bfe0 | 72 69 70 74 6f 72 5c 5c 44 65 73 63 72 69 70 74 6f 72 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 | riptor\\Descriptor'.=>.$vendorDi |
c000 | 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 44 65 73 63 72 69 70 74 6f 72 | r...'/symfony/console/Descriptor |
c020 | 2f 44 65 73 63 72 69 70 74 6f 72 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c | /Descriptor.php',.....'Symfony\\ |
c040 | 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 44 65 73 63 72 69 70 74 6f 72 5c 5c | Component\\Console\\Descriptor\\ |
c060 | 44 65 73 63 72 69 70 74 6f 72 49 6e 74 65 72 66 61 63 65 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 | DescriptorInterface'.=>.$vendorD |
c080 | 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 44 65 73 63 72 69 70 74 6f | ir...'/symfony/console/Descripto |
c0a0 | 72 2f 44 65 73 63 72 69 70 74 6f 72 49 6e 74 65 72 66 61 63 65 2e 70 68 70 27 2c 0a 20 20 20 20 | r/DescriptorInterface.php',..... |
c0c0 | 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 44 65 | 'Symfony\\Component\\Console\\De |
c0e0 | 73 63 72 69 70 74 6f 72 5c 5c 4a 73 6f 6e 44 65 73 63 72 69 70 74 6f 72 27 20 3d 3e 20 24 76 65 | scriptor\\JsonDescriptor'.=>.$ve |
c100 | 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 44 65 73 63 | ndorDir...'/symfony/console/Desc |
c120 | 72 69 70 74 6f 72 2f 4a 73 6f 6e 44 65 73 63 72 69 70 74 6f 72 2e 70 68 70 27 2c 0a 20 20 20 20 | riptor/JsonDescriptor.php',..... |
c140 | 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 44 65 | 'Symfony\\Component\\Console\\De |
c160 | 73 63 72 69 70 74 6f 72 5c 5c 4d 61 72 6b 64 6f 77 6e 44 65 73 63 72 69 70 74 6f 72 27 20 3d 3e | scriptor\\MarkdownDescriptor'.=> |
c180 | 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f | .$vendorDir...'/symfony/console/ |
c1a0 | 44 65 73 63 72 69 70 74 6f 72 2f 4d 61 72 6b 64 6f 77 6e 44 65 73 63 72 69 70 74 6f 72 2e 70 68 | Descriptor/MarkdownDescriptor.ph |
c1c0 | 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e | p',.....'Symfony\\Component\\Con |
c1e0 | 73 6f 6c 65 5c 5c 44 65 73 63 72 69 70 74 6f 72 5c 5c 54 65 78 74 44 65 73 63 72 69 70 74 6f 72 | sole\\Descriptor\\TextDescriptor |
c200 | 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 | '.=>.$vendorDir...'/symfony/cons |
c220 | 6f 6c 65 2f 44 65 73 63 72 69 70 74 6f 72 2f 54 65 78 74 44 65 73 63 72 69 70 74 6f 72 2e 70 68 | ole/Descriptor/TextDescriptor.ph |
c240 | 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e | p',.....'Symfony\\Component\\Con |
c260 | 73 6f 6c 65 5c 5c 44 65 73 63 72 69 70 74 6f 72 5c 5c 58 6d 6c 44 65 73 63 72 69 70 74 6f 72 27 | sole\\Descriptor\\XmlDescriptor' |
c280 | 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f | .=>.$vendorDir...'/symfony/conso |
c2a0 | 6c 65 2f 44 65 73 63 72 69 70 74 6f 72 2f 58 6d 6c 44 65 73 63 72 69 70 74 6f 72 2e 70 68 70 27 | le/Descriptor/XmlDescriptor.php' |
c2c0 | 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f | ,.....'Symfony\\Component\\Conso |
c2e0 | 6c 65 5c 5c 45 76 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 43 6f 6d 6d 61 6e 64 45 76 65 6e 74 27 20 | le\\Event\\ConsoleCommandEvent'. |
c300 | 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c | =>.$vendorDir...'/symfony/consol |
c320 | 65 2f 45 76 65 6e 74 2f 43 6f 6e 73 6f 6c 65 43 6f 6d 6d 61 6e 64 45 76 65 6e 74 2e 70 68 70 27 | e/Event/ConsoleCommandEvent.php' |
c340 | 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f | ,.....'Symfony\\Component\\Conso |
c360 | 6c 65 5c 5c 45 76 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 45 76 65 6e 74 27 20 3d 3e 20 24 76 65 6e | le\\Event\\ConsoleEvent'.=>.$ven |
c380 | 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 45 76 65 6e 74 | dorDir...'/symfony/console/Event |
c3a0 | 2f 43 6f 6e 73 6f 6c 65 45 76 65 6e 74 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 | /ConsoleEvent.php',.....'Symfony |
c3c0 | 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 45 76 65 6e 74 5c 5c 43 6f 6e | \\Component\\Console\\Event\\Con |
c3e0 | 73 6f 6c 65 45 78 63 65 70 74 69 6f 6e 45 76 65 6e 74 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 | soleExceptionEvent'.=>.$vendorDi |
c400 | 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 45 76 65 6e 74 2f 43 6f 6e 73 | r...'/symfony/console/Event/Cons |
c420 | 6f 6c 65 45 78 63 65 70 74 69 6f 6e 45 76 65 6e 74 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d | oleExceptionEvent.php',.....'Sym |
c440 | 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 45 76 65 6e 74 5c | fony\\Component\\Console\\Event\ |
c460 | 5c 43 6f 6e 73 6f 6c 65 54 65 72 6d 69 6e 61 74 65 45 76 65 6e 74 27 20 3d 3e 20 24 76 65 6e 64 | \ConsoleTerminateEvent'.=>.$vend |
c480 | 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 45 76 65 6e 74 2f | orDir...'/symfony/console/Event/ |
c4a0 | 43 6f 6e 73 6f 6c 65 54 65 72 6d 69 6e 61 74 65 45 76 65 6e 74 2e 70 68 70 27 2c 0a 20 20 20 20 | ConsoleTerminateEvent.php',..... |
c4c0 | 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 45 78 | 'Symfony\\Component\\Console\\Ex |
c4e0 | 63 65 70 74 69 6f 6e 5c 5c 43 6f 6d 6d 61 6e 64 4e 6f 74 46 6f 75 6e 64 45 78 63 65 70 74 69 6f | ception\\CommandNotFoundExceptio |
c500 | 6e 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e | n'.=>.$vendorDir...'/symfony/con |
c520 | 73 6f 6c 65 2f 45 78 63 65 70 74 69 6f 6e 2f 43 6f 6d 6d 61 6e 64 4e 6f 74 46 6f 75 6e 64 45 78 | sole/Exception/CommandNotFoundEx |
c540 | 63 65 70 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 | ception.php',.....'Symfony\\Comp |
c560 | 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 45 78 63 65 70 74 69 6f 6e 5c 5c 45 78 63 65 70 | onent\\Console\\Exception\\Excep |
c580 | 74 69 6f 6e 49 6e 74 65 72 66 61 63 65 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 | tionInterface'.=>.$vendorDir...' |
c5a0 | 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 45 78 63 65 70 74 69 6f 6e 2f 45 78 63 65 70 | /symfony/console/Exception/Excep |
c5c0 | 74 69 6f 6e 49 6e 74 65 72 66 61 63 65 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 | tionInterface.php',.....'Symfony |
c5e0 | 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 45 78 63 65 70 74 69 6f 6e 5c | \\Component\\Console\\Exception\ |
c600 | 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 27 20 3d 3e 20 24 76 | \InvalidArgumentException'.=>.$v |
c620 | 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 45 78 63 | endorDir...'/symfony/console/Exc |
c640 | 65 70 74 69 6f 6e 2f 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 2e | eption/InvalidArgumentException. |
c660 | 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 | php',.....'Symfony\\Component\\C |
c680 | 6f 6e 73 6f 6c 65 5c 5c 45 78 63 65 70 74 69 6f 6e 5c 5c 49 6e 76 61 6c 69 64 4f 70 74 69 6f 6e | onsole\\Exception\\InvalidOption |
c6a0 | 45 78 63 65 70 74 69 6f 6e 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d | Exception'.=>.$vendorDir...'/sym |
c6c0 | 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 45 78 63 65 70 74 69 6f 6e 2f 49 6e 76 61 6c 69 64 4f 70 | fony/console/Exception/InvalidOp |
c6e0 | 74 69 6f 6e 45 78 63 65 70 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 | tionException.php',.....'Symfony |
c700 | 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 45 78 63 65 70 74 69 6f 6e 5c | \\Component\\Console\\Exception\ |
c720 | 5c 4c 6f 67 69 63 45 78 63 65 70 74 69 6f 6e 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e | \LogicException'.=>.$vendorDir.. |
c740 | 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 45 78 63 65 70 74 69 6f 6e 2f 4c 6f 67 | .'/symfony/console/Exception/Log |
c760 | 69 63 45 78 63 65 70 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c | icException.php',.....'Symfony\\ |
c780 | 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 45 78 63 65 70 74 69 6f 6e 5c 5c 52 | Component\\Console\\Exception\\R |
c7a0 | 75 6e 74 69 6d 65 45 78 63 65 70 74 69 6f 6e 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e | untimeException'.=>.$vendorDir.. |
c7c0 | 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 45 78 63 65 70 74 69 6f 6e 2f 52 75 6e | .'/symfony/console/Exception/Run |
c7e0 | 74 69 6d 65 45 78 63 65 70 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 | timeException.php',.....'Symfony |
c800 | 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 46 6f 72 6d 61 74 74 65 72 5c | \\Component\\Console\\Formatter\ |
c820 | 5c 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 | \OutputFormatter'.=>.$vendorDir. |
c840 | 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 46 6f 72 6d 61 74 74 65 72 2f 4f 75 | ..'/symfony/console/Formatter/Ou |
c860 | 74 70 75 74 46 6f 72 6d 61 74 74 65 72 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 | tputFormatter.php',.....'Symfony |
c880 | 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 46 6f 72 6d 61 74 74 65 72 5c | \\Component\\Console\\Formatter\ |
c8a0 | 5c 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 49 6e 74 65 72 66 61 63 65 27 20 3d 3e 20 24 76 | \OutputFormatterInterface'.=>.$v |
c8c0 | 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 46 6f 72 | endorDir...'/symfony/console/For |
c8e0 | 6d 61 74 74 65 72 2f 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 49 6e 74 65 72 66 61 63 65 2e | matter/OutputFormatterInterface. |
c900 | 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 | php',.....'Symfony\\Component\\C |
c920 | 6f 6e 73 6f 6c 65 5c 5c 46 6f 72 6d 61 74 74 65 72 5c 5c 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 | onsole\\Formatter\\OutputFormatt |
c940 | 65 72 53 74 79 6c 65 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f | erStyle'.=>.$vendorDir...'/symfo |
c960 | 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 46 6f 72 6d 61 74 74 65 72 2f 4f 75 74 70 75 74 46 6f 72 6d 61 | ny/console/Formatter/OutputForma |
c980 | 74 74 65 72 53 74 79 6c 65 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f | tterStyle.php',.....'Symfony\\Co |
c9a0 | 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 46 6f 72 6d 61 74 74 65 72 5c 5c 4f 75 74 | mponent\\Console\\Formatter\\Out |
c9c0 | 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c 65 49 6e 74 65 72 66 61 63 65 27 20 3d 3e 20 24 | putFormatterStyleInterface'.=>.$ |
c9e0 | 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 46 6f | vendorDir...'/symfony/console/Fo |
ca00 | 72 6d 61 74 74 65 72 2f 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c 65 49 6e 74 65 | rmatter/OutputFormatterStyleInte |
ca20 | 72 66 61 63 65 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e | rface.php',.....'Symfony\\Compon |
ca40 | 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 46 6f 72 6d 61 74 74 65 72 5c 5c 4f 75 74 70 75 74 46 | ent\\Console\\Formatter\\OutputF |
ca60 | 6f 72 6d 61 74 74 65 72 53 74 79 6c 65 53 74 61 63 6b 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 | ormatterStyleStack'.=>.$vendorDi |
ca80 | 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 46 6f 72 6d 61 74 74 65 72 2f | r...'/symfony/console/Formatter/ |
caa0 | 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c 65 53 74 61 63 6b 2e 70 68 70 27 2c 0a | OutputFormatterStyleStack.php',. |
cac0 | 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 | ....'Symfony\\Component\\Console |
cae0 | 5c 5c 48 65 6c 70 65 72 5c 5c 44 65 62 75 67 46 6f 72 6d 61 74 74 65 72 48 65 6c 70 65 72 27 20 | \\Helper\\DebugFormatterHelper'. |
cb00 | 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c | =>.$vendorDir...'/symfony/consol |
cb20 | 65 2f 48 65 6c 70 65 72 2f 44 65 62 75 67 46 6f 72 6d 61 74 74 65 72 48 65 6c 70 65 72 2e 70 68 | e/Helper/DebugFormatterHelper.ph |
cb40 | 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e | p',.....'Symfony\\Component\\Con |
cb60 | 73 6f 6c 65 5c 5c 48 65 6c 70 65 72 5c 5c 44 65 73 63 72 69 70 74 6f 72 48 65 6c 70 65 72 27 20 | sole\\Helper\\DescriptorHelper'. |
cb80 | 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c | =>.$vendorDir...'/symfony/consol |
cba0 | 65 2f 48 65 6c 70 65 72 2f 44 65 73 63 72 69 70 74 6f 72 48 65 6c 70 65 72 2e 70 68 70 27 2c 0a | e/Helper/DescriptorHelper.php',. |
cbc0 | 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 | ....'Symfony\\Component\\Console |
cbe0 | 5c 5c 48 65 6c 70 65 72 5c 5c 46 6f 72 6d 61 74 74 65 72 48 65 6c 70 65 72 27 20 3d 3e 20 24 76 | \\Helper\\FormatterHelper'.=>.$v |
cc00 | 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 48 65 6c | endorDir...'/symfony/console/Hel |
cc20 | 70 65 72 2f 46 6f 72 6d 61 74 74 65 72 48 65 6c 70 65 72 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 | per/FormatterHelper.php',.....'S |
cc40 | 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 48 65 6c 70 | ymfony\\Component\\Console\\Help |
cc60 | 65 72 5c 5c 48 65 6c 70 65 72 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 | er\\Helper'.=>.$vendorDir...'/sy |
cc80 | 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 48 65 6c 70 65 72 2f 48 65 6c 70 65 72 2e 70 68 70 27 | mfony/console/Helper/Helper.php' |
cca0 | 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f | ,.....'Symfony\\Component\\Conso |
ccc0 | 6c 65 5c 5c 48 65 6c 70 65 72 5c 5c 48 65 6c 70 65 72 49 6e 74 65 72 66 61 63 65 27 20 3d 3e 20 | le\\Helper\\HelperInterface'.=>. |
cce0 | 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 48 | $vendorDir...'/symfony/console/H |
cd00 | 65 6c 70 65 72 2f 48 65 6c 70 65 72 49 6e 74 65 72 66 61 63 65 2e 70 68 70 27 2c 0a 20 20 20 20 | elper/HelperInterface.php',..... |
cd20 | 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 48 65 | 'Symfony\\Component\\Console\\He |
cd40 | 6c 70 65 72 5c 5c 48 65 6c 70 65 72 53 65 74 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e | lper\\HelperSet'.=>.$vendorDir.. |
cd60 | 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 48 65 6c 70 65 72 2f 48 65 6c 70 65 72 | .'/symfony/console/Helper/Helper |
cd80 | 53 65 74 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e | Set.php',.....'Symfony\\Componen |
cda0 | 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 48 65 6c 70 65 72 5c 5c 49 6e 70 75 74 41 77 61 72 65 48 65 | t\\Console\\Helper\\InputAwareHe |
cdc0 | 6c 70 65 72 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f | lper'.=>.$vendorDir...'/symfony/ |
cde0 | 63 6f 6e 73 6f 6c 65 2f 48 65 6c 70 65 72 2f 49 6e 70 75 74 41 77 61 72 65 48 65 6c 70 65 72 2e | console/Helper/InputAwareHelper. |
ce00 | 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 | php',.....'Symfony\\Component\\C |
ce20 | 6f 6e 73 6f 6c 65 5c 5c 48 65 6c 70 65 72 5c 5c 50 72 6f 63 65 73 73 48 65 6c 70 65 72 27 20 3d | onsole\\Helper\\ProcessHelper'.= |
ce40 | 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 | >.$vendorDir...'/symfony/console |
ce60 | 2f 48 65 6c 70 65 72 2f 50 72 6f 63 65 73 73 48 65 6c 70 65 72 2e 70 68 70 27 2c 0a 20 20 20 20 | /Helper/ProcessHelper.php',..... |
ce80 | 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 48 65 | 'Symfony\\Component\\Console\\He |
cea0 | 6c 70 65 72 5c 5c 50 72 6f 67 72 65 73 73 42 61 72 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 | lper\\ProgressBar'.=>.$vendorDir |
cec0 | 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 48 65 6c 70 65 72 2f 50 72 6f 67 | ...'/symfony/console/Helper/Prog |
cee0 | 72 65 73 73 42 61 72 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 | ressBar.php',.....'Symfony\\Comp |
cf00 | 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 48 65 6c 70 65 72 5c 5c 50 72 6f 67 72 65 73 73 | onent\\Console\\Helper\\Progress |
cf20 | 49 6e 64 69 63 61 74 6f 72 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d | Indicator'.=>.$vendorDir...'/sym |
cf40 | 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 48 65 6c 70 65 72 2f 50 72 6f 67 72 65 73 73 49 6e 64 69 | fony/console/Helper/ProgressIndi |
cf60 | 63 61 74 6f 72 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e | cator.php',.....'Symfony\\Compon |
cf80 | 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 48 65 6c 70 65 72 5c 5c 51 75 65 73 74 69 6f 6e 48 65 | ent\\Console\\Helper\\QuestionHe |
cfa0 | 6c 70 65 72 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f | lper'.=>.$vendorDir...'/symfony/ |
cfc0 | 63 6f 6e 73 6f 6c 65 2f 48 65 6c 70 65 72 2f 51 75 65 73 74 69 6f 6e 48 65 6c 70 65 72 2e 70 68 | console/Helper/QuestionHelper.ph |
cfe0 | 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e | p',.....'Symfony\\Component\\Con |
d000 | 73 6f 6c 65 5c 5c 48 65 6c 70 65 72 5c 5c 53 79 6d 66 6f 6e 79 51 75 65 73 74 69 6f 6e 48 65 6c | sole\\Helper\\SymfonyQuestionHel |
d020 | 70 65 72 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 | per'.=>.$vendorDir...'/symfony/c |
d040 | 6f 6e 73 6f 6c 65 2f 48 65 6c 70 65 72 2f 53 79 6d 66 6f 6e 79 51 75 65 73 74 69 6f 6e 48 65 6c | onsole/Helper/SymfonyQuestionHel |
d060 | 70 65 72 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e | per.php',.....'Symfony\\Componen |
d080 | 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 48 65 6c 70 65 72 5c 5c 54 61 62 6c 65 27 20 3d 3e 20 24 76 | t\\Console\\Helper\\Table'.=>.$v |
d0a0 | 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 48 65 6c | endorDir...'/symfony/console/Hel |
d0c0 | 70 65 72 2f 54 61 62 6c 65 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f | per/Table.php',.....'Symfony\\Co |
d0e0 | 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 48 65 6c 70 65 72 5c 5c 54 61 62 6c 65 43 | mponent\\Console\\Helper\\TableC |
d100 | 65 6c 6c 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 | ell'.=>.$vendorDir...'/symfony/c |
d120 | 6f 6e 73 6f 6c 65 2f 48 65 6c 70 65 72 2f 54 61 62 6c 65 43 65 6c 6c 2e 70 68 70 27 2c 0a 20 20 | onsole/Helper/TableCell.php',... |
d140 | 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c | ..'Symfony\\Component\\Console\\ |
d160 | 48 65 6c 70 65 72 5c 5c 54 61 62 6c 65 53 65 70 61 72 61 74 6f 72 27 20 3d 3e 20 24 76 65 6e 64 | Helper\\TableSeparator'.=>.$vend |
d180 | 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 48 65 6c 70 65 72 | orDir...'/symfony/console/Helper |
d1a0 | 2f 54 61 62 6c 65 53 65 70 61 72 61 74 6f 72 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f | /TableSeparator.php',.....'Symfo |
d1c0 | 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 48 65 6c 70 65 72 5c 5c | ny\\Component\\Console\\Helper\\ |
d1e0 | 54 61 62 6c 65 53 74 79 6c 65 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 | TableStyle'.=>.$vendorDir...'/sy |
d200 | 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 48 65 6c 70 65 72 2f 54 61 62 6c 65 53 74 79 6c 65 2e | mfony/console/Helper/TableStyle. |
d220 | 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 | php',.....'Symfony\\Component\\C |
d240 | 6f 6e 73 6f 6c 65 5c 5c 49 6e 70 75 74 5c 5c 41 72 67 76 49 6e 70 75 74 27 20 3d 3e 20 24 76 65 | onsole\\Input\\ArgvInput'.=>.$ve |
d260 | 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 49 6e 70 75 | ndorDir...'/symfony/console/Inpu |
d280 | 74 2f 41 72 67 76 49 6e 70 75 74 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c | t/ArgvInput.php',.....'Symfony\\ |
d2a0 | 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 49 6e 70 75 74 5c 5c 41 72 72 61 79 | Component\\Console\\Input\\Array |
d2c0 | 49 6e 70 75 74 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 | Input'.=>.$vendorDir...'/symfony |
d2e0 | 2f 63 6f 6e 73 6f 6c 65 2f 49 6e 70 75 74 2f 41 72 72 61 79 49 6e 70 75 74 2e 70 68 70 27 2c 0a | /console/Input/ArrayInput.php',. |
d300 | 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 | ....'Symfony\\Component\\Console |
d320 | 5c 5c 49 6e 70 75 74 5c 5c 49 6e 70 75 74 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 | \\Input\\Input'.=>.$vendorDir... |
d340 | 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 49 6e 70 75 74 2f 49 6e 70 75 74 2e 70 68 | '/symfony/console/Input/Input.ph |
d360 | 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e | p',.....'Symfony\\Component\\Con |
d380 | 73 6f 6c 65 5c 5c 49 6e 70 75 74 5c 5c 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 27 20 3d 3e 20 24 | sole\\Input\\InputArgument'.=>.$ |
d3a0 | 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 49 6e | vendorDir...'/symfony/console/In |
d3c0 | 70 75 74 2f 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d | put/InputArgument.php',.....'Sym |
d3e0 | 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 49 6e 70 75 74 5c | fony\\Component\\Console\\Input\ |
d400 | 5c 49 6e 70 75 74 41 77 61 72 65 49 6e 74 65 72 66 61 63 65 27 20 3d 3e 20 24 76 65 6e 64 6f 72 | \InputAwareInterface'.=>.$vendor |
d420 | 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 49 6e 70 75 74 2f 49 6e | Dir...'/symfony/console/Input/In |
d440 | 70 75 74 41 77 61 72 65 49 6e 74 65 72 66 61 63 65 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d | putAwareInterface.php',.....'Sym |
d460 | 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 49 6e 70 75 74 5c | fony\\Component\\Console\\Input\ |
d480 | 5c 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 | \InputDefinition'.=>.$vendorDir. |
d4a0 | 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 49 6e 70 75 74 2f 49 6e 70 75 74 44 | ..'/symfony/console/Input/InputD |
d4c0 | 65 66 69 6e 69 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f | efinition.php',.....'Symfony\\Co |
d4e0 | 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 49 6e 70 75 74 5c 5c 49 6e 70 75 74 49 6e | mponent\\Console\\Input\\InputIn |
d500 | 74 65 72 66 61 63 65 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f | terface'.=>.$vendorDir...'/symfo |
d520 | 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 49 6e 70 75 74 2f 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 2e | ny/console/Input/InputInterface. |
d540 | 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 | php',.....'Symfony\\Component\\C |
d560 | 6f 6e 73 6f 6c 65 5c 5c 49 6e 70 75 74 5c 5c 49 6e 70 75 74 4f 70 74 69 6f 6e 27 20 3d 3e 20 24 | onsole\\Input\\InputOption'.=>.$ |
d580 | 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 49 6e | vendorDir...'/symfony/console/In |
d5a0 | 70 75 74 2f 49 6e 70 75 74 4f 70 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f | put/InputOption.php',.....'Symfo |
d5c0 | 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 49 6e 70 75 74 5c 5c 53 | ny\\Component\\Console\\Input\\S |
d5e0 | 74 72 69 6e 67 49 6e 70 75 74 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 | tringInput'.=>.$vendorDir...'/sy |
d600 | 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 49 6e 70 75 74 2f 53 74 72 69 6e 67 49 6e 70 75 74 2e | mfony/console/Input/StringInput. |
d620 | 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 | php',.....'Symfony\\Component\\C |
d640 | 6f 6e 73 6f 6c 65 5c 5c 4c 6f 67 67 65 72 5c 5c 43 6f 6e 73 6f 6c 65 4c 6f 67 67 65 72 27 20 3d | onsole\\Logger\\ConsoleLogger'.= |
d660 | 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 | >.$vendorDir...'/symfony/console |
d680 | 2f 4c 6f 67 67 65 72 2f 43 6f 6e 73 6f 6c 65 4c 6f 67 67 65 72 2e 70 68 70 27 2c 0a 20 20 20 20 | /Logger/ConsoleLogger.php',..... |
d6a0 | 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 4f 75 | 'Symfony\\Component\\Console\\Ou |
d6c0 | 74 70 75 74 5c 5c 42 75 66 66 65 72 65 64 4f 75 74 70 75 74 27 20 3d 3e 20 24 76 65 6e 64 6f 72 | tput\\BufferedOutput'.=>.$vendor |
d6e0 | 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 4f 75 74 70 75 74 2f 42 | Dir...'/symfony/console/Output/B |
d700 | 75 66 66 65 72 65 64 4f 75 74 70 75 74 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 | ufferedOutput.php',.....'Symfony |
d720 | 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 4f 75 74 70 75 74 5c 5c 43 6f | \\Component\\Console\\Output\\Co |
d740 | 6e 73 6f 6c 65 4f 75 74 70 75 74 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 | nsoleOutput'.=>.$vendorDir...'/s |
d760 | 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 4f 75 74 70 75 74 2f 43 6f 6e 73 6f 6c 65 4f 75 74 | ymfony/console/Output/ConsoleOut |
d780 | 70 75 74 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e | put.php',.....'Symfony\\Componen |
d7a0 | 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 4f 75 74 70 75 74 5c 5c 43 6f 6e 73 6f 6c 65 4f 75 74 70 75 | t\\Console\\Output\\ConsoleOutpu |
d7c0 | 74 49 6e 74 65 72 66 61 63 65 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 | tInterface'.=>.$vendorDir...'/sy |
d7e0 | 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 4f 75 74 70 75 74 2f 43 6f 6e 73 6f 6c 65 4f 75 74 70 | mfony/console/Output/ConsoleOutp |
d800 | 75 74 49 6e 74 65 72 66 61 63 65 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c | utInterface.php',.....'Symfony\\ |
d820 | 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 4f 75 74 70 75 74 5c 5c 4e 75 6c 6c | Component\\Console\\Output\\Null |
d840 | 4f 75 74 70 75 74 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e | Output'.=>.$vendorDir...'/symfon |
d860 | 79 2f 63 6f 6e 73 6f 6c 65 2f 4f 75 74 70 75 74 2f 4e 75 6c 6c 4f 75 74 70 75 74 2e 70 68 70 27 | y/console/Output/NullOutput.php' |
d880 | 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f | ,.....'Symfony\\Component\\Conso |
d8a0 | 6c 65 5c 5c 4f 75 74 70 75 74 5c 5c 4f 75 74 70 75 74 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 | le\\Output\\Output'.=>.$vendorDi |
d8c0 | 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 4f 75 74 70 75 74 2f 4f 75 74 | r...'/symfony/console/Output/Out |
d8e0 | 70 75 74 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e | put.php',.....'Symfony\\Componen |
d900 | 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 4f 75 74 70 75 74 5c 5c 4f 75 74 70 75 74 49 6e 74 65 72 66 | t\\Console\\Output\\OutputInterf |
d920 | 61 63 65 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 | ace'.=>.$vendorDir...'/symfony/c |
d940 | 6f 6e 73 6f 6c 65 2f 4f 75 74 70 75 74 2f 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 2e 70 68 | onsole/Output/OutputInterface.ph |
d960 | 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e | p',.....'Symfony\\Component\\Con |
d980 | 73 6f 6c 65 5c 5c 4f 75 74 70 75 74 5c 5c 53 74 72 65 61 6d 4f 75 74 70 75 74 27 20 3d 3e 20 24 | sole\\Output\\StreamOutput'.=>.$ |
d9a0 | 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 4f 75 | vendorDir...'/symfony/console/Ou |
d9c0 | 74 70 75 74 2f 53 74 72 65 61 6d 4f 75 74 70 75 74 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d | tput/StreamOutput.php',.....'Sym |
d9e0 | 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 51 75 65 73 74 69 | fony\\Component\\Console\\Questi |
da00 | 6f 6e 5c 5c 43 68 6f 69 63 65 51 75 65 73 74 69 6f 6e 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 | on\\ChoiceQuestion'.=>.$vendorDi |
da20 | 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 51 75 65 73 74 69 6f 6e 2f 43 | r...'/symfony/console/Question/C |
da40 | 68 6f 69 63 65 51 75 65 73 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 | hoiceQuestion.php',.....'Symfony |
da60 | 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 51 75 65 73 74 69 6f 6e 5c 5c | \\Component\\Console\\Question\\ |
da80 | 43 6f 6e 66 69 72 6d 61 74 69 6f 6e 51 75 65 73 74 69 6f 6e 27 20 3d 3e 20 24 76 65 6e 64 6f 72 | ConfirmationQuestion'.=>.$vendor |
daa0 | 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 51 75 65 73 74 69 6f 6e | Dir...'/symfony/console/Question |
dac0 | 2f 43 6f 6e 66 69 72 6d 61 74 69 6f 6e 51 75 65 73 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 | /ConfirmationQuestion.php',..... |
dae0 | 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 51 75 | 'Symfony\\Component\\Console\\Qu |
db00 | 65 73 74 69 6f 6e 5c 5c 51 75 65 73 74 69 6f 6e 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 | estion\\Question'.=>.$vendorDir. |
db20 | 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 51 75 65 73 74 69 6f 6e 2f 51 75 65 | ..'/symfony/console/Question/Que |
db40 | 73 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e | stion.php',.....'Symfony\\Compon |
db60 | 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 53 74 79 6c 65 5c 5c 4f 75 74 70 75 74 53 74 79 6c 65 | ent\\Console\\Style\\OutputStyle |
db80 | 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 | '.=>.$vendorDir...'/symfony/cons |
dba0 | 6f 6c 65 2f 53 74 79 6c 65 2f 4f 75 74 70 75 74 53 74 79 6c 65 2e 70 68 70 27 2c 0a 20 20 20 20 | ole/Style/OutputStyle.php',..... |
dbc0 | 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 53 74 | 'Symfony\\Component\\Console\\St |
dbe0 | 79 6c 65 5c 5c 53 74 79 6c 65 49 6e 74 65 72 66 61 63 65 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 | yle\\StyleInterface'.=>.$vendorD |
dc00 | 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 53 74 79 6c 65 2f 53 74 79 | ir...'/symfony/console/Style/Sty |
dc20 | 6c 65 49 6e 74 65 72 66 61 63 65 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c | leInterface.php',.....'Symfony\\ |
dc40 | 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 53 74 79 6c 65 5c 5c 53 79 6d 66 6f | Component\\Console\\Style\\Symfo |
dc60 | 6e 79 53 74 79 6c 65 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f | nyStyle'.=>.$vendorDir...'/symfo |
dc80 | 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 53 74 79 6c 65 2f 53 79 6d 66 6f 6e 79 53 74 79 6c 65 2e 70 68 | ny/console/Style/SymfonyStyle.ph |
dca0 | 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e | p',.....'Symfony\\Component\\Con |
dcc0 | 73 6f 6c 65 5c 5c 54 65 73 74 65 72 5c 5c 41 70 70 6c 69 63 61 74 69 6f 6e 54 65 73 74 65 72 27 | sole\\Tester\\ApplicationTester' |
dce0 | 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f | .=>.$vendorDir...'/symfony/conso |
dd00 | 6c 65 2f 54 65 73 74 65 72 2f 41 70 70 6c 69 63 61 74 69 6f 6e 54 65 73 74 65 72 2e 70 68 70 27 | le/Tester/ApplicationTester.php' |
dd20 | 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 43 6f 6e 73 6f | ,.....'Symfony\\Component\\Conso |
dd40 | 6c 65 5c 5c 54 65 73 74 65 72 5c 5c 43 6f 6d 6d 61 6e 64 54 65 73 74 65 72 27 20 3d 3e 20 24 76 | le\\Tester\\CommandTester'.=>.$v |
dd60 | 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 2f 54 65 73 | endorDir...'/symfony/console/Tes |
dd80 | 74 65 72 2f 43 6f 6d 6d 61 6e 64 54 65 73 74 65 72 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d | ter/CommandTester.php',.....'Sym |
dda0 | 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 44 65 62 75 67 5c 5c 42 75 66 66 65 72 69 6e | fony\\Component\\Debug\\Bufferin |
ddc0 | 67 4c 6f 67 67 65 72 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f | gLogger'.=>.$vendorDir...'/symfo |
dde0 | 6e 79 2f 64 65 62 75 67 2f 42 75 66 66 65 72 69 6e 67 4c 6f 67 67 65 72 2e 70 68 70 27 2c 0a 20 | ny/debug/BufferingLogger.php',.. |
de00 | 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 44 65 62 75 67 5c 5c 44 | ...'Symfony\\Component\\Debug\\D |
de20 | 65 62 75 67 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f | ebug'.=>.$vendorDir...'/symfony/ |
de40 | 64 65 62 75 67 2f 44 65 62 75 67 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c | debug/Debug.php',.....'Symfony\\ |
de60 | 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 44 65 62 75 67 5c 5c 44 65 62 75 67 43 6c 61 73 73 4c 6f 61 64 | Component\\Debug\\DebugClassLoad |
de80 | 65 72 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 64 65 | er'.=>.$vendorDir...'/symfony/de |
dea0 | 62 75 67 2f 44 65 62 75 67 43 6c 61 73 73 4c 6f 61 64 65 72 2e 70 68 70 27 2c 0a 20 20 20 20 27 | bug/DebugClassLoader.php',.....' |
dec0 | 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 44 65 62 75 67 5c 5c 45 72 72 6f 72 | Symfony\\Component\\Debug\\Error |
dee0 | 48 61 6e 64 6c 65 72 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f | Handler'.=>.$vendorDir...'/symfo |
df00 | 6e 79 2f 64 65 62 75 67 2f 45 72 72 6f 72 48 61 6e 64 6c 65 72 2e 70 68 70 27 2c 0a 20 20 20 20 | ny/debug/ErrorHandler.php',..... |
df20 | 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 44 65 62 75 67 5c 5c 45 78 63 65 | 'Symfony\\Component\\Debug\\Exce |
df40 | 70 74 69 6f 6e 48 61 6e 64 6c 65 72 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f | ptionHandler'.=>.$vendorDir...'/ |
df60 | 73 79 6d 66 6f 6e 79 2f 64 65 62 75 67 2f 45 78 63 65 70 74 69 6f 6e 48 61 6e 64 6c 65 72 2e 70 | symfony/debug/ExceptionHandler.p |
df80 | 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 44 65 | hp',.....'Symfony\\Component\\De |
dfa0 | 62 75 67 5c 5c 45 78 63 65 70 74 69 6f 6e 5c 5c 43 6c 61 73 73 4e 6f 74 46 6f 75 6e 64 45 78 63 | bug\\Exception\\ClassNotFoundExc |
dfc0 | 65 70 74 69 6f 6e 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e | eption'.=>.$vendorDir...'/symfon |
dfe0 | 79 2f 64 65 62 75 67 2f 45 78 63 65 70 74 69 6f 6e 2f 43 6c 61 73 73 4e 6f 74 46 6f 75 6e 64 45 | y/debug/Exception/ClassNotFoundE |
e000 | 78 63 65 70 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d | xception.php',.....'Symfony\\Com |
e020 | 70 6f 6e 65 6e 74 5c 5c 44 65 62 75 67 5c 5c 45 78 63 65 70 74 69 6f 6e 5c 5c 43 6f 6e 74 65 78 | ponent\\Debug\\Exception\\Contex |
e040 | 74 45 72 72 6f 72 45 78 63 65 70 74 69 6f 6e 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e | tErrorException'.=>.$vendorDir.. |
e060 | 20 27 2f 73 79 6d 66 6f 6e 79 2f 64 65 62 75 67 2f 45 78 63 65 70 74 69 6f 6e 2f 43 6f 6e 74 65 | .'/symfony/debug/Exception/Conte |
e080 | 78 74 45 72 72 6f 72 45 78 63 65 70 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 | xtErrorException.php',.....'Symf |
e0a0 | 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 44 65 62 75 67 5c 5c 45 78 63 65 70 74 69 6f 6e | ony\\Component\\Debug\\Exception |
e0c0 | 5c 5c 46 61 74 61 6c 45 72 72 6f 72 45 78 63 65 70 74 69 6f 6e 27 20 3d 3e 20 24 76 65 6e 64 6f | \\FatalErrorException'.=>.$vendo |
e0e0 | 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 64 65 62 75 67 2f 45 78 63 65 70 74 69 6f 6e | rDir...'/symfony/debug/Exception |
e100 | 2f 46 61 74 61 6c 45 72 72 6f 72 45 78 63 65 70 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 27 | /FatalErrorException.php',.....' |
e120 | 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 44 65 62 75 67 5c 5c 45 78 63 65 70 | Symfony\\Component\\Debug\\Excep |
e140 | 74 69 6f 6e 5c 5c 46 61 74 61 6c 54 68 72 6f 77 61 62 6c 65 45 72 72 6f 72 27 20 3d 3e 20 24 76 | tion\\FatalThrowableError'.=>.$v |
e160 | 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 64 65 62 75 67 2f 45 78 63 65 70 | endorDir...'/symfony/debug/Excep |
e180 | 74 69 6f 6e 2f 46 61 74 61 6c 54 68 72 6f 77 61 62 6c 65 45 72 72 6f 72 2e 70 68 70 27 2c 0a 20 | tion/FatalThrowableError.php',.. |
e1a0 | 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 44 65 62 75 67 5c 5c 45 | ...'Symfony\\Component\\Debug\\E |
e1c0 | 78 63 65 70 74 69 6f 6e 5c 5c 46 6c 61 74 74 65 6e 45 78 63 65 70 74 69 6f 6e 27 20 3d 3e 20 24 | xception\\FlattenException'.=>.$ |
e1e0 | 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 64 65 62 75 67 2f 45 78 63 65 | vendorDir...'/symfony/debug/Exce |
e200 | 70 74 69 6f 6e 2f 46 6c 61 74 74 65 6e 45 78 63 65 70 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 | ption/FlattenException.php',.... |
e220 | 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 44 65 62 75 67 5c 5c 45 78 63 | .'Symfony\\Component\\Debug\\Exc |
e240 | 65 70 74 69 6f 6e 5c 5c 4f 75 74 4f 66 4d 65 6d 6f 72 79 45 78 63 65 70 74 69 6f 6e 27 20 3d 3e | eption\\OutOfMemoryException'.=> |
e260 | 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 64 65 62 75 67 2f 45 78 | .$vendorDir...'/symfony/debug/Ex |
e280 | 63 65 70 74 69 6f 6e 2f 4f 75 74 4f 66 4d 65 6d 6f 72 79 45 78 63 65 70 74 69 6f 6e 2e 70 68 70 | ception/OutOfMemoryException.php |
e2a0 | 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 44 65 62 75 | ',.....'Symfony\\Component\\Debu |
e2c0 | 67 5c 5c 45 78 63 65 70 74 69 6f 6e 5c 5c 55 6e 64 65 66 69 6e 65 64 46 75 6e 63 74 69 6f 6e 45 | g\\Exception\\UndefinedFunctionE |
e2e0 | 78 63 65 70 74 69 6f 6e 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 | xception'.=>.$vendorDir...'/symf |
e300 | 6f 6e 79 2f 64 65 62 75 67 2f 45 78 63 65 70 74 69 6f 6e 2f 55 6e 64 65 66 69 6e 65 64 46 75 6e | ony/debug/Exception/UndefinedFun |
e320 | 63 74 69 6f 6e 45 78 63 65 70 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e | ctionException.php',.....'Symfon |
e340 | 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 44 65 62 75 67 5c 5c 45 78 63 65 70 74 69 6f 6e 5c 5c | y\\Component\\Debug\\Exception\\ |
e360 | 55 6e 64 65 66 69 6e 65 64 4d 65 74 68 6f 64 45 78 63 65 70 74 69 6f 6e 27 20 3d 3e 20 24 76 65 | UndefinedMethodException'.=>.$ve |
e380 | 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 64 65 62 75 67 2f 45 78 63 65 70 74 | ndorDir...'/symfony/debug/Except |
e3a0 | 69 6f 6e 2f 55 6e 64 65 66 69 6e 65 64 4d 65 74 68 6f 64 45 78 63 65 70 74 69 6f 6e 2e 70 68 70 | ion/UndefinedMethodException.php |
e3c0 | 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 44 65 62 75 | ',.....'Symfony\\Component\\Debu |
e3e0 | 67 5c 5c 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 5c 5c 43 6c 61 73 73 4e 6f 74 46 6f | g\\FatalErrorHandler\\ClassNotFo |
e400 | 75 6e 64 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 27 20 3d 3e 20 24 76 65 6e 64 6f 72 | undFatalErrorHandler'.=>.$vendor |
e420 | 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 64 65 62 75 67 2f 46 61 74 61 6c 45 72 72 6f 72 | Dir...'/symfony/debug/FatalError |
e440 | 48 61 6e 64 6c 65 72 2f 43 6c 61 73 73 4e 6f 74 46 6f 75 6e 64 46 61 74 61 6c 45 72 72 6f 72 48 | Handler/ClassNotFoundFatalErrorH |
e460 | 61 6e 64 6c 65 72 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f | andler.php',.....'Symfony\\Compo |
e480 | 6e 65 6e 74 5c 5c 44 65 62 75 67 5c 5c 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 5c 5c | nent\\Debug\\FatalErrorHandler\\ |
e4a0 | 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 49 6e 74 65 72 66 61 63 65 27 20 3d 3e 20 24 | FatalErrorHandlerInterface'.=>.$ |
e4c0 | 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 64 65 62 75 67 2f 46 61 74 61 | vendorDir...'/symfony/debug/Fata |
e4e0 | 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 2f 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 49 | lErrorHandler/FatalErrorHandlerI |
e500 | 6e 74 65 72 66 61 63 65 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d | nterface.php',.....'Symfony\\Com |
e520 | 70 6f 6e 65 6e 74 5c 5c 44 65 62 75 67 5c 5c 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 | ponent\\Debug\\FatalErrorHandler |
e540 | 5c 5c 55 6e 64 65 66 69 6e 65 64 46 75 6e 63 74 69 6f 6e 46 61 74 61 6c 45 72 72 6f 72 48 61 6e | \\UndefinedFunctionFatalErrorHan |
e560 | 64 6c 65 72 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f | dler'.=>.$vendorDir...'/symfony/ |
e580 | 64 65 62 75 67 2f 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 2f 55 6e 64 65 66 69 6e 65 | debug/FatalErrorHandler/Undefine |
e5a0 | 64 46 75 6e 63 74 69 6f 6e 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 2e 70 68 70 27 2c | dFunctionFatalErrorHandler.php', |
e5c0 | 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 44 65 62 75 67 5c | .....'Symfony\\Component\\Debug\ |
e5e0 | 5c 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 5c 5c 55 6e 64 65 66 69 6e 65 64 4d 65 74 | \FatalErrorHandler\\UndefinedMet |
e600 | 68 6f 64 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 27 20 3d 3e 20 24 76 65 6e 64 6f 72 | hodFatalErrorHandler'.=>.$vendor |
e620 | 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 64 65 62 75 67 2f 46 61 74 61 6c 45 72 72 6f 72 | Dir...'/symfony/debug/FatalError |
e640 | 48 61 6e 64 6c 65 72 2f 55 6e 64 65 66 69 6e 65 64 4d 65 74 68 6f 64 46 61 74 61 6c 45 72 72 6f | Handler/UndefinedMethodFatalErro |
e660 | 72 48 61 6e 64 6c 65 72 2e 70 68 70 27 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 50 6f 6c | rHandler.php',.....'Symfony\\Pol |
e680 | 79 66 69 6c 6c 5c 5c 4d 62 73 74 72 69 6e 67 5c 5c 4d 62 73 74 72 69 6e 67 27 20 3d 3e 20 24 76 | yfill\\Mbstring\\Mbstring'.=>.$v |
e6a0 | 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 70 6f 6c 79 66 69 6c 6c 2d 6d 62 | endorDir...'/symfony/polyfill-mb |
e6c0 | 73 74 72 69 6e 67 2f 4d 62 73 74 72 69 6e 67 2e 70 68 70 27 2c 0a 29 3b 0a 3c 3f 70 68 70 0a 0a | string/Mbstring.php',.);.<?php.. |
e6e0 | 2f 2f 20 61 75 74 6f 6c 6f 61 64 5f 70 73 72 34 2e 70 68 70 20 40 67 65 6e 65 72 61 74 65 64 20 | //.autoload_psr4.php.@generated. |
e700 | 62 79 20 43 6f 6d 70 6f 73 65 72 0a 0a 24 76 65 6e 64 6f 72 44 69 72 20 3d 20 64 69 72 6e 61 6d | by.Composer..$vendorDir.=.dirnam |
e720 | 65 28 64 69 72 6e 61 6d 65 28 5f 5f 46 49 4c 45 5f 5f 29 29 3b 0a 24 62 61 73 65 44 69 72 20 3d | e(dirname(__FILE__));.$baseDir.= |
e740 | 20 64 69 72 6e 61 6d 65 28 24 76 65 6e 64 6f 72 44 69 72 29 3b 0a 0a 72 65 74 75 72 6e 20 61 72 | .dirname($vendorDir);..return.ar |
e760 | 72 61 79 28 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 50 6f 6c 79 66 69 6c 6c 5c 5c 4d 62 73 | ray(.....'Symfony\\Polyfill\\Mbs |
e780 | 74 72 69 6e 67 5c 5c 27 20 3d 3e 20 61 72 72 61 79 28 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 | tring\\'.=>.array($vendorDir...' |
e7a0 | 2f 73 79 6d 66 6f 6e 79 2f 70 6f 6c 79 66 69 6c 6c 2d 6d 62 73 74 72 69 6e 67 27 29 2c 0a 20 20 | /symfony/polyfill-mbstring'),... |
e7c0 | 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 5c 44 65 62 75 67 5c 5c 27 20 | ..'Symfony\\Component\\Debug\\'. |
e7e0 | 3d 3e 20 61 72 72 61 79 28 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f | =>.array($vendorDir...'/symfony/ |
e800 | 64 65 62 75 67 27 29 2c 0a 20 20 20 20 27 53 79 6d 66 6f 6e 79 5c 5c 43 6f 6d 70 6f 6e 65 6e 74 | debug'),.....'Symfony\\Component |
e820 | 5c 5c 43 6f 6e 73 6f 6c 65 5c 5c 27 20 3d 3e 20 61 72 72 61 79 28 24 76 65 6e 64 6f 72 44 69 72 | \\Console\\'.=>.array($vendorDir |
e840 | 20 2e 20 27 2f 73 79 6d 66 6f 6e 79 2f 63 6f 6e 73 6f 6c 65 27 29 2c 0a 20 20 20 20 27 50 73 72 | ...'/symfony/console'),.....'Psr |
e860 | 5c 5c 4c 6f 67 5c 5c 27 20 3d 3e 20 61 72 72 61 79 28 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 | \\Log\\'.=>.array($vendorDir...' |
e880 | 2f 70 73 72 2f 6c 6f 67 2f 50 73 72 2f 4c 6f 67 27 29 2c 0a 20 20 20 20 27 4e 43 5c 5c 55 70 64 | /psr/log/Psr/Log'),.....'NC\\Upd |
e8a0 | 61 74 65 72 5c 5c 27 20 3d 3e 20 61 72 72 61 79 28 24 62 61 73 65 44 69 72 20 2e 20 27 2f 6c 69 | ater\\'.=>.array($baseDir...'/li |
e8c0 | 62 27 29 2c 0a 29 3b 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 | b'),.);.<?php../*..*.This.file.i |
e8e0 | 73 20 70 61 72 74 20 6f 66 20 43 6f 6d 70 6f 73 65 72 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 4e 69 | s.part.of.Composer...*..*.(c).Ni |
e900 | 6c 73 20 41 64 65 72 6d 61 6e 6e 20 3c 6e 61 64 65 72 6d 61 6e 40 6e 61 64 65 72 6d 61 6e 2e 64 | ls.Adermann.<naderman@naderman.d |
e920 | 65 3e 0a 20 2a 20 20 20 20 20 4a 6f 72 64 69 20 42 6f 67 67 69 61 6e 6f 20 3c 6a 2e 62 6f 67 67 | e>..*.....Jordi.Boggiano.<j.bogg |
e940 | 69 61 6e 6f 40 73 65 6c 64 2e 62 65 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c | iano@seld.be>..*..*.For.the.full |
e960 | 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 | .copyright.and.license.informati |
e980 | 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 | on,.please.view.the.LICENSE..*.f |
e9a0 | 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 | ile.that.was.distributed.with.th |
e9c0 | 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 43 | is.source.code...*/..namespace.C |
e9e0 | 6f 6d 70 6f 73 65 72 5c 41 75 74 6f 6c 6f 61 64 3b 0a 0a 2f 2a 2a 0a 20 2a 20 43 6c 61 73 73 4c | omposer\Autoload;../**..*.ClassL |
ea00 | 6f 61 64 65 72 20 69 6d 70 6c 65 6d 65 6e 74 73 20 61 20 50 53 52 2d 30 2c 20 50 53 52 2d 34 20 | oader.implements.a.PSR-0,.PSR-4. |
ea20 | 61 6e 64 20 63 6c 61 73 73 6d 61 70 20 63 6c 61 73 73 20 6c 6f 61 64 65 72 2e 0a 20 2a 0a 20 2a | and.classmap.class.loader...*..* |
ea40 | 20 20 20 20 20 24 6c 6f 61 64 65 72 20 3d 20 6e 65 77 20 5c 43 6f 6d 70 6f 73 65 72 5c 41 75 74 | .....$loader.=.new.\Composer\Aut |
ea60 | 6f 6c 6f 61 64 5c 43 6c 61 73 73 4c 6f 61 64 65 72 28 29 3b 0a 20 2a 0a 20 2a 20 20 20 20 20 2f | oload\ClassLoader();..*..*...../ |
ea80 | 2f 20 72 65 67 69 73 74 65 72 20 63 6c 61 73 73 65 73 20 77 69 74 68 20 6e 61 6d 65 73 70 61 63 | /.register.classes.with.namespac |
eaa0 | 65 73 0a 20 2a 20 20 20 20 20 24 6c 6f 61 64 65 72 2d 3e 61 64 64 28 27 53 79 6d 66 6f 6e 79 5c | es..*.....$loader->add('Symfony\ |
eac0 | 43 6f 6d 70 6f 6e 65 6e 74 27 2c 20 5f 5f 44 49 52 5f 5f 2e 27 2f 63 6f 6d 70 6f 6e 65 6e 74 27 | Component',.__DIR__.'/component' |
eae0 | 29 3b 0a 20 2a 20 20 20 20 20 24 6c 6f 61 64 65 72 2d 3e 61 64 64 28 27 53 79 6d 66 6f 6e 79 27 | );..*.....$loader->add('Symfony' |
eb00 | 2c 20 20 20 20 20 20 20 20 20 20 20 5f 5f 44 49 52 5f 5f 2e 27 2f 66 72 61 6d 65 77 6f 72 6b 27 | ,...........__DIR__.'/framework' |
eb20 | 29 3b 0a 20 2a 0a 20 2a 20 20 20 20 20 2f 2f 20 61 63 74 69 76 61 74 65 20 74 68 65 20 61 75 74 | );..*..*.....//.activate.the.aut |
eb40 | 6f 6c 6f 61 64 65 72 0a 20 2a 20 20 20 20 20 24 6c 6f 61 64 65 72 2d 3e 72 65 67 69 73 74 65 72 | oloader..*.....$loader->register |
eb60 | 28 29 3b 0a 20 2a 0a 20 2a 20 20 20 20 20 2f 2f 20 74 6f 20 65 6e 61 62 6c 65 20 73 65 61 72 63 | ();..*..*.....//.to.enable.searc |
eb80 | 68 69 6e 67 20 74 68 65 20 69 6e 63 6c 75 64 65 20 70 61 74 68 20 28 65 67 2e 20 66 6f 72 20 50 | hing.the.include.path.(eg..for.P |
eba0 | 45 41 52 20 70 61 63 6b 61 67 65 73 29 0a 20 2a 20 20 20 20 20 24 6c 6f 61 64 65 72 2d 3e 73 65 | EAR.packages)..*.....$loader->se |
ebc0 | 74 55 73 65 49 6e 63 6c 75 64 65 50 61 74 68 28 74 72 75 65 29 3b 0a 20 2a 0a 20 2a 20 49 6e 20 | tUseIncludePath(true);..*..*.In. |
ebe0 | 74 68 69 73 20 65 78 61 6d 70 6c 65 2c 20 69 66 20 79 6f 75 20 74 72 79 20 74 6f 20 75 73 65 20 | this.example,.if.you.try.to.use. |
ec00 | 61 20 63 6c 61 73 73 20 69 6e 20 74 68 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 | a.class.in.the.Symfony\Component |
ec20 | 0a 20 2a 20 6e 61 6d 65 73 70 61 63 65 20 6f 72 20 6f 6e 65 20 6f 66 20 69 74 73 20 63 68 69 6c | ..*.namespace.or.one.of.its.chil |
ec40 | 64 72 65 6e 20 28 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 20 | dren.(Symfony\Component\Console. |
ec60 | 66 6f 72 20 69 6e 73 74 61 6e 63 65 29 2c 0a 20 2a 20 74 68 65 20 61 75 74 6f 6c 6f 61 64 65 72 | for.instance),..*.the.autoloader |
ec80 | 20 77 69 6c 6c 20 66 69 72 73 74 20 6c 6f 6f 6b 20 66 6f 72 20 74 68 65 20 63 6c 61 73 73 20 75 | .will.first.look.for.the.class.u |
eca0 | 6e 64 65 72 20 74 68 65 20 63 6f 6d 70 6f 6e 65 6e 74 2f 0a 20 2a 20 64 69 72 65 63 74 6f 72 79 | nder.the.component/..*.directory |
ecc0 | 2c 20 61 6e 64 20 69 74 20 77 69 6c 6c 20 74 68 65 6e 20 66 61 6c 6c 62 61 63 6b 20 74 6f 20 74 | ,.and.it.will.then.fallback.to.t |
ece0 | 68 65 20 66 72 61 6d 65 77 6f 72 6b 2f 20 64 69 72 65 63 74 6f 72 79 20 69 66 20 6e 6f 74 0a 20 | he.framework/.directory.if.not.. |
ed00 | 2a 20 66 6f 75 6e 64 20 62 65 66 6f 72 65 20 67 69 76 69 6e 67 20 75 70 2e 0a 20 2a 0a 20 2a 20 | *.found.before.giving.up...*..*. |
ed20 | 54 68 69 73 20 63 6c 61 73 73 20 69 73 20 6c 6f 6f 73 65 6c 79 20 62 61 73 65 64 20 6f 6e 20 74 | This.class.is.loosely.based.on.t |
ed40 | 68 65 20 53 79 6d 66 6f 6e 79 20 55 6e 69 76 65 72 73 61 6c 43 6c 61 73 73 4c 6f 61 64 65 72 2e | he.Symfony.UniversalClassLoader. |
ed60 | 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 | ..*..*.@author.Fabien.Potencier. |
ed80 | 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 20 40 61 75 74 68 6f 72 20 | <fabien@symfony.com>..*.@author. |
eda0 | 4a 6f 72 64 69 20 42 6f 67 67 69 61 6e 6f 20 3c 6a 2e 62 6f 67 67 69 61 6e 6f 40 73 65 6c 64 2e | Jordi.Boggiano.<j.boggiano@seld. |
edc0 | 62 65 3e 0a 20 2a 20 40 73 65 65 20 20 20 20 68 74 74 70 73 3a 2f 2f 77 77 77 2e 70 68 70 2d 66 | be>..*.@see....https://www.php-f |
ede0 | 69 67 2e 6f 72 67 2f 70 73 72 2f 70 73 72 2d 30 2f 0a 20 2a 20 40 73 65 65 20 20 20 20 68 74 74 | ig.org/psr/psr-0/..*.@see....htt |
ee00 | 70 73 3a 2f 2f 77 77 77 2e 70 68 70 2d 66 69 67 2e 6f 72 67 2f 70 73 72 2f 70 73 72 2d 34 2f 0a | ps://www.php-fig.org/psr/psr-4/. |
ee20 | 20 2a 2f 0a 63 6c 61 73 73 20 43 6c 61 73 73 4c 6f 61 64 65 72 0a 7b 0a 20 20 20 20 2f 2a 2a 20 | .*/.class.ClassLoader.{...../**. |
ee40 | 40 76 61 72 20 3f 73 74 72 69 6e 67 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 76 65 6e | @var.?string.*/.....private.$ven |
ee60 | 64 6f 72 44 69 72 3b 0a 0a 20 20 20 20 2f 2f 20 50 53 52 2d 34 0a 20 20 20 20 2f 2a 2a 0a 20 20 | dorDir;......//.PSR-4...../**... |
ee80 | 20 20 20 2a 20 40 76 61 72 20 61 72 72 61 79 5b 5d 0a 20 20 20 20 20 2a 20 40 70 73 61 6c 6d 2d | ...*.@var.array[]......*.@psalm- |
eea0 | 76 61 72 20 61 72 72 61 79 3c 73 74 72 69 6e 67 2c 20 61 72 72 61 79 3c 73 74 72 69 6e 67 2c 20 | var.array<string,.array<string,. |
eec0 | 69 6e 74 3e 3e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 70 72 65 66 69 | int>>......*/.....private.$prefi |
eee0 | 78 4c 65 6e 67 74 68 73 50 73 72 34 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 2f 2a 2a 0a | xLengthsPsr4.=.array();...../**. |
ef00 | 20 20 20 20 20 2a 20 40 76 61 72 20 61 72 72 61 79 5b 5d 0a 20 20 20 20 20 2a 20 40 70 73 61 6c | .....*.@var.array[]......*.@psal |
ef20 | 6d 2d 76 61 72 20 61 72 72 61 79 3c 73 74 72 69 6e 67 2c 20 61 72 72 61 79 3c 69 6e 74 2c 20 73 | m-var.array<string,.array<int,.s |
ef40 | 74 72 69 6e 67 3e 3e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 70 72 65 | tring>>......*/.....private.$pre |
ef60 | 66 69 78 44 69 72 73 50 73 72 34 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 2f 2a 2a 0a 20 | fixDirsPsr4.=.array();...../**.. |
ef80 | 20 20 20 20 2a 20 40 76 61 72 20 61 72 72 61 79 5b 5d 0a 20 20 20 20 20 2a 20 40 70 73 61 6c 6d | ....*.@var.array[]......*.@psalm |
efa0 | 2d 76 61 72 20 61 72 72 61 79 3c 73 74 72 69 6e 67 2c 20 73 74 72 69 6e 67 3e 0a 20 20 20 20 20 | -var.array<string,.string>...... |
efc0 | 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 66 61 6c 6c 62 61 63 6b 44 69 72 73 50 73 72 34 | */.....private.$fallbackDirsPsr4 |
efe0 | 20 3d 20 61 72 72 61 79 28 29 3b 0a 0a 20 20 20 20 2f 2f 20 50 53 52 2d 30 0a 20 20 20 20 2f 2a | .=.array();......//.PSR-0...../* |
f000 | 2a 0a 20 20 20 20 20 2a 20 40 76 61 72 20 61 72 72 61 79 5b 5d 0a 20 20 20 20 20 2a 20 40 70 73 | *......*.@var.array[]......*.@ps |
f020 | 61 6c 6d 2d 76 61 72 20 61 72 72 61 79 3c 73 74 72 69 6e 67 2c 20 61 72 72 61 79 3c 73 74 72 69 | alm-var.array<string,.array<stri |
f040 | 6e 67 2c 20 73 74 72 69 6e 67 5b 5d 3e 3e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 | ng,.string[]>>......*/.....priva |
f060 | 74 65 20 24 70 72 65 66 69 78 65 73 50 73 72 30 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 | te.$prefixesPsr0.=.array();..... |
f080 | 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 76 61 72 20 61 72 72 61 79 5b 5d 0a 20 20 20 20 20 2a 20 40 | /**......*.@var.array[]......*.@ |
f0a0 | 70 73 61 6c 6d 2d 76 61 72 20 61 72 72 61 79 3c 73 74 72 69 6e 67 2c 20 73 74 72 69 6e 67 3e 0a | psalm-var.array<string,.string>. |
f0c0 | 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 66 61 6c 6c 62 61 63 6b 44 69 72 | .....*/.....private.$fallbackDir |
f0e0 | 73 50 73 72 30 20 3d 20 61 72 72 61 79 28 29 3b 0a 0a 20 20 20 20 2f 2a 2a 20 40 76 61 72 20 62 | sPsr0.=.array();....../**.@var.b |
f100 | 6f 6f 6c 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 75 73 65 49 6e 63 6c 75 64 65 50 61 | ool.*/.....private.$useIncludePa |
f120 | 74 68 20 3d 20 66 61 6c 73 65 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 76 61 72 | th.=.false;....../**......*.@var |
f140 | 20 73 74 72 69 6e 67 5b 5d 0a 20 20 20 20 20 2a 20 40 70 73 61 6c 6d 2d 76 61 72 20 61 72 72 61 | .string[]......*.@psalm-var.arra |
f160 | 79 3c 73 74 72 69 6e 67 2c 20 73 74 72 69 6e 67 3e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 | y<string,.string>......*/.....pr |
f180 | 69 76 61 74 65 20 24 63 6c 61 73 73 4d 61 70 20 3d 20 61 72 72 61 79 28 29 3b 0a 0a 20 20 20 20 | ivate.$classMap.=.array();...... |
f1a0 | 2f 2a 2a 20 40 76 61 72 20 62 6f 6f 6c 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 63 6c | /**.@var.bool.*/.....private.$cl |
f1c0 | 61 73 73 4d 61 70 41 75 74 68 6f 72 69 74 61 74 69 76 65 20 3d 20 66 61 6c 73 65 3b 0a 0a 20 20 | assMapAuthoritative.=.false;.... |
f1e0 | 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 76 61 72 20 62 6f 6f 6c 5b 5d 0a 20 20 20 20 20 2a 20 | ../**......*.@var.bool[]......*. |
f200 | 40 70 73 61 6c 6d 2d 76 61 72 20 61 72 72 61 79 3c 73 74 72 69 6e 67 2c 20 62 6f 6f 6c 3e 0a 20 | @psalm-var.array<string,.bool>.. |
f220 | 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 6d 69 73 73 69 6e 67 43 6c 61 73 73 | ....*/.....private.$missingClass |
f240 | 65 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 0a 20 20 20 20 2f 2a 2a 20 40 76 61 72 20 3f 73 74 72 | es.=.array();....../**.@var.?str |
f260 | 69 6e 67 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 61 70 63 75 50 72 65 66 69 78 3b 0a | ing.*/.....private.$apcuPrefix;. |
f280 | 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 76 61 72 20 73 65 6c 66 5b 5d 0a 20 20 20 20 | ...../**......*.@var.self[]..... |
f2a0 | 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 24 72 65 67 69 73 74 65 72 | .*/.....private.static.$register |
f2c0 | 65 64 4c 6f 61 64 65 72 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 | edLoaders.=.array();....../**... |
f2e0 | 20 20 20 2a 20 40 70 61 72 61 6d 20 3f 73 74 72 69 6e 67 20 24 76 65 6e 64 6f 72 44 69 72 0a 20 | ...*.@param.?string.$vendorDir.. |
f300 | 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 63 6f 6e | ....*/.....public.function.__con |
f320 | 73 74 72 75 63 74 28 24 76 65 6e 64 6f 72 44 69 72 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a | struct($vendorDir.=.null).....{. |
f340 | 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 76 65 6e 64 6f 72 44 69 72 20 3d 20 24 76 65 6e 64 | ........$this->vendorDir.=.$vend |
f360 | 6f 72 44 69 72 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 72 65 | orDir;.....}....../**......*.@re |
f380 | 74 75 72 6e 20 73 74 72 69 6e 67 5b 5d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 | turn.string[]......*/.....public |
f3a0 | 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 50 72 65 66 69 78 65 73 28 29 0a 20 20 20 20 7b 0a 20 20 | .function.getPrefixes().....{... |
f3c0 | 20 20 20 20 20 20 69 66 20 28 21 65 6d 70 74 79 28 24 74 68 69 73 2d 3e 70 72 65 66 69 78 65 73 | ......if.(!empty($this->prefixes |
f3e0 | 50 73 72 30 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 63 61 6c 6c | Psr0)).{.............return.call |
f400 | 5f 75 73 65 72 5f 66 75 6e 63 5f 61 72 72 61 79 28 27 61 72 72 61 79 5f 6d 65 72 67 65 27 2c 20 | _user_func_array('array_merge',. |
f420 | 61 72 72 61 79 5f 76 61 6c 75 65 73 28 24 74 68 69 73 2d 3e 70 72 65 66 69 78 65 73 50 73 72 30 | array_values($this->prefixesPsr0 |
f440 | 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 61 72 | ));.........}..........return.ar |
f460 | 72 61 79 28 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 72 65 | ray();.....}....../**......*.@re |
f480 | 74 75 72 6e 20 61 72 72 61 79 5b 5d 0a 20 20 20 20 20 2a 20 40 70 73 61 6c 6d 2d 72 65 74 75 72 | turn.array[]......*.@psalm-retur |
f4a0 | 6e 20 61 72 72 61 79 3c 73 74 72 69 6e 67 2c 20 61 72 72 61 79 3c 69 6e 74 2c 20 73 74 72 69 6e | n.array<string,.array<int,.strin |
f4c0 | 67 3e 3e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 | g>>......*/.....public.function. |
f4e0 | 67 65 74 50 72 65 66 69 78 65 73 50 73 72 34 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | getPrefixesPsr4().....{......... |
f500 | 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 70 72 65 66 69 78 44 69 72 73 50 73 72 34 3b 0a 20 20 | return.$this->prefixDirsPsr4;... |
f520 | 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 61 72 72 61 | ..}....../**......*.@return.arra |
f540 | 79 5b 5d 0a 20 20 20 20 20 2a 20 40 70 73 61 6c 6d 2d 72 65 74 75 72 6e 20 61 72 72 61 79 3c 73 | y[]......*.@psalm-return.array<s |
f560 | 74 72 69 6e 67 2c 20 73 74 72 69 6e 67 3e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 | tring,.string>......*/.....publi |
f580 | 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 46 61 6c 6c 62 61 63 6b 44 69 72 73 28 29 0a 20 20 20 | c.function.getFallbackDirs().... |
f5a0 | 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 66 61 6c 6c 62 61 63 | .{.........return.$this->fallbac |
f5c0 | 6b 44 69 72 73 50 73 72 30 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a | kDirsPsr0;.....}....../**......* |
f5e0 | 20 40 72 65 74 75 72 6e 20 61 72 72 61 79 5b 5d 0a 20 20 20 20 20 2a 20 40 70 73 61 6c 6d 2d 72 | .@return.array[]......*.@psalm-r |
f600 | 65 74 75 72 6e 20 61 72 72 61 79 3c 73 74 72 69 6e 67 2c 20 73 74 72 69 6e 67 3e 0a 20 20 20 20 | eturn.array<string,.string>..... |
f620 | 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 46 61 6c 6c 62 | .*/.....public.function.getFallb |
f640 | 61 63 6b 44 69 72 73 50 73 72 34 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 | ackDirsPsr4().....{.........retu |
f660 | 72 6e 20 24 74 68 69 73 2d 3e 66 61 6c 6c 62 61 63 6b 44 69 72 73 50 73 72 34 3b 0a 20 20 20 20 | rn.$this->fallbackDirsPsr4;..... |
f680 | 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 | }....../**......*.@return.string |
f6a0 | 5b 5d 20 41 72 72 61 79 20 6f 66 20 63 6c 61 73 73 6e 61 6d 65 20 3d 3e 20 70 61 74 68 0a 20 20 | [].Array.of.classname.=>.path... |
f6c0 | 20 20 20 2a 20 40 70 73 61 6c 6d 2d 72 65 74 75 72 6e 20 61 72 72 61 79 3c 73 74 72 69 6e 67 2c | ...*.@psalm-return.array<string, |
f6e0 | 20 73 74 72 69 6e 67 3e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 | .string>......*/.....public.func |
f700 | 74 69 6f 6e 20 67 65 74 43 6c 61 73 73 4d 61 70 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 | tion.getClassMap().....{........ |
f720 | 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 63 6c 61 73 73 4d 61 70 3b 0a 20 20 20 20 7d 0a 0a | .return.$this->classMap;.....}.. |
f740 | 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 5b 5d 20 24 | ..../**......*.@param.string[].$ |
f760 | 63 6c 61 73 73 4d 61 70 20 43 6c 61 73 73 20 74 6f 20 66 69 6c 65 6e 61 6d 65 20 6d 61 70 0a 20 | classMap.Class.to.filename.map.. |
f780 | 20 20 20 20 2a 20 40 70 73 61 6c 6d 2d 70 61 72 61 6d 20 61 72 72 61 79 3c 73 74 72 69 6e 67 2c | ....*.@psalm-param.array<string, |
f7a0 | 20 73 74 72 69 6e 67 3e 20 24 63 6c 61 73 73 4d 61 70 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a | .string>.$classMap......*......* |
f7c0 | 20 40 72 65 74 75 72 6e 20 76 6f 69 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 | .@return.void......*/.....public |
f7e0 | 20 66 75 6e 63 74 69 6f 6e 20 61 64 64 43 6c 61 73 73 4d 61 70 28 61 72 72 61 79 20 24 63 6c 61 | .function.addClassMap(array.$cla |
f800 | 73 73 4d 61 70 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 74 68 69 73 2d 3e | ssMap).....{.........if.($this-> |
f820 | 63 6c 61 73 73 4d 61 70 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 63 | classMap).{.............$this->c |
f840 | 6c 61 73 73 4d 61 70 20 3d 20 61 72 72 61 79 5f 6d 65 72 67 65 28 24 74 68 69 73 2d 3e 63 6c 61 | lassMap.=.array_merge($this->cla |
f860 | 73 73 4d 61 70 2c 20 24 63 6c 61 73 73 4d 61 70 29 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 | ssMap,.$classMap);.........}.els |
f880 | 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 63 6c 61 73 73 4d 61 70 20 | e.{.............$this->classMap. |
f8a0 | 3d 20 24 63 6c 61 73 73 4d 61 70 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 | =.$classMap;.........}.....}.... |
f8c0 | 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 67 69 73 74 65 72 73 20 61 20 73 65 74 20 6f 66 20 | ../**......*.Registers.a.set.of. |
f8e0 | 50 53 52 2d 30 20 64 69 72 65 63 74 6f 72 69 65 73 20 66 6f 72 20 61 20 67 69 76 65 6e 20 70 72 | PSR-0.directories.for.a.given.pr |
f900 | 65 66 69 78 2c 20 65 69 74 68 65 72 0a 20 20 20 20 20 2a 20 61 70 70 65 6e 64 69 6e 67 20 6f 72 | efix,.either......*.appending.or |
f920 | 20 70 72 65 70 65 6e 64 69 6e 67 20 74 6f 20 74 68 65 20 6f 6e 65 73 20 70 72 65 76 69 6f 75 73 | .prepending.to.the.ones.previous |
f940 | 6c 79 20 73 65 74 20 66 6f 72 20 74 68 69 73 20 70 72 65 66 69 78 2e 0a 20 20 20 20 20 2a 0a 20 | ly.set.for.this.prefix.......*.. |
f960 | 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 20 20 20 20 20 20 20 20 20 24 70 72 | ....*.@param.string..........$pr |
f980 | 65 66 69 78 20 20 54 68 65 20 70 72 65 66 69 78 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 | efix..The.prefix......*.@param.s |
f9a0 | 74 72 69 6e 67 5b 5d 7c 73 74 72 69 6e 67 20 24 70 61 74 68 73 20 20 20 54 68 65 20 50 53 52 2d | tring[]|string.$paths...The.PSR- |
f9c0 | 30 20 72 6f 6f 74 20 64 69 72 65 63 74 6f 72 69 65 73 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d | 0.root.directories......*.@param |
f9e0 | 20 62 6f 6f 6c 20 20 20 20 20 20 20 20 20 20 20 20 24 70 72 65 70 65 6e 64 20 57 68 65 74 68 65 | .bool............$prepend.Whethe |
fa00 | 72 20 74 6f 20 70 72 65 70 65 6e 64 20 74 68 65 20 64 69 72 65 63 74 6f 72 69 65 73 0a 20 20 20 | r.to.prepend.the.directories.... |
fa20 | 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 76 6f 69 64 0a 20 20 20 20 20 2a 2f 0a | ..*......*.@return.void......*/. |
fa40 | 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 61 64 64 28 24 70 72 65 66 69 78 2c | ....public.function.add($prefix, |
fa60 | 20 24 70 61 74 68 73 2c 20 24 70 72 65 70 65 6e 64 20 3d 20 66 61 6c 73 65 29 0a 20 20 20 20 7b | .$paths,.$prepend.=.false).....{ |
fa80 | 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 24 70 72 65 66 69 78 29 20 7b 0a 20 20 20 20 20 20 20 | .........if.(!$prefix).{........ |
faa0 | 20 20 20 20 20 69 66 20 28 24 70 72 65 70 65 6e 64 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | .....if.($prepend).{............ |
fac0 | 20 20 20 20 20 24 74 68 69 73 2d 3e 66 61 6c 6c 62 61 63 6b 44 69 72 73 50 73 72 30 20 3d 20 61 | .....$this->fallbackDirsPsr0.=.a |
fae0 | 72 72 61 79 5f 6d 65 72 67 65 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | rray_merge(..................... |
fb00 | 28 61 72 72 61 79 29 20 24 70 61 74 68 73 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | (array).$paths,................. |
fb20 | 20 20 20 20 24 74 68 69 73 2d 3e 66 61 6c 6c 62 61 63 6b 44 69 72 73 50 73 72 30 0a 20 20 20 20 | ....$this->fallbackDirsPsr0..... |
fb40 | 20 20 20 20 20 20 20 20 20 20 20 20 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 | ............);.............}.els |
fb60 | 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 66 61 6c 6c 62 | e.{.................$this->fallb |
fb80 | 61 63 6b 44 69 72 73 50 73 72 30 20 3d 20 61 72 72 61 79 5f 6d 65 72 67 65 28 0a 20 20 20 20 20 | ackDirsPsr0.=.array_merge(...... |
fba0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 66 61 6c 6c 62 61 63 6b 44 69 | ...............$this->fallbackDi |
fbc0 | 72 73 50 73 72 30 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 28 61 72 72 | rsPsr0,.....................(arr |
fbe0 | 61 79 29 20 24 70 61 74 68 73 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 29 3b 0a 20 20 | ay).$paths.................);... |
fc00 | 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 3b | ..........}..............return; |
fc20 | 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 66 69 72 73 74 20 3d 20 24 70 72 | .........}..........$first.=.$pr |
fc40 | 65 66 69 78 5b 30 5d 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 69 73 73 65 74 28 24 74 68 69 | efix[0];.........if.(!isset($thi |
fc60 | 73 2d 3e 70 72 65 66 69 78 65 73 50 73 72 30 5b 24 66 69 72 73 74 5d 5b 24 70 72 65 66 69 78 5d | s->prefixesPsr0[$first][$prefix] |
fc80 | 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 70 72 65 66 69 78 65 73 | )).{.............$this->prefixes |
fca0 | 50 73 72 30 5b 24 66 69 72 73 74 5d 5b 24 70 72 65 66 69 78 5d 20 3d 20 28 61 72 72 61 79 29 20 | Psr0[$first][$prefix].=.(array). |
fcc0 | 24 70 61 74 68 73 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 3b 0a 20 20 20 | $paths;..............return;.... |
fce0 | 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 70 72 65 70 65 6e 64 29 20 7b 0a 20 | .....}.........if.($prepend).{.. |
fd00 | 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 70 72 65 66 69 78 65 73 50 73 72 30 5b 24 | ...........$this->prefixesPsr0[$ |
fd20 | 66 69 72 73 74 5d 5b 24 70 72 65 66 69 78 5d 20 3d 20 61 72 72 61 79 5f 6d 65 72 67 65 28 0a 20 | first][$prefix].=.array_merge(.. |
fd40 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 28 61 72 72 61 79 29 20 24 70 61 74 68 73 2c 0a 20 | ...............(array).$paths,.. |
fd60 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 70 72 65 66 69 78 65 73 50 73 | ...............$this->prefixesPs |
fd80 | 72 30 5b 24 66 69 72 73 74 5d 5b 24 70 72 65 66 69 78 5d 0a 20 20 20 20 20 20 20 20 20 20 20 20 | r0[$first][$prefix]............. |
fda0 | 29 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | );.........}.else.{............. |
fdc0 | 24 74 68 69 73 2d 3e 70 72 65 66 69 78 65 73 50 73 72 30 5b 24 66 69 72 73 74 5d 5b 24 70 72 65 | $this->prefixesPsr0[$first][$pre |
fde0 | 66 69 78 5d 20 3d 20 61 72 72 61 79 5f 6d 65 72 67 65 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 | fix].=.array_merge(............. |
fe00 | 20 20 20 20 24 74 68 69 73 2d 3e 70 72 65 66 69 78 65 73 50 73 72 30 5b 24 66 69 72 73 74 5d 5b | ....$this->prefixesPsr0[$first][ |
fe20 | 24 70 72 65 66 69 78 5d 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 28 61 72 72 61 79 | $prefix],.................(array |
fe40 | 29 20 24 70 61 74 68 73 0a 20 20 20 20 20 20 20 20 20 20 20 20 29 3b 0a 20 20 20 20 20 20 20 20 | ).$paths.............);......... |
fe60 | 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 67 69 73 74 65 72 | }.....}....../**......*.Register |
fe80 | 73 20 61 20 73 65 74 20 6f 66 20 50 53 52 2d 34 20 64 69 72 65 63 74 6f 72 69 65 73 20 66 6f 72 | s.a.set.of.PSR-4.directories.for |
fea0 | 20 61 20 67 69 76 65 6e 20 6e 61 6d 65 73 70 61 63 65 2c 20 65 69 74 68 65 72 0a 20 20 20 20 20 | .a.given.namespace,.either...... |
fec0 | 2a 20 61 70 70 65 6e 64 69 6e 67 20 6f 72 20 70 72 65 70 65 6e 64 69 6e 67 20 74 6f 20 74 68 65 | *.appending.or.prepending.to.the |
fee0 | 20 6f 6e 65 73 20 70 72 65 76 69 6f 75 73 6c 79 20 73 65 74 20 66 6f 72 20 74 68 69 73 20 6e 61 | .ones.previously.set.for.this.na |
ff00 | 6d 65 73 70 61 63 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 | mespace.......*......*.@param.st |
ff20 | 72 69 6e 67 20 20 20 20 20 20 20 20 20 20 24 70 72 65 66 69 78 20 20 54 68 65 20 70 72 65 66 69 | ring..........$prefix..The.prefi |
ff40 | 78 2f 6e 61 6d 65 73 70 61 63 65 2c 20 77 69 74 68 20 74 72 61 69 6c 69 6e 67 20 27 5c 5c 27 0a | x/namespace,.with.trailing.'\\'. |
ff60 | 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 5b 5d 7c 73 74 72 69 6e 67 20 24 70 | .....*.@param.string[]|string.$p |
ff80 | 61 74 68 73 20 20 20 54 68 65 20 50 53 52 2d 34 20 62 61 73 65 20 64 69 72 65 63 74 6f 72 69 65 | aths...The.PSR-4.base.directorie |
ffa0 | 73 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 62 6f 6f 6c 20 20 20 20 20 20 20 20 20 20 20 20 | s......*.@param.bool............ |
ffc0 | 24 70 72 65 70 65 6e 64 20 57 68 65 74 68 65 72 20 74 6f 20 70 72 65 70 65 6e 64 20 74 68 65 20 | $prepend.Whether.to.prepend.the. |
ffe0 | 64 69 72 65 63 74 6f 72 69 65 73 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 | directories......*......*.@throw |
10000 | 73 20 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 0a 20 20 20 20 | s.\InvalidArgumentException..... |
10020 | 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 76 6f 69 64 0a 20 20 20 20 20 2a 2f 0a 20 | .*......*.@return.void......*/.. |
10040 | 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 61 64 64 50 73 72 34 28 24 70 72 65 66 | ...public.function.addPsr4($pref |
10060 | 69 78 2c 20 24 70 61 74 68 73 2c 20 24 70 72 65 70 65 6e 64 20 3d 20 66 61 6c 73 65 29 0a 20 20 | ix,.$paths,.$prepend.=.false)... |
10080 | 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 24 70 72 65 66 69 78 29 20 7b 0a 20 20 20 20 | ..{.........if.(!$prefix).{..... |
100a0 | 20 20 20 20 20 20 20 20 2f 2f 20 52 65 67 69 73 74 65 72 20 64 69 72 65 63 74 6f 72 69 65 73 20 | ........//.Register.directories. |
100c0 | 66 6f 72 20 74 68 65 20 72 6f 6f 74 20 6e 61 6d 65 73 70 61 63 65 2e 0a 20 20 20 20 20 20 20 20 | for.the.root.namespace.......... |
100e0 | 20 20 20 20 69 66 20 28 24 70 72 65 70 65 6e 64 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ....if.($prepend).{............. |
10100 | 20 20 20 20 24 74 68 69 73 2d 3e 66 61 6c 6c 62 61 63 6b 44 69 72 73 50 73 72 34 20 3d 20 61 72 | ....$this->fallbackDirsPsr4.=.ar |
10120 | 72 61 79 5f 6d 65 72 67 65 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 28 | ray_merge(.....................( |
10140 | 61 72 72 61 79 29 20 24 70 61 74 68 73 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | array).$paths,.................. |
10160 | 20 20 20 24 74 68 69 73 2d 3e 66 61 6c 6c 62 61 63 6b 44 69 72 73 50 73 72 34 0a 20 20 20 20 20 | ...$this->fallbackDirsPsr4...... |
10180 | 20 20 20 20 20 20 20 20 20 20 20 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 | ...........);.............}.else |
101a0 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 66 61 6c 6c 62 61 | .{.................$this->fallba |
101c0 | 63 6b 44 69 72 73 50 73 72 34 20 3d 20 61 72 72 61 79 5f 6d 65 72 67 65 28 0a 20 20 20 20 20 20 | ckDirsPsr4.=.array_merge(....... |
101e0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 66 61 6c 6c 62 61 63 6b 44 69 72 | ..............$this->fallbackDir |
10200 | 73 50 73 72 34 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 28 61 72 72 61 | sPsr4,.....................(arra |
10220 | 79 29 20 24 70 61 74 68 73 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 29 3b 0a 20 20 20 | y).$paths.................);.... |
10240 | 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 21 69 73 | .........}.........}.elseif.(!is |
10260 | 73 65 74 28 24 74 68 69 73 2d 3e 70 72 65 66 69 78 44 69 72 73 50 73 72 34 5b 24 70 72 65 66 69 | set($this->prefixDirsPsr4[$prefi |
10280 | 78 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 52 65 67 69 73 74 65 72 20 64 | x])).{.............//.Register.d |
102a0 | 69 72 65 63 74 6f 72 69 65 73 20 66 6f 72 20 61 20 6e 65 77 20 6e 61 6d 65 73 70 61 63 65 2e 0a | irectories.for.a.new.namespace.. |
102c0 | 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 65 6e 67 74 68 20 3d 20 73 74 72 6c 65 6e 28 24 70 72 | ............$length.=.strlen($pr |
102e0 | 65 66 69 78 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 27 5c 5c 27 20 21 3d 3d 20 | efix);.............if.('\\'.!==. |
10300 | 24 70 72 65 66 69 78 5b 24 6c 65 6e 67 74 68 20 2d 20 31 5d 29 20 7b 0a 20 20 20 20 20 20 20 20 | $prefix[$length.-.1]).{......... |
10320 | 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 | ........throw.new.\InvalidArgume |
10340 | 6e 74 45 78 63 65 70 74 69 6f 6e 28 22 41 20 6e 6f 6e 2d 65 6d 70 74 79 20 50 53 52 2d 34 20 70 | ntException("A.non-empty.PSR-4.p |
10360 | 72 65 66 69 78 20 6d 75 73 74 20 65 6e 64 20 77 69 74 68 20 61 20 6e 61 6d 65 73 70 61 63 65 20 | refix.must.end.with.a.namespace. |
10380 | 73 65 70 61 72 61 74 6f 72 2e 22 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 | separator.");.............}..... |
103a0 | 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 70 72 65 66 69 78 4c 65 6e 67 74 68 73 50 73 72 34 | ........$this->prefixLengthsPsr4 |
103c0 | 5b 24 70 72 65 66 69 78 5b 30 5d 5d 5b 24 70 72 65 66 69 78 5d 20 3d 20 24 6c 65 6e 67 74 68 3b | [$prefix[0]][$prefix].=.$length; |
103e0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 70 72 65 66 69 78 44 69 72 73 50 73 | .............$this->prefixDirsPs |
10400 | 72 34 5b 24 70 72 65 66 69 78 5d 20 3d 20 28 61 72 72 61 79 29 20 24 70 61 74 68 73 3b 0a 20 20 | r4[$prefix].=.(array).$paths;... |
10420 | 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 24 70 72 65 70 65 6e 64 29 20 7b 0a 20 20 20 20 | ......}.elseif.($prepend).{..... |
10440 | 20 20 20 20 20 20 20 20 2f 2f 20 50 72 65 70 65 6e 64 20 64 69 72 65 63 74 6f 72 69 65 73 20 66 | ........//.Prepend.directories.f |
10460 | 6f 72 20 61 6e 20 61 6c 72 65 61 64 79 20 72 65 67 69 73 74 65 72 65 64 20 6e 61 6d 65 73 70 61 | or.an.already.registered.namespa |
10480 | 63 65 2e 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 70 72 65 66 69 78 44 69 72 | ce..............$this->prefixDir |
104a0 | 73 50 73 72 34 5b 24 70 72 65 66 69 78 5d 20 3d 20 61 72 72 61 79 5f 6d 65 72 67 65 28 0a 20 20 | sPsr4[$prefix].=.array_merge(... |
104c0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 28 61 72 72 61 79 29 20 24 70 61 74 68 73 2c 0a 20 20 | ..............(array).$paths,... |
104e0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 70 72 65 66 69 78 44 69 72 73 50 | ..............$this->prefixDirsP |
10500 | 73 72 34 5b 24 70 72 65 66 69 78 5d 0a 20 20 20 20 20 20 20 20 20 20 20 20 29 3b 0a 20 20 20 20 | sr4[$prefix].............);..... |
10520 | 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 41 70 70 65 | ....}.else.{.............//.Appe |
10540 | 6e 64 20 64 69 72 65 63 74 6f 72 69 65 73 20 66 6f 72 20 61 6e 20 61 6c 72 65 61 64 79 20 72 65 | nd.directories.for.an.already.re |
10560 | 67 69 73 74 65 72 65 64 20 6e 61 6d 65 73 70 61 63 65 2e 0a 20 20 20 20 20 20 20 20 20 20 20 20 | gistered.namespace.............. |
10580 | 24 74 68 69 73 2d 3e 70 72 65 66 69 78 44 69 72 73 50 73 72 34 5b 24 70 72 65 66 69 78 5d 20 3d | $this->prefixDirsPsr4[$prefix].= |
105a0 | 20 61 72 72 61 79 5f 6d 65 72 67 65 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 | .array_merge(.................$t |
105c0 | 68 69 73 2d 3e 70 72 65 66 69 78 44 69 72 73 50 73 72 34 5b 24 70 72 65 66 69 78 5d 2c 0a 20 20 | his->prefixDirsPsr4[$prefix],... |
105e0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 28 61 72 72 61 79 29 20 24 70 61 74 68 73 0a 20 20 20 | ..............(array).$paths.... |
10600 | 20 20 20 20 20 20 20 20 20 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 | .........);.........}.....}..... |
10620 | 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 67 69 73 74 65 72 73 20 61 20 73 65 74 20 6f 66 20 50 | ./**......*.Registers.a.set.of.P |
10640 | 53 52 2d 30 20 64 69 72 65 63 74 6f 72 69 65 73 20 66 6f 72 20 61 20 67 69 76 65 6e 20 70 72 65 | SR-0.directories.for.a.given.pre |
10660 | 66 69 78 2c 0a 20 20 20 20 20 2a 20 72 65 70 6c 61 63 69 6e 67 20 61 6e 79 20 6f 74 68 65 72 73 | fix,......*.replacing.any.others |
10680 | 20 70 72 65 76 69 6f 75 73 6c 79 20 73 65 74 20 66 6f 72 20 74 68 69 73 20 70 72 65 66 69 78 2e | .previously.set.for.this.prefix. |
106a0 | 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 20 20 20 | ......*......*.@param.string.... |
106c0 | 20 20 20 20 20 20 24 70 72 65 66 69 78 20 54 68 65 20 70 72 65 66 69 78 0a 20 20 20 20 20 2a 20 | ......$prefix.The.prefix......*. |
106e0 | 40 70 61 72 61 6d 20 73 74 72 69 6e 67 5b 5d 7c 73 74 72 69 6e 67 20 24 70 61 74 68 73 20 20 54 | @param.string[]|string.$paths..T |
10700 | 68 65 20 50 53 52 2d 30 20 62 61 73 65 20 64 69 72 65 63 74 6f 72 69 65 73 0a 20 20 20 20 20 2a | he.PSR-0.base.directories......* |
10720 | 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 76 6f 69 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 | ......*.@return.void......*/.... |
10740 | 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 28 24 70 72 65 66 69 78 2c 20 24 70 | .public.function.set($prefix,.$p |
10760 | 61 74 68 73 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 24 70 72 65 66 69 78 | aths).....{.........if.(!$prefix |
10780 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 66 61 6c 6c 62 61 63 6b 44 | ).{.............$this->fallbackD |
107a0 | 69 72 73 50 73 72 30 20 3d 20 28 61 72 72 61 79 29 20 24 70 61 74 68 73 3b 0a 20 20 20 20 20 20 | irsPsr0.=.(array).$paths;....... |
107c0 | 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 70 72 | ..}.else.{.............$this->pr |
107e0 | 65 66 69 78 65 73 50 73 72 30 5b 24 70 72 65 66 69 78 5b 30 5d 5d 5b 24 70 72 65 66 69 78 5d 20 | efixesPsr0[$prefix[0]][$prefix]. |
10800 | 3d 20 28 61 72 72 61 79 29 20 24 70 61 74 68 73 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 | =.(array).$paths;.........}..... |
10820 | 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 67 69 73 74 65 72 73 20 61 20 73 65 | }....../**......*.Registers.a.se |
10840 | 74 20 6f 66 20 50 53 52 2d 34 20 64 69 72 65 63 74 6f 72 69 65 73 20 66 6f 72 20 61 20 67 69 76 | t.of.PSR-4.directories.for.a.giv |
10860 | 65 6e 20 6e 61 6d 65 73 70 61 63 65 2c 0a 20 20 20 20 20 2a 20 72 65 70 6c 61 63 69 6e 67 20 61 | en.namespace,......*.replacing.a |
10880 | 6e 79 20 6f 74 68 65 72 73 20 70 72 65 76 69 6f 75 73 6c 79 20 73 65 74 20 66 6f 72 20 74 68 69 | ny.others.previously.set.for.thi |
108a0 | 73 20 6e 61 6d 65 73 70 61 63 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 | s.namespace.......*......*.@para |
108c0 | 6d 20 73 74 72 69 6e 67 20 20 20 20 20 20 20 20 20 20 24 70 72 65 66 69 78 20 54 68 65 20 70 72 | m.string..........$prefix.The.pr |
108e0 | 65 66 69 78 2f 6e 61 6d 65 73 70 61 63 65 2c 20 77 69 74 68 20 74 72 61 69 6c 69 6e 67 20 27 5c | efix/namespace,.with.trailing.'\ |
10900 | 5c 27 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 5b 5d 7c 73 74 72 69 6e 67 | \'......*.@param.string[]|string |
10920 | 20 24 70 61 74 68 73 20 20 54 68 65 20 50 53 52 2d 34 20 62 61 73 65 20 64 69 72 65 63 74 6f 72 | .$paths..The.PSR-4.base.director |
10940 | 69 65 73 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 5c 49 6e 76 61 6c | ies......*......*.@throws.\Inval |
10960 | 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 | idArgumentException......*...... |
10980 | 2a 20 40 72 65 74 75 72 6e 20 76 6f 69 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 | *.@return.void......*/.....publi |
109a0 | 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 50 73 72 34 28 24 70 72 65 66 69 78 2c 20 24 70 61 74 | c.function.setPsr4($prefix,.$pat |
109c0 | 68 73 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 24 70 72 65 66 69 78 29 20 | hs).....{.........if.(!$prefix). |
109e0 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 66 61 6c 6c 62 61 63 6b 44 69 72 | {.............$this->fallbackDir |
10a00 | 73 50 73 72 34 20 3d 20 28 61 72 72 61 79 29 20 24 70 61 74 68 73 3b 0a 20 20 20 20 20 20 20 20 | sPsr4.=.(array).$paths;......... |
10a20 | 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 65 6e 67 74 68 20 3d 20 73 | }.else.{.............$length.=.s |
10a40 | 74 72 6c 65 6e 28 24 70 72 65 66 69 78 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 | trlen($prefix);.............if.( |
10a60 | 27 5c 5c 27 20 21 3d 3d 20 24 70 72 65 66 69 78 5b 24 6c 65 6e 67 74 68 20 2d 20 31 5d 29 20 7b | '\\'.!==.$prefix[$length.-.1]).{ |
10a80 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 5c 49 6e 76 61 | .................throw.new.\Inva |
10aa0 | 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 22 41 20 6e 6f 6e 2d 65 6d 70 74 | lidArgumentException("A.non-empt |
10ac0 | 79 20 50 53 52 2d 34 20 70 72 65 66 69 78 20 6d 75 73 74 20 65 6e 64 20 77 69 74 68 20 61 20 6e | y.PSR-4.prefix.must.end.with.a.n |
10ae0 | 61 6d 65 73 70 61 63 65 20 73 65 70 61 72 61 74 6f 72 2e 22 29 3b 0a 20 20 20 20 20 20 20 20 20 | amespace.separator.");.......... |
10b00 | 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 70 72 65 66 69 78 4c 65 | ...}.............$this->prefixLe |
10b20 | 6e 67 74 68 73 50 73 72 34 5b 24 70 72 65 66 69 78 5b 30 5d 5d 5b 24 70 72 65 66 69 78 5d 20 3d | ngthsPsr4[$prefix[0]][$prefix].= |
10b40 | 20 24 6c 65 6e 67 74 68 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 70 72 65 | .$length;.............$this->pre |
10b60 | 66 69 78 44 69 72 73 50 73 72 34 5b 24 70 72 65 66 69 78 5d 20 3d 20 28 61 72 72 61 79 29 20 24 | fixDirsPsr4[$prefix].=.(array).$ |
10b80 | 70 61 74 68 73 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a | paths;.........}.....}....../**. |
10ba0 | 20 20 20 20 20 2a 20 54 75 72 6e 73 20 6f 6e 20 73 65 61 72 63 68 69 6e 67 20 74 68 65 20 69 6e | .....*.Turns.on.searching.the.in |
10bc0 | 63 6c 75 64 65 20 70 61 74 68 20 66 6f 72 20 63 6c 61 73 73 20 66 69 6c 65 73 2e 0a 20 20 20 20 | clude.path.for.class.files...... |
10be0 | 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 62 6f 6f 6c 20 24 75 73 65 49 6e 63 6c 75 64 | .*......*.@param.bool.$useInclud |
10c00 | 65 50 61 74 68 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 76 6f 69 64 | ePath......*......*.@return.void |
10c20 | 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 | ......*/.....public.function.set |
10c40 | 55 73 65 49 6e 63 6c 75 64 65 50 61 74 68 28 24 75 73 65 49 6e 63 6c 75 64 65 50 61 74 68 29 0a | UseIncludePath($useIncludePath). |
10c60 | 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 75 73 65 49 6e 63 6c 75 64 65 50 | ....{.........$this->useIncludeP |
10c80 | 61 74 68 20 3d 20 24 75 73 65 49 6e 63 6c 75 64 65 50 61 74 68 3b 0a 20 20 20 20 7d 0a 0a 20 20 | ath.=.$useIncludePath;.....}.... |
10ca0 | 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 43 61 6e 20 62 65 20 75 73 65 64 20 74 6f 20 63 68 65 63 | ../**......*.Can.be.used.to.chec |
10cc0 | 6b 20 69 66 20 74 68 65 20 61 75 74 6f 6c 6f 61 64 65 72 20 75 73 65 73 20 74 68 65 20 69 6e 63 | k.if.the.autoloader.uses.the.inc |
10ce0 | 6c 75 64 65 20 70 61 74 68 20 74 6f 20 63 68 65 63 6b 0a 20 20 20 20 20 2a 20 66 6f 72 20 63 6c | lude.path.to.check......*.for.cl |
10d00 | 61 73 73 65 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 62 6f 6f | asses.......*......*.@return.boo |
10d20 | 6c 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 | l......*/.....public.function.ge |
10d40 | 74 55 73 65 49 6e 63 6c 75 64 65 50 61 74 68 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | tUseIncludePath().....{......... |
10d60 | 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 75 73 65 49 6e 63 6c 75 64 65 50 61 74 68 3b 0a 20 20 | return.$this->useIncludePath;... |
10d80 | 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 54 75 72 6e 73 20 6f 66 66 20 73 65 | ..}....../**......*.Turns.off.se |
10da0 | 61 72 63 68 69 6e 67 20 74 68 65 20 70 72 65 66 69 78 20 61 6e 64 20 66 61 6c 6c 62 61 63 6b 20 | arching.the.prefix.and.fallback. |
10dc0 | 64 69 72 65 63 74 6f 72 69 65 73 20 66 6f 72 20 63 6c 61 73 73 65 73 0a 20 20 20 20 20 2a 20 74 | directories.for.classes......*.t |
10de0 | 68 61 74 20 68 61 76 65 20 6e 6f 74 20 62 65 65 6e 20 72 65 67 69 73 74 65 72 65 64 20 77 69 74 | hat.have.not.been.registered.wit |
10e00 | 68 20 74 68 65 20 63 6c 61 73 73 20 6d 61 70 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 | h.the.class.map.......*......*.@ |
10e20 | 70 61 72 61 6d 20 62 6f 6f 6c 20 24 63 6c 61 73 73 4d 61 70 41 75 74 68 6f 72 69 74 61 74 69 76 | param.bool.$classMapAuthoritativ |
10e40 | 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 76 6f 69 64 0a 20 20 20 | e......*......*.@return.void.... |
10e60 | 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 43 6c 61 73 | ..*/.....public.function.setClas |
10e80 | 73 4d 61 70 41 75 74 68 6f 72 69 74 61 74 69 76 65 28 24 63 6c 61 73 73 4d 61 70 41 75 74 68 6f | sMapAuthoritative($classMapAutho |
10ea0 | 72 69 74 61 74 69 76 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 63 | ritative).....{.........$this->c |
10ec0 | 6c 61 73 73 4d 61 70 41 75 74 68 6f 72 69 74 61 74 69 76 65 20 3d 20 24 63 6c 61 73 73 4d 61 70 | lassMapAuthoritative.=.$classMap |
10ee0 | 41 75 74 68 6f 72 69 74 61 74 69 76 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 | Authoritative;.....}....../**... |
10f00 | 20 20 20 2a 20 53 68 6f 75 6c 64 20 63 6c 61 73 73 20 6c 6f 6f 6b 75 70 20 66 61 69 6c 20 69 66 | ...*.Should.class.lookup.fail.if |
10f20 | 20 6e 6f 74 20 66 6f 75 6e 64 20 69 6e 20 74 68 65 20 63 75 72 72 65 6e 74 20 63 6c 61 73 73 20 | .not.found.in.the.current.class. |
10f40 | 6d 61 70 3f 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 62 6f 6f 6c 0a | map?......*......*.@return.bool. |
10f60 | 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 69 73 43 6c | .....*/.....public.function.isCl |
10f80 | 61 73 73 4d 61 70 41 75 74 68 6f 72 69 74 61 74 69 76 65 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 | assMapAuthoritative().....{..... |
10fa0 | 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 63 6c 61 73 73 4d 61 70 41 75 74 68 6f 72 | ....return.$this->classMapAuthor |
10fc0 | 69 74 61 74 69 76 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 41 | itative;.....}....../**......*.A |
10fe0 | 50 43 75 20 70 72 65 66 69 78 20 74 6f 20 75 73 65 20 74 6f 20 63 61 63 68 65 20 66 6f 75 6e 64 | PCu.prefix.to.use.to.cache.found |
11000 | 2f 6e 6f 74 2d 66 6f 75 6e 64 20 63 6c 61 73 73 65 73 2c 20 69 66 20 74 68 65 20 65 78 74 65 6e | /not-found.classes,.if.the.exten |
11020 | 73 69 6f 6e 20 69 73 20 65 6e 61 62 6c 65 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 | sion.is.enabled.......*......*.@ |
11040 | 70 61 72 61 6d 20 73 74 72 69 6e 67 7c 6e 75 6c 6c 20 24 61 70 63 75 50 72 65 66 69 78 0a 20 20 | param.string|null.$apcuPrefix... |
11060 | 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 76 6f 69 64 0a 20 20 20 20 20 2a 2f | ...*......*.@return.void......*/ |
11080 | 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 41 70 63 75 50 72 65 66 | .....public.function.setApcuPref |
110a0 | 69 78 28 24 61 70 63 75 50 72 65 66 69 78 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 | ix($apcuPrefix).....{.........$t |
110c0 | 68 69 73 2d 3e 61 70 63 75 50 72 65 66 69 78 20 3d 20 66 75 6e 63 74 69 6f 6e 5f 65 78 69 73 74 | his->apcuPrefix.=.function_exist |
110e0 | 73 28 27 61 70 63 75 5f 66 65 74 63 68 27 29 20 26 26 20 66 69 6c 74 65 72 5f 76 61 72 28 69 6e | s('apcu_fetch').&&.filter_var(in |
11100 | 69 5f 67 65 74 28 27 61 70 63 2e 65 6e 61 62 6c 65 64 27 29 2c 20 46 49 4c 54 45 52 5f 56 41 4c | i_get('apc.enabled'),.FILTER_VAL |
11120 | 49 44 41 54 45 5f 42 4f 4f 4c 45 41 4e 29 20 3f 20 24 61 70 63 75 50 72 65 66 69 78 20 3a 20 6e | IDATE_BOOLEAN).?.$apcuPrefix.:.n |
11140 | 75 6c 6c 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 54 68 65 20 41 | ull;.....}....../**......*.The.A |
11160 | 50 43 75 20 70 72 65 66 69 78 20 69 6e 20 75 73 65 2c 20 6f 72 20 6e 75 6c 6c 20 69 66 20 41 50 | PCu.prefix.in.use,.or.null.if.AP |
11180 | 43 75 20 63 61 63 68 69 6e 67 20 69 73 20 6e 6f 74 20 65 6e 61 62 6c 65 64 2e 0a 20 20 20 20 20 | Cu.caching.is.not.enabled....... |
111a0 | 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 7c 6e 75 6c 6c 0a 20 20 20 | *......*.@return.string|null.... |
111c0 | 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 41 70 63 75 | ..*/.....public.function.getApcu |
111e0 | 50 72 65 66 69 78 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 | Prefix().....{.........return.$t |
11200 | 68 69 73 2d 3e 61 70 63 75 50 72 65 66 69 78 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a | his->apcuPrefix;.....}....../**. |
11220 | 20 20 20 20 20 2a 20 52 65 67 69 73 74 65 72 73 20 74 68 69 73 20 69 6e 73 74 61 6e 63 65 20 61 | .....*.Registers.this.instance.a |
11240 | 73 20 61 6e 20 61 75 74 6f 6c 6f 61 64 65 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 | s.an.autoloader.......*......*.@ |
11260 | 70 61 72 61 6d 20 62 6f 6f 6c 20 24 70 72 65 70 65 6e 64 20 57 68 65 74 68 65 72 20 74 6f 20 70 | param.bool.$prepend.Whether.to.p |
11280 | 72 65 70 65 6e 64 20 74 68 65 20 61 75 74 6f 6c 6f 61 64 65 72 20 6f 72 20 6e 6f 74 0a 20 20 20 | repend.the.autoloader.or.not.... |
112a0 | 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 76 6f 69 64 0a 20 20 20 20 20 2a 2f 0a | ..*......*.@return.void......*/. |
112c0 | 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 72 65 67 69 73 74 65 72 28 24 70 72 | ....public.function.register($pr |
112e0 | 65 70 65 6e 64 20 3d 20 66 61 6c 73 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 73 70 6c | epend.=.false).....{.........spl |
11300 | 5f 61 75 74 6f 6c 6f 61 64 5f 72 65 67 69 73 74 65 72 28 61 72 72 61 79 28 24 74 68 69 73 2c 20 | _autoload_register(array($this,. |
11320 | 27 6c 6f 61 64 43 6c 61 73 73 27 29 2c 20 74 72 75 65 2c 20 24 70 72 65 70 65 6e 64 29 3b 0a 0a | 'loadClass'),.true,.$prepend);.. |
11340 | 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 74 68 69 73 2d 3e 76 65 6e 64 | ........if.(null.===.$this->vend |
11360 | 6f 72 44 69 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 3b 0a 20 20 20 | orDir).{.............return;.... |
11380 | 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 70 72 65 70 65 6e 64 29 20 7b 0a | .....}..........if.($prepend).{. |
113a0 | 20 20 20 20 20 20 20 20 20 20 20 20 73 65 6c 66 3a 3a 24 72 65 67 69 73 74 65 72 65 64 4c 6f 61 | ............self::$registeredLoa |
113c0 | 64 65 72 73 20 3d 20 61 72 72 61 79 28 24 74 68 69 73 2d 3e 76 65 6e 64 6f 72 44 69 72 20 3d 3e | ders.=.array($this->vendorDir.=> |
113e0 | 20 24 74 68 69 73 29 20 2b 20 73 65 6c 66 3a 3a 24 72 65 67 69 73 74 65 72 65 64 4c 6f 61 64 65 | .$this).+.self::$registeredLoade |
11400 | 72 73 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | rs;.........}.else.{............ |
11420 | 20 75 6e 73 65 74 28 73 65 6c 66 3a 3a 24 72 65 67 69 73 74 65 72 65 64 4c 6f 61 64 65 72 73 5b | .unset(self::$registeredLoaders[ |
11440 | 24 74 68 69 73 2d 3e 76 65 6e 64 6f 72 44 69 72 5d 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | $this->vendorDir]);............. |
11460 | 73 65 6c 66 3a 3a 24 72 65 67 69 73 74 65 72 65 64 4c 6f 61 64 65 72 73 5b 24 74 68 69 73 2d 3e | self::$registeredLoaders[$this-> |
11480 | 76 65 6e 64 6f 72 44 69 72 5d 20 3d 20 24 74 68 69 73 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 | vendorDir].=.$this;.........}... |
114a0 | 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 55 6e 72 65 67 69 73 74 65 72 73 20 | ..}....../**......*.Unregisters. |
114c0 | 74 68 69 73 20 69 6e 73 74 61 6e 63 65 20 61 73 20 61 6e 20 61 75 74 6f 6c 6f 61 64 65 72 2e 0a | this.instance.as.an.autoloader.. |
114e0 | 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 76 6f 69 64 0a 20 20 20 20 20 | .....*......*.@return.void...... |
11500 | 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 75 6e 72 65 67 69 73 74 65 | */.....public.function.unregiste |
11520 | 72 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 73 70 6c 5f 61 75 74 6f 6c 6f 61 64 5f 75 | r().....{.........spl_autoload_u |
11540 | 6e 72 65 67 69 73 74 65 72 28 61 72 72 61 79 28 24 74 68 69 73 2c 20 27 6c 6f 61 64 43 6c 61 73 | nregister(array($this,.'loadClas |
11560 | 73 27 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 21 3d 3d 20 24 74 68 69 | s'));..........if.(null.!==.$thi |
11580 | 73 2d 3e 76 65 6e 64 6f 72 44 69 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 75 6e 73 65 | s->vendorDir).{.............unse |
115a0 | 74 28 73 65 6c 66 3a 3a 24 72 65 67 69 73 74 65 72 65 64 4c 6f 61 64 65 72 73 5b 24 74 68 69 73 | t(self::$registeredLoaders[$this |
115c0 | 2d 3e 76 65 6e 64 6f 72 44 69 72 5d 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a | ->vendorDir]);.........}.....}.. |
115e0 | 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 4c 6f 61 64 73 20 74 68 65 20 67 69 76 65 6e 20 63 | ..../**......*.Loads.the.given.c |
11600 | 6c 61 73 73 20 6f 72 20 69 6e 74 65 72 66 61 63 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a | lass.or.interface.......*......* |
11620 | 20 40 70 61 72 61 6d 20 20 73 74 72 69 6e 67 20 20 20 20 24 63 6c 61 73 73 20 54 68 65 20 6e 61 | .@param..string....$class.The.na |
11640 | 6d 65 20 6f 66 20 74 68 65 20 63 6c 61 73 73 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 74 | me.of.the.class......*.@return.t |
11660 | 72 75 65 7c 6e 75 6c 6c 20 54 72 75 65 20 69 66 20 6c 6f 61 64 65 64 2c 20 6e 75 6c 6c 20 6f 74 | rue|null.True.if.loaded,.null.ot |
11680 | 68 65 72 77 69 73 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 | herwise......*/.....public.funct |
116a0 | 69 6f 6e 20 6c 6f 61 64 43 6c 61 73 73 28 24 63 6c 61 73 73 29 0a 20 20 20 20 7b 0a 20 20 20 20 | ion.loadClass($class).....{..... |
116c0 | 20 20 20 20 69 66 20 28 24 66 69 6c 65 20 3d 20 24 74 68 69 73 2d 3e 66 69 6e 64 46 69 6c 65 28 | ....if.($file.=.$this->findFile( |
116e0 | 24 63 6c 61 73 73 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 6e 63 6c 75 64 65 46 69 | $class)).{.............includeFi |
11700 | 6c 65 28 24 66 69 6c 65 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 74 | le($file);..............return.t |
11720 | 72 75 65 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6e | rue;.........}..........return.n |
11740 | 75 6c 6c 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 46 69 6e 64 73 | ull;.....}....../**......*.Finds |
11760 | 20 74 68 65 20 70 61 74 68 20 74 6f 20 74 68 65 20 66 69 6c 65 20 77 68 65 72 65 20 74 68 65 20 | .the.path.to.the.file.where.the. |
11780 | 63 6c 61 73 73 20 69 73 20 64 65 66 69 6e 65 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 | class.is.defined.......*......*. |
117a0 | 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 63 6c 61 73 73 20 54 68 65 20 6e 61 6d 65 20 6f 66 | @param.string.$class.The.name.of |
117c0 | 20 74 68 65 20 63 6c 61 73 73 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e | .the.class......*......*.@return |
117e0 | 20 73 74 72 69 6e 67 7c 66 61 6c 73 65 20 54 68 65 20 70 61 74 68 20 69 66 20 66 6f 75 6e 64 2c | .string|false.The.path.if.found, |
11800 | 20 66 61 6c 73 65 20 6f 74 68 65 72 77 69 73 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 | .false.otherwise......*/.....pub |
11820 | 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 66 69 6e 64 46 69 6c 65 28 24 63 6c 61 73 73 29 0a 20 20 | lic.function.findFile($class)... |
11840 | 20 20 7b 0a 20 20 20 20 20 20 20 20 2f 2f 20 63 6c 61 73 73 20 6d 61 70 20 6c 6f 6f 6b 75 70 0a | ..{.........//.class.map.lookup. |
11860 | 20 20 20 20 20 20 20 20 69 66 20 28 69 73 73 65 74 28 24 74 68 69 73 2d 3e 63 6c 61 73 73 4d 61 | ........if.(isset($this->classMa |
11880 | 70 5b 24 63 6c 61 73 73 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e | p[$class])).{.............return |
118a0 | 20 24 74 68 69 73 2d 3e 63 6c 61 73 73 4d 61 70 5b 24 63 6c 61 73 73 5d 3b 0a 20 20 20 20 20 20 | .$this->classMap[$class];....... |
118c0 | 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 74 68 69 73 2d 3e 63 6c 61 73 73 4d 61 70 41 | ..}.........if.($this->classMapA |
118e0 | 75 74 68 6f 72 69 74 61 74 69 76 65 20 7c 7c 20 69 73 73 65 74 28 24 74 68 69 73 2d 3e 6d 69 73 | uthoritative.||.isset($this->mis |
11900 | 73 69 6e 67 43 6c 61 73 73 65 73 5b 24 63 6c 61 73 73 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 | singClasses[$class])).{......... |
11920 | 20 20 20 20 72 65 74 75 72 6e 20 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 | ....return.false;.........}..... |
11940 | 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 21 3d 3d 20 24 74 68 69 73 2d 3e 61 70 63 75 50 72 65 66 | ....if.(null.!==.$this->apcuPref |
11960 | 69 78 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 66 69 6c 65 20 3d 20 61 70 63 75 5f 66 | ix).{.............$file.=.apcu_f |
11980 | 65 74 63 68 28 24 74 68 69 73 2d 3e 61 70 63 75 50 72 65 66 69 78 2e 24 63 6c 61 73 73 2c 20 24 | etch($this->apcuPrefix.$class,.$ |
119a0 | 68 69 74 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 68 69 74 29 20 7b 0a 20 20 | hit);.............if.($hit).{... |
119c0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 66 69 6c 65 3b 0a 20 20 20 20 | ..............return.$file;..... |
119e0 | 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 66 69 | ........}.........}..........$fi |
11a00 | 6c 65 20 3d 20 24 74 68 69 73 2d 3e 66 69 6e 64 46 69 6c 65 57 69 74 68 45 78 74 65 6e 73 69 6f | le.=.$this->findFileWithExtensio |
11a20 | 6e 28 24 63 6c 61 73 73 2c 20 27 2e 70 68 70 27 29 3b 0a 0a 20 20 20 20 20 20 20 20 2f 2f 20 53 | n($class,.'.php');..........//.S |
11a40 | 65 61 72 63 68 20 66 6f 72 20 48 61 63 6b 20 66 69 6c 65 73 20 69 66 20 77 65 20 61 72 65 20 72 | earch.for.Hack.files.if.we.are.r |
11a60 | 75 6e 6e 69 6e 67 20 6f 6e 20 48 48 56 4d 0a 20 20 20 20 20 20 20 20 69 66 20 28 66 61 6c 73 65 | unning.on.HHVM.........if.(false |
11a80 | 20 3d 3d 3d 20 24 66 69 6c 65 20 26 26 20 64 65 66 69 6e 65 64 28 27 48 48 56 4d 5f 56 45 52 53 | .===.$file.&&.defined('HHVM_VERS |
11aa0 | 49 4f 4e 27 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 66 69 6c 65 20 3d 20 24 74 68 | ION')).{.............$file.=.$th |
11ac0 | 69 73 2d 3e 66 69 6e 64 46 69 6c 65 57 69 74 68 45 78 74 65 6e 73 69 6f 6e 28 24 63 6c 61 73 73 | is->findFileWithExtension($class |
11ae0 | 2c 20 27 2e 68 68 27 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 | ,.'.hh');.........}..........if. |
11b00 | 28 6e 75 6c 6c 20 21 3d 3d 20 24 74 68 69 73 2d 3e 61 70 63 75 50 72 65 66 69 78 29 20 7b 0a 20 | (null.!==.$this->apcuPrefix).{.. |
11b20 | 20 20 20 20 20 20 20 20 20 20 20 61 70 63 75 5f 61 64 64 28 24 74 68 69 73 2d 3e 61 70 63 75 50 | ...........apcu_add($this->apcuP |
11b40 | 72 65 66 69 78 2e 24 63 6c 61 73 73 2c 20 24 66 69 6c 65 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a | refix.$class,.$file);.........}. |
11b60 | 0a 20 20 20 20 20 20 20 20 69 66 20 28 66 61 6c 73 65 20 3d 3d 3d 20 24 66 69 6c 65 29 20 7b 0a | .........if.(false.===.$file).{. |
11b80 | 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 52 65 6d 65 6d 62 65 72 20 74 68 61 74 20 74 68 69 | ............//.Remember.that.thi |
11ba0 | 73 20 63 6c 61 73 73 20 64 6f 65 73 20 6e 6f 74 20 65 78 69 73 74 2e 0a 20 20 20 20 20 20 20 20 | s.class.does.not.exist.......... |
11bc0 | 20 20 20 20 24 74 68 69 73 2d 3e 6d 69 73 73 69 6e 67 43 6c 61 73 73 65 73 5b 24 63 6c 61 73 73 | ....$this->missingClasses[$class |
11be0 | 5d 20 3d 20 74 72 75 65 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 | ].=.true;.........}..........ret |
11c00 | 75 72 6e 20 24 66 69 6c 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a | urn.$file;.....}....../**......* |
11c20 | 20 52 65 74 75 72 6e 73 20 74 68 65 20 63 75 72 72 65 6e 74 6c 79 20 72 65 67 69 73 74 65 72 65 | .Returns.the.currently.registere |
11c40 | 64 20 6c 6f 61 64 65 72 73 20 69 6e 64 65 78 65 64 20 62 79 20 74 68 65 69 72 20 63 6f 72 72 65 | d.loaders.indexed.by.their.corre |
11c60 | 73 70 6f 6e 64 69 6e 67 20 76 65 6e 64 6f 72 20 64 69 72 65 63 74 6f 72 69 65 73 2e 0a 20 20 20 | sponding.vendor.directories..... |
11c80 | 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 65 6c 66 5b 5d 0a 20 20 20 20 20 2a | ..*......*.@return.self[]......* |
11ca0 | 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 | /.....public.static.function.get |
11cc0 | 52 65 67 69 73 74 65 72 65 64 4c 6f 61 64 65 72 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 | RegisteredLoaders().....{....... |
11ce0 | 20 20 72 65 74 75 72 6e 20 73 65 6c 66 3a 3a 24 72 65 67 69 73 74 65 72 65 64 4c 6f 61 64 65 72 | ..return.self::$registeredLoader |
11d00 | 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 | s;.....}....../**......*.@param. |
11d20 | 20 73 74 72 69 6e 67 20 20 20 20 20 20 20 24 63 6c 61 73 73 0a 20 20 20 20 20 2a 20 40 70 61 72 | .string.......$class......*.@par |
11d40 | 61 6d 20 20 73 74 72 69 6e 67 20 20 20 20 20 20 20 24 65 78 74 0a 20 20 20 20 20 2a 20 40 72 65 | am..string.......$ext......*.@re |
11d60 | 74 75 72 6e 20 73 74 72 69 6e 67 7c 66 61 6c 73 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 | turn.string|false......*/.....pr |
11d80 | 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 66 69 6e 64 46 69 6c 65 57 69 74 68 45 78 74 65 6e | ivate.function.findFileWithExten |
11da0 | 73 69 6f 6e 28 24 63 6c 61 73 73 2c 20 24 65 78 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 | sion($class,.$ext).....{........ |
11dc0 | 20 2f 2f 20 50 53 52 2d 34 20 6c 6f 6f 6b 75 70 0a 20 20 20 20 20 20 20 20 24 6c 6f 67 69 63 61 | .//.PSR-4.lookup.........$logica |
11de0 | 6c 50 61 74 68 50 73 72 34 20 3d 20 73 74 72 74 72 28 24 63 6c 61 73 73 2c 20 27 5c 5c 27 2c 20 | lPathPsr4.=.strtr($class,.'\\',. |
11e00 | 44 49 52 45 43 54 4f 52 59 5f 53 45 50 41 52 41 54 4f 52 29 20 2e 20 24 65 78 74 3b 0a 0a 20 20 | DIRECTORY_SEPARATOR)...$ext;.... |
11e20 | 20 20 20 20 20 20 24 66 69 72 73 74 20 3d 20 24 63 6c 61 73 73 5b 30 5d 3b 0a 20 20 20 20 20 20 | ......$first.=.$class[0];....... |
11e40 | 20 20 69 66 20 28 69 73 73 65 74 28 24 74 68 69 73 2d 3e 70 72 65 66 69 78 4c 65 6e 67 74 68 73 | ..if.(isset($this->prefixLengths |
11e60 | 50 73 72 34 5b 24 66 69 72 73 74 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 73 75 | Psr4[$first])).{.............$su |
11e80 | 62 50 61 74 68 20 3d 20 24 63 6c 61 73 73 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 77 68 69 6c | bPath.=.$class;.............whil |
11ea0 | 65 20 28 66 61 6c 73 65 20 21 3d 3d 20 24 6c 61 73 74 50 6f 73 20 3d 20 73 74 72 72 70 6f 73 28 | e.(false.!==.$lastPos.=.strrpos( |
11ec0 | 24 73 75 62 50 61 74 68 2c 20 27 5c 5c 27 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | $subPath,.'\\')).{.............. |
11ee0 | 20 20 20 24 73 75 62 50 61 74 68 20 3d 20 73 75 62 73 74 72 28 24 73 75 62 50 61 74 68 2c 20 30 | ...$subPath.=.substr($subPath,.0 |
11f00 | 2c 20 24 6c 61 73 74 50 6f 73 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 73 65 | ,.$lastPos);.................$se |
11f20 | 61 72 63 68 20 3d 20 24 73 75 62 50 61 74 68 20 2e 20 27 5c 5c 27 3b 0a 20 20 20 20 20 20 20 20 | arch.=.$subPath...'\\';......... |
11f40 | 20 20 20 20 20 20 20 20 69 66 20 28 69 73 73 65 74 28 24 74 68 69 73 2d 3e 70 72 65 66 69 78 44 | ........if.(isset($this->prefixD |
11f60 | 69 72 73 50 73 72 34 5b 24 73 65 61 72 63 68 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | irsPsr4[$search])).{............ |
11f80 | 20 20 20 20 20 20 20 20 20 24 70 61 74 68 45 6e 64 20 3d 20 44 49 52 45 43 54 4f 52 59 5f 53 45 | .........$pathEnd.=.DIRECTORY_SE |
11fa0 | 50 41 52 41 54 4f 52 20 2e 20 73 75 62 73 74 72 28 24 6c 6f 67 69 63 61 6c 50 61 74 68 50 73 72 | PARATOR...substr($logicalPathPsr |
11fc0 | 34 2c 20 24 6c 61 73 74 50 6f 73 20 2b 20 31 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | 4,.$lastPos.+.1);............... |
11fe0 | 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 74 68 69 73 2d 3e 70 72 65 66 69 78 44 69 72 73 | ......foreach.($this->prefixDirs |
12000 | 50 73 72 34 5b 24 73 65 61 72 63 68 5d 20 61 73 20 24 64 69 72 29 20 7b 0a 20 20 20 20 20 20 20 | Psr4[$search].as.$dir).{........ |
12020 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 66 69 6c 65 5f 65 78 69 73 74 73 | .................if.(file_exists |
12040 | 28 24 66 69 6c 65 20 3d 20 24 64 69 72 20 2e 20 24 70 61 74 68 45 6e 64 29 29 20 7b 0a 20 20 20 | ($file.=.$dir...$pathEnd)).{.... |
12060 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 | .........................return. |
12080 | 24 66 69 6c 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d | $file;.........................} |
120a0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 | .....................}.......... |
120c0 | 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d | .......}.............}.........} |
120e0 | 0a 0a 20 20 20 20 20 20 20 20 2f 2f 20 50 53 52 2d 34 20 66 61 6c 6c 62 61 63 6b 20 64 69 72 73 | ..........//.PSR-4.fallback.dirs |
12100 | 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 74 68 69 73 2d 3e 66 61 6c 6c 62 61 63 | .........foreach.($this->fallbac |
12120 | 6b 44 69 72 73 50 73 72 34 20 61 73 20 24 64 69 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | kDirsPsr4.as.$dir).{............ |
12140 | 20 69 66 20 28 66 69 6c 65 5f 65 78 69 73 74 73 28 24 66 69 6c 65 20 3d 20 24 64 69 72 20 2e 20 | .if.(file_exists($file.=.$dir... |
12160 | 44 49 52 45 43 54 4f 52 59 5f 53 45 50 41 52 41 54 4f 52 20 2e 20 24 6c 6f 67 69 63 61 6c 50 61 | DIRECTORY_SEPARATOR...$logicalPa |
12180 | 74 68 50 73 72 34 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 | thPsr4)).{.................retur |
121a0 | 6e 20 24 66 69 6c 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d | n.$file;.............}.........} |
121c0 | 0a 0a 20 20 20 20 20 20 20 20 2f 2f 20 50 53 52 2d 30 20 6c 6f 6f 6b 75 70 0a 20 20 20 20 20 20 | ..........//.PSR-0.lookup....... |
121e0 | 20 20 69 66 20 28 66 61 6c 73 65 20 21 3d 3d 20 24 70 6f 73 20 3d 20 73 74 72 72 70 6f 73 28 24 | ..if.(false.!==.$pos.=.strrpos($ |
12200 | 63 6c 61 73 73 2c 20 27 5c 5c 27 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 6e | class,.'\\')).{.............//.n |
12220 | 61 6d 65 73 70 61 63 65 64 20 63 6c 61 73 73 20 6e 61 6d 65 0a 20 20 20 20 20 20 20 20 20 20 20 | amespaced.class.name............ |
12240 | 20 24 6c 6f 67 69 63 61 6c 50 61 74 68 50 73 72 30 20 3d 20 73 75 62 73 74 72 28 24 6c 6f 67 69 | .$logicalPathPsr0.=.substr($logi |
12260 | 63 61 6c 50 61 74 68 50 73 72 34 2c 20 30 2c 20 24 70 6f 73 20 2b 20 31 29 0a 20 20 20 20 20 20 | calPathPsr4,.0,.$pos.+.1)....... |
12280 | 20 20 20 20 20 20 20 20 20 20 2e 20 73 74 72 74 72 28 73 75 62 73 74 72 28 24 6c 6f 67 69 63 61 | ............strtr(substr($logica |
122a0 | 6c 50 61 74 68 50 73 72 34 2c 20 24 70 6f 73 20 2b 20 31 29 2c 20 27 5f 27 2c 20 44 49 52 45 43 | lPathPsr4,.$pos.+.1),.'_',.DIREC |
122c0 | 54 4f 52 59 5f 53 45 50 41 52 41 54 4f 52 29 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 | TORY_SEPARATOR);.........}.else. |
122e0 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 50 45 41 52 2d 6c 69 6b 65 20 63 6c 61 73 73 | {.............//.PEAR-like.class |
12300 | 20 6e 61 6d 65 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 6f 67 69 63 61 6c 50 61 74 68 50 73 | .name.............$logicalPathPs |
12320 | 72 30 20 3d 20 73 74 72 74 72 28 24 63 6c 61 73 73 2c 20 27 5f 27 2c 20 44 49 52 45 43 54 4f 52 | r0.=.strtr($class,.'_',.DIRECTOR |
12340 | 59 5f 53 45 50 41 52 41 54 4f 52 29 20 2e 20 24 65 78 74 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a | Y_SEPARATOR)...$ext;.........}.. |
12360 | 20 20 20 20 20 20 20 20 69 66 20 28 69 73 73 65 74 28 24 74 68 69 73 2d 3e 70 72 65 66 69 78 65 | ........if.(isset($this->prefixe |
12380 | 73 50 73 72 30 5b 24 66 69 72 73 74 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 66 6f | sPsr0[$first])).{.............fo |
123a0 | 72 65 61 63 68 20 28 24 74 68 69 73 2d 3e 70 72 65 66 69 78 65 73 50 73 72 30 5b 24 66 69 72 73 | reach.($this->prefixesPsr0[$firs |
123c0 | 74 5d 20 61 73 20 24 70 72 65 66 69 78 20 3d 3e 20 24 64 69 72 73 29 20 7b 0a 20 20 20 20 20 20 | t].as.$prefix.=>.$dirs).{....... |
123e0 | 20 20 20 20 20 20 20 20 20 20 69 66 20 28 30 20 3d 3d 3d 20 73 74 72 70 6f 73 28 24 63 6c 61 73 | ..........if.(0.===.strpos($clas |
12400 | 73 2c 20 24 70 72 65 66 69 78 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | s,.$prefix)).{.................. |
12420 | 20 20 20 66 6f 72 65 61 63 68 20 28 24 64 69 72 73 20 61 73 20 24 64 69 72 29 20 7b 0a 20 20 20 | ...foreach.($dirs.as.$dir).{.... |
12440 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 66 69 6c 65 5f 65 78 | .....................if.(file_ex |
12460 | 69 73 74 73 28 24 66 69 6c 65 20 3d 20 24 64 69 72 20 2e 20 44 49 52 45 43 54 4f 52 59 5f 53 45 | ists($file.=.$dir...DIRECTORY_SE |
12480 | 50 41 52 41 54 4f 52 20 2e 20 24 6c 6f 67 69 63 61 6c 50 61 74 68 50 73 72 30 29 29 20 7b 0a 20 | PARATOR...$logicalPathPsr0)).{.. |
124a0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 | ...........................retur |
124c0 | 6e 20 24 66 69 6c 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | n.$file;........................ |
124e0 | 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 | .}.....................}........ |
12500 | 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 | .........}.............}........ |
12520 | 20 7d 0a 0a 20 20 20 20 20 20 20 20 2f 2f 20 50 53 52 2d 30 20 66 61 6c 6c 62 61 63 6b 20 64 69 | .}..........//.PSR-0.fallback.di |
12540 | 72 73 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 74 68 69 73 2d 3e 66 61 6c 6c 62 | rs.........foreach.($this->fallb |
12560 | 61 63 6b 44 69 72 73 50 73 72 30 20 61 73 20 24 64 69 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | ackDirsPsr0.as.$dir).{.......... |
12580 | 20 20 20 69 66 20 28 66 69 6c 65 5f 65 78 69 73 74 73 28 24 66 69 6c 65 20 3d 20 24 64 69 72 20 | ...if.(file_exists($file.=.$dir. |
125a0 | 2e 20 44 49 52 45 43 54 4f 52 59 5f 53 45 50 41 52 41 54 4f 52 20 2e 20 24 6c 6f 67 69 63 61 6c | ..DIRECTORY_SEPARATOR...$logical |
125c0 | 50 61 74 68 50 73 72 30 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 | PathPsr0)).{.................ret |
125e0 | 75 72 6e 20 24 66 69 6c 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 | urn.$file;.............}........ |
12600 | 20 7d 0a 0a 20 20 20 20 20 20 20 20 2f 2f 20 50 53 52 2d 30 20 69 6e 63 6c 75 64 65 20 70 61 74 | .}..........//.PSR-0.include.pat |
12620 | 68 73 2e 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 74 68 69 73 2d 3e 75 73 65 49 6e 63 6c 75 64 | hs..........if.($this->useInclud |
12640 | 65 50 61 74 68 20 26 26 20 24 66 69 6c 65 20 3d 20 73 74 72 65 61 6d 5f 72 65 73 6f 6c 76 65 5f | ePath.&&.$file.=.stream_resolve_ |
12660 | 69 6e 63 6c 75 64 65 5f 70 61 74 68 28 24 6c 6f 67 69 63 61 6c 50 61 74 68 50 73 72 30 29 29 20 | include_path($logicalPathPsr0)). |
12680 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 66 69 6c 65 3b 0a 20 20 20 20 | {.............return.$file;..... |
126a0 | 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 66 61 6c 73 65 3b 0a 20 20 20 | ....}..........return.false;.... |
126c0 | 20 7d 0a 7d 0a 0a 2f 2a 2a 0a 20 2a 20 53 63 6f 70 65 20 69 73 6f 6c 61 74 65 64 20 69 6e 63 6c | .}.}../**..*.Scope.isolated.incl |
126e0 | 75 64 65 2e 0a 20 2a 0a 20 2a 20 50 72 65 76 65 6e 74 73 20 61 63 63 65 73 73 20 74 6f 20 24 74 | ude...*..*.Prevents.access.to.$t |
12700 | 68 69 73 2f 73 65 6c 66 20 66 72 6f 6d 20 69 6e 63 6c 75 64 65 64 20 66 69 6c 65 73 2e 0a 20 2a | his/self.from.included.files...* |
12720 | 0a 20 2a 20 40 70 61 72 61 6d 20 20 73 74 72 69 6e 67 20 24 66 69 6c 65 0a 20 2a 20 40 72 65 74 | ..*.@param..string.$file..*.@ret |
12740 | 75 72 6e 20 76 6f 69 64 0a 20 2a 20 40 70 72 69 76 61 74 65 0a 20 2a 2f 0a 66 75 6e 63 74 69 6f | urn.void..*.@private..*/.functio |
12760 | 6e 20 69 6e 63 6c 75 64 65 46 69 6c 65 28 24 66 69 6c 65 29 0a 7b 0a 20 20 20 20 69 6e 63 6c 75 | n.includeFile($file).{.....inclu |
12780 | 64 65 20 24 66 69 6c 65 3b 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 | de.$file;.}.<?php../*..*.This.fi |
127a0 | 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 | le.is.part.of.the.Symfony.packag |
127c0 | 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 | e...*..*.(c).Fabien.Potencier.<f |
127e0 | 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 | abien@symfony.com>..*..*.For.the |
12800 | 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f | .full.copyright.and.license.info |
12820 | 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 | rmation,.please.view.the.LICENSE |
12840 | 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 | ..*.file.that.was.distributed.wi |
12860 | 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 | th.this.source.code...*/..namesp |
12880 | 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 44 65 62 75 67 3b 0a 0a 75 73 | ace.Symfony\Component\Debug;..us |
128a0 | 65 20 50 73 72 5c 4c 6f 67 5c 41 62 73 74 72 61 63 74 4c 6f 67 67 65 72 3b 0a 0a 2f 2a 2a 0a 20 | e.Psr\Log\AbstractLogger;../**.. |
128c0 | 2a 20 41 20 62 75 66 66 65 72 69 6e 67 20 6c 6f 67 67 65 72 20 74 68 61 74 20 73 74 61 63 6b 73 | *.A.buffering.logger.that.stacks |
128e0 | 20 6c 6f 67 73 20 66 6f 72 20 6c 61 74 65 72 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 4e | .logs.for.later...*..*.@author.N |
12900 | 69 63 6f 6c 61 73 20 47 72 65 6b 61 73 20 3c 70 40 74 63 68 77 6f 72 6b 2e 63 6f 6d 3e 0a 20 2a | icolas.Grekas.<p@tchwork.com>..* |
12920 | 2f 0a 63 6c 61 73 73 20 42 75 66 66 65 72 69 6e 67 4c 6f 67 67 65 72 20 65 78 74 65 6e 64 73 20 | /.class.BufferingLogger.extends. |
12940 | 41 62 73 74 72 61 63 74 4c 6f 67 67 65 72 0a 7b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 6c 6f | AbstractLogger.{.....private.$lo |
12960 | 67 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 | gs.=.array();......public.functi |
12980 | 6f 6e 20 6c 6f 67 28 24 6c 65 76 65 6c 2c 20 24 6d 65 73 73 61 67 65 2c 20 61 72 72 61 79 20 24 | on.log($level,.$message,.array.$ |
129a0 | 63 6f 6e 74 65 78 74 20 3d 20 61 72 72 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 | context.=.array()).....{........ |
129c0 | 20 24 74 68 69 73 2d 3e 6c 6f 67 73 5b 5d 20 3d 20 61 72 72 61 79 28 24 6c 65 76 65 6c 2c 20 24 | .$this->logs[].=.array($level,.$ |
129e0 | 6d 65 73 73 61 67 65 2c 20 24 63 6f 6e 74 65 78 74 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 | message,.$context);.....}......p |
12a00 | 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 63 6c 65 61 6e 4c 6f 67 73 28 29 0a 20 20 20 20 7b | ublic.function.cleanLogs().....{ |
12a20 | 0a 20 20 20 20 20 20 20 20 24 6c 6f 67 73 20 3d 20 24 74 68 69 73 2d 3e 6c 6f 67 73 3b 0a 20 20 | .........$logs.=.$this->logs;... |
12a40 | 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6c 6f 67 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 0a 20 20 | ......$this->logs.=.array();.... |
12a60 | 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 6c 6f 67 73 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 | ......return.$logs;.....}.}.<?ph |
12a80 | 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 | p../*..*.This.file.is.part.of.th |
12aa0 | 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 | e.Symfony.package...*..*.(c).Fab |
12ac0 | 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f | ien.Potencier.<fabien@symfony.co |
12ae0 | 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 | m>..*..*.For.the.full.copyright. |
12b00 | 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 | and.license.information,.please. |
12b20 | 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 | view.the.LICENSE..*.file.that.wa |
12b40 | 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 | s.distributed.with.this.source.c |
12b60 | 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 | ode...*/..namespace.Symfony\Comp |
12b80 | 6f 6e 65 6e 74 5c 44 65 62 75 67 3b 0a 0a 75 73 65 20 50 73 72 5c 4c 6f 67 5c 4c 6f 67 4c 65 76 | onent\Debug;..use.Psr\Log\LogLev |
12ba0 | 65 6c 3b 0a 75 73 65 20 50 73 72 5c 4c 6f 67 5c 4c 6f 67 67 65 72 49 6e 74 65 72 66 61 63 65 3b | el;.use.Psr\Log\LoggerInterface; |
12bc0 | 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 44 65 62 75 67 5c 45 78 63 | .use.Symfony\Component\Debug\Exc |
12be0 | 65 70 74 69 6f 6e 5c 43 6f 6e 74 65 78 74 45 72 72 6f 72 45 78 63 65 70 74 69 6f 6e 3b 0a 75 73 | eption\ContextErrorException;.us |
12c00 | 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 44 65 62 75 67 5c 45 78 63 65 70 74 | e.Symfony\Component\Debug\Except |
12c20 | 69 6f 6e 5c 46 61 74 61 6c 45 72 72 6f 72 45 78 63 65 70 74 69 6f 6e 3b 0a 75 73 65 20 53 79 6d | ion\FatalErrorException;.use.Sym |
12c40 | 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 44 65 62 75 67 5c 45 78 63 65 70 74 69 6f 6e 5c 46 | fony\Component\Debug\Exception\F |
12c60 | 61 74 61 6c 54 68 72 6f 77 61 62 6c 65 45 72 72 6f 72 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c | atalThrowableError;.use.Symfony\ |
12c80 | 43 6f 6d 70 6f 6e 65 6e 74 5c 44 65 62 75 67 5c 45 78 63 65 70 74 69 6f 6e 5c 4f 75 74 4f 66 4d | Component\Debug\Exception\OutOfM |
12ca0 | 65 6d 6f 72 79 45 78 63 65 70 74 69 6f 6e 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 | emoryException;.use.Symfony\Comp |
12cc0 | 6f 6e 65 6e 74 5c 44 65 62 75 67 5c 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 5c 55 6e | onent\Debug\FatalErrorHandler\Un |
12ce0 | 64 65 66 69 6e 65 64 46 75 6e 63 74 69 6f 6e 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 | definedFunctionFatalErrorHandler |
12d00 | 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 44 65 62 75 67 5c 46 61 | ;.use.Symfony\Component\Debug\Fa |
12d20 | 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 5c 55 6e 64 65 66 69 6e 65 64 4d 65 74 68 6f 64 46 | talErrorHandler\UndefinedMethodF |
12d40 | 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f | atalErrorHandler;.use.Symfony\Co |
12d60 | 6d 70 6f 6e 65 6e 74 5c 44 65 62 75 67 5c 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 5c | mponent\Debug\FatalErrorHandler\ |
12d80 | 43 6c 61 73 73 4e 6f 74 46 6f 75 6e 64 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 3b 0a | ClassNotFoundFatalErrorHandler;. |
12da0 | 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 44 65 62 75 67 5c 46 61 74 61 | use.Symfony\Component\Debug\Fata |
12dc0 | 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 5c 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 49 | lErrorHandler\FatalErrorHandlerI |
12de0 | 6e 74 65 72 66 61 63 65 3b 0a 0a 2f 2a 2a 0a 20 2a 20 41 20 67 65 6e 65 72 69 63 20 45 72 72 6f | nterface;../**..*.A.generic.Erro |
12e00 | 72 48 61 6e 64 6c 65 72 20 66 6f 72 20 74 68 65 20 50 48 50 20 65 6e 67 69 6e 65 2e 0a 20 2a 0a | rHandler.for.the.PHP.engine...*. |
12e20 | 20 2a 20 50 72 6f 76 69 64 65 73 20 66 69 76 65 20 62 69 74 20 66 69 65 6c 64 73 20 74 68 61 74 | .*.Provides.five.bit.fields.that |
12e40 | 20 63 6f 6e 74 72 6f 6c 20 68 6f 77 20 65 72 72 6f 72 73 20 61 72 65 20 68 61 6e 64 6c 65 64 3a | .control.how.errors.are.handled: |
12e60 | 0a 20 2a 20 2d 20 74 68 72 6f 77 6e 45 72 72 6f 72 73 3a 20 65 72 72 6f 72 73 20 74 68 72 6f 77 | ..*.-.thrownErrors:.errors.throw |
12e80 | 6e 20 61 73 20 5c 45 72 72 6f 72 45 78 63 65 70 74 69 6f 6e 0a 20 2a 20 2d 20 6c 6f 67 67 65 64 | n.as.\ErrorException..*.-.logged |
12ea0 | 45 72 72 6f 72 73 3a 20 6c 6f 67 67 65 64 20 65 72 72 6f 72 73 2c 20 77 68 65 6e 20 6e 6f 74 20 | Errors:.logged.errors,.when.not. |
12ec0 | 40 2d 73 69 6c 65 6e 63 65 64 0a 20 2a 20 2d 20 73 63 6f 70 65 64 45 72 72 6f 72 73 3a 20 65 72 | @-silenced..*.-.scopedErrors:.er |
12ee0 | 72 6f 72 73 20 74 68 72 6f 77 6e 20 6f 72 20 6c 6f 67 67 65 64 20 77 69 74 68 20 74 68 65 69 72 | rors.thrown.or.logged.with.their |
12f00 | 20 6c 6f 63 61 6c 20 63 6f 6e 74 65 78 74 0a 20 2a 20 2d 20 74 72 61 63 65 64 45 72 72 6f 72 73 | .local.context..*.-.tracedErrors |
12f20 | 3a 20 65 72 72 6f 72 73 20 6c 6f 67 67 65 64 20 77 69 74 68 20 74 68 65 69 72 20 73 74 61 63 6b | :.errors.logged.with.their.stack |
12f40 | 20 74 72 61 63 65 2c 20 6f 6e 6c 79 20 6f 6e 63 65 20 66 6f 72 20 72 65 70 65 61 74 65 64 20 65 | .trace,.only.once.for.repeated.e |
12f60 | 72 72 6f 72 73 0a 20 2a 20 2d 20 73 63 72 65 61 6d 65 64 45 72 72 6f 72 73 3a 20 6e 65 76 65 72 | rrors..*.-.screamedErrors:.never |
12f80 | 20 40 2d 73 69 6c 65 6e 63 65 64 20 65 72 72 6f 72 73 0a 20 2a 0a 20 2a 20 45 61 63 68 20 65 72 | .@-silenced.errors..*..*.Each.er |
12fa0 | 72 6f 72 20 6c 65 76 65 6c 20 63 61 6e 20 62 65 20 6c 6f 67 67 65 64 20 62 79 20 61 20 64 65 64 | ror.level.can.be.logged.by.a.ded |
12fc0 | 69 63 61 74 65 64 20 50 53 52 2d 33 20 6c 6f 67 67 65 72 20 6f 62 6a 65 63 74 2e 0a 20 2a 20 53 | icated.PSR-3.logger.object...*.S |
12fe0 | 63 72 65 61 6d 69 6e 67 20 6f 6e 6c 79 20 61 70 70 6c 69 65 73 20 74 6f 20 6c 6f 67 67 69 6e 67 | creaming.only.applies.to.logging |
13000 | 2e 0a 20 2a 20 54 68 72 6f 77 69 6e 67 20 74 61 6b 65 73 20 70 72 65 63 65 64 65 6e 63 65 20 6f | ...*.Throwing.takes.precedence.o |
13020 | 76 65 72 20 6c 6f 67 67 69 6e 67 2e 0a 20 2a 20 55 6e 63 61 75 67 68 74 20 65 78 63 65 70 74 69 | ver.logging...*.Uncaught.excepti |
13040 | 6f 6e 73 20 61 72 65 20 6c 6f 67 67 65 64 20 61 73 20 45 5f 45 52 52 4f 52 2e 0a 20 2a 20 45 5f | ons.are.logged.as.E_ERROR...*.E_ |
13060 | 44 45 50 52 45 43 41 54 45 44 20 61 6e 64 20 45 5f 55 53 45 52 5f 44 45 50 52 45 43 41 54 45 44 | DEPRECATED.and.E_USER_DEPRECATED |
13080 | 20 6c 65 76 65 6c 73 20 6e 65 76 65 72 20 74 68 72 6f 77 2e 0a 20 2a 20 45 5f 52 45 43 4f 56 45 | .levels.never.throw...*.E_RECOVE |
130a0 | 52 41 42 4c 45 5f 45 52 52 4f 52 20 61 6e 64 20 45 5f 55 53 45 52 5f 45 52 52 4f 52 20 6c 65 76 | RABLE_ERROR.and.E_USER_ERROR.lev |
130c0 | 65 6c 73 20 61 6c 77 61 79 73 20 74 68 72 6f 77 2e 0a 20 2a 20 4e 6f 6e 20 63 61 74 63 68 61 62 | els.always.throw...*.Non.catchab |
130e0 | 6c 65 20 65 72 72 6f 72 73 20 74 68 61 74 20 63 61 6e 20 62 65 20 64 65 74 65 63 74 65 64 20 61 | le.errors.that.can.be.detected.a |
13100 | 74 20 73 68 75 74 64 6f 77 6e 20 74 69 6d 65 20 61 72 65 20 6c 6f 67 67 65 64 20 77 68 65 6e 20 | t.shutdown.time.are.logged.when. |
13120 | 74 68 65 20 73 63 72 65 61 6d 20 62 69 74 20 66 69 65 6c 64 20 61 6c 6c 6f 77 73 20 73 6f 2e 0a | the.scream.bit.field.allows.so.. |
13140 | 20 2a 20 41 73 20 65 72 72 6f 72 73 20 68 61 76 65 20 61 20 70 65 72 66 6f 72 6d 61 6e 63 65 20 | .*.As.errors.have.a.performance. |
13160 | 63 6f 73 74 2c 20 72 65 70 65 61 74 65 64 20 65 72 72 6f 72 73 20 61 72 65 20 61 6c 6c 20 6c 6f | cost,.repeated.errors.are.all.lo |
13180 | 67 67 65 64 2c 20 73 6f 20 74 68 61 74 20 74 68 65 20 64 65 76 65 6c 6f 70 65 72 0a 20 2a 20 63 | gged,.so.that.the.developer..*.c |
131a0 | 61 6e 20 73 65 65 20 74 68 65 6d 20 61 6e 64 20 77 65 69 67 68 74 20 74 68 65 6d 20 61 73 20 6d | an.see.them.and.weight.them.as.m |
131c0 | 6f 72 65 20 69 6d 70 6f 72 74 61 6e 74 20 74 6f 20 66 69 78 20 74 68 61 6e 20 6f 74 68 65 72 73 | ore.important.to.fix.than.others |
131e0 | 20 6f 66 20 74 68 65 20 73 61 6d 65 20 6c 65 76 65 6c 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f | .of.the.same.level...*..*.@autho |
13200 | 72 20 4e 69 63 6f 6c 61 73 20 47 72 65 6b 61 73 20 3c 70 40 74 63 68 77 6f 72 6b 2e 63 6f 6d 3e | r.Nicolas.Grekas.<p@tchwork.com> |
13220 | 0a 20 2a 2f 0a 63 6c 61 73 73 20 45 72 72 6f 72 48 61 6e 64 6c 65 72 0a 7b 0a 20 20 20 20 70 72 | ..*/.class.ErrorHandler.{.....pr |
13240 | 69 76 61 74 65 20 24 6c 65 76 65 6c 73 20 3d 20 61 72 72 61 79 28 0a 20 20 20 20 20 20 20 20 45 | ivate.$levels.=.array(.........E |
13260 | 5f 44 45 50 52 45 43 41 54 45 44 20 3d 3e 20 27 44 65 70 72 65 63 61 74 65 64 27 2c 0a 20 20 20 | _DEPRECATED.=>.'Deprecated',.... |
13280 | 20 20 20 20 20 45 5f 55 53 45 52 5f 44 45 50 52 45 43 41 54 45 44 20 3d 3e 20 27 55 73 65 72 20 | .....E_USER_DEPRECATED.=>.'User. |
132a0 | 44 65 70 72 65 63 61 74 65 64 27 2c 0a 20 20 20 20 20 20 20 20 45 5f 4e 4f 54 49 43 45 20 3d 3e | Deprecated',.........E_NOTICE.=> |
132c0 | 20 27 4e 6f 74 69 63 65 27 2c 0a 20 20 20 20 20 20 20 20 45 5f 55 53 45 52 5f 4e 4f 54 49 43 45 | .'Notice',.........E_USER_NOTICE |
132e0 | 20 3d 3e 20 27 55 73 65 72 20 4e 6f 74 69 63 65 27 2c 0a 20 20 20 20 20 20 20 20 45 5f 53 54 52 | .=>.'User.Notice',.........E_STR |
13300 | 49 43 54 20 3d 3e 20 27 52 75 6e 74 69 6d 65 20 4e 6f 74 69 63 65 27 2c 0a 20 20 20 20 20 20 20 | ICT.=>.'Runtime.Notice',........ |
13320 | 20 45 5f 57 41 52 4e 49 4e 47 20 3d 3e 20 27 57 61 72 6e 69 6e 67 27 2c 0a 20 20 20 20 20 20 20 | .E_WARNING.=>.'Warning',........ |
13340 | 20 45 5f 55 53 45 52 5f 57 41 52 4e 49 4e 47 20 3d 3e 20 27 55 73 65 72 20 57 61 72 6e 69 6e 67 | .E_USER_WARNING.=>.'User.Warning |
13360 | 27 2c 0a 20 20 20 20 20 20 20 20 45 5f 43 4f 4d 50 49 4c 45 5f 57 41 52 4e 49 4e 47 20 3d 3e 20 | ',.........E_COMPILE_WARNING.=>. |
13380 | 27 43 6f 6d 70 69 6c 65 20 57 61 72 6e 69 6e 67 27 2c 0a 20 20 20 20 20 20 20 20 45 5f 43 4f 52 | 'Compile.Warning',.........E_COR |
133a0 | 45 5f 57 41 52 4e 49 4e 47 20 3d 3e 20 27 43 6f 72 65 20 57 61 72 6e 69 6e 67 27 2c 0a 20 20 20 | E_WARNING.=>.'Core.Warning',.... |
133c0 | 20 20 20 20 20 45 5f 55 53 45 52 5f 45 52 52 4f 52 20 3d 3e 20 27 55 73 65 72 20 45 72 72 6f 72 | .....E_USER_ERROR.=>.'User.Error |
133e0 | 27 2c 0a 20 20 20 20 20 20 20 20 45 5f 52 45 43 4f 56 45 52 41 42 4c 45 5f 45 52 52 4f 52 20 3d | ',.........E_RECOVERABLE_ERROR.= |
13400 | 3e 20 27 43 61 74 63 68 61 62 6c 65 20 46 61 74 61 6c 20 45 72 72 6f 72 27 2c 0a 20 20 20 20 20 | >.'Catchable.Fatal.Error',...... |
13420 | 20 20 20 45 5f 43 4f 4d 50 49 4c 45 5f 45 52 52 4f 52 20 3d 3e 20 27 43 6f 6d 70 69 6c 65 20 45 | ...E_COMPILE_ERROR.=>.'Compile.E |
13440 | 72 72 6f 72 27 2c 0a 20 20 20 20 20 20 20 20 45 5f 50 41 52 53 45 20 3d 3e 20 27 50 61 72 73 65 | rror',.........E_PARSE.=>.'Parse |
13460 | 20 45 72 72 6f 72 27 2c 0a 20 20 20 20 20 20 20 20 45 5f 45 52 52 4f 52 20 3d 3e 20 27 45 72 72 | .Error',.........E_ERROR.=>.'Err |
13480 | 6f 72 27 2c 0a 20 20 20 20 20 20 20 20 45 5f 43 4f 52 45 5f 45 52 52 4f 52 20 3d 3e 20 27 43 6f | or',.........E_CORE_ERROR.=>.'Co |
134a0 | 72 65 20 45 72 72 6f 72 27 2c 0a 20 20 20 20 29 3b 0a 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 | re.Error',.....);......private.$ |
134c0 | 6c 6f 67 67 65 72 73 20 3d 20 61 72 72 61 79 28 0a 20 20 20 20 20 20 20 20 45 5f 44 45 50 52 45 | loggers.=.array(.........E_DEPRE |
134e0 | 43 41 54 45 44 20 3d 3e 20 61 72 72 61 79 28 6e 75 6c 6c 2c 20 4c 6f 67 4c 65 76 65 6c 3a 3a 49 | CATED.=>.array(null,.LogLevel::I |
13500 | 4e 46 4f 29 2c 0a 20 20 20 20 20 20 20 20 45 5f 55 53 45 52 5f 44 45 50 52 45 43 41 54 45 44 20 | NFO),.........E_USER_DEPRECATED. |
13520 | 3d 3e 20 61 72 72 61 79 28 6e 75 6c 6c 2c 20 4c 6f 67 4c 65 76 65 6c 3a 3a 49 4e 46 4f 29 2c 0a | =>.array(null,.LogLevel::INFO),. |
13540 | 20 20 20 20 20 20 20 20 45 5f 4e 4f 54 49 43 45 20 3d 3e 20 61 72 72 61 79 28 6e 75 6c 6c 2c 20 | ........E_NOTICE.=>.array(null,. |
13560 | 4c 6f 67 4c 65 76 65 6c 3a 3a 57 41 52 4e 49 4e 47 29 2c 0a 20 20 20 20 20 20 20 20 45 5f 55 53 | LogLevel::WARNING),.........E_US |
13580 | 45 52 5f 4e 4f 54 49 43 45 20 3d 3e 20 61 72 72 61 79 28 6e 75 6c 6c 2c 20 4c 6f 67 4c 65 76 65 | ER_NOTICE.=>.array(null,.LogLeve |
135a0 | 6c 3a 3a 57 41 52 4e 49 4e 47 29 2c 0a 20 20 20 20 20 20 20 20 45 5f 53 54 52 49 43 54 20 3d 3e | l::WARNING),.........E_STRICT.=> |
135c0 | 20 61 72 72 61 79 28 6e 75 6c 6c 2c 20 4c 6f 67 4c 65 76 65 6c 3a 3a 57 41 52 4e 49 4e 47 29 2c | .array(null,.LogLevel::WARNING), |
135e0 | 0a 20 20 20 20 20 20 20 20 45 5f 57 41 52 4e 49 4e 47 20 3d 3e 20 61 72 72 61 79 28 6e 75 6c 6c | .........E_WARNING.=>.array(null |
13600 | 2c 20 4c 6f 67 4c 65 76 65 6c 3a 3a 57 41 52 4e 49 4e 47 29 2c 0a 20 20 20 20 20 20 20 20 45 5f | ,.LogLevel::WARNING),.........E_ |
13620 | 55 53 45 52 5f 57 41 52 4e 49 4e 47 20 3d 3e 20 61 72 72 61 79 28 6e 75 6c 6c 2c 20 4c 6f 67 4c | USER_WARNING.=>.array(null,.LogL |
13640 | 65 76 65 6c 3a 3a 57 41 52 4e 49 4e 47 29 2c 0a 20 20 20 20 20 20 20 20 45 5f 43 4f 4d 50 49 4c | evel::WARNING),.........E_COMPIL |
13660 | 45 5f 57 41 52 4e 49 4e 47 20 3d 3e 20 61 72 72 61 79 28 6e 75 6c 6c 2c 20 4c 6f 67 4c 65 76 65 | E_WARNING.=>.array(null,.LogLeve |
13680 | 6c 3a 3a 57 41 52 4e 49 4e 47 29 2c 0a 20 20 20 20 20 20 20 20 45 5f 43 4f 52 45 5f 57 41 52 4e | l::WARNING),.........E_CORE_WARN |
136a0 | 49 4e 47 20 3d 3e 20 61 72 72 61 79 28 6e 75 6c 6c 2c 20 4c 6f 67 4c 65 76 65 6c 3a 3a 57 41 52 | ING.=>.array(null,.LogLevel::WAR |
136c0 | 4e 49 4e 47 29 2c 0a 20 20 20 20 20 20 20 20 45 5f 55 53 45 52 5f 45 52 52 4f 52 20 3d 3e 20 61 | NING),.........E_USER_ERROR.=>.a |
136e0 | 72 72 61 79 28 6e 75 6c 6c 2c 20 4c 6f 67 4c 65 76 65 6c 3a 3a 43 52 49 54 49 43 41 4c 29 2c 0a | rray(null,.LogLevel::CRITICAL),. |
13700 | 20 20 20 20 20 20 20 20 45 5f 52 45 43 4f 56 45 52 41 42 4c 45 5f 45 52 52 4f 52 20 3d 3e 20 61 | ........E_RECOVERABLE_ERROR.=>.a |
13720 | 72 72 61 79 28 6e 75 6c 6c 2c 20 4c 6f 67 4c 65 76 65 6c 3a 3a 43 52 49 54 49 43 41 4c 29 2c 0a | rray(null,.LogLevel::CRITICAL),. |
13740 | 20 20 20 20 20 20 20 20 45 5f 43 4f 4d 50 49 4c 45 5f 45 52 52 4f 52 20 3d 3e 20 61 72 72 61 79 | ........E_COMPILE_ERROR.=>.array |
13760 | 28 6e 75 6c 6c 2c 20 4c 6f 67 4c 65 76 65 6c 3a 3a 43 52 49 54 49 43 41 4c 29 2c 0a 20 20 20 20 | (null,.LogLevel::CRITICAL),..... |
13780 | 20 20 20 20 45 5f 50 41 52 53 45 20 3d 3e 20 61 72 72 61 79 28 6e 75 6c 6c 2c 20 4c 6f 67 4c 65 | ....E_PARSE.=>.array(null,.LogLe |
137a0 | 76 65 6c 3a 3a 43 52 49 54 49 43 41 4c 29 2c 0a 20 20 20 20 20 20 20 20 45 5f 45 52 52 4f 52 20 | vel::CRITICAL),.........E_ERROR. |
137c0 | 3d 3e 20 61 72 72 61 79 28 6e 75 6c 6c 2c 20 4c 6f 67 4c 65 76 65 6c 3a 3a 43 52 49 54 49 43 41 | =>.array(null,.LogLevel::CRITICA |
137e0 | 4c 29 2c 0a 20 20 20 20 20 20 20 20 45 5f 43 4f 52 45 5f 45 52 52 4f 52 20 3d 3e 20 61 72 72 61 | L),.........E_CORE_ERROR.=>.arra |
13800 | 79 28 6e 75 6c 6c 2c 20 4c 6f 67 4c 65 76 65 6c 3a 3a 43 52 49 54 49 43 41 4c 29 2c 0a 20 20 20 | y(null,.LogLevel::CRITICAL),.... |
13820 | 20 29 3b 0a 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 74 68 72 6f 77 6e 45 72 72 6f 72 73 20 3d | .);......private.$thrownErrors.= |
13840 | 20 30 78 31 46 46 46 3b 20 2f 2f 20 45 5f 41 4c 4c 20 2d 20 45 5f 44 45 50 52 45 43 41 54 45 44 | .0x1FFF;.//.E_ALL.-.E_DEPRECATED |
13860 | 20 2d 20 45 5f 55 53 45 52 5f 44 45 50 52 45 43 41 54 45 44 0a 20 20 20 20 70 72 69 76 61 74 65 | .-.E_USER_DEPRECATED.....private |
13880 | 20 24 73 63 6f 70 65 64 45 72 72 6f 72 73 20 3d 20 30 78 31 46 46 46 3b 20 2f 2f 20 45 5f 41 4c | .$scopedErrors.=.0x1FFF;.//.E_AL |
138a0 | 4c 20 2d 20 45 5f 44 45 50 52 45 43 41 54 45 44 20 2d 20 45 5f 55 53 45 52 5f 44 45 50 52 45 43 | L.-.E_DEPRECATED.-.E_USER_DEPREC |
138c0 | 41 54 45 44 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 74 72 61 63 65 64 45 72 72 6f 72 73 20 3d | ATED.....private.$tracedErrors.= |
138e0 | 20 30 78 37 37 46 42 3b 20 2f 2f 20 45 5f 41 4c 4c 20 2d 20 45 5f 53 54 52 49 43 54 20 2d 20 45 | .0x77FB;.//.E_ALL.-.E_STRICT.-.E |
13900 | 5f 50 41 52 53 45 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 73 63 72 65 61 6d 65 64 45 72 72 6f | _PARSE.....private.$screamedErro |
13920 | 72 73 20 3d 20 30 78 35 35 3b 20 2f 2f 20 45 5f 45 52 52 4f 52 20 2b 20 45 5f 43 4f 52 45 5f 45 | rs.=.0x55;.//.E_ERROR.+.E_CORE_E |
13940 | 52 52 4f 52 20 2b 20 45 5f 43 4f 4d 50 49 4c 45 5f 45 52 52 4f 52 20 2b 20 45 5f 50 41 52 53 45 | RROR.+.E_COMPILE_ERROR.+.E_PARSE |
13960 | 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 6c 6f 67 67 65 64 45 72 72 6f 72 73 20 3d 20 30 3b 0a | .....private.$loggedErrors.=.0;. |
13980 | 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 6c 6f 67 67 65 64 54 72 61 63 65 73 20 3d 20 61 72 72 | .....private.$loggedTraces.=.arr |
139a0 | 61 79 28 29 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 69 73 52 65 63 75 72 73 69 76 65 20 3d | ay();.....private.$isRecursive.= |
139c0 | 20 30 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 69 73 52 6f 6f 74 20 3d 20 66 61 6c 73 65 3b | .0;.....private.$isRoot.=.false; |
139e0 | 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 65 78 63 65 70 74 69 6f 6e 48 61 6e 64 6c 65 72 3b 0a | .....private.$exceptionHandler;. |
13a00 | 20 20 20 20 70 72 69 76 61 74 65 20 24 62 6f 6f 74 73 74 72 61 70 70 69 6e 67 4c 6f 67 67 65 72 | ....private.$bootstrappingLogger |
13a20 | 3b 0a 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 24 72 65 73 65 72 76 65 64 4d | ;......private.static.$reservedM |
13a40 | 65 6d 6f 72 79 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 24 73 74 61 63 6b | emory;.....private.static.$stack |
13a60 | 65 64 45 72 72 6f 72 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 | edErrors.=.array();.....private. |
13a80 | 73 74 61 74 69 63 20 24 73 74 61 63 6b 65 64 45 72 72 6f 72 4c 65 76 65 6c 73 20 3d 20 61 72 72 | static.$stackedErrorLevels.=.arr |
13aa0 | 61 79 28 29 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 24 74 6f 53 74 72 69 | ay();.....private.static.$toStri |
13ac0 | 6e 67 45 78 63 65 70 74 69 6f 6e 20 3d 20 6e 75 6c 6c 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 | ngException.=.null;....../**.... |
13ae0 | 20 20 2a 20 52 65 67 69 73 74 65 72 73 20 74 68 65 20 65 72 72 6f 72 20 68 61 6e 64 6c 65 72 2e | ..*.Registers.the.error.handler. |
13b00 | 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 65 6c 66 7c 6e 75 6c 6c 20 | ......*......*.@param.self|null. |
13b20 | 24 68 61 6e 64 6c 65 72 20 54 68 65 20 68 61 6e 64 6c 65 72 20 74 6f 20 72 65 67 69 73 74 65 72 | $handler.The.handler.to.register |
13b40 | 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 62 6f 6f 6c 20 20 20 20 20 20 24 72 65 70 6c 61 63 | ......*.@param.bool......$replac |
13b60 | 65 20 57 68 65 74 68 65 72 20 74 6f 20 72 65 70 6c 61 63 65 20 6f 72 20 6e 6f 74 20 61 6e 79 20 | e.Whether.to.replace.or.not.any. |
13b80 | 65 78 69 73 74 69 6e 67 20 68 61 6e 64 6c 65 72 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 | existing.handler......*......*.@ |
13ba0 | 72 65 74 75 72 6e 20 73 65 6c 66 20 54 68 65 20 72 65 67 69 73 74 65 72 65 64 20 65 72 72 6f 72 | return.self.The.registered.error |
13bc0 | 20 68 61 6e 64 6c 65 72 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 | .handler......*/.....public.stat |
13be0 | 69 63 20 66 75 6e 63 74 69 6f 6e 20 72 65 67 69 73 74 65 72 28 73 65 6c 66 20 24 68 61 6e 64 6c | ic.function.register(self.$handl |
13c00 | 65 72 20 3d 20 6e 75 6c 6c 2c 20 24 72 65 70 6c 61 63 65 20 3d 20 74 72 75 65 29 0a 20 20 20 20 | er.=.null,.$replace.=.true)..... |
13c20 | 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 73 65 6c 66 3a 3a 24 72 65 | {.........if.(null.===.self::$re |
13c40 | 73 65 72 76 65 64 4d 65 6d 6f 72 79 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 73 65 6c 66 | servedMemory).{.............self |
13c60 | 3a 3a 24 72 65 73 65 72 76 65 64 4d 65 6d 6f 72 79 20 3d 20 73 74 72 5f 72 65 70 65 61 74 28 27 | ::$reservedMemory.=.str_repeat(' |
13c80 | 78 27 2c 20 31 30 32 34 30 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 67 69 73 74 65 72 | x',.10240);.............register |
13ca0 | 5f 73 68 75 74 64 6f 77 6e 5f 66 75 6e 63 74 69 6f 6e 28 5f 5f 43 4c 41 53 53 5f 5f 2e 27 3a 3a | _shutdown_function(__CLASS__.':: |
13cc0 | 68 61 6e 64 6c 65 46 61 74 61 6c 45 72 72 6f 72 27 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 | handleFatalError');.........}... |
13ce0 | 20 20 20 20 20 20 20 69 66 20 28 24 68 61 6e 64 6c 65 72 49 73 4e 65 77 20 3d 20 6e 75 6c 6c 20 | .......if.($handlerIsNew.=.null. |
13d00 | 3d 3d 3d 20 24 68 61 6e 64 6c 65 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 68 61 6e | ===.$handler).{.............$han |
13d20 | 64 6c 65 72 20 3d 20 6e 65 77 20 73 74 61 74 69 63 28 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a | dler.=.new.static();.........}.. |
13d40 | 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 70 72 65 76 20 3d 20 73 65 74 | ........if.(null.===.$prev.=.set |
13d60 | 5f 65 72 72 6f 72 5f 68 61 6e 64 6c 65 72 28 61 72 72 61 79 28 24 68 61 6e 64 6c 65 72 2c 20 27 | _error_handler(array($handler,.' |
13d80 | 68 61 6e 64 6c 65 45 72 72 6f 72 27 29 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 | handleError'))).{.............re |
13da0 | 73 74 6f 72 65 5f 65 72 72 6f 72 5f 68 61 6e 64 6c 65 72 28 29 3b 0a 20 20 20 20 20 20 20 20 20 | store_error_handler();.......... |
13dc0 | 20 20 20 2f 2f 20 53 70 65 63 69 66 79 69 6e 67 20 74 68 65 20 65 72 72 6f 72 20 74 79 70 65 73 | ...//.Specifying.the.error.types |
13de0 | 20 65 61 72 6c 69 65 72 20 77 6f 75 6c 64 20 65 78 70 6f 73 65 20 75 73 20 74 6f 20 68 74 74 70 | .earlier.would.expose.us.to.http |
13e00 | 73 3a 2f 2f 62 75 67 73 2e 70 68 70 2e 6e 65 74 2f 36 33 32 30 36 0a 20 20 20 20 20 20 20 20 20 | s://bugs.php.net/63206.......... |
13e20 | 20 20 20 73 65 74 5f 65 72 72 6f 72 5f 68 61 6e 64 6c 65 72 28 61 72 72 61 79 28 24 68 61 6e 64 | ...set_error_handler(array($hand |
13e40 | 6c 65 72 2c 20 27 68 61 6e 64 6c 65 45 72 72 6f 72 27 29 2c 20 24 68 61 6e 64 6c 65 72 2d 3e 74 | ler,.'handleError'),.$handler->t |
13e60 | 68 72 6f 77 6e 45 72 72 6f 72 73 20 7c 20 24 68 61 6e 64 6c 65 72 2d 3e 6c 6f 67 67 65 64 45 72 | hrownErrors.|.$handler->loggedEr |
13e80 | 72 6f 72 73 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 68 61 6e 64 6c 65 72 2d 3e 69 73 52 | rors);.............$handler->isR |
13ea0 | 6f 6f 74 20 3d 20 74 72 75 65 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 | oot.=.true;.........}..........i |
13ec0 | 66 20 28 24 68 61 6e 64 6c 65 72 49 73 4e 65 77 20 26 26 20 69 73 5f 61 72 72 61 79 28 24 70 72 | f.($handlerIsNew.&&.is_array($pr |
13ee0 | 65 76 29 20 26 26 20 24 70 72 65 76 5b 30 5d 20 69 6e 73 74 61 6e 63 65 6f 66 20 73 65 6c 66 29 | ev).&&.$prev[0].instanceof.self) |
13f00 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 68 61 6e 64 6c 65 72 20 3d 20 24 70 72 65 76 5b | .{.............$handler.=.$prev[ |
13f20 | 30 5d 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 72 65 70 6c 61 63 65 20 3d 20 66 61 6c 73 65 | 0];.............$replace.=.false |
13f40 | 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 72 65 70 6c 61 63 65 | ;.........}.........if.($replace |
13f60 | 20 7c 7c 20 21 24 70 72 65 76 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 68 61 6e 64 6c | .||.!$prev).{.............$handl |
13f80 | 65 72 2d 3e 73 65 74 45 78 63 65 70 74 69 6f 6e 48 61 6e 64 6c 65 72 28 73 65 74 5f 65 78 63 65 | er->setExceptionHandler(set_exce |
13fa0 | 70 74 69 6f 6e 5f 68 61 6e 64 6c 65 72 28 61 72 72 61 79 28 24 68 61 6e 64 6c 65 72 2c 20 27 68 | ption_handler(array($handler,.'h |
13fc0 | 61 6e 64 6c 65 45 78 63 65 70 74 69 6f 6e 27 29 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c | andleException')));.........}.el |
13fe0 | 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 73 74 6f 72 65 5f 65 72 72 6f 72 5f 68 | se.{.............restore_error_h |
14000 | 61 6e 64 6c 65 72 28 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 68 61 | andler();.........}..........$ha |
14020 | 6e 64 6c 65 72 2d 3e 74 68 72 6f 77 41 74 28 45 5f 41 4c 4c 20 26 20 24 68 61 6e 64 6c 65 72 2d | ndler->throwAt(E_ALL.&.$handler- |
14040 | 3e 74 68 72 6f 77 6e 45 72 72 6f 72 73 2c 20 74 72 75 65 29 3b 0a 0a 20 20 20 20 20 20 20 20 72 | >thrownErrors,.true);..........r |
14060 | 65 74 75 72 6e 20 24 68 61 6e 64 6c 65 72 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 | eturn.$handler;.....}......publi |
14080 | 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 74 28 42 75 66 66 65 72 69 6e 67 | c.function.__construct(Buffering |
140a0 | 4c 6f 67 67 65 72 20 24 62 6f 6f 74 73 74 72 61 70 70 69 6e 67 4c 6f 67 67 65 72 20 3d 20 6e 75 | Logger.$bootstrappingLogger.=.nu |
140c0 | 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 62 6f 6f 74 73 74 72 61 70 | ll).....{.........if.($bootstrap |
140e0 | 70 69 6e 67 4c 6f 67 67 65 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d | pingLogger).{.............$this- |
14100 | 3e 62 6f 6f 74 73 74 72 61 70 70 69 6e 67 4c 6f 67 67 65 72 20 3d 20 24 62 6f 6f 74 73 74 72 61 | >bootstrappingLogger.=.$bootstra |
14120 | 70 70 69 6e 67 4c 6f 67 67 65 72 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e | ppingLogger;.............$this-> |
14140 | 73 65 74 44 65 66 61 75 6c 74 4c 6f 67 67 65 72 28 24 62 6f 6f 74 73 74 72 61 70 70 69 6e 67 4c | setDefaultLogger($bootstrappingL |
14160 | 6f 67 67 65 72 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a | ogger);.........}.....}....../** |
14180 | 0a 20 20 20 20 20 2a 20 53 65 74 73 20 61 20 6c 6f 67 67 65 72 20 74 6f 20 6e 6f 6e 20 61 73 73 | ......*.Sets.a.logger.to.non.ass |
141a0 | 69 67 6e 65 64 20 65 72 72 6f 72 73 20 6c 65 76 65 6c 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 | igned.errors.levels.......*..... |
141c0 | 20 2a 20 40 70 61 72 61 6d 20 4c 6f 67 67 65 72 49 6e 74 65 72 66 61 63 65 20 24 6c 6f 67 67 65 | .*.@param.LoggerInterface.$logge |
141e0 | 72 20 20 41 20 50 53 52 2d 33 20 6c 6f 67 67 65 72 20 74 6f 20 70 75 74 20 61 73 20 64 65 66 61 | r..A.PSR-3.logger.to.put.as.defa |
14200 | 75 6c 74 20 66 6f 72 20 74 68 65 20 67 69 76 65 6e 20 6c 65 76 65 6c 73 0a 20 20 20 20 20 2a 20 | ult.for.the.given.levels......*. |
14220 | 40 70 61 72 61 6d 20 61 72 72 61 79 7c 69 6e 74 20 20 20 20 20 20 20 24 6c 65 76 65 6c 73 20 20 | @param.array|int.......$levels.. |
14240 | 41 6e 20 61 72 72 61 79 20 6d 61 70 20 6f 66 20 45 5f 2a 20 74 6f 20 4c 6f 67 4c 65 76 65 6c 3a | An.array.map.of.E_*.to.LogLevel: |
14260 | 3a 2a 20 6f 72 20 61 6e 20 69 6e 74 65 67 65 72 20 62 69 74 20 66 69 65 6c 64 20 6f 66 20 45 5f | :*.or.an.integer.bit.field.of.E_ |
14280 | 2a 20 63 6f 6e 73 74 61 6e 74 73 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 62 6f 6f 6c 20 20 | *.constants......*.@param.bool.. |
142a0 | 20 20 20 20 20 20 20 20 20 20 24 72 65 70 6c 61 63 65 20 57 68 65 74 68 65 72 20 74 6f 20 72 65 | ..........$replace.Whether.to.re |
142c0 | 70 6c 61 63 65 20 6f 72 20 6e 6f 74 20 61 6e 79 20 65 78 69 73 74 69 6e 67 20 6c 6f 67 67 65 72 | place.or.not.any.existing.logger |
142e0 | 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 | ......*/.....public.function.set |
14300 | 44 65 66 61 75 6c 74 4c 6f 67 67 65 72 28 4c 6f 67 67 65 72 49 6e 74 65 72 66 61 63 65 20 24 6c | DefaultLogger(LoggerInterface.$l |
14320 | 6f 67 67 65 72 2c 20 24 6c 65 76 65 6c 73 20 3d 20 45 5f 41 4c 4c 2c 20 24 72 65 70 6c 61 63 65 | ogger,.$levels.=.E_ALL,.$replace |
14340 | 20 3d 20 66 61 6c 73 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 6c 6f 67 67 65 72 73 | .=.false).....{.........$loggers |
14360 | 20 3d 20 61 72 72 61 79 28 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 69 73 5f 61 72 72 61 | .=.array();..........if.(is_arra |
14380 | 79 28 24 6c 65 76 65 6c 73 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 | y($levels)).{.............foreac |
143a0 | 68 20 28 24 6c 65 76 65 6c 73 20 61 73 20 24 74 79 70 65 20 3d 3e 20 24 6c 6f 67 4c 65 76 65 6c | h.($levels.as.$type.=>.$logLevel |
143c0 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 65 6d 70 74 79 28 24 74 | ).{.................if.(empty($t |
143e0 | 68 69 73 2d 3e 6c 6f 67 67 65 72 73 5b 24 74 79 70 65 5d 5b 30 5d 29 20 7c 7c 20 24 72 65 70 6c | his->loggers[$type][0]).||.$repl |
14400 | 61 63 65 20 7c 7c 20 24 74 68 69 73 2d 3e 6c 6f 67 67 65 72 73 5b 24 74 79 70 65 5d 5b 30 5d 20 | ace.||.$this->loggers[$type][0]. |
14420 | 3d 3d 3d 20 24 74 68 69 73 2d 3e 62 6f 6f 74 73 74 72 61 70 70 69 6e 67 4c 6f 67 67 65 72 29 20 | ===.$this->bootstrappingLogger). |
14440 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 6f 67 67 65 72 73 5b 24 | {.....................$loggers[$ |
14460 | 74 79 70 65 5d 20 3d 20 61 72 72 61 79 28 24 6c 6f 67 67 65 72 2c 20 24 6c 6f 67 4c 65 76 65 6c | type].=.array($logger,.$logLevel |
14480 | 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 | );.................}............ |
144a0 | 20 7d 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | .}.........}.else.{............. |
144c0 | 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 6c 65 76 65 6c 73 29 20 7b 0a 20 20 20 20 20 20 20 20 | if.(null.===.$levels).{......... |
144e0 | 20 20 20 20 20 20 20 20 24 6c 65 76 65 6c 73 20 3d 20 45 5f 41 4c 4c 3b 0a 20 20 20 20 20 20 20 | ........$levels.=.E_ALL;........ |
14500 | 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 74 68 69 | .....}.............foreach.($thi |
14520 | 73 2d 3e 6c 6f 67 67 65 72 73 20 61 73 20 24 74 79 70 65 20 3d 3e 20 24 6c 6f 67 29 20 7b 0a 20 | s->loggers.as.$type.=>.$log).{.. |
14540 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 28 24 74 79 70 65 20 26 20 24 6c 65 76 | ...............if.(($type.&.$lev |
14560 | 65 6c 73 29 20 26 26 20 28 65 6d 70 74 79 28 24 6c 6f 67 5b 30 5d 29 20 7c 7c 20 24 72 65 70 6c | els).&&.(empty($log[0]).||.$repl |
14580 | 61 63 65 20 7c 7c 20 24 6c 6f 67 5b 30 5d 20 3d 3d 3d 20 24 74 68 69 73 2d 3e 62 6f 6f 74 73 74 | ace.||.$log[0].===.$this->bootst |
145a0 | 72 61 70 70 69 6e 67 4c 6f 67 67 65 72 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | rappingLogger)).{............... |
145c0 | 20 20 20 20 20 20 24 6c 6f 67 5b 30 5d 20 3d 20 24 6c 6f 67 67 65 72 3b 0a 20 20 20 20 20 20 20 | ......$log[0].=.$logger;........ |
145e0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 6f 67 67 65 72 73 5b 24 74 79 70 65 5d 20 3d 20 24 | .............$loggers[$type].=.$ |
14600 | 6c 6f 67 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 | log;.................}.......... |
14620 | 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 | ...}.........}..........$this->s |
14640 | 65 74 4c 6f 67 67 65 72 73 28 24 6c 6f 67 67 65 72 73 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 | etLoggers($loggers);.....}...... |
14660 | 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 61 20 6c 6f 67 67 65 72 20 66 6f 72 20 65 61 63 | /**......*.Sets.a.logger.for.eac |
14680 | 68 20 65 72 72 6f 72 20 6c 65 76 65 6c 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 | h.error.level.......*......*.@pa |
146a0 | 72 61 6d 20 61 72 72 61 79 20 24 6c 6f 67 67 65 72 73 20 45 72 72 6f 72 20 6c 65 76 65 6c 73 20 | ram.array.$loggers.Error.levels. |
146c0 | 74 6f 20 5b 4c 6f 67 67 65 72 49 6e 74 65 72 66 61 63 65 7c 6e 75 6c 6c 2c 20 4c 6f 67 4c 65 76 | to.[LoggerInterface|null,.LogLev |
146e0 | 65 6c 3a 3a 2a 5d 20 6d 61 70 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e | el::*].map......*......*.@return |
14700 | 20 61 72 72 61 79 20 54 68 65 20 70 72 65 76 69 6f 75 73 20 6d 61 70 0a 20 20 20 20 20 2a 0a 20 | .array.The.previous.map......*.. |
14720 | 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 | ....*.@throws.\InvalidArgumentEx |
14740 | 63 65 70 74 69 6f 6e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 | ception......*/.....public.funct |
14760 | 69 6f 6e 20 73 65 74 4c 6f 67 67 65 72 73 28 61 72 72 61 79 20 24 6c 6f 67 67 65 72 73 29 0a 20 | ion.setLoggers(array.$loggers).. |
14780 | 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 70 72 65 76 4c 6f 67 67 65 64 20 3d 20 24 74 68 69 73 | ...{.........$prevLogged.=.$this |
147a0 | 2d 3e 6c 6f 67 67 65 64 45 72 72 6f 72 73 3b 0a 20 20 20 20 20 20 20 20 24 70 72 65 76 20 3d 20 | ->loggedErrors;.........$prev.=. |
147c0 | 24 74 68 69 73 2d 3e 6c 6f 67 67 65 72 73 3b 0a 20 20 20 20 20 20 20 20 24 66 6c 75 73 68 20 3d | $this->loggers;.........$flush.= |
147e0 | 20 61 72 72 61 79 28 29 3b 0a 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 6c 6f 67 | .array();..........foreach.($log |
14800 | 67 65 72 73 20 61 73 20 24 74 79 70 65 20 3d 3e 20 24 6c 6f 67 29 20 7b 0a 20 20 20 20 20 20 20 | gers.as.$type.=>.$log).{........ |
14820 | 20 20 20 20 20 69 66 20 28 21 69 73 73 65 74 28 24 70 72 65 76 5b 24 74 79 70 65 5d 29 29 20 7b | .....if.(!isset($prev[$type])).{ |
14840 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 5c 49 6e 76 61 | .................throw.new.\Inva |
14860 | 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 27 55 6e 6b 6e 6f 77 6e 20 65 72 | lidArgumentException('Unknown.er |
14880 | 72 6f 72 20 74 79 70 65 3a 20 27 2e 24 74 79 70 65 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ror.type:.'.$type);............. |
148a0 | 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 21 69 73 5f 61 72 72 61 79 28 24 6c 6f 67 | }.............if.(!is_array($log |
148c0 | 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 6f 67 20 3d 20 61 72 72 61 | )).{.................$log.=.arra |
148e0 | 79 28 24 6c 6f 67 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 21 | y($log);.............}.elseif.(! |
14900 | 61 72 72 61 79 5f 6b 65 79 5f 65 78 69 73 74 73 28 30 2c 20 24 6c 6f 67 29 29 20 7b 0a 20 20 20 | array_key_exists(0,.$log)).{.... |
14920 | 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 5c 49 6e 76 61 6c 69 64 41 | .............throw.new.\InvalidA |
14940 | 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 27 4e 6f 20 6c 6f 67 67 65 72 20 70 72 6f 76 | rgumentException('No.logger.prov |
14960 | 69 64 65 64 27 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 | ided');.............}........... |
14980 | 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 6c 6f 67 5b 30 5d 29 20 7b 0a 20 20 20 20 20 20 | ..if.(null.===.$log[0]).{....... |
149a0 | 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6c 6f 67 67 65 64 45 72 72 6f 72 73 20 26 3d | ..........$this->loggedErrors.&= |
149c0 | 20 7e 24 74 79 70 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 24 | .~$type;.............}.elseif.($ |
149e0 | 6c 6f 67 5b 30 5d 20 69 6e 73 74 61 6e 63 65 6f 66 20 4c 6f 67 67 65 72 49 6e 74 65 72 66 61 63 | log[0].instanceof.LoggerInterfac |
14a00 | 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6c 6f 67 67 | e).{.................$this->logg |
14a20 | 65 64 45 72 72 6f 72 73 20 7c 3d 20 24 74 79 70 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d | edErrors.|=.$type;.............} |
14a40 | 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 | .else.{.................throw.ne |
14a60 | 77 20 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 27 49 6e 76 | w.\InvalidArgumentException('Inv |
14a80 | 61 6c 69 64 20 6c 6f 67 67 65 72 20 70 72 6f 76 69 64 65 64 27 29 3b 0a 20 20 20 20 20 20 20 20 | alid.logger.provided');......... |
14aa0 | 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6c 6f 67 67 65 72 73 | ....}.............$this->loggers |
14ac0 | 5b 24 74 79 70 65 5d 20 3d 20 24 6c 6f 67 20 2b 20 24 70 72 65 76 5b 24 74 79 70 65 5d 3b 0a 0a | [$type].=.$log.+.$prev[$type];.. |
14ae0 | 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 74 68 69 73 2d 3e 62 6f 6f 74 73 74 72 61 70 | ............if.($this->bootstrap |
14b00 | 70 69 6e 67 4c 6f 67 67 65 72 20 26 26 20 24 70 72 65 76 5b 24 74 79 70 65 5d 5b 30 5d 20 3d 3d | pingLogger.&&.$prev[$type][0].== |
14b20 | 3d 20 24 74 68 69 73 2d 3e 62 6f 6f 74 73 74 72 61 70 70 69 6e 67 4c 6f 67 67 65 72 29 20 7b 0a | =.$this->bootstrappingLogger).{. |
14b40 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 66 6c 75 73 68 5b 24 74 79 70 65 5d 20 3d 20 | ................$flush[$type].=. |
14b60 | 24 74 79 70 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 20 | $type;.............}.........}.. |
14b80 | 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 72 65 52 65 67 69 73 74 65 72 28 24 70 72 65 76 4c 6f | .......$this->reRegister($prevLo |
14ba0 | 67 67 65 64 20 7c 20 24 74 68 69 73 2d 3e 74 68 72 6f 77 6e 45 72 72 6f 72 73 29 3b 0a 0a 20 20 | gged.|.$this->thrownErrors);.... |
14bc0 | 20 20 20 20 20 20 69 66 20 28 24 66 6c 75 73 68 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ......if.($flush).{............. |
14be0 | 66 6f 72 65 61 63 68 20 28 24 74 68 69 73 2d 3e 62 6f 6f 74 73 74 72 61 70 70 69 6e 67 4c 6f 67 | foreach.($this->bootstrappingLog |
14c00 | 67 65 72 2d 3e 63 6c 65 61 6e 4c 6f 67 73 28 29 20 61 73 20 24 6c 6f 67 29 20 7b 0a 20 20 20 20 | ger->cleanLogs().as.$log).{..... |
14c20 | 20 20 20 20 20 20 20 20 20 20 20 20 24 74 79 70 65 20 3d 20 24 6c 6f 67 5b 32 5d 5b 27 74 79 70 | ............$type.=.$log[2]['typ |
14c40 | 65 27 5d 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 21 69 73 73 65 74 28 | e'];.................if.(!isset( |
14c60 | 24 66 6c 75 73 68 5b 24 74 79 70 65 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | $flush[$type])).{............... |
14c80 | 20 20 20 20 20 20 24 74 68 69 73 2d 3e 62 6f 6f 74 73 74 72 61 70 70 69 6e 67 4c 6f 67 67 65 72 | ......$this->bootstrappingLogger |
14ca0 | 2d 3e 6c 6f 67 28 24 6c 6f 67 5b 30 5d 2c 20 24 6c 6f 67 5b 31 5d 2c 20 24 6c 6f 67 5b 32 5d 29 | ->log($log[0],.$log[1],.$log[2]) |
14cc0 | 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 24 74 68 69 | ;.................}.elseif.($thi |
14ce0 | 73 2d 3e 6c 6f 67 67 65 72 73 5b 24 74 79 70 65 5d 5b 30 5d 29 20 7b 0a 20 20 20 20 20 20 20 20 | s->loggers[$type][0]).{......... |
14d00 | 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6c 6f 67 67 65 72 73 5b 24 74 79 70 65 | ............$this->loggers[$type |
14d20 | 5d 5b 30 5d 2d 3e 6c 6f 67 28 24 74 68 69 73 2d 3e 6c 6f 67 67 65 72 73 5b 24 74 79 70 65 5d 5b | ][0]->log($this->loggers[$type][ |
14d40 | 31 5d 2c 20 24 6c 6f 67 5b 31 5d 2c 20 24 6c 6f 67 5b 32 5d 29 3b 0a 20 20 20 20 20 20 20 20 20 | 1],.$log[1],.$log[2]);.......... |
14d60 | 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d | .......}.............}.........} |
14d80 | 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 70 72 65 76 3b 0a 20 20 20 20 7d 0a 0a 20 | ..........return.$prev;.....}... |
14da0 | 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 61 20 75 73 65 72 20 65 78 63 65 70 74 | .../**......*.Sets.a.user.except |
14dc0 | 69 6f 6e 20 68 61 6e 64 6c 65 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 | ion.handler.......*......*.@para |
14de0 | 6d 20 63 61 6c 6c 61 62 6c 65 20 24 68 61 6e 64 6c 65 72 20 41 20 68 61 6e 64 6c 65 72 20 74 68 | m.callable.$handler.A.handler.th |
14e00 | 61 74 20 77 69 6c 6c 20 62 65 20 63 61 6c 6c 65 64 20 6f 6e 20 45 78 63 65 70 74 69 6f 6e 0a 20 | at.will.be.called.on.Exception.. |
14e20 | 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 63 61 6c 6c 61 62 6c 65 7c 6e 75 | ....*......*.@return.callable|nu |
14e40 | 6c 6c 20 54 68 65 20 70 72 65 76 69 6f 75 73 20 65 78 63 65 70 74 69 6f 6e 20 68 61 6e 64 6c 65 | ll.The.previous.exception.handle |
14e60 | 72 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 | r......*/.....public.function.se |
14e80 | 74 45 78 63 65 70 74 69 6f 6e 48 61 6e 64 6c 65 72 28 63 61 6c 6c 61 62 6c 65 20 24 68 61 6e 64 | tExceptionHandler(callable.$hand |
14ea0 | 6c 65 72 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 70 72 65 76 20 | ler.=.null).....{.........$prev. |
14ec0 | 3d 20 24 74 68 69 73 2d 3e 65 78 63 65 70 74 69 6f 6e 48 61 6e 64 6c 65 72 3b 0a 20 20 20 20 20 | =.$this->exceptionHandler;...... |
14ee0 | 20 20 20 24 74 68 69 73 2d 3e 65 78 63 65 70 74 69 6f 6e 48 61 6e 64 6c 65 72 20 3d 20 24 68 61 | ...$this->exceptionHandler.=.$ha |
14f00 | 6e 64 6c 65 72 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 70 72 65 76 3b 0a 20 20 | ndler;..........return.$prev;... |
14f20 | 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 74 68 65 20 50 48 50 | ..}....../**......*.Sets.the.PHP |
14f40 | 20 65 72 72 6f 72 20 6c 65 76 65 6c 73 20 74 68 61 74 20 74 68 72 6f 77 20 61 6e 20 65 78 63 65 | .error.levels.that.throw.an.exce |
14f60 | 70 74 69 6f 6e 20 77 68 65 6e 20 61 20 50 48 50 20 65 72 72 6f 72 20 6f 63 63 75 72 73 2e 0a 20 | ption.when.a.PHP.error.occurs... |
14f80 | 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 69 6e 74 20 20 24 6c 65 76 65 6c 73 | ....*......*.@param.int..$levels |
14fa0 | 20 20 41 20 62 69 74 20 66 69 65 6c 64 20 6f 66 20 45 5f 2a 20 63 6f 6e 73 74 61 6e 74 73 20 66 | ..A.bit.field.of.E_*.constants.f |
14fc0 | 6f 72 20 74 68 72 6f 77 6e 20 65 72 72 6f 72 73 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 62 | or.thrown.errors......*.@param.b |
14fe0 | 6f 6f 6c 20 24 72 65 70 6c 61 63 65 20 52 65 70 6c 61 63 65 20 6f 72 20 61 6d 65 6e 64 20 74 68 | ool.$replace.Replace.or.amend.th |
15000 | 65 20 70 72 65 76 69 6f 75 73 20 76 61 6c 75 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 | e.previous.value......*......*.@ |
15020 | 72 65 74 75 72 6e 20 69 6e 74 20 54 68 65 20 70 72 65 76 69 6f 75 73 20 76 61 6c 75 65 0a 20 20 | return.int.The.previous.value... |
15040 | 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 74 68 72 6f 77 41 | ...*/.....public.function.throwA |
15060 | 74 28 24 6c 65 76 65 6c 73 2c 20 24 72 65 70 6c 61 63 65 20 3d 20 66 61 6c 73 65 29 0a 20 20 20 | t($levels,.$replace.=.false).... |
15080 | 20 7b 0a 20 20 20 20 20 20 20 20 24 70 72 65 76 20 3d 20 24 74 68 69 73 2d 3e 74 68 72 6f 77 6e | .{.........$prev.=.$this->thrown |
150a0 | 45 72 72 6f 72 73 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 74 68 72 6f 77 6e 45 72 72 | Errors;.........$this->thrownErr |
150c0 | 6f 72 73 20 3d 20 28 24 6c 65 76 65 6c 73 20 7c 20 45 5f 52 45 43 4f 56 45 52 41 42 4c 45 5f 45 | ors.=.($levels.|.E_RECOVERABLE_E |
150e0 | 52 52 4f 52 20 7c 20 45 5f 55 53 45 52 5f 45 52 52 4f 52 29 20 26 20 7e 45 5f 55 53 45 52 5f 44 | RROR.|.E_USER_ERROR).&.~E_USER_D |
15100 | 45 50 52 45 43 41 54 45 44 20 26 20 7e 45 5f 44 45 50 52 45 43 41 54 45 44 3b 0a 20 20 20 20 20 | EPRECATED.&.~E_DEPRECATED;...... |
15120 | 20 20 20 69 66 20 28 21 24 72 65 70 6c 61 63 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ...if.(!$replace).{............. |
15140 | 24 74 68 69 73 2d 3e 74 68 72 6f 77 6e 45 72 72 6f 72 73 20 7c 3d 20 24 70 72 65 76 3b 0a 20 20 | $this->thrownErrors.|=.$prev;... |
15160 | 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 72 65 52 65 67 69 73 74 65 | ......}.........$this->reRegiste |
15180 | 72 28 24 70 72 65 76 20 7c 20 24 74 68 69 73 2d 3e 6c 6f 67 67 65 64 45 72 72 6f 72 73 29 3b 0a | r($prev.|.$this->loggedErrors);. |
151a0 | 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 70 72 65 76 3b 0a 20 20 20 20 7d 0a 0a 20 20 | .........return.$prev;.....}.... |
151c0 | 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 74 68 65 20 50 48 50 20 65 72 72 6f 72 20 | ../**......*.Sets.the.PHP.error. |
151e0 | 6c 65 76 65 6c 73 20 66 6f 72 20 77 68 69 63 68 20 6c 6f 63 61 6c 20 76 61 72 69 61 62 6c 65 73 | levels.for.which.local.variables |
15200 | 20 61 72 65 20 70 72 65 73 65 72 76 65 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 | .are.preserved.......*......*.@p |
15220 | 61 72 61 6d 20 69 6e 74 20 20 24 6c 65 76 65 6c 73 20 20 41 20 62 69 74 20 66 69 65 6c 64 20 6f | aram.int..$levels..A.bit.field.o |
15240 | 66 20 45 5f 2a 20 63 6f 6e 73 74 61 6e 74 73 20 66 6f 72 20 73 63 6f 70 65 64 20 65 72 72 6f 72 | f.E_*.constants.for.scoped.error |
15260 | 73 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 62 6f 6f 6c 20 24 72 65 70 6c 61 63 65 20 52 65 | s......*.@param.bool.$replace.Re |
15280 | 70 6c 61 63 65 20 6f 72 20 61 6d 65 6e 64 20 74 68 65 20 70 72 65 76 69 6f 75 73 20 76 61 6c 75 | place.or.amend.the.previous.valu |
152a0 | 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 69 6e 74 20 54 68 65 20 | e......*......*.@return.int.The. |
152c0 | 70 72 65 76 69 6f 75 73 20 76 61 6c 75 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 | previous.value......*/.....publi |
152e0 | 63 20 66 75 6e 63 74 69 6f 6e 20 73 63 6f 70 65 41 74 28 24 6c 65 76 65 6c 73 2c 20 24 72 65 70 | c.function.scopeAt($levels,.$rep |
15300 | 6c 61 63 65 20 3d 20 66 61 6c 73 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 70 72 65 | lace.=.false).....{.........$pre |
15320 | 76 20 3d 20 24 74 68 69 73 2d 3e 73 63 6f 70 65 64 45 72 72 6f 72 73 3b 0a 20 20 20 20 20 20 20 | v.=.$this->scopedErrors;........ |
15340 | 20 24 74 68 69 73 2d 3e 73 63 6f 70 65 64 45 72 72 6f 72 73 20 3d 20 28 69 6e 74 29 20 24 6c 65 | .$this->scopedErrors.=.(int).$le |
15360 | 76 65 6c 73 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 24 72 65 70 6c 61 63 65 29 20 7b 0a 20 | vels;.........if.(!$replace).{.. |
15380 | 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 63 6f 70 65 64 45 72 72 6f 72 73 20 7c | ...........$this->scopedErrors.| |
153a0 | 3d 20 24 70 72 65 76 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 | =.$prev;.........}..........retu |
153c0 | 72 6e 20 24 70 72 65 76 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 | rn.$prev;.....}....../**......*. |
153e0 | 53 65 74 73 20 74 68 65 20 50 48 50 20 65 72 72 6f 72 20 6c 65 76 65 6c 73 20 66 6f 72 20 77 68 | Sets.the.PHP.error.levels.for.wh |
15400 | 69 63 68 20 74 68 65 20 73 74 61 63 6b 20 74 72 61 63 65 20 69 73 20 70 72 65 73 65 72 76 65 64 | ich.the.stack.trace.is.preserved |
15420 | 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 69 6e 74 20 20 24 6c 65 76 | .......*......*.@param.int..$lev |
15440 | 65 6c 73 20 20 41 20 62 69 74 20 66 69 65 6c 64 20 6f 66 20 45 5f 2a 20 63 6f 6e 73 74 61 6e 74 | els..A.bit.field.of.E_*.constant |
15460 | 73 20 66 6f 72 20 74 72 61 63 65 64 20 65 72 72 6f 72 73 0a 20 20 20 20 20 2a 20 40 70 61 72 61 | s.for.traced.errors......*.@para |
15480 | 6d 20 62 6f 6f 6c 20 24 72 65 70 6c 61 63 65 20 52 65 70 6c 61 63 65 20 6f 72 20 61 6d 65 6e 64 | m.bool.$replace.Replace.or.amend |
154a0 | 20 74 68 65 20 70 72 65 76 69 6f 75 73 20 76 61 6c 75 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 | .the.previous.value......*...... |
154c0 | 2a 20 40 72 65 74 75 72 6e 20 69 6e 74 20 54 68 65 20 70 72 65 76 69 6f 75 73 20 76 61 6c 75 65 | *.@return.int.The.previous.value |
154e0 | 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 74 72 61 | ......*/.....public.function.tra |
15500 | 63 65 41 74 28 24 6c 65 76 65 6c 73 2c 20 24 72 65 70 6c 61 63 65 20 3d 20 66 61 6c 73 65 29 0a | ceAt($levels,.$replace.=.false). |
15520 | 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 70 72 65 76 20 3d 20 24 74 68 69 73 2d 3e 74 72 61 | ....{.........$prev.=.$this->tra |
15540 | 63 65 64 45 72 72 6f 72 73 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 74 72 61 63 65 64 | cedErrors;.........$this->traced |
15560 | 45 72 72 6f 72 73 20 3d 20 28 69 6e 74 29 20 24 6c 65 76 65 6c 73 3b 0a 20 20 20 20 20 20 20 20 | Errors.=.(int).$levels;......... |
15580 | 69 66 20 28 21 24 72 65 70 6c 61 63 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 | if.(!$replace).{.............$th |
155a0 | 69 73 2d 3e 74 72 61 63 65 64 45 72 72 6f 72 73 20 7c 3d 20 24 70 72 65 76 3b 0a 20 20 20 20 20 | is->tracedErrors.|=.$prev;...... |
155c0 | 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 70 72 65 76 3b 0a 20 20 20 20 | ...}..........return.$prev;..... |
155e0 | 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 74 68 65 20 65 72 72 6f 72 | }....../**......*.Sets.the.error |
15600 | 20 6c 65 76 65 6c 73 20 77 68 65 72 65 20 74 68 65 20 40 2d 6f 70 65 72 61 74 6f 72 20 69 73 20 | .levels.where.the.@-operator.is. |
15620 | 69 67 6e 6f 72 65 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 69 6e | ignored.......*......*.@param.in |
15640 | 74 20 20 24 6c 65 76 65 6c 73 20 20 41 20 62 69 74 20 66 69 65 6c 64 20 6f 66 20 45 5f 2a 20 63 | t..$levels..A.bit.field.of.E_*.c |
15660 | 6f 6e 73 74 61 6e 74 73 20 66 6f 72 20 73 63 72 65 61 6d 65 64 20 65 72 72 6f 72 73 0a 20 20 20 | onstants.for.screamed.errors.... |
15680 | 20 20 2a 20 40 70 61 72 61 6d 20 62 6f 6f 6c 20 24 72 65 70 6c 61 63 65 20 52 65 70 6c 61 63 65 | ..*.@param.bool.$replace.Replace |
156a0 | 20 6f 72 20 61 6d 65 6e 64 20 74 68 65 20 70 72 65 76 69 6f 75 73 20 76 61 6c 75 65 0a 20 20 20 | .or.amend.the.previous.value.... |
156c0 | 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 69 6e 74 20 54 68 65 20 70 72 65 76 69 | ..*......*.@return.int.The.previ |
156e0 | 6f 75 73 20 76 61 6c 75 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e | ous.value......*/.....public.fun |
15700 | 63 74 69 6f 6e 20 73 63 72 65 61 6d 41 74 28 24 6c 65 76 65 6c 73 2c 20 24 72 65 70 6c 61 63 65 | ction.screamAt($levels,.$replace |
15720 | 20 3d 20 66 61 6c 73 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 70 72 65 76 20 3d 20 | .=.false).....{.........$prev.=. |
15740 | 24 74 68 69 73 2d 3e 73 63 72 65 61 6d 65 64 45 72 72 6f 72 73 3b 0a 20 20 20 20 20 20 20 20 24 | $this->screamedErrors;.........$ |
15760 | 74 68 69 73 2d 3e 73 63 72 65 61 6d 65 64 45 72 72 6f 72 73 20 3d 20 28 69 6e 74 29 20 24 6c 65 | this->screamedErrors.=.(int).$le |
15780 | 76 65 6c 73 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 24 72 65 70 6c 61 63 65 29 20 7b 0a 20 | vels;.........if.(!$replace).{.. |
157a0 | 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 63 72 65 61 6d 65 64 45 72 72 6f 72 73 | ...........$this->screamedErrors |
157c0 | 20 7c 3d 20 24 70 72 65 76 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 | .|=.$prev;.........}..........re |
157e0 | 74 75 72 6e 20 24 70 72 65 76 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 | turn.$prev;.....}....../**...... |
15800 | 2a 20 52 65 2d 72 65 67 69 73 74 65 72 73 20 61 73 20 61 20 50 48 50 20 65 72 72 6f 72 20 68 61 | *.Re-registers.as.a.PHP.error.ha |
15820 | 6e 64 6c 65 72 20 69 66 20 6c 65 76 65 6c 73 20 63 68 61 6e 67 65 64 2e 0a 20 20 20 20 20 2a 2f | ndler.if.levels.changed.......*/ |
15840 | 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 72 65 52 65 67 69 73 74 65 72 | .....private.function.reRegister |
15860 | 28 24 70 72 65 76 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 70 72 65 76 20 | ($prev).....{.........if.($prev. |
15880 | 21 3d 3d 20 24 74 68 69 73 2d 3e 74 68 72 6f 77 6e 45 72 72 6f 72 73 20 7c 20 24 74 68 69 73 2d | !==.$this->thrownErrors.|.$this- |
158a0 | 3e 6c 6f 67 67 65 64 45 72 72 6f 72 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 68 61 | >loggedErrors).{.............$ha |
158c0 | 6e 64 6c 65 72 20 3d 20 73 65 74 5f 65 72 72 6f 72 5f 68 61 6e 64 6c 65 72 28 27 76 61 72 5f 64 | ndler.=.set_error_handler('var_d |
158e0 | 75 6d 70 27 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 68 61 6e 64 6c 65 72 20 3d 20 69 73 | ump');.............$handler.=.is |
15900 | 5f 61 72 72 61 79 28 24 68 61 6e 64 6c 65 72 29 20 3f 20 24 68 61 6e 64 6c 65 72 5b 30 5d 20 3a | _array($handler).?.$handler[0].: |
15920 | 20 6e 75 6c 6c 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 73 74 6f 72 65 5f 65 72 72 6f 72 | .null;.............restore_error |
15940 | 5f 68 61 6e 64 6c 65 72 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 68 61 6e | _handler();.............if.($han |
15960 | 64 6c 65 72 20 3d 3d 3d 20 24 74 68 69 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | dler.===.$this).{............... |
15980 | 20 20 72 65 73 74 6f 72 65 5f 65 72 72 6f 72 5f 68 61 6e 64 6c 65 72 28 29 3b 0a 20 20 20 20 20 | ..restore_error_handler();...... |
159a0 | 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 74 68 69 73 2d 3e 69 73 52 6f 6f 74 29 20 7b 0a | ...........if.($this->isRoot).{. |
159c0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 73 65 74 5f 65 72 72 6f 72 5f 68 61 | ....................set_error_ha |
159e0 | 6e 64 6c 65 72 28 61 72 72 61 79 28 24 74 68 69 73 2c 20 27 68 61 6e 64 6c 65 45 72 72 6f 72 27 | ndler(array($this,.'handleError' |
15a00 | 29 2c 20 24 74 68 69 73 2d 3e 74 68 72 6f 77 6e 45 72 72 6f 72 73 20 7c 20 24 74 68 69 73 2d 3e | ),.$this->thrownErrors.|.$this-> |
15a20 | 6c 6f 67 67 65 64 45 72 72 6f 72 73 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d | loggedErrors);.................} |
15a40 | 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 73 65 74 5f | .else.{.....................set_ |
15a60 | 65 72 72 6f 72 5f 68 61 6e 64 6c 65 72 28 61 72 72 61 79 28 24 74 68 69 73 2c 20 27 68 61 6e 64 | error_handler(array($this,.'hand |
15a80 | 6c 65 45 72 72 6f 72 27 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 | leError'));.................}... |
15aa0 | 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 | ..........}.........}.....}..... |
15ac0 | 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 48 61 6e 64 6c 65 73 20 65 72 72 6f 72 73 20 62 79 20 66 69 | ./**......*.Handles.errors.by.fi |
15ae0 | 6c 74 65 72 69 6e 67 20 74 68 65 6e 20 6c 6f 67 67 69 6e 67 20 74 68 65 6d 20 61 63 63 6f 72 64 | ltering.then.logging.them.accord |
15b00 | 69 6e 67 20 74 6f 20 74 68 65 20 63 6f 6e 66 69 67 75 72 65 64 20 62 69 74 20 66 69 65 6c 64 73 | ing.to.the.configured.bit.fields |
15b20 | 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 69 6e 74 20 20 20 20 24 74 | .......*......*.@param.int....$t |
15b40 | 79 70 65 20 20 20 20 20 20 4f 6e 65 20 6f 66 20 74 68 65 20 45 5f 2a 20 63 6f 6e 73 74 61 6e 74 | ype......One.of.the.E_*.constant |
15b60 | 73 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6d 65 73 73 61 67 65 0a | s......*.@param.string.$message. |
15b80 | 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 66 69 6c 65 0a 20 20 20 20 20 | .....*.@param.string.$file...... |
15ba0 | 2a 20 40 70 61 72 61 6d 20 69 6e 74 20 20 20 20 24 6c 69 6e 65 0a 20 20 20 20 20 2a 20 40 70 61 | *.@param.int....$line......*.@pa |
15bc0 | 72 61 6d 20 61 72 72 61 79 20 20 24 63 6f 6e 74 65 78 74 0a 20 20 20 20 20 2a 20 40 70 61 72 61 | ram.array..$context......*.@para |
15be0 | 6d 20 61 72 72 61 79 20 20 24 62 61 63 6b 74 72 61 63 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 | m.array..$backtrace......*...... |
15c00 | 2a 20 40 72 65 74 75 72 6e 20 62 6f 6f 6c 20 52 65 74 75 72 6e 73 20 66 61 6c 73 65 20 77 68 65 | *.@return.bool.Returns.false.whe |
15c20 | 6e 20 6e 6f 20 68 61 6e 64 6c 69 6e 67 20 68 61 70 70 65 6e 73 20 73 6f 20 74 68 61 74 20 74 68 | n.no.handling.happens.so.that.th |
15c40 | 65 20 50 48 50 20 65 6e 67 69 6e 65 20 63 61 6e 20 68 61 6e 64 6c 65 20 74 68 65 20 65 72 72 6f | e.PHP.engine.can.handle.the.erro |
15c60 | 72 20 69 74 73 65 6c 66 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 5c | r.itself......*......*.@throws.\ |
15c80 | 45 72 72 6f 72 45 78 63 65 70 74 69 6f 6e 20 57 68 65 6e 20 24 74 68 69 73 2d 3e 74 68 72 6f 77 | ErrorException.When.$this->throw |
15ca0 | 6e 45 72 72 6f 72 73 20 72 65 71 75 65 73 74 73 20 73 6f 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 | nErrors.requests.so......*...... |
15cc0 | 2a 20 40 69 6e 74 65 72 6e 61 6c 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 | *.@internal......*/.....public.f |
15ce0 | 75 6e 63 74 69 6f 6e 20 68 61 6e 64 6c 65 45 72 72 6f 72 28 24 74 79 70 65 2c 20 24 6d 65 73 73 | unction.handleError($type,.$mess |
15d00 | 61 67 65 2c 20 24 66 69 6c 65 2c 20 24 6c 69 6e 65 2c 20 61 72 72 61 79 20 24 63 6f 6e 74 65 78 | age,.$file,.$line,.array.$contex |
15d20 | 74 2c 20 61 72 72 61 79 20 24 62 61 63 6b 74 72 61 63 65 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 | t,.array.$backtrace.=.null)..... |
15d40 | 7b 0a 20 20 20 20 20 20 20 20 24 6c 65 76 65 6c 20 3d 20 65 72 72 6f 72 5f 72 65 70 6f 72 74 69 | {.........$level.=.error_reporti |
15d60 | 6e 67 28 29 20 7c 20 45 5f 52 45 43 4f 56 45 52 41 42 4c 45 5f 45 52 52 4f 52 20 7c 20 45 5f 55 | ng().|.E_RECOVERABLE_ERROR.|.E_U |
15d80 | 53 45 52 5f 45 52 52 4f 52 20 7c 20 45 5f 44 45 50 52 45 43 41 54 45 44 20 7c 20 45 5f 55 53 45 | SER_ERROR.|.E_DEPRECATED.|.E_USE |
15da0 | 52 5f 44 45 50 52 45 43 41 54 45 44 3b 0a 20 20 20 20 20 20 20 20 24 6c 6f 67 20 3d 20 24 74 68 | R_DEPRECATED;.........$log.=.$th |
15dc0 | 69 73 2d 3e 6c 6f 67 67 65 64 45 72 72 6f 72 73 20 26 20 24 74 79 70 65 3b 0a 20 20 20 20 20 20 | is->loggedErrors.&.$type;....... |
15de0 | 20 20 24 74 68 72 6f 77 20 3d 20 24 74 68 69 73 2d 3e 74 68 72 6f 77 6e 45 72 72 6f 72 73 20 26 | ..$throw.=.$this->thrownErrors.& |
15e00 | 20 24 74 79 70 65 20 26 20 24 6c 65 76 65 6c 3b 0a 20 20 20 20 20 20 20 20 24 74 79 70 65 20 26 | .$type.&.$level;.........$type.& |
15e20 | 3d 20 24 6c 65 76 65 6c 20 7c 20 24 74 68 69 73 2d 3e 73 63 72 65 61 6d 65 64 45 72 72 6f 72 73 | =.$level.|.$this->screamedErrors |
15e40 | 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 24 74 79 70 65 20 7c 7c 20 28 21 24 6c 6f 67 20 | ;..........if.(!$type.||.(!$log. |
15e60 | 26 26 20 21 24 74 68 72 6f 77 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 | &&.!$throw)).{.............retur |
15e80 | 6e 20 24 74 79 70 65 20 26 26 20 24 6c 6f 67 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 | n.$type.&&.$log;.........}...... |
15ea0 | 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 21 3d 3d 20 24 62 61 63 6b 74 72 61 63 65 20 26 26 20 24 | ....if.(null.!==.$backtrace.&&.$ |
15ec0 | 74 79 70 65 20 26 20 45 5f 45 52 52 4f 52 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f | type.&.E_ERROR).{.............// |
15ee0 | 20 45 5f 45 52 52 4f 52 20 66 61 74 61 6c 20 65 72 72 6f 72 73 20 61 72 65 20 74 72 69 67 67 65 | .E_ERROR.fatal.errors.are.trigge |
15f00 | 72 65 64 20 6f 6e 20 48 48 56 4d 20 77 68 65 6e 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 | red.on.HHVM.when.............//. |
15f20 | 68 68 76 6d 2e 65 72 72 6f 72 5f 68 61 6e 64 6c 69 6e 67 2e 63 61 6c 6c 5f 75 73 65 72 5f 68 61 | hhvm.error_handling.call_user_ha |
15f40 | 6e 64 6c 65 72 5f 6f 6e 5f 66 61 74 61 6c 73 3d 31 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f | ndler_on_fatals=1.............// |
15f60 | 20 77 68 69 63 68 20 69 73 20 74 68 65 20 77 61 79 20 74 6f 20 67 65 74 20 74 68 65 69 72 20 62 | .which.is.the.way.to.get.their.b |
15f80 | 61 63 6b 74 72 61 63 65 2e 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 68 61 6e | acktrace..............$this->han |
15fa0 | 64 6c 65 46 61 74 61 6c 45 72 72 6f 72 28 63 6f 6d 70 61 63 74 28 27 74 79 70 65 27 2c 20 27 6d | dleFatalError(compact('type',.'m |
15fc0 | 65 73 73 61 67 65 27 2c 20 27 66 69 6c 65 27 2c 20 27 6c 69 6e 65 27 2c 20 27 62 61 63 6b 74 72 | essage',.'file',.'line',.'backtr |
15fe0 | 61 63 65 27 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 74 72 75 65 | ace'));..............return.true |
16000 | 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 74 68 72 6f 77 29 | ;.........}..........if.($throw) |
16020 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 21 3d 3d 20 73 65 6c 66 | .{.............if.(null.!==.self |
16040 | 3a 3a 24 74 6f 53 74 72 69 6e 67 45 78 63 65 70 74 69 6f 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 | ::$toStringException).{......... |
16060 | 20 20 20 20 20 20 20 20 24 74 68 72 6f 77 20 3d 20 73 65 6c 66 3a 3a 24 74 6f 53 74 72 69 6e 67 | ........$throw.=.self::$toString |
16080 | 45 78 63 65 70 74 69 6f 6e 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 73 65 6c 66 3a | Exception;.................self: |
160a0 | 3a 24 74 6f 53 74 72 69 6e 67 45 78 63 65 70 74 69 6f 6e 20 3d 20 6e 75 6c 6c 3b 0a 20 20 20 20 | :$toStringException.=.null;..... |
160c0 | 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 28 24 74 68 69 73 2d 3e 73 63 6f 70 65 64 | ........}.elseif.(($this->scoped |
160e0 | 45 72 72 6f 72 73 20 26 20 24 74 79 70 65 29 20 26 26 20 63 6c 61 73 73 5f 65 78 69 73 74 73 28 | Errors.&.$type).&&.class_exists( |
16100 | 43 6f 6e 74 65 78 74 45 72 72 6f 72 45 78 63 65 70 74 69 6f 6e 3a 3a 63 6c 61 73 73 29 29 20 7b | ContextErrorException::class)).{ |
16120 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 72 6f 77 20 3d 20 6e 65 77 20 43 6f | .................$throw.=.new.Co |
16140 | 6e 74 65 78 74 45 72 72 6f 72 45 78 63 65 70 74 69 6f 6e 28 24 74 68 69 73 2d 3e 6c 65 76 65 6c | ntextErrorException($this->level |
16160 | 73 5b 24 74 79 70 65 5d 2e 27 3a 20 27 2e 24 6d 65 73 73 61 67 65 2c 20 30 2c 20 24 74 79 70 65 | s[$type].':.'.$message,.0,.$type |
16180 | 2c 20 24 66 69 6c 65 2c 20 24 6c 69 6e 65 2c 20 24 63 6f 6e 74 65 78 74 29 3b 0a 20 20 20 20 20 | ,.$file,.$line,.$context);...... |
161a0 | 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | .......}.else.{................. |
161c0 | 24 74 68 72 6f 77 20 3d 20 6e 65 77 20 5c 45 72 72 6f 72 45 78 63 65 70 74 69 6f 6e 28 24 74 68 | $throw.=.new.\ErrorException($th |
161e0 | 69 73 2d 3e 6c 65 76 65 6c 73 5b 24 74 79 70 65 5d 2e 27 3a 20 27 2e 24 6d 65 73 73 61 67 65 2c | is->levels[$type].':.'.$message, |
16200 | 20 30 2c 20 24 74 79 70 65 2c 20 24 66 69 6c 65 2c 20 24 6c 69 6e 65 29 3b 0a 20 20 20 20 20 20 | .0,.$type,.$file,.$line);....... |
16220 | 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 45 5f 55 53 45 52 5f | ......}..............if.(E_USER_ |
16240 | 45 52 52 4f 52 20 26 20 24 74 79 70 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ERROR.&.$type).{................ |
16260 | 20 24 62 61 63 6b 74 72 61 63 65 20 3d 20 24 62 61 63 6b 74 72 61 63 65 20 3f 3a 20 24 74 68 72 | .$backtrace.=.$backtrace.?:.$thr |
16280 | 6f 77 2d 3e 67 65 74 54 72 61 63 65 28 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ow->getTrace();................. |
162a0 | 20 66 6f 72 20 28 24 69 20 3d 20 31 3b 20 69 73 73 65 74 28 24 62 61 63 6b 74 72 61 63 65 5b 24 | .for.($i.=.1;.isset($backtrace[$ |
162c0 | 69 5d 29 3b 20 2b 2b 24 69 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | i]);.++$i).{.................... |
162e0 | 20 69 66 20 28 69 73 73 65 74 28 24 62 61 63 6b 74 72 61 63 65 5b 24 69 5d 5b 27 66 75 6e 63 74 | .if.(isset($backtrace[$i]['funct |
16300 | 69 6f 6e 27 5d 2c 20 24 62 61 63 6b 74 72 61 63 65 5b 24 69 5d 5b 27 74 79 70 65 27 5d 2c 20 24 | ion'],.$backtrace[$i]['type'],.$ |
16320 | 62 61 63 6b 74 72 61 63 65 5b 24 69 20 2d 20 31 5d 5b 27 66 75 6e 63 74 69 6f 6e 27 5d 29 0a 20 | backtrace[$i.-.1]['function']).. |
16340 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 26 26 20 27 5f 5f 74 6f 53 | .......................&&.'__toS |
16360 | 74 72 69 6e 67 27 20 3d 3d 3d 20 24 62 61 63 6b 74 72 61 63 65 5b 24 69 5d 5b 27 66 75 6e 63 74 | tring'.===.$backtrace[$i]['funct |
16380 | 69 6f 6e 27 5d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 26 26 | ion'].........................&& |
163a0 | 20 27 2d 3e 27 20 3d 3d 3d 20 24 62 61 63 6b 74 72 61 63 65 5b 24 69 5d 5b 27 74 79 70 65 27 5d | .'->'.===.$backtrace[$i]['type'] |
163c0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 26 26 20 21 69 73 73 | .........................&&.!iss |
163e0 | 65 74 28 24 62 61 63 6b 74 72 61 63 65 5b 24 69 20 2d 20 31 5d 5b 27 63 6c 61 73 73 27 5d 29 0a | et($backtrace[$i.-.1]['class']). |
16400 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 26 26 20 28 27 74 72 69 | ........................&&.('tri |
16420 | 67 67 65 72 5f 65 72 72 6f 72 27 20 3d 3d 3d 20 24 62 61 63 6b 74 72 61 63 65 5b 24 69 20 2d 20 | gger_error'.===.$backtrace[$i.-. |
16440 | 31 5d 5b 27 66 75 6e 63 74 69 6f 6e 27 5d 20 7c 7c 20 27 75 73 65 72 5f 65 72 72 6f 72 27 20 3d | 1]['function'].||.'user_error'.= |
16460 | 3d 3d 20 24 62 61 63 6b 74 72 61 63 65 5b 24 69 20 2d 20 31 5d 5b 27 66 75 6e 63 74 69 6f 6e 27 | ==.$backtrace[$i.-.1]['function' |
16480 | 5d 29 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 29 20 7b 0a 20 20 20 20 20 | ]).....................).{...... |
164a0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 48 65 72 65 2c 20 77 65 20 6b | ...................//.Here,.we.k |
164c0 | 6e 6f 77 20 74 72 69 67 67 65 72 5f 65 72 72 6f 72 28 29 20 68 61 73 20 62 65 65 6e 20 63 61 6c | now.trigger_error().has.been.cal |
164e0 | 6c 65 64 20 66 72 6f 6d 20 5f 5f 74 6f 53 74 72 69 6e 67 28 29 2e 0a 20 20 20 20 20 20 20 20 20 | led.from.__toString()........... |
16500 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 48 48 56 4d 20 69 73 20 66 69 6e 65 20 77 | ...............//.HHVM.is.fine.w |
16520 | 69 74 68 20 74 68 72 6f 77 69 6e 67 20 66 72 6f 6d 20 5f 5f 74 6f 53 74 72 69 6e 67 28 29 20 62 | ith.throwing.from.__toString().b |
16540 | 75 74 20 50 48 50 20 74 72 69 67 67 65 72 73 20 61 20 66 61 74 61 6c 20 65 72 72 6f 72 20 69 6e | ut.PHP.triggers.a.fatal.error.in |
16560 | 73 74 65 61 64 2e 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2f | stead........................../ |
16580 | 2f 20 41 20 73 6d 61 6c 6c 20 63 6f 6e 76 65 6e 74 69 6f 6e 20 61 6c 6c 6f 77 73 20 77 6f 72 6b | /.A.small.convention.allows.work |
165a0 | 69 6e 67 20 61 72 6f 75 6e 64 20 74 68 65 20 6c 69 6d 69 74 61 74 69 6f 6e 3a 0a 20 20 20 20 20 | ing.around.the.limitation:...... |
165c0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 67 69 76 65 6e 20 61 20 63 61 | ...................//.given.a.ca |
165e0 | 75 67 68 74 20 24 65 20 65 78 63 65 70 74 69 6f 6e 20 69 6e 20 5f 5f 74 6f 53 74 72 69 6e 67 28 | ught.$e.exception.in.__toString( |
16600 | 29 2c 20 71 75 69 74 74 69 6e 67 20 74 68 65 20 6d 65 74 68 6f 64 20 77 69 74 68 0a 20 20 20 20 | ),.quitting.the.method.with..... |
16620 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 60 72 65 74 75 72 6e 20 74 | ....................//.`return.t |
16640 | 72 69 67 67 65 72 5f 65 72 72 6f 72 28 24 65 2c 20 45 5f 55 53 45 52 5f 45 52 52 4f 52 29 3b 60 | rigger_error($e,.E_USER_ERROR);` |
16660 | 20 61 6c 6c 6f 77 73 20 74 68 69 73 20 65 72 72 6f 72 20 68 61 6e 64 6c 65 72 0a 20 20 20 20 20 | .allows.this.error.handler...... |
16680 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 74 6f 20 6d 61 6b 65 20 24 65 | ...................//.to.make.$e |
166a0 | 20 67 65 74 20 74 68 72 6f 75 67 68 20 74 68 65 20 5f 5f 74 6f 53 74 72 69 6e 67 28 29 20 62 61 | .get.through.the.__toString().ba |
166c0 | 72 72 69 65 72 2e 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | rrier........................... |
166e0 | 66 6f 72 65 61 63 68 20 28 24 63 6f 6e 74 65 78 74 20 61 73 20 24 65 29 20 7b 0a 20 20 20 20 20 | foreach.($context.as.$e).{...... |
16700 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 28 24 65 20 69 | .......................if.(($e.i |
16720 | 6e 73 74 61 6e 63 65 6f 66 20 5c 45 78 63 65 70 74 69 6f 6e 20 7c 7c 20 24 65 20 69 6e 73 74 61 | nstanceof.\Exception.||.$e.insta |
16740 | 6e 63 65 6f 66 20 5c 54 68 72 6f 77 61 62 6c 65 29 20 26 26 20 24 65 2d 3e 5f 5f 74 6f 53 74 72 | nceof.\Throwable).&&.$e->__toStr |
16760 | 69 6e 67 28 29 20 3d 3d 3d 20 24 6d 65 73 73 61 67 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | ing().===.$message).{........... |
16780 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 31 20 3d 3d 3d 20 | ......................if.(1.===. |
167a0 | 24 69 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | $i).{........................... |
167c0 | 20 20 20 20 20 20 20 20 20 20 2f 2f 20 4f 6e 20 48 48 56 4d 0a 20 20 20 20 20 20 20 20 20 20 20 | ..........//.On.HHVM............ |
167e0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 72 6f 77 20 | .........................$throw. |
16800 | 3d 20 24 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | =.$e;........................... |
16820 | 20 20 20 20 20 20 20 20 20 20 62 72 65 61 6b 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ..........break;................ |
16840 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | .................}.............. |
16860 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 73 65 6c 66 3a 3a 24 74 6f 53 74 72 69 | ...................self::$toStri |
16880 | 6e 67 45 78 63 65 70 74 69 6f 6e 20 3d 20 24 65 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | ngException.=.$e;............... |
168a0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 74 72 75 65 3b 0a | ...................return.true;. |
168c0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 | ............................}... |
168e0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 | ......................}......... |
16900 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 31 20 3c 20 24 69 29 20 7b 0a 20 | .................if.(1.<.$i).{.. |
16920 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 4f 6e | ...........................//.On |
16940 | 20 50 48 50 20 28 6e 6f 74 20 6f 6e 20 48 48 56 4d 29 2c 20 64 69 73 70 6c 61 79 20 74 68 65 20 | .PHP.(not.on.HHVM),.display.the. |
16960 | 6f 72 69 67 69 6e 61 6c 20 65 72 72 6f 72 20 6d 65 73 73 61 67 65 20 69 6e 73 74 65 61 64 20 6f | original.error.message.instead.o |
16980 | 66 20 74 68 65 20 64 65 66 61 75 6c 74 20 6f 6e 65 2e 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | f.the.default.one............... |
169a0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 68 61 6e 64 6c 65 45 78 63 65 | ...............$this->handleExce |
169c0 | 70 74 69 6f 6e 28 24 74 68 72 6f 77 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ption($throw);.................. |
169e0 | 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 53 74 6f 70 20 74 68 65 20 70 72 6f 63 65 73 73 20 | ............//.Stop.the.process. |
16a00 | 62 79 20 67 69 76 69 6e 67 20 62 61 63 6b 20 74 68 65 20 65 72 72 6f 72 20 74 6f 20 74 68 65 20 | by.giving.back.the.error.to.the. |
16a20 | 6e 61 74 69 76 65 20 68 61 6e 64 6c 65 72 2e 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | native.handler.................. |
16a40 | 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 | ............return.false;....... |
16a60 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ..................}............. |
16a80 | 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 | ........}.................}..... |
16aa0 | 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 24 74 68 | ........}..............throw.$th |
16ac0 | 72 6f 77 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 2f 2f 20 46 6f 72 20 64 | row;.........}..........//.For.d |
16ae0 | 75 70 6c 69 63 61 74 65 64 20 65 72 72 6f 72 73 2c 20 6c 6f 67 20 74 68 65 20 74 72 61 63 65 20 | uplicated.errors,.log.the.trace. |
16b00 | 6f 6e 6c 79 20 6f 6e 63 65 0a 20 20 20 20 20 20 20 20 24 65 20 3d 20 6d 64 35 28 22 7b 24 74 79 | only.once.........$e.=.md5("{$ty |
16b20 | 70 65 7d 2f 7b 24 6c 69 6e 65 7d 2f 7b 24 66 69 6c 65 7d 5c 78 30 30 7b 24 6d 65 73 73 61 67 65 | pe}/{$line}/{$file}\x00{$message |
16b40 | 7d 22 2c 20 74 72 75 65 29 3b 0a 20 20 20 20 20 20 20 20 24 74 72 61 63 65 20 3d 20 74 72 75 65 | }",.true);.........$trace.=.true |
16b60 | 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 28 24 74 68 69 73 2d 3e 74 72 61 63 65 64 45 72 | ;..........if.(!($this->tracedEr |
16b80 | 72 6f 72 73 20 26 20 24 74 79 70 65 29 20 7c 7c 20 69 73 73 65 74 28 24 74 68 69 73 2d 3e 6c 6f | rors.&.$type).||.isset($this->lo |
16ba0 | 67 67 65 64 54 72 61 63 65 73 5b 24 65 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 | ggedTraces[$e])).{.............$ |
16bc0 | 74 72 61 63 65 20 3d 20 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a | trace.=.false;.........}.else.{. |
16be0 | 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6c 6f 67 67 65 64 54 72 61 63 65 73 5b | ............$this->loggedTraces[ |
16c00 | 24 65 5d 20 3d 20 31 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 65 20 3d | $e].=.1;.........}..........$e.= |
16c20 | 20 63 6f 6d 70 61 63 74 28 27 74 79 70 65 27 2c 20 27 66 69 6c 65 27 2c 20 27 6c 69 6e 65 27 2c | .compact('type',.'file',.'line', |
16c40 | 20 27 6c 65 76 65 6c 27 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 74 79 70 65 20 26 20 | .'level');..........if.($type.&. |
16c60 | 24 6c 65 76 65 6c 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 74 68 69 73 2d | $level).{.............if.($this- |
16c80 | 3e 73 63 6f 70 65 64 45 72 72 6f 72 73 20 26 20 24 74 79 70 65 29 20 7b 0a 20 20 20 20 20 20 20 | >scopedErrors.&.$type).{........ |
16ca0 | 20 20 20 20 20 20 20 20 20 24 65 5b 27 73 63 6f 70 65 5f 76 61 72 73 27 5d 20 3d 20 24 63 6f 6e | .........$e['scope_vars'].=.$con |
16cc0 | 74 65 78 74 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 74 72 61 63 65 | text;.................if.($trace |
16ce0 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 65 5b 27 73 74 61 63 | ).{.....................$e['stac |
16d00 | 6b 27 5d 20 3d 20 24 62 61 63 6b 74 72 61 63 65 20 3f 3a 20 64 65 62 75 67 5f 62 61 63 6b 74 72 | k'].=.$backtrace.?:.debug_backtr |
16d20 | 61 63 65 28 44 45 42 55 47 5f 42 41 43 4b 54 52 41 43 45 5f 50 52 4f 56 49 44 45 5f 4f 42 4a 45 | ace(DEBUG_BACKTRACE_PROVIDE_OBJE |
16d40 | 43 54 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 | CT);.................}.......... |
16d60 | 20 20 20 7d 20 65 6c 73 65 69 66 20 28 24 74 72 61 63 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | ...}.elseif.($trace).{.......... |
16d80 | 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 62 61 63 6b 74 72 61 63 65 29 20 | .......if.(null.===.$backtrace). |
16da0 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 65 5b 27 73 74 61 63 6b 27 | {.....................$e['stack' |
16dc0 | 5d 20 3d 20 64 65 62 75 67 5f 62 61 63 6b 74 72 61 63 65 28 44 45 42 55 47 5f 42 41 43 4b 54 52 | ].=.debug_backtrace(DEBUG_BACKTR |
16de0 | 41 43 45 5f 49 47 4e 4f 52 45 5f 41 52 47 53 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ACE_IGNORE_ARGS);............... |
16e00 | 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 66 | ..}.else.{.....................f |
16e20 | 6f 72 65 61 63 68 20 28 24 62 61 63 6b 74 72 61 63 65 20 61 73 20 26 24 66 72 61 6d 65 29 20 7b | oreach.($backtrace.as.&$frame).{ |
16e40 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 75 6e 73 65 74 28 24 | .........................unset($ |
16e60 | 66 72 61 6d 65 5b 27 61 72 67 73 27 5d 2c 20 24 66 72 61 6d 65 29 3b 0a 20 20 20 20 20 20 20 20 | frame['args'],.$frame);......... |
16e80 | 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ............}................... |
16ea0 | 20 20 24 65 5b 27 73 74 61 63 6b 27 5d 20 3d 20 24 62 61 63 6b 74 72 61 63 65 3b 0a 20 20 20 20 | ..$e['stack'].=.$backtrace;..... |
16ec0 | 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 | ............}.............}..... |
16ee0 | 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 74 68 69 73 2d 3e 69 73 52 65 63 75 | ....}..........if.($this->isRecu |
16f00 | 72 73 69 76 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 6f 67 20 3d 20 30 3b 0a 20 | rsive).{.............$log.=.0;.. |
16f20 | 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 73 65 6c 66 3a 3a 24 73 74 61 63 6b 65 64 45 | .......}.elseif.(self::$stackedE |
16f40 | 72 72 6f 72 4c 65 76 65 6c 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 73 65 6c 66 3a 3a | rrorLevels).{.............self:: |
16f60 | 24 73 74 61 63 6b 65 64 45 72 72 6f 72 73 5b 5d 20 3d 20 61 72 72 61 79 28 24 74 68 69 73 2d 3e | $stackedErrors[].=.array($this-> |
16f80 | 6c 6f 67 67 65 72 73 5b 24 74 79 70 65 5d 5b 30 5d 2c 20 28 24 74 79 70 65 20 26 20 24 6c 65 76 | loggers[$type][0],.($type.&.$lev |
16fa0 | 65 6c 29 20 3f 20 24 74 68 69 73 2d 3e 6c 6f 67 67 65 72 73 5b 24 74 79 70 65 5d 5b 31 5d 20 3a | el).?.$this->loggers[$type][1].: |
16fc0 | 20 4c 6f 67 4c 65 76 65 6c 3a 3a 44 45 42 55 47 2c 20 24 6d 65 73 73 61 67 65 2c 20 24 65 29 3b | .LogLevel::DEBUG,.$message,.$e); |
16fe0 | 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 72 | .........}.else.{.............tr |
17000 | 79 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 69 73 52 65 63 | y.{.................$this->isRec |
17020 | 75 72 73 69 76 65 20 3d 20 74 72 75 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 | ursive.=.true;.................$ |
17040 | 74 68 69 73 2d 3e 6c 6f 67 67 65 72 73 5b 24 74 79 70 65 5d 5b 30 5d 2d 3e 6c 6f 67 28 28 24 74 | this->loggers[$type][0]->log(($t |
17060 | 79 70 65 20 26 20 24 6c 65 76 65 6c 29 20 3f 20 24 74 68 69 73 2d 3e 6c 6f 67 67 65 72 73 5b 24 | ype.&.$level).?.$this->loggers[$ |
17080 | 74 79 70 65 5d 5b 31 5d 20 3a 20 4c 6f 67 4c 65 76 65 6c 3a 3a 44 45 42 55 47 2c 20 24 6d 65 73 | type][1].:.LogLevel::DEBUG,.$mes |
170a0 | 73 61 67 65 2c 20 24 65 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 66 69 6e 61 6c 6c 79 | sage,.$e);.............}.finally |
170c0 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 69 73 52 65 63 75 | .{.................$this->isRecu |
170e0 | 72 73 69 76 65 20 3d 20 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 | rsive.=.false;.............}.... |
17100 | 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 79 70 65 20 26 26 20 | .....}..........return.$type.&&. |
17120 | 24 6c 6f 67 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 48 61 6e 64 | $log;.....}....../**......*.Hand |
17140 | 6c 65 73 20 61 6e 20 65 78 63 65 70 74 69 6f 6e 20 62 79 20 6c 6f 67 67 69 6e 67 20 74 68 65 6e | les.an.exception.by.logging.then |
17160 | 20 66 6f 72 77 61 72 64 69 6e 67 20 69 74 20 74 6f 20 61 6e 6f 74 68 65 72 20 68 61 6e 64 6c 65 | .forwarding.it.to.another.handle |
17180 | 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 5c 45 78 63 65 70 74 69 | r.......*......*.@param.\Excepti |
171a0 | 6f 6e 7c 5c 54 68 72 6f 77 61 62 6c 65 20 24 65 78 63 65 70 74 69 6f 6e 20 41 6e 20 65 78 63 65 | on|\Throwable.$exception.An.exce |
171c0 | 70 74 69 6f 6e 20 74 6f 20 68 61 6e 64 6c 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 | ption.to.handle......*.@param.ar |
171e0 | 72 61 79 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 65 72 72 6f 72 20 20 20 20 20 41 | ray.................$error.....A |
17200 | 6e 20 61 72 72 61 79 20 61 73 20 72 65 74 75 72 6e 65 64 20 62 79 20 65 72 72 6f 72 5f 67 65 74 | n.array.as.returned.by.error_get |
17220 | 5f 6c 61 73 74 28 29 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 69 6e 74 65 72 6e 61 6c 0a | _last()......*......*.@internal. |
17240 | 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 68 61 6e 64 | .....*/.....public.function.hand |
17260 | 6c 65 45 78 63 65 70 74 69 6f 6e 28 24 65 78 63 65 70 74 69 6f 6e 2c 20 61 72 72 61 79 20 24 65 | leException($exception,.array.$e |
17280 | 72 72 6f 72 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 | rror.=.null).....{.........if.(! |
172a0 | 24 65 78 63 65 70 74 69 6f 6e 20 69 6e 73 74 61 6e 63 65 6f 66 20 5c 45 78 63 65 70 74 69 6f 6e | $exception.instanceof.\Exception |
172c0 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 65 78 63 65 70 74 69 6f 6e 20 3d 20 6e 65 77 | ).{.............$exception.=.new |
172e0 | 20 46 61 74 61 6c 54 68 72 6f 77 61 62 6c 65 45 72 72 6f 72 28 24 65 78 63 65 70 74 69 6f 6e 29 | .FatalThrowableError($exception) |
17300 | 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 24 74 79 70 65 20 3d 20 24 65 78 63 | ;.........}.........$type.=.$exc |
17320 | 65 70 74 69 6f 6e 20 69 6e 73 74 61 6e 63 65 6f 66 20 46 61 74 61 6c 45 72 72 6f 72 45 78 63 65 | eption.instanceof.FatalErrorExce |
17340 | 70 74 69 6f 6e 20 3f 20 24 65 78 63 65 70 74 69 6f 6e 2d 3e 67 65 74 53 65 76 65 72 69 74 79 28 | ption.?.$exception->getSeverity( |
17360 | 29 20 3a 20 45 5f 45 52 52 4f 52 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 28 24 74 68 69 73 | ).:.E_ERROR;..........if.(($this |
17380 | 2d 3e 6c 6f 67 67 65 64 45 72 72 6f 72 73 20 26 20 24 74 79 70 65 29 20 7c 7c 20 24 65 78 63 65 | ->loggedErrors.&.$type).||.$exce |
173a0 | 70 74 69 6f 6e 20 69 6e 73 74 61 6e 63 65 6f 66 20 46 61 74 61 6c 54 68 72 6f 77 61 62 6c 65 45 | ption.instanceof.FatalThrowableE |
173c0 | 72 72 6f 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 65 20 3d 20 61 72 72 61 79 28 0a | rror).{.............$e.=.array(. |
173e0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 27 74 79 70 65 27 20 3d 3e 20 24 74 79 70 65 2c | ................'type'.=>.$type, |
17400 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 27 66 69 6c 65 27 20 3d 3e 20 24 65 78 63 65 | .................'file'.=>.$exce |
17420 | 70 74 69 6f 6e 2d 3e 67 65 74 46 69 6c 65 28 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ption->getFile(),............... |
17440 | 20 20 27 6c 69 6e 65 27 20 3d 3e 20 24 65 78 63 65 70 74 69 6f 6e 2d 3e 67 65 74 4c 69 6e 65 28 | ..'line'.=>.$exception->getLine( |
17460 | 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 27 6c 65 76 65 6c 27 20 3d 3e 20 65 72 | ),.................'level'.=>.er |
17480 | 72 6f 72 5f 72 65 70 6f 72 74 69 6e 67 28 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ror_reporting(),................ |
174a0 | 20 27 73 74 61 63 6b 27 20 3d 3e 20 24 65 78 63 65 70 74 69 6f 6e 2d 3e 67 65 74 54 72 61 63 65 | .'stack'.=>.$exception->getTrace |
174c0 | 28 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 | (),.............);.............i |
174e0 | 66 20 28 24 65 78 63 65 70 74 69 6f 6e 20 69 6e 73 74 61 6e 63 65 6f 66 20 46 61 74 61 6c 45 72 | f.($exception.instanceof.FatalEr |
17500 | 72 6f 72 45 78 63 65 70 74 69 6f 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | rorException).{................. |
17520 | 69 66 20 28 24 65 78 63 65 70 74 69 6f 6e 20 69 6e 73 74 61 6e 63 65 6f 66 20 46 61 74 61 6c 54 | if.($exception.instanceof.FatalT |
17540 | 68 72 6f 77 61 62 6c 65 45 72 72 6f 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | hrowableError).{................ |
17560 | 20 20 20 20 20 24 65 72 72 6f 72 20 3d 20 61 72 72 61 79 28 0a 20 20 20 20 20 20 20 20 20 20 20 | .....$error.=.array(............ |
17580 | 20 20 20 20 20 20 20 20 20 20 20 20 20 27 74 79 70 65 27 20 3d 3e 20 24 74 79 70 65 2c 0a 20 20 | .............'type'.=>.$type,... |
175a0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 27 6d 65 73 73 61 67 65 27 20 | ......................'message'. |
175c0 | 3d 3e 20 24 6d 65 73 73 61 67 65 20 3d 20 24 65 78 63 65 70 74 69 6f 6e 2d 3e 67 65 74 4d 65 73 | =>.$message.=.$exception->getMes |
175e0 | 73 61 67 65 28 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | sage(),......................... |
17600 | 27 66 69 6c 65 27 20 3d 3e 20 24 65 5b 27 66 69 6c 65 27 5d 2c 0a 20 20 20 20 20 20 20 20 20 20 | 'file'.=>.$e['file'],........... |
17620 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 27 6c 69 6e 65 27 20 3d 3e 20 24 65 5b 27 6c 69 6e 65 | ..............'line'.=>.$e['line |
17640 | 27 5d 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 29 3b 0a 20 20 20 20 20 | '],.....................);...... |
17660 | 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ...........}.else.{............. |
17680 | 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 20 3d 20 27 46 61 74 61 6c 20 27 2e 24 65 78 63 | ........$message.=.'Fatal.'.$exc |
176a0 | 65 70 74 69 6f 6e 2d 3e 67 65 74 4d 65 73 73 61 67 65 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 | eption->getMessage();........... |
176c0 | 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 24 65 | ......}.............}.elseif.($e |
176e0 | 78 63 65 70 74 69 6f 6e 20 69 6e 73 74 61 6e 63 65 6f 66 20 5c 45 72 72 6f 72 45 78 63 65 70 74 | xception.instanceof.\ErrorExcept |
17700 | 69 6f 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 20 | ion).{.................$message. |
17720 | 3d 20 27 55 6e 63 61 75 67 68 74 20 27 2e 24 65 78 63 65 70 74 69 6f 6e 2d 3e 67 65 74 4d 65 73 | =.'Uncaught.'.$exception->getMes |
17740 | 73 61 67 65 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 65 78 63 | sage();.................if.($exc |
17760 | 65 70 74 69 6f 6e 20 69 6e 73 74 61 6e 63 65 6f 66 20 43 6f 6e 74 65 78 74 45 72 72 6f 72 45 78 | eption.instanceof.ContextErrorEx |
17780 | 63 65 70 74 69 6f 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 | ception).{.....................$ |
177a0 | 65 5b 27 63 6f 6e 74 65 78 74 27 5d 20 3d 20 24 65 78 63 65 70 74 69 6f 6e 2d 3e 67 65 74 43 6f | e['context'].=.$exception->getCo |
177c0 | 6e 74 65 78 74 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 | ntext();.................}...... |
177e0 | 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | .......}.else.{................. |
17800 | 24 6d 65 73 73 61 67 65 20 3d 20 27 55 6e 63 61 75 67 68 74 20 45 78 63 65 70 74 69 6f 6e 3a 20 | $message.=.'Uncaught.Exception:. |
17820 | 27 2e 24 65 78 63 65 70 74 69 6f 6e 2d 3e 67 65 74 4d 65 73 73 61 67 65 28 29 3b 0a 20 20 20 20 | '.$exception->getMessage();..... |
17840 | 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 | ........}.........}.........if.( |
17860 | 24 74 68 69 73 2d 3e 6c 6f 67 67 65 64 45 72 72 6f 72 73 20 26 20 24 74 79 70 65 29 20 7b 0a 20 | $this->loggedErrors.&.$type).{.. |
17880 | 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6c 6f 67 67 65 72 73 5b 24 74 79 70 65 5d | ...........$this->loggers[$type] |
178a0 | 5b 30 5d 2d 3e 6c 6f 67 28 24 74 68 69 73 2d 3e 6c 6f 67 67 65 72 73 5b 24 74 79 70 65 5d 5b 31 | [0]->log($this->loggers[$type][1 |
178c0 | 5d 2c 20 24 6d 65 73 73 61 67 65 2c 20 24 65 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 | ],.$message,.$e);.........}..... |
178e0 | 20 20 20 20 69 66 20 28 24 65 78 63 65 70 74 69 6f 6e 20 69 6e 73 74 61 6e 63 65 6f 66 20 46 61 | ....if.($exception.instanceof.Fa |
17900 | 74 61 6c 45 72 72 6f 72 45 78 63 65 70 74 69 6f 6e 20 26 26 20 21 24 65 78 63 65 70 74 69 6f 6e | talErrorException.&&.!$exception |
17920 | 20 69 6e 73 74 61 6e 63 65 6f 66 20 4f 75 74 4f 66 4d 65 6d 6f 72 79 45 78 63 65 70 74 69 6f 6e | .instanceof.OutOfMemoryException |
17940 | 20 26 26 20 24 65 72 72 6f 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 | .&&.$error).{.............foreac |
17960 | 68 20 28 24 74 68 69 73 2d 3e 67 65 74 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 73 28 | h.($this->getFatalErrorHandlers( |
17980 | 29 20 61 73 20 24 68 61 6e 64 6c 65 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ).as.$handler).{................ |
179a0 | 20 69 66 20 28 24 65 20 3d 20 24 68 61 6e 64 6c 65 72 2d 3e 68 61 6e 64 6c 65 45 72 72 6f 72 28 | .if.($e.=.$handler->handleError( |
179c0 | 24 65 72 72 6f 72 2c 20 24 65 78 63 65 70 74 69 6f 6e 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | $error,.$exception)).{.......... |
179e0 | 20 20 20 20 20 20 20 20 20 20 20 24 65 78 63 65 70 74 69 6f 6e 20 3d 20 24 65 3b 0a 20 20 20 20 | ...........$exception.=.$e;..... |
17a00 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 62 72 65 61 6b 3b 0a 20 20 20 20 20 20 20 20 20 | ................break;.......... |
17a20 | 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d | .......}.............}.........} |
17a40 | 0a 20 20 20 20 20 20 20 20 69 66 20 28 65 6d 70 74 79 28 24 74 68 69 73 2d 3e 65 78 63 65 70 74 | .........if.(empty($this->except |
17a60 | 69 6f 6e 48 61 6e 64 6c 65 72 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 | ionHandler)).{.............throw |
17a80 | 20 24 65 78 63 65 70 74 69 6f 6e 3b 20 2f 2f 20 47 69 76 65 20 62 61 63 6b 20 24 65 78 63 65 70 | .$exception;.//.Give.back.$excep |
17aa0 | 74 69 6f 6e 20 74 6f 20 74 68 65 20 6e 61 74 69 76 65 20 68 61 6e 64 6c 65 72 0a 20 20 20 20 20 | tion.to.the.native.handler...... |
17ac0 | 20 20 20 7d 0a 20 20 20 20 20 20 20 20 74 72 79 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 63 | ...}.........try.{.............c |
17ae0 | 61 6c 6c 5f 75 73 65 72 5f 66 75 6e 63 28 24 74 68 69 73 2d 3e 65 78 63 65 70 74 69 6f 6e 48 61 | all_user_func($this->exceptionHa |
17b00 | 6e 64 6c 65 72 2c 20 24 65 78 63 65 70 74 69 6f 6e 29 3b 0a 20 20 20 20 20 20 20 20 7d 20 63 61 | ndler,.$exception);.........}.ca |
17b20 | 74 63 68 20 28 5c 45 78 63 65 70 74 69 6f 6e 20 24 68 61 6e 64 6c 65 72 45 78 63 65 70 74 69 6f | tch.(\Exception.$handlerExceptio |
17b40 | 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 7d 20 63 61 74 63 68 20 28 5c 54 68 72 6f 77 61 62 6c 65 | n).{.........}.catch.(\Throwable |
17b60 | 20 24 68 61 6e 64 6c 65 72 45 78 63 65 70 74 69 6f 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 7d 0a | .$handlerException).{.........}. |
17b80 | 20 20 20 20 20 20 20 20 69 66 20 28 69 73 73 65 74 28 24 68 61 6e 64 6c 65 72 45 78 63 65 70 74 | ........if.(isset($handlerExcept |
17ba0 | 69 6f 6e 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 65 78 63 65 70 | ion)).{.............$this->excep |
17bc0 | 74 69 6f 6e 48 61 6e 64 6c 65 72 20 3d 20 6e 75 6c 6c 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | tionHandler.=.null;............. |
17be0 | 24 74 68 69 73 2d 3e 68 61 6e 64 6c 65 45 78 63 65 70 74 69 6f 6e 28 24 68 61 6e 64 6c 65 72 45 | $this->handleException($handlerE |
17c00 | 78 63 65 70 74 69 6f 6e 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 | xception);.........}.....}...... |
17c20 | 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 68 75 74 64 6f 77 6e 20 72 65 67 69 73 74 65 72 65 64 20 66 | /**......*.Shutdown.registered.f |
17c40 | 75 6e 63 74 69 6f 6e 20 66 6f 72 20 68 61 6e 64 6c 69 6e 67 20 50 48 50 20 66 61 74 61 6c 20 65 | unction.for.handling.PHP.fatal.e |
17c60 | 72 72 6f 72 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 | rrors.......*......*.@param.arra |
17c80 | 79 20 24 65 72 72 6f 72 20 41 6e 20 61 72 72 61 79 20 61 73 20 72 65 74 75 72 6e 65 64 20 62 79 | y.$error.An.array.as.returned.by |
17ca0 | 20 65 72 72 6f 72 5f 67 65 74 5f 6c 61 73 74 28 29 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 | .error_get_last()......*......*. |
17cc0 | 40 69 6e 74 65 72 6e 61 6c 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 | @internal......*/.....public.sta |
17ce0 | 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 68 61 6e 64 6c 65 46 61 74 61 6c 45 72 72 6f 72 28 61 72 | tic.function.handleFatalError(ar |
17d00 | 72 61 79 20 24 65 72 72 6f 72 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 | ray.$error.=.null).....{........ |
17d20 | 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 73 65 6c 66 3a 3a 24 72 65 73 65 72 76 65 64 4d 65 6d | .if.(null.===.self::$reservedMem |
17d40 | 6f 72 79 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 3b 0a 20 20 20 20 20 | ory).{.............return;...... |
17d60 | 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 73 65 6c 66 3a 3a 24 72 65 73 65 72 76 65 64 4d 65 6d | ...}..........self::$reservedMem |
17d80 | 6f 72 79 20 3d 20 6e 75 6c 6c 3b 0a 0a 20 20 20 20 20 20 20 20 24 68 61 6e 64 6c 65 72 20 3d 20 | ory.=.null;..........$handler.=. |
17da0 | 73 65 74 5f 65 72 72 6f 72 5f 68 61 6e 64 6c 65 72 28 27 76 61 72 5f 64 75 6d 70 27 29 3b 0a 20 | set_error_handler('var_dump');.. |
17dc0 | 20 20 20 20 20 20 20 24 68 61 6e 64 6c 65 72 20 3d 20 69 73 5f 61 72 72 61 79 28 24 68 61 6e 64 | .......$handler.=.is_array($hand |
17de0 | 6c 65 72 29 20 3f 20 24 68 61 6e 64 6c 65 72 5b 30 5d 20 3a 20 6e 75 6c 6c 3b 0a 20 20 20 20 20 | ler).?.$handler[0].:.null;...... |
17e00 | 20 20 20 72 65 73 74 6f 72 65 5f 65 72 72 6f 72 5f 68 61 6e 64 6c 65 72 28 29 3b 0a 0a 20 20 20 | ...restore_error_handler();..... |
17e20 | 20 20 20 20 20 69 66 20 28 21 24 68 61 6e 64 6c 65 72 20 69 6e 73 74 61 6e 63 65 6f 66 20 73 65 | .....if.(!$handler.instanceof.se |
17e40 | 6c 66 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 3b 0a 20 20 20 20 20 20 | lf).{.............return;....... |
17e60 | 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 65 72 72 6f 72 | ..}..........if.(null.===.$error |
17e80 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 65 72 72 6f 72 20 3d 20 65 72 72 6f 72 5f 67 | ).{.............$error.=.error_g |
17ea0 | 65 74 5f 6c 61 73 74 28 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 74 72 | et_last();.........}..........tr |
17ec0 | 79 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 77 68 69 6c 65 20 28 73 65 6c 66 3a 3a 24 73 74 | y.{.............while.(self::$st |
17ee0 | 61 63 6b 65 64 45 72 72 6f 72 4c 65 76 65 6c 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ackedErrorLevels).{............. |
17f00 | 20 20 20 20 73 74 61 74 69 63 3a 3a 75 6e 73 74 61 63 6b 45 72 72 6f 72 73 28 29 3b 0a 20 20 20 | ....static::unstackErrors();.... |
17f20 | 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 20 63 61 74 63 68 20 28 5c 45 78 63 | .........}.........}.catch.(\Exc |
17f40 | 65 70 74 69 6f 6e 20 24 65 78 63 65 70 74 69 6f 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | eption.$exception).{............ |
17f60 | 20 2f 2f 20 48 61 6e 64 6c 65 64 20 62 65 6c 6f 77 0a 20 20 20 20 20 20 20 20 7d 20 63 61 74 63 | .//.Handled.below.........}.catc |
17f80 | 68 20 28 5c 54 68 72 6f 77 61 62 6c 65 20 24 65 78 63 65 70 74 69 6f 6e 29 20 7b 0a 20 20 20 20 | h.(\Throwable.$exception).{..... |
17fa0 | 20 20 20 20 20 20 20 20 2f 2f 20 48 61 6e 64 6c 65 64 20 62 65 6c 6f 77 0a 20 20 20 20 20 20 20 | ........//.Handled.below........ |
17fc0 | 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 65 72 72 6f 72 20 26 26 20 24 65 72 72 6f 72 | .}..........if.($error.&&.$error |
17fe0 | 5b 27 74 79 70 65 27 5d 20 26 3d 20 45 5f 50 41 52 53 45 20 7c 20 45 5f 45 52 52 4f 52 20 7c 20 | ['type'].&=.E_PARSE.|.E_ERROR.|. |
18000 | 45 5f 43 4f 52 45 5f 45 52 52 4f 52 20 7c 20 45 5f 43 4f 4d 50 49 4c 45 5f 45 52 52 4f 52 29 20 | E_CORE_ERROR.|.E_COMPILE_ERROR). |
18020 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 4c 65 74 27 73 20 6e 6f 74 20 74 68 72 6f 77 | {.............//.Let's.not.throw |
18040 | 20 61 6e 79 6d 6f 72 65 20 62 75 74 20 6b 65 65 70 20 6c 6f 67 67 69 6e 67 0a 20 20 20 20 20 20 | .anymore.but.keep.logging....... |
18060 | 20 20 20 20 20 20 24 68 61 6e 64 6c 65 72 2d 3e 74 68 72 6f 77 41 74 28 30 2c 20 74 72 75 65 29 | ......$handler->throwAt(0,.true) |
18080 | 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 72 61 63 65 20 3d 20 69 73 73 65 74 28 24 65 72 | ;.............$trace.=.isset($er |
180a0 | 72 6f 72 5b 27 62 61 63 6b 74 72 61 63 65 27 5d 29 20 3f 20 24 65 72 72 6f 72 5b 27 62 61 63 6b | ror['backtrace']).?.$error['back |
180c0 | 74 72 61 63 65 27 5d 20 3a 20 6e 75 6c 6c 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 | trace'].:.null;..............if. |
180e0 | 28 30 20 3d 3d 3d 20 73 74 72 70 6f 73 28 24 65 72 72 6f 72 5b 27 6d 65 73 73 61 67 65 27 5d 2c | (0.===.strpos($error['message'], |
18100 | 20 27 41 6c 6c 6f 77 65 64 20 6d 65 6d 6f 72 79 27 29 20 7c 7c 20 30 20 3d 3d 3d 20 73 74 72 70 | .'Allowed.memory').||.0.===.strp |
18120 | 6f 73 28 24 65 72 72 6f 72 5b 27 6d 65 73 73 61 67 65 27 5d 2c 20 27 4f 75 74 20 6f 66 20 6d 65 | os($error['message'],.'Out.of.me |
18140 | 6d 6f 72 79 27 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 65 78 63 65 70 | mory')).{.................$excep |
18160 | 74 69 6f 6e 20 3d 20 6e 65 77 20 4f 75 74 4f 66 4d 65 6d 6f 72 79 45 78 63 65 70 74 69 6f 6e 28 | tion.=.new.OutOfMemoryException( |
18180 | 24 68 61 6e 64 6c 65 72 2d 3e 6c 65 76 65 6c 73 5b 24 65 72 72 6f 72 5b 27 74 79 70 65 27 5d 5d | $handler->levels[$error['type']] |
181a0 | 2e 27 3a 20 27 2e 24 65 72 72 6f 72 5b 27 6d 65 73 73 61 67 65 27 5d 2c 20 30 2c 20 24 65 72 72 | .':.'.$error['message'],.0,.$err |
181c0 | 6f 72 5b 27 74 79 70 65 27 5d 2c 20 24 65 72 72 6f 72 5b 27 66 69 6c 65 27 5d 2c 20 24 65 72 72 | or['type'],.$error['file'],.$err |
181e0 | 6f 72 5b 27 6c 69 6e 65 27 5d 2c 20 32 2c 20 66 61 6c 73 65 2c 20 24 74 72 61 63 65 29 3b 0a 20 | or['line'],.2,.false,.$trace);.. |
18200 | 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ...........}.else.{............. |
18220 | 20 20 20 20 24 65 78 63 65 70 74 69 6f 6e 20 3d 20 6e 65 77 20 46 61 74 61 6c 45 72 72 6f 72 45 | ....$exception.=.new.FatalErrorE |
18240 | 78 63 65 70 74 69 6f 6e 28 24 68 61 6e 64 6c 65 72 2d 3e 6c 65 76 65 6c 73 5b 24 65 72 72 6f 72 | xception($handler->levels[$error |
18260 | 5b 27 74 79 70 65 27 5d 5d 2e 27 3a 20 27 2e 24 65 72 72 6f 72 5b 27 6d 65 73 73 61 67 65 27 5d | ['type']].':.'.$error['message'] |
18280 | 2c 20 30 2c 20 24 65 72 72 6f 72 5b 27 74 79 70 65 27 5d 2c 20 24 65 72 72 6f 72 5b 27 66 69 6c | ,.0,.$error['type'],.$error['fil |
182a0 | 65 27 5d 2c 20 24 65 72 72 6f 72 5b 27 6c 69 6e 65 27 5d 2c 20 32 2c 20 74 72 75 65 2c 20 24 74 | e'],.$error['line'],.2,.true,.$t |
182c0 | 72 61 63 65 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 20 65 | race);.............}.........}.e |
182e0 | 6c 73 65 69 66 20 28 21 69 73 73 65 74 28 24 65 78 63 65 70 74 69 6f 6e 29 29 20 7b 0a 20 20 20 | lseif.(!isset($exception)).{.... |
18300 | 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 | .........return;.........}...... |
18320 | 20 20 20 20 74 72 79 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 68 61 6e 64 6c 65 72 2d 3e | ....try.{.............$handler-> |
18340 | 68 61 6e 64 6c 65 45 78 63 65 70 74 69 6f 6e 28 24 65 78 63 65 70 74 69 6f 6e 2c 20 24 65 72 72 | handleException($exception,.$err |
18360 | 6f 72 29 3b 0a 20 20 20 20 20 20 20 20 7d 20 63 61 74 63 68 20 28 46 61 74 61 6c 45 72 72 6f 72 | or);.........}.catch.(FatalError |
18380 | 45 78 63 65 70 74 69 6f 6e 20 24 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 49 | Exception.$e).{.............//.I |
183a0 | 67 6e 6f 72 65 20 74 68 69 73 20 72 65 2d 74 68 72 6f 77 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 | gnore.this.re-throw.........}... |
183c0 | 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 43 6f 6e 66 69 67 75 72 65 73 20 74 | ..}....../**......*.Configures.t |
183e0 | 68 65 20 65 72 72 6f 72 20 68 61 6e 64 6c 65 72 20 66 6f 72 20 64 65 6c 61 79 65 64 20 68 61 6e | he.error.handler.for.delayed.han |
18400 | 64 6c 69 6e 67 2e 0a 20 20 20 20 20 2a 20 45 6e 73 75 72 65 73 20 61 6c 73 6f 20 74 68 61 74 20 | dling.......*.Ensures.also.that. |
18420 | 6e 6f 6e 2d 63 61 74 63 68 61 62 6c 65 20 66 61 74 61 6c 20 65 72 72 6f 72 73 20 61 72 65 20 6e | non-catchable.fatal.errors.are.n |
18440 | 65 76 65 72 20 73 69 6c 65 6e 63 65 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 41 73 20 | ever.silenced.......*......*.As. |
18460 | 73 68 6f 77 6e 20 62 79 20 68 74 74 70 3a 2f 2f 62 75 67 73 2e 70 68 70 2e 6e 65 74 2f 34 32 30 | shown.by.http://bugs.php.net/420 |
18480 | 39 38 20 61 6e 64 20 68 74 74 70 3a 2f 2f 62 75 67 73 2e 70 68 70 2e 6e 65 74 2f 36 30 37 32 34 | 98.and.http://bugs.php.net/60724 |
184a0 | 0a 20 20 20 20 20 2a 20 50 48 50 20 68 61 73 20 61 20 63 6f 6d 70 69 6c 65 20 73 74 61 67 65 20 | ......*.PHP.has.a.compile.stage. |
184c0 | 77 68 65 72 65 20 69 74 20 62 65 68 61 76 65 73 20 75 6e 75 73 75 61 6c 6c 79 2e 20 54 6f 20 77 | where.it.behaves.unusually..To.w |
184e0 | 6f 72 6b 61 72 6f 75 6e 64 20 69 74 2c 0a 20 20 20 20 20 2a 20 77 65 20 70 6c 75 67 20 61 6e 20 | orkaround.it,......*.we.plug.an. |
18500 | 65 72 72 6f 72 20 68 61 6e 64 6c 65 72 20 74 68 61 74 20 6f 6e 6c 79 20 73 74 61 63 6b 73 20 65 | error.handler.that.only.stacks.e |
18520 | 72 72 6f 72 73 20 66 6f 72 20 6c 61 74 65 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 54 | rrors.for.later.......*......*.T |
18540 | 68 65 20 6d 6f 73 74 20 69 6d 70 6f 72 74 61 6e 74 20 66 65 61 74 75 72 65 20 6f 66 20 74 68 69 | he.most.important.feature.of.thi |
18560 | 73 20 69 73 20 74 6f 20 70 72 65 76 65 6e 74 0a 20 20 20 20 20 2a 20 61 75 74 6f 6c 6f 61 64 69 | s.is.to.prevent......*.autoloadi |
18580 | 6e 67 20 75 6e 74 69 6c 20 75 6e 73 74 61 63 6b 45 72 72 6f 72 73 28 29 20 69 73 20 63 61 6c 6c | ng.until.unstackErrors().is.call |
185a0 | 65 64 2e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 | ed.......*/.....public.static.fu |
185c0 | 6e 63 74 69 6f 6e 20 73 74 61 63 6b 45 72 72 6f 72 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 | nction.stackErrors().....{...... |
185e0 | 20 20 20 73 65 6c 66 3a 3a 24 73 74 61 63 6b 65 64 45 72 72 6f 72 4c 65 76 65 6c 73 5b 5d 20 3d | ...self::$stackedErrorLevels[].= |
18600 | 20 65 72 72 6f 72 5f 72 65 70 6f 72 74 69 6e 67 28 65 72 72 6f 72 5f 72 65 70 6f 72 74 69 6e 67 | .error_reporting(error_reporting |
18620 | 28 29 20 7c 20 45 5f 50 41 52 53 45 20 7c 20 45 5f 45 52 52 4f 52 20 7c 20 45 5f 43 4f 52 45 5f | ().|.E_PARSE.|.E_ERROR.|.E_CORE_ |
18640 | 45 52 52 4f 52 20 7c 20 45 5f 43 4f 4d 50 49 4c 45 5f 45 52 52 4f 52 29 3b 0a 20 20 20 20 7d 0a | ERROR.|.E_COMPILE_ERROR);.....}. |
18660 | 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 55 6e 73 74 61 63 6b 73 20 73 74 61 63 6b 65 64 | ...../**......*.Unstacks.stacked |
18680 | 20 65 72 72 6f 72 73 20 61 6e 64 20 66 6f 72 77 61 72 64 73 20 74 6f 20 74 68 65 20 6c 6f 67 67 | .errors.and.forwards.to.the.logg |
186a0 | 65 72 2e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 | er.......*/.....public.static.fu |
186c0 | 6e 63 74 69 6f 6e 20 75 6e 73 74 61 63 6b 45 72 72 6f 72 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 | nction.unstackErrors().....{.... |
186e0 | 20 20 20 20 20 24 6c 65 76 65 6c 20 3d 20 61 72 72 61 79 5f 70 6f 70 28 73 65 6c 66 3a 3a 24 73 | .....$level.=.array_pop(self::$s |
18700 | 74 61 63 6b 65 64 45 72 72 6f 72 4c 65 76 65 6c 73 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 | tackedErrorLevels);..........if. |
18720 | 28 6e 75 6c 6c 20 21 3d 3d 20 24 6c 65 76 65 6c 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | (null.!==.$level).{............. |
18740 | 24 65 20 3d 20 65 72 72 6f 72 5f 72 65 70 6f 72 74 69 6e 67 28 24 6c 65 76 65 6c 29 3b 0a 20 20 | $e.=.error_reporting($level);... |
18760 | 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 65 20 21 3d 3d 20 28 24 6c 65 76 65 6c 20 7c 20 45 | ..........if.($e.!==.($level.|.E |
18780 | 5f 50 41 52 53 45 20 7c 20 45 5f 45 52 52 4f 52 20 7c 20 45 5f 43 4f 52 45 5f 45 52 52 4f 52 20 | _PARSE.|.E_ERROR.|.E_CORE_ERROR. |
187a0 | 7c 20 45 5f 43 4f 4d 50 49 4c 45 5f 45 52 52 4f 52 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | |.E_COMPILE_ERROR)).{........... |
187c0 | 20 20 20 20 20 20 2f 2f 20 49 66 20 74 68 65 20 75 73 65 72 20 63 68 61 6e 67 65 64 20 74 68 65 | ......//.If.the.user.changed.the |
187e0 | 20 65 72 72 6f 72 20 6c 65 76 65 6c 2c 20 64 6f 20 6e 6f 74 20 6f 76 65 72 77 72 69 74 65 20 69 | .error.level,.do.not.overwrite.i |
18800 | 74 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 65 72 72 6f 72 5f 72 65 70 6f 72 74 69 6e | t.................error_reportin |
18820 | 67 28 24 65 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a | g($e);.............}.........}.. |
18840 | 20 20 20 20 20 20 20 20 69 66 20 28 65 6d 70 74 79 28 73 65 6c 66 3a 3a 24 73 74 61 63 6b 65 64 | ........if.(empty(self::$stacked |
18860 | 45 72 72 6f 72 4c 65 76 65 6c 73 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 65 72 72 | ErrorLevels)).{.............$err |
18880 | 6f 72 73 20 3d 20 73 65 6c 66 3a 3a 24 73 74 61 63 6b 65 64 45 72 72 6f 72 73 3b 0a 20 20 20 20 | ors.=.self::$stackedErrors;..... |
188a0 | 20 20 20 20 20 20 20 20 73 65 6c 66 3a 3a 24 73 74 61 63 6b 65 64 45 72 72 6f 72 73 20 3d 20 61 | ........self::$stackedErrors.=.a |
188c0 | 72 72 61 79 28 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 65 | rray();..............foreach.($e |
188e0 | 72 72 6f 72 73 20 61 73 20 24 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 | rrors.as.$e).{.................$ |
18900 | 65 5b 30 5d 2d 3e 6c 6f 67 28 24 65 5b 31 5d 2c 20 24 65 5b 32 5d 2c 20 24 65 5b 33 5d 29 3b 0a | e[0]->log($e[1],.$e[2],.$e[3]);. |
18920 | 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 | ............}.........}.....}... |
18940 | 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 66 61 74 61 6c 20 65 72 72 | .../**......*.Gets.the.fatal.err |
18960 | 6f 72 20 68 61 6e 64 6c 65 72 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 4f 76 65 72 72 | or.handlers.......*......*.Overr |
18980 | 69 64 65 20 74 68 69 73 20 6d 65 74 68 6f 64 20 69 66 20 79 6f 75 20 77 61 6e 74 20 74 6f 20 64 | ide.this.method.if.you.want.to.d |
189a0 | 65 66 69 6e 65 20 6d 6f 72 65 20 66 61 74 61 6c 20 65 72 72 6f 72 20 68 61 6e 64 6c 65 72 73 2e | efine.more.fatal.error.handlers. |
189c0 | 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 46 61 74 61 6c 45 72 72 6f | ......*......*.@return.FatalErro |
189e0 | 72 48 61 6e 64 6c 65 72 49 6e 74 65 72 66 61 63 65 5b 5d 20 41 6e 20 61 72 72 61 79 20 6f 66 20 | rHandlerInterface[].An.array.of. |
18a00 | 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 49 6e 74 65 72 66 61 63 65 0a 20 20 20 20 20 | FatalErrorHandlerInterface...... |
18a20 | 2a 2f 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 46 61 74 | */.....protected.function.getFat |
18a40 | 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | alErrorHandlers().....{......... |
18a60 | 72 65 74 75 72 6e 20 61 72 72 61 79 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 6e 65 77 20 55 6e | return.array(.............new.Un |
18a80 | 64 65 66 69 6e 65 64 46 75 6e 63 74 69 6f 6e 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 | definedFunctionFatalErrorHandler |
18aa0 | 28 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 6e 65 77 20 55 6e 64 65 66 69 6e 65 64 4d 65 74 | (),.............new.UndefinedMet |
18ac0 | 68 6f 64 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 28 29 2c 0a 20 20 20 20 20 20 20 20 | hodFatalErrorHandler(),......... |
18ae0 | 20 20 20 20 6e 65 77 20 43 6c 61 73 73 4e 6f 74 46 6f 75 6e 64 46 61 74 61 6c 45 72 72 6f 72 48 | ....new.ClassNotFoundFatalErrorH |
18b00 | 61 6e 64 6c 65 72 28 29 2c 0a 20 20 20 20 20 20 20 20 29 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 | andler(),.........);.....}.}.<?p |
18b20 | 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 | hp../*..*.This.file.is.part.of.t |
18b40 | 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 | he.Symfony.package...*..*.(c).Fa |
18b60 | 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 | bien.Potencier.<fabien@symfony.c |
18b80 | 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 | om>..*..*.For.the.full.copyright |
18ba0 | 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 | .and.license.information,.please |
18bc0 | 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 | .view.the.LICENSE..*.file.that.w |
18be0 | 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 | as.distributed.with.this.source. |
18c00 | 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d | code...*/..namespace.Symfony\Com |
18c20 | 70 6f 6e 65 6e 74 5c 44 65 62 75 67 3b 0a 0a 2f 2a 2a 0a 20 2a 20 52 65 67 69 73 74 65 72 73 20 | ponent\Debug;../**..*.Registers. |
18c40 | 61 6c 6c 20 74 68 65 20 64 65 62 75 67 20 74 6f 6f 6c 73 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 | all.the.debug.tools...*..*.@auth |
18c60 | 6f 72 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 | or.Fabien.Potencier.<fabien@symf |
18c80 | 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 44 65 62 75 67 0a 7b 0a 20 20 20 20 70 | ony.com>..*/.class.Debug.{.....p |
18ca0 | 72 69 76 61 74 65 20 73 74 61 74 69 63 20 24 65 6e 61 62 6c 65 64 20 3d 20 66 61 6c 73 65 3b 0a | rivate.static.$enabled.=.false;. |
18cc0 | 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 45 6e 61 62 6c 65 73 20 74 68 65 20 64 65 62 75 | ...../**......*.Enables.the.debu |
18ce0 | 67 20 74 6f 6f 6c 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 54 68 69 73 20 6d 65 74 68 | g.tools.......*......*.This.meth |
18d00 | 6f 64 20 72 65 67 69 73 74 65 72 73 20 61 6e 20 65 72 72 6f 72 20 68 61 6e 64 6c 65 72 20 61 6e | od.registers.an.error.handler.an |
18d20 | 64 20 61 6e 20 65 78 63 65 70 74 69 6f 6e 20 68 61 6e 64 6c 65 72 2e 0a 20 20 20 20 20 2a 0a 20 | d.an.exception.handler.......*.. |
18d40 | 20 20 20 20 2a 20 49 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 43 6c 61 73 73 4c 6f 61 64 65 72 | ....*.If.the.Symfony.ClassLoader |
18d60 | 20 63 6f 6d 70 6f 6e 65 6e 74 20 69 73 20 61 76 61 69 6c 61 62 6c 65 2c 20 61 20 73 70 65 63 69 | .component.is.available,.a.speci |
18d80 | 61 6c 0a 20 20 20 20 20 2a 20 63 6c 61 73 73 20 6c 6f 61 64 65 72 20 69 73 20 61 6c 73 6f 20 72 | al......*.class.loader.is.also.r |
18da0 | 65 67 69 73 74 65 72 65 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 | egistered.......*......*.@param. |
18dc0 | 69 6e 74 20 20 24 65 72 72 6f 72 52 65 70 6f 72 74 69 6e 67 4c 65 76 65 6c 20 54 68 65 20 6c 65 | int..$errorReportingLevel.The.le |
18de0 | 76 65 6c 20 6f 66 20 65 72 72 6f 72 20 72 65 70 6f 72 74 69 6e 67 20 79 6f 75 20 77 61 6e 74 0a | vel.of.error.reporting.you.want. |
18e00 | 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 62 6f 6f 6c 20 24 64 69 73 70 6c 61 79 45 72 72 6f 72 | .....*.@param.bool.$displayError |
18e20 | 73 20 20 20 20 20 20 20 57 68 65 74 68 65 72 20 74 6f 20 64 69 73 70 6c 61 79 20 65 72 72 6f 72 | s.......Whether.to.display.error |
18e40 | 73 20 28 66 6f 72 20 64 65 76 65 6c 6f 70 6d 65 6e 74 29 20 6f 72 20 6a 75 73 74 20 6c 6f 67 20 | s.(for.development).or.just.log. |
18e60 | 74 68 65 6d 20 28 66 6f 72 20 70 72 6f 64 75 63 74 69 6f 6e 29 0a 20 20 20 20 20 2a 2f 0a 20 20 | them.(for.production)......*/... |
18e80 | 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 65 6e 61 62 6c 65 28 | ..public.static.function.enable( |
18ea0 | 24 65 72 72 6f 72 52 65 70 6f 72 74 69 6e 67 4c 65 76 65 6c 20 3d 20 45 5f 41 4c 4c 2c 20 24 64 | $errorReportingLevel.=.E_ALL,.$d |
18ec0 | 69 73 70 6c 61 79 45 72 72 6f 72 73 20 3d 20 74 72 75 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 | isplayErrors.=.true).....{...... |
18ee0 | 20 20 20 69 66 20 28 73 74 61 74 69 63 3a 3a 24 65 6e 61 62 6c 65 64 29 20 7b 0a 20 20 20 20 20 | ...if.(static::$enabled).{...... |
18f00 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 | .......return;.........}........ |
18f20 | 20 20 73 74 61 74 69 63 3a 3a 24 65 6e 61 62 6c 65 64 20 3d 20 74 72 75 65 3b 0a 0a 20 20 20 20 | ..static::$enabled.=.true;...... |
18f40 | 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 21 3d 3d 20 24 65 72 72 6f 72 52 65 70 6f 72 74 69 6e 67 | ....if.(null.!==.$errorReporting |
18f60 | 4c 65 76 65 6c 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 65 72 72 6f 72 5f 72 65 70 6f 72 | Level).{.............error_repor |
18f80 | 74 69 6e 67 28 24 65 72 72 6f 72 52 65 70 6f 72 74 69 6e 67 4c 65 76 65 6c 29 3b 0a 20 20 20 20 | ting($errorReportingLevel);..... |
18fa0 | 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 65 72 72 6f 72 5f 72 | ....}.else.{.............error_r |
18fc0 | 65 70 6f 72 74 69 6e 67 28 45 5f 41 4c 4c 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 | eporting(E_ALL);.........}...... |
18fe0 | 20 20 20 20 69 66 20 28 27 63 6c 69 27 20 21 3d 3d 20 50 48 50 5f 53 41 50 49 29 20 7b 0a 20 20 | ....if.('cli'.!==.PHP_SAPI).{... |
19000 | 20 20 20 20 20 20 20 20 20 20 69 6e 69 5f 73 65 74 28 27 64 69 73 70 6c 61 79 5f 65 72 72 6f 72 | ..........ini_set('display_error |
19020 | 73 27 2c 20 30 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 45 78 63 65 70 74 69 6f 6e 48 61 6e | s',.0);.............ExceptionHan |
19040 | 64 6c 65 72 3a 3a 72 65 67 69 73 74 65 72 28 29 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 | dler::register();.........}.else |
19060 | 69 66 20 28 24 64 69 73 70 6c 61 79 45 72 72 6f 72 73 20 26 26 20 28 21 69 6e 69 5f 67 65 74 28 | if.($displayErrors.&&.(!ini_get( |
19080 | 27 6c 6f 67 5f 65 72 72 6f 72 73 27 29 20 7c 7c 20 69 6e 69 5f 67 65 74 28 27 65 72 72 6f 72 5f | 'log_errors').||.ini_get('error_ |
190a0 | 6c 6f 67 27 29 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 43 4c 49 20 2d 20 64 | log'))).{.............//.CLI.-.d |
190c0 | 69 73 70 6c 61 79 20 65 72 72 6f 72 73 20 6f 6e 6c 79 20 69 66 20 74 68 65 79 27 72 65 20 6e 6f | isplay.errors.only.if.they're.no |
190e0 | 74 20 61 6c 72 65 61 64 79 20 6c 6f 67 67 65 64 20 74 6f 20 53 54 44 45 52 52 0a 20 20 20 20 20 | t.already.logged.to.STDERR...... |
19100 | 20 20 20 20 20 20 20 69 6e 69 5f 73 65 74 28 27 64 69 73 70 6c 61 79 5f 65 72 72 6f 72 73 27 2c | .......ini_set('display_errors', |
19120 | 20 31 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 64 69 73 70 | .1);.........}.........if.($disp |
19140 | 6c 61 79 45 72 72 6f 72 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 45 72 72 6f 72 48 61 | layErrors).{.............ErrorHa |
19160 | 6e 64 6c 65 72 3a 3a 72 65 67 69 73 74 65 72 28 6e 65 77 20 45 72 72 6f 72 48 61 6e 64 6c 65 72 | ndler::register(new.ErrorHandler |
19180 | 28 6e 65 77 20 42 75 66 66 65 72 69 6e 67 4c 6f 67 67 65 72 28 29 29 29 3b 0a 20 20 20 20 20 20 | (new.BufferingLogger()));....... |
191a0 | 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 45 72 72 6f 72 48 61 6e 64 | ..}.else.{.............ErrorHand |
191c0 | 6c 65 72 3a 3a 72 65 67 69 73 74 65 72 28 29 2d 3e 74 68 72 6f 77 41 74 28 30 2c 20 74 72 75 65 | ler::register()->throwAt(0,.true |
191e0 | 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 44 65 62 75 67 43 6c 61 73 73 | );.........}..........DebugClass |
19200 | 4c 6f 61 64 65 72 3a 3a 65 6e 61 62 6c 65 28 29 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a | Loader::enable();.....}.}.<?php. |
19220 | 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 | ./*..*.This.file.is.part.of.the. |
19240 | 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 | Symfony.package...*..*.(c).Fabie |
19260 | 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e | n.Potencier.<fabien@symfony.com> |
19280 | 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e | ..*..*.For.the.full.copyright.an |
192a0 | 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 | d.license.information,.please.vi |
192c0 | 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 | ew.the.LICENSE..*.file.that.was. |
192e0 | 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 | distributed.with.this.source.cod |
19300 | 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e | e...*/..namespace.Symfony\Compon |
19320 | 65 6e 74 5c 44 65 62 75 67 3b 0a 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e | ent\Debug;..use.Symfony\Componen |
19340 | 74 5c 44 65 62 75 67 5c 45 78 63 65 70 74 69 6f 6e 5c 46 6c 61 74 74 65 6e 45 78 63 65 70 74 69 | t\Debug\Exception\FlattenExcepti |
19360 | 6f 6e 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 44 65 62 75 67 5c | on;.use.Symfony\Component\Debug\ |
19380 | 45 78 63 65 70 74 69 6f 6e 5c 4f 75 74 4f 66 4d 65 6d 6f 72 79 45 78 63 65 70 74 69 6f 6e 3b 0a | Exception\OutOfMemoryException;. |
193a0 | 0a 2f 2a 2a 0a 20 2a 20 45 78 63 65 70 74 69 6f 6e 48 61 6e 64 6c 65 72 20 63 6f 6e 76 65 72 74 | ./**..*.ExceptionHandler.convert |
193c0 | 73 20 61 6e 20 65 78 63 65 70 74 69 6f 6e 20 74 6f 20 61 20 52 65 73 70 6f 6e 73 65 20 6f 62 6a | s.an.exception.to.a.Response.obj |
193e0 | 65 63 74 2e 0a 20 2a 0a 20 2a 20 49 74 20 69 73 20 6d 6f 73 74 6c 79 20 75 73 65 66 75 6c 20 69 | ect...*..*.It.is.mostly.useful.i |
19400 | 6e 20 64 65 62 75 67 20 6d 6f 64 65 20 74 6f 20 72 65 70 6c 61 63 65 20 74 68 65 20 64 65 66 61 | n.debug.mode.to.replace.the.defa |
19420 | 75 6c 74 20 50 48 50 2f 58 44 65 62 75 67 0a 20 2a 20 6f 75 74 70 75 74 20 77 69 74 68 20 73 6f | ult.PHP/XDebug..*.output.with.so |
19440 | 6d 65 74 68 69 6e 67 20 70 72 65 74 74 69 65 72 20 61 6e 64 20 6d 6f 72 65 20 75 73 65 66 75 6c | mething.prettier.and.more.useful |
19460 | 2e 0a 20 2a 0a 20 2a 20 41 73 20 74 68 69 73 20 63 6c 61 73 73 20 69 73 20 6d 61 69 6e 6c 79 20 | ...*..*.As.this.class.is.mainly. |
19480 | 75 73 65 64 20 64 75 72 69 6e 67 20 4b 65 72 6e 65 6c 20 62 6f 6f 74 2c 20 77 68 65 72 65 20 6e | used.during.Kernel.boot,.where.n |
194a0 | 6f 74 68 69 6e 67 20 69 73 20 79 65 74 0a 20 2a 20 61 76 61 69 6c 61 62 6c 65 2c 20 74 68 65 20 | othing.is.yet..*.available,.the. |
194c0 | 52 65 73 70 6f 6e 73 65 20 63 6f 6e 74 65 6e 74 20 69 73 20 61 6c 77 61 79 73 20 48 54 4d 4c 2e | Response.content.is.always.HTML. |
194e0 | 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 | ..*..*.@author.Fabien.Potencier. |
19500 | 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 20 40 61 75 74 68 6f 72 20 | <fabien@symfony.com>..*.@author. |
19520 | 4e 69 63 6f 6c 61 73 20 47 72 65 6b 61 73 20 3c 70 40 74 63 68 77 6f 72 6b 2e 63 6f 6d 3e 0a 20 | Nicolas.Grekas.<p@tchwork.com>.. |
19540 | 2a 2f 0a 63 6c 61 73 73 20 45 78 63 65 70 74 69 6f 6e 48 61 6e 64 6c 65 72 0a 7b 0a 20 20 20 20 | */.class.ExceptionHandler.{..... |
19560 | 70 72 69 76 61 74 65 20 24 64 65 62 75 67 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 63 68 61 | private.$debug;.....private.$cha |
19580 | 72 73 65 74 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 68 61 6e 64 6c 65 72 3b 0a 20 20 20 20 | rset;.....private.$handler;..... |
195a0 | 70 72 69 76 61 74 65 20 24 63 61 75 67 68 74 42 75 66 66 65 72 3b 0a 20 20 20 20 70 72 69 76 61 | private.$caughtBuffer;.....priva |
195c0 | 74 65 20 24 63 61 75 67 68 74 4c 65 6e 67 74 68 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 66 | te.$caughtLength;.....private.$f |
195e0 | 69 6c 65 4c 69 6e 6b 46 6f 72 6d 61 74 3b 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 | ileLinkFormat;......public.funct |
19600 | 69 6f 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 74 28 24 64 65 62 75 67 20 3d 20 74 72 75 65 2c 20 24 | ion.__construct($debug.=.true,.$ |
19620 | 63 68 61 72 73 65 74 20 3d 20 6e 75 6c 6c 2c 20 24 66 69 6c 65 4c 69 6e 6b 46 6f 72 6d 61 74 20 | charset.=.null,.$fileLinkFormat. |
19640 | 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 64 65 62 | =.null).....{.........$this->deb |
19660 | 75 67 20 3d 20 24 64 65 62 75 67 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 63 68 61 72 | ug.=.$debug;.........$this->char |
19680 | 73 65 74 20 3d 20 24 63 68 61 72 73 65 74 20 3f 3a 20 69 6e 69 5f 67 65 74 28 27 64 65 66 61 75 | set.=.$charset.?:.ini_get('defau |
196a0 | 6c 74 5f 63 68 61 72 73 65 74 27 29 20 3f 3a 20 27 55 54 46 2d 38 27 3b 0a 20 20 20 20 20 20 20 | lt_charset').?:.'UTF-8';........ |
196c0 | 20 24 74 68 69 73 2d 3e 66 69 6c 65 4c 69 6e 6b 46 6f 72 6d 61 74 20 3d 20 24 66 69 6c 65 4c 69 | .$this->fileLinkFormat.=.$fileLi |
196e0 | 6e 6b 46 6f 72 6d 61 74 20 3f 3a 20 69 6e 69 5f 67 65 74 28 27 78 64 65 62 75 67 2e 66 69 6c 65 | nkFormat.?:.ini_get('xdebug.file |
19700 | 5f 6c 69 6e 6b 5f 66 6f 72 6d 61 74 27 29 20 3f 3a 20 67 65 74 5f 63 66 67 5f 76 61 72 28 27 78 | _link_format').?:.get_cfg_var('x |
19720 | 64 65 62 75 67 2e 66 69 6c 65 5f 6c 69 6e 6b 5f 66 6f 72 6d 61 74 27 29 3b 0a 20 20 20 20 7d 0a | debug.file_link_format');.....}. |
19740 | 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 67 69 73 74 65 72 73 20 74 68 65 20 65 78 | ...../**......*.Registers.the.ex |
19760 | 63 65 70 74 69 6f 6e 20 68 61 6e 64 6c 65 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 | ception.handler.......*......*.@ |
19780 | 70 61 72 61 6d 20 62 6f 6f 6c 20 20 20 20 20 20 20 20 24 64 65 62 75 67 20 20 20 20 20 20 20 20 | param.bool........$debug........ |
197a0 | 20 20 45 6e 61 62 6c 65 2f 64 69 73 61 62 6c 65 20 64 65 62 75 67 20 6d 6f 64 65 2c 20 77 68 65 | ..Enable/disable.debug.mode,.whe |
197c0 | 72 65 20 74 68 65 20 73 74 61 63 6b 20 74 72 61 63 65 20 69 73 20 64 69 73 70 6c 61 79 65 64 0a | re.the.stack.trace.is.displayed. |
197e0 | 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 7c 6e 75 6c 6c 20 24 63 68 61 72 73 | .....*.@param.string|null.$chars |
19800 | 65 74 20 20 20 20 20 20 20 20 54 68 65 20 63 68 61 72 73 65 74 20 75 73 65 64 20 62 79 20 65 78 | et........The.charset.used.by.ex |
19820 | 63 65 70 74 69 6f 6e 20 6d 65 73 73 61 67 65 73 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 | ception.messages......*.@param.s |
19840 | 74 72 69 6e 67 7c 6e 75 6c 6c 20 24 66 69 6c 65 4c 69 6e 6b 46 6f 72 6d 61 74 20 54 68 65 20 49 | tring|null.$fileLinkFormat.The.I |
19860 | 44 45 20 6c 69 6e 6b 20 74 65 6d 70 6c 61 74 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 | DE.link.template......*......*.@ |
19880 | 72 65 74 75 72 6e 20 45 78 63 65 70 74 69 6f 6e 48 61 6e 64 6c 65 72 20 54 68 65 20 72 65 67 69 | return.ExceptionHandler.The.regi |
198a0 | 73 74 65 72 65 64 20 65 78 63 65 70 74 69 6f 6e 20 68 61 6e 64 6c 65 72 0a 20 20 20 20 20 2a 2f | stered.exception.handler......*/ |
198c0 | 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 72 65 67 69 | .....public.static.function.regi |
198e0 | 73 74 65 72 28 24 64 65 62 75 67 20 3d 20 74 72 75 65 2c 20 24 63 68 61 72 73 65 74 20 3d 20 6e | ster($debug.=.true,.$charset.=.n |
19900 | 75 6c 6c 2c 20 24 66 69 6c 65 4c 69 6e 6b 46 6f 72 6d 61 74 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 | ull,.$fileLinkFormat.=.null).... |
19920 | 20 7b 0a 20 20 20 20 20 20 20 20 24 68 61 6e 64 6c 65 72 20 3d 20 6e 65 77 20 73 74 61 74 69 63 | .{.........$handler.=.new.static |
19940 | 28 24 64 65 62 75 67 2c 20 24 63 68 61 72 73 65 74 2c 20 24 66 69 6c 65 4c 69 6e 6b 46 6f 72 6d | ($debug,.$charset,.$fileLinkForm |
19960 | 61 74 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 70 72 65 76 20 3d 20 73 65 74 5f 65 78 63 65 70 74 | at);..........$prev.=.set_except |
19980 | 69 6f 6e 5f 68 61 6e 64 6c 65 72 28 61 72 72 61 79 28 24 68 61 6e 64 6c 65 72 2c 20 27 68 61 6e | ion_handler(array($handler,.'han |
199a0 | 64 6c 65 27 29 29 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 69 73 5f 61 72 72 61 79 28 24 70 72 | dle'));.........if.(is_array($pr |
199c0 | 65 76 29 20 26 26 20 24 70 72 65 76 5b 30 5d 20 69 6e 73 74 61 6e 63 65 6f 66 20 45 72 72 6f 72 | ev).&&.$prev[0].instanceof.Error |
199e0 | 48 61 6e 64 6c 65 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 73 74 6f 72 65 5f 65 | Handler).{.............restore_e |
19a00 | 78 63 65 70 74 69 6f 6e 5f 68 61 6e 64 6c 65 72 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | xception_handler();............. |
19a20 | 24 70 72 65 76 5b 30 5d 2d 3e 73 65 74 45 78 63 65 70 74 69 6f 6e 48 61 6e 64 6c 65 72 28 61 72 | $prev[0]->setExceptionHandler(ar |
19a40 | 72 61 79 28 24 68 61 6e 64 6c 65 72 2c 20 27 68 61 6e 64 6c 65 27 29 29 3b 0a 20 20 20 20 20 20 | ray($handler,.'handle'));....... |
19a60 | 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 68 61 6e 64 6c 65 72 3b 0a 20 20 | ..}..........return.$handler;... |
19a80 | 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 61 20 75 73 65 72 20 | ..}....../**......*.Sets.a.user. |
19aa0 | 65 78 63 65 70 74 69 6f 6e 20 68 61 6e 64 6c 65 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a | exception.handler.......*......* |
19ac0 | 20 40 70 61 72 61 6d 20 63 61 6c 6c 61 62 6c 65 20 24 68 61 6e 64 6c 65 72 20 41 6e 20 68 61 6e | .@param.callable.$handler.An.han |
19ae0 | 64 6c 65 72 20 74 68 61 74 20 77 69 6c 6c 20 62 65 20 63 61 6c 6c 65 64 20 6f 6e 20 45 78 63 65 | dler.that.will.be.called.on.Exce |
19b00 | 70 74 69 6f 6e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 63 61 6c 6c | ption......*......*.@return.call |
19b20 | 61 62 6c 65 7c 6e 75 6c 6c 20 54 68 65 20 70 72 65 76 69 6f 75 73 20 65 78 63 65 70 74 69 6f 6e | able|null.The.previous.exception |
19b40 | 20 68 61 6e 64 6c 65 72 20 69 66 20 61 6e 79 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c | .handler.if.any......*/.....publ |
19b60 | 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 48 61 6e 64 6c 65 72 28 63 61 6c 6c 61 62 6c 65 20 | ic.function.setHandler(callable. |
19b80 | 24 68 61 6e 64 6c 65 72 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 | $handler.=.null).....{.........$ |
19ba0 | 6f 6c 64 20 3d 20 24 74 68 69 73 2d 3e 68 61 6e 64 6c 65 72 3b 0a 20 20 20 20 20 20 20 20 24 74 | old.=.$this->handler;.........$t |
19bc0 | 68 69 73 2d 3e 68 61 6e 64 6c 65 72 20 3d 20 24 68 61 6e 64 6c 65 72 3b 0a 0a 20 20 20 20 20 20 | his->handler.=.$handler;........ |
19be0 | 20 20 72 65 74 75 72 6e 20 24 6f 6c 64 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 | ..return.$old;.....}....../**... |
19c00 | 20 20 20 2a 20 53 65 74 73 20 74 68 65 20 66 6f 72 6d 61 74 20 66 6f 72 20 6c 69 6e 6b 73 20 74 | ...*.Sets.the.format.for.links.t |
19c20 | 6f 20 73 6f 75 72 63 65 20 66 69 6c 65 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 | o.source.files.......*......*.@p |
19c40 | 61 72 61 6d 20 73 74 72 69 6e 67 20 24 66 6f 72 6d 61 74 20 54 68 65 20 66 6f 72 6d 61 74 20 66 | aram.string.$format.The.format.f |
19c60 | 6f 72 20 6c 69 6e 6b 73 20 74 6f 20 73 6f 75 72 63 65 20 66 69 6c 65 73 0a 20 20 20 20 20 2a 0a | or.links.to.source.files......*. |
19c80 | 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 20 54 68 65 20 70 72 65 76 69 6f | .....*.@return.string.The.previo |
19ca0 | 75 73 20 66 69 6c 65 20 6c 69 6e 6b 20 66 6f 72 6d 61 74 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 | us.file.link.format......*/..... |
19cc0 | 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 46 69 6c 65 4c 69 6e 6b 46 6f 72 6d 61 | public.function.setFileLinkForma |
19ce0 | 74 28 24 66 6f 72 6d 61 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 6f 6c 64 20 3d 20 | t($format).....{.........$old.=. |
19d00 | 24 74 68 69 73 2d 3e 66 69 6c 65 4c 69 6e 6b 46 6f 72 6d 61 74 3b 0a 20 20 20 20 20 20 20 20 24 | $this->fileLinkFormat;.........$ |
19d20 | 74 68 69 73 2d 3e 66 69 6c 65 4c 69 6e 6b 46 6f 72 6d 61 74 20 3d 20 24 66 6f 72 6d 61 74 3b 0a | this->fileLinkFormat.=.$format;. |
19d40 | 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 6f 6c 64 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 | .........return.$old;.....}..... |
19d60 | 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 6e 64 73 20 61 20 72 65 73 70 6f 6e 73 65 20 66 6f 72 | ./**......*.Sends.a.response.for |
19d80 | 20 74 68 65 20 67 69 76 65 6e 20 45 78 63 65 70 74 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 | .the.given.Exception.......*.... |
19da0 | 20 20 2a 20 54 6f 20 62 65 20 61 73 20 66 61 69 6c 2d 73 61 66 65 20 61 73 20 70 6f 73 73 69 62 | ..*.To.be.as.fail-safe.as.possib |
19dc0 | 6c 65 2c 20 74 68 65 20 65 78 63 65 70 74 69 6f 6e 20 69 73 20 66 69 72 73 74 20 68 61 6e 64 6c | le,.the.exception.is.first.handl |
19de0 | 65 64 0a 20 20 20 20 20 2a 20 62 79 20 6f 75 72 20 73 69 6d 70 6c 65 20 65 78 63 65 70 74 69 6f | ed......*.by.our.simple.exceptio |
19e00 | 6e 20 68 61 6e 64 6c 65 72 2c 20 74 68 65 6e 20 62 79 20 74 68 65 20 75 73 65 72 20 65 78 63 65 | n.handler,.then.by.the.user.exce |
19e20 | 70 74 69 6f 6e 20 68 61 6e 64 6c 65 72 2e 0a 20 20 20 20 20 2a 20 54 68 65 20 6c 61 74 74 65 72 | ption.handler.......*.The.latter |
19e40 | 20 74 61 6b 65 73 20 70 72 65 63 65 64 65 6e 63 65 20 61 6e 64 20 61 6e 79 20 6f 75 74 70 75 74 | .takes.precedence.and.any.output |
19e60 | 20 66 72 6f 6d 20 74 68 65 20 66 6f 72 6d 65 72 20 69 73 20 63 61 6e 63 65 6c 6c 65 64 2c 0a 20 | .from.the.former.is.cancelled,.. |
19e80 | 20 20 20 20 2a 20 69 66 20 61 6e 64 20 6f 6e 6c 79 20 69 66 20 6e 6f 74 68 69 6e 67 20 62 61 64 | ....*.if.and.only.if.nothing.bad |
19ea0 | 20 68 61 70 70 65 6e 73 20 69 6e 20 74 68 69 73 20 68 61 6e 64 6c 69 6e 67 20 70 61 74 68 2e 0a | .happens.in.this.handling.path.. |
19ec0 | 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 68 61 6e 64 | .....*/.....public.function.hand |
19ee0 | 6c 65 28 5c 45 78 63 65 70 74 69 6f 6e 20 24 65 78 63 65 70 74 69 6f 6e 29 0a 20 20 20 20 7b 0a | le(\Exception.$exception).....{. |
19f00 | 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 74 68 69 73 2d 3e 68 61 6e 64 | ........if.(null.===.$this->hand |
19f20 | 6c 65 72 20 7c 7c 20 24 65 78 63 65 70 74 69 6f 6e 20 69 6e 73 74 61 6e 63 65 6f 66 20 4f 75 74 | ler.||.$exception.instanceof.Out |
19f40 | 4f 66 4d 65 6d 6f 72 79 45 78 63 65 70 74 69 6f 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | OfMemoryException).{............ |
19f60 | 20 24 74 68 69 73 2d 3e 73 65 6e 64 50 68 70 52 65 73 70 6f 6e 73 65 28 24 65 78 63 65 70 74 69 | .$this->sendPhpResponse($excepti |
19f80 | 6f 6e 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 3b 0a 20 20 20 20 20 20 | on);..............return;....... |
19fa0 | 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 63 61 75 67 68 74 4c 65 6e 67 74 68 20 3d 20 24 74 68 | ..}..........$caughtLength.=.$th |
19fc0 | 69 73 2d 3e 63 61 75 67 68 74 4c 65 6e 67 74 68 20 3d 20 30 3b 0a 0a 20 20 20 20 20 20 20 20 6f | is->caughtLength.=.0;..........o |
19fe0 | 62 5f 73 74 61 72 74 28 66 75 6e 63 74 69 6f 6e 20 28 24 62 75 66 66 65 72 29 20 7b 0a 20 20 20 | b_start(function.($buffer).{.... |
1a000 | 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 63 61 75 67 68 74 42 75 66 66 65 72 20 3d 20 24 | .........$this->caughtBuffer.=.$ |
1a020 | 62 75 66 66 65 72 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 27 27 3b 0a | buffer;..............return.'';. |
1a040 | 20 20 20 20 20 20 20 20 7d 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 65 6e 64 | ........});..........$this->send |
1a060 | 50 68 70 52 65 73 70 6f 6e 73 65 28 24 65 78 63 65 70 74 69 6f 6e 29 3b 0a 20 20 20 20 20 20 20 | PhpResponse($exception);........ |
1a080 | 20 77 68 69 6c 65 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 74 68 69 73 2d 3e 63 61 75 67 68 74 42 75 | .while.(null.===.$this->caughtBu |
1a0a0 | 66 66 65 72 20 26 26 20 6f 62 5f 65 6e 64 5f 66 6c 75 73 68 28 29 29 20 7b 0a 20 20 20 20 20 20 | ffer.&&.ob_end_flush()).{....... |
1a0c0 | 20 20 20 20 20 20 2f 2f 20 45 6d 70 74 79 20 6c 6f 6f 70 2c 20 65 76 65 72 79 74 68 69 6e 67 20 | ......//.Empty.loop,.everything. |
1a0e0 | 69 73 20 69 6e 20 74 68 65 20 63 6f 6e 64 69 74 69 6f 6e 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 | is.in.the.condition.........}... |
1a100 | 20 20 20 20 20 20 69 66 20 28 69 73 73 65 74 28 24 74 68 69 73 2d 3e 63 61 75 67 68 74 42 75 66 | ......if.(isset($this->caughtBuf |
1a120 | 66 65 72 5b 30 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 6f 62 5f 73 74 61 72 74 28 | fer[0])).{.............ob_start( |
1a140 | 66 75 6e 63 74 69 6f 6e 20 28 24 62 75 66 66 65 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | function.($buffer).{............ |
1a160 | 20 20 20 20 20 69 66 20 28 24 74 68 69 73 2d 3e 63 61 75 67 68 74 4c 65 6e 67 74 68 29 20 7b 0a | .....if.($this->caughtLength).{. |
1a180 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 75 73 65 20 73 75 62 73 74 | ....................//.use.subst |
1a1a0 | 72 5f 72 65 70 6c 61 63 65 28 29 20 69 6e 73 74 65 61 64 20 6f 66 20 73 75 62 73 74 72 28 29 20 | r_replace().instead.of.substr(). |
1a1c0 | 66 6f 72 20 6d 62 73 74 72 69 6e 67 20 6f 76 65 72 6c 6f 61 64 69 6e 67 20 72 65 73 69 73 74 61 | for.mbstring.overloading.resista |
1a1e0 | 6e 63 65 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6c 65 61 6e 42 75 | nce.....................$cleanBu |
1a200 | 66 66 65 72 20 3d 20 73 75 62 73 74 72 5f 72 65 70 6c 61 63 65 28 24 62 75 66 66 65 72 2c 20 27 | ffer.=.substr_replace($buffer,.' |
1a220 | 27 2c 20 30 2c 20 24 74 68 69 73 2d 3e 63 61 75 67 68 74 4c 65 6e 67 74 68 29 3b 0a 20 20 20 20 | ',.0,.$this->caughtLength);..... |
1a240 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 69 73 73 65 74 28 24 63 6c 65 61 6e | ................if.(isset($clean |
1a260 | 42 75 66 66 65 72 5b 30 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | Buffer[0])).{................... |
1a280 | 20 20 20 20 20 20 24 62 75 66 66 65 72 20 3d 20 24 63 6c 65 61 6e 42 75 66 66 65 72 3b 0a 20 20 | ......$buffer.=.$cleanBuffer;... |
1a2a0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ..................}............. |
1a2c0 | 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 62 | ....}..................return.$b |
1a2e0 | 75 66 66 65 72 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 29 3b 0a 0a 20 20 20 20 20 20 20 20 | uffer;.............});.......... |
1a300 | 20 20 20 20 65 63 68 6f 20 24 74 68 69 73 2d 3e 63 61 75 67 68 74 42 75 66 66 65 72 3b 0a 20 20 | ....echo.$this->caughtBuffer;... |
1a320 | 20 20 20 20 20 20 20 20 20 20 24 63 61 75 67 68 74 4c 65 6e 67 74 68 20 3d 20 6f 62 5f 67 65 74 | ..........$caughtLength.=.ob_get |
1a340 | 5f 6c 65 6e 67 74 68 28 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 24 74 68 | _length();.........}.........$th |
1a360 | 69 73 2d 3e 63 61 75 67 68 74 42 75 66 66 65 72 20 3d 20 6e 75 6c 6c 3b 0a 0a 20 20 20 20 20 20 | is->caughtBuffer.=.null;........ |
1a380 | 20 20 74 72 79 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 63 61 6c 6c 5f 75 73 65 72 5f 66 75 | ..try.{.............call_user_fu |
1a3a0 | 6e 63 28 24 74 68 69 73 2d 3e 68 61 6e 64 6c 65 72 2c 20 24 65 78 63 65 70 74 69 6f 6e 29 3b 0a | nc($this->handler,.$exception);. |
1a3c0 | 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 63 61 75 67 68 74 4c 65 6e 67 74 68 20 | ............$this->caughtLength. |
1a3e0 | 3d 20 24 63 61 75 67 68 74 4c 65 6e 67 74 68 3b 0a 20 20 20 20 20 20 20 20 7d 20 63 61 74 63 68 | =.$caughtLength;.........}.catch |
1a400 | 20 28 5c 45 78 63 65 70 74 69 6f 6e 20 24 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 | .(\Exception.$e).{.............i |
1a420 | 66 20 28 21 24 63 61 75 67 68 74 4c 65 6e 67 74 68 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | f.(!$caughtLength).{............ |
1a440 | 20 20 20 20 20 2f 2f 20 41 6c 6c 20 68 61 6e 64 6c 65 72 73 20 66 61 69 6c 65 64 2e 20 4c 65 74 | .....//.All.handlers.failed..Let |
1a460 | 20 50 48 50 20 68 61 6e 64 6c 65 20 74 68 61 74 20 6e 6f 77 2e 0a 20 20 20 20 20 20 20 20 20 20 | .PHP.handle.that.now............ |
1a480 | 20 20 20 20 20 20 74 68 72 6f 77 20 24 65 78 63 65 70 74 69 6f 6e 3b 0a 20 20 20 20 20 20 20 20 | ......throw.$exception;......... |
1a4a0 | 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 | ....}.........}.....}....../**.. |
1a4c0 | 20 20 20 20 2a 20 53 65 6e 64 73 20 74 68 65 20 65 72 72 6f 72 20 61 73 73 6f 63 69 61 74 65 64 | ....*.Sends.the.error.associated |
1a4e0 | 20 77 69 74 68 20 74 68 65 20 67 69 76 65 6e 20 45 78 63 65 70 74 69 6f 6e 20 61 73 20 61 20 70 | .with.the.given.Exception.as.a.p |
1a500 | 6c 61 69 6e 20 50 48 50 20 72 65 73 70 6f 6e 73 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a | lain.PHP.response.......*......* |
1a520 | 20 54 68 69 73 20 6d 65 74 68 6f 64 20 75 73 65 73 20 70 6c 61 69 6e 20 50 48 50 20 66 75 6e 63 | .This.method.uses.plain.PHP.func |
1a540 | 74 69 6f 6e 73 20 6c 69 6b 65 20 68 65 61 64 65 72 28 29 20 61 6e 64 20 65 63 68 6f 20 74 6f 20 | tions.like.header().and.echo.to. |
1a560 | 6f 75 74 70 75 74 0a 20 20 20 20 20 2a 20 74 68 65 20 72 65 73 70 6f 6e 73 65 2e 0a 20 20 20 20 | output......*.the.response...... |
1a580 | 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 5c 45 78 63 65 70 74 69 6f 6e 7c 46 6c 61 74 | .*......*.@param.\Exception|Flat |
1a5a0 | 74 65 6e 45 78 63 65 70 74 69 6f 6e 20 24 65 78 63 65 70 74 69 6f 6e 20 41 6e 20 5c 45 78 63 65 | tenException.$exception.An.\Exce |
1a5c0 | 70 74 69 6f 6e 20 6f 72 20 46 6c 61 74 74 65 6e 45 78 63 65 70 74 69 6f 6e 20 69 6e 73 74 61 6e | ption.or.FlattenException.instan |
1a5e0 | 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 | ce......*/.....public.function.s |
1a600 | 65 6e 64 50 68 70 52 65 73 70 6f 6e 73 65 28 24 65 78 63 65 70 74 69 6f 6e 29 0a 20 20 20 20 7b | endPhpResponse($exception).....{ |
1a620 | 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 24 65 78 63 65 70 74 69 6f 6e 20 69 6e 73 74 61 6e 63 | .........if.(!$exception.instanc |
1a640 | 65 6f 66 20 46 6c 61 74 74 65 6e 45 78 63 65 70 74 69 6f 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 | eof.FlattenException).{......... |
1a660 | 20 20 20 20 24 65 78 63 65 70 74 69 6f 6e 20 3d 20 46 6c 61 74 74 65 6e 45 78 63 65 70 74 69 6f | ....$exception.=.FlattenExceptio |
1a680 | 6e 3a 3a 63 72 65 61 74 65 28 24 65 78 63 65 70 74 69 6f 6e 29 3b 0a 20 20 20 20 20 20 20 20 7d | n::create($exception);.........} |
1a6a0 | 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 68 65 61 64 65 72 73 5f 73 65 6e 74 28 29 29 20 7b | ..........if.(!headers_sent()).{ |
1a6c0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 68 65 61 64 65 72 28 73 70 72 69 6e 74 66 28 27 48 54 54 | .............header(sprintf('HTT |
1a6e0 | 50 2f 31 2e 30 20 25 73 27 2c 20 24 65 78 63 65 70 74 69 6f 6e 2d 3e 67 65 74 53 74 61 74 75 73 | P/1.0.%s',.$exception->getStatus |
1a700 | 43 6f 64 65 28 29 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 | Code()));.............foreach.($ |
1a720 | 65 78 63 65 70 74 69 6f 6e 2d 3e 67 65 74 48 65 61 64 65 72 73 28 29 20 61 73 20 24 6e 61 6d 65 | exception->getHeaders().as.$name |
1a740 | 20 3d 3e 20 24 76 61 6c 75 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 68 65 | .=>.$value).{.................he |
1a760 | 61 64 65 72 28 24 6e 61 6d 65 2e 27 3a 20 27 2e 24 76 61 6c 75 65 2c 20 66 61 6c 73 65 29 3b 0a | ader($name.':.'.$value,.false);. |
1a780 | 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 68 65 61 64 65 72 | ............}.............header |
1a7a0 | 28 27 43 6f 6e 74 65 6e 74 2d 54 79 70 65 3a 20 74 65 78 74 2f 68 74 6d 6c 3b 20 63 68 61 72 73 | ('Content-Type:.text/html;.chars |
1a7c0 | 65 74 3d 27 2e 24 74 68 69 73 2d 3e 63 68 61 72 73 65 74 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a | et='.$this->charset);.........}. |
1a7e0 | 0a 20 20 20 20 20 20 20 20 65 63 68 6f 20 24 74 68 69 73 2d 3e 64 65 63 6f 72 61 74 65 28 24 74 | .........echo.$this->decorate($t |
1a800 | 68 69 73 2d 3e 67 65 74 43 6f 6e 74 65 6e 74 28 24 65 78 63 65 70 74 69 6f 6e 29 2c 20 24 74 68 | his->getContent($exception),.$th |
1a820 | 69 73 2d 3e 67 65 74 53 74 79 6c 65 73 68 65 65 74 28 24 65 78 63 65 70 74 69 6f 6e 29 29 3b 0a | is->getStylesheet($exception));. |
1a840 | 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 66 | ....}....../**......*.Gets.the.f |
1a860 | 75 6c 6c 20 48 54 4d 4c 20 63 6f 6e 74 65 6e 74 20 61 73 73 6f 63 69 61 74 65 64 20 77 69 74 68 | ull.HTML.content.associated.with |
1a880 | 20 74 68 65 20 67 69 76 65 6e 20 65 78 63 65 70 74 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 | .the.given.exception.......*.... |
1a8a0 | 20 20 2a 20 40 70 61 72 61 6d 20 5c 45 78 63 65 70 74 69 6f 6e 7c 46 6c 61 74 74 65 6e 45 78 63 | ..*.@param.\Exception|FlattenExc |
1a8c0 | 65 70 74 69 6f 6e 20 24 65 78 63 65 70 74 69 6f 6e 20 41 6e 20 5c 45 78 63 65 70 74 69 6f 6e 20 | eption.$exception.An.\Exception. |
1a8e0 | 6f 72 20 46 6c 61 74 74 65 6e 45 78 63 65 70 74 69 6f 6e 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 | or.FlattenException.instance.... |
1a900 | 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 20 54 68 65 20 48 54 | ..*......*.@return.string.The.HT |
1a920 | 4d 4c 20 63 6f 6e 74 65 6e 74 20 61 73 20 61 20 73 74 72 69 6e 67 0a 20 20 20 20 20 2a 2f 0a 20 | ML.content.as.a.string......*/.. |
1a940 | 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 48 74 6d 6c 28 24 65 78 63 65 | ...public.function.getHtml($exce |
1a960 | 70 74 69 6f 6e 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 24 65 78 63 65 70 | ption).....{.........if.(!$excep |
1a980 | 74 69 6f 6e 20 69 6e 73 74 61 6e 63 65 6f 66 20 46 6c 61 74 74 65 6e 45 78 63 65 70 74 69 6f 6e | tion.instanceof.FlattenException |
1a9a0 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 65 78 63 65 70 74 69 6f 6e 20 3d 20 46 6c 61 | ).{.............$exception.=.Fla |
1a9c0 | 74 74 65 6e 45 78 63 65 70 74 69 6f 6e 3a 3a 63 72 65 61 74 65 28 24 65 78 63 65 70 74 69 6f 6e | ttenException::create($exception |
1a9e0 | 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 | );.........}..........return.$th |
1aa00 | 69 73 2d 3e 64 65 63 6f 72 61 74 65 28 24 74 68 69 73 2d 3e 67 65 74 43 6f 6e 74 65 6e 74 28 24 | is->decorate($this->getContent($ |
1aa20 | 65 78 63 65 70 74 69 6f 6e 29 2c 20 24 74 68 69 73 2d 3e 67 65 74 53 74 79 6c 65 73 68 65 65 74 | exception),.$this->getStylesheet |
1aa40 | 28 24 65 78 63 65 70 74 69 6f 6e 29 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 | ($exception));.....}....../**... |
1aa60 | 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 48 54 4d 4c 20 63 6f 6e 74 65 6e 74 20 61 73 73 6f 63 | ...*.Gets.the.HTML.content.assoc |
1aa80 | 69 61 74 65 64 20 77 69 74 68 20 74 68 65 20 67 69 76 65 6e 20 65 78 63 65 70 74 69 6f 6e 2e 0a | iated.with.the.given.exception.. |
1aaa0 | 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 46 6c 61 74 74 65 6e 45 78 63 65 | .....*......*.@param.FlattenExce |
1aac0 | 70 74 69 6f 6e 20 24 65 78 63 65 70 74 69 6f 6e 20 41 20 46 6c 61 74 74 65 6e 45 78 63 65 70 74 | ption.$exception.A.FlattenExcept |
1aae0 | 69 6f 6e 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 | ion.instance......*......*.@retu |
1ab00 | 72 6e 20 73 74 72 69 6e 67 20 54 68 65 20 63 6f 6e 74 65 6e 74 20 61 73 20 61 20 73 74 72 69 6e | rn.string.The.content.as.a.strin |
1ab20 | 67 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 | g......*/.....public.function.ge |
1ab40 | 74 43 6f 6e 74 65 6e 74 28 46 6c 61 74 74 65 6e 45 78 63 65 70 74 69 6f 6e 20 24 65 78 63 65 70 | tContent(FlattenException.$excep |
1ab60 | 74 69 6f 6e 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 73 77 69 74 63 68 20 28 24 65 78 63 | tion).....{.........switch.($exc |
1ab80 | 65 70 74 69 6f 6e 2d 3e 67 65 74 53 74 61 74 75 73 43 6f 64 65 28 29 29 20 7b 0a 20 20 20 20 20 | eption->getStatusCode()).{...... |
1aba0 | 20 20 20 20 20 20 20 63 61 73 65 20 34 30 34 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | .......case.404:................ |
1abc0 | 20 24 74 69 74 6c 65 20 3d 20 27 53 6f 72 72 79 2c 20 74 68 65 20 70 61 67 65 20 79 6f 75 20 61 | .$title.=.'Sorry,.the.page.you.a |
1abe0 | 72 65 20 6c 6f 6f 6b 69 6e 67 20 66 6f 72 20 63 6f 75 6c 64 20 6e 6f 74 20 62 65 20 66 6f 75 6e | re.looking.for.could.not.be.foun |
1ac00 | 64 2e 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 62 72 65 61 6b 3b 0a 20 20 20 20 | d.';.................break;..... |
1ac20 | 20 20 20 20 20 20 20 20 64 65 66 61 75 6c 74 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ........default:................ |
1ac40 | 20 24 74 69 74 6c 65 20 3d 20 27 57 68 6f 6f 70 73 2c 20 6c 6f 6f 6b 73 20 6c 69 6b 65 20 73 6f | .$title.=.'Whoops,.looks.like.so |
1ac60 | 6d 65 74 68 69 6e 67 20 77 65 6e 74 20 77 72 6f 6e 67 2e 27 3b 0a 20 20 20 20 20 20 20 20 7d 0a | mething.went.wrong.';.........}. |
1ac80 | 0a 20 20 20 20 20 20 20 20 24 63 6f 6e 74 65 6e 74 20 3d 20 27 27 3b 0a 20 20 20 20 20 20 20 20 | .........$content.=.'';......... |
1aca0 | 69 66 20 28 24 74 68 69 73 2d 3e 64 65 62 75 67 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | if.($this->debug).{............. |
1acc0 | 74 72 79 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6f 75 6e 74 20 3d 20 63 | try.{.................$count.=.c |
1ace0 | 6f 75 6e 74 28 24 65 78 63 65 70 74 69 6f 6e 2d 3e 67 65 74 41 6c 6c 50 72 65 76 69 6f 75 73 28 | ount($exception->getAllPrevious( |
1ad00 | 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 6f 74 61 6c 20 3d 20 24 63 6f | ));.................$total.=.$co |
1ad20 | 75 6e 74 20 2b 20 31 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 | unt.+.1;.................foreach |
1ad40 | 20 28 24 65 78 63 65 70 74 69 6f 6e 2d 3e 74 6f 41 72 72 61 79 28 29 20 61 73 20 24 70 6f 73 69 | .($exception->toArray().as.$posi |
1ad60 | 74 69 6f 6e 20 3d 3e 20 24 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | tion.=>.$e).{................... |
1ad80 | 20 20 24 69 6e 64 20 3d 20 24 63 6f 75 6e 74 20 2d 20 24 70 6f 73 69 74 69 6f 6e 20 2b 20 31 3b | ..$ind.=.$count.-.$position.+.1; |
1ada0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6c 61 73 73 20 3d 20 24 74 | .....................$class.=.$t |
1adc0 | 68 69 73 2d 3e 66 6f 72 6d 61 74 43 6c 61 73 73 28 24 65 5b 27 63 6c 61 73 73 27 5d 29 3b 0a 20 | his->formatClass($e['class']);.. |
1ade0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 20 3d 20 6e 6c | ...................$message.=.nl |
1ae00 | 32 62 72 28 24 74 68 69 73 2d 3e 65 73 63 61 70 65 48 74 6d 6c 28 24 65 5b 27 6d 65 73 73 61 67 | 2br($this->escapeHtml($e['messag |
1ae20 | 65 27 5d 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6f 6e 74 | e']));.....................$cont |
1ae40 | 65 6e 74 20 2e 3d 20 73 70 72 69 6e 74 66 28 3c 3c 3c 27 45 4f 46 27 0a 20 20 20 20 20 20 20 20 | ent..=.sprintf(<<<'EOF'......... |
1ae60 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c 68 32 20 63 6c 61 73 73 3d 22 62 6c 6f 63 6b | ................<h2.class="block |
1ae80 | 5f 65 78 63 65 70 74 69 6f 6e 20 63 6c 65 61 72 5f 66 69 78 22 3e 0a 20 20 20 20 20 20 20 20 20 | _exception.clear_fix">.......... |
1aea0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c 73 70 61 6e 20 63 6c 61 73 73 3d 22 | ...................<span.class=" |
1aec0 | 65 78 63 65 70 74 69 6f 6e 5f 63 6f 75 6e 74 65 72 22 3e 25 64 2f 25 64 3c 2f 73 70 61 6e 3e 0a | exception_counter">%d/%d</span>. |
1aee0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c 73 70 61 | ............................<spa |
1af00 | 6e 20 63 6c 61 73 73 3d 22 65 78 63 65 70 74 69 6f 6e 5f 74 69 74 6c 65 22 3e 25 73 25 73 3a 3c | n.class="exception_title">%s%s:< |
1af20 | 2f 73 70 61 6e 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | /span>.......................... |
1af40 | 20 20 20 3c 73 70 61 6e 20 63 6c 61 73 73 3d 22 65 78 63 65 70 74 69 6f 6e 5f 6d 65 73 73 61 67 | ...<span.class="exception_messag |
1af60 | 65 22 3e 25 73 3c 2f 73 70 61 6e 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | e">%s</span>.................... |
1af80 | 20 20 20 20 20 3c 2f 68 32 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | .....</h2>...................... |
1afa0 | 20 20 20 3c 64 69 76 20 63 6c 61 73 73 3d 22 62 6c 6f 63 6b 22 3e 0a 20 20 20 20 20 20 20 20 20 | ...<div.class="block">.......... |
1afc0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 3c 6f 6c 20 63 6c 61 73 73 3d 22 74 72 | ...................<ol.class="tr |
1afe0 | 61 63 65 73 20 6c 69 73 74 5f 65 78 63 65 70 74 69 6f 6e 22 3e 0a 0a 45 4f 46 0a 20 20 20 20 20 | aces.list_exception">..EOF...... |
1b000 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2c 20 24 69 6e 64 2c 20 24 74 6f 74 61 | ...................,.$ind,.$tota |
1b020 | 6c 2c 20 24 63 6c 61 73 73 2c 20 24 74 68 69 73 2d 3e 66 6f 72 6d 61 74 50 61 74 68 28 24 65 5b | l,.$class,.$this->formatPath($e[ |
1b040 | 27 74 72 61 63 65 27 5d 5b 30 5d 5b 27 66 69 6c 65 27 5d 2c 20 24 65 5b 27 74 72 61 63 65 27 5d | 'trace'][0]['file'],.$e['trace'] |
1b060 | 5b 30 5d 5b 27 6c 69 6e 65 27 5d 29 2c 20 24 6d 65 73 73 61 67 65 29 3b 0a 20 20 20 20 20 20 20 | [0]['line']),.$message);........ |
1b080 | 20 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 65 5b 27 74 72 61 63 65 27 | .............foreach.($e['trace' |
1b0a0 | 5d 20 61 73 20 24 74 72 61 63 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ].as.$trace).{.................. |
1b0c0 | 20 20 20 20 20 20 20 24 63 6f 6e 74 65 6e 74 20 2e 3d 20 27 20 20 20 20 20 20 20 3c 6c 69 3e 27 | .......$content..=.'.......<li>' |
1b0e0 | 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 74 | ;.........................if.($t |
1b100 | 72 61 63 65 5b 27 66 75 6e 63 74 69 6f 6e 27 5d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | race['function']).{............. |
1b120 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6f 6e 74 65 6e 74 20 2e 3d 20 73 70 72 69 | ................$content..=.spri |
1b140 | 6e 74 66 28 27 61 74 20 25 73 25 73 25 73 28 25 73 29 27 2c 20 24 74 68 69 73 2d 3e 66 6f 72 6d | ntf('at.%s%s%s(%s)',.$this->form |
1b160 | 61 74 43 6c 61 73 73 28 24 74 72 61 63 65 5b 27 63 6c 61 73 73 27 5d 29 2c 20 24 74 72 61 63 65 | atClass($trace['class']),.$trace |
1b180 | 5b 27 74 79 70 65 27 5d 2c 20 24 74 72 61 63 65 5b 27 66 75 6e 63 74 69 6f 6e 27 5d 2c 20 24 74 | ['type'],.$trace['function'],.$t |
1b1a0 | 68 69 73 2d 3e 66 6f 72 6d 61 74 41 72 67 73 28 24 74 72 61 63 65 5b 27 61 72 67 73 27 5d 29 29 | his->formatArgs($trace['args'])) |
1b1c0 | 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 | ;.........................}..... |
1b1e0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 69 73 73 65 74 28 24 74 | ....................if.(isset($t |
1b200 | 72 61 63 65 5b 27 66 69 6c 65 27 5d 29 20 26 26 20 69 73 73 65 74 28 24 74 72 61 63 65 5b 27 6c | race['file']).&&.isset($trace['l |
1b220 | 69 6e 65 27 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ine'])).{....................... |
1b240 | 20 20 20 20 20 20 24 63 6f 6e 74 65 6e 74 20 2e 3d 20 24 74 68 69 73 2d 3e 66 6f 72 6d 61 74 50 | ......$content..=.$this->formatP |
1b260 | 61 74 68 28 24 74 72 61 63 65 5b 27 66 69 6c 65 27 5d 2c 20 24 74 72 61 63 65 5b 27 6c 69 6e 65 | ath($trace['file'],.$trace['line |
1b280 | 27 5d 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 | ']);.........................}.. |
1b2a0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6f 6e 74 65 6e 74 20 | .......................$content. |
1b2c0 | 2e 3d 20 22 3c 2f 6c 69 3e 5c 6e 22 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | .=."</li>\n";................... |
1b2e0 | 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6f 6e 74 65 6e | ..}......................$conten |
1b300 | 74 20 2e 3d 20 22 20 20 20 20 3c 2f 6f 6c 3e 5c 6e 3c 2f 64 69 76 3e 5c 6e 22 3b 0a 20 20 20 20 | t..=."....</ol>\n</div>\n";..... |
1b320 | 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 63 61 74 63 | ............}.............}.catc |
1b340 | 68 20 28 5c 45 78 63 65 70 74 69 6f 6e 20 24 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | h.(\Exception.$e).{............. |
1b360 | 20 20 20 20 2f 2f 20 73 6f 6d 65 74 68 69 6e 67 20 6e 61 73 74 79 20 68 61 70 70 65 6e 65 64 20 | ....//.something.nasty.happened. |
1b380 | 61 6e 64 20 77 65 20 63 61 6e 6e 6f 74 20 74 68 72 6f 77 20 61 6e 20 65 78 63 65 70 74 69 6f 6e | and.we.cannot.throw.an.exception |
1b3a0 | 20 61 6e 79 6d 6f 72 65 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 74 68 | .anymore.................if.($th |
1b3c0 | 69 73 2d 3e 64 65 62 75 67 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | is->debug).{.................... |
1b3e0 | 20 24 74 69 74 6c 65 20 3d 20 73 70 72 69 6e 74 66 28 27 45 78 63 65 70 74 69 6f 6e 20 74 68 72 | .$title.=.sprintf('Exception.thr |
1b400 | 6f 77 6e 20 77 68 65 6e 20 68 61 6e 64 6c 69 6e 67 20 61 6e 20 65 78 63 65 70 74 69 6f 6e 20 28 | own.when.handling.an.exception.( |
1b420 | 25 73 3a 20 25 73 29 27 2c 20 67 65 74 5f 63 6c 61 73 73 28 24 65 29 2c 20 24 74 68 69 73 2d 3e | %s:.%s)',.get_class($e),.$this-> |
1b440 | 65 73 63 61 70 65 48 74 6d 6c 28 24 65 2d 3e 67 65 74 4d 65 73 73 61 67 65 28 29 29 29 3b 0a 20 | escapeHtml($e->getMessage()));.. |
1b460 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 | ...............}.else.{......... |
1b480 | 20 20 20 20 20 20 20 20 20 20 20 20 24 74 69 74 6c 65 20 3d 20 27 57 68 6f 6f 70 73 2c 20 6c 6f | ............$title.=.'Whoops,.lo |
1b4a0 | 6f 6b 73 20 6c 69 6b 65 20 73 6f 6d 65 74 68 69 6e 67 20 77 65 6e 74 20 77 72 6f 6e 67 2e 27 3b | oks.like.something.went.wrong.'; |
1b4c0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d | .................}.............} |
1b4e0 | 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 3c 3c 3c 45 4f | .........}..........return.<<<EO |
1b500 | 46 0a 20 20 20 20 20 20 20 20 20 20 20 20 3c 64 69 76 20 69 64 3d 22 73 66 2d 72 65 73 65 74 63 | F.............<div.id="sf-resetc |
1b520 | 6f 6e 74 65 6e 74 22 20 63 6c 61 73 73 3d 22 73 66 2d 72 65 73 65 74 22 3e 0a 20 20 20 20 20 20 | ontent".class="sf-reset">....... |
1b540 | 20 20 20 20 20 20 20 20 20 20 3c 68 31 3e 24 74 69 74 6c 65 3c 2f 68 31 3e 0a 20 20 20 20 20 20 | ..........<h1>$title</h1>....... |
1b560 | 20 20 20 20 20 20 20 20 20 20 24 63 6f 6e 74 65 6e 74 0a 20 20 20 20 20 20 20 20 20 20 20 20 3c | ..........$content.............< |
1b580 | 2f 64 69 76 3e 0a 45 4f 46 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a | /div>.EOF;.....}....../**......* |
1b5a0 | 20 47 65 74 73 20 74 68 65 20 73 74 79 6c 65 73 68 65 65 74 20 61 73 73 6f 63 69 61 74 65 64 20 | .Gets.the.stylesheet.associated. |
1b5c0 | 77 69 74 68 20 74 68 65 20 67 69 76 65 6e 20 65 78 63 65 70 74 69 6f 6e 2e 0a 20 20 20 20 20 2a | with.the.given.exception.......* |
1b5e0 | 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 46 6c 61 74 74 65 6e 45 78 63 65 70 74 69 6f 6e 20 | ......*.@param.FlattenException. |
1b600 | 24 65 78 63 65 70 74 69 6f 6e 20 41 20 46 6c 61 74 74 65 6e 45 78 63 65 70 74 69 6f 6e 20 69 6e | $exception.A.FlattenException.in |
1b620 | 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 | stance......*......*.@return.str |
1b640 | 69 6e 67 20 54 68 65 20 73 74 79 6c 65 73 68 65 65 74 20 61 73 20 61 20 73 74 72 69 6e 67 0a 20 | ing.The.stylesheet.as.a.string.. |
1b660 | 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 53 74 | ....*/.....public.function.getSt |
1b680 | 79 6c 65 73 68 65 65 74 28 46 6c 61 74 74 65 6e 45 78 63 65 70 74 69 6f 6e 20 24 65 78 63 65 70 | ylesheet(FlattenException.$excep |
1b6a0 | 74 69 6f 6e 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 3c 3c 3c 27 45 | tion).....{.........return.<<<'E |
1b6c0 | 4f 46 27 0a 20 20 20 20 20 20 20 20 20 20 20 20 2e 73 66 2d 72 65 73 65 74 20 7b 20 66 6f 6e 74 | OF'..............sf-reset.{.font |
1b6e0 | 3a 20 31 31 70 78 20 56 65 72 64 61 6e 61 2c 20 41 72 69 61 6c 2c 20 73 61 6e 73 2d 73 65 72 69 | :.11px.Verdana,.Arial,.sans-seri |
1b700 | 66 3b 20 63 6f 6c 6f 72 3a 20 23 33 33 33 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2e 73 66 | f;.color:.#333.}..............sf |
1b720 | 2d 72 65 73 65 74 20 2e 63 6c 65 61 72 20 7b 20 63 6c 65 61 72 3a 62 6f 74 68 3b 20 68 65 69 67 | -reset..clear.{.clear:both;.heig |
1b740 | 68 74 3a 30 3b 20 66 6f 6e 74 2d 73 69 7a 65 3a 30 3b 20 6c 69 6e 65 2d 68 65 69 67 68 74 3a 30 | ht:0;.font-size:0;.line-height:0 |
1b760 | 3b 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2e 73 66 2d 72 65 73 65 74 20 2e 63 6c 65 61 72 | ;.}..............sf-reset..clear |
1b780 | 5f 66 69 78 3a 61 66 74 65 72 20 7b 20 64 69 73 70 6c 61 79 3a 62 6c 6f 63 6b 3b 20 68 65 69 67 | _fix:after.{.display:block;.heig |
1b7a0 | 68 74 3a 30 3b 20 63 6c 65 61 72 3a 62 6f 74 68 3b 20 76 69 73 69 62 69 6c 69 74 79 3a 68 69 64 | ht:0;.clear:both;.visibility:hid |
1b7c0 | 64 65 6e 3b 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2e 73 66 2d 72 65 73 65 74 20 2e 63 6c | den;.}..............sf-reset..cl |
1b7e0 | 65 61 72 5f 66 69 78 20 7b 20 64 69 73 70 6c 61 79 3a 69 6e 6c 69 6e 65 2d 62 6c 6f 63 6b 3b 20 | ear_fix.{.display:inline-block;. |
1b800 | 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2e 73 66 2d 72 65 73 65 74 20 2a 20 68 74 6d 6c 20 2e | }..............sf-reset.*.html.. |
1b820 | 63 6c 65 61 72 5f 66 69 78 20 7b 20 68 65 69 67 68 74 3a 31 25 3b 20 7d 0a 20 20 20 20 20 20 20 | clear_fix.{.height:1%;.}........ |
1b840 | 20 20 20 20 20 2e 73 66 2d 72 65 73 65 74 20 2e 63 6c 65 61 72 5f 66 69 78 20 7b 20 64 69 73 70 | ......sf-reset..clear_fix.{.disp |
1b860 | 6c 61 79 3a 62 6c 6f 63 6b 3b 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2e 73 66 2d 72 65 73 | lay:block;.}..............sf-res |
1b880 | 65 74 2c 20 2e 73 66 2d 72 65 73 65 74 20 2e 62 6c 6f 63 6b 20 7b 20 6d 61 72 67 69 6e 3a 20 61 | et,..sf-reset..block.{.margin:.a |
1b8a0 | 75 74 6f 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2e 73 66 2d 72 65 73 65 74 20 61 62 62 72 | uto.}..............sf-reset.abbr |
1b8c0 | 20 7b 20 62 6f 72 64 65 72 2d 62 6f 74 74 6f 6d 3a 20 31 70 78 20 64 6f 74 74 65 64 20 23 30 30 | .{.border-bottom:.1px.dotted.#00 |
1b8e0 | 30 3b 20 63 75 72 73 6f 72 3a 20 68 65 6c 70 3b 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2e | 0;.cursor:.help;.}.............. |
1b900 | 73 66 2d 72 65 73 65 74 20 70 20 7b 20 66 6f 6e 74 2d 73 69 7a 65 3a 31 34 70 78 3b 20 6c 69 6e | sf-reset.p.{.font-size:14px;.lin |
1b920 | 65 2d 68 65 69 67 68 74 3a 32 30 70 78 3b 20 63 6f 6c 6f 72 3a 23 38 36 38 36 38 36 3b 20 70 61 | e-height:20px;.color:#868686;.pa |
1b940 | 64 64 69 6e 67 2d 62 6f 74 74 6f 6d 3a 32 30 70 78 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 | dding-bottom:20px.}............. |
1b960 | 2e 73 66 2d 72 65 73 65 74 20 73 74 72 6f 6e 67 20 7b 20 66 6f 6e 74 2d 77 65 69 67 68 74 3a 62 | .sf-reset.strong.{.font-weight:b |
1b980 | 6f 6c 64 3b 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2e 73 66 2d 72 65 73 65 74 20 61 20 7b | old;.}..............sf-reset.a.{ |
1b9a0 | 20 63 6f 6c 6f 72 3a 23 36 63 36 31 35 39 3b 20 63 75 72 73 6f 72 3a 20 64 65 66 61 75 6c 74 3b | .color:#6c6159;.cursor:.default; |
1b9c0 | 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2e 73 66 2d 72 65 73 65 74 20 61 20 69 6d 67 20 7b | .}..............sf-reset.a.img.{ |
1b9e0 | 20 62 6f 72 64 65 72 3a 6e 6f 6e 65 3b 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2e 73 66 2d | .border:none;.}..............sf- |
1ba00 | 72 65 73 65 74 20 61 3a 68 6f 76 65 72 20 7b 20 74 65 78 74 2d 64 65 63 6f 72 61 74 69 6f 6e 3a | reset.a:hover.{.text-decoration: |
1ba20 | 75 6e 64 65 72 6c 69 6e 65 3b 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2e 73 66 2d 72 65 73 | underline;.}..............sf-res |
1ba40 | 65 74 20 65 6d 20 7b 20 66 6f 6e 74 2d 73 74 79 6c 65 3a 69 74 61 6c 69 63 3b 20 7d 0a 20 20 20 | et.em.{.font-style:italic;.}.... |
1ba60 | 20 20 20 20 20 20 20 20 20 2e 73 66 2d 72 65 73 65 74 20 68 31 2c 20 2e 73 66 2d 72 65 73 65 74 | ..........sf-reset.h1,..sf-reset |
1ba80 | 20 68 32 20 7b 20 66 6f 6e 74 3a 20 32 30 70 78 20 47 65 6f 72 67 69 61 2c 20 22 54 69 6d 65 73 | .h2.{.font:.20px.Georgia,."Times |
1baa0 | 20 4e 65 77 20 52 6f 6d 61 6e 22 2c 20 54 69 6d 65 73 2c 20 73 65 72 69 66 20 7d 0a 20 20 20 20 | .New.Roman",.Times,.serif.}..... |
1bac0 | 20 20 20 20 20 20 20 20 2e 73 66 2d 72 65 73 65 74 20 2e 65 78 63 65 70 74 69 6f 6e 5f 63 6f 75 | .........sf-reset..exception_cou |
1bae0 | 6e 74 65 72 20 7b 20 62 61 63 6b 67 72 6f 75 6e 64 2d 63 6f 6c 6f 72 3a 20 23 66 66 66 3b 20 63 | nter.{.background-color:.#fff;.c |
1bb00 | 6f 6c 6f 72 3a 20 23 33 33 33 3b 20 70 61 64 64 69 6e 67 3a 20 36 70 78 3b 20 66 6c 6f 61 74 3a | olor:.#333;.padding:.6px;.float: |
1bb20 | 20 6c 65 66 74 3b 20 6d 61 72 67 69 6e 2d 72 69 67 68 74 3a 20 31 30 70 78 3b 20 66 6c 6f 61 74 | .left;.margin-right:.10px;.float |
1bb40 | 3a 20 6c 65 66 74 3b 20 64 69 73 70 6c 61 79 3a 20 62 6c 6f 63 6b 3b 20 7d 0a 20 20 20 20 20 20 | :.left;.display:.block;.}....... |
1bb60 | 20 20 20 20 20 20 2e 73 66 2d 72 65 73 65 74 20 2e 65 78 63 65 70 74 69 6f 6e 5f 74 69 74 6c 65 | .......sf-reset..exception_title |
1bb80 | 20 7b 20 6d 61 72 67 69 6e 2d 6c 65 66 74 3a 20 33 65 6d 3b 20 6d 61 72 67 69 6e 2d 62 6f 74 74 | .{.margin-left:.3em;.margin-bott |
1bba0 | 6f 6d 3a 20 30 2e 37 65 6d 3b 20 64 69 73 70 6c 61 79 3a 20 62 6c 6f 63 6b 3b 20 7d 0a 20 20 20 | om:.0.7em;.display:.block;.}.... |
1bbc0 | 20 20 20 20 20 20 20 20 20 2e 73 66 2d 72 65 73 65 74 20 2e 65 78 63 65 70 74 69 6f 6e 5f 6d 65 | ..........sf-reset..exception_me |
1bbe0 | 73 73 61 67 65 20 7b 20 6d 61 72 67 69 6e 2d 6c 65 66 74 3a 20 33 65 6d 3b 20 64 69 73 70 6c 61 | ssage.{.margin-left:.3em;.displa |
1bc00 | 79 3a 20 62 6c 6f 63 6b 3b 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2e 73 66 2d 72 65 73 65 | y:.block;.}..............sf-rese |
1bc20 | 74 20 2e 74 72 61 63 65 73 20 6c 69 20 7b 20 66 6f 6e 74 2d 73 69 7a 65 3a 31 32 70 78 3b 20 70 | t..traces.li.{.font-size:12px;.p |
1bc40 | 61 64 64 69 6e 67 3a 20 32 70 78 20 34 70 78 3b 20 6c 69 73 74 2d 73 74 79 6c 65 2d 74 79 70 65 | adding:.2px.4px;.list-style-type |
1bc60 | 3a 64 65 63 69 6d 61 6c 3b 20 6d 61 72 67 69 6e 2d 6c 65 66 74 3a 32 30 70 78 3b 20 7d 0a 20 20 | :decimal;.margin-left:20px;.}... |
1bc80 | 20 20 20 20 20 20 20 20 20 20 2e 73 66 2d 72 65 73 65 74 20 2e 62 6c 6f 63 6b 20 7b 20 62 61 63 | ...........sf-reset..block.{.bac |
1bca0 | 6b 67 72 6f 75 6e 64 2d 63 6f 6c 6f 72 3a 23 46 46 46 46 46 46 3b 20 70 61 64 64 69 6e 67 3a 31 | kground-color:#FFFFFF;.padding:1 |
1bcc0 | 30 70 78 20 32 38 70 78 3b 20 6d 61 72 67 69 6e 2d 62 6f 74 74 6f 6d 3a 32 30 70 78 3b 0a 20 20 | 0px.28px;.margin-bottom:20px;... |
1bce0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2d 77 65 62 6b 69 74 2d 62 6f 72 64 65 72 2d 62 6f 74 | ..............-webkit-border-bot |
1bd00 | 74 6f 6d 2d 72 69 67 68 74 2d 72 61 64 69 75 73 3a 20 31 36 70 78 3b 0a 20 20 20 20 20 20 20 20 | tom-right-radius:.16px;......... |
1bd20 | 20 20 20 20 20 20 20 20 2d 77 65 62 6b 69 74 2d 62 6f 72 64 65 72 2d 62 6f 74 74 6f 6d 2d 6c 65 | ........-webkit-border-bottom-le |
1bd40 | 66 74 2d 72 61 64 69 75 73 3a 20 31 36 70 78 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ft-radius:.16px;................ |
1bd60 | 20 2d 6d 6f 7a 2d 62 6f 72 64 65 72 2d 72 61 64 69 75 73 2d 62 6f 74 74 6f 6d 72 69 67 68 74 3a | .-moz-border-radius-bottomright: |
1bd80 | 20 31 36 70 78 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2d 6d 6f 7a 2d 62 6f 72 64 | .16px;.................-moz-bord |
1bda0 | 65 72 2d 72 61 64 69 75 73 2d 62 6f 74 74 6f 6d 6c 65 66 74 3a 20 31 36 70 78 3b 0a 20 20 20 20 | er-radius-bottomleft:.16px;..... |
1bdc0 | 20 20 20 20 20 20 20 20 20 20 20 20 62 6f 72 64 65 72 2d 62 6f 74 74 6f 6d 2d 72 69 67 68 74 2d | ............border-bottom-right- |
1bde0 | 72 61 64 69 75 73 3a 20 31 36 70 78 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 62 6f | radius:.16px;.................bo |
1be00 | 72 64 65 72 2d 62 6f 74 74 6f 6d 2d 6c 65 66 74 2d 72 61 64 69 75 73 3a 20 31 36 70 78 3b 0a 20 | rder-bottom-left-radius:.16px;.. |
1be20 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 62 6f 72 64 65 72 2d 62 6f 74 74 6f 6d 3a 31 70 78 | ...............border-bottom:1px |
1be40 | 20 73 6f 6c 69 64 20 23 63 63 63 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 62 6f 72 | .solid.#ccc;.................bor |
1be60 | 64 65 72 2d 72 69 67 68 74 3a 31 70 78 20 73 6f 6c 69 64 20 23 63 63 63 3b 0a 20 20 20 20 20 20 | der-right:1px.solid.#ccc;....... |
1be80 | 20 20 20 20 20 20 20 20 20 20 62 6f 72 64 65 72 2d 6c 65 66 74 3a 31 70 78 20 73 6f 6c 69 64 20 | ..........border-left:1px.solid. |
1bea0 | 23 63 63 63 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 77 6f 72 64 2d 77 72 61 70 3a | #ccc;.................word-wrap: |
1bec0 | 20 62 72 65 61 6b 2d 77 6f 72 64 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 | .break-word;.............}...... |
1bee0 | 20 20 20 20 20 20 20 2e 73 66 2d 72 65 73 65 74 20 2e 62 6c 6f 63 6b 5f 65 78 63 65 70 74 69 6f | ........sf-reset..block_exceptio |
1bf00 | 6e 20 7b 20 62 61 63 6b 67 72 6f 75 6e 64 2d 63 6f 6c 6f 72 3a 23 64 64 64 3b 20 63 6f 6c 6f 72 | n.{.background-color:#ddd;.color |
1bf20 | 3a 20 23 33 33 33 3b 20 70 61 64 64 69 6e 67 3a 32 30 70 78 3b 0a 20 20 20 20 20 20 20 20 20 20 | :.#333;.padding:20px;........... |
1bf40 | 20 20 20 20 20 20 2d 77 65 62 6b 69 74 2d 62 6f 72 64 65 72 2d 74 6f 70 2d 6c 65 66 74 2d 72 61 | ......-webkit-border-top-left-ra |
1bf60 | 64 69 75 73 3a 20 31 36 70 78 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2d 77 65 62 | dius:.16px;.................-web |
1bf80 | 6b 69 74 2d 62 6f 72 64 65 72 2d 74 6f 70 2d 72 69 67 68 74 2d 72 61 64 69 75 73 3a 20 31 36 70 | kit-border-top-right-radius:.16p |
1bfa0 | 78 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2d 6d 6f 7a 2d 62 6f 72 64 65 72 2d 72 | x;.................-moz-border-r |
1bfc0 | 61 64 69 75 73 2d 74 6f 70 6c 65 66 74 3a 20 31 36 70 78 3b 0a 20 20 20 20 20 20 20 20 20 20 20 | adius-topleft:.16px;............ |
1bfe0 | 20 20 20 20 20 2d 6d 6f 7a 2d 62 6f 72 64 65 72 2d 72 61 64 69 75 73 2d 74 6f 70 72 69 67 68 74 | .....-moz-border-radius-topright |
1c000 | 3a 20 31 36 70 78 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 62 6f 72 64 65 72 2d 74 | :.16px;.................border-t |
1c020 | 6f 70 2d 6c 65 66 74 2d 72 61 64 69 75 73 3a 20 31 36 70 78 3b 0a 20 20 20 20 20 20 20 20 20 20 | op-left-radius:.16px;........... |
1c040 | 20 20 20 20 20 20 62 6f 72 64 65 72 2d 74 6f 70 2d 72 69 67 68 74 2d 72 61 64 69 75 73 3a 20 31 | ......border-top-right-radius:.1 |
1c060 | 36 70 78 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 62 6f 72 64 65 72 2d 74 6f 70 3a | 6px;.................border-top: |
1c080 | 31 70 78 20 73 6f 6c 69 64 20 23 63 63 63 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | 1px.solid.#ccc;................. |
1c0a0 | 62 6f 72 64 65 72 2d 72 69 67 68 74 3a 31 70 78 20 73 6f 6c 69 64 20 23 63 63 63 3b 0a 20 20 20 | border-right:1px.solid.#ccc;.... |
1c0c0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 62 6f 72 64 65 72 2d 6c 65 66 74 3a 31 70 78 20 73 6f 6c | .............border-left:1px.sol |
1c0e0 | 69 64 20 23 63 63 63 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6f 76 65 72 66 6c 6f | id.#ccc;.................overflo |
1c100 | 77 3a 20 68 69 64 64 65 6e 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 77 6f 72 64 2d | w:.hidden;.................word- |
1c120 | 77 72 61 70 3a 20 62 72 65 61 6b 2d 77 6f 72 64 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a | wrap:.break-word;.............}. |
1c140 | 20 20 20 20 20 20 20 20 20 20 20 20 2e 73 66 2d 72 65 73 65 74 20 61 20 7b 20 62 61 63 6b 67 72 | .............sf-reset.a.{.backgr |
1c160 | 6f 75 6e 64 3a 6e 6f 6e 65 3b 20 63 6f 6c 6f 72 3a 23 38 36 38 36 38 36 3b 20 74 65 78 74 2d 64 | ound:none;.color:#868686;.text-d |
1c180 | 65 63 6f 72 61 74 69 6f 6e 3a 6e 6f 6e 65 3b 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2e 73 | ecoration:none;.}..............s |
1c1a0 | 66 2d 72 65 73 65 74 20 61 3a 68 6f 76 65 72 20 7b 20 62 61 63 6b 67 72 6f 75 6e 64 3a 6e 6f 6e | f-reset.a:hover.{.background:non |
1c1c0 | 65 3b 20 63 6f 6c 6f 72 3a 23 33 31 33 31 33 31 3b 20 74 65 78 74 2d 64 65 63 6f 72 61 74 69 6f | e;.color:#313131;.text-decoratio |
1c1e0 | 6e 3a 75 6e 64 65 72 6c 69 6e 65 3b 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2e 73 66 2d 72 | n:underline;.}..............sf-r |
1c200 | 65 73 65 74 20 6f 6c 20 7b 20 70 61 64 64 69 6e 67 3a 20 31 30 70 78 20 30 3b 20 7d 0a 20 20 20 | eset.ol.{.padding:.10px.0;.}.... |
1c220 | 20 20 20 20 20 20 20 20 20 2e 73 66 2d 72 65 73 65 74 20 68 31 20 7b 20 62 61 63 6b 67 72 6f 75 | ..........sf-reset.h1.{.backgrou |
1c240 | 6e 64 2d 63 6f 6c 6f 72 3a 23 46 46 46 46 46 46 3b 20 70 61 64 64 69 6e 67 3a 20 31 35 70 78 20 | nd-color:#FFFFFF;.padding:.15px. |
1c260 | 32 38 70 78 3b 20 6d 61 72 67 69 6e 2d 62 6f 74 74 6f 6d 3a 20 32 30 70 78 3b 0a 20 20 20 20 20 | 28px;.margin-bottom:.20px;...... |
1c280 | 20 20 20 20 20 20 20 20 20 20 20 2d 77 65 62 6b 69 74 2d 62 6f 72 64 65 72 2d 72 61 64 69 75 73 | ...........-webkit-border-radius |
1c2a0 | 3a 20 31 30 70 78 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2d 6d 6f 7a 2d 62 6f 72 | :.10px;.................-moz-bor |
1c2c0 | 64 65 72 2d 72 61 64 69 75 73 3a 20 31 30 70 78 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | der-radius:.10px;............... |
1c2e0 | 20 20 62 6f 72 64 65 72 2d 72 61 64 69 75 73 3a 20 31 30 70 78 3b 0a 20 20 20 20 20 20 20 20 20 | ..border-radius:.10px;.......... |
1c300 | 20 20 20 20 20 20 20 62 6f 72 64 65 72 3a 20 31 70 78 20 73 6f 6c 69 64 20 23 63 63 63 3b 0a 20 | .......border:.1px.solid.#ccc;.. |
1c320 | 20 20 20 20 20 20 20 20 20 20 20 7d 0a 45 4f 46 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 72 69 | ...........}.EOF;.....}......pri |
1c340 | 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 64 65 63 6f 72 61 74 65 28 24 63 6f 6e 74 65 6e 74 2c | vate.function.decorate($content, |
1c360 | 20 24 63 73 73 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 3c 3c 3c 45 | .$css).....{.........return.<<<E |
1c380 | 4f 46 0a 3c 21 44 4f 43 54 59 50 45 20 68 74 6d 6c 3e 0a 3c 68 74 6d 6c 3e 0a 20 20 20 20 3c 68 | OF.<!DOCTYPE.html>.<html>.....<h |
1c3a0 | 65 61 64 3e 0a 20 20 20 20 20 20 20 20 3c 6d 65 74 61 20 63 68 61 72 73 65 74 3d 22 7b 24 74 68 | ead>.........<meta.charset="{$th |
1c3c0 | 69 73 2d 3e 63 68 61 72 73 65 74 7d 22 20 2f 3e 0a 20 20 20 20 20 20 20 20 3c 6d 65 74 61 20 6e | is->charset}"./>.........<meta.n |
1c3e0 | 61 6d 65 3d 22 72 6f 62 6f 74 73 22 20 63 6f 6e 74 65 6e 74 3d 22 6e 6f 69 6e 64 65 78 2c 6e 6f | ame="robots".content="noindex,no |
1c400 | 66 6f 6c 6c 6f 77 22 20 2f 3e 0a 20 20 20 20 20 20 20 20 3c 73 74 79 6c 65 3e 0a 20 20 20 20 20 | follow"./>.........<style>...... |
1c420 | 20 20 20 20 20 20 20 2f 2a 20 43 6f 70 79 72 69 67 68 74 20 28 63 29 20 32 30 31 30 2c 20 59 61 | ......./*.Copyright.(c).2010,.Ya |
1c440 | 68 6f 6f 21 20 49 6e 63 2e 20 41 6c 6c 20 72 69 67 68 74 73 20 72 65 73 65 72 76 65 64 2e 20 43 | hoo!.Inc..All.rights.reserved..C |
1c460 | 6f 64 65 20 6c 69 63 65 6e 73 65 64 20 75 6e 64 65 72 20 74 68 65 20 42 53 44 20 4c 69 63 65 6e | ode.licensed.under.the.BSD.Licen |
1c480 | 73 65 3a 20 68 74 74 70 3a 2f 2f 64 65 76 65 6c 6f 70 65 72 2e 79 61 68 6f 6f 2e 63 6f 6d 2f 79 | se:.http://developer.yahoo.com/y |
1c4a0 | 75 69 2f 6c 69 63 65 6e 73 65 2e 68 74 6d 6c 20 2a 2f 0a 20 20 20 20 20 20 20 20 20 20 20 20 68 | ui/license.html.*/.............h |
1c4c0 | 74 6d 6c 7b 63 6f 6c 6f 72 3a 23 30 30 30 3b 62 61 63 6b 67 72 6f 75 6e 64 3a 23 46 46 46 3b 7d | tml{color:#000;background:#FFF;} |
1c4e0 | 62 6f 64 79 2c 64 69 76 2c 64 6c 2c 64 74 2c 64 64 2c 75 6c 2c 6f 6c 2c 6c 69 2c 68 31 2c 68 32 | body,div,dl,dt,dd,ul,ol,li,h1,h2 |
1c500 | 2c 68 33 2c 68 34 2c 68 35 2c 68 36 2c 70 72 65 2c 63 6f 64 65 2c 66 6f 72 6d 2c 66 69 65 6c 64 | ,h3,h4,h5,h6,pre,code,form,field |
1c520 | 73 65 74 2c 6c 65 67 65 6e 64 2c 69 6e 70 75 74 2c 74 65 78 74 61 72 65 61 2c 70 2c 62 6c 6f 63 | set,legend,input,textarea,p,bloc |
1c540 | 6b 71 75 6f 74 65 2c 74 68 2c 74 64 7b 6d 61 72 67 69 6e 3a 30 3b 70 61 64 64 69 6e 67 3a 30 3b | kquote,th,td{margin:0;padding:0; |
1c560 | 7d 74 61 62 6c 65 7b 62 6f 72 64 65 72 2d 63 6f 6c 6c 61 70 73 65 3a 63 6f 6c 6c 61 70 73 65 3b | }table{border-collapse:collapse; |
1c580 | 62 6f 72 64 65 72 2d 73 70 61 63 69 6e 67 3a 30 3b 7d 66 69 65 6c 64 73 65 74 2c 69 6d 67 7b 62 | border-spacing:0;}fieldset,img{b |
1c5a0 | 6f 72 64 65 72 3a 30 3b 7d 61 64 64 72 65 73 73 2c 63 61 70 74 69 6f 6e 2c 63 69 74 65 2c 63 6f | order:0;}address,caption,cite,co |
1c5c0 | 64 65 2c 64 66 6e 2c 65 6d 2c 73 74 72 6f 6e 67 2c 74 68 2c 76 61 72 7b 66 6f 6e 74 2d 73 74 79 | de,dfn,em,strong,th,var{font-sty |
1c5e0 | 6c 65 3a 6e 6f 72 6d 61 6c 3b 66 6f 6e 74 2d 77 65 69 67 68 74 3a 6e 6f 72 6d 61 6c 3b 7d 6c 69 | le:normal;font-weight:normal;}li |
1c600 | 7b 6c 69 73 74 2d 73 74 79 6c 65 3a 6e 6f 6e 65 3b 7d 63 61 70 74 69 6f 6e 2c 74 68 7b 74 65 78 | {list-style:none;}caption,th{tex |
1c620 | 74 2d 61 6c 69 67 6e 3a 6c 65 66 74 3b 7d 68 31 2c 68 32 2c 68 33 2c 68 34 2c 68 35 2c 68 36 7b | t-align:left;}h1,h2,h3,h4,h5,h6{ |
1c640 | 66 6f 6e 74 2d 73 69 7a 65 3a 31 30 30 25 3b 66 6f 6e 74 2d 77 65 69 67 68 74 3a 6e 6f 72 6d 61 | font-size:100%;font-weight:norma |
1c660 | 6c 3b 7d 71 3a 62 65 66 6f 72 65 2c 71 3a 61 66 74 65 72 7b 63 6f 6e 74 65 6e 74 3a 27 27 3b 7d | l;}q:before,q:after{content:'';} |
1c680 | 61 62 62 72 2c 61 63 72 6f 6e 79 6d 7b 62 6f 72 64 65 72 3a 30 3b 66 6f 6e 74 2d 76 61 72 69 61 | abbr,acronym{border:0;font-varia |
1c6a0 | 6e 74 3a 6e 6f 72 6d 61 6c 3b 7d 73 75 70 7b 76 65 72 74 69 63 61 6c 2d 61 6c 69 67 6e 3a 74 65 | nt:normal;}sup{vertical-align:te |
1c6c0 | 78 74 2d 74 6f 70 3b 7d 73 75 62 7b 76 65 72 74 69 63 61 6c 2d 61 6c 69 67 6e 3a 74 65 78 74 2d | xt-top;}sub{vertical-align:text- |
1c6e0 | 62 6f 74 74 6f 6d 3b 7d 69 6e 70 75 74 2c 74 65 78 74 61 72 65 61 2c 73 65 6c 65 63 74 7b 66 6f | bottom;}input,textarea,select{fo |
1c700 | 6e 74 2d 66 61 6d 69 6c 79 3a 69 6e 68 65 72 69 74 3b 66 6f 6e 74 2d 73 69 7a 65 3a 69 6e 68 65 | nt-family:inherit;font-size:inhe |
1c720 | 72 69 74 3b 66 6f 6e 74 2d 77 65 69 67 68 74 3a 69 6e 68 65 72 69 74 3b 7d 69 6e 70 75 74 2c 74 | rit;font-weight:inherit;}input,t |
1c740 | 65 78 74 61 72 65 61 2c 73 65 6c 65 63 74 7b 2a 66 6f 6e 74 2d 73 69 7a 65 3a 31 30 30 25 3b 7d | extarea,select{*font-size:100%;} |
1c760 | 6c 65 67 65 6e 64 7b 63 6f 6c 6f 72 3a 23 30 30 30 3b 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 | legend{color:#000;}............. |
1c780 | 20 68 74 6d 6c 20 7b 20 62 61 63 6b 67 72 6f 75 6e 64 3a 20 23 65 65 65 3b 20 70 61 64 64 69 6e | .html.{.background:.#eee;.paddin |
1c7a0 | 67 3a 20 31 30 70 78 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 6d 67 20 7b 20 62 6f 72 64 | g:.10px.}.............img.{.bord |
1c7c0 | 65 72 3a 20 30 3b 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 23 73 66 2d 72 65 73 65 74 63 6f | er:.0;.}.............#sf-resetco |
1c7e0 | 6e 74 65 6e 74 20 7b 20 77 69 64 74 68 3a 39 37 30 70 78 3b 20 6d 61 72 67 69 6e 3a 30 20 61 75 | ntent.{.width:970px;.margin:0.au |
1c800 | 74 6f 3b 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 63 73 73 0a 20 20 20 20 20 20 20 20 3c | to;.}.............$css.........< |
1c820 | 2f 73 74 79 6c 65 3e 0a 20 20 20 20 3c 2f 68 65 61 64 3e 0a 20 20 20 20 3c 62 6f 64 79 3e 0a 20 | /style>.....</head>.....<body>.. |
1c840 | 20 20 20 20 20 20 20 24 63 6f 6e 74 65 6e 74 0a 20 20 20 20 3c 2f 62 6f 64 79 3e 0a 3c 2f 68 74 | .......$content.....</body>.</ht |
1c860 | 6d 6c 3e 0a 45 4f 46 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 | ml>.EOF;.....}......private.func |
1c880 | 74 69 6f 6e 20 66 6f 72 6d 61 74 43 6c 61 73 73 28 24 63 6c 61 73 73 29 0a 20 20 20 20 7b 0a 20 | tion.formatClass($class).....{.. |
1c8a0 | 20 20 20 20 20 20 20 24 70 61 72 74 73 20 3d 20 65 78 70 6c 6f 64 65 28 27 5c 5c 27 2c 20 24 63 | .......$parts.=.explode('\\',.$c |
1c8c0 | 6c 61 73 73 29 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 70 72 69 6e 74 66 28 27 | lass);..........return.sprintf(' |
1c8e0 | 3c 61 62 62 72 20 74 69 74 6c 65 3d 22 25 73 22 3e 25 73 3c 2f 61 62 62 72 3e 27 2c 20 24 63 6c | <abbr.title="%s">%s</abbr>',.$cl |
1c900 | 61 73 73 2c 20 61 72 72 61 79 5f 70 6f 70 28 24 70 61 72 74 73 29 29 3b 0a 20 20 20 20 7d 0a 0a | ass,.array_pop($parts));.....}.. |
1c920 | 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 66 6f 72 6d 61 74 50 61 74 68 28 | ....private.function.formatPath( |
1c940 | 24 70 61 74 68 2c 20 24 6c 69 6e 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 70 61 74 | $path,.$line).....{.........$pat |
1c960 | 68 20 3d 20 24 74 68 69 73 2d 3e 65 73 63 61 70 65 48 74 6d 6c 28 24 70 61 74 68 29 3b 0a 20 20 | h.=.$this->escapeHtml($path);... |
1c980 | 20 20 20 20 20 20 24 66 69 6c 65 20 3d 20 70 72 65 67 5f 6d 61 74 63 68 28 27 23 5b 5e 2f 5c 5c | ......$file.=.preg_match('#[^/\\ |
1c9a0 | 5c 5c 5d 2a 24 23 27 2c 20 24 70 61 74 68 2c 20 24 66 69 6c 65 29 20 3f 20 24 66 69 6c 65 5b 30 | \\]*$#',.$path,.$file).?.$file[0 |
1c9c0 | 5d 20 3a 20 24 70 61 74 68 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 6c 69 6e 6b 46 6f 72 | ].:.$path;..........if.($linkFor |
1c9e0 | 6d 61 74 20 3d 20 24 74 68 69 73 2d 3e 66 69 6c 65 4c 69 6e 6b 46 6f 72 6d 61 74 29 20 7b 0a 20 | mat.=.$this->fileLinkFormat).{.. |
1ca00 | 20 20 20 20 20 20 20 20 20 20 20 24 6c 69 6e 6b 20 3d 20 73 74 72 74 72 28 24 74 68 69 73 2d 3e | ...........$link.=.strtr($this-> |
1ca20 | 65 73 63 61 70 65 48 74 6d 6c 28 24 6c 69 6e 6b 46 6f 72 6d 61 74 29 2c 20 61 72 72 61 79 28 27 | escapeHtml($linkFormat),.array(' |
1ca40 | 25 66 27 20 3d 3e 20 24 70 61 74 68 2c 20 27 25 6c 27 20 3d 3e 20 28 69 6e 74 29 20 24 6c 69 6e | %f'.=>.$path,.'%l'.=>.(int).$lin |
1ca60 | 65 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 70 72 69 6e 74 66 | e));..............return.sprintf |
1ca80 | 28 27 20 69 6e 20 3c 61 20 68 72 65 66 3d 22 25 73 22 20 74 69 74 6c 65 3d 22 47 6f 20 74 6f 20 | ('.in.<a.href="%s".title="Go.to. |
1caa0 | 73 6f 75 72 63 65 22 3e 25 73 20 6c 69 6e 65 20 25 64 3c 2f 61 3e 27 2c 20 24 6c 69 6e 6b 2c 20 | source">%s.line.%d</a>',.$link,. |
1cac0 | 24 66 69 6c 65 2c 20 24 6c 69 6e 65 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 | $file,.$line);.........}........ |
1cae0 | 20 20 72 65 74 75 72 6e 20 73 70 72 69 6e 74 66 28 27 20 69 6e 20 3c 61 20 74 69 74 6c 65 3d 22 | ..return.sprintf('.in.<a.title=" |
1cb00 | 25 73 20 6c 69 6e 65 20 25 33 24 64 22 20 6f 6e 64 62 6c 63 6c 69 63 6b 3d 22 76 61 72 20 66 3d | %s.line.%3$d".ondblclick="var.f= |
1cb20 | 74 68 69 73 2e 69 6e 6e 65 72 48 54 4d 4c 3b 74 68 69 73 2e 69 6e 6e 65 72 48 54 4d 4c 3d 74 68 | this.innerHTML;this.innerHTML=th |
1cb40 | 69 73 2e 74 69 74 6c 65 3b 74 68 69 73 2e 74 69 74 6c 65 3d 66 3b 22 3e 25 73 20 6c 69 6e 65 20 | is.title;this.title=f;">%s.line. |
1cb60 | 25 64 3c 2f 61 3e 27 2c 20 24 70 61 74 68 2c 20 24 66 69 6c 65 2c 20 24 6c 69 6e 65 29 3b 0a 20 | %d</a>',.$path,.$file,.$line);.. |
1cb80 | 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 46 6f 72 6d 61 74 73 20 61 6e 20 | ...}....../**......*.Formats.an. |
1cba0 | 61 72 72 61 79 20 61 73 20 61 20 73 74 72 69 6e 67 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a | array.as.a.string.......*......* |
1cbc0 | 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 24 61 72 67 73 20 54 68 65 20 61 72 67 75 6d 65 6e 74 | .@param.array.$args.The.argument |
1cbe0 | 20 61 72 72 61 79 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 | .array......*......*.@return.str |
1cc00 | 69 6e 67 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e | ing......*/.....private.function |
1cc20 | 20 66 6f 72 6d 61 74 41 72 67 73 28 61 72 72 61 79 20 24 61 72 67 73 29 0a 20 20 20 20 7b 0a 20 | .formatArgs(array.$args).....{.. |
1cc40 | 20 20 20 20 20 20 20 24 72 65 73 75 6c 74 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 | .......$result.=.array();....... |
1cc60 | 20 20 66 6f 72 65 61 63 68 20 28 24 61 72 67 73 20 61 73 20 24 6b 65 79 20 3d 3e 20 24 69 74 65 | ..foreach.($args.as.$key.=>.$ite |
1cc80 | 6d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 27 6f 62 6a 65 63 74 27 20 3d 3d | m).{.............if.('object'.== |
1cca0 | 3d 20 24 69 74 65 6d 5b 30 5d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 66 | =.$item[0]).{.................$f |
1ccc0 | 6f 72 6d 61 74 74 65 64 56 61 6c 75 65 20 3d 20 73 70 72 69 6e 74 66 28 27 3c 65 6d 3e 6f 62 6a | ormattedValue.=.sprintf('<em>obj |
1cce0 | 65 63 74 3c 2f 65 6d 3e 28 25 73 29 27 2c 20 24 74 68 69 73 2d 3e 66 6f 72 6d 61 74 43 6c 61 73 | ect</em>(%s)',.$this->formatClas |
1cd00 | 73 28 24 69 74 65 6d 5b 31 5d 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 | s($item[1]));.............}.else |
1cd20 | 69 66 20 28 27 61 72 72 61 79 27 20 3d 3d 3d 20 24 69 74 65 6d 5b 30 5d 29 20 7b 0a 20 20 20 20 | if.('array'.===.$item[0]).{..... |
1cd40 | 20 20 20 20 20 20 20 20 20 20 20 20 24 66 6f 72 6d 61 74 74 65 64 56 61 6c 75 65 20 3d 20 73 70 | ............$formattedValue.=.sp |
1cd60 | 72 69 6e 74 66 28 27 3c 65 6d 3e 61 72 72 61 79 3c 2f 65 6d 3e 28 25 73 29 27 2c 20 69 73 5f 61 | rintf('<em>array</em>(%s)',.is_a |
1cd80 | 72 72 61 79 28 24 69 74 65 6d 5b 31 5d 29 20 3f 20 24 74 68 69 73 2d 3e 66 6f 72 6d 61 74 41 72 | rray($item[1]).?.$this->formatAr |
1cda0 | 67 73 28 24 69 74 65 6d 5b 31 5d 29 20 3a 20 24 69 74 65 6d 5b 31 5d 29 3b 0a 20 20 20 20 20 20 | gs($item[1]).:.$item[1]);....... |
1cdc0 | 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 27 73 74 72 69 6e 67 27 20 3d 3d 3d 20 24 69 74 | ......}.elseif.('string'.===.$it |
1cde0 | 65 6d 5b 30 5d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 66 6f 72 6d 61 74 | em[0]).{.................$format |
1ce00 | 74 65 64 56 61 6c 75 65 20 3d 20 73 70 72 69 6e 74 66 28 22 27 25 73 27 22 2c 20 24 74 68 69 73 | tedValue.=.sprintf("'%s'",.$this |
1ce20 | 2d 3e 65 73 63 61 70 65 48 74 6d 6c 28 24 69 74 65 6d 5b 31 5d 29 29 3b 0a 20 20 20 20 20 20 20 | ->escapeHtml($item[1]));........ |
1ce40 | 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 27 6e 75 6c 6c 27 20 3d 3d 3d 20 24 69 74 65 6d 5b | .....}.elseif.('null'.===.$item[ |
1ce60 | 30 5d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 66 6f 72 6d 61 74 74 65 64 | 0]).{.................$formatted |
1ce80 | 56 61 6c 75 65 20 3d 20 27 3c 65 6d 3e 6e 75 6c 6c 3c 2f 65 6d 3e 27 3b 0a 20 20 20 20 20 20 20 | Value.=.'<em>null</em>';........ |
1cea0 | 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 27 62 6f 6f 6c 65 61 6e 27 20 3d 3d 3d 20 24 69 74 | .....}.elseif.('boolean'.===.$it |
1cec0 | 65 6d 5b 30 5d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 66 6f 72 6d 61 74 | em[0]).{.................$format |
1cee0 | 74 65 64 56 61 6c 75 65 20 3d 20 27 3c 65 6d 3e 27 2e 73 74 72 74 6f 6c 6f 77 65 72 28 76 61 72 | tedValue.=.'<em>'.strtolower(var |
1cf00 | 5f 65 78 70 6f 72 74 28 24 69 74 65 6d 5b 31 5d 2c 20 74 72 75 65 29 29 2e 27 3c 2f 65 6d 3e 27 | _export($item[1],.true)).'</em>' |
1cf20 | 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 27 72 65 73 6f 75 72 63 | ;.............}.elseif.('resourc |
1cf40 | 65 27 20 3d 3d 3d 20 24 69 74 65 6d 5b 30 5d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | e'.===.$item[0]).{.............. |
1cf60 | 20 20 20 24 66 6f 72 6d 61 74 74 65 64 56 61 6c 75 65 20 3d 20 27 3c 65 6d 3e 72 65 73 6f 75 72 | ...$formattedValue.=.'<em>resour |
1cf80 | 63 65 3c 2f 65 6d 3e 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 | ce</em>';.............}.else.{.. |
1cfa0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 66 6f 72 6d 61 74 74 65 64 56 61 6c 75 65 20 3d | ...............$formattedValue.= |
1cfc0 | 20 73 74 72 5f 72 65 70 6c 61 63 65 28 22 5c 6e 22 2c 20 27 27 2c 20 76 61 72 5f 65 78 70 6f 72 | .str_replace("\n",.'',.var_expor |
1cfe0 | 74 28 24 74 68 69 73 2d 3e 65 73 63 61 70 65 48 74 6d 6c 28 28 73 74 72 69 6e 67 29 20 24 69 74 | t($this->escapeHtml((string).$it |
1d000 | 65 6d 5b 31 5d 29 2c 20 74 72 75 65 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 | em[1]),.true));.............}... |
1d020 | 20 20 20 20 20 20 20 20 20 20 20 24 72 65 73 75 6c 74 5b 5d 20 3d 20 69 73 5f 69 6e 74 28 24 6b | ...........$result[].=.is_int($k |
1d040 | 65 79 29 20 3f 20 24 66 6f 72 6d 61 74 74 65 64 56 61 6c 75 65 20 3a 20 73 70 72 69 6e 74 66 28 | ey).?.$formattedValue.:.sprintf( |
1d060 | 22 27 25 73 27 20 3d 3e 20 25 73 22 2c 20 24 6b 65 79 2c 20 24 66 6f 72 6d 61 74 74 65 64 56 61 | "'%s'.=>.%s",.$key,.$formattedVa |
1d080 | 6c 75 65 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 | lue);.........}..........return. |
1d0a0 | 69 6d 70 6c 6f 64 65 28 27 2c 20 27 2c 20 24 72 65 73 75 6c 74 29 3b 0a 20 20 20 20 7d 0a 0a 20 | implode(',.',.$result);.....}... |
1d0c0 | 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 48 54 4d 4c 2d 65 6e 63 6f 64 65 73 20 61 20 73 74 72 | .../**......*.HTML-encodes.a.str |
1d0e0 | 69 6e 67 2e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f | ing.......*/.....private.functio |
1d100 | 6e 20 65 73 63 61 70 65 48 74 6d 6c 28 24 73 74 72 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 | n.escapeHtml($str).....{........ |
1d120 | 20 72 65 74 75 72 6e 20 68 74 6d 6c 73 70 65 63 69 61 6c 63 68 61 72 73 28 24 73 74 72 2c 20 45 | .return.htmlspecialchars($str,.E |
1d140 | 4e 54 5f 51 55 4f 54 45 53 20 7c 20 45 4e 54 5f 53 55 42 53 54 49 54 55 54 45 2c 20 24 74 68 69 | NT_QUOTES.|.ENT_SUBSTITUTE,.$thi |
1d160 | 73 2d 3e 63 68 61 72 73 65 74 29 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 | s->charset);.....}.}.<?php../*.. |
1d180 | 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f | *.This.file.is.part.of.the.Symfo |
1d1a0 | 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 | ny.package...*..*.(c).Fabien.Pot |
1d1c0 | 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 | encier.<fabien@symfony.com>..*.. |
1d1e0 | 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 | *.For.the.full.copyright.and.lic |
1d200 | 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 | ense.information,.please.view.th |
1d220 | 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 | e.LICENSE..*.file.that.was.distr |
1d240 | 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a | ibuted.with.this.source.code...* |
1d260 | 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 44 | /..namespace.Symfony\Component\D |
1d280 | 65 62 75 67 3b 0a 0a 2f 2a 2a 0a 20 2a 20 41 75 74 6f 6c 6f 61 64 65 72 20 63 68 65 63 6b 69 6e | ebug;../**..*.Autoloader.checkin |
1d2a0 | 67 20 69 66 20 74 68 65 20 63 6c 61 73 73 20 69 73 20 72 65 61 6c 6c 79 20 64 65 66 69 6e 65 64 | g.if.the.class.is.really.defined |
1d2c0 | 20 69 6e 20 74 68 65 20 66 69 6c 65 20 66 6f 75 6e 64 2e 0a 20 2a 0a 20 2a 20 54 68 65 20 43 6c | .in.the.file.found...*..*.The.Cl |
1d2e0 | 61 73 73 4c 6f 61 64 65 72 20 77 69 6c 6c 20 77 72 61 70 20 61 6c 6c 20 72 65 67 69 73 74 65 72 | assLoader.will.wrap.all.register |
1d300 | 65 64 20 61 75 74 6f 6c 6f 61 64 65 72 73 0a 20 2a 20 61 6e 64 20 77 69 6c 6c 20 74 68 72 6f 77 | ed.autoloaders..*.and.will.throw |
1d320 | 20 61 6e 20 65 78 63 65 70 74 69 6f 6e 20 69 66 20 61 20 66 69 6c 65 20 69 73 20 66 6f 75 6e 64 | .an.exception.if.a.file.is.found |
1d340 | 20 62 75 74 20 64 6f 65 73 0a 20 2a 20 6e 6f 74 20 64 65 63 6c 61 72 65 20 74 68 65 20 63 6c 61 | .but.does..*.not.declare.the.cla |
1d360 | 73 73 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 | ss...*..*.@author.Fabien.Potenci |
1d380 | 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 20 40 61 75 74 68 | er.<fabien@symfony.com>..*.@auth |
1d3a0 | 6f 72 20 43 68 72 69 73 74 6f 70 68 65 20 43 6f 65 76 6f 65 74 20 3c 73 74 6f 66 40 6e 6f 74 6b | or.Christophe.Coevoet.<stof@notk |
1d3c0 | 2e 6f 72 67 3e 0a 20 2a 20 40 61 75 74 68 6f 72 20 4e 69 63 6f 6c 61 73 20 47 72 65 6b 61 73 20 | .org>..*.@author.Nicolas.Grekas. |
1d3e0 | 3c 70 40 74 63 68 77 6f 72 6b 2e 63 6f 6d 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 44 65 62 75 67 43 | <p@tchwork.com>..*/.class.DebugC |
1d400 | 6c 61 73 73 4c 6f 61 64 65 72 0a 7b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 63 6c 61 73 73 4c | lassLoader.{.....private.$classL |
1d420 | 6f 61 64 65 72 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 69 73 46 69 6e 64 65 72 3b 0a 20 20 | oader;.....private.$isFinder;... |
1d440 | 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 24 63 61 73 65 43 68 65 63 6b 3b 0a 20 20 20 | ..private.static.$caseCheck;.... |
1d460 | 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 24 64 65 70 72 65 63 61 74 65 64 20 3d 20 61 72 | .private.static.$deprecated.=.ar |
1d480 | 72 61 79 28 29 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 24 70 68 70 37 52 | ray();.....private.static.$php7R |
1d4a0 | 65 73 65 72 76 65 64 20 3d 20 61 72 72 61 79 28 27 69 6e 74 27 2c 20 27 66 6c 6f 61 74 27 2c 20 | eserved.=.array('int',.'float',. |
1d4c0 | 27 62 6f 6f 6c 27 2c 20 27 73 74 72 69 6e 67 27 2c 20 27 74 72 75 65 27 2c 20 27 66 61 6c 73 65 | 'bool',.'string',.'true',.'false |
1d4e0 | 27 2c 20 27 6e 75 6c 6c 27 29 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 24 | ',.'null');.....private.static.$ |
1d500 | 64 61 72 77 69 6e 43 61 63 68 65 20 3d 20 61 72 72 61 79 28 27 2f 27 20 3d 3e 20 61 72 72 61 79 | darwinCache.=.array('/'.=>.array |
1d520 | 28 27 2f 27 2c 20 61 72 72 61 79 28 29 29 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a | ('/',.array()));....../**......* |
1d540 | 20 43 6f 6e 73 74 72 75 63 74 6f 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 | .Constructor.......*......*.@par |
1d560 | 61 6d 20 63 61 6c 6c 61 62 6c 65 20 24 63 6c 61 73 73 4c 6f 61 64 65 72 20 41 20 63 6c 61 73 73 | am.callable.$classLoader.A.class |
1d580 | 20 6c 6f 61 64 65 72 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 | .loader......*/.....public.funct |
1d5a0 | 69 6f 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 74 28 63 61 6c 6c 61 62 6c 65 20 24 63 6c 61 73 73 4c | ion.__construct(callable.$classL |
1d5c0 | 6f 61 64 65 72 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 63 6c 61 73 | oader).....{.........$this->clas |
1d5e0 | 73 4c 6f 61 64 65 72 20 3d 20 24 63 6c 61 73 73 4c 6f 61 64 65 72 3b 0a 20 20 20 20 20 20 20 20 | sLoader.=.$classLoader;......... |
1d600 | 24 74 68 69 73 2d 3e 69 73 46 69 6e 64 65 72 20 3d 20 69 73 5f 61 72 72 61 79 28 24 63 6c 61 73 | $this->isFinder.=.is_array($clas |
1d620 | 73 4c 6f 61 64 65 72 29 20 26 26 20 6d 65 74 68 6f 64 5f 65 78 69 73 74 73 28 24 63 6c 61 73 73 | sLoader).&&.method_exists($class |
1d640 | 4c 6f 61 64 65 72 5b 30 5d 2c 20 27 66 69 6e 64 46 69 6c 65 27 29 3b 0a 0a 20 20 20 20 20 20 20 | Loader[0],.'findFile');......... |
1d660 | 20 69 66 20 28 21 69 73 73 65 74 28 73 65 6c 66 3a 3a 24 63 61 73 65 43 68 65 63 6b 29 29 20 7b | .if.(!isset(self::$caseCheck)).{ |
1d680 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 66 69 6c 65 20 3d 20 66 69 6c 65 5f 65 78 69 73 74 73 | .............$file.=.file_exists |
1d6a0 | 28 5f 5f 46 49 4c 45 5f 5f 29 20 3f 20 5f 5f 46 49 4c 45 5f 5f 20 3a 20 72 74 72 69 6d 28 72 65 | (__FILE__).?.__FILE__.:.rtrim(re |
1d6c0 | 61 6c 70 61 74 68 28 27 2e 27 29 2c 20 44 49 52 45 43 54 4f 52 59 5f 53 45 50 41 52 41 54 4f 52 | alpath('.'),.DIRECTORY_SEPARATOR |
1d6e0 | 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 69 20 3d 20 73 74 72 72 70 6f 73 28 24 66 69 6c | );.............$i.=.strrpos($fil |
1d700 | 65 2c 20 44 49 52 45 43 54 4f 52 59 5f 53 45 50 41 52 41 54 4f 52 29 3b 0a 20 20 20 20 20 20 20 | e,.DIRECTORY_SEPARATOR);........ |
1d720 | 20 20 20 20 20 24 64 69 72 20 3d 20 73 75 62 73 74 72 28 24 66 69 6c 65 2c 20 30 2c 20 31 20 2b | .....$dir.=.substr($file,.0,.1.+ |
1d740 | 20 24 69 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 66 69 6c 65 20 3d 20 73 75 62 73 74 72 | .$i);.............$file.=.substr |
1d760 | 28 24 66 69 6c 65 2c 20 31 20 2b 20 24 69 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 65 | ($file,.1.+.$i);.............$te |
1d780 | 73 74 20 3d 20 73 74 72 74 6f 75 70 70 65 72 28 24 66 69 6c 65 29 20 3d 3d 3d 20 24 66 69 6c 65 | st.=.strtoupper($file).===.$file |
1d7a0 | 20 3f 20 73 74 72 74 6f 6c 6f 77 65 72 28 24 66 69 6c 65 29 20 3a 20 73 74 72 74 6f 75 70 70 65 | .?.strtolower($file).:.strtouppe |
1d7c0 | 72 28 24 66 69 6c 65 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 65 73 74 20 3d 20 72 65 | r($file);.............$test.=.re |
1d7e0 | 61 6c 70 61 74 68 28 24 64 69 72 2e 24 74 65 73 74 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 | alpath($dir.$test);............. |
1d800 | 20 69 66 20 28 66 61 6c 73 65 20 3d 3d 3d 20 24 74 65 73 74 20 7c 7c 20 66 61 6c 73 65 20 3d 3d | .if.(false.===.$test.||.false.== |
1d820 | 3d 20 24 69 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 66 69 6c 65 73 | =.$i).{.................//.files |
1d840 | 79 73 74 65 6d 20 69 73 20 63 61 73 65 20 73 65 6e 73 69 74 69 76 65 0a 20 20 20 20 20 20 20 20 | ystem.is.case.sensitive......... |
1d860 | 20 20 20 20 20 20 20 20 73 65 6c 66 3a 3a 24 63 61 73 65 43 68 65 63 6b 20 3d 20 30 3b 0a 20 20 | ........self::$caseCheck.=.0;... |
1d880 | 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 73 75 62 73 74 72 28 24 74 65 73 74 | ..........}.elseif.(substr($test |
1d8a0 | 2c 20 2d 73 74 72 6c 65 6e 28 24 66 69 6c 65 29 29 20 3d 3d 3d 20 24 66 69 6c 65 29 20 7b 0a 20 | ,.-strlen($file)).===.$file).{.. |
1d8c0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 66 69 6c 65 73 79 73 74 65 6d 20 69 73 20 | ...............//.filesystem.is. |
1d8e0 | 63 61 73 65 20 69 6e 73 65 6e 73 69 74 69 76 65 20 61 6e 64 20 72 65 61 6c 70 61 74 68 28 29 20 | case.insensitive.and.realpath(). |
1d900 | 6e 6f 72 6d 61 6c 69 7a 65 73 20 74 68 65 20 63 61 73 65 20 6f 66 20 63 68 61 72 61 63 74 65 72 | normalizes.the.case.of.character |
1d920 | 73 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 73 65 6c 66 3a 3a 24 63 61 73 65 43 68 65 | s.................self::$caseChe |
1d940 | 63 6b 20 3d 20 31 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 66 61 | ck.=.1;.............}.elseif.(fa |
1d960 | 6c 73 65 20 21 3d 3d 20 73 74 72 69 70 6f 73 28 50 48 50 5f 4f 53 2c 20 27 64 61 72 77 69 6e 27 | lse.!==.stripos(PHP_OS,.'darwin' |
1d980 | 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 6f 6e 20 4d 61 63 4f 53 | )).{.................//.on.MacOS |
1d9a0 | 58 2c 20 48 46 53 2b 20 69 73 20 63 61 73 65 20 69 6e 73 65 6e 73 69 74 69 76 65 20 62 75 74 20 | X,.HFS+.is.case.insensitive.but. |
1d9c0 | 72 65 61 6c 70 61 74 68 28 29 20 64 6f 65 73 6e 27 74 20 6e 6f 72 6d 61 6c 69 7a 65 20 74 68 65 | realpath().doesn't.normalize.the |
1d9e0 | 20 63 61 73 65 20 6f 66 20 63 68 61 72 61 63 74 65 72 73 0a 20 20 20 20 20 20 20 20 20 20 20 20 | .case.of.characters............. |
1da00 | 20 20 20 20 73 65 6c 66 3a 3a 24 63 61 73 65 43 68 65 63 6b 20 3d 20 32 3b 0a 20 20 20 20 20 20 | ....self::$caseCheck.=.2;....... |
1da20 | 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2f | ......}.else.{................./ |
1da40 | 2f 20 66 69 6c 65 73 79 73 74 65 6d 20 63 61 73 65 20 63 68 65 63 6b 73 20 66 61 69 6c 65 64 2c | /.filesystem.case.checks.failed, |
1da60 | 20 66 61 6c 6c 62 61 63 6b 20 74 6f 20 64 69 73 61 62 6c 69 6e 67 20 74 68 65 6d 0a 20 20 20 20 | .fallback.to.disabling.them..... |
1da80 | 20 20 20 20 20 20 20 20 20 20 20 20 73 65 6c 66 3a 3a 24 63 61 73 65 43 68 65 63 6b 20 3d 20 30 | ............self::$caseCheck.=.0 |
1daa0 | 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a | ;.............}.........}.....}. |
1dac0 | 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 77 72 61 70 70 65 64 | ...../**......*.Gets.the.wrapped |
1dae0 | 20 63 6c 61 73 73 20 6c 6f 61 64 65 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 | .class.loader.......*......*.@re |
1db00 | 74 75 72 6e 20 63 61 6c 6c 61 62 6c 65 20 54 68 65 20 77 72 61 70 70 65 64 20 63 6c 61 73 73 20 | turn.callable.The.wrapped.class. |
1db20 | 6c 6f 61 64 65 72 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 | loader......*/.....public.functi |
1db40 | 6f 6e 20 67 65 74 43 6c 61 73 73 4c 6f 61 64 65 72 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 | on.getClassLoader().....{....... |
1db60 | 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 63 6c 61 73 73 4c 6f 61 64 65 72 3b 0a 20 20 20 | ..return.$this->classLoader;.... |
1db80 | 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 57 72 61 70 73 20 61 6c 6c 20 61 75 74 | .}....../**......*.Wraps.all.aut |
1dba0 | 6f 6c 6f 61 64 65 72 73 2e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 | oloaders.......*/.....public.sta |
1dbc0 | 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 65 6e 61 62 6c 65 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 | tic.function.enable().....{..... |
1dbe0 | 20 20 20 20 2f 2f 20 45 6e 73 75 72 65 73 20 77 65 20 64 6f 6e 27 74 20 68 69 74 20 68 74 74 70 | ....//.Ensures.we.don't.hit.http |
1dc00 | 73 3a 2f 2f 62 75 67 73 2e 70 68 70 2e 6e 65 74 2f 34 32 30 39 38 0a 20 20 20 20 20 20 20 20 63 | s://bugs.php.net/42098.........c |
1dc20 | 6c 61 73 73 5f 65 78 69 73 74 73 28 27 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 44 | lass_exists('Symfony\Component\D |
1dc40 | 65 62 75 67 5c 45 72 72 6f 72 48 61 6e 64 6c 65 72 27 29 3b 0a 20 20 20 20 20 20 20 20 63 6c 61 | ebug\ErrorHandler');.........cla |
1dc60 | 73 73 5f 65 78 69 73 74 73 28 27 50 73 72 5c 4c 6f 67 5c 4c 6f 67 4c 65 76 65 6c 27 29 3b 0a 0a | ss_exists('Psr\Log\LogLevel');.. |
1dc80 | 20 20 20 20 20 20 20 20 69 66 20 28 21 69 73 5f 61 72 72 61 79 28 24 66 75 6e 63 74 69 6f 6e 73 | ........if.(!is_array($functions |
1dca0 | 20 3d 20 73 70 6c 5f 61 75 74 6f 6c 6f 61 64 5f 66 75 6e 63 74 69 6f 6e 73 28 29 29 29 20 7b 0a | .=.spl_autoload_functions())).{. |
1dcc0 | 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 | ............return;.........}... |
1dce0 | 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 66 75 6e 63 74 69 6f 6e 73 20 61 73 20 24 66 | .......foreach.($functions.as.$f |
1dd00 | 75 6e 63 74 69 6f 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 73 70 6c 5f 61 75 74 6f 6c | unction).{.............spl_autol |
1dd20 | 6f 61 64 5f 75 6e 72 65 67 69 73 74 65 72 28 24 66 75 6e 63 74 69 6f 6e 29 3b 0a 20 20 20 20 20 | oad_unregister($function);...... |
1dd40 | 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 66 75 6e 63 74 69 6f 6e | ...}..........foreach.($function |
1dd60 | 73 20 61 73 20 24 66 75 6e 63 74 69 6f 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 | s.as.$function).{.............if |
1dd80 | 20 28 21 69 73 5f 61 72 72 61 79 28 24 66 75 6e 63 74 69 6f 6e 29 20 7c 7c 20 21 24 66 75 6e 63 | .(!is_array($function).||.!$func |
1dda0 | 74 69 6f 6e 5b 30 5d 20 69 6e 73 74 61 6e 63 65 6f 66 20 73 65 6c 66 29 20 7b 0a 20 20 20 20 20 | tion[0].instanceof.self).{...... |
1ddc0 | 20 20 20 20 20 20 20 20 20 20 20 24 66 75 6e 63 74 69 6f 6e 20 3d 20 61 72 72 61 79 28 6e 65 77 | ...........$function.=.array(new |
1dde0 | 20 73 74 61 74 69 63 28 24 66 75 6e 63 74 69 6f 6e 29 2c 20 27 6c 6f 61 64 43 6c 61 73 73 27 29 | .static($function),.'loadClass') |
1de00 | 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 73 70 6c | ;.............}..............spl |
1de20 | 5f 61 75 74 6f 6c 6f 61 64 5f 72 65 67 69 73 74 65 72 28 24 66 75 6e 63 74 69 6f 6e 29 3b 0a 20 | _autoload_register($function);.. |
1de40 | 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 44 | .......}.....}....../**......*.D |
1de60 | 69 73 61 62 6c 65 73 20 74 68 65 20 77 72 61 70 70 69 6e 67 2e 0a 20 20 20 20 20 2a 2f 0a 20 20 | isables.the.wrapping.......*/... |
1de80 | 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 64 69 73 61 62 6c 65 | ..public.static.function.disable |
1dea0 | 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 69 73 5f 61 72 72 61 79 28 24 | ().....{.........if.(!is_array($ |
1dec0 | 66 75 6e 63 74 69 6f 6e 73 20 3d 20 73 70 6c 5f 61 75 74 6f 6c 6f 61 64 5f 66 75 6e 63 74 69 6f | functions.=.spl_autoload_functio |
1dee0 | 6e 73 28 29 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 3b 0a 20 20 20 | ns())).{.............return;.... |
1df00 | 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 66 75 6e 63 74 69 | .....}..........foreach.($functi |
1df20 | 6f 6e 73 20 61 73 20 24 66 75 6e 63 74 69 6f 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ons.as.$function).{............. |
1df40 | 73 70 6c 5f 61 75 74 6f 6c 6f 61 64 5f 75 6e 72 65 67 69 73 74 65 72 28 24 66 75 6e 63 74 69 6f | spl_autoload_unregister($functio |
1df60 | 6e 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 | n);.........}..........foreach.( |
1df80 | 24 66 75 6e 63 74 69 6f 6e 73 20 61 73 20 24 66 75 6e 63 74 69 6f 6e 29 20 7b 0a 20 20 20 20 20 | $functions.as.$function).{...... |
1dfa0 | 20 20 20 20 20 20 20 69 66 20 28 69 73 5f 61 72 72 61 79 28 24 66 75 6e 63 74 69 6f 6e 29 20 26 | .......if.(is_array($function).& |
1dfc0 | 26 20 24 66 75 6e 63 74 69 6f 6e 5b 30 5d 20 69 6e 73 74 61 6e 63 65 6f 66 20 73 65 6c 66 29 20 | &.$function[0].instanceof.self). |
1dfe0 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 66 75 6e 63 74 69 6f 6e 20 3d 20 24 66 | {.................$function.=.$f |
1e000 | 75 6e 63 74 69 6f 6e 5b 30 5d 2d 3e 67 65 74 43 6c 61 73 73 4c 6f 61 64 65 72 28 29 3b 0a 20 20 | unction[0]->getClassLoader();... |
1e020 | 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 73 70 6c 5f 61 75 74 | ..........}..............spl_aut |
1e040 | 6f 6c 6f 61 64 5f 72 65 67 69 73 74 65 72 28 24 66 75 6e 63 74 69 6f 6e 29 3b 0a 20 20 20 20 20 | oload_register($function);...... |
1e060 | 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 4c 6f 61 64 73 | ...}.....}....../**......*.Loads |
1e080 | 20 74 68 65 20 67 69 76 65 6e 20 63 6c 61 73 73 20 6f 72 20 69 6e 74 65 72 66 61 63 65 2e 0a 20 | .the.given.class.or.interface... |
1e0a0 | 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 63 6c 61 73 | ....*......*.@param.string.$clas |
1e0c0 | 73 20 54 68 65 20 6e 61 6d 65 20 6f 66 20 74 68 65 20 63 6c 61 73 73 0a 20 20 20 20 20 2a 0a 20 | s.The.name.of.the.class......*.. |
1e0e0 | 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 62 6f 6f 6c 7c 6e 75 6c 6c 20 54 72 75 65 2c 20 69 66 | ....*.@return.bool|null.True,.if |
1e100 | 20 6c 6f 61 64 65 64 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 5c 52 | .loaded......*......*.@throws.\R |
1e120 | 75 6e 74 69 6d 65 45 78 63 65 70 74 69 6f 6e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c | untimeException......*/.....publ |
1e140 | 69 63 20 66 75 6e 63 74 69 6f 6e 20 6c 6f 61 64 43 6c 61 73 73 28 24 63 6c 61 73 73 29 0a 20 20 | ic.function.loadClass($class)... |
1e160 | 20 20 7b 0a 20 20 20 20 20 20 20 20 45 72 72 6f 72 48 61 6e 64 6c 65 72 3a 3a 73 74 61 63 6b 45 | ..{.........ErrorHandler::stackE |
1e180 | 72 72 6f 72 73 28 29 3b 0a 0a 20 20 20 20 20 20 20 20 74 72 79 20 7b 0a 20 20 20 20 20 20 20 20 | rrors();..........try.{......... |
1e1a0 | 20 20 20 20 69 66 20 28 24 74 68 69 73 2d 3e 69 73 46 69 6e 64 65 72 29 20 7b 0a 20 20 20 20 20 | ....if.($this->isFinder).{...... |
1e1c0 | 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 66 69 6c 65 20 3d 20 24 74 68 69 73 2d 3e 63 6c | ...........if.($file.=.$this->cl |
1e1e0 | 61 73 73 4c 6f 61 64 65 72 5b 30 5d 2d 3e 66 69 6e 64 46 69 6c 65 28 24 63 6c 61 73 73 29 29 20 | assLoader[0]->findFile($class)). |
1e200 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 71 75 69 72 65 5f 6f 6e | {.....................require_on |
1e220 | 63 65 20 24 66 69 6c 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 | ce.$file;.................}..... |
1e240 | 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ........}.else.{................ |
1e260 | 20 63 61 6c 6c 5f 75 73 65 72 5f 66 75 6e 63 28 24 74 68 69 73 2d 3e 63 6c 61 73 73 4c 6f 61 64 | .call_user_func($this->classLoad |
1e280 | 65 72 2c 20 24 63 6c 61 73 73 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 66 69 | er,.$class);.................$fi |
1e2a0 | 6c 65 20 3d 20 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 | le.=.false;.............}....... |
1e2c0 | 20 20 7d 20 66 69 6e 61 6c 6c 79 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 45 72 72 6f 72 48 | ..}.finally.{.............ErrorH |
1e2e0 | 61 6e 64 6c 65 72 3a 3a 75 6e 73 74 61 63 6b 45 72 72 6f 72 73 28 29 3b 0a 20 20 20 20 20 20 20 | andler::unstackErrors();........ |
1e300 | 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 65 78 69 73 74 73 20 3d 20 63 6c 61 73 73 5f 65 78 69 73 | .}..........$exists.=.class_exis |
1e320 | 74 73 28 24 63 6c 61 73 73 2c 20 66 61 6c 73 65 29 20 7c 7c 20 69 6e 74 65 72 66 61 63 65 5f 65 | ts($class,.false).||.interface_e |
1e340 | 78 69 73 74 73 28 24 63 6c 61 73 73 2c 20 66 61 6c 73 65 29 20 7c 7c 20 74 72 61 69 74 5f 65 78 | xists($class,.false).||.trait_ex |
1e360 | 69 73 74 73 28 24 63 6c 61 73 73 2c 20 66 61 6c 73 65 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 | ists($class,.false);..........if |
1e380 | 20 28 27 5c 5c 27 20 3d 3d 3d 20 24 63 6c 61 73 73 5b 30 5d 29 20 7b 0a 20 20 20 20 20 20 20 20 | .('\\'.===.$class[0]).{......... |
1e3a0 | 20 20 20 20 24 63 6c 61 73 73 20 3d 20 73 75 62 73 74 72 28 24 63 6c 61 73 73 2c 20 31 29 3b 0a | ....$class.=.substr($class,.1);. |
1e3c0 | 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 65 78 69 73 74 73 29 20 | ........}..........if.($exists). |
1e3e0 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 72 65 66 6c 20 3d 20 6e 65 77 20 5c 52 65 66 6c 65 | {.............$refl.=.new.\Refle |
1e400 | 63 74 69 6f 6e 43 6c 61 73 73 28 24 63 6c 61 73 73 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ctionClass($class);............. |
1e420 | 24 6e 61 6d 65 20 3d 20 24 72 65 66 6c 2d 3e 67 65 74 4e 61 6d 65 28 29 3b 0a 0a 20 20 20 20 20 | $name.=.$refl->getName();....... |
1e440 | 20 20 20 20 20 20 20 69 66 20 28 24 6e 61 6d 65 20 21 3d 3d 20 24 63 6c 61 73 73 20 26 26 20 30 | .......if.($name.!==.$class.&&.0 |
1e460 | 20 3d 3d 3d 20 73 74 72 63 61 73 65 63 6d 70 28 24 6e 61 6d 65 2c 20 24 63 6c 61 73 73 29 29 20 | .===.strcasecmp($name,.$class)). |
1e480 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 5c 52 75 6e | {.................throw.new.\Run |
1e4a0 | 74 69 6d 65 45 78 63 65 70 74 69 6f 6e 28 73 70 72 69 6e 74 66 28 27 43 61 73 65 20 6d 69 73 6d | timeException(sprintf('Case.mism |
1e4c0 | 61 74 63 68 20 62 65 74 77 65 65 6e 20 6c 6f 61 64 65 64 20 61 6e 64 20 64 65 63 6c 61 72 65 64 | atch.between.loaded.and.declared |
1e4e0 | 20 63 6c 61 73 73 20 6e 61 6d 65 73 3a 20 25 73 20 76 73 20 25 73 27 2c 20 24 63 6c 61 73 73 2c | .class.names:.%s.vs.%s',.$class, |
1e500 | 20 24 6e 61 6d 65 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 | .$name));.............}......... |
1e520 | 20 20 20 20 20 69 66 20 28 69 6e 5f 61 72 72 61 79 28 73 74 72 74 6f 6c 6f 77 65 72 28 24 72 65 | .....if.(in_array(strtolower($re |
1e540 | 66 6c 2d 3e 67 65 74 53 68 6f 72 74 4e 61 6d 65 28 29 29 2c 20 73 65 6c 66 3a 3a 24 70 68 70 37 | fl->getShortName()),.self::$php7 |
1e560 | 52 65 73 65 72 76 65 64 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 40 74 72 | Reserved)).{.................@tr |
1e580 | 69 67 67 65 72 5f 65 72 72 6f 72 28 73 70 72 69 6e 74 66 28 27 25 73 20 75 73 65 73 20 61 20 72 | igger_error(sprintf('%s.uses.a.r |
1e5a0 | 65 73 65 72 76 65 64 20 63 6c 61 73 73 20 6e 61 6d 65 20 28 25 73 29 20 74 68 61 74 20 77 69 6c | eserved.class.name.(%s).that.wil |
1e5c0 | 6c 20 62 72 65 61 6b 20 6f 6e 20 50 48 50 20 37 20 61 6e 64 20 68 69 67 68 65 72 27 2c 20 24 6e | l.break.on.PHP.7.and.higher',.$n |
1e5e0 | 61 6d 65 2c 20 24 72 65 66 6c 2d 3e 67 65 74 53 68 6f 72 74 4e 61 6d 65 28 29 29 2c 20 45 5f 55 | ame,.$refl->getShortName()),.E_U |
1e600 | 53 45 52 5f 44 45 50 52 45 43 41 54 45 44 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 | SER_DEPRECATED);.............}.e |
1e620 | 6c 73 65 69 66 20 28 70 72 65 67 5f 6d 61 74 63 68 28 27 23 5c 6e 20 5c 2a 20 40 64 65 70 72 65 | lseif.(preg_match('#\n.\*.@depre |
1e640 | 63 61 74 65 64 20 28 2e 2a 3f 29 5c 72 3f 5c 6e 20 5c 2a 28 3f 3a 20 40 7c 2f 24 29 23 73 27 2c | cated.(.*?)\r?\n.\*(?:.@|/$)#s', |
1e660 | 20 24 72 65 66 6c 2d 3e 67 65 74 44 6f 63 43 6f 6d 6d 65 6e 74 28 29 2c 20 24 6e 6f 74 69 63 65 | .$refl->getDocComment(),.$notice |
1e680 | 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 73 65 6c 66 3a 3a 24 64 65 70 72 | )).{.................self::$depr |
1e6a0 | 65 63 61 74 65 64 5b 24 6e 61 6d 65 5d 20 3d 20 70 72 65 67 5f 72 65 70 6c 61 63 65 28 27 23 5c | ecated[$name].=.preg_replace('#\ |
1e6c0 | 73 2a 5c 72 3f 5c 6e 20 5c 2a 20 2b 23 27 2c 20 27 20 27 2c 20 24 6e 6f 74 69 63 65 5b 31 5d 29 | s*\r?\n.\*.+#',.'.',.$notice[1]) |
1e6e0 | 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 | ;.............}.else.{.......... |
1e700 | 20 20 20 20 20 20 20 69 66 20 28 32 20 3e 20 24 6c 65 6e 20 3d 20 31 20 2b 20 28 73 74 72 70 6f | .......if.(2.>.$len.=.1.+.(strpo |
1e720 | 73 28 24 6e 61 6d 65 2c 20 27 5c 5c 27 2c 20 31 20 2b 20 73 74 72 70 6f 73 28 24 6e 61 6d 65 2c | s($name,.'\\',.1.+.strpos($name, |
1e740 | 20 27 5c 5c 27 29 29 20 3f 3a 20 73 74 72 70 6f 73 28 24 6e 61 6d 65 2c 20 27 5f 27 29 29 29 20 | .'\\')).?:.strpos($name,.'_'))). |
1e760 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 65 6e 20 3d 20 30 3b 0a | {.....................$len.=.0;. |
1e780 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6e 73 20 3d 20 27 27 3b 0a 20 20 | ....................$ns.=.'';... |
1e7a0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 | ..............}.else.{.......... |
1e7c0 | 20 20 20 20 20 20 20 20 20 20 20 73 77 69 74 63 68 20 28 24 6e 73 20 3d 20 73 75 62 73 74 72 28 | ...........switch.($ns.=.substr( |
1e7e0 | 24 6e 61 6d 65 2c 20 30 2c 20 24 6c 65 6e 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | $name,.0,.$len)).{.............. |
1e800 | 20 20 20 20 20 20 20 20 20 20 20 63 61 73 65 20 27 53 79 6d 66 6f 6e 79 5c 42 72 69 64 67 65 5c | ...........case.'Symfony\Bridge\ |
1e820 | 5c 27 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 63 61 73 65 | \':.........................case |
1e840 | 20 27 53 79 6d 66 6f 6e 79 5c 42 75 6e 64 6c 65 5c 5c 27 3a 0a 20 20 20 20 20 20 20 20 20 20 20 | .'Symfony\Bundle\\':............ |
1e860 | 20 20 20 20 20 20 20 20 20 20 20 20 20 63 61 73 65 20 27 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f | .............case.'Symfony\Compo |
1e880 | 6e 65 6e 74 5c 5c 27 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | nent\\':........................ |
1e8a0 | 20 20 20 20 20 24 6e 73 20 3d 20 27 53 79 6d 66 6f 6e 79 5c 5c 27 3b 0a 20 20 20 20 20 20 20 20 | .....$ns.=.'Symfony\\';......... |
1e8c0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 65 6e 20 3d 20 73 74 72 6c 65 | ....................$len.=.strle |
1e8e0 | 6e 28 24 6e 73 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | n($ns);......................... |
1e900 | 20 20 20 20 62 72 65 61 6b 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d | ....break;.....................} |
1e920 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | .................}.............. |
1e940 | 20 20 20 24 70 61 72 65 6e 74 20 3d 20 67 65 74 5f 70 61 72 65 6e 74 5f 63 6c 61 73 73 28 24 63 | ...$parent.=.get_parent_class($c |
1e960 | 6c 61 73 73 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 21 24 70 61 | lass);..................if.(!$pa |
1e980 | 72 65 6e 74 20 7c 7c 20 73 74 72 6e 63 6d 70 28 24 6e 73 2c 20 24 70 61 72 65 6e 74 2c 20 24 6c | rent.||.strncmp($ns,.$parent,.$l |
1e9a0 | 65 6e 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 | en)).{.....................if.($ |
1e9c0 | 70 61 72 65 6e 74 20 26 26 20 69 73 73 65 74 28 73 65 6c 66 3a 3a 24 64 65 70 72 65 63 61 74 65 | parent.&&.isset(self::$deprecate |
1e9e0 | 64 5b 24 70 61 72 65 6e 74 5d 29 20 26 26 20 73 74 72 6e 63 6d 70 28 24 6e 73 2c 20 24 70 61 72 | d[$parent]).&&.strncmp($ns,.$par |
1ea00 | 65 6e 74 2c 20 24 6c 65 6e 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ent,.$len)).{................... |
1ea20 | 20 20 20 20 20 20 40 74 72 69 67 67 65 72 5f 65 72 72 6f 72 28 73 70 72 69 6e 74 66 28 27 54 68 | ......@trigger_error(sprintf('Th |
1ea40 | 65 20 25 73 20 63 6c 61 73 73 20 65 78 74 65 6e 64 73 20 25 73 20 74 68 61 74 20 69 73 20 64 65 | e.%s.class.extends.%s.that.is.de |
1ea60 | 70 72 65 63 61 74 65 64 20 25 73 27 2c 20 24 6e 61 6d 65 2c 20 24 70 61 72 65 6e 74 2c 20 73 65 | precated.%s',.$name,.$parent,.se |
1ea80 | 6c 66 3a 3a 24 64 65 70 72 65 63 61 74 65 64 5b 24 70 61 72 65 6e 74 5d 29 2c 20 45 5f 55 53 45 | lf::$deprecated[$parent]),.E_USE |
1eaa0 | 52 5f 44 45 50 52 45 43 41 54 45 44 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | R_DEPRECATED);.................. |
1eac0 | 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 70 61 72 65 6e | ...}......................$paren |
1eae0 | 74 49 6e 74 65 72 66 61 63 65 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 20 | tInterfaces.=.array();.......... |
1eb00 | 20 20 20 20 20 20 20 20 20 20 20 24 64 65 70 72 65 63 61 74 65 64 49 6e 74 65 72 66 61 63 65 73 | ...........$deprecatedInterfaces |
1eb20 | 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | .=.array();..................... |
1eb40 | 69 66 20 28 24 70 61 72 65 6e 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | if.($parent).{.................. |
1eb60 | 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 63 6c 61 73 73 5f 69 6d 70 6c 65 6d 65 6e 74 73 | .......foreach.(class_implements |
1eb80 | 28 24 70 61 72 65 6e 74 29 20 61 73 20 24 69 6e 74 65 72 66 61 63 65 29 20 7b 0a 20 20 20 20 20 | ($parent).as.$interface).{...... |
1eba0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 70 61 72 65 6e 74 49 6e | .......................$parentIn |
1ebc0 | 74 65 72 66 61 63 65 73 5b 24 69 6e 74 65 72 66 61 63 65 5d 20 3d 20 31 3b 0a 20 20 20 20 20 20 | terfaces[$interface].=.1;....... |
1ebe0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ..................}............. |
1ec00 | 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 66 | ........}......................f |
1ec20 | 6f 72 65 61 63 68 20 28 24 72 65 66 6c 2d 3e 67 65 74 49 6e 74 65 72 66 61 63 65 4e 61 6d 65 73 | oreach.($refl->getInterfaceNames |
1ec40 | 28 29 20 61 73 20 24 69 6e 74 65 72 66 61 63 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ().as.$interface).{............. |
1ec60 | 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 69 73 73 65 74 28 73 65 6c 66 3a 3a 24 64 65 70 | ............if.(isset(self::$dep |
1ec80 | 72 65 63 61 74 65 64 5b 24 69 6e 74 65 72 66 61 63 65 5d 29 20 26 26 20 73 74 72 6e 63 6d 70 28 | recated[$interface]).&&.strncmp( |
1eca0 | 24 6e 73 2c 20 24 69 6e 74 65 72 66 61 63 65 2c 20 24 6c 65 6e 29 29 20 7b 0a 20 20 20 20 20 20 | $ns,.$interface,.$len)).{....... |
1ecc0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 64 65 70 72 65 63 61 74 65 | ......................$deprecate |
1ece0 | 64 49 6e 74 65 72 66 61 63 65 73 5b 5d 20 3d 20 24 69 6e 74 65 72 66 61 63 65 3b 0a 20 20 20 20 | dInterfaces[].=.$interface;..... |
1ed00 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 | ....................}........... |
1ed20 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 63 6c 61 73 73 5f 69 6d 70 | ..............foreach.(class_imp |
1ed40 | 6c 65 6d 65 6e 74 73 28 24 69 6e 74 65 72 66 61 63 65 29 20 61 73 20 24 69 6e 74 65 72 66 61 63 | lements($interface).as.$interfac |
1ed60 | 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | e).{............................ |
1ed80 | 20 24 70 61 72 65 6e 74 49 6e 74 65 72 66 61 63 65 73 5b 24 69 6e 74 65 72 66 61 63 65 5d 20 3d | .$parentInterfaces[$interface].= |
1eda0 | 20 31 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 | .1;.........................}... |
1edc0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 | ..................}............. |
1ede0 | 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 64 65 70 72 65 63 61 74 65 64 49 6e 74 | .........foreach.($deprecatedInt |
1ee00 | 65 72 66 61 63 65 73 20 61 73 20 24 69 6e 74 65 72 66 61 63 65 29 20 7b 0a 20 20 20 20 20 20 20 | erfaces.as.$interface).{........ |
1ee20 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 21 69 73 73 65 74 28 24 70 61 72 | .................if.(!isset($par |
1ee40 | 65 6e 74 49 6e 74 65 72 66 61 63 65 73 5b 24 69 6e 74 65 72 66 61 63 65 5d 29 29 20 7b 0a 20 20 | entInterfaces[$interface])).{... |
1ee60 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 40 74 72 69 67 67 | ..........................@trigg |
1ee80 | 65 72 5f 65 72 72 6f 72 28 73 70 72 69 6e 74 66 28 27 54 68 65 20 25 73 20 25 73 20 25 73 20 74 | er_error(sprintf('The.%s.%s.%s.t |
1eea0 | 68 61 74 20 69 73 20 64 65 70 72 65 63 61 74 65 64 20 25 73 27 2c 20 24 6e 61 6d 65 2c 20 24 72 | hat.is.deprecated.%s',.$name,.$r |
1eec0 | 65 66 6c 2d 3e 69 73 49 6e 74 65 72 66 61 63 65 28 29 20 3f 20 27 69 6e 74 65 72 66 61 63 65 20 | efl->isInterface().?.'interface. |
1eee0 | 65 78 74 65 6e 64 73 27 20 3a 20 27 63 6c 61 73 73 20 69 6d 70 6c 65 6d 65 6e 74 73 27 2c 20 24 | extends'.:.'class.implements',.$ |
1ef00 | 69 6e 74 65 72 66 61 63 65 2c 20 73 65 6c 66 3a 3a 24 64 65 70 72 65 63 61 74 65 64 5b 24 69 6e | interface,.self::$deprecated[$in |
1ef20 | 74 65 72 66 61 63 65 5d 29 2c 20 45 5f 55 53 45 52 5f 44 45 50 52 45 43 41 54 45 44 29 3b 0a 20 | terface]),.E_USER_DEPRECATED);.. |
1ef40 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 | .......................}........ |
1ef60 | 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d | .............}.................} |
1ef80 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 | .............}.........}........ |
1efa0 | 20 20 69 66 20 28 24 66 69 6c 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 21 | ..if.($file).{.............if.(! |
1efc0 | 24 65 78 69 73 74 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 66 | $exists).{.................if.(f |
1efe0 | 61 6c 73 65 20 21 3d 3d 20 73 74 72 70 6f 73 28 24 63 6c 61 73 73 2c 20 27 2f 27 29 29 20 7b 0a | alse.!==.strpos($class,.'/')).{. |
1f000 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 5c 52 | ....................throw.new.\R |
1f020 | 75 6e 74 69 6d 65 45 78 63 65 70 74 69 6f 6e 28 73 70 72 69 6e 74 66 28 27 54 72 79 69 6e 67 20 | untimeException(sprintf('Trying. |
1f040 | 74 6f 20 61 75 74 6f 6c 6f 61 64 20 61 20 63 6c 61 73 73 20 77 69 74 68 20 61 6e 20 69 6e 76 61 | to.autoload.a.class.with.an.inva |
1f060 | 6c 69 64 20 6e 61 6d 65 20 22 25 73 22 2e 20 42 65 20 63 61 72 65 66 75 6c 20 74 68 61 74 20 74 | lid.name."%s"..Be.careful.that.t |
1f080 | 68 65 20 6e 61 6d 65 73 70 61 63 65 20 73 65 70 61 72 61 74 6f 72 20 69 73 20 22 5c 22 20 69 6e | he.namespace.separator.is."\".in |
1f0a0 | 20 50 48 50 2c 20 6e 6f 74 20 22 2f 22 2e 27 2c 20 24 63 6c 61 73 73 29 29 3b 0a 20 20 20 20 20 | .PHP,.not."/".',.$class));...... |
1f0c0 | 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 | ...........}..................th |
1f0e0 | 72 6f 77 20 6e 65 77 20 5c 52 75 6e 74 69 6d 65 45 78 63 65 70 74 69 6f 6e 28 73 70 72 69 6e 74 | row.new.\RuntimeException(sprint |
1f100 | 66 28 27 54 68 65 20 61 75 74 6f 6c 6f 61 64 65 72 20 65 78 70 65 63 74 65 64 20 63 6c 61 73 73 | f('The.autoloader.expected.class |
1f120 | 20 22 25 73 22 20 74 6f 20 62 65 20 64 65 66 69 6e 65 64 20 69 6e 20 66 69 6c 65 20 22 25 73 22 | ."%s".to.be.defined.in.file."%s" |
1f140 | 2e 20 54 68 65 20 66 69 6c 65 20 77 61 73 20 66 6f 75 6e 64 20 62 75 74 20 74 68 65 20 63 6c 61 | ..The.file.was.found.but.the.cla |
1f160 | 73 73 20 77 61 73 20 6e 6f 74 20 69 6e 20 69 74 2c 20 74 68 65 20 63 6c 61 73 73 20 6e 61 6d 65 | ss.was.not.in.it,.the.class.name |
1f180 | 20 6f 72 20 6e 61 6d 65 73 70 61 63 65 20 70 72 6f 62 61 62 6c 79 20 68 61 73 20 61 20 74 79 70 | .or.namespace.probably.has.a.typ |
1f1a0 | 6f 2e 27 2c 20 24 63 6c 61 73 73 2c 20 24 66 69 6c 65 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 | o.',.$class,.$file));........... |
1f1c0 | 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 73 65 6c 66 3a 3a 24 63 61 73 65 43 | ..}.............if.(self::$caseC |
1f1e0 | 68 65 63 6b 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 72 65 61 6c 20 3d 20 | heck).{.................$real.=. |
1f200 | 65 78 70 6c 6f 64 65 28 27 5c 5c 27 2c 20 24 63 6c 61 73 73 2e 73 74 72 72 63 68 72 28 24 66 69 | explode('\\',.$class.strrchr($fi |
1f220 | 6c 65 2c 20 27 2e 27 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 61 69 6c | le,.'.'));.................$tail |
1f240 | 20 3d 20 65 78 70 6c 6f 64 65 28 44 49 52 45 43 54 4f 52 59 5f 53 45 50 41 52 41 54 4f 52 2c 20 | .=.explode(DIRECTORY_SEPARATOR,. |
1f260 | 73 74 72 5f 72 65 70 6c 61 63 65 28 27 2f 27 2c 20 44 49 52 45 43 54 4f 52 59 5f 53 45 50 41 52 | str_replace('/',.DIRECTORY_SEPAR |
1f280 | 41 54 4f 52 2c 20 24 66 69 6c 65 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ATOR,.$file));.................. |
1f2a0 | 24 69 20 3d 20 63 6f 75 6e 74 28 24 74 61 69 6c 29 20 2d 20 31 3b 0a 20 20 20 20 20 20 20 20 20 | $i.=.count($tail).-.1;.......... |
1f2c0 | 20 20 20 20 20 20 20 24 6a 20 3d 20 63 6f 75 6e 74 28 24 72 65 61 6c 29 20 2d 20 31 3b 0a 0a 20 | .......$j.=.count($real).-.1;... |
1f2e0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 77 68 69 6c 65 20 28 69 73 73 65 74 28 24 74 61 69 | ...............while.(isset($tai |
1f300 | 6c 5b 24 69 5d 2c 20 24 72 65 61 6c 5b 24 6a 5d 29 20 26 26 20 24 74 61 69 6c 5b 24 69 5d 20 3d | l[$i],.$real[$j]).&&.$tail[$i].= |
1f320 | 3d 3d 20 24 72 65 61 6c 5b 24 6a 5d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ==.$real[$j]).{................. |
1f340 | 20 20 20 20 2d 2d 24 69 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2d 2d | ....--$i;.....................-- |
1f360 | 24 6a 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 | $j;.................}........... |
1f380 | 20 20 20 20 20 20 20 61 72 72 61 79 5f 73 70 6c 69 63 65 28 24 74 61 69 6c 2c 20 30 2c 20 24 69 | .......array_splice($tail,.0,.$i |
1f3a0 | 20 2b 20 31 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 | .+.1);.............}............ |
1f3c0 | 20 69 66 20 28 73 65 6c 66 3a 3a 24 63 61 73 65 43 68 65 63 6b 20 26 26 20 24 74 61 69 6c 29 20 | .if.(self::$caseCheck.&&.$tail). |
1f3e0 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 61 69 6c 20 3d 20 44 49 52 45 43 54 | {.................$tail.=.DIRECT |
1f400 | 4f 52 59 5f 53 45 50 41 52 41 54 4f 52 2e 69 6d 70 6c 6f 64 65 28 44 49 52 45 43 54 4f 52 59 5f | ORY_SEPARATOR.implode(DIRECTORY_ |
1f420 | 53 45 50 41 52 41 54 4f 52 2c 20 24 74 61 69 6c 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | SEPARATOR,.$tail);.............. |
1f440 | 20 20 20 24 74 61 69 6c 4c 65 6e 20 3d 20 73 74 72 6c 65 6e 28 24 74 61 69 6c 29 3b 0a 20 20 20 | ...$tailLen.=.strlen($tail);.... |
1f460 | 20 20 20 20 20 20 20 20 20 20 20 20 20 24 72 65 61 6c 20 3d 20 24 72 65 66 6c 2d 3e 67 65 74 46 | .............$real.=.$refl->getF |
1f480 | 69 6c 65 4e 61 6d 65 28 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 | ileName();..................if.( |
1f4a0 | 32 20 3d 3d 3d 20 73 65 6c 66 3a 3a 24 63 61 73 65 43 68 65 63 6b 29 20 7b 0a 20 20 20 20 20 20 | 2.===.self::$caseCheck).{....... |
1f4c0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 72 65 61 6c 70 61 74 68 28 29 20 6f 6e 20 4d | ..............//.realpath().on.M |
1f4e0 | 61 63 4f 53 58 20 64 6f 65 73 6e 27 74 20 6e 6f 72 6d 61 6c 69 7a 65 20 74 68 65 20 63 61 73 65 | acOSX.doesn't.normalize.the.case |
1f500 | 20 6f 66 20 63 68 61 72 61 63 74 65 72 73 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | .of.characters.................. |
1f520 | 20 20 20 20 24 69 20 3d 20 31 20 2b 20 73 74 72 72 70 6f 73 28 24 72 65 61 6c 2c 20 27 2f 27 29 | ....$i.=.1.+.strrpos($real,.'/') |
1f540 | 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 66 69 6c 65 20 3d 20 73 75 | ;.....................$file.=.su |
1f560 | 62 73 74 72 28 24 72 65 61 6c 2c 20 24 69 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | bstr($real,.$i);................ |
1f580 | 20 20 20 20 20 24 72 65 61 6c 20 3d 20 73 75 62 73 74 72 28 24 72 65 61 6c 2c 20 30 2c 20 24 69 | .....$real.=.substr($real,.0,.$i |
1f5a0 | 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 69 73 73 65 | );......................if.(isse |
1f5c0 | 74 28 73 65 6c 66 3a 3a 24 64 61 72 77 69 6e 43 61 63 68 65 5b 24 72 65 61 6c 5d 29 29 20 7b 0a | t(self::$darwinCache[$real])).{. |
1f5e0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6b 44 69 72 20 3d 20 | ........................$kDir.=. |
1f600 | 24 72 65 61 6c 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 | $real;.....................}.els |
1f620 | 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6b 44 69 | e.{.........................$kDi |
1f640 | 72 20 3d 20 73 74 72 74 6f 6c 6f 77 65 72 28 24 72 65 61 6c 29 3b 0a 0a 20 20 20 20 20 20 20 20 | r.=.strtolower($real);.......... |
1f660 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 69 73 73 65 74 28 73 65 6c 66 3a 3a | ................if.(isset(self:: |
1f680 | 24 64 61 72 77 69 6e 43 61 63 68 65 5b 24 6b 44 69 72 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 | $darwinCache[$kDir])).{......... |
1f6a0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 72 65 61 6c 20 3d 20 73 65 6c 66 | ....................$real.=.self |
1f6c0 | 3a 3a 24 64 61 72 77 69 6e 43 61 63 68 65 5b 24 6b 44 69 72 5d 5b 30 5d 3b 0a 20 20 20 20 20 20 | ::$darwinCache[$kDir][0];....... |
1f6e0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 | ..................}.else.{...... |
1f700 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 64 69 72 20 3d 20 67 65 | .......................$dir.=.ge |
1f720 | 74 63 77 64 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | tcwd();......................... |
1f740 | 20 20 20 20 63 68 64 69 72 28 24 72 65 61 6c 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ....chdir($real);............... |
1f760 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 72 65 61 6c 20 3d 20 67 65 74 63 77 64 28 29 2e 27 | ..............$real.=.getcwd().' |
1f780 | 2f 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | /';............................. |
1f7a0 | 63 68 64 69 72 28 24 64 69 72 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | chdir($dir);.................... |
1f7c0 | 20 20 20 20 20 20 20 20 20 20 24 64 69 72 20 3d 20 24 72 65 61 6c 3b 0a 20 20 20 20 20 20 20 20 | ..........$dir.=.$real;......... |
1f7e0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6b 20 3d 20 24 6b 44 69 72 3b 0a | ....................$k.=.$kDir;. |
1f800 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 69 20 3d | ............................$i.= |
1f820 | 20 73 74 72 6c 65 6e 28 24 64 69 72 29 20 2d 20 31 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | .strlen($dir).-.1;.............. |
1f840 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 77 68 69 6c 65 20 28 21 69 73 73 65 74 28 73 65 6c | ...............while.(!isset(sel |
1f860 | 66 3a 3a 24 64 61 72 77 69 6e 43 61 63 68 65 5b 24 6b 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 | f::$darwinCache[$k])).{......... |
1f880 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 73 65 6c 66 3a 3a 24 64 | ........................self::$d |
1f8a0 | 61 72 77 69 6e 43 61 63 68 65 5b 24 6b 5d 20 3d 20 61 72 72 61 79 28 24 64 69 72 2c 20 61 72 72 | arwinCache[$k].=.array($dir,.arr |
1f8c0 | 61 79 28 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ay());.......................... |
1f8e0 | 20 20 20 20 20 20 20 73 65 6c 66 3a 3a 24 64 61 72 77 69 6e 43 61 63 68 65 5b 24 64 69 72 5d 20 | .......self::$darwinCache[$dir]. |
1f900 | 3d 20 26 73 65 6c 66 3a 3a 24 64 61 72 77 69 6e 43 61 63 68 65 5b 24 6b 5d 3b 0a 0a 20 20 20 20 | =.&self::$darwinCache[$k];...... |
1f920 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 77 68 69 6c | ............................whil |
1f940 | 65 20 28 27 2f 27 20 21 3d 3d 20 24 64 69 72 5b 2d 2d 24 69 5d 29 20 7b 0a 20 20 20 20 20 20 20 | e.('/'.!==.$dir[--$i]).{........ |
1f960 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 | .........................}...... |
1f980 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6b 20 3d 20 | ...........................$k.=. |
1f9a0 | 73 75 62 73 74 72 28 24 6b 2c 20 30 2c 20 2b 2b 24 69 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 | substr($k,.0,.++$i);............ |
1f9c0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 64 69 72 20 3d 20 73 75 62 73 | .....................$dir.=.subs |
1f9e0 | 74 72 28 24 64 69 72 2c 20 30 2c 20 24 69 2d 2d 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | tr($dir,.0,.$i--);.............. |
1fa00 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ...............}................ |
1fa20 | 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d | .........}.....................} |
1fa40 | 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 64 69 72 46 69 6c 65 73 20 | ......................$dirFiles. |
1fa60 | 3d 20 73 65 6c 66 3a 3a 24 64 61 72 77 69 6e 43 61 63 68 65 5b 24 6b 44 69 72 5d 5b 31 5d 3b 0a | =.self::$darwinCache[$kDir][1];. |
1fa80 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 69 73 73 65 74 28 24 | .....................if.(isset($ |
1faa0 | 64 69 72 46 69 6c 65 73 5b 24 66 69 6c 65 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | dirFiles[$file])).{............. |
1fac0 | 20 20 20 20 20 20 20 20 20 20 20 20 24 6b 46 69 6c 65 20 3d 20 24 66 69 6c 65 3b 0a 20 20 20 20 | ............$kFile.=.$file;..... |
1fae0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 | ................}.else.{........ |
1fb00 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6b 46 69 6c 65 20 3d 20 73 74 72 74 6f 6c | .................$kFile.=.strtol |
1fb20 | 6f 77 65 72 28 24 66 69 6c 65 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ower($file);.................... |
1fb40 | 20 20 20 20 20 20 69 66 20 28 21 69 73 73 65 74 28 24 64 69 72 46 69 6c 65 73 5b 24 6b 46 69 6c | ......if.(!isset($dirFiles[$kFil |
1fb60 | 65 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | e])).{.......................... |
1fb80 | 20 20 20 66 6f 72 65 61 63 68 20 28 73 63 61 6e 64 69 72 28 24 72 65 61 6c 2c 20 32 29 20 61 73 | ...foreach.(scandir($real,.2).as |
1fba0 | 20 24 66 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | .$f).{.......................... |
1fbc0 | 20 20 20 20 20 20 20 69 66 20 28 27 2e 27 20 21 3d 3d 20 24 66 5b 30 5d 29 20 7b 0a 20 20 20 20 | .......if.('.'.!==.$f[0]).{..... |
1fbe0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ................................ |
1fc00 | 24 64 69 72 46 69 6c 65 73 5b 24 66 5d 20 3d 20 24 66 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | $dirFiles[$f].=.$f;............. |
1fc20 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 66 20 3d | ........................if.($f.= |
1fc40 | 3d 3d 20 24 66 69 6c 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ==.$file).{..................... |
1fc60 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6b 46 69 6c 65 20 3d 20 24 6b 20 | ....................$kFile.=.$k. |
1fc80 | 3d 20 24 66 69 6c 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | =.$file;........................ |
1fca0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 24 66 20 21 3d 3d 20 24 6b | .............}.elseif.($f.!==.$k |
1fcc0 | 20 3d 20 73 74 72 74 6f 6c 6f 77 65 72 28 24 66 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | .=.strtolower($f)).{............ |
1fce0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 64 69 | .............................$di |
1fd00 | 72 46 69 6c 65 73 5b 24 6b 5d 20 3d 20 24 66 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | rFiles[$k].=.$f;................ |
1fd20 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 | .....................}.......... |
1fd40 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 | .......................}........ |
1fd60 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 | .....................}.......... |
1fd80 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 73 65 6c 66 3a 3a 24 64 61 72 77 69 6e | ...................self::$darwin |
1fda0 | 43 61 63 68 65 5b 24 6b 44 69 72 5d 5b 31 5d 20 3d 20 24 64 69 72 46 69 6c 65 73 3b 0a 20 20 20 | Cache[$kDir][1].=.$dirFiles;.... |
1fdc0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 | .....................}.......... |
1fde0 | 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ...........}.................... |
1fe00 | 20 20 24 72 65 61 6c 20 2e 3d 20 24 64 69 72 46 69 6c 65 73 5b 24 6b 46 69 6c 65 5d 3b 0a 20 20 | ..$real..=.$dirFiles[$kFile];... |
1fe20 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ..............}................. |
1fe40 | 20 69 66 20 28 30 20 3d 3d 3d 20 73 75 62 73 74 72 5f 63 6f 6d 70 61 72 65 28 24 72 65 61 6c 2c | .if.(0.===.substr_compare($real, |
1fe60 | 20 24 74 61 69 6c 2c 20 2d 24 74 61 69 6c 4c 65 6e 2c 20 24 74 61 69 6c 4c 65 6e 2c 20 74 72 75 | .$tail,.-$tailLen,.$tailLen,.tru |
1fe80 | 65 29 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 26 26 20 30 20 21 3d 3d 20 73 75 | e)...................&&.0.!==.su |
1fea0 | 62 73 74 72 5f 63 6f 6d 70 61 72 65 28 24 72 65 61 6c 2c 20 24 74 61 69 6c 2c 20 2d 24 74 61 69 | bstr_compare($real,.$tail,.-$tai |
1fec0 | 6c 4c 65 6e 2c 20 24 74 61 69 6c 4c 65 6e 2c 20 66 61 6c 73 65 29 0a 20 20 20 20 20 20 20 20 20 | lLen,.$tailLen,.false).......... |
1fee0 | 20 20 20 20 20 20 20 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 | .......).{.....................t |
1ff00 | 68 72 6f 77 20 6e 65 77 20 5c 52 75 6e 74 69 6d 65 45 78 63 65 70 74 69 6f 6e 28 73 70 72 69 6e | hrow.new.\RuntimeException(sprin |
1ff20 | 74 66 28 27 43 61 73 65 20 6d 69 73 6d 61 74 63 68 20 62 65 74 77 65 65 6e 20 63 6c 61 73 73 20 | tf('Case.mismatch.between.class. |
1ff40 | 61 6e 64 20 72 65 61 6c 20 66 69 6c 65 20 6e 61 6d 65 73 3a 20 25 73 20 76 73 20 25 73 20 69 6e | and.real.file.names:.%s.vs.%s.in |
1ff60 | 20 25 73 27 2c 20 73 75 62 73 74 72 28 24 74 61 69 6c 2c 20 2d 24 74 61 69 6c 4c 65 6e 20 2b 20 | .%s',.substr($tail,.-$tailLen.+. |
1ff80 | 31 29 2c 20 73 75 62 73 74 72 28 24 72 65 61 6c 2c 20 2d 24 74 61 69 6c 4c 65 6e 20 2b 20 31 29 | 1),.substr($real,.-$tailLen.+.1) |
1ffa0 | 2c 20 73 75 62 73 74 72 28 24 72 65 61 6c 2c 20 30 2c 20 2d 24 74 61 69 6c 4c 65 6e 20 2b 20 31 | ,.substr($real,.0,.-$tailLen.+.1 |
1ffc0 | 29 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 | )));.................}.......... |
1ffe0 | 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 74 72 75 65 3b 0a 20 | ...}..............return.true;.. |
20000 | 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 | .......}.....}.}.<?php../*..*.Th |
20020 | 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 | is.file.is.part.of.the.Symfony.p |
20040 | 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 | ackage...*..*.(c).Fabien.Potenci |
20060 | 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f | er.<fabien@symfony.com>..*..*.Fo |
20080 | 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 | r.the.full.copyright.and.license |
200a0 | 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 | .information,.please.view.the.LI |
200c0 | 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 | CENSE..*.file.that.was.distribut |
200e0 | 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e | ed.with.this.source.code...*/..n |
20100 | 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 44 65 62 75 67 | amespace.Symfony\Component\Debug |
20120 | 5c 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 3b 0a 0a 75 73 65 20 53 79 6d 66 6f 6e 79 | \FatalErrorHandler;..use.Symfony |
20140 | 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 44 65 62 75 67 5c 45 78 63 65 70 74 69 6f 6e 5c 55 6e 64 65 66 | \Component\Debug\Exception\Undef |
20160 | 69 6e 65 64 46 75 6e 63 74 69 6f 6e 45 78 63 65 70 74 69 6f 6e 3b 0a 75 73 65 20 53 79 6d 66 6f | inedFunctionException;.use.Symfo |
20180 | 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 44 65 62 75 67 5c 45 78 63 65 70 74 69 6f 6e 5c 46 61 74 | ny\Component\Debug\Exception\Fat |
201a0 | 61 6c 45 72 72 6f 72 45 78 63 65 70 74 69 6f 6e 3b 0a 0a 2f 2a 2a 0a 20 2a 20 45 72 72 6f 72 48 | alErrorException;../**..*.ErrorH |
201c0 | 61 6e 64 6c 65 72 20 66 6f 72 20 75 6e 64 65 66 69 6e 65 64 20 66 75 6e 63 74 69 6f 6e 73 2e 0a | andler.for.undefined.functions.. |
201e0 | 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c | .*..*.@author.Fabien.Potencier.< |
20200 | 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 55 6e | fabien@symfony.com>..*/.class.Un |
20220 | 64 65 66 69 6e 65 64 46 75 6e 63 74 69 6f 6e 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 | definedFunctionFatalErrorHandler |
20240 | 20 69 6d 70 6c 65 6d 65 6e 74 73 20 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 49 6e 74 | .implements.FatalErrorHandlerInt |
20260 | 65 72 66 61 63 65 0a 7b 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 | erface.{...../**......*.{@inheri |
20280 | 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f | tdoc}......*/.....public.functio |
202a0 | 6e 20 68 61 6e 64 6c 65 45 72 72 6f 72 28 61 72 72 61 79 20 24 65 72 72 6f 72 2c 20 46 61 74 61 | n.handleError(array.$error,.Fata |
202c0 | 6c 45 72 72 6f 72 45 78 63 65 70 74 69 6f 6e 20 24 65 78 63 65 70 74 69 6f 6e 29 0a 20 20 20 20 | lErrorException.$exception)..... |
202e0 | 7b 0a 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 4c 65 6e 20 3d 20 73 74 72 6c 65 6e 28 24 | {.........$messageLen.=.strlen($ |
20300 | 65 72 72 6f 72 5b 27 6d 65 73 73 61 67 65 27 5d 29 3b 0a 20 20 20 20 20 20 20 20 24 6e 6f 74 46 | error['message']);.........$notF |
20320 | 6f 75 6e 64 53 75 66 66 69 78 20 3d 20 27 28 29 27 3b 0a 20 20 20 20 20 20 20 20 24 6e 6f 74 46 | oundSuffix.=.'()';.........$notF |
20340 | 6f 75 6e 64 53 75 66 66 69 78 4c 65 6e 20 3d 20 73 74 72 6c 65 6e 28 24 6e 6f 74 46 6f 75 6e 64 | oundSuffixLen.=.strlen($notFound |
20360 | 53 75 66 66 69 78 29 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 6e 6f 74 46 6f 75 6e 64 53 75 | Suffix);.........if.($notFoundSu |
20380 | 66 66 69 78 4c 65 6e 20 3e 20 24 6d 65 73 73 61 67 65 4c 65 6e 29 20 7b 0a 20 20 20 20 20 20 20 | ffixLen.>.$messageLen).{........ |
203a0 | 20 20 20 20 20 72 65 74 75 72 6e 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 | .....return;.........}.......... |
203c0 | 69 66 20 28 30 20 21 3d 3d 20 73 75 62 73 74 72 5f 63 6f 6d 70 61 72 65 28 24 65 72 72 6f 72 5b | if.(0.!==.substr_compare($error[ |
203e0 | 27 6d 65 73 73 61 67 65 27 5d 2c 20 24 6e 6f 74 46 6f 75 6e 64 53 75 66 66 69 78 2c 20 2d 24 6e | 'message'],.$notFoundSuffix,.-$n |
20400 | 6f 74 46 6f 75 6e 64 53 75 66 66 69 78 4c 65 6e 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | otFoundSuffixLen)).{............ |
20420 | 20 72 65 74 75 72 6e 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 70 72 65 | .return;.........}..........$pre |
20440 | 66 69 78 20 3d 20 27 43 61 6c 6c 20 74 6f 20 75 6e 64 65 66 69 6e 65 64 20 66 75 6e 63 74 69 6f | fix.=.'Call.to.undefined.functio |
20460 | 6e 20 27 3b 0a 20 20 20 20 20 20 20 20 24 70 72 65 66 69 78 4c 65 6e 20 3d 20 73 74 72 6c 65 6e | n.';.........$prefixLen.=.strlen |
20480 | 28 24 70 72 65 66 69 78 29 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 30 20 21 3d 3d 20 73 74 72 | ($prefix);.........if.(0.!==.str |
204a0 | 70 6f 73 28 24 65 72 72 6f 72 5b 27 6d 65 73 73 61 67 65 27 5d 2c 20 24 70 72 65 66 69 78 29 29 | pos($error['message'],.$prefix)) |
204c0 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 3b 0a 20 20 20 20 20 20 20 20 7d | .{.............return;.........} |
204e0 | 0a 0a 20 20 20 20 20 20 20 20 24 66 75 6c 6c 79 51 75 61 6c 69 66 69 65 64 46 75 6e 63 74 69 6f | ..........$fullyQualifiedFunctio |
20500 | 6e 4e 61 6d 65 20 3d 20 73 75 62 73 74 72 28 24 65 72 72 6f 72 5b 27 6d 65 73 73 61 67 65 27 5d | nName.=.substr($error['message'] |
20520 | 2c 20 24 70 72 65 66 69 78 4c 65 6e 2c 20 2d 24 6e 6f 74 46 6f 75 6e 64 53 75 66 66 69 78 4c 65 | ,.$prefixLen,.-$notFoundSuffixLe |
20540 | 6e 29 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 66 61 6c 73 65 20 21 3d 3d 20 24 6e 61 6d 65 73 | n);.........if.(false.!==.$names |
20560 | 70 61 63 65 53 65 70 61 72 61 74 6f 72 49 6e 64 65 78 20 3d 20 73 74 72 72 70 6f 73 28 24 66 75 | paceSeparatorIndex.=.strrpos($fu |
20580 | 6c 6c 79 51 75 61 6c 69 66 69 65 64 46 75 6e 63 74 69 6f 6e 4e 61 6d 65 2c 20 27 5c 5c 27 29 29 | llyQualifiedFunctionName,.'\\')) |
205a0 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 66 75 6e 63 74 69 6f 6e 4e 61 6d 65 20 3d 20 73 | .{.............$functionName.=.s |
205c0 | 75 62 73 74 72 28 24 66 75 6c 6c 79 51 75 61 6c 69 66 69 65 64 46 75 6e 63 74 69 6f 6e 4e 61 6d | ubstr($fullyQualifiedFunctionNam |
205e0 | 65 2c 20 24 6e 61 6d 65 73 70 61 63 65 53 65 70 61 72 61 74 6f 72 49 6e 64 65 78 20 2b 20 31 29 | e,.$namespaceSeparatorIndex.+.1) |
20600 | 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6e 61 6d 65 73 70 61 63 65 50 72 65 66 69 78 20 3d | ;.............$namespacePrefix.= |
20620 | 20 73 75 62 73 74 72 28 24 66 75 6c 6c 79 51 75 61 6c 69 66 69 65 64 46 75 6e 63 74 69 6f 6e 4e | .substr($fullyQualifiedFunctionN |
20640 | 61 6d 65 2c 20 30 2c 20 24 6e 61 6d 65 73 70 61 63 65 53 65 70 61 72 61 74 6f 72 49 6e 64 65 78 | ame,.0,.$namespaceSeparatorIndex |
20660 | 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 20 3d 20 73 70 72 69 6e 74 | );.............$message.=.sprint |
20680 | 66 28 27 41 74 74 65 6d 70 74 65 64 20 74 6f 20 63 61 6c 6c 20 66 75 6e 63 74 69 6f 6e 20 22 25 | f('Attempted.to.call.function."% |
206a0 | 73 22 20 66 72 6f 6d 20 6e 61 6d 65 73 70 61 63 65 20 22 25 73 22 2e 27 2c 20 24 66 75 6e 63 74 | s".from.namespace."%s".',.$funct |
206c0 | 69 6f 6e 4e 61 6d 65 2c 20 24 6e 61 6d 65 73 70 61 63 65 50 72 65 66 69 78 29 3b 0a 20 20 20 20 | ionName,.$namespacePrefix);..... |
206e0 | 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 66 75 6e 63 74 69 | ....}.else.{.............$functi |
20700 | 6f 6e 4e 61 6d 65 20 3d 20 24 66 75 6c 6c 79 51 75 61 6c 69 66 69 65 64 46 75 6e 63 74 69 6f 6e | onName.=.$fullyQualifiedFunction |
20720 | 4e 61 6d 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 20 3d 20 73 70 72 | Name;.............$message.=.spr |
20740 | 69 6e 74 66 28 27 41 74 74 65 6d 70 74 65 64 20 74 6f 20 63 61 6c 6c 20 66 75 6e 63 74 69 6f 6e | intf('Attempted.to.call.function |
20760 | 20 22 25 73 22 20 66 72 6f 6d 20 74 68 65 20 67 6c 6f 62 61 6c 20 6e 61 6d 65 73 70 61 63 65 2e | ."%s".from.the.global.namespace. |
20780 | 27 2c 20 24 66 75 6e 63 74 69 6f 6e 4e 61 6d 65 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 | ',.$functionName);.........}.... |
207a0 | 20 20 20 20 20 20 24 63 61 6e 64 69 64 61 74 65 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 | ......$candidates.=.array();.... |
207c0 | 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 67 65 74 5f 64 65 66 69 6e 65 64 5f 66 75 6e 63 74 69 | .....foreach.(get_defined_functi |
207e0 | 6f 6e 73 28 29 20 61 73 20 24 74 79 70 65 20 3d 3e 20 24 64 65 66 69 6e 65 64 46 75 6e 63 74 69 | ons().as.$type.=>.$definedFuncti |
20800 | 6f 6e 4e 61 6d 65 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 | onNames).{.............foreach.( |
20820 | 24 64 65 66 69 6e 65 64 46 75 6e 63 74 69 6f 6e 4e 61 6d 65 73 20 61 73 20 24 64 65 66 69 6e 65 | $definedFunctionNames.as.$define |
20840 | 64 46 75 6e 63 74 69 6f 6e 4e 61 6d 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | dFunctionName).{................ |
20860 | 20 69 66 20 28 66 61 6c 73 65 20 21 3d 3d 20 24 6e 61 6d 65 73 70 61 63 65 53 65 70 61 72 61 74 | .if.(false.!==.$namespaceSeparat |
20880 | 6f 72 49 6e 64 65 78 20 3d 20 73 74 72 72 70 6f 73 28 24 64 65 66 69 6e 65 64 46 75 6e 63 74 69 | orIndex.=.strrpos($definedFuncti |
208a0 | 6f 6e 4e 61 6d 65 2c 20 27 5c 5c 27 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | onName,.'\\')).{................ |
208c0 | 20 20 20 20 20 24 64 65 66 69 6e 65 64 46 75 6e 63 74 69 6f 6e 4e 61 6d 65 42 61 73 65 6e 61 6d | .....$definedFunctionNameBasenam |
208e0 | 65 20 3d 20 73 75 62 73 74 72 28 24 64 65 66 69 6e 65 64 46 75 6e 63 74 69 6f 6e 4e 61 6d 65 2c | e.=.substr($definedFunctionName, |
20900 | 20 24 6e 61 6d 65 73 70 61 63 65 53 65 70 61 72 61 74 6f 72 49 6e 64 65 78 20 2b 20 31 29 3b 0a | .$namespaceSeparatorIndex.+.1);. |
20920 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 | ................}.else.{........ |
20940 | 20 20 20 20 20 20 20 20 20 20 20 20 20 24 64 65 66 69 6e 65 64 46 75 6e 63 74 69 6f 6e 4e 61 6d | .............$definedFunctionNam |
20960 | 65 42 61 73 65 6e 61 6d 65 20 3d 20 24 64 65 66 69 6e 65 64 46 75 6e 63 74 69 6f 6e 4e 61 6d 65 | eBasename.=.$definedFunctionName |
20980 | 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 | ;.................}............. |
209a0 | 20 20 20 20 20 69 66 20 28 24 64 65 66 69 6e 65 64 46 75 6e 63 74 69 6f 6e 4e 61 6d 65 42 61 73 | .....if.($definedFunctionNameBas |
209c0 | 65 6e 61 6d 65 20 3d 3d 3d 20 24 66 75 6e 63 74 69 6f 6e 4e 61 6d 65 29 20 7b 0a 20 20 20 20 20 | ename.===.$functionName).{...... |
209e0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 63 61 6e 64 69 64 61 74 65 73 5b 5d 20 3d 20 27 | ...............$candidates[].=.' |
20a00 | 5c 5c 27 2e 24 64 65 66 69 6e 65 64 46 75 6e 63 74 69 6f 6e 4e 61 6d 65 3b 0a 20 20 20 20 20 20 | \\'.$definedFunctionName;....... |
20a20 | 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 | ..........}.............}....... |
20a40 | 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 63 61 6e 64 69 64 61 74 65 73 29 20 7b 0a | ..}..........if.($candidates).{. |
20a60 | 20 20 20 20 20 20 20 20 20 20 20 20 73 6f 72 74 28 24 63 61 6e 64 69 64 61 74 65 73 29 3b 0a 20 | ............sort($candidates);.. |
20a80 | 20 20 20 20 20 20 20 20 20 20 20 24 6c 61 73 74 20 3d 20 61 72 72 61 79 5f 70 6f 70 28 24 63 61 | ...........$last.=.array_pop($ca |
20aa0 | 6e 64 69 64 61 74 65 73 29 2e 27 22 3f 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 | ndidates).'"?';.............if.( |
20ac0 | 24 63 61 6e 64 69 64 61 74 65 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 | $candidates).{.................$ |
20ae0 | 63 61 6e 64 69 64 61 74 65 73 20 3d 20 27 65 2e 67 2e 20 22 27 2e 69 6d 70 6c 6f 64 65 28 27 22 | candidates.=.'e.g.."'.implode('" |
20b00 | 2c 20 22 27 2c 20 24 63 61 6e 64 69 64 61 74 65 73 29 2e 27 22 20 6f 72 20 22 27 2e 24 6c 61 73 | ,."',.$candidates).'".or."'.$las |
20b20 | 74 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 | t;.............}.else.{......... |
20b40 | 20 20 20 20 20 20 20 20 24 63 61 6e 64 69 64 61 74 65 73 20 3d 20 27 22 27 2e 24 6c 61 73 74 3b | ........$candidates.=.'"'.$last; |
20b60 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 | .............}.............$mess |
20b80 | 61 67 65 20 2e 3d 20 22 5c 6e 44 69 64 20 79 6f 75 20 6d 65 61 6e 20 74 6f 20 63 61 6c 6c 20 22 | age..=."\nDid.you.mean.to.call." |
20ba0 | 2e 24 63 61 6e 64 69 64 61 74 65 73 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 | .$candidates;.........}......... |
20bc0 | 20 72 65 74 75 72 6e 20 6e 65 77 20 55 6e 64 65 66 69 6e 65 64 46 75 6e 63 74 69 6f 6e 45 78 63 | .return.new.UndefinedFunctionExc |
20be0 | 65 70 74 69 6f 6e 28 24 6d 65 73 73 61 67 65 2c 20 24 65 78 63 65 70 74 69 6f 6e 29 3b 0a 20 20 | eption($message,.$exception);... |
20c00 | 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 | ..}.}.<?php../*..*.This.file.is. |
20c20 | 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a | part.of.the.Symfony.package...*. |
20c40 | 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 | .*.(c).Fabien.Potencier.<fabien@ |
20c60 | 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 | symfony.com>..*..*.For.the.full. |
20c80 | 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f | copyright.and.license.informatio |
20ca0 | 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 | n,.please.view.the.LICENSE..*.fi |
20cc0 | 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 | le.that.was.distributed.with.thi |
20ce0 | 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 | s.source.code...*/..namespace.Sy |
20d00 | 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 44 65 62 75 67 5c 46 61 74 61 6c 45 72 72 6f 72 | mfony\Component\Debug\FatalError |
20d20 | 48 61 6e 64 6c 65 72 3b 0a 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c | Handler;..use.Symfony\Component\ |
20d40 | 44 65 62 75 67 5c 45 78 63 65 70 74 69 6f 6e 5c 43 6c 61 73 73 4e 6f 74 46 6f 75 6e 64 45 78 63 | Debug\Exception\ClassNotFoundExc |
20d60 | 65 70 74 69 6f 6e 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 44 65 | eption;.use.Symfony\Component\De |
20d80 | 62 75 67 5c 45 78 63 65 70 74 69 6f 6e 5c 46 61 74 61 6c 45 72 72 6f 72 45 78 63 65 70 74 69 6f | bug\Exception\FatalErrorExceptio |
20da0 | 6e 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 44 65 62 75 67 5c 44 | n;.use.Symfony\Component\Debug\D |
20dc0 | 65 62 75 67 43 6c 61 73 73 4c 6f 61 64 65 72 3b 0a 75 73 65 20 43 6f 6d 70 6f 73 65 72 5c 41 75 | ebugClassLoader;.use.Composer\Au |
20de0 | 74 6f 6c 6f 61 64 5c 43 6c 61 73 73 4c 6f 61 64 65 72 20 61 73 20 43 6f 6d 70 6f 73 65 72 43 6c | toload\ClassLoader.as.ComposerCl |
20e00 | 61 73 73 4c 6f 61 64 65 72 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 | assLoader;.use.Symfony\Component |
20e20 | 5c 43 6c 61 73 73 4c 6f 61 64 65 72 5c 43 6c 61 73 73 4c 6f 61 64 65 72 20 61 73 20 53 79 6d 66 | \ClassLoader\ClassLoader.as.Symf |
20e40 | 6f 6e 79 43 6c 61 73 73 4c 6f 61 64 65 72 3b 0a 0a 2f 2a 2a 0a 20 2a 20 45 72 72 6f 72 48 61 6e | onyClassLoader;../**..*.ErrorHan |
20e60 | 64 6c 65 72 20 66 6f 72 20 63 6c 61 73 73 65 73 20 74 68 61 74 20 64 6f 20 6e 6f 74 20 65 78 69 | dler.for.classes.that.do.not.exi |
20e80 | 73 74 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 | st...*..*.@author.Fabien.Potenci |
20ea0 | 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 2f 0a 63 6c 61 73 | er.<fabien@symfony.com>..*/.clas |
20ec0 | 73 20 43 6c 61 73 73 4e 6f 74 46 6f 75 6e 64 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 | s.ClassNotFoundFatalErrorHandler |
20ee0 | 20 69 6d 70 6c 65 6d 65 6e 74 73 20 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 49 6e 74 | .implements.FatalErrorHandlerInt |
20f00 | 65 72 66 61 63 65 0a 7b 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 | erface.{...../**......*.{@inheri |
20f20 | 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f | tdoc}......*/.....public.functio |
20f40 | 6e 20 68 61 6e 64 6c 65 45 72 72 6f 72 28 61 72 72 61 79 20 24 65 72 72 6f 72 2c 20 46 61 74 61 | n.handleError(array.$error,.Fata |
20f60 | 6c 45 72 72 6f 72 45 78 63 65 70 74 69 6f 6e 20 24 65 78 63 65 70 74 69 6f 6e 29 0a 20 20 20 20 | lErrorException.$exception)..... |
20f80 | 7b 0a 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 4c 65 6e 20 3d 20 73 74 72 6c 65 6e 28 24 | {.........$messageLen.=.strlen($ |
20fa0 | 65 72 72 6f 72 5b 27 6d 65 73 73 61 67 65 27 5d 29 3b 0a 20 20 20 20 20 20 20 20 24 6e 6f 74 46 | error['message']);.........$notF |
20fc0 | 6f 75 6e 64 53 75 66 66 69 78 20 3d 20 27 5c 27 20 6e 6f 74 20 66 6f 75 6e 64 27 3b 0a 20 20 20 | oundSuffix.=.'\'.not.found';.... |
20fe0 | 20 20 20 20 20 24 6e 6f 74 46 6f 75 6e 64 53 75 66 66 69 78 4c 65 6e 20 3d 20 73 74 72 6c 65 6e | .....$notFoundSuffixLen.=.strlen |
21000 | 28 24 6e 6f 74 46 6f 75 6e 64 53 75 66 66 69 78 29 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 | ($notFoundSuffix);.........if.($ |
21020 | 6e 6f 74 46 6f 75 6e 64 53 75 66 66 69 78 4c 65 6e 20 3e 20 24 6d 65 73 73 61 67 65 4c 65 6e 29 | notFoundSuffixLen.>.$messageLen) |
21040 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 3b 0a 20 20 20 20 20 20 20 20 7d | .{.............return;.........} |
21060 | 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 30 20 21 3d 3d 20 73 75 62 73 74 72 5f 63 6f 6d 70 61 | ..........if.(0.!==.substr_compa |
21080 | 72 65 28 24 65 72 72 6f 72 5b 27 6d 65 73 73 61 67 65 27 5d 2c 20 24 6e 6f 74 46 6f 75 6e 64 53 | re($error['message'],.$notFoundS |
210a0 | 75 66 66 69 78 2c 20 2d 24 6e 6f 74 46 6f 75 6e 64 53 75 66 66 69 78 4c 65 6e 29 29 20 7b 0a 20 | uffix,.-$notFoundSuffixLen)).{.. |
210c0 | 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 | ...........return;.........}.... |
210e0 | 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 61 72 72 61 79 28 27 63 6c 61 73 73 27 2c 20 27 69 | ......foreach.(array('class',.'i |
21100 | 6e 74 65 72 66 61 63 65 27 2c 20 27 74 72 61 69 74 27 29 20 61 73 20 24 74 79 70 65 4e 61 6d 65 | nterface',.'trait').as.$typeName |
21120 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 70 72 65 66 69 78 20 3d 20 75 63 66 69 72 73 | ).{.............$prefix.=.ucfirs |
21140 | 74 28 24 74 79 70 65 4e 61 6d 65 29 2e 27 20 5c 27 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | t($typeName).'.\'';............. |
21160 | 24 70 72 65 66 69 78 4c 65 6e 20 3d 20 73 74 72 6c 65 6e 28 24 70 72 65 66 69 78 29 3b 0a 20 20 | $prefixLen.=.strlen($prefix);... |
21180 | 20 20 20 20 20 20 20 20 20 20 69 66 20 28 30 20 21 3d 3d 20 73 74 72 70 6f 73 28 24 65 72 72 6f | ..........if.(0.!==.strpos($erro |
211a0 | 72 5b 27 6d 65 73 73 61 67 65 27 5d 2c 20 24 70 72 65 66 69 78 29 29 20 7b 0a 20 20 20 20 20 20 | r['message'],.$prefix)).{....... |
211c0 | 20 20 20 20 20 20 20 20 20 20 63 6f 6e 74 69 6e 75 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ..........continue;............. |
211e0 | 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 66 75 6c 6c 79 51 75 61 6c 69 66 69 65 64 43 6c | }..............$fullyQualifiedCl |
21200 | 61 73 73 4e 61 6d 65 20 3d 20 73 75 62 73 74 72 28 24 65 72 72 6f 72 5b 27 6d 65 73 73 61 67 65 | assName.=.substr($error['message |
21220 | 27 5d 2c 20 24 70 72 65 66 69 78 4c 65 6e 2c 20 2d 24 6e 6f 74 46 6f 75 6e 64 53 75 66 66 69 78 | '],.$prefixLen,.-$notFoundSuffix |
21240 | 4c 65 6e 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 66 61 6c 73 65 20 21 3d 3d 20 | Len);.............if.(false.!==. |
21260 | 24 6e 61 6d 65 73 70 61 63 65 53 65 70 61 72 61 74 6f 72 49 6e 64 65 78 20 3d 20 73 74 72 72 70 | $namespaceSeparatorIndex.=.strrp |
21280 | 6f 73 28 24 66 75 6c 6c 79 51 75 61 6c 69 66 69 65 64 43 6c 61 73 73 4e 61 6d 65 2c 20 27 5c 5c | os($fullyQualifiedClassName,.'\\ |
212a0 | 27 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6c 61 73 73 4e 61 6d 65 | ')).{.................$className |
212c0 | 20 3d 20 73 75 62 73 74 72 28 24 66 75 6c 6c 79 51 75 61 6c 69 66 69 65 64 43 6c 61 73 73 4e 61 | .=.substr($fullyQualifiedClassNa |
212e0 | 6d 65 2c 20 24 6e 61 6d 65 73 70 61 63 65 53 65 70 61 72 61 74 6f 72 49 6e 64 65 78 20 2b 20 31 | me,.$namespaceSeparatorIndex.+.1 |
21300 | 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6e 61 6d 65 73 70 61 63 65 50 72 65 | );.................$namespacePre |
21320 | 66 69 78 20 3d 20 73 75 62 73 74 72 28 24 66 75 6c 6c 79 51 75 61 6c 69 66 69 65 64 43 6c 61 73 | fix.=.substr($fullyQualifiedClas |
21340 | 73 4e 61 6d 65 2c 20 30 2c 20 24 6e 61 6d 65 73 70 61 63 65 53 65 70 61 72 61 74 6f 72 49 6e 64 | sName,.0,.$namespaceSeparatorInd |
21360 | 65 78 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 20 3d 20 | ex);.................$message.=. |
21380 | 73 70 72 69 6e 74 66 28 27 41 74 74 65 6d 70 74 65 64 20 74 6f 20 6c 6f 61 64 20 25 73 20 22 25 | sprintf('Attempted.to.load.%s."% |
213a0 | 73 22 20 66 72 6f 6d 20 6e 61 6d 65 73 70 61 63 65 20 22 25 73 22 2e 27 2c 20 24 74 79 70 65 4e | s".from.namespace."%s".',.$typeN |
213c0 | 61 6d 65 2c 20 24 63 6c 61 73 73 4e 61 6d 65 2c 20 24 6e 61 6d 65 73 70 61 63 65 50 72 65 66 69 | ame,.$className,.$namespacePrefi |
213e0 | 78 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 61 69 6c 20 3d 20 27 20 66 6f | x);.................$tail.=.'.fo |
21400 | 72 20 61 6e 6f 74 68 65 72 20 6e 61 6d 65 73 70 61 63 65 3f 27 3b 0a 20 20 20 20 20 20 20 20 20 | r.another.namespace?';.......... |
21420 | 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6c 61 | ...}.else.{.................$cla |
21440 | 73 73 4e 61 6d 65 20 3d 20 24 66 75 6c 6c 79 51 75 61 6c 69 66 69 65 64 43 6c 61 73 73 4e 61 6d | ssName.=.$fullyQualifiedClassNam |
21460 | 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 20 3d 20 73 70 | e;.................$message.=.sp |
21480 | 72 69 6e 74 66 28 27 41 74 74 65 6d 70 74 65 64 20 74 6f 20 6c 6f 61 64 20 25 73 20 22 25 73 22 | rintf('Attempted.to.load.%s."%s" |
214a0 | 20 66 72 6f 6d 20 74 68 65 20 67 6c 6f 62 61 6c 20 6e 61 6d 65 73 70 61 63 65 2e 27 2c 20 24 74 | .from.the.global.namespace.',.$t |
214c0 | 79 70 65 4e 61 6d 65 2c 20 24 63 6c 61 73 73 4e 61 6d 65 29 3b 0a 20 20 20 20 20 20 20 20 20 20 | ypeName,.$className);........... |
214e0 | 20 20 20 20 20 20 24 74 61 69 6c 20 3d 20 27 3f 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d | ......$tail.=.'?';.............} |
21500 | 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 63 61 6e 64 69 64 61 74 65 73 20 3d 20 | ..............if.($candidates.=. |
21520 | 24 74 68 69 73 2d 3e 67 65 74 43 6c 61 73 73 43 61 6e 64 69 64 61 74 65 73 28 24 63 6c 61 73 73 | $this->getClassCandidates($class |
21540 | 4e 61 6d 65 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 61 69 6c 20 3d | Name)).{.................$tail.= |
21560 | 20 61 72 72 61 79 5f 70 6f 70 28 24 63 61 6e 64 69 64 61 74 65 73 29 2e 27 22 3f 27 3b 0a 20 20 | .array_pop($candidates).'"?';... |
21580 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 63 61 6e 64 69 64 61 74 65 73 29 20 7b | ..............if.($candidates).{ |
215a0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 61 69 6c 20 3d 20 27 20 66 | .....................$tail.=.'.f |
215c0 | 6f 72 20 65 2e 67 2e 20 22 27 2e 69 6d 70 6c 6f 64 65 28 27 22 2c 20 22 27 2c 20 24 63 61 6e 64 | or.e.g.."'.implode('",."',.$cand |
215e0 | 69 64 61 74 65 73 29 2e 27 22 20 6f 72 20 22 27 2e 24 74 61 69 6c 3b 0a 20 20 20 20 20 20 20 20 | idates).'".or."'.$tail;......... |
21600 | 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ........}.else.{................ |
21620 | 20 20 20 20 20 24 74 61 69 6c 20 3d 20 27 20 66 6f 72 20 22 27 2e 24 74 61 69 6c 3b 0a 20 20 20 | .....$tail.=.'.for."'.$tail;.... |
21640 | 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 | .............}.............}.... |
21660 | 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 20 2e 3d 20 22 5c 6e 44 69 64 20 79 6f 75 20 | .........$message..=."\nDid.you. |
21680 | 66 6f 72 67 65 74 20 61 20 5c 22 75 73 65 5c 22 20 73 74 61 74 65 6d 65 6e 74 22 2e 24 74 61 69 | forget.a.\"use\".statement".$tai |
216a0 | 6c 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6e 65 77 20 43 6c 61 73 73 | l;..............return.new.Class |
216c0 | 4e 6f 74 46 6f 75 6e 64 45 78 63 65 70 74 69 6f 6e 28 24 6d 65 73 73 61 67 65 2c 20 24 65 78 63 | NotFoundException($message,.$exc |
216e0 | 65 70 74 69 6f 6e 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a | eption);.........}.....}....../* |
21700 | 2a 0a 20 20 20 20 20 2a 20 54 72 69 65 73 20 74 6f 20 67 75 65 73 73 20 74 68 65 20 66 75 6c 6c | *......*.Tries.to.guess.the.full |
21720 | 20 6e 61 6d 65 73 70 61 63 65 20 66 6f 72 20 61 20 67 69 76 65 6e 20 63 6c 61 73 73 20 6e 61 6d | .namespace.for.a.given.class.nam |
21740 | 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 42 79 20 64 65 66 61 75 6c 74 2c 20 69 74 20 | e.......*......*.By.default,.it. |
21760 | 6c 6f 6f 6b 73 20 66 6f 72 20 50 53 52 2d 30 20 61 6e 64 20 50 53 52 2d 34 20 63 6c 61 73 73 65 | looks.for.PSR-0.and.PSR-4.classe |
21780 | 73 20 72 65 67 69 73 74 65 72 65 64 20 76 69 61 20 61 20 53 79 6d 66 6f 6e 79 20 6f 72 20 61 20 | s.registered.via.a.Symfony.or.a. |
217a0 | 43 6f 6d 70 6f 73 65 72 0a 20 20 20 20 20 2a 20 61 75 74 6f 6c 6f 61 64 65 72 20 28 74 68 61 74 | Composer......*.autoloader.(that |
217c0 | 20 73 68 6f 75 6c 64 20 63 6f 76 65 72 20 61 6c 6c 20 63 6f 6d 6d 6f 6e 20 63 61 73 65 73 29 2e | .should.cover.all.common.cases). |
217e0 | 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 63 6c | ......*......*.@param.string.$cl |
21800 | 61 73 73 20 41 20 63 6c 61 73 73 20 6e 61 6d 65 20 28 77 69 74 68 6f 75 74 20 69 74 73 20 6e 61 | ass.A.class.name.(without.its.na |
21820 | 6d 65 73 70 61 63 65 29 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 61 | mespace)......*......*.@return.a |
21840 | 72 72 61 79 20 41 6e 20 61 72 72 61 79 20 6f 66 20 70 6f 73 73 69 62 6c 65 20 66 75 6c 6c 79 20 | rray.An.array.of.possible.fully. |
21860 | 71 75 61 6c 69 66 69 65 64 20 63 6c 61 73 73 20 6e 61 6d 65 73 0a 20 20 20 20 20 2a 2f 0a 20 20 | qualified.class.names......*/... |
21880 | 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 43 6c 61 73 73 43 61 6e 64 69 | ..private.function.getClassCandi |
218a0 | 64 61 74 65 73 28 24 63 6c 61 73 73 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 | dates($class).....{.........if.( |
218c0 | 21 69 73 5f 61 72 72 61 79 28 24 66 75 6e 63 74 69 6f 6e 73 20 3d 20 73 70 6c 5f 61 75 74 6f 6c | !is_array($functions.=.spl_autol |
218e0 | 6f 61 64 5f 66 75 6e 63 74 69 6f 6e 73 28 29 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | oad_functions())).{............. |
21900 | 72 65 74 75 72 6e 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 | return.array();.........}....... |
21920 | 20 20 20 2f 2f 20 66 69 6e 64 20 53 79 6d 66 6f 6e 79 20 61 6e 64 20 43 6f 6d 70 6f 73 65 72 20 | ...//.find.Symfony.and.Composer. |
21940 | 61 75 74 6f 6c 6f 61 64 65 72 73 0a 20 20 20 20 20 20 20 20 24 63 6c 61 73 73 65 73 20 3d 20 61 | autoloaders.........$classes.=.a |
21960 | 72 72 61 79 28 29 3b 0a 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 66 75 6e 63 74 | rray();..........foreach.($funct |
21980 | 69 6f 6e 73 20 61 73 20 24 66 75 6e 63 74 69 6f 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | ions.as.$function).{............ |
219a0 | 20 69 66 20 28 21 69 73 5f 61 72 72 61 79 28 24 66 75 6e 63 74 69 6f 6e 29 29 20 7b 0a 20 20 20 | .if.(!is_array($function)).{.... |
219c0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 63 6f 6e 74 69 6e 75 65 3b 0a 20 20 20 20 20 20 20 20 20 | .............continue;.......... |
219e0 | 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 67 65 74 20 63 6c 61 73 73 20 6c 6f | ...}.............//.get.class.lo |
21a00 | 61 64 65 72 73 20 77 72 61 70 70 65 64 20 62 79 20 44 65 62 75 67 43 6c 61 73 73 4c 6f 61 64 65 | aders.wrapped.by.DebugClassLoade |
21a20 | 72 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 66 75 6e 63 74 69 6f 6e 5b 30 5d 20 69 | r.............if.($function[0].i |
21a40 | 6e 73 74 61 6e 63 65 6f 66 20 44 65 62 75 67 43 6c 61 73 73 4c 6f 61 64 65 72 29 20 7b 0a 20 20 | nstanceof.DebugClassLoader).{... |
21a60 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 66 75 6e 63 74 69 6f 6e 20 3d 20 24 66 75 6e 63 74 | ..............$function.=.$funct |
21a80 | 69 6f 6e 5b 30 5d 2d 3e 67 65 74 43 6c 61 73 73 4c 6f 61 64 65 72 28 29 3b 0a 0a 20 20 20 20 20 | ion[0]->getClassLoader();....... |
21aa0 | 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 21 69 73 5f 61 72 72 61 79 28 24 66 75 6e 63 74 69 | ...........if.(!is_array($functi |
21ac0 | 6f 6e 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 63 6f 6e 74 69 | on)).{.....................conti |
21ae0 | 6e 75 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 | nue;.................}.......... |
21b00 | 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 66 75 6e 63 74 69 6f 6e 5b | ...}..............if.($function[ |
21b20 | 30 5d 20 69 6e 73 74 61 6e 63 65 6f 66 20 43 6f 6d 70 6f 73 65 72 43 6c 61 73 73 4c 6f 61 64 65 | 0].instanceof.ComposerClassLoade |
21b40 | 72 20 7c 7c 20 24 66 75 6e 63 74 69 6f 6e 5b 30 5d 20 69 6e 73 74 61 6e 63 65 6f 66 20 53 79 6d | r.||.$function[0].instanceof.Sym |
21b60 | 66 6f 6e 79 43 6c 61 73 73 4c 6f 61 64 65 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | fonyClassLoader).{.............. |
21b80 | 20 20 20 66 6f 72 65 61 63 68 20 28 24 66 75 6e 63 74 69 6f 6e 5b 30 5d 2d 3e 67 65 74 50 72 65 | ...foreach.($function[0]->getPre |
21ba0 | 66 69 78 65 73 28 29 20 61 73 20 24 70 72 65 66 69 78 20 3d 3e 20 24 70 61 74 68 73 29 20 7b 0a | fixes().as.$prefix.=>.$paths).{. |
21bc0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 70 61 | ....................foreach.($pa |
21be0 | 74 68 73 20 61 73 20 24 70 61 74 68 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ths.as.$path).{................. |
21c00 | 20 20 20 20 20 20 20 20 24 63 6c 61 73 73 65 73 20 3d 20 61 72 72 61 79 5f 6d 65 72 67 65 28 24 | ........$classes.=.array_merge($ |
21c20 | 63 6c 61 73 73 65 73 2c 20 24 74 68 69 73 2d 3e 66 69 6e 64 43 6c 61 73 73 49 6e 50 61 74 68 28 | classes,.$this->findClassInPath( |
21c40 | 24 70 61 74 68 2c 20 24 63 6c 61 73 73 2c 20 24 70 72 65 66 69 78 29 29 3b 0a 20 20 20 20 20 20 | $path,.$class,.$prefix));....... |
21c60 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ..............}................. |
21c80 | 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 | }.............}.............if.( |
21ca0 | 24 66 75 6e 63 74 69 6f 6e 5b 30 5d 20 69 6e 73 74 61 6e 63 65 6f 66 20 43 6f 6d 70 6f 73 65 72 | $function[0].instanceof.Composer |
21cc0 | 43 6c 61 73 73 4c 6f 61 64 65 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 66 | ClassLoader).{.................f |
21ce0 | 6f 72 65 61 63 68 20 28 24 66 75 6e 63 74 69 6f 6e 5b 30 5d 2d 3e 67 65 74 50 72 65 66 69 78 65 | oreach.($function[0]->getPrefixe |
21d00 | 73 50 73 72 34 28 29 20 61 73 20 24 70 72 65 66 69 78 20 3d 3e 20 24 70 61 74 68 73 29 20 7b 0a | sPsr4().as.$prefix.=>.$paths).{. |
21d20 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 70 61 | ....................foreach.($pa |
21d40 | 74 68 73 20 61 73 20 24 70 61 74 68 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ths.as.$path).{................. |
21d60 | 20 20 20 20 20 20 20 20 24 63 6c 61 73 73 65 73 20 3d 20 61 72 72 61 79 5f 6d 65 72 67 65 28 24 | ........$classes.=.array_merge($ |
21d80 | 63 6c 61 73 73 65 73 2c 20 24 74 68 69 73 2d 3e 66 69 6e 64 43 6c 61 73 73 49 6e 50 61 74 68 28 | classes,.$this->findClassInPath( |
21da0 | 24 70 61 74 68 2c 20 24 63 6c 61 73 73 2c 20 24 70 72 65 66 69 78 29 29 3b 0a 20 20 20 20 20 20 | $path,.$class,.$prefix));....... |
21dc0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ..............}................. |
21de0 | 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 | }.............}.........}....... |
21e00 | 20 20 20 72 65 74 75 72 6e 20 61 72 72 61 79 5f 75 6e 69 71 75 65 28 24 63 6c 61 73 73 65 73 29 | ...return.array_unique($classes) |
21e20 | 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 | ;.....}....../**......*.@param.s |
21e40 | 74 72 69 6e 67 20 24 70 61 74 68 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 | tring.$path......*.@param.string |
21e60 | 20 24 63 6c 61 73 73 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 70 72 | .$class......*.@param.string.$pr |
21e80 | 65 66 69 78 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 61 72 72 61 79 | efix......*......*.@return.array |
21ea0 | 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 66 69 | ......*/.....private.function.fi |
21ec0 | 6e 64 43 6c 61 73 73 49 6e 50 61 74 68 28 24 70 61 74 68 2c 20 24 63 6c 61 73 73 2c 20 24 70 72 | ndClassInPath($path,.$class,.$pr |
21ee0 | 65 66 69 78 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 24 70 61 74 68 20 3d | efix).....{.........if.(!$path.= |
21f00 | 20 72 65 61 6c 70 61 74 68 28 24 70 61 74 68 2e 27 2f 27 2e 73 74 72 74 72 28 24 70 72 65 66 69 | .realpath($path.'/'.strtr($prefi |
21f20 | 78 2c 20 27 5c 5c 5f 27 2c 20 27 2f 2f 27 29 29 20 3f 3a 20 72 65 61 6c 70 61 74 68 28 24 70 61 | x,.'\\_',.'//')).?:.realpath($pa |
21f40 | 74 68 2e 27 2f 27 2e 64 69 72 6e 61 6d 65 28 73 74 72 74 72 28 24 70 72 65 66 69 78 2c 20 27 5c | th.'/'.dirname(strtr($prefix,.'\ |
21f60 | 5c 5f 27 2c 20 27 2f 2f 27 29 29 29 20 3f 3a 20 72 65 61 6c 70 61 74 68 28 24 70 61 74 68 29 29 | \_',.'//'))).?:.realpath($path)) |
21f80 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 61 72 72 61 79 28 29 3b 0a 20 | .{.............return.array();.. |
21fa0 | 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 63 6c 61 73 73 65 73 20 3d 20 61 72 72 | .......}..........$classes.=.arr |
21fc0 | 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 24 66 69 6c 65 6e 61 6d 65 20 3d 20 24 63 6c 61 73 73 | ay();.........$filename.=.$class |
21fe0 | 2e 27 2e 70 68 70 27 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 6e 65 77 20 5c 52 | .'.php';.........foreach.(new.\R |
22000 | 65 63 75 72 73 69 76 65 49 74 65 72 61 74 6f 72 49 74 65 72 61 74 6f 72 28 6e 65 77 20 5c 52 65 | ecursiveIteratorIterator(new.\Re |
22020 | 63 75 72 73 69 76 65 44 69 72 65 63 74 6f 72 79 49 74 65 72 61 74 6f 72 28 24 70 61 74 68 2c 20 | cursiveDirectoryIterator($path,. |
22040 | 5c 52 65 63 75 72 73 69 76 65 44 69 72 65 63 74 6f 72 79 49 74 65 72 61 74 6f 72 3a 3a 53 4b 49 | \RecursiveDirectoryIterator::SKI |
22060 | 50 5f 44 4f 54 53 29 2c 20 5c 52 65 63 75 72 73 69 76 65 49 74 65 72 61 74 6f 72 49 74 65 72 61 | P_DOTS),.\RecursiveIteratorItera |
22080 | 74 6f 72 3a 3a 4c 45 41 56 45 53 5f 4f 4e 4c 59 29 20 61 73 20 24 66 69 6c 65 29 20 7b 0a 20 20 | tor::LEAVES_ONLY).as.$file).{... |
220a0 | 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 66 69 6c 65 6e 61 6d 65 20 3d 3d 20 24 66 69 6c 65 | ..........if.($filename.==.$file |
220c0 | 2d 3e 67 65 74 46 69 6c 65 4e 61 6d 65 28 29 20 26 26 20 24 63 6c 61 73 73 20 3d 20 24 74 68 69 | ->getFileName().&&.$class.=.$thi |
220e0 | 73 2d 3e 63 6f 6e 76 65 72 74 46 69 6c 65 54 6f 43 6c 61 73 73 28 24 70 61 74 68 2c 20 24 66 69 | s->convertFileToClass($path,.$fi |
22100 | 6c 65 2d 3e 67 65 74 50 61 74 68 4e 61 6d 65 28 29 2c 20 24 70 72 65 66 69 78 29 29 20 7b 0a 20 | le->getPathName(),.$prefix)).{.. |
22120 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6c 61 73 73 65 73 5b 5d 20 3d 20 24 63 6c 61 | ...............$classes[].=.$cla |
22140 | 73 73 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 | ss;.............}.........}..... |
22160 | 20 20 20 20 20 72 65 74 75 72 6e 20 24 63 6c 61 73 73 65 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 | .....return.$classes;.....}..... |
22180 | 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 70 61 74 68 0a | ./**......*.@param.string.$path. |
221a0 | 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 66 69 6c 65 0a 20 20 20 20 20 | .....*.@param.string.$file...... |
221c0 | 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 70 72 65 66 69 78 0a 20 20 20 20 20 2a 0a 20 | *.@param.string.$prefix......*.. |
221e0 | 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 7c 6e 75 6c 6c 0a 20 20 20 20 20 2a | ....*.@return.string|null......* |
22200 | 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 63 6f 6e 76 65 72 74 46 69 | /.....private.function.convertFi |
22220 | 6c 65 54 6f 43 6c 61 73 73 28 24 70 61 74 68 2c 20 24 66 69 6c 65 2c 20 24 70 72 65 66 69 78 29 | leToClass($path,.$file,.$prefix) |
22240 | 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 63 61 6e 64 69 64 61 74 65 73 20 3d 20 61 72 72 | .....{.........$candidates.=.arr |
22260 | 61 79 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 6e 61 6d 65 73 70 61 63 65 64 20 63 6c | ay(.............//.namespaced.cl |
22280 | 61 73 73 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6e 61 6d 65 73 70 61 63 65 64 43 6c 61 73 73 | ass.............$namespacedClass |
222a0 | 20 3d 20 73 74 72 5f 72 65 70 6c 61 63 65 28 61 72 72 61 79 28 24 70 61 74 68 2e 44 49 52 45 43 | .=.str_replace(array($path.DIREC |
222c0 | 54 4f 52 59 5f 53 45 50 41 52 41 54 4f 52 2c 20 27 2e 70 68 70 27 2c 20 27 2f 27 29 2c 20 61 72 | TORY_SEPARATOR,.'.php',.'/'),.ar |
222e0 | 72 61 79 28 27 27 2c 20 27 27 2c 20 27 5c 5c 27 29 2c 20 24 66 69 6c 65 29 2c 0a 20 20 20 20 20 | ray('',.'',.'\\'),.$file),...... |
22300 | 20 20 20 20 20 20 20 2f 2f 20 6e 61 6d 65 73 70 61 63 65 64 20 63 6c 61 73 73 20 28 77 69 74 68 | .......//.namespaced.class.(with |
22320 | 20 74 61 72 67 65 74 20 64 69 72 29 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 70 72 65 66 69 78 | .target.dir).............$prefix |
22340 | 2e 24 6e 61 6d 65 73 70 61 63 65 64 43 6c 61 73 73 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f | .$namespacedClass,............./ |
22360 | 2f 20 6e 61 6d 65 73 70 61 63 65 64 20 63 6c 61 73 73 20 28 77 69 74 68 20 74 61 72 67 65 74 20 | /.namespaced.class.(with.target. |
22380 | 64 69 72 20 61 6e 64 20 73 65 70 61 72 61 74 6f 72 29 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 | dir.and.separator).............$ |
223a0 | 70 72 65 66 69 78 2e 27 5c 5c 27 2e 24 6e 61 6d 65 73 70 61 63 65 64 43 6c 61 73 73 2c 0a 20 20 | prefix.'\\'.$namespacedClass,... |
223c0 | 20 20 20 20 20 20 20 20 20 20 2f 2f 20 50 45 41 52 20 63 6c 61 73 73 0a 20 20 20 20 20 20 20 20 | ..........//.PEAR.class......... |
223e0 | 20 20 20 20 73 74 72 5f 72 65 70 6c 61 63 65 28 27 5c 5c 27 2c 20 27 5f 27 2c 20 24 6e 61 6d 65 | ....str_replace('\\',.'_',.$name |
22400 | 73 70 61 63 65 64 43 6c 61 73 73 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 50 45 41 | spacedClass),.............//.PEA |
22420 | 52 20 63 6c 61 73 73 20 28 77 69 74 68 20 74 61 72 67 65 74 20 64 69 72 29 0a 20 20 20 20 20 20 | R.class.(with.target.dir)....... |
22440 | 20 20 20 20 20 20 73 74 72 5f 72 65 70 6c 61 63 65 28 27 5c 5c 27 2c 20 27 5f 27 2c 20 24 70 72 | ......str_replace('\\',.'_',.$pr |
22460 | 65 66 69 78 2e 24 6e 61 6d 65 73 70 61 63 65 64 43 6c 61 73 73 29 2c 0a 20 20 20 20 20 20 20 20 | efix.$namespacedClass),......... |
22480 | 20 20 20 20 2f 2f 20 50 45 41 52 20 63 6c 61 73 73 20 28 77 69 74 68 20 74 61 72 67 65 74 20 64 | ....//.PEAR.class.(with.target.d |
224a0 | 69 72 20 61 6e 64 20 73 65 70 61 72 61 74 6f 72 29 0a 20 20 20 20 20 20 20 20 20 20 20 20 73 74 | ir.and.separator).............st |
224c0 | 72 5f 72 65 70 6c 61 63 65 28 27 5c 5c 27 2c 20 27 5f 27 2c 20 24 70 72 65 66 69 78 2e 27 5c 5c | r_replace('\\',.'_',.$prefix.'\\ |
224e0 | 27 2e 24 6e 61 6d 65 73 70 61 63 65 64 43 6c 61 73 73 29 2c 0a 20 20 20 20 20 20 20 20 29 3b 0a | '.$namespacedClass),.........);. |
22500 | 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 70 72 65 66 69 78 29 20 7b 0a 20 20 20 20 20 20 20 20 | .........if.($prefix).{......... |
22520 | 20 20 20 20 24 63 61 6e 64 69 64 61 74 65 73 20 3d 20 61 72 72 61 79 5f 66 69 6c 74 65 72 28 24 | ....$candidates.=.array_filter($ |
22540 | 63 61 6e 64 69 64 61 74 65 73 2c 20 66 75 6e 63 74 69 6f 6e 20 28 24 63 61 6e 64 69 64 61 74 65 | candidates,.function.($candidate |
22560 | 29 20 75 73 65 20 28 24 70 72 65 66 69 78 29 20 7b 72 65 74 75 72 6e 20 30 20 3d 3d 3d 20 73 74 | ).use.($prefix).{return.0.===.st |
22580 | 72 70 6f 73 28 24 63 61 6e 64 69 64 61 74 65 2c 20 24 70 72 65 66 69 78 29 3b 7d 29 3b 0a 20 20 | rpos($candidate,.$prefix);});... |
225a0 | 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 2f 2f 20 57 65 20 63 61 6e 6e 6f 74 20 75 73 | ......}..........//.We.cannot.us |
225c0 | 65 20 74 68 65 20 61 75 74 6f 6c 6f 61 64 65 72 20 68 65 72 65 20 61 73 20 6d 6f 73 74 20 6f 66 | e.the.autoloader.here.as.most.of |
225e0 | 20 74 68 65 6d 20 75 73 65 20 72 65 71 75 69 72 65 3b 20 62 75 74 20 69 66 20 74 68 65 20 63 6c | .them.use.require;.but.if.the.cl |
22600 | 61 73 73 0a 20 20 20 20 20 20 20 20 2f 2f 20 69 73 20 6e 6f 74 20 66 6f 75 6e 64 2c 20 74 68 65 | ass.........//.is.not.found,.the |
22620 | 20 6e 65 77 20 61 75 74 6f 6c 6f 61 64 65 72 20 63 61 6c 6c 20 77 69 6c 6c 20 72 65 71 75 69 72 | .new.autoloader.call.will.requir |
22640 | 65 20 74 68 65 20 66 69 6c 65 20 61 67 61 69 6e 20 6c 65 61 64 69 6e 67 20 74 6f 20 61 0a 20 20 | e.the.file.again.leading.to.a... |
22660 | 20 20 20 20 20 20 2f 2f 20 22 63 61 6e 6e 6f 74 20 72 65 64 65 63 6c 61 72 65 20 63 6c 61 73 73 | ......//."cannot.redeclare.class |
22680 | 22 20 65 72 72 6f 72 2e 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 63 61 6e 64 69 | ".error..........foreach.($candi |
226a0 | 64 61 74 65 73 20 61 73 20 24 63 61 6e 64 69 64 61 74 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | dates.as.$candidate).{.......... |
226c0 | 20 20 20 69 66 20 28 24 74 68 69 73 2d 3e 63 6c 61 73 73 45 78 69 73 74 73 28 24 63 61 6e 64 69 | ...if.($this->classExists($candi |
226e0 | 64 61 74 65 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 | date)).{.................return. |
22700 | 24 63 61 6e 64 69 64 61 74 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 | $candidate;.............}....... |
22720 | 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 71 75 69 72 65 5f 6f 6e 63 65 20 24 66 69 6c 65 3b | ..}..........require_once.$file; |
22740 | 0a 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 63 61 6e 64 69 64 61 74 65 73 20 61 | ..........foreach.($candidates.a |
22760 | 73 20 24 63 61 6e 64 69 64 61 74 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 | s.$candidate).{.............if.( |
22780 | 24 74 68 69 73 2d 3e 63 6c 61 73 73 45 78 69 73 74 73 28 24 63 61 6e 64 69 64 61 74 65 29 29 20 | $this->classExists($candidate)). |
227a0 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 63 61 6e 64 69 64 | {.................return.$candid |
227c0 | 61 74 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 | ate;.............}.........}.... |
227e0 | 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 | .}....../**......*.@param.string |
22800 | 20 24 63 6c 61 73 73 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 62 6f | .$class......*......*.@return.bo |
22820 | 6f 6c 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 | ol......*/.....private.function. |
22840 | 63 6c 61 73 73 45 78 69 73 74 73 28 24 63 6c 61 73 73 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 | classExists($class).....{....... |
22860 | 20 20 72 65 74 75 72 6e 20 63 6c 61 73 73 5f 65 78 69 73 74 73 28 24 63 6c 61 73 73 2c 20 66 61 | ..return.class_exists($class,.fa |
22880 | 6c 73 65 29 20 7c 7c 20 69 6e 74 65 72 66 61 63 65 5f 65 78 69 73 74 73 28 24 63 6c 61 73 73 2c | lse).||.interface_exists($class, |
228a0 | 20 66 61 6c 73 65 29 20 7c 7c 20 74 72 61 69 74 5f 65 78 69 73 74 73 28 24 63 6c 61 73 73 2c 20 | .false).||.trait_exists($class,. |
228c0 | 66 61 6c 73 65 29 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 | false);.....}.}.<?php../*..*.Thi |
228e0 | 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 | s.file.is.part.of.the.Symfony.pa |
22900 | 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 | ckage...*..*.(c).Fabien.Potencie |
22920 | 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 | r.<fabien@symfony.com>..*..*.For |
22940 | 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 | .the.full.copyright.and.license. |
22960 | 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 | information,.please.view.the.LIC |
22980 | 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 | ENSE..*.file.that.was.distribute |
229a0 | 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 | d.with.this.source.code...*/..na |
229c0 | 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 44 65 62 75 67 5c | mespace.Symfony\Component\Debug\ |
229e0 | 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 3b 0a 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c | FatalErrorHandler;..use.Symfony\ |
22a00 | 43 6f 6d 70 6f 6e 65 6e 74 5c 44 65 62 75 67 5c 45 78 63 65 70 74 69 6f 6e 5c 46 61 74 61 6c 45 | Component\Debug\Exception\FatalE |
22a20 | 72 72 6f 72 45 78 63 65 70 74 69 6f 6e 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f | rrorException;.use.Symfony\Compo |
22a40 | 6e 65 6e 74 5c 44 65 62 75 67 5c 45 78 63 65 70 74 69 6f 6e 5c 55 6e 64 65 66 69 6e 65 64 4d 65 | nent\Debug\Exception\UndefinedMe |
22a60 | 74 68 6f 64 45 78 63 65 70 74 69 6f 6e 3b 0a 0a 2f 2a 2a 0a 20 2a 20 45 72 72 6f 72 48 61 6e 64 | thodException;../**..*.ErrorHand |
22a80 | 6c 65 72 20 66 6f 72 20 75 6e 64 65 66 69 6e 65 64 20 6d 65 74 68 6f 64 73 2e 0a 20 2a 0a 20 2a | ler.for.undefined.methods...*..* |
22aa0 | 20 40 61 75 74 68 6f 72 20 47 72 c3 a9 67 6f 69 72 65 20 50 69 6e 65 61 75 20 3c 6c 79 72 69 78 | .@author.Gr..goire.Pineau.<lyrix |
22ac0 | 78 40 6c 79 72 69 78 78 2e 69 6e 66 6f 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 55 6e 64 65 66 69 6e | x@lyrixx.info>..*/.class.Undefin |
22ae0 | 65 64 4d 65 74 68 6f 64 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 20 69 6d 70 6c 65 6d | edMethodFatalErrorHandler.implem |
22b00 | 65 6e 74 73 20 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 49 6e 74 65 72 66 61 63 65 0a | ents.FatalErrorHandlerInterface. |
22b20 | 7b 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 | {...../**......*.{@inheritdoc}.. |
22b40 | 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 68 61 6e 64 6c | ....*/.....public.function.handl |
22b60 | 65 45 72 72 6f 72 28 61 72 72 61 79 20 24 65 72 72 6f 72 2c 20 46 61 74 61 6c 45 72 72 6f 72 45 | eError(array.$error,.FatalErrorE |
22b80 | 78 63 65 70 74 69 6f 6e 20 24 65 78 63 65 70 74 69 6f 6e 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 | xception.$exception).....{...... |
22ba0 | 20 20 20 70 72 65 67 5f 6d 61 74 63 68 28 27 2f 5e 43 61 6c 6c 20 74 6f 20 75 6e 64 65 66 69 6e | ...preg_match('/^Call.to.undefin |
22bc0 | 65 64 20 6d 65 74 68 6f 64 20 28 2e 2a 29 3a 3a 28 2e 2a 29 5c 28 5c 29 24 2f 27 2c 20 24 65 72 | ed.method.(.*)::(.*)\(\)$/',.$er |
22be0 | 72 6f 72 5b 27 6d 65 73 73 61 67 65 27 5d 2c 20 24 6d 61 74 63 68 65 73 29 3b 0a 20 20 20 20 20 | ror['message'],.$matches);...... |
22c00 | 20 20 20 69 66 20 28 21 24 6d 61 74 63 68 65 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ...if.(!$matches).{............. |
22c20 | 72 65 74 75 72 6e 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 63 6c 61 73 | return;.........}..........$clas |
22c40 | 73 4e 61 6d 65 20 3d 20 24 6d 61 74 63 68 65 73 5b 31 5d 3b 0a 20 20 20 20 20 20 20 20 24 6d 65 | sName.=.$matches[1];.........$me |
22c60 | 74 68 6f 64 4e 61 6d 65 20 3d 20 24 6d 61 74 63 68 65 73 5b 32 5d 3b 0a 0a 20 20 20 20 20 20 20 | thodName.=.$matches[2];......... |
22c80 | 20 24 6d 65 73 73 61 67 65 20 3d 20 73 70 72 69 6e 74 66 28 27 41 74 74 65 6d 70 74 65 64 20 74 | .$message.=.sprintf('Attempted.t |
22ca0 | 6f 20 63 61 6c 6c 20 61 6e 20 75 6e 64 65 66 69 6e 65 64 20 6d 65 74 68 6f 64 20 6e 61 6d 65 64 | o.call.an.undefined.method.named |
22cc0 | 20 22 25 73 22 20 6f 66 20 63 6c 61 73 73 20 22 25 73 22 2e 27 2c 20 24 6d 65 74 68 6f 64 4e 61 | ."%s".of.class."%s".',.$methodNa |
22ce0 | 6d 65 2c 20 24 63 6c 61 73 73 4e 61 6d 65 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 63 61 6e 64 69 | me,.$className);..........$candi |
22d00 | 64 61 74 65 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 | dates.=.array();.........foreach |
22d20 | 20 28 67 65 74 5f 63 6c 61 73 73 5f 6d 65 74 68 6f 64 73 28 24 63 6c 61 73 73 4e 61 6d 65 29 20 | .(get_class_methods($className). |
22d40 | 61 73 20 24 64 65 66 69 6e 65 64 4d 65 74 68 6f 64 4e 61 6d 65 29 20 7b 0a 20 20 20 20 20 20 20 | as.$definedMethodName).{........ |
22d60 | 20 20 20 20 20 24 6c 65 76 20 3d 20 6c 65 76 65 6e 73 68 74 65 69 6e 28 24 6d 65 74 68 6f 64 4e | .....$lev.=.levenshtein($methodN |
22d80 | 61 6d 65 2c 20 24 64 65 66 69 6e 65 64 4d 65 74 68 6f 64 4e 61 6d 65 29 3b 0a 20 20 20 20 20 20 | ame,.$definedMethodName);....... |
22da0 | 20 20 20 20 20 20 69 66 20 28 24 6c 65 76 20 3c 3d 20 73 74 72 6c 65 6e 28 24 6d 65 74 68 6f 64 | ......if.($lev.<=.strlen($method |
22dc0 | 4e 61 6d 65 29 20 2f 20 33 20 7c 7c 20 66 61 6c 73 65 20 21 3d 3d 20 73 74 72 70 6f 73 28 24 64 | Name)./.3.||.false.!==.strpos($d |
22de0 | 65 66 69 6e 65 64 4d 65 74 68 6f 64 4e 61 6d 65 2c 20 24 6d 65 74 68 6f 64 4e 61 6d 65 29 29 20 | efinedMethodName,.$methodName)). |
22e00 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 63 61 6e 64 69 64 61 74 65 73 5b 5d 20 | {.................$candidates[]. |
22e20 | 3d 20 24 64 65 66 69 6e 65 64 4d 65 74 68 6f 64 4e 61 6d 65 3b 0a 20 20 20 20 20 20 20 20 20 20 | =.$definedMethodName;........... |
22e40 | 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 63 61 6e 64 | ..}.........}..........if.($cand |
22e60 | 69 64 61 74 65 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 73 6f 72 74 28 24 63 61 6e 64 | idates).{.............sort($cand |
22e80 | 69 64 61 74 65 73 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 61 73 74 20 3d 20 61 72 72 | idates);.............$last.=.arr |
22ea0 | 61 79 5f 70 6f 70 28 24 63 61 6e 64 69 64 61 74 65 73 29 2e 27 22 3f 27 3b 0a 20 20 20 20 20 20 | ay_pop($candidates).'"?';....... |
22ec0 | 20 20 20 20 20 20 69 66 20 28 24 63 61 6e 64 69 64 61 74 65 73 29 20 7b 0a 20 20 20 20 20 20 20 | ......if.($candidates).{........ |
22ee0 | 20 20 20 20 20 20 20 20 20 24 63 61 6e 64 69 64 61 74 65 73 20 3d 20 27 65 2e 67 2e 20 22 27 2e | .........$candidates.=.'e.g.."'. |
22f00 | 69 6d 70 6c 6f 64 65 28 27 22 2c 20 22 27 2c 20 24 63 61 6e 64 69 64 61 74 65 73 29 2e 27 22 20 | implode('",."',.$candidates).'". |
22f20 | 6f 72 20 22 27 2e 24 6c 61 73 74 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 | or."'.$last;.............}.else. |
22f40 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 63 61 6e 64 69 64 61 74 65 73 20 3d 20 | {.................$candidates.=. |
22f60 | 27 22 27 2e 24 6c 61 73 74 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 | '"'.$last;.............}........ |
22f80 | 20 20 20 20 20 24 6d 65 73 73 61 67 65 20 2e 3d 20 22 5c 6e 44 69 64 20 79 6f 75 20 6d 65 61 6e | .....$message..=."\nDid.you.mean |
22fa0 | 20 74 6f 20 63 61 6c 6c 20 22 2e 24 63 61 6e 64 69 64 61 74 65 73 3b 0a 20 20 20 20 20 20 20 20 | .to.call.".$candidates;......... |
22fc0 | 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6e 65 77 20 55 6e 64 65 66 69 6e 65 64 4d | }..........return.new.UndefinedM |
22fe0 | 65 74 68 6f 64 45 78 63 65 70 74 69 6f 6e 28 24 6d 65 73 73 61 67 65 2c 20 24 65 78 63 65 70 74 | ethodException($message,.$except |
23000 | 69 6f 6e 29 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 | ion);.....}.}.<?php../*..*.This. |
23020 | 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b | file.is.part.of.the.Symfony.pack |
23040 | 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 | age...*..*.(c).Fabien.Potencier. |
23060 | 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 | <fabien@symfony.com>..*..*.For.t |
23080 | 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e | he.full.copyright.and.license.in |
230a0 | 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e | formation,.please.view.the.LICEN |
230c0 | 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 | SE..*.file.that.was.distributed. |
230e0 | 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 | with.this.source.code...*/..name |
23100 | 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 44 65 62 75 67 5c 46 61 | space.Symfony\Component\Debug\Fa |
23120 | 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 3b 0a 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f | talErrorHandler;..use.Symfony\Co |
23140 | 6d 70 6f 6e 65 6e 74 5c 44 65 62 75 67 5c 45 78 63 65 70 74 69 6f 6e 5c 46 61 74 61 6c 45 72 72 | mponent\Debug\Exception\FatalErr |
23160 | 6f 72 45 78 63 65 70 74 69 6f 6e 3b 0a 0a 2f 2a 2a 0a 20 2a 20 41 74 74 65 6d 70 74 73 20 74 6f | orException;../**..*.Attempts.to |
23180 | 20 63 6f 6e 76 65 72 74 20 66 61 74 61 6c 20 65 72 72 6f 72 73 20 74 6f 20 65 78 63 65 70 74 69 | .convert.fatal.errors.to.excepti |
231a0 | 6f 6e 73 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 | ons...*..*.@author.Fabien.Potenc |
231c0 | 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 2f 0a 69 6e 74 | ier.<fabien@symfony.com>..*/.int |
231e0 | 65 72 66 61 63 65 20 46 61 74 61 6c 45 72 72 6f 72 48 61 6e 64 6c 65 72 49 6e 74 65 72 66 61 63 | erface.FatalErrorHandlerInterfac |
23200 | 65 0a 7b 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 41 74 74 65 6d 70 74 73 20 74 6f 20 63 | e.{...../**......*.Attempts.to.c |
23220 | 6f 6e 76 65 72 74 20 61 6e 20 65 72 72 6f 72 20 69 6e 74 6f 20 61 6e 20 65 78 63 65 70 74 69 6f | onvert.an.error.into.an.exceptio |
23240 | 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 20 20 | n.......*......*.@param.array... |
23260 | 20 20 20 20 20 20 20 20 20 20 20 20 24 65 72 72 6f 72 20 20 20 20 20 41 6e 20 61 72 72 61 79 20 | ............$error.....An.array. |
23280 | 61 73 20 72 65 74 75 72 6e 65 64 20 62 79 20 65 72 72 6f 72 5f 67 65 74 5f 6c 61 73 74 28 29 0a | as.returned.by.error_get_last(). |
232a0 | 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 46 61 74 61 6c 45 72 72 6f 72 45 78 63 65 70 74 69 6f | .....*.@param.FatalErrorExceptio |
232c0 | 6e 20 24 65 78 63 65 70 74 69 6f 6e 20 41 20 46 61 74 61 6c 45 72 72 6f 72 45 78 63 65 70 74 69 | n.$exception.A.FatalErrorExcepti |
232e0 | 6f 6e 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 | on.instance......*......*.@retur |
23300 | 6e 20 46 61 74 61 6c 45 72 72 6f 72 45 78 63 65 70 74 69 6f 6e 7c 6e 75 6c 6c 20 41 20 46 61 74 | n.FatalErrorException|null.A.Fat |
23320 | 61 6c 45 72 72 6f 72 45 78 63 65 70 74 69 6f 6e 20 69 6e 73 74 61 6e 63 65 20 69 66 20 74 68 65 | alErrorException.instance.if.the |
23340 | 20 63 6c 61 73 73 20 69 73 20 61 62 6c 65 20 74 6f 20 63 6f 6e 76 65 72 74 20 74 68 65 20 65 72 | .class.is.able.to.convert.the.er |
23360 | 72 6f 72 2c 20 6e 75 6c 6c 20 6f 74 68 65 72 77 69 73 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 | ror,.null.otherwise......*/..... |
23380 | 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 68 61 6e 64 6c 65 45 72 72 6f 72 28 61 72 72 61 | public.function.handleError(arra |
233a0 | 79 20 24 65 72 72 6f 72 2c 20 46 61 74 61 6c 45 72 72 6f 72 45 78 63 65 70 74 69 6f 6e 20 24 65 | y.$error,.FatalErrorException.$e |
233c0 | 78 63 65 70 74 69 6f 6e 29 3b 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 | xception);.}.<?php../*..*.This.f |
233e0 | 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 | ile.is.part.of.the.Symfony.packa |
23400 | 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c | ge...*..*.(c).Fabien.Potencier.< |
23420 | 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 | fabien@symfony.com>..*..*.For.th |
23440 | 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 | e.full.copyright.and.license.inf |
23460 | 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 | ormation,.please.view.the.LICENS |
23480 | 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 | E..*.file.that.was.distributed.w |
234a0 | 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 | ith.this.source.code...*/..names |
234c0 | 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 44 65 62 75 67 5c 45 78 63 | pace.Symfony\Component\Debug\Exc |
234e0 | 65 70 74 69 6f 6e 3b 0a 0a 2f 2a 2a 0a 20 2a 20 46 61 74 61 6c 20 54 68 72 6f 77 61 62 6c 65 20 | eption;../**..*.Fatal.Throwable. |
23500 | 45 72 72 6f 72 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 4e 69 63 6f 6c 61 73 20 47 72 65 | Error...*..*.@author.Nicolas.Gre |
23520 | 6b 61 73 20 3c 70 40 74 63 68 77 6f 72 6b 2e 63 6f 6d 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 46 61 | kas.<p@tchwork.com>..*/.class.Fa |
23540 | 74 61 6c 54 68 72 6f 77 61 62 6c 65 45 72 72 6f 72 20 65 78 74 65 6e 64 73 20 46 61 74 61 6c 45 | talThrowableError.extends.FatalE |
23560 | 72 72 6f 72 45 78 63 65 70 74 69 6f 6e 0a 7b 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 | rrorException.{.....public.funct |
23580 | 69 6f 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 74 28 5c 54 68 72 6f 77 61 62 6c 65 20 24 65 29 0a 20 | ion.__construct(\Throwable.$e).. |
235a0 | 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 65 20 69 6e 73 74 61 6e 63 65 6f 66 20 5c | ...{.........if.($e.instanceof.\ |
235c0 | 50 61 72 73 65 45 72 72 6f 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 | ParseError).{.............$messa |
235e0 | 67 65 20 3d 20 27 50 61 72 73 65 20 65 72 72 6f 72 3a 20 27 2e 24 65 2d 3e 67 65 74 4d 65 73 73 | ge.=.'Parse.error:.'.$e->getMess |
23600 | 61 67 65 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 73 65 76 65 72 69 74 79 20 3d 20 45 | age();.............$severity.=.E |
23620 | 5f 50 41 52 53 45 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 24 65 20 69 6e 73 | _PARSE;.........}.elseif.($e.ins |
23640 | 74 61 6e 63 65 6f 66 20 5c 54 79 70 65 45 72 72 6f 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | tanceof.\TypeError).{........... |
23660 | 20 20 24 6d 65 73 73 61 67 65 20 3d 20 27 54 79 70 65 20 65 72 72 6f 72 3a 20 27 2e 24 65 2d 3e | ..$message.=.'Type.error:.'.$e-> |
23680 | 67 65 74 4d 65 73 73 61 67 65 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 73 65 76 65 72 | getMessage();.............$sever |
236a0 | 69 74 79 20 3d 20 45 5f 52 45 43 4f 56 45 52 41 42 4c 45 5f 45 52 52 4f 52 3b 0a 20 20 20 20 20 | ity.=.E_RECOVERABLE_ERROR;...... |
236c0 | 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 | ...}.else.{.............$message |
236e0 | 20 3d 20 24 65 2d 3e 67 65 74 4d 65 73 73 61 67 65 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 | .=.$e->getMessage();............ |
23700 | 20 24 73 65 76 65 72 69 74 79 20 3d 20 45 5f 45 52 52 4f 52 3b 0a 20 20 20 20 20 20 20 20 7d 0a | .$severity.=.E_ERROR;.........}. |
23720 | 0a 20 20 20 20 20 20 20 20 5c 45 72 72 6f 72 45 78 63 65 70 74 69 6f 6e 3a 3a 5f 5f 63 6f 6e 73 | .........\ErrorException::__cons |
23740 | 74 72 75 63 74 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 2c 0a 20 20 20 | truct(.............$message,.... |
23760 | 20 20 20 20 20 20 20 20 20 24 65 2d 3e 67 65 74 43 6f 64 65 28 29 2c 0a 20 20 20 20 20 20 20 20 | .........$e->getCode(),......... |
23780 | 20 20 20 20 24 73 65 76 65 72 69 74 79 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 65 2d 3e 67 | ....$severity,.............$e->g |
237a0 | 65 74 46 69 6c 65 28 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 65 2d 3e 67 65 74 4c 69 6e | etFile(),.............$e->getLin |
237c0 | 65 28 29 0a 20 20 20 20 20 20 20 20 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 | e().........);..........$this->s |
237e0 | 65 74 54 72 61 63 65 28 24 65 2d 3e 67 65 74 54 72 61 63 65 28 29 29 3b 0a 20 20 20 20 7d 0a 7d | etTrace($e->getTrace());.....}.} |
23800 | 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 | .<?php../*..*.This.file.is.part. |
23820 | 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 | of.the.Symfony.package...*..*.(c |
23840 | 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f | ).Fabien.Potencier.<fabien@symfo |
23860 | 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 | ny.com>..*..*.For.the.full.copyr |
23880 | 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c | ight.and.license.information,.pl |
238a0 | 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 | ease.view.the.LICENSE..*.file.th |
238c0 | 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 | at.was.distributed.with.this.sou |
238e0 | 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 | rce.code...*/..namespace.Symfony |
23900 | 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 44 65 62 75 67 5c 45 78 63 65 70 74 69 6f 6e 3b 0a 0a 2f 2a 2a | \Component\Debug\Exception;../** |
23920 | 0a 20 2a 20 4f 75 74 20 6f 66 20 6d 65 6d 6f 72 79 20 65 78 63 65 70 74 69 6f 6e 2e 0a 20 2a 0a | ..*.Out.of.memory.exception...*. |
23940 | 20 2a 20 40 61 75 74 68 6f 72 20 4e 69 63 6f 6c 61 73 20 47 72 65 6b 61 73 20 3c 70 40 74 63 68 | .*.@author.Nicolas.Grekas.<p@tch |
23960 | 77 6f 72 6b 2e 63 6f 6d 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 4f 75 74 4f 66 4d 65 6d 6f 72 79 45 | work.com>..*/.class.OutOfMemoryE |
23980 | 78 63 65 70 74 69 6f 6e 20 65 78 74 65 6e 64 73 20 46 61 74 61 6c 45 72 72 6f 72 45 78 63 65 70 | xception.extends.FatalErrorExcep |
239a0 | 74 69 6f 6e 0a 7b 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 | tion.{.}.<?php../*..*.This.file. |
239c0 | 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a | is.part.of.the.Symfony.package.. |
239e0 | 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 | .*..*.(c).Fabien.Potencier.<fabi |
23a00 | 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 | en@symfony.com>..*..*.For.the.fu |
23a20 | 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 | ll.copyright.and.license.informa |
23a40 | 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a | tion,.please.view.the.LICENSE..* |
23a60 | 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 | .file.that.was.distributed.with. |
23a80 | 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 | this.source.code...*/..namespace |
23aa0 | 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 44 65 62 75 67 5c 45 78 63 65 70 74 69 | .Symfony\Component\Debug\Excepti |
23ac0 | 6f 6e 3b 0a 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 48 74 74 70 4b | on;..use.Symfony\Component\HttpK |
23ae0 | 65 72 6e 65 6c 5c 45 78 63 65 70 74 69 6f 6e 5c 48 74 74 70 45 78 63 65 70 74 69 6f 6e 49 6e 74 | ernel\Exception\HttpExceptionInt |
23b00 | 65 72 66 61 63 65 3b 0a 0a 2f 2a 2a 0a 20 2a 20 46 6c 61 74 74 65 6e 45 78 63 65 70 74 69 6f 6e | erface;../**..*.FlattenException |
23b20 | 20 77 72 61 70 73 20 61 20 50 48 50 20 45 78 63 65 70 74 69 6f 6e 20 74 6f 20 62 65 20 61 62 6c | .wraps.a.PHP.Exception.to.be.abl |
23b40 | 65 20 74 6f 20 73 65 72 69 61 6c 69 7a 65 20 69 74 2e 0a 20 2a 0a 20 2a 20 42 61 73 69 63 61 6c | e.to.serialize.it...*..*.Basical |
23b60 | 6c 79 2c 20 74 68 69 73 20 63 6c 61 73 73 20 72 65 6d 6f 76 65 73 20 61 6c 6c 20 6f 62 6a 65 63 | ly,.this.class.removes.all.objec |
23b80 | 74 73 20 66 72 6f 6d 20 74 68 65 20 74 72 61 63 65 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 | ts.from.the.trace...*..*.@author |
23ba0 | 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e | .Fabien.Potencier.<fabien@symfon |
23bc0 | 79 2e 63 6f 6d 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 46 6c 61 74 74 65 6e 45 78 63 65 70 74 69 6f | y.com>..*/.class.FlattenExceptio |
23be0 | 6e 0a 7b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 6d 65 73 73 61 67 65 3b 0a 20 20 20 20 70 72 | n.{.....private.$message;.....pr |
23c00 | 69 76 61 74 65 20 24 63 6f 64 65 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 70 72 65 76 69 6f | ivate.$code;.....private.$previo |
23c20 | 75 73 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 74 72 61 63 65 3b 0a 20 20 20 20 70 72 69 76 | us;.....private.$trace;.....priv |
23c40 | 61 74 65 20 24 63 6c 61 73 73 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 73 74 61 74 75 73 43 | ate.$class;.....private.$statusC |
23c60 | 6f 64 65 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 68 65 61 64 65 72 73 3b 0a 20 20 20 20 70 | ode;.....private.$headers;.....p |
23c80 | 72 69 76 61 74 65 20 24 66 69 6c 65 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 6c 69 6e 65 3b | rivate.$file;.....private.$line; |
23ca0 | 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 63 72 65 | ......public.static.function.cre |
23cc0 | 61 74 65 28 5c 45 78 63 65 70 74 69 6f 6e 20 24 65 78 63 65 70 74 69 6f 6e 2c 20 24 73 74 61 74 | ate(\Exception.$exception,.$stat |
23ce0 | 75 73 43 6f 64 65 20 3d 20 6e 75 6c 6c 2c 20 61 72 72 61 79 20 24 68 65 61 64 65 72 73 20 3d 20 | usCode.=.null,.array.$headers.=. |
23d00 | 61 72 72 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 65 20 3d 20 6e 65 77 20 | array()).....{.........$e.=.new. |
23d20 | 73 74 61 74 69 63 28 29 3b 0a 20 20 20 20 20 20 20 20 24 65 2d 3e 73 65 74 4d 65 73 73 61 67 65 | static();.........$e->setMessage |
23d40 | 28 24 65 78 63 65 70 74 69 6f 6e 2d 3e 67 65 74 4d 65 73 73 61 67 65 28 29 29 3b 0a 20 20 20 20 | ($exception->getMessage());..... |
23d60 | 20 20 20 20 24 65 2d 3e 73 65 74 43 6f 64 65 28 24 65 78 63 65 70 74 69 6f 6e 2d 3e 67 65 74 43 | ....$e->setCode($exception->getC |
23d80 | 6f 64 65 28 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 65 78 63 65 70 74 69 6f 6e 20 | ode());..........if.($exception. |
23da0 | 69 6e 73 74 61 6e 63 65 6f 66 20 48 74 74 70 45 78 63 65 70 74 69 6f 6e 49 6e 74 65 72 66 61 63 | instanceof.HttpExceptionInterfac |
23dc0 | 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 73 74 61 74 75 73 43 6f 64 65 20 3d 20 24 | e).{.............$statusCode.=.$ |
23de0 | 65 78 63 65 70 74 69 6f 6e 2d 3e 67 65 74 53 74 61 74 75 73 43 6f 64 65 28 29 3b 0a 20 20 20 20 | exception->getStatusCode();..... |
23e00 | 20 20 20 20 20 20 20 20 24 68 65 61 64 65 72 73 20 3d 20 61 72 72 61 79 5f 6d 65 72 67 65 28 24 | ........$headers.=.array_merge($ |
23e20 | 68 65 61 64 65 72 73 2c 20 24 65 78 63 65 70 74 69 6f 6e 2d 3e 67 65 74 48 65 61 64 65 72 73 28 | headers,.$exception->getHeaders( |
23e40 | 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 | ));.........}..........if.(null. |
23e60 | 3d 3d 3d 20 24 73 74 61 74 75 73 43 6f 64 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 | ===.$statusCode).{.............$ |
23e80 | 73 74 61 74 75 73 43 6f 64 65 20 3d 20 35 30 30 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 | statusCode.=.500;.........}..... |
23ea0 | 20 20 20 20 20 24 65 2d 3e 73 65 74 53 74 61 74 75 73 43 6f 64 65 28 24 73 74 61 74 75 73 43 6f | .....$e->setStatusCode($statusCo |
23ec0 | 64 65 29 3b 0a 20 20 20 20 20 20 20 20 24 65 2d 3e 73 65 74 48 65 61 64 65 72 73 28 24 68 65 61 | de);.........$e->setHeaders($hea |
23ee0 | 64 65 72 73 29 3b 0a 20 20 20 20 20 20 20 20 24 65 2d 3e 73 65 74 54 72 61 63 65 46 72 6f 6d 45 | ders);.........$e->setTraceFromE |
23f00 | 78 63 65 70 74 69 6f 6e 28 24 65 78 63 65 70 74 69 6f 6e 29 3b 0a 20 20 20 20 20 20 20 20 24 65 | xception($exception);.........$e |
23f20 | 2d 3e 73 65 74 43 6c 61 73 73 28 67 65 74 5f 63 6c 61 73 73 28 24 65 78 63 65 70 74 69 6f 6e 29 | ->setClass(get_class($exception) |
23f40 | 29 3b 0a 20 20 20 20 20 20 20 20 24 65 2d 3e 73 65 74 46 69 6c 65 28 24 65 78 63 65 70 74 69 6f | );.........$e->setFile($exceptio |
23f60 | 6e 2d 3e 67 65 74 46 69 6c 65 28 29 29 3b 0a 20 20 20 20 20 20 20 20 24 65 2d 3e 73 65 74 4c 69 | n->getFile());.........$e->setLi |
23f80 | 6e 65 28 24 65 78 63 65 70 74 69 6f 6e 2d 3e 67 65 74 4c 69 6e 65 28 29 29 3b 0a 0a 20 20 20 20 | ne($exception->getLine());...... |
23fa0 | 20 20 20 20 24 70 72 65 76 69 6f 75 73 20 3d 20 24 65 78 63 65 70 74 69 6f 6e 2d 3e 67 65 74 50 | ....$previous.=.$exception->getP |
23fc0 | 72 65 76 69 6f 75 73 28 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 70 72 65 76 69 6f 75 | revious();..........if.($previou |
23fe0 | 73 20 69 6e 73 74 61 6e 63 65 6f 66 20 5c 45 78 63 65 70 74 69 6f 6e 29 20 7b 0a 20 20 20 20 20 | s.instanceof.\Exception).{...... |
24000 | 20 20 20 20 20 20 20 24 65 2d 3e 73 65 74 50 72 65 76 69 6f 75 73 28 73 74 61 74 69 63 3a 3a 63 | .......$e->setPrevious(static::c |
24020 | 72 65 61 74 65 28 24 70 72 65 76 69 6f 75 73 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 | reate($previous));.........}.els |
24040 | 65 69 66 20 28 24 70 72 65 76 69 6f 75 73 20 69 6e 73 74 61 6e 63 65 6f 66 20 5c 54 68 72 6f 77 | eif.($previous.instanceof.\Throw |
24060 | 61 62 6c 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 65 2d 3e 73 65 74 50 72 65 76 69 | able).{.............$e->setPrevi |
24080 | 6f 75 73 28 73 74 61 74 69 63 3a 3a 63 72 65 61 74 65 28 6e 65 77 20 46 61 74 61 6c 54 68 72 6f | ous(static::create(new.FatalThro |
240a0 | 77 61 62 6c 65 45 72 72 6f 72 28 24 70 72 65 76 69 6f 75 73 29 29 29 3b 0a 20 20 20 20 20 20 20 | wableError($previous)));........ |
240c0 | 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 | .}..........return.$e;.....}.... |
240e0 | 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 74 6f 41 72 72 61 79 28 29 0a 20 20 20 20 | ..public.function.toArray()..... |
24100 | 7b 0a 20 20 20 20 20 20 20 20 24 65 78 63 65 70 74 69 6f 6e 73 20 3d 20 61 72 72 61 79 28 29 3b | {.........$exceptions.=.array(); |
24120 | 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 61 72 72 61 79 5f 6d 65 72 67 65 28 61 72 | .........foreach.(array_merge(ar |
24140 | 72 61 79 28 24 74 68 69 73 29 2c 20 24 74 68 69 73 2d 3e 67 65 74 41 6c 6c 50 72 65 76 69 6f 75 | ray($this),.$this->getAllPreviou |
24160 | 73 28 29 29 20 61 73 20 24 65 78 63 65 70 74 69 6f 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | s()).as.$exception).{........... |
24180 | 20 20 24 65 78 63 65 70 74 69 6f 6e 73 5b 5d 20 3d 20 61 72 72 61 79 28 0a 20 20 20 20 20 20 20 | ..$exceptions[].=.array(........ |
241a0 | 20 20 20 20 20 20 20 20 20 27 6d 65 73 73 61 67 65 27 20 3d 3e 20 24 65 78 63 65 70 74 69 6f 6e | .........'message'.=>.$exception |
241c0 | 2d 3e 67 65 74 4d 65 73 73 61 67 65 28 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ->getMessage(),................. |
241e0 | 27 63 6c 61 73 73 27 20 3d 3e 20 24 65 78 63 65 70 74 69 6f 6e 2d 3e 67 65 74 43 6c 61 73 73 28 | 'class'.=>.$exception->getClass( |
24200 | 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 27 74 72 61 63 65 27 20 3d 3e 20 24 65 | ),.................'trace'.=>.$e |
24220 | 78 63 65 70 74 69 6f 6e 2d 3e 67 65 74 54 72 61 63 65 28 29 2c 0a 20 20 20 20 20 20 20 20 20 20 | xception->getTrace(),........... |
24240 | 20 20 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 | ..);.........}..........return.$ |
24260 | 65 78 63 65 70 74 69 6f 6e 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 | exceptions;.....}......public.fu |
24280 | 6e 63 74 69 6f 6e 20 67 65 74 53 74 61 74 75 73 43 6f 64 65 28 29 0a 20 20 20 20 7b 0a 20 20 20 | nction.getStatusCode().....{.... |
242a0 | 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 73 74 61 74 75 73 43 6f 64 65 3b 0a 20 | .....return.$this->statusCode;.. |
242c0 | 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 53 74 61 | ...}......public.function.setSta |
242e0 | 74 75 73 43 6f 64 65 28 24 63 6f 64 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 | tusCode($code).....{.........$th |
24300 | 69 73 2d 3e 73 74 61 74 75 73 43 6f 64 65 20 3d 20 24 63 6f 64 65 3b 0a 20 20 20 20 7d 0a 0a 20 | is->statusCode.=.$code;.....}... |
24320 | 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 48 65 61 64 65 72 73 28 29 0a | ...public.function.getHeaders(). |
24340 | 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 68 65 61 64 | ....{.........return.$this->head |
24360 | 65 72 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 | ers;.....}......public.function. |
24380 | 73 65 74 48 65 61 64 65 72 73 28 61 72 72 61 79 20 24 68 65 61 64 65 72 73 29 0a 20 20 20 20 7b | setHeaders(array.$headers).....{ |
243a0 | 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 68 65 61 64 65 72 73 20 3d 20 24 68 65 61 64 65 | .........$this->headers.=.$heade |
243c0 | 72 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 | rs;.....}......public.function.g |
243e0 | 65 74 43 6c 61 73 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 | etClass().....{.........return.$ |
24400 | 74 68 69 73 2d 3e 63 6c 61 73 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 66 | this->class;.....}......public.f |
24420 | 75 6e 63 74 69 6f 6e 20 73 65 74 43 6c 61 73 73 28 24 63 6c 61 73 73 29 0a 20 20 20 20 7b 0a 20 | unction.setClass($class).....{.. |
24440 | 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 63 6c 61 73 73 20 3d 20 24 63 6c 61 73 73 3b 0a 20 20 | .......$this->class.=.$class;... |
24460 | 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 46 69 6c 65 | ..}......public.function.getFile |
24480 | 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 66 | ().....{.........return.$this->f |
244a0 | 69 6c 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 | ile;.....}......public.function. |
244c0 | 73 65 74 46 69 6c 65 28 24 66 69 6c 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 | setFile($file).....{.........$th |
244e0 | 69 73 2d 3e 66 69 6c 65 20 3d 20 24 66 69 6c 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 | is->file.=.$file;.....}......pub |
24500 | 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 4c 69 6e 65 28 29 0a 20 20 20 20 7b 0a 20 20 20 | lic.function.getLine().....{.... |
24520 | 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 6c 69 6e 65 3b 0a 20 20 20 20 7d 0a 0a | .....return.$this->line;.....}.. |
24540 | 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 4c 69 6e 65 28 24 6c 69 6e | ....public.function.setLine($lin |
24560 | 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6c 69 6e 65 20 3d 20 24 | e).....{.........$this->line.=.$ |
24580 | 6c 69 6e 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e | line;.....}......public.function |
245a0 | 20 67 65 74 4d 65 73 73 61 67 65 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 | .getMessage().....{.........retu |
245c0 | 72 6e 20 24 74 68 69 73 2d 3e 6d 65 73 73 61 67 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 | rn.$this->message;.....}......pu |
245e0 | 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 4d 65 73 73 61 67 65 28 24 6d 65 73 73 61 67 | blic.function.setMessage($messag |
24600 | 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6d 65 73 73 61 67 65 20 | e).....{.........$this->message. |
24620 | 3d 20 24 6d 65 73 73 61 67 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 | =.$message;.....}......public.fu |
24640 | 6e 63 74 69 6f 6e 20 67 65 74 43 6f 64 65 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 | nction.getCode().....{.........r |
24660 | 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 63 6f 64 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 | eturn.$this->code;.....}......pu |
24680 | 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 43 6f 64 65 28 24 63 6f 64 65 29 0a 20 20 20 | blic.function.setCode($code).... |
246a0 | 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 63 6f 64 65 20 3d 20 24 63 6f 64 65 3b 0a | .{.........$this->code.=.$code;. |
246c0 | 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 50 72 | ....}......public.function.getPr |
246e0 | 65 76 69 6f 75 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 | evious().....{.........return.$t |
24700 | 68 69 73 2d 3e 70 72 65 76 69 6f 75 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 | his->previous;.....}......public |
24720 | 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 50 72 65 76 69 6f 75 73 28 46 6c 61 74 74 65 6e 45 78 63 | .function.setPrevious(FlattenExc |
24740 | 65 70 74 69 6f 6e 20 24 70 72 65 76 69 6f 75 73 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | eption.$previous).....{......... |
24760 | 24 74 68 69 73 2d 3e 70 72 65 76 69 6f 75 73 20 3d 20 24 70 72 65 76 69 6f 75 73 3b 0a 20 20 20 | $this->previous.=.$previous;.... |
24780 | 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 41 6c 6c 50 72 | .}......public.function.getAllPr |
247a0 | 65 76 69 6f 75 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 65 78 63 65 70 74 69 6f | evious().....{.........$exceptio |
247c0 | 6e 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 24 65 20 3d 20 24 74 68 69 73 | ns.=.array();.........$e.=.$this |
247e0 | 3b 0a 20 20 20 20 20 20 20 20 77 68 69 6c 65 20 28 24 65 20 3d 20 24 65 2d 3e 67 65 74 50 72 65 | ;.........while.($e.=.$e->getPre |
24800 | 76 69 6f 75 73 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 65 78 63 65 70 74 69 6f | vious()).{.............$exceptio |
24820 | 6e 73 5b 5d 20 3d 20 24 65 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 | ns[].=.$e;.........}..........re |
24840 | 74 75 72 6e 20 24 65 78 63 65 70 74 69 6f 6e 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 | turn.$exceptions;.....}......pub |
24860 | 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 54 72 61 63 65 28 29 0a 20 20 20 20 7b 0a 20 20 | lic.function.getTrace().....{... |
24880 | 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 74 72 61 63 65 3b 0a 20 20 20 20 7d | ......return.$this->trace;.....} |
248a0 | 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 54 72 61 63 65 46 72 | ......public.function.setTraceFr |
248c0 | 6f 6d 45 78 63 65 70 74 69 6f 6e 28 5c 45 78 63 65 70 74 69 6f 6e 20 24 65 78 63 65 70 74 69 6f | omException(\Exception.$exceptio |
248e0 | 6e 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 65 74 54 72 61 63 65 | n).....{.........$this->setTrace |
24900 | 28 24 65 78 63 65 70 74 69 6f 6e 2d 3e 67 65 74 54 72 61 63 65 28 29 2c 20 24 65 78 63 65 70 74 | ($exception->getTrace(),.$except |
24920 | 69 6f 6e 2d 3e 67 65 74 46 69 6c 65 28 29 2c 20 24 65 78 63 65 70 74 69 6f 6e 2d 3e 67 65 74 4c | ion->getFile(),.$exception->getL |
24940 | 69 6e 65 28 29 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 | ine());.....}......public.functi |
24960 | 6f 6e 20 73 65 74 54 72 61 63 65 28 24 74 72 61 63 65 2c 20 24 66 69 6c 65 2c 20 24 6c 69 6e 65 | on.setTrace($trace,.$file,.$line |
24980 | 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 74 72 61 63 65 20 3d 20 61 | ).....{.........$this->trace.=.a |
249a0 | 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 74 72 61 63 65 5b 5d 20 3d | rray();.........$this->trace[].= |
249c0 | 20 61 72 72 61 79 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 6e 61 6d 65 73 70 61 63 65 27 20 | .array(.............'namespace'. |
249e0 | 3d 3e 20 27 27 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 73 68 6f 72 74 5f 63 6c 61 73 73 27 | =>.'',.............'short_class' |
24a00 | 20 3d 3e 20 27 27 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 63 6c 61 73 73 27 20 3d 3e 20 27 | .=>.'',.............'class'.=>.' |
24a20 | 27 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 74 79 70 65 27 20 3d 3e 20 27 27 2c 0a 20 20 20 | ',.............'type'.=>.'',.... |
24a40 | 20 20 20 20 20 20 20 20 20 27 66 75 6e 63 74 69 6f 6e 27 20 3d 3e 20 27 27 2c 0a 20 20 20 20 20 | .........'function'.=>.'',...... |
24a60 | 20 20 20 20 20 20 20 27 66 69 6c 65 27 20 3d 3e 20 24 66 69 6c 65 2c 0a 20 20 20 20 20 20 20 20 | .......'file'.=>.$file,......... |
24a80 | 20 20 20 20 27 6c 69 6e 65 27 20 3d 3e 20 24 6c 69 6e 65 2c 0a 20 20 20 20 20 20 20 20 20 20 20 | ....'line'.=>.$line,............ |
24aa0 | 20 27 61 72 67 73 27 20 3d 3e 20 61 72 72 61 79 28 29 2c 0a 20 20 20 20 20 20 20 20 29 3b 0a 20 | .'args'.=>.array(),.........);.. |
24ac0 | 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 74 72 61 63 65 20 61 73 20 24 65 6e 74 72 79 | .......foreach.($trace.as.$entry |
24ae0 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6c 61 73 73 20 3d 20 27 27 3b 0a 20 20 20 | ).{.............$class.=.'';.... |
24b00 | 20 20 20 20 20 20 20 20 20 24 6e 61 6d 65 73 70 61 63 65 20 3d 20 27 27 3b 0a 20 20 20 20 20 20 | .........$namespace.=.'';....... |
24b20 | 20 20 20 20 20 20 69 66 20 28 69 73 73 65 74 28 24 65 6e 74 72 79 5b 27 63 6c 61 73 73 27 5d 29 | ......if.(isset($entry['class']) |
24b40 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 70 61 72 74 73 20 3d 20 65 78 70 | ).{.................$parts.=.exp |
24b60 | 6c 6f 64 65 28 27 5c 5c 27 2c 20 24 65 6e 74 72 79 5b 27 63 6c 61 73 73 27 5d 29 3b 0a 20 20 20 | lode('\\',.$entry['class']);.... |
24b80 | 20 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6c 61 73 73 20 3d 20 61 72 72 61 79 5f 70 6f 70 28 | .............$class.=.array_pop( |
24ba0 | 24 70 61 72 74 73 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6e 61 6d 65 73 70 | $parts);.................$namesp |
24bc0 | 61 63 65 20 3d 20 69 6d 70 6c 6f 64 65 28 27 5c 5c 27 2c 20 24 70 61 72 74 73 29 3b 0a 20 20 20 | ace.=.implode('\\',.$parts);.... |
24be0 | 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 74 | .........}..............$this->t |
24c00 | 72 61 63 65 5b 5d 20 3d 20 61 72 72 61 79 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | race[].=.array(................. |
24c20 | 27 6e 61 6d 65 73 70 61 63 65 27 20 3d 3e 20 24 6e 61 6d 65 73 70 61 63 65 2c 0a 20 20 20 20 20 | 'namespace'.=>.$namespace,...... |
24c40 | 20 20 20 20 20 20 20 20 20 20 20 27 73 68 6f 72 74 5f 63 6c 61 73 73 27 20 3d 3e 20 24 63 6c 61 | ...........'short_class'.=>.$cla |
24c60 | 73 73 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 27 63 6c 61 73 73 27 20 3d 3e 20 69 | ss,.................'class'.=>.i |
24c80 | 73 73 65 74 28 24 65 6e 74 72 79 5b 27 63 6c 61 73 73 27 5d 29 20 3f 20 24 65 6e 74 72 79 5b 27 | sset($entry['class']).?.$entry[' |
24ca0 | 63 6c 61 73 73 27 5d 20 3a 20 27 27 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 27 74 | class'].:.'',.................'t |
24cc0 | 79 70 65 27 20 3d 3e 20 69 73 73 65 74 28 24 65 6e 74 72 79 5b 27 74 79 70 65 27 5d 29 20 3f 20 | ype'.=>.isset($entry['type']).?. |
24ce0 | 24 65 6e 74 72 79 5b 27 74 79 70 65 27 5d 20 3a 20 27 27 2c 0a 20 20 20 20 20 20 20 20 20 20 20 | $entry['type'].:.'',............ |
24d00 | 20 20 20 20 20 27 66 75 6e 63 74 69 6f 6e 27 20 3d 3e 20 69 73 73 65 74 28 24 65 6e 74 72 79 5b | .....'function'.=>.isset($entry[ |
24d20 | 27 66 75 6e 63 74 69 6f 6e 27 5d 29 20 3f 20 24 65 6e 74 72 79 5b 27 66 75 6e 63 74 69 6f 6e 27 | 'function']).?.$entry['function' |
24d40 | 5d 20 3a 20 6e 75 6c 6c 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 27 66 69 6c 65 27 | ].:.null,.................'file' |
24d60 | 20 3d 3e 20 69 73 73 65 74 28 24 65 6e 74 72 79 5b 27 66 69 6c 65 27 5d 29 20 3f 20 24 65 6e 74 | .=>.isset($entry['file']).?.$ent |
24d80 | 72 79 5b 27 66 69 6c 65 27 5d 20 3a 20 6e 75 6c 6c 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | ry['file'].:.null,.............. |
24da0 | 20 20 20 27 6c 69 6e 65 27 20 3d 3e 20 69 73 73 65 74 28 24 65 6e 74 72 79 5b 27 6c 69 6e 65 27 | ...'line'.=>.isset($entry['line' |
24dc0 | 5d 29 20 3f 20 24 65 6e 74 72 79 5b 27 6c 69 6e 65 27 5d 20 3a 20 6e 75 6c 6c 2c 0a 20 20 20 20 | ]).?.$entry['line'].:.null,..... |
24de0 | 20 20 20 20 20 20 20 20 20 20 20 20 27 61 72 67 73 27 20 3d 3e 20 69 73 73 65 74 28 24 65 6e 74 | ............'args'.=>.isset($ent |
24e00 | 72 79 5b 27 61 72 67 73 27 5d 29 20 3f 20 24 74 68 69 73 2d 3e 66 6c 61 74 74 65 6e 41 72 67 73 | ry['args']).?.$this->flattenArgs |
24e20 | 28 24 65 6e 74 72 79 5b 27 61 72 67 73 27 5d 29 20 3a 20 61 72 72 61 79 28 29 2c 0a 20 20 20 20 | ($entry['args']).:.array(),..... |
24e40 | 20 20 20 20 20 20 20 20 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 | ........);.........}.....}...... |
24e60 | 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 66 6c 61 74 74 65 6e 41 72 67 73 28 24 61 72 | private.function.flattenArgs($ar |
24e80 | 67 73 2c 20 24 6c 65 76 65 6c 20 3d 20 30 2c 20 26 24 63 6f 75 6e 74 20 3d 20 30 29 0a 20 20 20 | gs,.$level.=.0,.&$count.=.0).... |
24ea0 | 20 7b 0a 20 20 20 20 20 20 20 20 24 72 65 73 75 6c 74 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 | .{.........$result.=.array();... |
24ec0 | 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 61 72 67 73 20 61 73 20 24 6b 65 79 20 3d 3e 20 | ......foreach.($args.as.$key.=>. |
24ee0 | 24 76 61 6c 75 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 2b 2b 24 63 6f 75 | $value).{.............if.(++$cou |
24f00 | 6e 74 20 3e 20 31 65 34 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 | nt.>.1e4).{.................retu |
24f20 | 72 6e 20 61 72 72 61 79 28 27 61 72 72 61 79 27 2c 20 27 2a 53 4b 49 50 50 45 44 20 6f 76 65 72 | rn.array('array',.'*SKIPPED.over |
24f40 | 20 31 30 30 30 30 20 65 6e 74 72 69 65 73 2a 27 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d | .10000.entries*');.............} |
24f60 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 76 61 6c 75 65 20 69 6e 73 74 61 6e 63 65 | .............if.($value.instance |
24f80 | 6f 66 20 5c 5f 5f 50 48 50 5f 49 6e 63 6f 6d 70 6c 65 74 65 5f 43 6c 61 73 73 29 20 7b 0a 20 20 | of.\__PHP_Incomplete_Class).{... |
24fa0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 69 73 5f 6f 62 6a 65 63 74 28 29 20 72 65 74 | ..............//.is_object().ret |
24fc0 | 75 72 6e 73 20 66 61 6c 73 65 20 6f 6e 20 50 48 50 3c 3d 37 2e 31 0a 20 20 20 20 20 20 20 20 20 | urns.false.on.PHP<=7.1.......... |
24fe0 | 20 20 20 20 20 20 20 24 72 65 73 75 6c 74 5b 24 6b 65 79 5d 20 3d 20 61 72 72 61 79 28 27 69 6e | .......$result[$key].=.array('in |
25000 | 63 6f 6d 70 6c 65 74 65 2d 6f 62 6a 65 63 74 27 2c 20 24 74 68 69 73 2d 3e 67 65 74 43 6c 61 73 | complete-object',.$this->getClas |
25020 | 73 4e 61 6d 65 46 72 6f 6d 49 6e 63 6f 6d 70 6c 65 74 65 28 24 76 61 6c 75 65 29 29 3b 0a 20 20 | sNameFromIncomplete($value));... |
25040 | 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 69 73 5f 6f 62 6a 65 63 74 28 24 76 | ..........}.elseif.(is_object($v |
25060 | 61 6c 75 65 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 72 65 73 75 6c 74 | alue)).{.................$result |
25080 | 5b 24 6b 65 79 5d 20 3d 20 61 72 72 61 79 28 27 6f 62 6a 65 63 74 27 2c 20 67 65 74 5f 63 6c 61 | [$key].=.array('object',.get_cla |
250a0 | 73 73 28 24 76 61 6c 75 65 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 | ss($value));.............}.elsei |
250c0 | 66 20 28 69 73 5f 61 72 72 61 79 28 24 76 61 6c 75 65 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | f.(is_array($value)).{.......... |
250e0 | 20 20 20 20 20 20 20 69 66 20 28 24 6c 65 76 65 6c 20 3e 20 31 30 29 20 7b 0a 20 20 20 20 20 20 | .......if.($level.>.10).{....... |
25100 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 72 65 73 75 6c 74 5b 24 6b 65 79 5d 20 3d 20 61 72 | ..............$result[$key].=.ar |
25120 | 72 61 79 28 27 61 72 72 61 79 27 2c 20 27 2a 44 45 45 50 20 4e 45 53 54 45 44 20 41 52 52 41 59 | ray('array',.'*DEEP.NESTED.ARRAY |
25140 | 2a 27 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 | *');.................}.else.{... |
25160 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 72 65 73 75 6c 74 5b 24 6b 65 79 5d 20 | ..................$result[$key]. |
25180 | 3d 20 61 72 72 61 79 28 27 61 72 72 61 79 27 2c 20 24 74 68 69 73 2d 3e 66 6c 61 74 74 65 6e 41 | =.array('array',.$this->flattenA |
251a0 | 72 67 73 28 24 76 61 6c 75 65 2c 20 24 6c 65 76 65 6c 20 2b 20 31 2c 20 24 63 6f 75 6e 74 29 29 | rgs($value,.$level.+.1,.$count)) |
251c0 | 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ;.................}............. |
251e0 | 7d 20 65 6c 73 65 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 76 61 6c 75 65 29 20 7b 0a 20 20 20 | }.elseif.(null.===.$value).{.... |
25200 | 20 20 20 20 20 20 20 20 20 20 20 20 20 24 72 65 73 75 6c 74 5b 24 6b 65 79 5d 20 3d 20 61 72 72 | .............$result[$key].=.arr |
25220 | 61 79 28 27 6e 75 6c 6c 27 2c 20 6e 75 6c 6c 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 | ay('null',.null);.............}. |
25240 | 65 6c 73 65 69 66 20 28 69 73 5f 62 6f 6f 6c 28 24 76 61 6c 75 65 29 29 20 7b 0a 20 20 20 20 20 | elseif.(is_bool($value)).{...... |
25260 | 20 20 20 20 20 20 20 20 20 20 20 24 72 65 73 75 6c 74 5b 24 6b 65 79 5d 20 3d 20 61 72 72 61 79 | ...........$result[$key].=.array |
25280 | 28 27 62 6f 6f 6c 65 61 6e 27 2c 20 24 76 61 6c 75 65 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 | ('boolean',.$value);............ |
252a0 | 20 7d 20 65 6c 73 65 69 66 20 28 69 73 5f 72 65 73 6f 75 72 63 65 28 24 76 61 6c 75 65 29 29 20 | .}.elseif.(is_resource($value)). |
252c0 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 72 65 73 75 6c 74 5b 24 6b 65 79 5d 20 | {.................$result[$key]. |
252e0 | 3d 20 61 72 72 61 79 28 27 72 65 73 6f 75 72 63 65 27 2c 20 67 65 74 5f 72 65 73 6f 75 72 63 65 | =.array('resource',.get_resource |
25300 | 5f 74 79 70 65 28 24 76 61 6c 75 65 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c | _type($value));.............}.el |
25320 | 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 72 65 73 75 6c 74 5b 24 6b 65 | se.{.................$result[$ke |
25340 | 79 5d 20 3d 20 61 72 72 61 79 28 27 73 74 72 69 6e 67 27 2c 20 28 73 74 72 69 6e 67 29 20 24 76 | y].=.array('string',.(string).$v |
25360 | 61 6c 75 65 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a | alue);.............}.........}.. |
25380 | 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 72 65 73 75 6c 74 3b 0a 20 20 20 20 7d 0a 0a 20 | ........return.$result;.....}... |
253a0 | 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 43 6c 61 73 73 4e 61 6d 65 | ...private.function.getClassName |
253c0 | 46 72 6f 6d 49 6e 63 6f 6d 70 6c 65 74 65 28 5c 5f 5f 50 48 50 5f 49 6e 63 6f 6d 70 6c 65 74 65 | FromIncomplete(\__PHP_Incomplete |
253e0 | 5f 43 6c 61 73 73 20 24 76 61 6c 75 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 61 72 | _Class.$value).....{.........$ar |
25400 | 72 61 79 20 3d 20 6e 65 77 20 5c 41 72 72 61 79 4f 62 6a 65 63 74 28 24 76 61 6c 75 65 29 3b 0a | ray.=.new.\ArrayObject($value);. |
25420 | 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 61 72 72 61 79 5b 27 5f 5f 50 48 50 5f 49 6e | .........return.$array['__PHP_In |
25440 | 63 6f 6d 70 6c 65 74 65 5f 43 6c 61 73 73 5f 4e 61 6d 65 27 5d 3b 0a 20 20 20 20 7d 0a 7d 0a 3c | complete_Class_Name'];.....}.}.< |
25460 | 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 | ?php../*..*.This.file.is.part.of |
25480 | 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 | .the.Symfony.package...*..*.(c). |
254a0 | 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 | Fabien.Potencier.<fabien@symfony |
254c0 | 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 | .com>..*..*.For.the.full.copyrig |
254e0 | 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 | ht.and.license.information,.plea |
25500 | 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 | se.view.the.LICENSE..*.file.that |
25520 | 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 | .was.distributed.with.this.sourc |
25540 | 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 | e.code...*/..namespace.Symfony\C |
25560 | 6f 6d 70 6f 6e 65 6e 74 5c 44 65 62 75 67 5c 45 78 63 65 70 74 69 6f 6e 3b 0a 0a 2f 2a 2a 0a 20 | omponent\Debug\Exception;../**.. |
25580 | 2a 20 55 6e 64 65 66 69 6e 65 64 20 46 75 6e 63 74 69 6f 6e 20 45 78 63 65 70 74 69 6f 6e 2e 0a | *.Undefined.Function.Exception.. |
255a0 | 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 4b 6f 6e 73 74 61 6e 74 6f 6e 20 4d 79 61 6b 73 68 69 | .*..*.@author.Konstanton.Myakshi |
255c0 | 6e 20 3c 6b 6f 63 2d 64 70 40 79 61 6e 64 65 78 2e 72 75 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 55 | n.<koc-dp@yandex.ru>..*/.class.U |
255e0 | 6e 64 65 66 69 6e 65 64 46 75 6e 63 74 69 6f 6e 45 78 63 65 70 74 69 6f 6e 20 65 78 74 65 6e 64 | ndefinedFunctionException.extend |
25600 | 73 20 46 61 74 61 6c 45 72 72 6f 72 45 78 63 65 70 74 69 6f 6e 0a 7b 0a 20 20 20 20 70 75 62 6c | s.FatalErrorException.{.....publ |
25620 | 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 74 28 24 6d 65 73 73 61 67 65 | ic.function.__construct($message |
25640 | 2c 20 5c 45 72 72 6f 72 45 78 63 65 70 74 69 6f 6e 20 24 70 72 65 76 69 6f 75 73 29 0a 20 20 20 | ,.\ErrorException.$previous).... |
25660 | 20 7b 0a 20 20 20 20 20 20 20 20 70 61 72 65 6e 74 3a 3a 5f 5f 63 6f 6e 73 74 72 75 63 74 28 0a | .{.........parent::__construct(. |
25680 | 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 2c 0a 20 20 20 20 20 20 20 20 20 20 | ............$message,........... |
256a0 | 20 20 24 70 72 65 76 69 6f 75 73 2d 3e 67 65 74 43 6f 64 65 28 29 2c 0a 20 20 20 20 20 20 20 20 | ..$previous->getCode(),......... |
256c0 | 20 20 20 20 24 70 72 65 76 69 6f 75 73 2d 3e 67 65 74 53 65 76 65 72 69 74 79 28 29 2c 0a 20 20 | ....$previous->getSeverity(),... |
256e0 | 20 20 20 20 20 20 20 20 20 20 24 70 72 65 76 69 6f 75 73 2d 3e 67 65 74 46 69 6c 65 28 29 2c 0a | ..........$previous->getFile(),. |
25700 | 20 20 20 20 20 20 20 20 20 20 20 20 24 70 72 65 76 69 6f 75 73 2d 3e 67 65 74 4c 69 6e 65 28 29 | ............$previous->getLine() |
25720 | 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 70 72 65 76 69 6f 75 73 2d 3e 67 65 74 50 72 65 76 | ,.............$previous->getPrev |
25740 | 69 6f 75 73 28 29 0a 20 20 20 20 20 20 20 20 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d | ious().........);.........$this- |
25760 | 3e 73 65 74 54 72 61 63 65 28 24 70 72 65 76 69 6f 75 73 2d 3e 67 65 74 54 72 61 63 65 28 29 29 | >setTrace($previous->getTrace()) |
25780 | 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 | ;.....}.}.<?php../*..*.This.file |
257a0 | 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e | .is.part.of.the.Symfony.package. |
257c0 | 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 | ..*..*.(c).Fabien.Potencier.<fab |
257e0 | 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 | ien@symfony.com>..*..*.For.the.f |
25800 | 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d | ull.copyright.and.license.inform |
25820 | 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 | ation,.please.view.the.LICENSE.. |
25840 | 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 | *.file.that.was.distributed.with |
25860 | 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 | .this.source.code...*/..namespac |
25880 | 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 44 65 62 75 67 5c 45 78 63 65 70 74 | e.Symfony\Component\Debug\Except |
258a0 | 69 6f 6e 3b 0a 0a 2f 2a 2a 0a 20 2a 20 43 6c 61 73 73 20 28 6f 72 20 54 72 61 69 74 20 6f 72 20 | ion;../**..*.Class.(or.Trait.or. |
258c0 | 49 6e 74 65 72 66 61 63 65 29 20 4e 6f 74 20 46 6f 75 6e 64 20 45 78 63 65 70 74 69 6f 6e 2e 0a | Interface).Not.Found.Exception.. |
258e0 | 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 4b 6f 6e 73 74 61 6e 74 6f 6e 20 4d 79 61 6b 73 68 69 | .*..*.@author.Konstanton.Myakshi |
25900 | 6e 20 3c 6b 6f 63 2d 64 70 40 79 61 6e 64 65 78 2e 72 75 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 43 | n.<koc-dp@yandex.ru>..*/.class.C |
25920 | 6c 61 73 73 4e 6f 74 46 6f 75 6e 64 45 78 63 65 70 74 69 6f 6e 20 65 78 74 65 6e 64 73 20 46 61 | lassNotFoundException.extends.Fa |
25940 | 74 61 6c 45 72 72 6f 72 45 78 63 65 70 74 69 6f 6e 0a 7b 0a 20 20 20 20 70 75 62 6c 69 63 20 66 | talErrorException.{.....public.f |
25960 | 75 6e 63 74 69 6f 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 74 28 24 6d 65 73 73 61 67 65 2c 20 5c 45 | unction.__construct($message,.\E |
25980 | 72 72 6f 72 45 78 63 65 70 74 69 6f 6e 20 24 70 72 65 76 69 6f 75 73 29 0a 20 20 20 20 7b 0a 20 | rrorException.$previous).....{.. |
259a0 | 20 20 20 20 20 20 20 70 61 72 65 6e 74 3a 3a 5f 5f 63 6f 6e 73 74 72 75 63 74 28 0a 20 20 20 20 | .......parent::__construct(..... |
259c0 | 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 70 | ........$message,.............$p |
259e0 | 72 65 76 69 6f 75 73 2d 3e 67 65 74 43 6f 64 65 28 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 | revious->getCode(),............. |
25a00 | 24 70 72 65 76 69 6f 75 73 2d 3e 67 65 74 53 65 76 65 72 69 74 79 28 29 2c 0a 20 20 20 20 20 20 | $previous->getSeverity(),....... |
25a20 | 20 20 20 20 20 20 24 70 72 65 76 69 6f 75 73 2d 3e 67 65 74 46 69 6c 65 28 29 2c 0a 20 20 20 20 | ......$previous->getFile(),..... |
25a40 | 20 20 20 20 20 20 20 20 24 70 72 65 76 69 6f 75 73 2d 3e 67 65 74 4c 69 6e 65 28 29 2c 0a 20 20 | ........$previous->getLine(),... |
25a60 | 20 20 20 20 20 20 20 20 20 20 24 70 72 65 76 69 6f 75 73 2d 3e 67 65 74 50 72 65 76 69 6f 75 73 | ..........$previous->getPrevious |
25a80 | 28 29 0a 20 20 20 20 20 20 20 20 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 65 74 | ().........);.........$this->set |
25aa0 | 54 72 61 63 65 28 24 70 72 65 76 69 6f 75 73 2d 3e 67 65 74 54 72 61 63 65 28 29 29 3b 0a 20 20 | Trace($previous->getTrace());... |
25ac0 | 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 | ..}.}.<?php../*..*.This.file.is. |
25ae0 | 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a | part.of.the.Symfony.package...*. |
25b00 | 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 | .*.(c).Fabien.Potencier.<fabien@ |
25b20 | 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 | symfony.com>..*..*.For.the.full. |
25b40 | 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f | copyright.and.license.informatio |
25b60 | 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 | n,.please.view.the.LICENSE..*.fi |
25b80 | 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 | le.that.was.distributed.with.thi |
25ba0 | 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 | s.source.code...*/..namespace.Sy |
25bc0 | 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 44 65 62 75 67 5c 45 78 63 65 70 74 69 6f 6e 3b | mfony\Component\Debug\Exception; |
25be0 | 0a 0a 2f 2a 2a 0a 20 2a 20 55 6e 64 65 66 69 6e 65 64 20 4d 65 74 68 6f 64 20 45 78 63 65 70 74 | ../**..*.Undefined.Method.Except |
25c00 | 69 6f 6e 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 47 72 c3 a9 67 6f 69 72 65 20 50 69 6e | ion...*..*.@author.Gr..goire.Pin |
25c20 | 65 61 75 20 3c 6c 79 72 69 78 78 40 6c 79 72 69 78 78 2e 69 6e 66 6f 3e 0a 20 2a 2f 0a 63 6c 61 | eau.<lyrixx@lyrixx.info>..*/.cla |
25c40 | 73 73 20 55 6e 64 65 66 69 6e 65 64 4d 65 74 68 6f 64 45 78 63 65 70 74 69 6f 6e 20 65 78 74 65 | ss.UndefinedMethodException.exte |
25c60 | 6e 64 73 20 46 61 74 61 6c 45 72 72 6f 72 45 78 63 65 70 74 69 6f 6e 0a 7b 0a 20 20 20 20 70 75 | nds.FatalErrorException.{.....pu |
25c80 | 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 74 28 24 6d 65 73 73 61 | blic.function.__construct($messa |
25ca0 | 67 65 2c 20 5c 45 72 72 6f 72 45 78 63 65 70 74 69 6f 6e 20 24 70 72 65 76 69 6f 75 73 29 0a 20 | ge,.\ErrorException.$previous).. |
25cc0 | 20 20 20 7b 0a 20 20 20 20 20 20 20 20 70 61 72 65 6e 74 3a 3a 5f 5f 63 6f 6e 73 74 72 75 63 74 | ...{.........parent::__construct |
25ce0 | 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 2c 0a 20 20 20 20 20 20 20 20 | (.............$message,......... |
25d00 | 20 20 20 20 24 70 72 65 76 69 6f 75 73 2d 3e 67 65 74 43 6f 64 65 28 29 2c 0a 20 20 20 20 20 20 | ....$previous->getCode(),....... |
25d20 | 20 20 20 20 20 20 24 70 72 65 76 69 6f 75 73 2d 3e 67 65 74 53 65 76 65 72 69 74 79 28 29 2c 0a | ......$previous->getSeverity(),. |
25d40 | 20 20 20 20 20 20 20 20 20 20 20 20 24 70 72 65 76 69 6f 75 73 2d 3e 67 65 74 46 69 6c 65 28 29 | ............$previous->getFile() |
25d60 | 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 70 72 65 76 69 6f 75 73 2d 3e 67 65 74 4c 69 6e 65 | ,.............$previous->getLine |
25d80 | 28 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 70 72 65 76 69 6f 75 73 2d 3e 67 65 74 50 72 | (),.............$previous->getPr |
25da0 | 65 76 69 6f 75 73 28 29 0a 20 20 20 20 20 20 20 20 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 | evious().........);.........$thi |
25dc0 | 73 2d 3e 73 65 74 54 72 61 63 65 28 24 70 72 65 76 69 6f 75 73 2d 3e 67 65 74 54 72 61 63 65 28 | s->setTrace($previous->getTrace( |
25de0 | 29 29 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 | ));.....}.}.<?php../*..*.This.fi |
25e00 | 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 | le.is.part.of.the.Symfony.packag |
25e20 | 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 | e...*..*.(c).Fabien.Potencier.<f |
25e40 | 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 | abien@symfony.com>..*..*.For.the |
25e60 | 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f | .full.copyright.and.license.info |
25e80 | 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 | rmation,.please.view.the.LICENSE |
25ea0 | 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 | ..*.file.that.was.distributed.wi |
25ec0 | 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 | th.this.source.code...*/..namesp |
25ee0 | 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 44 65 62 75 67 5c 45 78 63 65 | ace.Symfony\Component\Debug\Exce |
25f00 | 70 74 69 6f 6e 3b 0a 0a 2f 2a 2a 0a 20 2a 20 46 61 74 61 6c 20 45 72 72 6f 72 20 45 78 63 65 70 | ption;../**..*.Fatal.Error.Excep |
25f20 | 74 69 6f 6e 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 4b 6f 6e 73 74 61 6e 74 6f 6e 20 4d | tion...*..*.@author.Konstanton.M |
25f40 | 79 61 6b 73 68 69 6e 20 3c 6b 6f 63 2d 64 70 40 79 61 6e 64 65 78 2e 72 75 3e 0a 20 2a 2f 0a 63 | yakshin.<koc-dp@yandex.ru>..*/.c |
25f60 | 6c 61 73 73 20 46 61 74 61 6c 45 72 72 6f 72 45 78 63 65 70 74 69 6f 6e 20 65 78 74 65 6e 64 73 | lass.FatalErrorException.extends |
25f80 | 20 5c 45 72 72 6f 72 45 78 63 65 70 74 69 6f 6e 0a 7b 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 | .\ErrorException.{.....public.fu |
25fa0 | 6e 63 74 69 6f 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 74 28 24 6d 65 73 73 61 67 65 2c 20 24 63 6f | nction.__construct($message,.$co |
25fc0 | 64 65 2c 20 24 73 65 76 65 72 69 74 79 2c 20 24 66 69 6c 65 6e 61 6d 65 2c 20 24 6c 69 6e 65 6e | de,.$severity,.$filename,.$linen |
25fe0 | 6f 2c 20 24 74 72 61 63 65 4f 66 66 73 65 74 20 3d 20 6e 75 6c 6c 2c 20 24 74 72 61 63 65 41 72 | o,.$traceOffset.=.null,.$traceAr |
26000 | 67 73 20 3d 20 74 72 75 65 2c 20 61 72 72 61 79 20 24 74 72 61 63 65 20 3d 20 6e 75 6c 6c 29 0a | gs.=.true,.array.$trace.=.null). |
26020 | 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 70 61 72 65 6e 74 3a 3a 5f 5f 63 6f 6e 73 74 72 75 63 | ....{.........parent::__construc |
26040 | 74 28 24 6d 65 73 73 61 67 65 2c 20 24 63 6f 64 65 2c 20 24 73 65 76 65 72 69 74 79 2c 20 24 66 | t($message,.$code,.$severity,.$f |
26060 | 69 6c 65 6e 61 6d 65 2c 20 24 6c 69 6e 65 6e 6f 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 | ilename,.$lineno);..........if.( |
26080 | 6e 75 6c 6c 20 21 3d 3d 20 24 74 72 61 63 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 | null.!==.$trace).{.............i |
260a0 | 66 20 28 21 24 74 72 61 63 65 41 72 67 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | f.(!$traceArgs).{............... |
260c0 | 20 20 66 6f 72 65 61 63 68 20 28 24 74 72 61 63 65 20 61 73 20 26 24 66 72 61 6d 65 29 20 7b 0a | ..foreach.($trace.as.&$frame).{. |
260e0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 75 6e 73 65 74 28 24 66 72 61 6d 65 | ....................unset($frame |
26100 | 5b 27 61 72 67 73 27 5d 2c 20 24 66 72 61 6d 65 5b 27 74 68 69 73 27 5d 2c 20 24 66 72 61 6d 65 | ['args'],.$frame['this'],.$frame |
26120 | 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 | );.................}............ |
26140 | 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 65 74 54 72 61 63 65 28 | .}..............$this->setTrace( |
26160 | 24 74 72 61 63 65 29 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 6e 75 6c 6c 20 | $trace);.........}.elseif.(null. |
26180 | 21 3d 3d 20 24 74 72 61 63 65 4f 66 66 73 65 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | !==.$traceOffset).{............. |
261a0 | 69 66 20 28 66 75 6e 63 74 69 6f 6e 5f 65 78 69 73 74 73 28 27 78 64 65 62 75 67 5f 67 65 74 5f | if.(function_exists('xdebug_get_ |
261c0 | 66 75 6e 63 74 69 6f 6e 5f 73 74 61 63 6b 27 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | function_stack')).{............. |
261e0 | 20 20 20 20 24 74 72 61 63 65 20 3d 20 78 64 65 62 75 67 5f 67 65 74 5f 66 75 6e 63 74 69 6f 6e | ....$trace.=.xdebug_get_function |
26200 | 5f 73 74 61 63 6b 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 30 20 | _stack();.................if.(0. |
26220 | 3c 20 24 74 72 61 63 65 4f 66 66 73 65 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | <.$traceOffset).{............... |
26240 | 20 20 20 20 20 20 61 72 72 61 79 5f 73 70 6c 69 63 65 28 24 74 72 61 63 65 2c 20 2d 24 74 72 61 | ......array_splice($trace,.-$tra |
26260 | 63 65 4f 66 66 73 65 74 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 | ceOffset);.................}.... |
26280 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 74 72 61 63 65 20 61 73 | ..............foreach.($trace.as |
262a0 | 20 26 24 66 72 61 6d 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | .&$frame).{..................... |
262c0 | 69 66 20 28 21 69 73 73 65 74 28 24 66 72 61 6d 65 5b 27 74 79 70 65 27 5d 29 29 20 7b 0a 20 20 | if.(!isset($frame['type'])).{... |
262e0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 58 44 65 62 75 67 20 | ......................//.XDebug. |
26300 | 70 72 65 20 32 2e 31 2e 31 20 64 6f 65 73 6e 27 74 20 63 75 72 72 65 6e 74 6c 79 20 73 65 74 20 | pre.2.1.1.doesn't.currently.set. |
26320 | 74 68 65 20 63 61 6c 6c 20 74 79 70 65 20 6b 65 79 20 68 74 74 70 3a 2f 2f 62 75 67 73 2e 78 64 | the.call.type.key.http://bugs.xd |
26340 | 65 62 75 67 2e 6f 72 67 2f 76 69 65 77 2e 70 68 70 3f 69 64 3d 36 39 35 0a 20 20 20 20 20 20 20 | ebug.org/view.php?id=695........ |
26360 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 69 73 73 65 74 28 24 66 72 61 6d | .................if.(isset($fram |
26380 | 65 5b 27 63 6c 61 73 73 27 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | e['class'])).{.................. |
263a0 | 20 20 20 20 20 20 20 20 20 20 20 24 66 72 61 6d 65 5b 27 74 79 70 65 27 5d 20 3d 20 27 3a 3a 27 | ...........$frame['type'].=.'::' |
263c0 | 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 | ;.........................}..... |
263e0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 27 64 79 6e 61 6d | ................}.elseif.('dynam |
26400 | 69 63 27 20 3d 3d 3d 20 24 66 72 61 6d 65 5b 27 74 79 70 65 27 5d 29 20 7b 0a 20 20 20 20 20 20 | ic'.===.$frame['type']).{....... |
26420 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 66 72 61 6d 65 5b 27 74 79 70 65 27 5d | ..................$frame['type'] |
26440 | 20 3d 20 27 2d 3e 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 | .=.'->';.....................}.e |
26460 | 6c 73 65 69 66 20 28 27 73 74 61 74 69 63 27 20 3d 3d 3d 20 24 66 72 61 6d 65 5b 27 74 79 70 65 | lseif.('static'.===.$frame['type |
26480 | 27 5d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 66 | ']).{.........................$f |
264a0 | 72 61 6d 65 5b 27 74 79 70 65 27 5d 20 3d 20 27 3a 3a 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 | rame['type'].=.'::';............ |
264c0 | 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | .........}...................... |
264e0 | 2f 2f 20 58 44 65 62 75 67 20 61 6c 73 6f 20 68 61 73 20 61 20 64 69 66 66 65 72 65 6e 74 20 6e | //.XDebug.also.has.a.different.n |
26500 | 61 6d 65 20 66 6f 72 20 74 68 65 20 70 61 72 61 6d 65 74 65 72 73 20 61 72 72 61 79 0a 20 20 20 | ame.for.the.parameters.array.... |
26520 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 21 24 74 72 61 63 65 41 72 67 73 | .................if.(!$traceArgs |
26540 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 75 6e 73 65 | ).{.........................unse |
26560 | 74 28 24 66 72 61 6d 65 5b 27 70 61 72 61 6d 73 27 5d 2c 20 24 66 72 61 6d 65 5b 27 61 72 67 73 | t($frame['params'],.$frame['args |
26580 | 27 5d 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 | ']);.....................}.elsei |
265a0 | 66 20 28 69 73 73 65 74 28 24 66 72 61 6d 65 5b 27 70 61 72 61 6d 73 27 5d 29 20 26 26 20 21 69 | f.(isset($frame['params']).&&.!i |
265c0 | 73 73 65 74 28 24 66 72 61 6d 65 5b 27 61 72 67 73 27 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 | sset($frame['args'])).{......... |
265e0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 66 72 61 6d 65 5b 27 61 72 67 73 27 5d 20 3d | ................$frame['args'].= |
26600 | 20 24 66 72 61 6d 65 5b 27 70 61 72 61 6d 73 27 5d 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | .$frame['params'];.............. |
26620 | 20 20 20 20 20 20 20 20 20 20 20 75 6e 73 65 74 28 24 66 72 61 6d 65 5b 27 70 61 72 61 6d 73 27 | ...........unset($frame['params' |
26640 | 5d 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 | ]);.....................}....... |
26660 | 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 75 6e 73 | ..........}..................uns |
26680 | 65 74 28 24 66 72 61 6d 65 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 72 61 | et($frame);.................$tra |
266a0 | 63 65 20 3d 20 61 72 72 61 79 5f 72 65 76 65 72 73 65 28 24 74 72 61 63 65 29 3b 0a 20 20 20 20 | ce.=.array_reverse($trace);..... |
266c0 | 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 66 75 6e 63 74 69 6f 6e 5f 65 78 69 73 74 | ........}.elseif.(function_exist |
266e0 | 73 28 27 73 79 6d 66 6f 6e 79 5f 64 65 62 75 67 5f 62 61 63 6b 74 72 61 63 65 27 29 29 20 7b 0a | s('symfony_debug_backtrace')).{. |
26700 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 72 61 63 65 20 3d 20 73 79 6d 66 6f 6e 79 | ................$trace.=.symfony |
26720 | 5f 64 65 62 75 67 5f 62 61 63 6b 74 72 61 63 65 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | _debug_backtrace();............. |
26740 | 20 20 20 20 69 66 20 28 30 20 3c 20 24 74 72 61 63 65 4f 66 66 73 65 74 29 20 7b 0a 20 20 20 20 | ....if.(0.<.$traceOffset).{..... |
26760 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 61 72 72 61 79 5f 73 70 6c 69 63 65 28 24 74 72 | ................array_splice($tr |
26780 | 61 63 65 2c 20 30 2c 20 24 74 72 61 63 65 4f 66 66 73 65 74 29 3b 0a 20 20 20 20 20 20 20 20 20 | ace,.0,.$traceOffset);.......... |
267a0 | 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 | .......}.............}.else.{... |
267c0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 72 61 63 65 20 3d 20 61 72 72 61 79 28 29 3b 0a | ..............$trace.=.array();. |
267e0 | 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 | ............}..............$this |
26800 | 2d 3e 73 65 74 54 72 61 63 65 28 24 74 72 61 63 65 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 | ->setTrace($trace);.........}... |
26820 | 20 20 7d 0a 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 54 | ..}......protected.function.setT |
26840 | 72 61 63 65 28 24 74 72 61 63 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 72 61 63 | race($trace).....{.........$trac |
26860 | 65 52 65 66 6c 65 63 74 6f 72 20 3d 20 6e 65 77 20 5c 52 65 66 6c 65 63 74 69 6f 6e 50 72 6f 70 | eReflector.=.new.\ReflectionProp |
26880 | 65 72 74 79 28 27 45 78 63 65 70 74 69 6f 6e 27 2c 20 27 74 72 61 63 65 27 29 3b 0a 20 20 20 20 | erty('Exception',.'trace');..... |
268a0 | 20 20 20 20 24 74 72 61 63 65 52 65 66 6c 65 63 74 6f 72 2d 3e 73 65 74 41 63 63 65 73 73 69 62 | ....$traceReflector->setAccessib |
268c0 | 6c 65 28 74 72 75 65 29 3b 0a 20 20 20 20 20 20 20 20 24 74 72 61 63 65 52 65 66 6c 65 63 74 6f | le(true);.........$traceReflecto |
268e0 | 72 2d 3e 73 65 74 56 61 6c 75 65 28 24 74 68 69 73 2c 20 24 74 72 61 63 65 29 3b 0a 20 20 20 20 | r->setValue($this,.$trace);..... |
26900 | 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 | }.}.<?php../*..*.This.file.is.pa |
26920 | 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a | rt.of.the.Symfony.package...*..* |
26940 | 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 | .(c).Fabien.Potencier.<fabien@sy |
26960 | 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f | mfony.com>..*..*.For.the.full.co |
26980 | 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c | pyright.and.license.information, |
269a0 | 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 | .please.view.the.LICENSE..*.file |
269c0 | 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 | .that.was.distributed.with.this. |
269e0 | 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 | source.code...*/..namespace.Symf |
26a00 | 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 44 65 62 75 67 5c 45 78 63 65 70 74 69 6f 6e 3b 0a 0a | ony\Component\Debug\Exception;.. |
26a20 | 2f 2a 2a 0a 20 2a 20 45 72 72 6f 72 20 45 78 63 65 70 74 69 6f 6e 20 77 69 74 68 20 56 61 72 69 | /**..*.Error.Exception.with.Vari |
26a40 | 61 62 6c 65 20 43 6f 6e 74 65 78 74 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 43 68 72 69 | able.Context...*..*.@author.Chri |
26a60 | 73 74 69 61 6e 20 53 63 69 62 65 72 72 61 73 20 3c 75 75 66 36 34 32 39 40 67 6d 61 69 6c 2e 63 | stian.Sciberras.<uuf6429@gmail.c |
26a80 | 6f 6d 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 43 6f 6e 74 65 78 74 45 72 72 6f 72 45 78 63 65 70 74 | om>..*/.class.ContextErrorExcept |
26aa0 | 69 6f 6e 20 65 78 74 65 6e 64 73 20 5c 45 72 72 6f 72 45 78 63 65 70 74 69 6f 6e 0a 7b 0a 20 20 | ion.extends.\ErrorException.{... |
26ac0 | 20 20 70 72 69 76 61 74 65 20 24 63 6f 6e 74 65 78 74 20 3d 20 61 72 72 61 79 28 29 3b 0a 0a 20 | ..private.$context.=.array();... |
26ae0 | 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 74 28 24 | ...public.function.__construct($ |
26b00 | 6d 65 73 73 61 67 65 2c 20 24 63 6f 64 65 2c 20 24 73 65 76 65 72 69 74 79 2c 20 24 66 69 6c 65 | message,.$code,.$severity,.$file |
26b20 | 6e 61 6d 65 2c 20 24 6c 69 6e 65 6e 6f 2c 20 24 63 6f 6e 74 65 78 74 20 3d 20 61 72 72 61 79 28 | name,.$lineno,.$context.=.array( |
26b40 | 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 70 61 72 65 6e 74 3a 3a 5f 5f 63 6f 6e 73 74 | )).....{.........parent::__const |
26b60 | 72 75 63 74 28 24 6d 65 73 73 61 67 65 2c 20 24 63 6f 64 65 2c 20 24 73 65 76 65 72 69 74 79 2c | ruct($message,.$code,.$severity, |
26b80 | 20 24 66 69 6c 65 6e 61 6d 65 2c 20 24 6c 69 6e 65 6e 6f 29 3b 0a 20 20 20 20 20 20 20 20 24 74 | .$filename,.$lineno);.........$t |
26ba0 | 68 69 73 2d 3e 63 6f 6e 74 65 78 74 20 3d 20 24 63 6f 6e 74 65 78 74 3b 0a 20 20 20 20 7d 0a 0a | his->context.=.$context;.....}.. |
26bc0 | 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 61 72 72 61 79 20 41 72 72 | ..../**......*.@return.array.Arr |
26be0 | 61 79 20 6f 66 20 76 61 72 69 61 62 6c 65 73 20 74 68 61 74 20 65 78 69 73 74 65 64 20 77 68 65 | ay.of.variables.that.existed.whe |
26c00 | 6e 20 74 68 65 20 65 78 63 65 70 74 69 6f 6e 20 6f 63 63 75 72 72 65 64 0a 20 20 20 20 20 2a 2f | n.the.exception.occurred......*/ |
26c20 | 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 43 6f 6e 74 65 78 74 28 | .....public.function.getContext( |
26c40 | 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 63 6f | ).....{.........return.$this->co |
26c60 | 6e 74 65 78 74 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 73 74 61 74 69 63 20 24 64 61 | ntext;.....}.}.<?php..static.$da |
26c80 | 74 61 20 3d 20 61 72 72 61 79 20 28 0a 20 20 27 41 27 20 3d 3e 20 27 61 27 2c 0a 20 20 27 42 27 | ta.=.array.(...'A'.=>.'a',...'B' |
26ca0 | 20 3d 3e 20 27 62 27 2c 0a 20 20 27 43 27 20 3d 3e 20 27 63 27 2c 0a 20 20 27 44 27 20 3d 3e 20 | .=>.'b',...'C'.=>.'c',...'D'.=>. |
26cc0 | 27 64 27 2c 0a 20 20 27 45 27 20 3d 3e 20 27 65 27 2c 0a 20 20 27 46 27 20 3d 3e 20 27 66 27 2c | 'd',...'E'.=>.'e',...'F'.=>.'f', |
26ce0 | 0a 20 20 27 47 27 20 3d 3e 20 27 67 27 2c 0a 20 20 27 48 27 20 3d 3e 20 27 68 27 2c 0a 20 20 27 | ...'G'.=>.'g',...'H'.=>.'h',...' |
26d00 | 49 27 20 3d 3e 20 27 69 27 2c 0a 20 20 27 4a 27 20 3d 3e 20 27 6a 27 2c 0a 20 20 27 4b 27 20 3d | I'.=>.'i',...'J'.=>.'j',...'K'.= |
26d20 | 3e 20 27 6b 27 2c 0a 20 20 27 4c 27 20 3d 3e 20 27 6c 27 2c 0a 20 20 27 4d 27 20 3d 3e 20 27 6d | >.'k',...'L'.=>.'l',...'M'.=>.'m |
26d40 | 27 2c 0a 20 20 27 4e 27 20 3d 3e 20 27 6e 27 2c 0a 20 20 27 4f 27 20 3d 3e 20 27 6f 27 2c 0a 20 | ',...'N'.=>.'n',...'O'.=>.'o',.. |
26d60 | 20 27 50 27 20 3d 3e 20 27 70 27 2c 0a 20 20 27 51 27 20 3d 3e 20 27 71 27 2c 0a 20 20 27 52 27 | .'P'.=>.'p',...'Q'.=>.'q',...'R' |
26d80 | 20 3d 3e 20 27 72 27 2c 0a 20 20 27 53 27 20 3d 3e 20 27 73 27 2c 0a 20 20 27 54 27 20 3d 3e 20 | .=>.'r',...'S'.=>.'s',...'T'.=>. |
26da0 | 27 74 27 2c 0a 20 20 27 55 27 20 3d 3e 20 27 75 27 2c 0a 20 20 27 56 27 20 3d 3e 20 27 76 27 2c | 't',...'U'.=>.'u',...'V'.=>.'v', |
26dc0 | 0a 20 20 27 57 27 20 3d 3e 20 27 77 27 2c 0a 20 20 27 58 27 20 3d 3e 20 27 78 27 2c 0a 20 20 27 | ...'W'.=>.'w',...'X'.=>.'x',...' |
26de0 | 59 27 20 3d 3e 20 27 79 27 2c 0a 20 20 27 5a 27 20 3d 3e 20 27 7a 27 2c 0a 20 20 27 c3 80 27 20 | Y'.=>.'y',...'Z'.=>.'z',...'..'. |
26e00 | 3d 3e 20 27 c3 a0 27 2c 0a 20 20 27 c3 81 27 20 3d 3e 20 27 c3 a1 27 2c 0a 20 20 27 c3 82 27 20 | =>.'..',...'..'.=>.'..',...'..'. |
26e20 | 3d 3e 20 27 c3 a2 27 2c 0a 20 20 27 c3 83 27 20 3d 3e 20 27 c3 a3 27 2c 0a 20 20 27 c3 84 27 20 | =>.'..',...'..'.=>.'..',...'..'. |
26e40 | 3d 3e 20 27 c3 a4 27 2c 0a 20 20 27 c3 85 27 20 3d 3e 20 27 c3 a5 27 2c 0a 20 20 27 c3 86 27 20 | =>.'..',...'..'.=>.'..',...'..'. |
26e60 | 3d 3e 20 27 c3 a6 27 2c 0a 20 20 27 c3 87 27 20 3d 3e 20 27 c3 a7 27 2c 0a 20 20 27 c3 88 27 20 | =>.'..',...'..'.=>.'..',...'..'. |
26e80 | 3d 3e 20 27 c3 a8 27 2c 0a 20 20 27 c3 89 27 20 3d 3e 20 27 c3 a9 27 2c 0a 20 20 27 c3 8a 27 20 | =>.'..',...'..'.=>.'..',...'..'. |
26ea0 | 3d 3e 20 27 c3 aa 27 2c 0a 20 20 27 c3 8b 27 20 3d 3e 20 27 c3 ab 27 2c 0a 20 20 27 c3 8c 27 20 | =>.'..',...'..'.=>.'..',...'..'. |
26ec0 | 3d 3e 20 27 c3 ac 27 2c 0a 20 20 27 c3 8d 27 20 3d 3e 20 27 c3 ad 27 2c 0a 20 20 27 c3 8e 27 20 | =>.'..',...'..'.=>.'..',...'..'. |
26ee0 | 3d 3e 20 27 c3 ae 27 2c 0a 20 20 27 c3 8f 27 20 3d 3e 20 27 c3 af 27 2c 0a 20 20 27 c3 90 27 20 | =>.'..',...'..'.=>.'..',...'..'. |
26f00 | 3d 3e 20 27 c3 b0 27 2c 0a 20 20 27 c3 91 27 20 3d 3e 20 27 c3 b1 27 2c 0a 20 20 27 c3 92 27 20 | =>.'..',...'..'.=>.'..',...'..'. |
26f20 | 3d 3e 20 27 c3 b2 27 2c 0a 20 20 27 c3 93 27 20 3d 3e 20 27 c3 b3 27 2c 0a 20 20 27 c3 94 27 20 | =>.'..',...'..'.=>.'..',...'..'. |
26f40 | 3d 3e 20 27 c3 b4 27 2c 0a 20 20 27 c3 95 27 20 3d 3e 20 27 c3 b5 27 2c 0a 20 20 27 c3 96 27 20 | =>.'..',...'..'.=>.'..',...'..'. |
26f60 | 3d 3e 20 27 c3 b6 27 2c 0a 20 20 27 c3 98 27 20 3d 3e 20 27 c3 b8 27 2c 0a 20 20 27 c3 99 27 20 | =>.'..',...'..'.=>.'..',...'..'. |
26f80 | 3d 3e 20 27 c3 b9 27 2c 0a 20 20 27 c3 9a 27 20 3d 3e 20 27 c3 ba 27 2c 0a 20 20 27 c3 9b 27 20 | =>.'..',...'..'.=>.'..',...'..'. |
26fa0 | 3d 3e 20 27 c3 bb 27 2c 0a 20 20 27 c3 9c 27 20 3d 3e 20 27 c3 bc 27 2c 0a 20 20 27 c3 9d 27 20 | =>.'..',...'..'.=>.'..',...'..'. |
26fc0 | 3d 3e 20 27 c3 bd 27 2c 0a 20 20 27 c3 9e 27 20 3d 3e 20 27 c3 be 27 2c 0a 20 20 27 c4 80 27 20 | =>.'..',...'..'.=>.'..',...'..'. |
26fe0 | 3d 3e 20 27 c4 81 27 2c 0a 20 20 27 c4 82 27 20 3d 3e 20 27 c4 83 27 2c 0a 20 20 27 c4 84 27 20 | =>.'..',...'..'.=>.'..',...'..'. |
27000 | 3d 3e 20 27 c4 85 27 2c 0a 20 20 27 c4 86 27 20 3d 3e 20 27 c4 87 27 2c 0a 20 20 27 c4 88 27 20 | =>.'..',...'..'.=>.'..',...'..'. |
27020 | 3d 3e 20 27 c4 89 27 2c 0a 20 20 27 c4 8a 27 20 3d 3e 20 27 c4 8b 27 2c 0a 20 20 27 c4 8c 27 20 | =>.'..',...'..'.=>.'..',...'..'. |
27040 | 3d 3e 20 27 c4 8d 27 2c 0a 20 20 27 c4 8e 27 20 3d 3e 20 27 c4 8f 27 2c 0a 20 20 27 c4 90 27 20 | =>.'..',...'..'.=>.'..',...'..'. |
27060 | 3d 3e 20 27 c4 91 27 2c 0a 20 20 27 c4 92 27 20 3d 3e 20 27 c4 93 27 2c 0a 20 20 27 c4 94 27 20 | =>.'..',...'..'.=>.'..',...'..'. |
27080 | 3d 3e 20 27 c4 95 27 2c 0a 20 20 27 c4 96 27 20 3d 3e 20 27 c4 97 27 2c 0a 20 20 27 c4 98 27 20 | =>.'..',...'..'.=>.'..',...'..'. |
270a0 | 3d 3e 20 27 c4 99 27 2c 0a 20 20 27 c4 9a 27 20 3d 3e 20 27 c4 9b 27 2c 0a 20 20 27 c4 9c 27 20 | =>.'..',...'..'.=>.'..',...'..'. |
270c0 | 3d 3e 20 27 c4 9d 27 2c 0a 20 20 27 c4 9e 27 20 3d 3e 20 27 c4 9f 27 2c 0a 20 20 27 c4 a0 27 20 | =>.'..',...'..'.=>.'..',...'..'. |
270e0 | 3d 3e 20 27 c4 a1 27 2c 0a 20 20 27 c4 a2 27 20 3d 3e 20 27 c4 a3 27 2c 0a 20 20 27 c4 a4 27 20 | =>.'..',...'..'.=>.'..',...'..'. |
27100 | 3d 3e 20 27 c4 a5 27 2c 0a 20 20 27 c4 a6 27 20 3d 3e 20 27 c4 a7 27 2c 0a 20 20 27 c4 a8 27 20 | =>.'..',...'..'.=>.'..',...'..'. |
27120 | 3d 3e 20 27 c4 a9 27 2c 0a 20 20 27 c4 aa 27 20 3d 3e 20 27 c4 ab 27 2c 0a 20 20 27 c4 ac 27 20 | =>.'..',...'..'.=>.'..',...'..'. |
27140 | 3d 3e 20 27 c4 ad 27 2c 0a 20 20 27 c4 ae 27 20 3d 3e 20 27 c4 af 27 2c 0a 20 20 27 c4 b0 27 20 | =>.'..',...'..'.=>.'..',...'..'. |
27160 | 3d 3e 20 27 69 27 2c 0a 20 20 27 c4 b2 27 20 3d 3e 20 27 c4 b3 27 2c 0a 20 20 27 c4 b4 27 20 3d | =>.'i',...'..'.=>.'..',...'..'.= |
27180 | 3e 20 27 c4 b5 27 2c 0a 20 20 27 c4 b6 27 20 3d 3e 20 27 c4 b7 27 2c 0a 20 20 27 c4 b9 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
271a0 | 3e 20 27 c4 ba 27 2c 0a 20 20 27 c4 bb 27 20 3d 3e 20 27 c4 bc 27 2c 0a 20 20 27 c4 bd 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
271c0 | 3e 20 27 c4 be 27 2c 0a 20 20 27 c4 bf 27 20 3d 3e 20 27 c5 80 27 2c 0a 20 20 27 c5 81 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
271e0 | 3e 20 27 c5 82 27 2c 0a 20 20 27 c5 83 27 20 3d 3e 20 27 c5 84 27 2c 0a 20 20 27 c5 85 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27200 | 3e 20 27 c5 86 27 2c 0a 20 20 27 c5 87 27 20 3d 3e 20 27 c5 88 27 2c 0a 20 20 27 c5 8a 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27220 | 3e 20 27 c5 8b 27 2c 0a 20 20 27 c5 8c 27 20 3d 3e 20 27 c5 8d 27 2c 0a 20 20 27 c5 8e 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27240 | 3e 20 27 c5 8f 27 2c 0a 20 20 27 c5 90 27 20 3d 3e 20 27 c5 91 27 2c 0a 20 20 27 c5 92 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27260 | 3e 20 27 c5 93 27 2c 0a 20 20 27 c5 94 27 20 3d 3e 20 27 c5 95 27 2c 0a 20 20 27 c5 96 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27280 | 3e 20 27 c5 97 27 2c 0a 20 20 27 c5 98 27 20 3d 3e 20 27 c5 99 27 2c 0a 20 20 27 c5 9a 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
272a0 | 3e 20 27 c5 9b 27 2c 0a 20 20 27 c5 9c 27 20 3d 3e 20 27 c5 9d 27 2c 0a 20 20 27 c5 9e 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
272c0 | 3e 20 27 c5 9f 27 2c 0a 20 20 27 c5 a0 27 20 3d 3e 20 27 c5 a1 27 2c 0a 20 20 27 c5 a2 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
272e0 | 3e 20 27 c5 a3 27 2c 0a 20 20 27 c5 a4 27 20 3d 3e 20 27 c5 a5 27 2c 0a 20 20 27 c5 a6 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27300 | 3e 20 27 c5 a7 27 2c 0a 20 20 27 c5 a8 27 20 3d 3e 20 27 c5 a9 27 2c 0a 20 20 27 c5 aa 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27320 | 3e 20 27 c5 ab 27 2c 0a 20 20 27 c5 ac 27 20 3d 3e 20 27 c5 ad 27 2c 0a 20 20 27 c5 ae 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27340 | 3e 20 27 c5 af 27 2c 0a 20 20 27 c5 b0 27 20 3d 3e 20 27 c5 b1 27 2c 0a 20 20 27 c5 b2 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27360 | 3e 20 27 c5 b3 27 2c 0a 20 20 27 c5 b4 27 20 3d 3e 20 27 c5 b5 27 2c 0a 20 20 27 c5 b6 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27380 | 3e 20 27 c5 b7 27 2c 0a 20 20 27 c5 b8 27 20 3d 3e 20 27 c3 bf 27 2c 0a 20 20 27 c5 b9 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
273a0 | 3e 20 27 c5 ba 27 2c 0a 20 20 27 c5 bb 27 20 3d 3e 20 27 c5 bc 27 2c 0a 20 20 27 c5 bd 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
273c0 | 3e 20 27 c5 be 27 2c 0a 20 20 27 c6 81 27 20 3d 3e 20 27 c9 93 27 2c 0a 20 20 27 c6 82 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
273e0 | 3e 20 27 c6 83 27 2c 0a 20 20 27 c6 84 27 20 3d 3e 20 27 c6 85 27 2c 0a 20 20 27 c6 86 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27400 | 3e 20 27 c9 94 27 2c 0a 20 20 27 c6 87 27 20 3d 3e 20 27 c6 88 27 2c 0a 20 20 27 c6 89 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27420 | 3e 20 27 c9 96 27 2c 0a 20 20 27 c6 8a 27 20 3d 3e 20 27 c9 97 27 2c 0a 20 20 27 c6 8b 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27440 | 3e 20 27 c6 8c 27 2c 0a 20 20 27 c6 8e 27 20 3d 3e 20 27 c7 9d 27 2c 0a 20 20 27 c6 8f 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27460 | 3e 20 27 c9 99 27 2c 0a 20 20 27 c6 90 27 20 3d 3e 20 27 c9 9b 27 2c 0a 20 20 27 c6 91 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27480 | 3e 20 27 c6 92 27 2c 0a 20 20 27 c6 93 27 20 3d 3e 20 27 c9 a0 27 2c 0a 20 20 27 c6 94 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
274a0 | 3e 20 27 c9 a3 27 2c 0a 20 20 27 c6 96 27 20 3d 3e 20 27 c9 a9 27 2c 0a 20 20 27 c6 97 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
274c0 | 3e 20 27 c9 a8 27 2c 0a 20 20 27 c6 98 27 20 3d 3e 20 27 c6 99 27 2c 0a 20 20 27 c6 9c 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
274e0 | 3e 20 27 c9 af 27 2c 0a 20 20 27 c6 9d 27 20 3d 3e 20 27 c9 b2 27 2c 0a 20 20 27 c6 9f 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27500 | 3e 20 27 c9 b5 27 2c 0a 20 20 27 c6 a0 27 20 3d 3e 20 27 c6 a1 27 2c 0a 20 20 27 c6 a2 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27520 | 3e 20 27 c6 a3 27 2c 0a 20 20 27 c6 a4 27 20 3d 3e 20 27 c6 a5 27 2c 0a 20 20 27 c6 a6 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27540 | 3e 20 27 ca 80 27 2c 0a 20 20 27 c6 a7 27 20 3d 3e 20 27 c6 a8 27 2c 0a 20 20 27 c6 a9 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27560 | 3e 20 27 ca 83 27 2c 0a 20 20 27 c6 ac 27 20 3d 3e 20 27 c6 ad 27 2c 0a 20 20 27 c6 ae 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27580 | 3e 20 27 ca 88 27 2c 0a 20 20 27 c6 af 27 20 3d 3e 20 27 c6 b0 27 2c 0a 20 20 27 c6 b1 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
275a0 | 3e 20 27 ca 8a 27 2c 0a 20 20 27 c6 b2 27 20 3d 3e 20 27 ca 8b 27 2c 0a 20 20 27 c6 b3 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
275c0 | 3e 20 27 c6 b4 27 2c 0a 20 20 27 c6 b5 27 20 3d 3e 20 27 c6 b6 27 2c 0a 20 20 27 c6 b7 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
275e0 | 3e 20 27 ca 92 27 2c 0a 20 20 27 c6 b8 27 20 3d 3e 20 27 c6 b9 27 2c 0a 20 20 27 c6 bc 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27600 | 3e 20 27 c6 bd 27 2c 0a 20 20 27 c7 84 27 20 3d 3e 20 27 c7 86 27 2c 0a 20 20 27 c7 85 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27620 | 3e 20 27 c7 86 27 2c 0a 20 20 27 c7 87 27 20 3d 3e 20 27 c7 89 27 2c 0a 20 20 27 c7 88 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27640 | 3e 20 27 c7 89 27 2c 0a 20 20 27 c7 8a 27 20 3d 3e 20 27 c7 8c 27 2c 0a 20 20 27 c7 8b 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27660 | 3e 20 27 c7 8c 27 2c 0a 20 20 27 c7 8d 27 20 3d 3e 20 27 c7 8e 27 2c 0a 20 20 27 c7 8f 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27680 | 3e 20 27 c7 90 27 2c 0a 20 20 27 c7 91 27 20 3d 3e 20 27 c7 92 27 2c 0a 20 20 27 c7 93 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
276a0 | 3e 20 27 c7 94 27 2c 0a 20 20 27 c7 95 27 20 3d 3e 20 27 c7 96 27 2c 0a 20 20 27 c7 97 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
276c0 | 3e 20 27 c7 98 27 2c 0a 20 20 27 c7 99 27 20 3d 3e 20 27 c7 9a 27 2c 0a 20 20 27 c7 9b 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
276e0 | 3e 20 27 c7 9c 27 2c 0a 20 20 27 c7 9e 27 20 3d 3e 20 27 c7 9f 27 2c 0a 20 20 27 c7 a0 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27700 | 3e 20 27 c7 a1 27 2c 0a 20 20 27 c7 a2 27 20 3d 3e 20 27 c7 a3 27 2c 0a 20 20 27 c7 a4 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27720 | 3e 20 27 c7 a5 27 2c 0a 20 20 27 c7 a6 27 20 3d 3e 20 27 c7 a7 27 2c 0a 20 20 27 c7 a8 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27740 | 3e 20 27 c7 a9 27 2c 0a 20 20 27 c7 aa 27 20 3d 3e 20 27 c7 ab 27 2c 0a 20 20 27 c7 ac 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27760 | 3e 20 27 c7 ad 27 2c 0a 20 20 27 c7 ae 27 20 3d 3e 20 27 c7 af 27 2c 0a 20 20 27 c7 b1 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27780 | 3e 20 27 c7 b3 27 2c 0a 20 20 27 c7 b2 27 20 3d 3e 20 27 c7 b3 27 2c 0a 20 20 27 c7 b4 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
277a0 | 3e 20 27 c7 b5 27 2c 0a 20 20 27 c7 b6 27 20 3d 3e 20 27 c6 95 27 2c 0a 20 20 27 c7 b7 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
277c0 | 3e 20 27 c6 bf 27 2c 0a 20 20 27 c7 b8 27 20 3d 3e 20 27 c7 b9 27 2c 0a 20 20 27 c7 ba 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
277e0 | 3e 20 27 c7 bb 27 2c 0a 20 20 27 c7 bc 27 20 3d 3e 20 27 c7 bd 27 2c 0a 20 20 27 c7 be 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27800 | 3e 20 27 c7 bf 27 2c 0a 20 20 27 c8 80 27 20 3d 3e 20 27 c8 81 27 2c 0a 20 20 27 c8 82 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27820 | 3e 20 27 c8 83 27 2c 0a 20 20 27 c8 84 27 20 3d 3e 20 27 c8 85 27 2c 0a 20 20 27 c8 86 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27840 | 3e 20 27 c8 87 27 2c 0a 20 20 27 c8 88 27 20 3d 3e 20 27 c8 89 27 2c 0a 20 20 27 c8 8a 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27860 | 3e 20 27 c8 8b 27 2c 0a 20 20 27 c8 8c 27 20 3d 3e 20 27 c8 8d 27 2c 0a 20 20 27 c8 8e 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27880 | 3e 20 27 c8 8f 27 2c 0a 20 20 27 c8 90 27 20 3d 3e 20 27 c8 91 27 2c 0a 20 20 27 c8 92 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
278a0 | 3e 20 27 c8 93 27 2c 0a 20 20 27 c8 94 27 20 3d 3e 20 27 c8 95 27 2c 0a 20 20 27 c8 96 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
278c0 | 3e 20 27 c8 97 27 2c 0a 20 20 27 c8 98 27 20 3d 3e 20 27 c8 99 27 2c 0a 20 20 27 c8 9a 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
278e0 | 3e 20 27 c8 9b 27 2c 0a 20 20 27 c8 9c 27 20 3d 3e 20 27 c8 9d 27 2c 0a 20 20 27 c8 9e 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27900 | 3e 20 27 c8 9f 27 2c 0a 20 20 27 c8 a0 27 20 3d 3e 20 27 c6 9e 27 2c 0a 20 20 27 c8 a2 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27920 | 3e 20 27 c8 a3 27 2c 0a 20 20 27 c8 a4 27 20 3d 3e 20 27 c8 a5 27 2c 0a 20 20 27 c8 a6 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27940 | 3e 20 27 c8 a7 27 2c 0a 20 20 27 c8 a8 27 20 3d 3e 20 27 c8 a9 27 2c 0a 20 20 27 c8 aa 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27960 | 3e 20 27 c8 ab 27 2c 0a 20 20 27 c8 ac 27 20 3d 3e 20 27 c8 ad 27 2c 0a 20 20 27 c8 ae 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
27980 | 3e 20 27 c8 af 27 2c 0a 20 20 27 c8 b0 27 20 3d 3e 20 27 c8 b1 27 2c 0a 20 20 27 c8 b2 27 20 3d | >.'..',...'..'.=>.'..',...'..'.= |
279a0 | 3e 20 27 c8 b3 27 2c 0a 20 20 27 c8 ba 27 20 3d 3e 20 27 e2 b1 a5 27 2c 0a 20 20 27 c8 bb 27 20 | >.'..',...'..'.=>.'...',...'..'. |
279c0 | 3d 3e 20 27 c8 bc 27 2c 0a 20 20 27 c8 bd 27 20 3d 3e 20 27 c6 9a 27 2c 0a 20 20 27 c8 be 27 20 | =>.'..',...'..'.=>.'..',...'..'. |
279e0 | 3d 3e 20 27 e2 b1 a6 27 2c 0a 20 20 27 c9 81 27 20 3d 3e 20 27 c9 82 27 2c 0a 20 20 27 c9 83 27 | =>.'...',...'..'.=>.'..',...'..' |
27a00 | 20 3d 3e 20 27 c6 80 27 2c 0a 20 20 27 c9 84 27 20 3d 3e 20 27 ca 89 27 2c 0a 20 20 27 c9 85 27 | .=>.'..',...'..'.=>.'..',...'..' |
27a20 | 20 3d 3e 20 27 ca 8c 27 2c 0a 20 20 27 c9 86 27 20 3d 3e 20 27 c9 87 27 2c 0a 20 20 27 c9 88 27 | .=>.'..',...'..'.=>.'..',...'..' |
27a40 | 20 3d 3e 20 27 c9 89 27 2c 0a 20 20 27 c9 8a 27 20 3d 3e 20 27 c9 8b 27 2c 0a 20 20 27 c9 8c 27 | .=>.'..',...'..'.=>.'..',...'..' |
27a60 | 20 3d 3e 20 27 c9 8d 27 2c 0a 20 20 27 c9 8e 27 20 3d 3e 20 27 c9 8f 27 2c 0a 20 20 27 cd b0 27 | .=>.'..',...'..'.=>.'..',...'..' |
27a80 | 20 3d 3e 20 27 cd b1 27 2c 0a 20 20 27 cd b2 27 20 3d 3e 20 27 cd b3 27 2c 0a 20 20 27 cd b6 27 | .=>.'..',...'..'.=>.'..',...'..' |
27aa0 | 20 3d 3e 20 27 cd b7 27 2c 0a 20 20 27 cd bf 27 20 3d 3e 20 27 cf b3 27 2c 0a 20 20 27 ce 86 27 | .=>.'..',...'..'.=>.'..',...'..' |
27ac0 | 20 3d 3e 20 27 ce ac 27 2c 0a 20 20 27 ce 88 27 20 3d 3e 20 27 ce ad 27 2c 0a 20 20 27 ce 89 27 | .=>.'..',...'..'.=>.'..',...'..' |
27ae0 | 20 3d 3e 20 27 ce ae 27 2c 0a 20 20 27 ce 8a 27 20 3d 3e 20 27 ce af 27 2c 0a 20 20 27 ce 8c 27 | .=>.'..',...'..'.=>.'..',...'..' |
27b00 | 20 3d 3e 20 27 cf 8c 27 2c 0a 20 20 27 ce 8e 27 20 3d 3e 20 27 cf 8d 27 2c 0a 20 20 27 ce 8f 27 | .=>.'..',...'..'.=>.'..',...'..' |
27b20 | 20 3d 3e 20 27 cf 8e 27 2c 0a 20 20 27 ce 91 27 20 3d 3e 20 27 ce b1 27 2c 0a 20 20 27 ce 92 27 | .=>.'..',...'..'.=>.'..',...'..' |
27b40 | 20 3d 3e 20 27 ce b2 27 2c 0a 20 20 27 ce 93 27 20 3d 3e 20 27 ce b3 27 2c 0a 20 20 27 ce 94 27 | .=>.'..',...'..'.=>.'..',...'..' |
27b60 | 20 3d 3e 20 27 ce b4 27 2c 0a 20 20 27 ce 95 27 20 3d 3e 20 27 ce b5 27 2c 0a 20 20 27 ce 96 27 | .=>.'..',...'..'.=>.'..',...'..' |
27b80 | 20 3d 3e 20 27 ce b6 27 2c 0a 20 20 27 ce 97 27 20 3d 3e 20 27 ce b7 27 2c 0a 20 20 27 ce 98 27 | .=>.'..',...'..'.=>.'..',...'..' |
27ba0 | 20 3d 3e 20 27 ce b8 27 2c 0a 20 20 27 ce 99 27 20 3d 3e 20 27 ce b9 27 2c 0a 20 20 27 ce 9a 27 | .=>.'..',...'..'.=>.'..',...'..' |
27bc0 | 20 3d 3e 20 27 ce ba 27 2c 0a 20 20 27 ce 9b 27 20 3d 3e 20 27 ce bb 27 2c 0a 20 20 27 ce 9c 27 | .=>.'..',...'..'.=>.'..',...'..' |
27be0 | 20 3d 3e 20 27 ce bc 27 2c 0a 20 20 27 ce 9d 27 20 3d 3e 20 27 ce bd 27 2c 0a 20 20 27 ce 9e 27 | .=>.'..',...'..'.=>.'..',...'..' |
27c00 | 20 3d 3e 20 27 ce be 27 2c 0a 20 20 27 ce 9f 27 20 3d 3e 20 27 ce bf 27 2c 0a 20 20 27 ce a0 27 | .=>.'..',...'..'.=>.'..',...'..' |
27c20 | 20 3d 3e 20 27 cf 80 27 2c 0a 20 20 27 ce a1 27 20 3d 3e 20 27 cf 81 27 2c 0a 20 20 27 ce a3 27 | .=>.'..',...'..'.=>.'..',...'..' |
27c40 | 20 3d 3e 20 27 cf 83 27 2c 0a 20 20 27 ce a4 27 20 3d 3e 20 27 cf 84 27 2c 0a 20 20 27 ce a5 27 | .=>.'..',...'..'.=>.'..',...'..' |
27c60 | 20 3d 3e 20 27 cf 85 27 2c 0a 20 20 27 ce a6 27 20 3d 3e 20 27 cf 86 27 2c 0a 20 20 27 ce a7 27 | .=>.'..',...'..'.=>.'..',...'..' |
27c80 | 20 3d 3e 20 27 cf 87 27 2c 0a 20 20 27 ce a8 27 20 3d 3e 20 27 cf 88 27 2c 0a 20 20 27 ce a9 27 | .=>.'..',...'..'.=>.'..',...'..' |
27ca0 | 20 3d 3e 20 27 cf 89 27 2c 0a 20 20 27 ce aa 27 20 3d 3e 20 27 cf 8a 27 2c 0a 20 20 27 ce ab 27 | .=>.'..',...'..'.=>.'..',...'..' |
27cc0 | 20 3d 3e 20 27 cf 8b 27 2c 0a 20 20 27 cf 8f 27 20 3d 3e 20 27 cf 97 27 2c 0a 20 20 27 cf 98 27 | .=>.'..',...'..'.=>.'..',...'..' |
27ce0 | 20 3d 3e 20 27 cf 99 27 2c 0a 20 20 27 cf 9a 27 20 3d 3e 20 27 cf 9b 27 2c 0a 20 20 27 cf 9c 27 | .=>.'..',...'..'.=>.'..',...'..' |
27d00 | 20 3d 3e 20 27 cf 9d 27 2c 0a 20 20 27 cf 9e 27 20 3d 3e 20 27 cf 9f 27 2c 0a 20 20 27 cf a0 27 | .=>.'..',...'..'.=>.'..',...'..' |
27d20 | 20 3d 3e 20 27 cf a1 27 2c 0a 20 20 27 cf a2 27 20 3d 3e 20 27 cf a3 27 2c 0a 20 20 27 cf a4 27 | .=>.'..',...'..'.=>.'..',...'..' |
27d40 | 20 3d 3e 20 27 cf a5 27 2c 0a 20 20 27 cf a6 27 20 3d 3e 20 27 cf a7 27 2c 0a 20 20 27 cf a8 27 | .=>.'..',...'..'.=>.'..',...'..' |
27d60 | 20 3d 3e 20 27 cf a9 27 2c 0a 20 20 27 cf aa 27 20 3d 3e 20 27 cf ab 27 2c 0a 20 20 27 cf ac 27 | .=>.'..',...'..'.=>.'..',...'..' |
27d80 | 20 3d 3e 20 27 cf ad 27 2c 0a 20 20 27 cf ae 27 20 3d 3e 20 27 cf af 27 2c 0a 20 20 27 cf b4 27 | .=>.'..',...'..'.=>.'..',...'..' |
27da0 | 20 3d 3e 20 27 ce b8 27 2c 0a 20 20 27 cf b7 27 20 3d 3e 20 27 cf b8 27 2c 0a 20 20 27 cf b9 27 | .=>.'..',...'..'.=>.'..',...'..' |
27dc0 | 20 3d 3e 20 27 cf b2 27 2c 0a 20 20 27 cf ba 27 20 3d 3e 20 27 cf bb 27 2c 0a 20 20 27 cf bd 27 | .=>.'..',...'..'.=>.'..',...'..' |
27de0 | 20 3d 3e 20 27 cd bb 27 2c 0a 20 20 27 cf be 27 20 3d 3e 20 27 cd bc 27 2c 0a 20 20 27 cf bf 27 | .=>.'..',...'..'.=>.'..',...'..' |
27e00 | 20 3d 3e 20 27 cd bd 27 2c 0a 20 20 27 d0 80 27 20 3d 3e 20 27 d1 90 27 2c 0a 20 20 27 d0 81 27 | .=>.'..',...'..'.=>.'..',...'..' |
27e20 | 20 3d 3e 20 27 d1 91 27 2c 0a 20 20 27 d0 82 27 20 3d 3e 20 27 d1 92 27 2c 0a 20 20 27 d0 83 27 | .=>.'..',...'..'.=>.'..',...'..' |
27e40 | 20 3d 3e 20 27 d1 93 27 2c 0a 20 20 27 d0 84 27 20 3d 3e 20 27 d1 94 27 2c 0a 20 20 27 d0 85 27 | .=>.'..',...'..'.=>.'..',...'..' |
27e60 | 20 3d 3e 20 27 d1 95 27 2c 0a 20 20 27 d0 86 27 20 3d 3e 20 27 d1 96 27 2c 0a 20 20 27 d0 87 27 | .=>.'..',...'..'.=>.'..',...'..' |
27e80 | 20 3d 3e 20 27 d1 97 27 2c 0a 20 20 27 d0 88 27 20 3d 3e 20 27 d1 98 27 2c 0a 20 20 27 d0 89 27 | .=>.'..',...'..'.=>.'..',...'..' |
27ea0 | 20 3d 3e 20 27 d1 99 27 2c 0a 20 20 27 d0 8a 27 20 3d 3e 20 27 d1 9a 27 2c 0a 20 20 27 d0 8b 27 | .=>.'..',...'..'.=>.'..',...'..' |
27ec0 | 20 3d 3e 20 27 d1 9b 27 2c 0a 20 20 27 d0 8c 27 20 3d 3e 20 27 d1 9c 27 2c 0a 20 20 27 d0 8d 27 | .=>.'..',...'..'.=>.'..',...'..' |
27ee0 | 20 3d 3e 20 27 d1 9d 27 2c 0a 20 20 27 d0 8e 27 20 3d 3e 20 27 d1 9e 27 2c 0a 20 20 27 d0 8f 27 | .=>.'..',...'..'.=>.'..',...'..' |
27f00 | 20 3d 3e 20 27 d1 9f 27 2c 0a 20 20 27 d0 90 27 20 3d 3e 20 27 d0 b0 27 2c 0a 20 20 27 d0 91 27 | .=>.'..',...'..'.=>.'..',...'..' |
27f20 | 20 3d 3e 20 27 d0 b1 27 2c 0a 20 20 27 d0 92 27 20 3d 3e 20 27 d0 b2 27 2c 0a 20 20 27 d0 93 27 | .=>.'..',...'..'.=>.'..',...'..' |
27f40 | 20 3d 3e 20 27 d0 b3 27 2c 0a 20 20 27 d0 94 27 20 3d 3e 20 27 d0 b4 27 2c 0a 20 20 27 d0 95 27 | .=>.'..',...'..'.=>.'..',...'..' |
27f60 | 20 3d 3e 20 27 d0 b5 27 2c 0a 20 20 27 d0 96 27 20 3d 3e 20 27 d0 b6 27 2c 0a 20 20 27 d0 97 27 | .=>.'..',...'..'.=>.'..',...'..' |
27f80 | 20 3d 3e 20 27 d0 b7 27 2c 0a 20 20 27 d0 98 27 20 3d 3e 20 27 d0 b8 27 2c 0a 20 20 27 d0 99 27 | .=>.'..',...'..'.=>.'..',...'..' |
27fa0 | 20 3d 3e 20 27 d0 b9 27 2c 0a 20 20 27 d0 9a 27 20 3d 3e 20 27 d0 ba 27 2c 0a 20 20 27 d0 9b 27 | .=>.'..',...'..'.=>.'..',...'..' |
27fc0 | 20 3d 3e 20 27 d0 bb 27 2c 0a 20 20 27 d0 9c 27 20 3d 3e 20 27 d0 bc 27 2c 0a 20 20 27 d0 9d 27 | .=>.'..',...'..'.=>.'..',...'..' |
27fe0 | 20 3d 3e 20 27 d0 bd 27 2c 0a 20 20 27 d0 9e 27 20 3d 3e 20 27 d0 be 27 2c 0a 20 20 27 d0 9f 27 | .=>.'..',...'..'.=>.'..',...'..' |
28000 | 20 3d 3e 20 27 d0 bf 27 2c 0a 20 20 27 d0 a0 27 20 3d 3e 20 27 d1 80 27 2c 0a 20 20 27 d0 a1 27 | .=>.'..',...'..'.=>.'..',...'..' |
28020 | 20 3d 3e 20 27 d1 81 27 2c 0a 20 20 27 d0 a2 27 20 3d 3e 20 27 d1 82 27 2c 0a 20 20 27 d0 a3 27 | .=>.'..',...'..'.=>.'..',...'..' |
28040 | 20 3d 3e 20 27 d1 83 27 2c 0a 20 20 27 d0 a4 27 20 3d 3e 20 27 d1 84 27 2c 0a 20 20 27 d0 a5 27 | .=>.'..',...'..'.=>.'..',...'..' |
28060 | 20 3d 3e 20 27 d1 85 27 2c 0a 20 20 27 d0 a6 27 20 3d 3e 20 27 d1 86 27 2c 0a 20 20 27 d0 a7 27 | .=>.'..',...'..'.=>.'..',...'..' |
28080 | 20 3d 3e 20 27 d1 87 27 2c 0a 20 20 27 d0 a8 27 20 3d 3e 20 27 d1 88 27 2c 0a 20 20 27 d0 a9 27 | .=>.'..',...'..'.=>.'..',...'..' |
280a0 | 20 3d 3e 20 27 d1 89 27 2c 0a 20 20 27 d0 aa 27 20 3d 3e 20 27 d1 8a 27 2c 0a 20 20 27 d0 ab 27 | .=>.'..',...'..'.=>.'..',...'..' |
280c0 | 20 3d 3e 20 27 d1 8b 27 2c 0a 20 20 27 d0 ac 27 20 3d 3e 20 27 d1 8c 27 2c 0a 20 20 27 d0 ad 27 | .=>.'..',...'..'.=>.'..',...'..' |
280e0 | 20 3d 3e 20 27 d1 8d 27 2c 0a 20 20 27 d0 ae 27 20 3d 3e 20 27 d1 8e 27 2c 0a 20 20 27 d0 af 27 | .=>.'..',...'..'.=>.'..',...'..' |
28100 | 20 3d 3e 20 27 d1 8f 27 2c 0a 20 20 27 d1 a0 27 20 3d 3e 20 27 d1 a1 27 2c 0a 20 20 27 d1 a2 27 | .=>.'..',...'..'.=>.'..',...'..' |
28120 | 20 3d 3e 20 27 d1 a3 27 2c 0a 20 20 27 d1 a4 27 20 3d 3e 20 27 d1 a5 27 2c 0a 20 20 27 d1 a6 27 | .=>.'..',...'..'.=>.'..',...'..' |
28140 | 20 3d 3e 20 27 d1 a7 27 2c 0a 20 20 27 d1 a8 27 20 3d 3e 20 27 d1 a9 27 2c 0a 20 20 27 d1 aa 27 | .=>.'..',...'..'.=>.'..',...'..' |
28160 | 20 3d 3e 20 27 d1 ab 27 2c 0a 20 20 27 d1 ac 27 20 3d 3e 20 27 d1 ad 27 2c 0a 20 20 27 d1 ae 27 | .=>.'..',...'..'.=>.'..',...'..' |
28180 | 20 3d 3e 20 27 d1 af 27 2c 0a 20 20 27 d1 b0 27 20 3d 3e 20 27 d1 b1 27 2c 0a 20 20 27 d1 b2 27 | .=>.'..',...'..'.=>.'..',...'..' |
281a0 | 20 3d 3e 20 27 d1 b3 27 2c 0a 20 20 27 d1 b4 27 20 3d 3e 20 27 d1 b5 27 2c 0a 20 20 27 d1 b6 27 | .=>.'..',...'..'.=>.'..',...'..' |
281c0 | 20 3d 3e 20 27 d1 b7 27 2c 0a 20 20 27 d1 b8 27 20 3d 3e 20 27 d1 b9 27 2c 0a 20 20 27 d1 ba 27 | .=>.'..',...'..'.=>.'..',...'..' |
281e0 | 20 3d 3e 20 27 d1 bb 27 2c 0a 20 20 27 d1 bc 27 20 3d 3e 20 27 d1 bd 27 2c 0a 20 20 27 d1 be 27 | .=>.'..',...'..'.=>.'..',...'..' |
28200 | 20 3d 3e 20 27 d1 bf 27 2c 0a 20 20 27 d2 80 27 20 3d 3e 20 27 d2 81 27 2c 0a 20 20 27 d2 8a 27 | .=>.'..',...'..'.=>.'..',...'..' |
28220 | 20 3d 3e 20 27 d2 8b 27 2c 0a 20 20 27 d2 8c 27 20 3d 3e 20 27 d2 8d 27 2c 0a 20 20 27 d2 8e 27 | .=>.'..',...'..'.=>.'..',...'..' |
28240 | 20 3d 3e 20 27 d2 8f 27 2c 0a 20 20 27 d2 90 27 20 3d 3e 20 27 d2 91 27 2c 0a 20 20 27 d2 92 27 | .=>.'..',...'..'.=>.'..',...'..' |
28260 | 20 3d 3e 20 27 d2 93 27 2c 0a 20 20 27 d2 94 27 20 3d 3e 20 27 d2 95 27 2c 0a 20 20 27 d2 96 27 | .=>.'..',...'..'.=>.'..',...'..' |
28280 | 20 3d 3e 20 27 d2 97 27 2c 0a 20 20 27 d2 98 27 20 3d 3e 20 27 d2 99 27 2c 0a 20 20 27 d2 9a 27 | .=>.'..',...'..'.=>.'..',...'..' |
282a0 | 20 3d 3e 20 27 d2 9b 27 2c 0a 20 20 27 d2 9c 27 20 3d 3e 20 27 d2 9d 27 2c 0a 20 20 27 d2 9e 27 | .=>.'..',...'..'.=>.'..',...'..' |
282c0 | 20 3d 3e 20 27 d2 9f 27 2c 0a 20 20 27 d2 a0 27 20 3d 3e 20 27 d2 a1 27 2c 0a 20 20 27 d2 a2 27 | .=>.'..',...'..'.=>.'..',...'..' |
282e0 | 20 3d 3e 20 27 d2 a3 27 2c 0a 20 20 27 d2 a4 27 20 3d 3e 20 27 d2 a5 27 2c 0a 20 20 27 d2 a6 27 | .=>.'..',...'..'.=>.'..',...'..' |
28300 | 20 3d 3e 20 27 d2 a7 27 2c 0a 20 20 27 d2 a8 27 20 3d 3e 20 27 d2 a9 27 2c 0a 20 20 27 d2 aa 27 | .=>.'..',...'..'.=>.'..',...'..' |
28320 | 20 3d 3e 20 27 d2 ab 27 2c 0a 20 20 27 d2 ac 27 20 3d 3e 20 27 d2 ad 27 2c 0a 20 20 27 d2 ae 27 | .=>.'..',...'..'.=>.'..',...'..' |
28340 | 20 3d 3e 20 27 d2 af 27 2c 0a 20 20 27 d2 b0 27 20 3d 3e 20 27 d2 b1 27 2c 0a 20 20 27 d2 b2 27 | .=>.'..',...'..'.=>.'..',...'..' |
28360 | 20 3d 3e 20 27 d2 b3 27 2c 0a 20 20 27 d2 b4 27 20 3d 3e 20 27 d2 b5 27 2c 0a 20 20 27 d2 b6 27 | .=>.'..',...'..'.=>.'..',...'..' |
28380 | 20 3d 3e 20 27 d2 b7 27 2c 0a 20 20 27 d2 b8 27 20 3d 3e 20 27 d2 b9 27 2c 0a 20 20 27 d2 ba 27 | .=>.'..',...'..'.=>.'..',...'..' |
283a0 | 20 3d 3e 20 27 d2 bb 27 2c 0a 20 20 27 d2 bc 27 20 3d 3e 20 27 d2 bd 27 2c 0a 20 20 27 d2 be 27 | .=>.'..',...'..'.=>.'..',...'..' |
283c0 | 20 3d 3e 20 27 d2 bf 27 2c 0a 20 20 27 d3 80 27 20 3d 3e 20 27 d3 8f 27 2c 0a 20 20 27 d3 81 27 | .=>.'..',...'..'.=>.'..',...'..' |
283e0 | 20 3d 3e 20 27 d3 82 27 2c 0a 20 20 27 d3 83 27 20 3d 3e 20 27 d3 84 27 2c 0a 20 20 27 d3 85 27 | .=>.'..',...'..'.=>.'..',...'..' |
28400 | 20 3d 3e 20 27 d3 86 27 2c 0a 20 20 27 d3 87 27 20 3d 3e 20 27 d3 88 27 2c 0a 20 20 27 d3 89 27 | .=>.'..',...'..'.=>.'..',...'..' |
28420 | 20 3d 3e 20 27 d3 8a 27 2c 0a 20 20 27 d3 8b 27 20 3d 3e 20 27 d3 8c 27 2c 0a 20 20 27 d3 8d 27 | .=>.'..',...'..'.=>.'..',...'..' |
28440 | 20 3d 3e 20 27 d3 8e 27 2c 0a 20 20 27 d3 90 27 20 3d 3e 20 27 d3 91 27 2c 0a 20 20 27 d3 92 27 | .=>.'..',...'..'.=>.'..',...'..' |
28460 | 20 3d 3e 20 27 d3 93 27 2c 0a 20 20 27 d3 94 27 20 3d 3e 20 27 d3 95 27 2c 0a 20 20 27 d3 96 27 | .=>.'..',...'..'.=>.'..',...'..' |
28480 | 20 3d 3e 20 27 d3 97 27 2c 0a 20 20 27 d3 98 27 20 3d 3e 20 27 d3 99 27 2c 0a 20 20 27 d3 9a 27 | .=>.'..',...'..'.=>.'..',...'..' |
284a0 | 20 3d 3e 20 27 d3 9b 27 2c 0a 20 20 27 d3 9c 27 20 3d 3e 20 27 d3 9d 27 2c 0a 20 20 27 d3 9e 27 | .=>.'..',...'..'.=>.'..',...'..' |
284c0 | 20 3d 3e 20 27 d3 9f 27 2c 0a 20 20 27 d3 a0 27 20 3d 3e 20 27 d3 a1 27 2c 0a 20 20 27 d3 a2 27 | .=>.'..',...'..'.=>.'..',...'..' |
284e0 | 20 3d 3e 20 27 d3 a3 27 2c 0a 20 20 27 d3 a4 27 20 3d 3e 20 27 d3 a5 27 2c 0a 20 20 27 d3 a6 27 | .=>.'..',...'..'.=>.'..',...'..' |
28500 | 20 3d 3e 20 27 d3 a7 27 2c 0a 20 20 27 d3 a8 27 20 3d 3e 20 27 d3 a9 27 2c 0a 20 20 27 d3 aa 27 | .=>.'..',...'..'.=>.'..',...'..' |
28520 | 20 3d 3e 20 27 d3 ab 27 2c 0a 20 20 27 d3 ac 27 20 3d 3e 20 27 d3 ad 27 2c 0a 20 20 27 d3 ae 27 | .=>.'..',...'..'.=>.'..',...'..' |
28540 | 20 3d 3e 20 27 d3 af 27 2c 0a 20 20 27 d3 b0 27 20 3d 3e 20 27 d3 b1 27 2c 0a 20 20 27 d3 b2 27 | .=>.'..',...'..'.=>.'..',...'..' |
28560 | 20 3d 3e 20 27 d3 b3 27 2c 0a 20 20 27 d3 b4 27 20 3d 3e 20 27 d3 b5 27 2c 0a 20 20 27 d3 b6 27 | .=>.'..',...'..'.=>.'..',...'..' |
28580 | 20 3d 3e 20 27 d3 b7 27 2c 0a 20 20 27 d3 b8 27 20 3d 3e 20 27 d3 b9 27 2c 0a 20 20 27 d3 ba 27 | .=>.'..',...'..'.=>.'..',...'..' |
285a0 | 20 3d 3e 20 27 d3 bb 27 2c 0a 20 20 27 d3 bc 27 20 3d 3e 20 27 d3 bd 27 2c 0a 20 20 27 d3 be 27 | .=>.'..',...'..'.=>.'..',...'..' |
285c0 | 20 3d 3e 20 27 d3 bf 27 2c 0a 20 20 27 d4 80 27 20 3d 3e 20 27 d4 81 27 2c 0a 20 20 27 d4 82 27 | .=>.'..',...'..'.=>.'..',...'..' |
285e0 | 20 3d 3e 20 27 d4 83 27 2c 0a 20 20 27 d4 84 27 20 3d 3e 20 27 d4 85 27 2c 0a 20 20 27 d4 86 27 | .=>.'..',...'..'.=>.'..',...'..' |
28600 | 20 3d 3e 20 27 d4 87 27 2c 0a 20 20 27 d4 88 27 20 3d 3e 20 27 d4 89 27 2c 0a 20 20 27 d4 8a 27 | .=>.'..',...'..'.=>.'..',...'..' |
28620 | 20 3d 3e 20 27 d4 8b 27 2c 0a 20 20 27 d4 8c 27 20 3d 3e 20 27 d4 8d 27 2c 0a 20 20 27 d4 8e 27 | .=>.'..',...'..'.=>.'..',...'..' |
28640 | 20 3d 3e 20 27 d4 8f 27 2c 0a 20 20 27 d4 90 27 20 3d 3e 20 27 d4 91 27 2c 0a 20 20 27 d4 92 27 | .=>.'..',...'..'.=>.'..',...'..' |
28660 | 20 3d 3e 20 27 d4 93 27 2c 0a 20 20 27 d4 94 27 20 3d 3e 20 27 d4 95 27 2c 0a 20 20 27 d4 96 27 | .=>.'..',...'..'.=>.'..',...'..' |
28680 | 20 3d 3e 20 27 d4 97 27 2c 0a 20 20 27 d4 98 27 20 3d 3e 20 27 d4 99 27 2c 0a 20 20 27 d4 9a 27 | .=>.'..',...'..'.=>.'..',...'..' |
286a0 | 20 3d 3e 20 27 d4 9b 27 2c 0a 20 20 27 d4 9c 27 20 3d 3e 20 27 d4 9d 27 2c 0a 20 20 27 d4 9e 27 | .=>.'..',...'..'.=>.'..',...'..' |
286c0 | 20 3d 3e 20 27 d4 9f 27 2c 0a 20 20 27 d4 a0 27 20 3d 3e 20 27 d4 a1 27 2c 0a 20 20 27 d4 a2 27 | .=>.'..',...'..'.=>.'..',...'..' |
286e0 | 20 3d 3e 20 27 d4 a3 27 2c 0a 20 20 27 d4 a4 27 20 3d 3e 20 27 d4 a5 27 2c 0a 20 20 27 d4 a6 27 | .=>.'..',...'..'.=>.'..',...'..' |
28700 | 20 3d 3e 20 27 d4 a7 27 2c 0a 20 20 27 d4 a8 27 20 3d 3e 20 27 d4 a9 27 2c 0a 20 20 27 d4 aa 27 | .=>.'..',...'..'.=>.'..',...'..' |
28720 | 20 3d 3e 20 27 d4 ab 27 2c 0a 20 20 27 d4 ac 27 20 3d 3e 20 27 d4 ad 27 2c 0a 20 20 27 d4 ae 27 | .=>.'..',...'..'.=>.'..',...'..' |
28740 | 20 3d 3e 20 27 d4 af 27 2c 0a 20 20 27 d4 b1 27 20 3d 3e 20 27 d5 a1 27 2c 0a 20 20 27 d4 b2 27 | .=>.'..',...'..'.=>.'..',...'..' |
28760 | 20 3d 3e 20 27 d5 a2 27 2c 0a 20 20 27 d4 b3 27 20 3d 3e 20 27 d5 a3 27 2c 0a 20 20 27 d4 b4 27 | .=>.'..',...'..'.=>.'..',...'..' |
28780 | 20 3d 3e 20 27 d5 a4 27 2c 0a 20 20 27 d4 b5 27 20 3d 3e 20 27 d5 a5 27 2c 0a 20 20 27 d4 b6 27 | .=>.'..',...'..'.=>.'..',...'..' |
287a0 | 20 3d 3e 20 27 d5 a6 27 2c 0a 20 20 27 d4 b7 27 20 3d 3e 20 27 d5 a7 27 2c 0a 20 20 27 d4 b8 27 | .=>.'..',...'..'.=>.'..',...'..' |
287c0 | 20 3d 3e 20 27 d5 a8 27 2c 0a 20 20 27 d4 b9 27 20 3d 3e 20 27 d5 a9 27 2c 0a 20 20 27 d4 ba 27 | .=>.'..',...'..'.=>.'..',...'..' |
287e0 | 20 3d 3e 20 27 d5 aa 27 2c 0a 20 20 27 d4 bb 27 20 3d 3e 20 27 d5 ab 27 2c 0a 20 20 27 d4 bc 27 | .=>.'..',...'..'.=>.'..',...'..' |
28800 | 20 3d 3e 20 27 d5 ac 27 2c 0a 20 20 27 d4 bd 27 20 3d 3e 20 27 d5 ad 27 2c 0a 20 20 27 d4 be 27 | .=>.'..',...'..'.=>.'..',...'..' |
28820 | 20 3d 3e 20 27 d5 ae 27 2c 0a 20 20 27 d4 bf 27 20 3d 3e 20 27 d5 af 27 2c 0a 20 20 27 d5 80 27 | .=>.'..',...'..'.=>.'..',...'..' |
28840 | 20 3d 3e 20 27 d5 b0 27 2c 0a 20 20 27 d5 81 27 20 3d 3e 20 27 d5 b1 27 2c 0a 20 20 27 d5 82 27 | .=>.'..',...'..'.=>.'..',...'..' |
28860 | 20 3d 3e 20 27 d5 b2 27 2c 0a 20 20 27 d5 83 27 20 3d 3e 20 27 d5 b3 27 2c 0a 20 20 27 d5 84 27 | .=>.'..',...'..'.=>.'..',...'..' |
28880 | 20 3d 3e 20 27 d5 b4 27 2c 0a 20 20 27 d5 85 27 20 3d 3e 20 27 d5 b5 27 2c 0a 20 20 27 d5 86 27 | .=>.'..',...'..'.=>.'..',...'..' |
288a0 | 20 3d 3e 20 27 d5 b6 27 2c 0a 20 20 27 d5 87 27 20 3d 3e 20 27 d5 b7 27 2c 0a 20 20 27 d5 88 27 | .=>.'..',...'..'.=>.'..',...'..' |
288c0 | 20 3d 3e 20 27 d5 b8 27 2c 0a 20 20 27 d5 89 27 20 3d 3e 20 27 d5 b9 27 2c 0a 20 20 27 d5 8a 27 | .=>.'..',...'..'.=>.'..',...'..' |
288e0 | 20 3d 3e 20 27 d5 ba 27 2c 0a 20 20 27 d5 8b 27 20 3d 3e 20 27 d5 bb 27 2c 0a 20 20 27 d5 8c 27 | .=>.'..',...'..'.=>.'..',...'..' |
28900 | 20 3d 3e 20 27 d5 bc 27 2c 0a 20 20 27 d5 8d 27 20 3d 3e 20 27 d5 bd 27 2c 0a 20 20 27 d5 8e 27 | .=>.'..',...'..'.=>.'..',...'..' |
28920 | 20 3d 3e 20 27 d5 be 27 2c 0a 20 20 27 d5 8f 27 20 3d 3e 20 27 d5 bf 27 2c 0a 20 20 27 d5 90 27 | .=>.'..',...'..'.=>.'..',...'..' |
28940 | 20 3d 3e 20 27 d6 80 27 2c 0a 20 20 27 d5 91 27 20 3d 3e 20 27 d6 81 27 2c 0a 20 20 27 d5 92 27 | .=>.'..',...'..'.=>.'..',...'..' |
28960 | 20 3d 3e 20 27 d6 82 27 2c 0a 20 20 27 d5 93 27 20 3d 3e 20 27 d6 83 27 2c 0a 20 20 27 d5 94 27 | .=>.'..',...'..'.=>.'..',...'..' |
28980 | 20 3d 3e 20 27 d6 84 27 2c 0a 20 20 27 d5 95 27 20 3d 3e 20 27 d6 85 27 2c 0a 20 20 27 d5 96 27 | .=>.'..',...'..'.=>.'..',...'..' |
289a0 | 20 3d 3e 20 27 d6 86 27 2c 0a 20 20 27 e1 82 a0 27 20 3d 3e 20 27 e2 b4 80 27 2c 0a 20 20 27 e1 | .=>.'..',...'...'.=>.'...',...'. |
289c0 | 82 a1 27 20 3d 3e 20 27 e2 b4 81 27 2c 0a 20 20 27 e1 82 a2 27 20 3d 3e 20 27 e2 b4 82 27 2c 0a | ..'.=>.'...',...'...'.=>.'...',. |
289e0 | 20 20 27 e1 82 a3 27 20 3d 3e 20 27 e2 b4 83 27 2c 0a 20 20 27 e1 82 a4 27 20 3d 3e 20 27 e2 b4 | ..'...'.=>.'...',...'...'.=>.'.. |
28a00 | 84 27 2c 0a 20 20 27 e1 82 a5 27 20 3d 3e 20 27 e2 b4 85 27 2c 0a 20 20 27 e1 82 a6 27 20 3d 3e | .',...'...'.=>.'...',...'...'.=> |
28a20 | 20 27 e2 b4 86 27 2c 0a 20 20 27 e1 82 a7 27 20 3d 3e 20 27 e2 b4 87 27 2c 0a 20 20 27 e1 82 a8 | .'...',...'...'.=>.'...',...'... |
28a40 | 27 20 3d 3e 20 27 e2 b4 88 27 2c 0a 20 20 27 e1 82 a9 27 20 3d 3e 20 27 e2 b4 89 27 2c 0a 20 20 | '.=>.'...',...'...'.=>.'...',... |
28a60 | 27 e1 82 aa 27 20 3d 3e 20 27 e2 b4 8a 27 2c 0a 20 20 27 e1 82 ab 27 20 3d 3e 20 27 e2 b4 8b 27 | '...'.=>.'...',...'...'.=>.'...' |
28a80 | 2c 0a 20 20 27 e1 82 ac 27 20 3d 3e 20 27 e2 b4 8c 27 2c 0a 20 20 27 e1 82 ad 27 20 3d 3e 20 27 | ,...'...'.=>.'...',...'...'.=>.' |
28aa0 | e2 b4 8d 27 2c 0a 20 20 27 e1 82 ae 27 20 3d 3e 20 27 e2 b4 8e 27 2c 0a 20 20 27 e1 82 af 27 20 | ...',...'...'.=>.'...',...'...'. |
28ac0 | 3d 3e 20 27 e2 b4 8f 27 2c 0a 20 20 27 e1 82 b0 27 20 3d 3e 20 27 e2 b4 90 27 2c 0a 20 20 27 e1 | =>.'...',...'...'.=>.'...',...'. |
28ae0 | 82 b1 27 20 3d 3e 20 27 e2 b4 91 27 2c 0a 20 20 27 e1 82 b2 27 20 3d 3e 20 27 e2 b4 92 27 2c 0a | ..'.=>.'...',...'...'.=>.'...',. |
28b00 | 20 20 27 e1 82 b3 27 20 3d 3e 20 27 e2 b4 93 27 2c 0a 20 20 27 e1 82 b4 27 20 3d 3e 20 27 e2 b4 | ..'...'.=>.'...',...'...'.=>.'.. |
28b20 | 94 27 2c 0a 20 20 27 e1 82 b5 27 20 3d 3e 20 27 e2 b4 95 27 2c 0a 20 20 27 e1 82 b6 27 20 3d 3e | .',...'...'.=>.'...',...'...'.=> |
28b40 | 20 27 e2 b4 96 27 2c 0a 20 20 27 e1 82 b7 27 20 3d 3e 20 27 e2 b4 97 27 2c 0a 20 20 27 e1 82 b8 | .'...',...'...'.=>.'...',...'... |
28b60 | 27 20 3d 3e 20 27 e2 b4 98 27 2c 0a 20 20 27 e1 82 b9 27 20 3d 3e 20 27 e2 b4 99 27 2c 0a 20 20 | '.=>.'...',...'...'.=>.'...',... |
28b80 | 27 e1 82 ba 27 20 3d 3e 20 27 e2 b4 9a 27 2c 0a 20 20 27 e1 82 bb 27 20 3d 3e 20 27 e2 b4 9b 27 | '...'.=>.'...',...'...'.=>.'...' |
28ba0 | 2c 0a 20 20 27 e1 82 bc 27 20 3d 3e 20 27 e2 b4 9c 27 2c 0a 20 20 27 e1 82 bd 27 20 3d 3e 20 27 | ,...'...'.=>.'...',...'...'.=>.' |
28bc0 | e2 b4 9d 27 2c 0a 20 20 27 e1 82 be 27 20 3d 3e 20 27 e2 b4 9e 27 2c 0a 20 20 27 e1 82 bf 27 20 | ...',...'...'.=>.'...',...'...'. |
28be0 | 3d 3e 20 27 e2 b4 9f 27 2c 0a 20 20 27 e1 83 80 27 20 3d 3e 20 27 e2 b4 a0 27 2c 0a 20 20 27 e1 | =>.'...',...'...'.=>.'...',...'. |
28c00 | 83 81 27 20 3d 3e 20 27 e2 b4 a1 27 2c 0a 20 20 27 e1 83 82 27 20 3d 3e 20 27 e2 b4 a2 27 2c 0a | ..'.=>.'...',...'...'.=>.'...',. |
28c20 | 20 20 27 e1 83 83 27 20 3d 3e 20 27 e2 b4 a3 27 2c 0a 20 20 27 e1 83 84 27 20 3d 3e 20 27 e2 b4 | ..'...'.=>.'...',...'...'.=>.'.. |
28c40 | a4 27 2c 0a 20 20 27 e1 83 85 27 20 3d 3e 20 27 e2 b4 a5 27 2c 0a 20 20 27 e1 83 87 27 20 3d 3e | .',...'...'.=>.'...',...'...'.=> |
28c60 | 20 27 e2 b4 a7 27 2c 0a 20 20 27 e1 83 8d 27 20 3d 3e 20 27 e2 b4 ad 27 2c 0a 20 20 27 e1 b8 80 | .'...',...'...'.=>.'...',...'... |
28c80 | 27 20 3d 3e 20 27 e1 b8 81 27 2c 0a 20 20 27 e1 b8 82 27 20 3d 3e 20 27 e1 b8 83 27 2c 0a 20 20 | '.=>.'...',...'...'.=>.'...',... |
28ca0 | 27 e1 b8 84 27 20 3d 3e 20 27 e1 b8 85 27 2c 0a 20 20 27 e1 b8 86 27 20 3d 3e 20 27 e1 b8 87 27 | '...'.=>.'...',...'...'.=>.'...' |
28cc0 | 2c 0a 20 20 27 e1 b8 88 27 20 3d 3e 20 27 e1 b8 89 27 2c 0a 20 20 27 e1 b8 8a 27 20 3d 3e 20 27 | ,...'...'.=>.'...',...'...'.=>.' |
28ce0 | e1 b8 8b 27 2c 0a 20 20 27 e1 b8 8c 27 20 3d 3e 20 27 e1 b8 8d 27 2c 0a 20 20 27 e1 b8 8e 27 20 | ...',...'...'.=>.'...',...'...'. |
28d00 | 3d 3e 20 27 e1 b8 8f 27 2c 0a 20 20 27 e1 b8 90 27 20 3d 3e 20 27 e1 b8 91 27 2c 0a 20 20 27 e1 | =>.'...',...'...'.=>.'...',...'. |
28d20 | b8 92 27 20 3d 3e 20 27 e1 b8 93 27 2c 0a 20 20 27 e1 b8 94 27 20 3d 3e 20 27 e1 b8 95 27 2c 0a | ..'.=>.'...',...'...'.=>.'...',. |
28d40 | 20 20 27 e1 b8 96 27 20 3d 3e 20 27 e1 b8 97 27 2c 0a 20 20 27 e1 b8 98 27 20 3d 3e 20 27 e1 b8 | ..'...'.=>.'...',...'...'.=>.'.. |
28d60 | 99 27 2c 0a 20 20 27 e1 b8 9a 27 20 3d 3e 20 27 e1 b8 9b 27 2c 0a 20 20 27 e1 b8 9c 27 20 3d 3e | .',...'...'.=>.'...',...'...'.=> |
28d80 | 20 27 e1 b8 9d 27 2c 0a 20 20 27 e1 b8 9e 27 20 3d 3e 20 27 e1 b8 9f 27 2c 0a 20 20 27 e1 b8 a0 | .'...',...'...'.=>.'...',...'... |
28da0 | 27 20 3d 3e 20 27 e1 b8 a1 27 2c 0a 20 20 27 e1 b8 a2 27 20 3d 3e 20 27 e1 b8 a3 27 2c 0a 20 20 | '.=>.'...',...'...'.=>.'...',... |
28dc0 | 27 e1 b8 a4 27 20 3d 3e 20 27 e1 b8 a5 27 2c 0a 20 20 27 e1 b8 a6 27 20 3d 3e 20 27 e1 b8 a7 27 | '...'.=>.'...',...'...'.=>.'...' |
28de0 | 2c 0a 20 20 27 e1 b8 a8 27 20 3d 3e 20 27 e1 b8 a9 27 2c 0a 20 20 27 e1 b8 aa 27 20 3d 3e 20 27 | ,...'...'.=>.'...',...'...'.=>.' |
28e00 | e1 b8 ab 27 2c 0a 20 20 27 e1 b8 ac 27 20 3d 3e 20 27 e1 b8 ad 27 2c 0a 20 20 27 e1 b8 ae 27 20 | ...',...'...'.=>.'...',...'...'. |
28e20 | 3d 3e 20 27 e1 b8 af 27 2c 0a 20 20 27 e1 b8 b0 27 20 3d 3e 20 27 e1 b8 b1 27 2c 0a 20 20 27 e1 | =>.'...',...'...'.=>.'...',...'. |
28e40 | b8 b2 27 20 3d 3e 20 27 e1 b8 b3 27 2c 0a 20 20 27 e1 b8 b4 27 20 3d 3e 20 27 e1 b8 b5 27 2c 0a | ..'.=>.'...',...'...'.=>.'...',. |
28e60 | 20 20 27 e1 b8 b6 27 20 3d 3e 20 27 e1 b8 b7 27 2c 0a 20 20 27 e1 b8 b8 27 20 3d 3e 20 27 e1 b8 | ..'...'.=>.'...',...'...'.=>.'.. |
28e80 | b9 27 2c 0a 20 20 27 e1 b8 ba 27 20 3d 3e 20 27 e1 b8 bb 27 2c 0a 20 20 27 e1 b8 bc 27 20 3d 3e | .',...'...'.=>.'...',...'...'.=> |
28ea0 | 20 27 e1 b8 bd 27 2c 0a 20 20 27 e1 b8 be 27 20 3d 3e 20 27 e1 b8 bf 27 2c 0a 20 20 27 e1 b9 80 | .'...',...'...'.=>.'...',...'... |
28ec0 | 27 20 3d 3e 20 27 e1 b9 81 27 2c 0a 20 20 27 e1 b9 82 27 20 3d 3e 20 27 e1 b9 83 27 2c 0a 20 20 | '.=>.'...',...'...'.=>.'...',... |
28ee0 | 27 e1 b9 84 27 20 3d 3e 20 27 e1 b9 85 27 2c 0a 20 20 27 e1 b9 86 27 20 3d 3e 20 27 e1 b9 87 27 | '...'.=>.'...',...'...'.=>.'...' |
28f00 | 2c 0a 20 20 27 e1 b9 88 27 20 3d 3e 20 27 e1 b9 89 27 2c 0a 20 20 27 e1 b9 8a 27 20 3d 3e 20 27 | ,...'...'.=>.'...',...'...'.=>.' |
28f20 | e1 b9 8b 27 2c 0a 20 20 27 e1 b9 8c 27 20 3d 3e 20 27 e1 b9 8d 27 2c 0a 20 20 27 e1 b9 8e 27 20 | ...',...'...'.=>.'...',...'...'. |
28f40 | 3d 3e 20 27 e1 b9 8f 27 2c 0a 20 20 27 e1 b9 90 27 20 3d 3e 20 27 e1 b9 91 27 2c 0a 20 20 27 e1 | =>.'...',...'...'.=>.'...',...'. |
28f60 | b9 92 27 20 3d 3e 20 27 e1 b9 93 27 2c 0a 20 20 27 e1 b9 94 27 20 3d 3e 20 27 e1 b9 95 27 2c 0a | ..'.=>.'...',...'...'.=>.'...',. |
28f80 | 20 20 27 e1 b9 96 27 20 3d 3e 20 27 e1 b9 97 27 2c 0a 20 20 27 e1 b9 98 27 20 3d 3e 20 27 e1 b9 | ..'...'.=>.'...',...'...'.=>.'.. |
28fa0 | 99 27 2c 0a 20 20 27 e1 b9 9a 27 20 3d 3e 20 27 e1 b9 9b 27 2c 0a 20 20 27 e1 b9 9c 27 20 3d 3e | .',...'...'.=>.'...',...'...'.=> |
28fc0 | 20 27 e1 b9 9d 27 2c 0a 20 20 27 e1 b9 9e 27 20 3d 3e 20 27 e1 b9 9f 27 2c 0a 20 20 27 e1 b9 a0 | .'...',...'...'.=>.'...',...'... |
28fe0 | 27 20 3d 3e 20 27 e1 b9 a1 27 2c 0a 20 20 27 e1 b9 a2 27 20 3d 3e 20 27 e1 b9 a3 27 2c 0a 20 20 | '.=>.'...',...'...'.=>.'...',... |
29000 | 27 e1 b9 a4 27 20 3d 3e 20 27 e1 b9 a5 27 2c 0a 20 20 27 e1 b9 a6 27 20 3d 3e 20 27 e1 b9 a7 27 | '...'.=>.'...',...'...'.=>.'...' |
29020 | 2c 0a 20 20 27 e1 b9 a8 27 20 3d 3e 20 27 e1 b9 a9 27 2c 0a 20 20 27 e1 b9 aa 27 20 3d 3e 20 27 | ,...'...'.=>.'...',...'...'.=>.' |
29040 | e1 b9 ab 27 2c 0a 20 20 27 e1 b9 ac 27 20 3d 3e 20 27 e1 b9 ad 27 2c 0a 20 20 27 e1 b9 ae 27 20 | ...',...'...'.=>.'...',...'...'. |
29060 | 3d 3e 20 27 e1 b9 af 27 2c 0a 20 20 27 e1 b9 b0 27 20 3d 3e 20 27 e1 b9 b1 27 2c 0a 20 20 27 e1 | =>.'...',...'...'.=>.'...',...'. |
29080 | b9 b2 27 20 3d 3e 20 27 e1 b9 b3 27 2c 0a 20 20 27 e1 b9 b4 27 20 3d 3e 20 27 e1 b9 b5 27 2c 0a | ..'.=>.'...',...'...'.=>.'...',. |
290a0 | 20 20 27 e1 b9 b6 27 20 3d 3e 20 27 e1 b9 b7 27 2c 0a 20 20 27 e1 b9 b8 27 20 3d 3e 20 27 e1 b9 | ..'...'.=>.'...',...'...'.=>.'.. |
290c0 | b9 27 2c 0a 20 20 27 e1 b9 ba 27 20 3d 3e 20 27 e1 b9 bb 27 2c 0a 20 20 27 e1 b9 bc 27 20 3d 3e | .',...'...'.=>.'...',...'...'.=> |
290e0 | 20 27 e1 b9 bd 27 2c 0a 20 20 27 e1 b9 be 27 20 3d 3e 20 27 e1 b9 bf 27 2c 0a 20 20 27 e1 ba 80 | .'...',...'...'.=>.'...',...'... |
29100 | 27 20 3d 3e 20 27 e1 ba 81 27 2c 0a 20 20 27 e1 ba 82 27 20 3d 3e 20 27 e1 ba 83 27 2c 0a 20 20 | '.=>.'...',...'...'.=>.'...',... |
29120 | 27 e1 ba 84 27 20 3d 3e 20 27 e1 ba 85 27 2c 0a 20 20 27 e1 ba 86 27 20 3d 3e 20 27 e1 ba 87 27 | '...'.=>.'...',...'...'.=>.'...' |
29140 | 2c 0a 20 20 27 e1 ba 88 27 20 3d 3e 20 27 e1 ba 89 27 2c 0a 20 20 27 e1 ba 8a 27 20 3d 3e 20 27 | ,...'...'.=>.'...',...'...'.=>.' |
29160 | e1 ba 8b 27 2c 0a 20 20 27 e1 ba 8c 27 20 3d 3e 20 27 e1 ba 8d 27 2c 0a 20 20 27 e1 ba 8e 27 20 | ...',...'...'.=>.'...',...'...'. |
29180 | 3d 3e 20 27 e1 ba 8f 27 2c 0a 20 20 27 e1 ba 90 27 20 3d 3e 20 27 e1 ba 91 27 2c 0a 20 20 27 e1 | =>.'...',...'...'.=>.'...',...'. |
291a0 | ba 92 27 20 3d 3e 20 27 e1 ba 93 27 2c 0a 20 20 27 e1 ba 94 27 20 3d 3e 20 27 e1 ba 95 27 2c 0a | ..'.=>.'...',...'...'.=>.'...',. |
291c0 | 20 20 27 e1 ba 9e 27 20 3d 3e 20 27 c3 9f 27 2c 0a 20 20 27 e1 ba a0 27 20 3d 3e 20 27 e1 ba a1 | ..'...'.=>.'..',...'...'.=>.'... |
291e0 | 27 2c 0a 20 20 27 e1 ba a2 27 20 3d 3e 20 27 e1 ba a3 27 2c 0a 20 20 27 e1 ba a4 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
29200 | 27 e1 ba a5 27 2c 0a 20 20 27 e1 ba a6 27 20 3d 3e 20 27 e1 ba a7 27 2c 0a 20 20 27 e1 ba a8 27 | '...',...'...'.=>.'...',...'...' |
29220 | 20 3d 3e 20 27 e1 ba a9 27 2c 0a 20 20 27 e1 ba aa 27 20 3d 3e 20 27 e1 ba ab 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
29240 | e1 ba ac 27 20 3d 3e 20 27 e1 ba ad 27 2c 0a 20 20 27 e1 ba ae 27 20 3d 3e 20 27 e1 ba af 27 2c | ...'.=>.'...',...'...'.=>.'...', |
29260 | 0a 20 20 27 e1 ba b0 27 20 3d 3e 20 27 e1 ba b1 27 2c 0a 20 20 27 e1 ba b2 27 20 3d 3e 20 27 e1 | ...'...'.=>.'...',...'...'.=>.'. |
29280 | ba b3 27 2c 0a 20 20 27 e1 ba b4 27 20 3d 3e 20 27 e1 ba b5 27 2c 0a 20 20 27 e1 ba b6 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
292a0 | 3e 20 27 e1 ba b7 27 2c 0a 20 20 27 e1 ba b8 27 20 3d 3e 20 27 e1 ba b9 27 2c 0a 20 20 27 e1 ba | >.'...',...'...'.=>.'...',...'.. |
292c0 | ba 27 20 3d 3e 20 27 e1 ba bb 27 2c 0a 20 20 27 e1 ba bc 27 20 3d 3e 20 27 e1 ba bd 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
292e0 | 20 27 e1 ba be 27 20 3d 3e 20 27 e1 ba bf 27 2c 0a 20 20 27 e1 bb 80 27 20 3d 3e 20 27 e1 bb 81 | .'...'.=>.'...',...'...'.=>.'... |
29300 | 27 2c 0a 20 20 27 e1 bb 82 27 20 3d 3e 20 27 e1 bb 83 27 2c 0a 20 20 27 e1 bb 84 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
29320 | 27 e1 bb 85 27 2c 0a 20 20 27 e1 bb 86 27 20 3d 3e 20 27 e1 bb 87 27 2c 0a 20 20 27 e1 bb 88 27 | '...',...'...'.=>.'...',...'...' |
29340 | 20 3d 3e 20 27 e1 bb 89 27 2c 0a 20 20 27 e1 bb 8a 27 20 3d 3e 20 27 e1 bb 8b 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
29360 | e1 bb 8c 27 20 3d 3e 20 27 e1 bb 8d 27 2c 0a 20 20 27 e1 bb 8e 27 20 3d 3e 20 27 e1 bb 8f 27 2c | ...'.=>.'...',...'...'.=>.'...', |
29380 | 0a 20 20 27 e1 bb 90 27 20 3d 3e 20 27 e1 bb 91 27 2c 0a 20 20 27 e1 bb 92 27 20 3d 3e 20 27 e1 | ...'...'.=>.'...',...'...'.=>.'. |
293a0 | bb 93 27 2c 0a 20 20 27 e1 bb 94 27 20 3d 3e 20 27 e1 bb 95 27 2c 0a 20 20 27 e1 bb 96 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
293c0 | 3e 20 27 e1 bb 97 27 2c 0a 20 20 27 e1 bb 98 27 20 3d 3e 20 27 e1 bb 99 27 2c 0a 20 20 27 e1 bb | >.'...',...'...'.=>.'...',...'.. |
293e0 | 9a 27 20 3d 3e 20 27 e1 bb 9b 27 2c 0a 20 20 27 e1 bb 9c 27 20 3d 3e 20 27 e1 bb 9d 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
29400 | 20 27 e1 bb 9e 27 20 3d 3e 20 27 e1 bb 9f 27 2c 0a 20 20 27 e1 bb a0 27 20 3d 3e 20 27 e1 bb a1 | .'...'.=>.'...',...'...'.=>.'... |
29420 | 27 2c 0a 20 20 27 e1 bb a2 27 20 3d 3e 20 27 e1 bb a3 27 2c 0a 20 20 27 e1 bb a4 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
29440 | 27 e1 bb a5 27 2c 0a 20 20 27 e1 bb a6 27 20 3d 3e 20 27 e1 bb a7 27 2c 0a 20 20 27 e1 bb a8 27 | '...',...'...'.=>.'...',...'...' |
29460 | 20 3d 3e 20 27 e1 bb a9 27 2c 0a 20 20 27 e1 bb aa 27 20 3d 3e 20 27 e1 bb ab 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
29480 | e1 bb ac 27 20 3d 3e 20 27 e1 bb ad 27 2c 0a 20 20 27 e1 bb ae 27 20 3d 3e 20 27 e1 bb af 27 2c | ...'.=>.'...',...'...'.=>.'...', |
294a0 | 0a 20 20 27 e1 bb b0 27 20 3d 3e 20 27 e1 bb b1 27 2c 0a 20 20 27 e1 bb b2 27 20 3d 3e 20 27 e1 | ...'...'.=>.'...',...'...'.=>.'. |
294c0 | bb b3 27 2c 0a 20 20 27 e1 bb b4 27 20 3d 3e 20 27 e1 bb b5 27 2c 0a 20 20 27 e1 bb b6 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
294e0 | 3e 20 27 e1 bb b7 27 2c 0a 20 20 27 e1 bb b8 27 20 3d 3e 20 27 e1 bb b9 27 2c 0a 20 20 27 e1 bb | >.'...',...'...'.=>.'...',...'.. |
29500 | ba 27 20 3d 3e 20 27 e1 bb bb 27 2c 0a 20 20 27 e1 bb bc 27 20 3d 3e 20 27 e1 bb bd 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
29520 | 20 27 e1 bb be 27 20 3d 3e 20 27 e1 bb bf 27 2c 0a 20 20 27 e1 bc 88 27 20 3d 3e 20 27 e1 bc 80 | .'...'.=>.'...',...'...'.=>.'... |
29540 | 27 2c 0a 20 20 27 e1 bc 89 27 20 3d 3e 20 27 e1 bc 81 27 2c 0a 20 20 27 e1 bc 8a 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
29560 | 27 e1 bc 82 27 2c 0a 20 20 27 e1 bc 8b 27 20 3d 3e 20 27 e1 bc 83 27 2c 0a 20 20 27 e1 bc 8c 27 | '...',...'...'.=>.'...',...'...' |
29580 | 20 3d 3e 20 27 e1 bc 84 27 2c 0a 20 20 27 e1 bc 8d 27 20 3d 3e 20 27 e1 bc 85 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
295a0 | e1 bc 8e 27 20 3d 3e 20 27 e1 bc 86 27 2c 0a 20 20 27 e1 bc 8f 27 20 3d 3e 20 27 e1 bc 87 27 2c | ...'.=>.'...',...'...'.=>.'...', |
295c0 | 0a 20 20 27 e1 bc 98 27 20 3d 3e 20 27 e1 bc 90 27 2c 0a 20 20 27 e1 bc 99 27 20 3d 3e 20 27 e1 | ...'...'.=>.'...',...'...'.=>.'. |
295e0 | bc 91 27 2c 0a 20 20 27 e1 bc 9a 27 20 3d 3e 20 27 e1 bc 92 27 2c 0a 20 20 27 e1 bc 9b 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
29600 | 3e 20 27 e1 bc 93 27 2c 0a 20 20 27 e1 bc 9c 27 20 3d 3e 20 27 e1 bc 94 27 2c 0a 20 20 27 e1 bc | >.'...',...'...'.=>.'...',...'.. |
29620 | 9d 27 20 3d 3e 20 27 e1 bc 95 27 2c 0a 20 20 27 e1 bc a8 27 20 3d 3e 20 27 e1 bc a0 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
29640 | 20 27 e1 bc a9 27 20 3d 3e 20 27 e1 bc a1 27 2c 0a 20 20 27 e1 bc aa 27 20 3d 3e 20 27 e1 bc a2 | .'...'.=>.'...',...'...'.=>.'... |
29660 | 27 2c 0a 20 20 27 e1 bc ab 27 20 3d 3e 20 27 e1 bc a3 27 2c 0a 20 20 27 e1 bc ac 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
29680 | 27 e1 bc a4 27 2c 0a 20 20 27 e1 bc ad 27 20 3d 3e 20 27 e1 bc a5 27 2c 0a 20 20 27 e1 bc ae 27 | '...',...'...'.=>.'...',...'...' |
296a0 | 20 3d 3e 20 27 e1 bc a6 27 2c 0a 20 20 27 e1 bc af 27 20 3d 3e 20 27 e1 bc a7 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
296c0 | e1 bc b8 27 20 3d 3e 20 27 e1 bc b0 27 2c 0a 20 20 27 e1 bc b9 27 20 3d 3e 20 27 e1 bc b1 27 2c | ...'.=>.'...',...'...'.=>.'...', |
296e0 | 0a 20 20 27 e1 bc ba 27 20 3d 3e 20 27 e1 bc b2 27 2c 0a 20 20 27 e1 bc bb 27 20 3d 3e 20 27 e1 | ...'...'.=>.'...',...'...'.=>.'. |
29700 | bc b3 27 2c 0a 20 20 27 e1 bc bc 27 20 3d 3e 20 27 e1 bc b4 27 2c 0a 20 20 27 e1 bc bd 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
29720 | 3e 20 27 e1 bc b5 27 2c 0a 20 20 27 e1 bc be 27 20 3d 3e 20 27 e1 bc b6 27 2c 0a 20 20 27 e1 bc | >.'...',...'...'.=>.'...',...'.. |
29740 | bf 27 20 3d 3e 20 27 e1 bc b7 27 2c 0a 20 20 27 e1 bd 88 27 20 3d 3e 20 27 e1 bd 80 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
29760 | 20 27 e1 bd 89 27 20 3d 3e 20 27 e1 bd 81 27 2c 0a 20 20 27 e1 bd 8a 27 20 3d 3e 20 27 e1 bd 82 | .'...'.=>.'...',...'...'.=>.'... |
29780 | 27 2c 0a 20 20 27 e1 bd 8b 27 20 3d 3e 20 27 e1 bd 83 27 2c 0a 20 20 27 e1 bd 8c 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
297a0 | 27 e1 bd 84 27 2c 0a 20 20 27 e1 bd 8d 27 20 3d 3e 20 27 e1 bd 85 27 2c 0a 20 20 27 e1 bd 99 27 | '...',...'...'.=>.'...',...'...' |
297c0 | 20 3d 3e 20 27 e1 bd 91 27 2c 0a 20 20 27 e1 bd 9b 27 20 3d 3e 20 27 e1 bd 93 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
297e0 | e1 bd 9d 27 20 3d 3e 20 27 e1 bd 95 27 2c 0a 20 20 27 e1 bd 9f 27 20 3d 3e 20 27 e1 bd 97 27 2c | ...'.=>.'...',...'...'.=>.'...', |
29800 | 0a 20 20 27 e1 bd a8 27 20 3d 3e 20 27 e1 bd a0 27 2c 0a 20 20 27 e1 bd a9 27 20 3d 3e 20 27 e1 | ...'...'.=>.'...',...'...'.=>.'. |
29820 | bd a1 27 2c 0a 20 20 27 e1 bd aa 27 20 3d 3e 20 27 e1 bd a2 27 2c 0a 20 20 27 e1 bd ab 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
29840 | 3e 20 27 e1 bd a3 27 2c 0a 20 20 27 e1 bd ac 27 20 3d 3e 20 27 e1 bd a4 27 2c 0a 20 20 27 e1 bd | >.'...',...'...'.=>.'...',...'.. |
29860 | ad 27 20 3d 3e 20 27 e1 bd a5 27 2c 0a 20 20 27 e1 bd ae 27 20 3d 3e 20 27 e1 bd a6 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
29880 | 20 27 e1 bd af 27 20 3d 3e 20 27 e1 bd a7 27 2c 0a 20 20 27 e1 be 88 27 20 3d 3e 20 27 e1 be 80 | .'...'.=>.'...',...'...'.=>.'... |
298a0 | 27 2c 0a 20 20 27 e1 be 89 27 20 3d 3e 20 27 e1 be 81 27 2c 0a 20 20 27 e1 be 8a 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
298c0 | 27 e1 be 82 27 2c 0a 20 20 27 e1 be 8b 27 20 3d 3e 20 27 e1 be 83 27 2c 0a 20 20 27 e1 be 8c 27 | '...',...'...'.=>.'...',...'...' |
298e0 | 20 3d 3e 20 27 e1 be 84 27 2c 0a 20 20 27 e1 be 8d 27 20 3d 3e 20 27 e1 be 85 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
29900 | e1 be 8e 27 20 3d 3e 20 27 e1 be 86 27 2c 0a 20 20 27 e1 be 8f 27 20 3d 3e 20 27 e1 be 87 27 2c | ...'.=>.'...',...'...'.=>.'...', |
29920 | 0a 20 20 27 e1 be 98 27 20 3d 3e 20 27 e1 be 90 27 2c 0a 20 20 27 e1 be 99 27 20 3d 3e 20 27 e1 | ...'...'.=>.'...',...'...'.=>.'. |
29940 | be 91 27 2c 0a 20 20 27 e1 be 9a 27 20 3d 3e 20 27 e1 be 92 27 2c 0a 20 20 27 e1 be 9b 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
29960 | 3e 20 27 e1 be 93 27 2c 0a 20 20 27 e1 be 9c 27 20 3d 3e 20 27 e1 be 94 27 2c 0a 20 20 27 e1 be | >.'...',...'...'.=>.'...',...'.. |
29980 | 9d 27 20 3d 3e 20 27 e1 be 95 27 2c 0a 20 20 27 e1 be 9e 27 20 3d 3e 20 27 e1 be 96 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
299a0 | 20 27 e1 be 9f 27 20 3d 3e 20 27 e1 be 97 27 2c 0a 20 20 27 e1 be a8 27 20 3d 3e 20 27 e1 be a0 | .'...'.=>.'...',...'...'.=>.'... |
299c0 | 27 2c 0a 20 20 27 e1 be a9 27 20 3d 3e 20 27 e1 be a1 27 2c 0a 20 20 27 e1 be aa 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
299e0 | 27 e1 be a2 27 2c 0a 20 20 27 e1 be ab 27 20 3d 3e 20 27 e1 be a3 27 2c 0a 20 20 27 e1 be ac 27 | '...',...'...'.=>.'...',...'...' |
29a00 | 20 3d 3e 20 27 e1 be a4 27 2c 0a 20 20 27 e1 be ad 27 20 3d 3e 20 27 e1 be a5 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
29a20 | e1 be ae 27 20 3d 3e 20 27 e1 be a6 27 2c 0a 20 20 27 e1 be af 27 20 3d 3e 20 27 e1 be a7 27 2c | ...'.=>.'...',...'...'.=>.'...', |
29a40 | 0a 20 20 27 e1 be b8 27 20 3d 3e 20 27 e1 be b0 27 2c 0a 20 20 27 e1 be b9 27 20 3d 3e 20 27 e1 | ...'...'.=>.'...',...'...'.=>.'. |
29a60 | be b1 27 2c 0a 20 20 27 e1 be ba 27 20 3d 3e 20 27 e1 bd b0 27 2c 0a 20 20 27 e1 be bb 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
29a80 | 3e 20 27 e1 bd b1 27 2c 0a 20 20 27 e1 be bc 27 20 3d 3e 20 27 e1 be b3 27 2c 0a 20 20 27 e1 bf | >.'...',...'...'.=>.'...',...'.. |
29aa0 | 88 27 20 3d 3e 20 27 e1 bd b2 27 2c 0a 20 20 27 e1 bf 89 27 20 3d 3e 20 27 e1 bd b3 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
29ac0 | 20 27 e1 bf 8a 27 20 3d 3e 20 27 e1 bd b4 27 2c 0a 20 20 27 e1 bf 8b 27 20 3d 3e 20 27 e1 bd b5 | .'...'.=>.'...',...'...'.=>.'... |
29ae0 | 27 2c 0a 20 20 27 e1 bf 8c 27 20 3d 3e 20 27 e1 bf 83 27 2c 0a 20 20 27 e1 bf 98 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
29b00 | 27 e1 bf 90 27 2c 0a 20 20 27 e1 bf 99 27 20 3d 3e 20 27 e1 bf 91 27 2c 0a 20 20 27 e1 bf 9a 27 | '...',...'...'.=>.'...',...'...' |
29b20 | 20 3d 3e 20 27 e1 bd b6 27 2c 0a 20 20 27 e1 bf 9b 27 20 3d 3e 20 27 e1 bd b7 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
29b40 | e1 bf a8 27 20 3d 3e 20 27 e1 bf a0 27 2c 0a 20 20 27 e1 bf a9 27 20 3d 3e 20 27 e1 bf a1 27 2c | ...'.=>.'...',...'...'.=>.'...', |
29b60 | 0a 20 20 27 e1 bf aa 27 20 3d 3e 20 27 e1 bd ba 27 2c 0a 20 20 27 e1 bf ab 27 20 3d 3e 20 27 e1 | ...'...'.=>.'...',...'...'.=>.'. |
29b80 | bd bb 27 2c 0a 20 20 27 e1 bf ac 27 20 3d 3e 20 27 e1 bf a5 27 2c 0a 20 20 27 e1 bf b8 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
29ba0 | 3e 20 27 e1 bd b8 27 2c 0a 20 20 27 e1 bf b9 27 20 3d 3e 20 27 e1 bd b9 27 2c 0a 20 20 27 e1 bf | >.'...',...'...'.=>.'...',...'.. |
29bc0 | ba 27 20 3d 3e 20 27 e1 bd bc 27 2c 0a 20 20 27 e1 bf bb 27 20 3d 3e 20 27 e1 bd bd 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
29be0 | 20 27 e1 bf bc 27 20 3d 3e 20 27 e1 bf b3 27 2c 0a 20 20 27 e2 84 a6 27 20 3d 3e 20 27 cf 89 27 | .'...'.=>.'...',...'...'.=>.'..' |
29c00 | 2c 0a 20 20 27 e2 84 aa 27 20 3d 3e 20 27 6b 27 2c 0a 20 20 27 e2 84 ab 27 20 3d 3e 20 27 c3 a5 | ,...'...'.=>.'k',...'...'.=>.'.. |
29c20 | 27 2c 0a 20 20 27 e2 84 b2 27 20 3d 3e 20 27 e2 85 8e 27 2c 0a 20 20 27 e2 85 a0 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
29c40 | 27 e2 85 b0 27 2c 0a 20 20 27 e2 85 a1 27 20 3d 3e 20 27 e2 85 b1 27 2c 0a 20 20 27 e2 85 a2 27 | '...',...'...'.=>.'...',...'...' |
29c60 | 20 3d 3e 20 27 e2 85 b2 27 2c 0a 20 20 27 e2 85 a3 27 20 3d 3e 20 27 e2 85 b3 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
29c80 | e2 85 a4 27 20 3d 3e 20 27 e2 85 b4 27 2c 0a 20 20 27 e2 85 a5 27 20 3d 3e 20 27 e2 85 b5 27 2c | ...'.=>.'...',...'...'.=>.'...', |
29ca0 | 0a 20 20 27 e2 85 a6 27 20 3d 3e 20 27 e2 85 b6 27 2c 0a 20 20 27 e2 85 a7 27 20 3d 3e 20 27 e2 | ...'...'.=>.'...',...'...'.=>.'. |
29cc0 | 85 b7 27 2c 0a 20 20 27 e2 85 a8 27 20 3d 3e 20 27 e2 85 b8 27 2c 0a 20 20 27 e2 85 a9 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
29ce0 | 3e 20 27 e2 85 b9 27 2c 0a 20 20 27 e2 85 aa 27 20 3d 3e 20 27 e2 85 ba 27 2c 0a 20 20 27 e2 85 | >.'...',...'...'.=>.'...',...'.. |
29d00 | ab 27 20 3d 3e 20 27 e2 85 bb 27 2c 0a 20 20 27 e2 85 ac 27 20 3d 3e 20 27 e2 85 bc 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
29d20 | 20 27 e2 85 ad 27 20 3d 3e 20 27 e2 85 bd 27 2c 0a 20 20 27 e2 85 ae 27 20 3d 3e 20 27 e2 85 be | .'...'.=>.'...',...'...'.=>.'... |
29d40 | 27 2c 0a 20 20 27 e2 85 af 27 20 3d 3e 20 27 e2 85 bf 27 2c 0a 20 20 27 e2 86 83 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
29d60 | 27 e2 86 84 27 2c 0a 20 20 27 e2 92 b6 27 20 3d 3e 20 27 e2 93 90 27 2c 0a 20 20 27 e2 92 b7 27 | '...',...'...'.=>.'...',...'...' |
29d80 | 20 3d 3e 20 27 e2 93 91 27 2c 0a 20 20 27 e2 92 b8 27 20 3d 3e 20 27 e2 93 92 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
29da0 | e2 92 b9 27 20 3d 3e 20 27 e2 93 93 27 2c 0a 20 20 27 e2 92 ba 27 20 3d 3e 20 27 e2 93 94 27 2c | ...'.=>.'...',...'...'.=>.'...', |
29dc0 | 0a 20 20 27 e2 92 bb 27 20 3d 3e 20 27 e2 93 95 27 2c 0a 20 20 27 e2 92 bc 27 20 3d 3e 20 27 e2 | ...'...'.=>.'...',...'...'.=>.'. |
29de0 | 93 96 27 2c 0a 20 20 27 e2 92 bd 27 20 3d 3e 20 27 e2 93 97 27 2c 0a 20 20 27 e2 92 be 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
29e00 | 3e 20 27 e2 93 98 27 2c 0a 20 20 27 e2 92 bf 27 20 3d 3e 20 27 e2 93 99 27 2c 0a 20 20 27 e2 93 | >.'...',...'...'.=>.'...',...'.. |
29e20 | 80 27 20 3d 3e 20 27 e2 93 9a 27 2c 0a 20 20 27 e2 93 81 27 20 3d 3e 20 27 e2 93 9b 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
29e40 | 20 27 e2 93 82 27 20 3d 3e 20 27 e2 93 9c 27 2c 0a 20 20 27 e2 93 83 27 20 3d 3e 20 27 e2 93 9d | .'...'.=>.'...',...'...'.=>.'... |
29e60 | 27 2c 0a 20 20 27 e2 93 84 27 20 3d 3e 20 27 e2 93 9e 27 2c 0a 20 20 27 e2 93 85 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
29e80 | 27 e2 93 9f 27 2c 0a 20 20 27 e2 93 86 27 20 3d 3e 20 27 e2 93 a0 27 2c 0a 20 20 27 e2 93 87 27 | '...',...'...'.=>.'...',...'...' |
29ea0 | 20 3d 3e 20 27 e2 93 a1 27 2c 0a 20 20 27 e2 93 88 27 20 3d 3e 20 27 e2 93 a2 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
29ec0 | e2 93 89 27 20 3d 3e 20 27 e2 93 a3 27 2c 0a 20 20 27 e2 93 8a 27 20 3d 3e 20 27 e2 93 a4 27 2c | ...'.=>.'...',...'...'.=>.'...', |
29ee0 | 0a 20 20 27 e2 93 8b 27 20 3d 3e 20 27 e2 93 a5 27 2c 0a 20 20 27 e2 93 8c 27 20 3d 3e 20 27 e2 | ...'...'.=>.'...',...'...'.=>.'. |
29f00 | 93 a6 27 2c 0a 20 20 27 e2 93 8d 27 20 3d 3e 20 27 e2 93 a7 27 2c 0a 20 20 27 e2 93 8e 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
29f20 | 3e 20 27 e2 93 a8 27 2c 0a 20 20 27 e2 93 8f 27 20 3d 3e 20 27 e2 93 a9 27 2c 0a 20 20 27 e2 b0 | >.'...',...'...'.=>.'...',...'.. |
29f40 | 80 27 20 3d 3e 20 27 e2 b0 b0 27 2c 0a 20 20 27 e2 b0 81 27 20 3d 3e 20 27 e2 b0 b1 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
29f60 | 20 27 e2 b0 82 27 20 3d 3e 20 27 e2 b0 b2 27 2c 0a 20 20 27 e2 b0 83 27 20 3d 3e 20 27 e2 b0 b3 | .'...'.=>.'...',...'...'.=>.'... |
29f80 | 27 2c 0a 20 20 27 e2 b0 84 27 20 3d 3e 20 27 e2 b0 b4 27 2c 0a 20 20 27 e2 b0 85 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
29fa0 | 27 e2 b0 b5 27 2c 0a 20 20 27 e2 b0 86 27 20 3d 3e 20 27 e2 b0 b6 27 2c 0a 20 20 27 e2 b0 87 27 | '...',...'...'.=>.'...',...'...' |
29fc0 | 20 3d 3e 20 27 e2 b0 b7 27 2c 0a 20 20 27 e2 b0 88 27 20 3d 3e 20 27 e2 b0 b8 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
29fe0 | e2 b0 89 27 20 3d 3e 20 27 e2 b0 b9 27 2c 0a 20 20 27 e2 b0 8a 27 20 3d 3e 20 27 e2 b0 ba 27 2c | ...'.=>.'...',...'...'.=>.'...', |
2a000 | 0a 20 20 27 e2 b0 8b 27 20 3d 3e 20 27 e2 b0 bb 27 2c 0a 20 20 27 e2 b0 8c 27 20 3d 3e 20 27 e2 | ...'...'.=>.'...',...'...'.=>.'. |
2a020 | b0 bc 27 2c 0a 20 20 27 e2 b0 8d 27 20 3d 3e 20 27 e2 b0 bd 27 2c 0a 20 20 27 e2 b0 8e 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
2a040 | 3e 20 27 e2 b0 be 27 2c 0a 20 20 27 e2 b0 8f 27 20 3d 3e 20 27 e2 b0 bf 27 2c 0a 20 20 27 e2 b0 | >.'...',...'...'.=>.'...',...'.. |
2a060 | 90 27 20 3d 3e 20 27 e2 b1 80 27 2c 0a 20 20 27 e2 b0 91 27 20 3d 3e 20 27 e2 b1 81 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
2a080 | 20 27 e2 b0 92 27 20 3d 3e 20 27 e2 b1 82 27 2c 0a 20 20 27 e2 b0 93 27 20 3d 3e 20 27 e2 b1 83 | .'...'.=>.'...',...'...'.=>.'... |
2a0a0 | 27 2c 0a 20 20 27 e2 b0 94 27 20 3d 3e 20 27 e2 b1 84 27 2c 0a 20 20 27 e2 b0 95 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
2a0c0 | 27 e2 b1 85 27 2c 0a 20 20 27 e2 b0 96 27 20 3d 3e 20 27 e2 b1 86 27 2c 0a 20 20 27 e2 b0 97 27 | '...',...'...'.=>.'...',...'...' |
2a0e0 | 20 3d 3e 20 27 e2 b1 87 27 2c 0a 20 20 27 e2 b0 98 27 20 3d 3e 20 27 e2 b1 88 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
2a100 | e2 b0 99 27 20 3d 3e 20 27 e2 b1 89 27 2c 0a 20 20 27 e2 b0 9a 27 20 3d 3e 20 27 e2 b1 8a 27 2c | ...'.=>.'...',...'...'.=>.'...', |
2a120 | 0a 20 20 27 e2 b0 9b 27 20 3d 3e 20 27 e2 b1 8b 27 2c 0a 20 20 27 e2 b0 9c 27 20 3d 3e 20 27 e2 | ...'...'.=>.'...',...'...'.=>.'. |
2a140 | b1 8c 27 2c 0a 20 20 27 e2 b0 9d 27 20 3d 3e 20 27 e2 b1 8d 27 2c 0a 20 20 27 e2 b0 9e 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
2a160 | 3e 20 27 e2 b1 8e 27 2c 0a 20 20 27 e2 b0 9f 27 20 3d 3e 20 27 e2 b1 8f 27 2c 0a 20 20 27 e2 b0 | >.'...',...'...'.=>.'...',...'.. |
2a180 | a0 27 20 3d 3e 20 27 e2 b1 90 27 2c 0a 20 20 27 e2 b0 a1 27 20 3d 3e 20 27 e2 b1 91 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
2a1a0 | 20 27 e2 b0 a2 27 20 3d 3e 20 27 e2 b1 92 27 2c 0a 20 20 27 e2 b0 a3 27 20 3d 3e 20 27 e2 b1 93 | .'...'.=>.'...',...'...'.=>.'... |
2a1c0 | 27 2c 0a 20 20 27 e2 b0 a4 27 20 3d 3e 20 27 e2 b1 94 27 2c 0a 20 20 27 e2 b0 a5 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
2a1e0 | 27 e2 b1 95 27 2c 0a 20 20 27 e2 b0 a6 27 20 3d 3e 20 27 e2 b1 96 27 2c 0a 20 20 27 e2 b0 a7 27 | '...',...'...'.=>.'...',...'...' |
2a200 | 20 3d 3e 20 27 e2 b1 97 27 2c 0a 20 20 27 e2 b0 a8 27 20 3d 3e 20 27 e2 b1 98 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
2a220 | e2 b0 a9 27 20 3d 3e 20 27 e2 b1 99 27 2c 0a 20 20 27 e2 b0 aa 27 20 3d 3e 20 27 e2 b1 9a 27 2c | ...'.=>.'...',...'...'.=>.'...', |
2a240 | 0a 20 20 27 e2 b0 ab 27 20 3d 3e 20 27 e2 b1 9b 27 2c 0a 20 20 27 e2 b0 ac 27 20 3d 3e 20 27 e2 | ...'...'.=>.'...',...'...'.=>.'. |
2a260 | b1 9c 27 2c 0a 20 20 27 e2 b0 ad 27 20 3d 3e 20 27 e2 b1 9d 27 2c 0a 20 20 27 e2 b0 ae 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
2a280 | 3e 20 27 e2 b1 9e 27 2c 0a 20 20 27 e2 b1 a0 27 20 3d 3e 20 27 e2 b1 a1 27 2c 0a 20 20 27 e2 b1 | >.'...',...'...'.=>.'...',...'.. |
2a2a0 | a2 27 20 3d 3e 20 27 c9 ab 27 2c 0a 20 20 27 e2 b1 a3 27 20 3d 3e 20 27 e1 b5 bd 27 2c 0a 20 20 | .'.=>.'..',...'...'.=>.'...',... |
2a2c0 | 27 e2 b1 a4 27 20 3d 3e 20 27 c9 bd 27 2c 0a 20 20 27 e2 b1 a7 27 20 3d 3e 20 27 e2 b1 a8 27 2c | '...'.=>.'..',...'...'.=>.'...', |
2a2e0 | 0a 20 20 27 e2 b1 a9 27 20 3d 3e 20 27 e2 b1 aa 27 2c 0a 20 20 27 e2 b1 ab 27 20 3d 3e 20 27 e2 | ...'...'.=>.'...',...'...'.=>.'. |
2a300 | b1 ac 27 2c 0a 20 20 27 e2 b1 ad 27 20 3d 3e 20 27 c9 91 27 2c 0a 20 20 27 e2 b1 ae 27 20 3d 3e | ..',...'...'.=>.'..',...'...'.=> |
2a320 | 20 27 c9 b1 27 2c 0a 20 20 27 e2 b1 af 27 20 3d 3e 20 27 c9 90 27 2c 0a 20 20 27 e2 b1 b0 27 20 | .'..',...'...'.=>.'..',...'...'. |
2a340 | 3d 3e 20 27 c9 92 27 2c 0a 20 20 27 e2 b1 b2 27 20 3d 3e 20 27 e2 b1 b3 27 2c 0a 20 20 27 e2 b1 | =>.'..',...'...'.=>.'...',...'.. |
2a360 | b5 27 20 3d 3e 20 27 e2 b1 b6 27 2c 0a 20 20 27 e2 b1 be 27 20 3d 3e 20 27 c8 bf 27 2c 0a 20 20 | .'.=>.'...',...'...'.=>.'..',... |
2a380 | 27 e2 b1 bf 27 20 3d 3e 20 27 c9 80 27 2c 0a 20 20 27 e2 b2 80 27 20 3d 3e 20 27 e2 b2 81 27 2c | '...'.=>.'..',...'...'.=>.'...', |
2a3a0 | 0a 20 20 27 e2 b2 82 27 20 3d 3e 20 27 e2 b2 83 27 2c 0a 20 20 27 e2 b2 84 27 20 3d 3e 20 27 e2 | ...'...'.=>.'...',...'...'.=>.'. |
2a3c0 | b2 85 27 2c 0a 20 20 27 e2 b2 86 27 20 3d 3e 20 27 e2 b2 87 27 2c 0a 20 20 27 e2 b2 88 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
2a3e0 | 3e 20 27 e2 b2 89 27 2c 0a 20 20 27 e2 b2 8a 27 20 3d 3e 20 27 e2 b2 8b 27 2c 0a 20 20 27 e2 b2 | >.'...',...'...'.=>.'...',...'.. |
2a400 | 8c 27 20 3d 3e 20 27 e2 b2 8d 27 2c 0a 20 20 27 e2 b2 8e 27 20 3d 3e 20 27 e2 b2 8f 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
2a420 | 20 27 e2 b2 90 27 20 3d 3e 20 27 e2 b2 91 27 2c 0a 20 20 27 e2 b2 92 27 20 3d 3e 20 27 e2 b2 93 | .'...'.=>.'...',...'...'.=>.'... |
2a440 | 27 2c 0a 20 20 27 e2 b2 94 27 20 3d 3e 20 27 e2 b2 95 27 2c 0a 20 20 27 e2 b2 96 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
2a460 | 27 e2 b2 97 27 2c 0a 20 20 27 e2 b2 98 27 20 3d 3e 20 27 e2 b2 99 27 2c 0a 20 20 27 e2 b2 9a 27 | '...',...'...'.=>.'...',...'...' |
2a480 | 20 3d 3e 20 27 e2 b2 9b 27 2c 0a 20 20 27 e2 b2 9c 27 20 3d 3e 20 27 e2 b2 9d 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
2a4a0 | e2 b2 9e 27 20 3d 3e 20 27 e2 b2 9f 27 2c 0a 20 20 27 e2 b2 a0 27 20 3d 3e 20 27 e2 b2 a1 27 2c | ...'.=>.'...',...'...'.=>.'...', |
2a4c0 | 0a 20 20 27 e2 b2 a2 27 20 3d 3e 20 27 e2 b2 a3 27 2c 0a 20 20 27 e2 b2 a4 27 20 3d 3e 20 27 e2 | ...'...'.=>.'...',...'...'.=>.'. |
2a4e0 | b2 a5 27 2c 0a 20 20 27 e2 b2 a6 27 20 3d 3e 20 27 e2 b2 a7 27 2c 0a 20 20 27 e2 b2 a8 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
2a500 | 3e 20 27 e2 b2 a9 27 2c 0a 20 20 27 e2 b2 aa 27 20 3d 3e 20 27 e2 b2 ab 27 2c 0a 20 20 27 e2 b2 | >.'...',...'...'.=>.'...',...'.. |
2a520 | ac 27 20 3d 3e 20 27 e2 b2 ad 27 2c 0a 20 20 27 e2 b2 ae 27 20 3d 3e 20 27 e2 b2 af 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
2a540 | 20 27 e2 b2 b0 27 20 3d 3e 20 27 e2 b2 b1 27 2c 0a 20 20 27 e2 b2 b2 27 20 3d 3e 20 27 e2 b2 b3 | .'...'.=>.'...',...'...'.=>.'... |
2a560 | 27 2c 0a 20 20 27 e2 b2 b4 27 20 3d 3e 20 27 e2 b2 b5 27 2c 0a 20 20 27 e2 b2 b6 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
2a580 | 27 e2 b2 b7 27 2c 0a 20 20 27 e2 b2 b8 27 20 3d 3e 20 27 e2 b2 b9 27 2c 0a 20 20 27 e2 b2 ba 27 | '...',...'...'.=>.'...',...'...' |
2a5a0 | 20 3d 3e 20 27 e2 b2 bb 27 2c 0a 20 20 27 e2 b2 bc 27 20 3d 3e 20 27 e2 b2 bd 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
2a5c0 | e2 b2 be 27 20 3d 3e 20 27 e2 b2 bf 27 2c 0a 20 20 27 e2 b3 80 27 20 3d 3e 20 27 e2 b3 81 27 2c | ...'.=>.'...',...'...'.=>.'...', |
2a5e0 | 0a 20 20 27 e2 b3 82 27 20 3d 3e 20 27 e2 b3 83 27 2c 0a 20 20 27 e2 b3 84 27 20 3d 3e 20 27 e2 | ...'...'.=>.'...',...'...'.=>.'. |
2a600 | b3 85 27 2c 0a 20 20 27 e2 b3 86 27 20 3d 3e 20 27 e2 b3 87 27 2c 0a 20 20 27 e2 b3 88 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
2a620 | 3e 20 27 e2 b3 89 27 2c 0a 20 20 27 e2 b3 8a 27 20 3d 3e 20 27 e2 b3 8b 27 2c 0a 20 20 27 e2 b3 | >.'...',...'...'.=>.'...',...'.. |
2a640 | 8c 27 20 3d 3e 20 27 e2 b3 8d 27 2c 0a 20 20 27 e2 b3 8e 27 20 3d 3e 20 27 e2 b3 8f 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
2a660 | 20 27 e2 b3 90 27 20 3d 3e 20 27 e2 b3 91 27 2c 0a 20 20 27 e2 b3 92 27 20 3d 3e 20 27 e2 b3 93 | .'...'.=>.'...',...'...'.=>.'... |
2a680 | 27 2c 0a 20 20 27 e2 b3 94 27 20 3d 3e 20 27 e2 b3 95 27 2c 0a 20 20 27 e2 b3 96 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
2a6a0 | 27 e2 b3 97 27 2c 0a 20 20 27 e2 b3 98 27 20 3d 3e 20 27 e2 b3 99 27 2c 0a 20 20 27 e2 b3 9a 27 | '...',...'...'.=>.'...',...'...' |
2a6c0 | 20 3d 3e 20 27 e2 b3 9b 27 2c 0a 20 20 27 e2 b3 9c 27 20 3d 3e 20 27 e2 b3 9d 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
2a6e0 | e2 b3 9e 27 20 3d 3e 20 27 e2 b3 9f 27 2c 0a 20 20 27 e2 b3 a0 27 20 3d 3e 20 27 e2 b3 a1 27 2c | ...'.=>.'...',...'...'.=>.'...', |
2a700 | 0a 20 20 27 e2 b3 a2 27 20 3d 3e 20 27 e2 b3 a3 27 2c 0a 20 20 27 e2 b3 ab 27 20 3d 3e 20 27 e2 | ...'...'.=>.'...',...'...'.=>.'. |
2a720 | b3 ac 27 2c 0a 20 20 27 e2 b3 ad 27 20 3d 3e 20 27 e2 b3 ae 27 2c 0a 20 20 27 e2 b3 b2 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
2a740 | 3e 20 27 e2 b3 b3 27 2c 0a 20 20 27 ea 99 80 27 20 3d 3e 20 27 ea 99 81 27 2c 0a 20 20 27 ea 99 | >.'...',...'...'.=>.'...',...'.. |
2a760 | 82 27 20 3d 3e 20 27 ea 99 83 27 2c 0a 20 20 27 ea 99 84 27 20 3d 3e 20 27 ea 99 85 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
2a780 | 20 27 ea 99 86 27 20 3d 3e 20 27 ea 99 87 27 2c 0a 20 20 27 ea 99 88 27 20 3d 3e 20 27 ea 99 89 | .'...'.=>.'...',...'...'.=>.'... |
2a7a0 | 27 2c 0a 20 20 27 ea 99 8a 27 20 3d 3e 20 27 ea 99 8b 27 2c 0a 20 20 27 ea 99 8c 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
2a7c0 | 27 ea 99 8d 27 2c 0a 20 20 27 ea 99 8e 27 20 3d 3e 20 27 ea 99 8f 27 2c 0a 20 20 27 ea 99 90 27 | '...',...'...'.=>.'...',...'...' |
2a7e0 | 20 3d 3e 20 27 ea 99 91 27 2c 0a 20 20 27 ea 99 92 27 20 3d 3e 20 27 ea 99 93 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
2a800 | ea 99 94 27 20 3d 3e 20 27 ea 99 95 27 2c 0a 20 20 27 ea 99 96 27 20 3d 3e 20 27 ea 99 97 27 2c | ...'.=>.'...',...'...'.=>.'...', |
2a820 | 0a 20 20 27 ea 99 98 27 20 3d 3e 20 27 ea 99 99 27 2c 0a 20 20 27 ea 99 9a 27 20 3d 3e 20 27 ea | ...'...'.=>.'...',...'...'.=>.'. |
2a840 | 99 9b 27 2c 0a 20 20 27 ea 99 9c 27 20 3d 3e 20 27 ea 99 9d 27 2c 0a 20 20 27 ea 99 9e 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
2a860 | 3e 20 27 ea 99 9f 27 2c 0a 20 20 27 ea 99 a0 27 20 3d 3e 20 27 ea 99 a1 27 2c 0a 20 20 27 ea 99 | >.'...',...'...'.=>.'...',...'.. |
2a880 | a2 27 20 3d 3e 20 27 ea 99 a3 27 2c 0a 20 20 27 ea 99 a4 27 20 3d 3e 20 27 ea 99 a5 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
2a8a0 | 20 27 ea 99 a6 27 20 3d 3e 20 27 ea 99 a7 27 2c 0a 20 20 27 ea 99 a8 27 20 3d 3e 20 27 ea 99 a9 | .'...'.=>.'...',...'...'.=>.'... |
2a8c0 | 27 2c 0a 20 20 27 ea 99 aa 27 20 3d 3e 20 27 ea 99 ab 27 2c 0a 20 20 27 ea 99 ac 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
2a8e0 | 27 ea 99 ad 27 2c 0a 20 20 27 ea 9a 80 27 20 3d 3e 20 27 ea 9a 81 27 2c 0a 20 20 27 ea 9a 82 27 | '...',...'...'.=>.'...',...'...' |
2a900 | 20 3d 3e 20 27 ea 9a 83 27 2c 0a 20 20 27 ea 9a 84 27 20 3d 3e 20 27 ea 9a 85 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
2a920 | ea 9a 86 27 20 3d 3e 20 27 ea 9a 87 27 2c 0a 20 20 27 ea 9a 88 27 20 3d 3e 20 27 ea 9a 89 27 2c | ...'.=>.'...',...'...'.=>.'...', |
2a940 | 0a 20 20 27 ea 9a 8a 27 20 3d 3e 20 27 ea 9a 8b 27 2c 0a 20 20 27 ea 9a 8c 27 20 3d 3e 20 27 ea | ...'...'.=>.'...',...'...'.=>.'. |
2a960 | 9a 8d 27 2c 0a 20 20 27 ea 9a 8e 27 20 3d 3e 20 27 ea 9a 8f 27 2c 0a 20 20 27 ea 9a 90 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
2a980 | 3e 20 27 ea 9a 91 27 2c 0a 20 20 27 ea 9a 92 27 20 3d 3e 20 27 ea 9a 93 27 2c 0a 20 20 27 ea 9a | >.'...',...'...'.=>.'...',...'.. |
2a9a0 | 94 27 20 3d 3e 20 27 ea 9a 95 27 2c 0a 20 20 27 ea 9a 96 27 20 3d 3e 20 27 ea 9a 97 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
2a9c0 | 20 27 ea 9a 98 27 20 3d 3e 20 27 ea 9a 99 27 2c 0a 20 20 27 ea 9a 9a 27 20 3d 3e 20 27 ea 9a 9b | .'...'.=>.'...',...'...'.=>.'... |
2a9e0 | 27 2c 0a 20 20 27 ea 9c a2 27 20 3d 3e 20 27 ea 9c a3 27 2c 0a 20 20 27 ea 9c a4 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
2aa00 | 27 ea 9c a5 27 2c 0a 20 20 27 ea 9c a6 27 20 3d 3e 20 27 ea 9c a7 27 2c 0a 20 20 27 ea 9c a8 27 | '...',...'...'.=>.'...',...'...' |
2aa20 | 20 3d 3e 20 27 ea 9c a9 27 2c 0a 20 20 27 ea 9c aa 27 20 3d 3e 20 27 ea 9c ab 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
2aa40 | ea 9c ac 27 20 3d 3e 20 27 ea 9c ad 27 2c 0a 20 20 27 ea 9c ae 27 20 3d 3e 20 27 ea 9c af 27 2c | ...'.=>.'...',...'...'.=>.'...', |
2aa60 | 0a 20 20 27 ea 9c b2 27 20 3d 3e 20 27 ea 9c b3 27 2c 0a 20 20 27 ea 9c b4 27 20 3d 3e 20 27 ea | ...'...'.=>.'...',...'...'.=>.'. |
2aa80 | 9c b5 27 2c 0a 20 20 27 ea 9c b6 27 20 3d 3e 20 27 ea 9c b7 27 2c 0a 20 20 27 ea 9c b8 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
2aaa0 | 3e 20 27 ea 9c b9 27 2c 0a 20 20 27 ea 9c ba 27 20 3d 3e 20 27 ea 9c bb 27 2c 0a 20 20 27 ea 9c | >.'...',...'...'.=>.'...',...'.. |
2aac0 | bc 27 20 3d 3e 20 27 ea 9c bd 27 2c 0a 20 20 27 ea 9c be 27 20 3d 3e 20 27 ea 9c bf 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
2aae0 | 20 27 ea 9d 80 27 20 3d 3e 20 27 ea 9d 81 27 2c 0a 20 20 27 ea 9d 82 27 20 3d 3e 20 27 ea 9d 83 | .'...'.=>.'...',...'...'.=>.'... |
2ab00 | 27 2c 0a 20 20 27 ea 9d 84 27 20 3d 3e 20 27 ea 9d 85 27 2c 0a 20 20 27 ea 9d 86 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
2ab20 | 27 ea 9d 87 27 2c 0a 20 20 27 ea 9d 88 27 20 3d 3e 20 27 ea 9d 89 27 2c 0a 20 20 27 ea 9d 8a 27 | '...',...'...'.=>.'...',...'...' |
2ab40 | 20 3d 3e 20 27 ea 9d 8b 27 2c 0a 20 20 27 ea 9d 8c 27 20 3d 3e 20 27 ea 9d 8d 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
2ab60 | ea 9d 8e 27 20 3d 3e 20 27 ea 9d 8f 27 2c 0a 20 20 27 ea 9d 90 27 20 3d 3e 20 27 ea 9d 91 27 2c | ...'.=>.'...',...'...'.=>.'...', |
2ab80 | 0a 20 20 27 ea 9d 92 27 20 3d 3e 20 27 ea 9d 93 27 2c 0a 20 20 27 ea 9d 94 27 20 3d 3e 20 27 ea | ...'...'.=>.'...',...'...'.=>.'. |
2aba0 | 9d 95 27 2c 0a 20 20 27 ea 9d 96 27 20 3d 3e 20 27 ea 9d 97 27 2c 0a 20 20 27 ea 9d 98 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
2abc0 | 3e 20 27 ea 9d 99 27 2c 0a 20 20 27 ea 9d 9a 27 20 3d 3e 20 27 ea 9d 9b 27 2c 0a 20 20 27 ea 9d | >.'...',...'...'.=>.'...',...'.. |
2abe0 | 9c 27 20 3d 3e 20 27 ea 9d 9d 27 2c 0a 20 20 27 ea 9d 9e 27 20 3d 3e 20 27 ea 9d 9f 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
2ac00 | 20 27 ea 9d a0 27 20 3d 3e 20 27 ea 9d a1 27 2c 0a 20 20 27 ea 9d a2 27 20 3d 3e 20 27 ea 9d a3 | .'...'.=>.'...',...'...'.=>.'... |
2ac20 | 27 2c 0a 20 20 27 ea 9d a4 27 20 3d 3e 20 27 ea 9d a5 27 2c 0a 20 20 27 ea 9d a6 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
2ac40 | 27 ea 9d a7 27 2c 0a 20 20 27 ea 9d a8 27 20 3d 3e 20 27 ea 9d a9 27 2c 0a 20 20 27 ea 9d aa 27 | '...',...'...'.=>.'...',...'...' |
2ac60 | 20 3d 3e 20 27 ea 9d ab 27 2c 0a 20 20 27 ea 9d ac 27 20 3d 3e 20 27 ea 9d ad 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
2ac80 | ea 9d ae 27 20 3d 3e 20 27 ea 9d af 27 2c 0a 20 20 27 ea 9d b9 27 20 3d 3e 20 27 ea 9d ba 27 2c | ...'.=>.'...',...'...'.=>.'...', |
2aca0 | 0a 20 20 27 ea 9d bb 27 20 3d 3e 20 27 ea 9d bc 27 2c 0a 20 20 27 ea 9d bd 27 20 3d 3e 20 27 e1 | ...'...'.=>.'...',...'...'.=>.'. |
2acc0 | b5 b9 27 2c 0a 20 20 27 ea 9d be 27 20 3d 3e 20 27 ea 9d bf 27 2c 0a 20 20 27 ea 9e 80 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
2ace0 | 3e 20 27 ea 9e 81 27 2c 0a 20 20 27 ea 9e 82 27 20 3d 3e 20 27 ea 9e 83 27 2c 0a 20 20 27 ea 9e | >.'...',...'...'.=>.'...',...'.. |
2ad00 | 84 27 20 3d 3e 20 27 ea 9e 85 27 2c 0a 20 20 27 ea 9e 86 27 20 3d 3e 20 27 ea 9e 87 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
2ad20 | 20 27 ea 9e 8b 27 20 3d 3e 20 27 ea 9e 8c 27 2c 0a 20 20 27 ea 9e 8d 27 20 3d 3e 20 27 c9 a5 27 | .'...'.=>.'...',...'...'.=>.'..' |
2ad40 | 2c 0a 20 20 27 ea 9e 90 27 20 3d 3e 20 27 ea 9e 91 27 2c 0a 20 20 27 ea 9e 92 27 20 3d 3e 20 27 | ,...'...'.=>.'...',...'...'.=>.' |
2ad60 | ea 9e 93 27 2c 0a 20 20 27 ea 9e 96 27 20 3d 3e 20 27 ea 9e 97 27 2c 0a 20 20 27 ea 9e 98 27 20 | ...',...'...'.=>.'...',...'...'. |
2ad80 | 3d 3e 20 27 ea 9e 99 27 2c 0a 20 20 27 ea 9e 9a 27 20 3d 3e 20 27 ea 9e 9b 27 2c 0a 20 20 27 ea | =>.'...',...'...'.=>.'...',...'. |
2ada0 | 9e 9c 27 20 3d 3e 20 27 ea 9e 9d 27 2c 0a 20 20 27 ea 9e 9e 27 20 3d 3e 20 27 ea 9e 9f 27 2c 0a | ..'.=>.'...',...'...'.=>.'...',. |
2adc0 | 20 20 27 ea 9e a0 27 20 3d 3e 20 27 ea 9e a1 27 2c 0a 20 20 27 ea 9e a2 27 20 3d 3e 20 27 ea 9e | ..'...'.=>.'...',...'...'.=>.'.. |
2ade0 | a3 27 2c 0a 20 20 27 ea 9e a4 27 20 3d 3e 20 27 ea 9e a5 27 2c 0a 20 20 27 ea 9e a6 27 20 3d 3e | .',...'...'.=>.'...',...'...'.=> |
2ae00 | 20 27 ea 9e a7 27 2c 0a 20 20 27 ea 9e a8 27 20 3d 3e 20 27 ea 9e a9 27 2c 0a 20 20 27 ea 9e aa | .'...',...'...'.=>.'...',...'... |
2ae20 | 27 20 3d 3e 20 27 c9 a6 27 2c 0a 20 20 27 ea 9e ab 27 20 3d 3e 20 27 c9 9c 27 2c 0a 20 20 27 ea | '.=>.'..',...'...'.=>.'..',...'. |
2ae40 | 9e ac 27 20 3d 3e 20 27 c9 a1 27 2c 0a 20 20 27 ea 9e ad 27 20 3d 3e 20 27 c9 ac 27 2c 0a 20 20 | ..'.=>.'..',...'...'.=>.'..',... |
2ae60 | 27 ea 9e b0 27 20 3d 3e 20 27 ca 9e 27 2c 0a 20 20 27 ea 9e b1 27 20 3d 3e 20 27 ca 87 27 2c 0a | '...'.=>.'..',...'...'.=>.'..',. |
2ae80 | 20 20 27 ef bc a1 27 20 3d 3e 20 27 ef bd 81 27 2c 0a 20 20 27 ef bc a2 27 20 3d 3e 20 27 ef bd | ..'...'.=>.'...',...'...'.=>.'.. |
2aea0 | 82 27 2c 0a 20 20 27 ef bc a3 27 20 3d 3e 20 27 ef bd 83 27 2c 0a 20 20 27 ef bc a4 27 20 3d 3e | .',...'...'.=>.'...',...'...'.=> |
2aec0 | 20 27 ef bd 84 27 2c 0a 20 20 27 ef bc a5 27 20 3d 3e 20 27 ef bd 85 27 2c 0a 20 20 27 ef bc a6 | .'...',...'...'.=>.'...',...'... |
2aee0 | 27 20 3d 3e 20 27 ef bd 86 27 2c 0a 20 20 27 ef bc a7 27 20 3d 3e 20 27 ef bd 87 27 2c 0a 20 20 | '.=>.'...',...'...'.=>.'...',... |
2af00 | 27 ef bc a8 27 20 3d 3e 20 27 ef bd 88 27 2c 0a 20 20 27 ef bc a9 27 20 3d 3e 20 27 ef bd 89 27 | '...'.=>.'...',...'...'.=>.'...' |
2af20 | 2c 0a 20 20 27 ef bc aa 27 20 3d 3e 20 27 ef bd 8a 27 2c 0a 20 20 27 ef bc ab 27 20 3d 3e 20 27 | ,...'...'.=>.'...',...'...'.=>.' |
2af40 | ef bd 8b 27 2c 0a 20 20 27 ef bc ac 27 20 3d 3e 20 27 ef bd 8c 27 2c 0a 20 20 27 ef bc ad 27 20 | ...',...'...'.=>.'...',...'...'. |
2af60 | 3d 3e 20 27 ef bd 8d 27 2c 0a 20 20 27 ef bc ae 27 20 3d 3e 20 27 ef bd 8e 27 2c 0a 20 20 27 ef | =>.'...',...'...'.=>.'...',...'. |
2af80 | bc af 27 20 3d 3e 20 27 ef bd 8f 27 2c 0a 20 20 27 ef bc b0 27 20 3d 3e 20 27 ef bd 90 27 2c 0a | ..'.=>.'...',...'...'.=>.'...',. |
2afa0 | 20 20 27 ef bc b1 27 20 3d 3e 20 27 ef bd 91 27 2c 0a 20 20 27 ef bc b2 27 20 3d 3e 20 27 ef bd | ..'...'.=>.'...',...'...'.=>.'.. |
2afc0 | 92 27 2c 0a 20 20 27 ef bc b3 27 20 3d 3e 20 27 ef bd 93 27 2c 0a 20 20 27 ef bc b4 27 20 3d 3e | .',...'...'.=>.'...',...'...'.=> |
2afe0 | 20 27 ef bd 94 27 2c 0a 20 20 27 ef bc b5 27 20 3d 3e 20 27 ef bd 95 27 2c 0a 20 20 27 ef bc b6 | .'...',...'...'.=>.'...',...'... |
2b000 | 27 20 3d 3e 20 27 ef bd 96 27 2c 0a 20 20 27 ef bc b7 27 20 3d 3e 20 27 ef bd 97 27 2c 0a 20 20 | '.=>.'...',...'...'.=>.'...',... |
2b020 | 27 ef bc b8 27 20 3d 3e 20 27 ef bd 98 27 2c 0a 20 20 27 ef bc b9 27 20 3d 3e 20 27 ef bd 99 27 | '...'.=>.'...',...'...'.=>.'...' |
2b040 | 2c 0a 20 20 27 ef bc ba 27 20 3d 3e 20 27 ef bd 9a 27 2c 0a 20 20 27 f0 90 90 80 27 20 3d 3e 20 | ,...'...'.=>.'...',...'....'.=>. |
2b060 | 27 f0 90 90 a8 27 2c 0a 20 20 27 f0 90 90 81 27 20 3d 3e 20 27 f0 90 90 a9 27 2c 0a 20 20 27 f0 | '....',...'....'.=>.'....',...'. |
2b080 | 90 90 82 27 20 3d 3e 20 27 f0 90 90 aa 27 2c 0a 20 20 27 f0 90 90 83 27 20 3d 3e 20 27 f0 90 90 | ...'.=>.'....',...'....'.=>.'... |
2b0a0 | ab 27 2c 0a 20 20 27 f0 90 90 84 27 20 3d 3e 20 27 f0 90 90 ac 27 2c 0a 20 20 27 f0 90 90 85 27 | .',...'....'.=>.'....',...'....' |
2b0c0 | 20 3d 3e 20 27 f0 90 90 ad 27 2c 0a 20 20 27 f0 90 90 86 27 20 3d 3e 20 27 f0 90 90 ae 27 2c 0a | .=>.'....',...'....'.=>.'....',. |
2b0e0 | 20 20 27 f0 90 90 87 27 20 3d 3e 20 27 f0 90 90 af 27 2c 0a 20 20 27 f0 90 90 88 27 20 3d 3e 20 | ..'....'.=>.'....',...'....'.=>. |
2b100 | 27 f0 90 90 b0 27 2c 0a 20 20 27 f0 90 90 89 27 20 3d 3e 20 27 f0 90 90 b1 27 2c 0a 20 20 27 f0 | '....',...'....'.=>.'....',...'. |
2b120 | 90 90 8a 27 20 3d 3e 20 27 f0 90 90 b2 27 2c 0a 20 20 27 f0 90 90 8b 27 20 3d 3e 20 27 f0 90 90 | ...'.=>.'....',...'....'.=>.'... |
2b140 | b3 27 2c 0a 20 20 27 f0 90 90 8c 27 20 3d 3e 20 27 f0 90 90 b4 27 2c 0a 20 20 27 f0 90 90 8d 27 | .',...'....'.=>.'....',...'....' |
2b160 | 20 3d 3e 20 27 f0 90 90 b5 27 2c 0a 20 20 27 f0 90 90 8e 27 20 3d 3e 20 27 f0 90 90 b6 27 2c 0a | .=>.'....',...'....'.=>.'....',. |
2b180 | 20 20 27 f0 90 90 8f 27 20 3d 3e 20 27 f0 90 90 b7 27 2c 0a 20 20 27 f0 90 90 90 27 20 3d 3e 20 | ..'....'.=>.'....',...'....'.=>. |
2b1a0 | 27 f0 90 90 b8 27 2c 0a 20 20 27 f0 90 90 91 27 20 3d 3e 20 27 f0 90 90 b9 27 2c 0a 20 20 27 f0 | '....',...'....'.=>.'....',...'. |
2b1c0 | 90 90 92 27 20 3d 3e 20 27 f0 90 90 ba 27 2c 0a 20 20 27 f0 90 90 93 27 20 3d 3e 20 27 f0 90 90 | ...'.=>.'....',...'....'.=>.'... |
2b1e0 | bb 27 2c 0a 20 20 27 f0 90 90 94 27 20 3d 3e 20 27 f0 90 90 bc 27 2c 0a 20 20 27 f0 90 90 95 27 | .',...'....'.=>.'....',...'....' |
2b200 | 20 3d 3e 20 27 f0 90 90 bd 27 2c 0a 20 20 27 f0 90 90 96 27 20 3d 3e 20 27 f0 90 90 be 27 2c 0a | .=>.'....',...'....'.=>.'....',. |
2b220 | 20 20 27 f0 90 90 97 27 20 3d 3e 20 27 f0 90 90 bf 27 2c 0a 20 20 27 f0 90 90 98 27 20 3d 3e 20 | ..'....'.=>.'....',...'....'.=>. |
2b240 | 27 f0 90 91 80 27 2c 0a 20 20 27 f0 90 90 99 27 20 3d 3e 20 27 f0 90 91 81 27 2c 0a 20 20 27 f0 | '....',...'....'.=>.'....',...'. |
2b260 | 90 90 9a 27 20 3d 3e 20 27 f0 90 91 82 27 2c 0a 20 20 27 f0 90 90 9b 27 20 3d 3e 20 27 f0 90 91 | ...'.=>.'....',...'....'.=>.'... |
2b280 | 83 27 2c 0a 20 20 27 f0 90 90 9c 27 20 3d 3e 20 27 f0 90 91 84 27 2c 0a 20 20 27 f0 90 90 9d 27 | .',...'....'.=>.'....',...'....' |
2b2a0 | 20 3d 3e 20 27 f0 90 91 85 27 2c 0a 20 20 27 f0 90 90 9e 27 20 3d 3e 20 27 f0 90 91 86 27 2c 0a | .=>.'....',...'....'.=>.'....',. |
2b2c0 | 20 20 27 f0 90 90 9f 27 20 3d 3e 20 27 f0 90 91 87 27 2c 0a 20 20 27 f0 90 90 a0 27 20 3d 3e 20 | ..'....'.=>.'....',...'....'.=>. |
2b2e0 | 27 f0 90 91 88 27 2c 0a 20 20 27 f0 90 90 a1 27 20 3d 3e 20 27 f0 90 91 89 27 2c 0a 20 20 27 f0 | '....',...'....'.=>.'....',...'. |
2b300 | 90 90 a2 27 20 3d 3e 20 27 f0 90 91 8a 27 2c 0a 20 20 27 f0 90 90 a3 27 20 3d 3e 20 27 f0 90 91 | ...'.=>.'....',...'....'.=>.'... |
2b320 | 8b 27 2c 0a 20 20 27 f0 90 90 a4 27 20 3d 3e 20 27 f0 90 91 8c 27 2c 0a 20 20 27 f0 90 90 a5 27 | .',...'....'.=>.'....',...'....' |
2b340 | 20 3d 3e 20 27 f0 90 91 8d 27 2c 0a 20 20 27 f0 90 90 a6 27 20 3d 3e 20 27 f0 90 91 8e 27 2c 0a | .=>.'....',...'....'.=>.'....',. |
2b360 | 20 20 27 f0 90 90 a7 27 20 3d 3e 20 27 f0 90 91 8f 27 2c 0a 20 20 27 f0 91 a2 a0 27 20 3d 3e 20 | ..'....'.=>.'....',...'....'.=>. |
2b380 | 27 f0 91 a3 80 27 2c 0a 20 20 27 f0 91 a2 a1 27 20 3d 3e 20 27 f0 91 a3 81 27 2c 0a 20 20 27 f0 | '....',...'....'.=>.'....',...'. |
2b3a0 | 91 a2 a2 27 20 3d 3e 20 27 f0 91 a3 82 27 2c 0a 20 20 27 f0 91 a2 a3 27 20 3d 3e 20 27 f0 91 a3 | ...'.=>.'....',...'....'.=>.'... |
2b3c0 | 83 27 2c 0a 20 20 27 f0 91 a2 a4 27 20 3d 3e 20 27 f0 91 a3 84 27 2c 0a 20 20 27 f0 91 a2 a5 27 | .',...'....'.=>.'....',...'....' |
2b3e0 | 20 3d 3e 20 27 f0 91 a3 85 27 2c 0a 20 20 27 f0 91 a2 a6 27 20 3d 3e 20 27 f0 91 a3 86 27 2c 0a | .=>.'....',...'....'.=>.'....',. |
2b400 | 20 20 27 f0 91 a2 a7 27 20 3d 3e 20 27 f0 91 a3 87 27 2c 0a 20 20 27 f0 91 a2 a8 27 20 3d 3e 20 | ..'....'.=>.'....',...'....'.=>. |
2b420 | 27 f0 91 a3 88 27 2c 0a 20 20 27 f0 91 a2 a9 27 20 3d 3e 20 27 f0 91 a3 89 27 2c 0a 20 20 27 f0 | '....',...'....'.=>.'....',...'. |
2b440 | 91 a2 aa 27 20 3d 3e 20 27 f0 91 a3 8a 27 2c 0a 20 20 27 f0 91 a2 ab 27 20 3d 3e 20 27 f0 91 a3 | ...'.=>.'....',...'....'.=>.'... |
2b460 | 8b 27 2c 0a 20 20 27 f0 91 a2 ac 27 20 3d 3e 20 27 f0 91 a3 8c 27 2c 0a 20 20 27 f0 91 a2 ad 27 | .',...'....'.=>.'....',...'....' |
2b480 | 20 3d 3e 20 27 f0 91 a3 8d 27 2c 0a 20 20 27 f0 91 a2 ae 27 20 3d 3e 20 27 f0 91 a3 8e 27 2c 0a | .=>.'....',...'....'.=>.'....',. |
2b4a0 | 20 20 27 f0 91 a2 af 27 20 3d 3e 20 27 f0 91 a3 8f 27 2c 0a 20 20 27 f0 91 a2 b0 27 20 3d 3e 20 | ..'....'.=>.'....',...'....'.=>. |
2b4c0 | 27 f0 91 a3 90 27 2c 0a 20 20 27 f0 91 a2 b1 27 20 3d 3e 20 27 f0 91 a3 91 27 2c 0a 20 20 27 f0 | '....',...'....'.=>.'....',...'. |
2b4e0 | 91 a2 b2 27 20 3d 3e 20 27 f0 91 a3 92 27 2c 0a 20 20 27 f0 91 a2 b3 27 20 3d 3e 20 27 f0 91 a3 | ...'.=>.'....',...'....'.=>.'... |
2b500 | 93 27 2c 0a 20 20 27 f0 91 a2 b4 27 20 3d 3e 20 27 f0 91 a3 94 27 2c 0a 20 20 27 f0 91 a2 b5 27 | .',...'....'.=>.'....',...'....' |
2b520 | 20 3d 3e 20 27 f0 91 a3 95 27 2c 0a 20 20 27 f0 91 a2 b6 27 20 3d 3e 20 27 f0 91 a3 96 27 2c 0a | .=>.'....',...'....'.=>.'....',. |
2b540 | 20 20 27 f0 91 a2 b7 27 20 3d 3e 20 27 f0 91 a3 97 27 2c 0a 20 20 27 f0 91 a2 b8 27 20 3d 3e 20 | ..'....'.=>.'....',...'....'.=>. |
2b560 | 27 f0 91 a3 98 27 2c 0a 20 20 27 f0 91 a2 b9 27 20 3d 3e 20 27 f0 91 a3 99 27 2c 0a 20 20 27 f0 | '....',...'....'.=>.'....',...'. |
2b580 | 91 a2 ba 27 20 3d 3e 20 27 f0 91 a3 9a 27 2c 0a 20 20 27 f0 91 a2 bb 27 20 3d 3e 20 27 f0 91 a3 | ...'.=>.'....',...'....'.=>.'... |
2b5a0 | 9b 27 2c 0a 20 20 27 f0 91 a2 bc 27 20 3d 3e 20 27 f0 91 a3 9c 27 2c 0a 20 20 27 f0 91 a2 bd 27 | .',...'....'.=>.'....',...'....' |
2b5c0 | 20 3d 3e 20 27 f0 91 a3 9d 27 2c 0a 20 20 27 f0 91 a2 be 27 20 3d 3e 20 27 f0 91 a3 9e 27 2c 0a | .=>.'....',...'....'.=>.'....',. |
2b5e0 | 20 20 27 f0 91 a2 bf 27 20 3d 3e 20 27 f0 91 a3 9f 27 2c 0a 29 3b 0a 0a 24 72 65 73 75 6c 74 20 | ..'....'.=>.'....',.);..$result. |
2b600 | 3d 26 20 24 64 61 74 61 3b 0a 75 6e 73 65 74 28 24 64 61 74 61 29 3b 0a 0a 72 65 74 75 72 6e 20 | =&.$data;.unset($data);..return. |
2b620 | 24 72 65 73 75 6c 74 3b 0a 3c 3f 70 68 70 0a 0a 73 74 61 74 69 63 20 24 64 61 74 61 20 3d 20 61 | $result;.<?php..static.$data.=.a |
2b640 | 72 72 61 79 20 28 0a 20 20 27 61 27 20 3d 3e 20 27 41 27 2c 0a 20 20 27 62 27 20 3d 3e 20 27 42 | rray.(...'a'.=>.'A',...'b'.=>.'B |
2b660 | 27 2c 0a 20 20 27 63 27 20 3d 3e 20 27 43 27 2c 0a 20 20 27 64 27 20 3d 3e 20 27 44 27 2c 0a 20 | ',...'c'.=>.'C',...'d'.=>.'D',.. |
2b680 | 20 27 65 27 20 3d 3e 20 27 45 27 2c 0a 20 20 27 66 27 20 3d 3e 20 27 46 27 2c 0a 20 20 27 67 27 | .'e'.=>.'E',...'f'.=>.'F',...'g' |
2b6a0 | 20 3d 3e 20 27 47 27 2c 0a 20 20 27 68 27 20 3d 3e 20 27 48 27 2c 0a 20 20 27 69 27 20 3d 3e 20 | .=>.'G',...'h'.=>.'H',...'i'.=>. |
2b6c0 | 27 49 27 2c 0a 20 20 27 6a 27 20 3d 3e 20 27 4a 27 2c 0a 20 20 27 6b 27 20 3d 3e 20 27 4b 27 2c | 'I',...'j'.=>.'J',...'k'.=>.'K', |
2b6e0 | 0a 20 20 27 6c 27 20 3d 3e 20 27 4c 27 2c 0a 20 20 27 6d 27 20 3d 3e 20 27 4d 27 2c 0a 20 20 27 | ...'l'.=>.'L',...'m'.=>.'M',...' |
2b700 | 6e 27 20 3d 3e 20 27 4e 27 2c 0a 20 20 27 6f 27 20 3d 3e 20 27 4f 27 2c 0a 20 20 27 70 27 20 3d | n'.=>.'N',...'o'.=>.'O',...'p'.= |
2b720 | 3e 20 27 50 27 2c 0a 20 20 27 71 27 20 3d 3e 20 27 51 27 2c 0a 20 20 27 72 27 20 3d 3e 20 27 52 | >.'P',...'q'.=>.'Q',...'r'.=>.'R |
2b740 | 27 2c 0a 20 20 27 73 27 20 3d 3e 20 27 53 27 2c 0a 20 20 27 74 27 20 3d 3e 20 27 54 27 2c 0a 20 | ',...'s'.=>.'S',...'t'.=>.'T',.. |
2b760 | 20 27 75 27 20 3d 3e 20 27 55 27 2c 0a 20 20 27 76 27 20 3d 3e 20 27 56 27 2c 0a 20 20 27 77 27 | .'u'.=>.'U',...'v'.=>.'V',...'w' |
2b780 | 20 3d 3e 20 27 57 27 2c 0a 20 20 27 78 27 20 3d 3e 20 27 58 27 2c 0a 20 20 27 79 27 20 3d 3e 20 | .=>.'W',...'x'.=>.'X',...'y'.=>. |
2b7a0 | 27 59 27 2c 0a 20 20 27 7a 27 20 3d 3e 20 27 5a 27 2c 0a 20 20 27 c2 b5 27 20 3d 3e 20 27 ce 9c | 'Y',...'z'.=>.'Z',...'..'.=>.'.. |
2b7c0 | 27 2c 0a 20 20 27 c3 a0 27 20 3d 3e 20 27 c3 80 27 2c 0a 20 20 27 c3 a1 27 20 3d 3e 20 27 c3 81 | ',...'..'.=>.'..',...'..'.=>.'.. |
2b7e0 | 27 2c 0a 20 20 27 c3 a2 27 20 3d 3e 20 27 c3 82 27 2c 0a 20 20 27 c3 a3 27 20 3d 3e 20 27 c3 83 | ',...'..'.=>.'..',...'..'.=>.'.. |
2b800 | 27 2c 0a 20 20 27 c3 a4 27 20 3d 3e 20 27 c3 84 27 2c 0a 20 20 27 c3 a5 27 20 3d 3e 20 27 c3 85 | ',...'..'.=>.'..',...'..'.=>.'.. |
2b820 | 27 2c 0a 20 20 27 c3 a6 27 20 3d 3e 20 27 c3 86 27 2c 0a 20 20 27 c3 a7 27 20 3d 3e 20 27 c3 87 | ',...'..'.=>.'..',...'..'.=>.'.. |
2b840 | 27 2c 0a 20 20 27 c3 a8 27 20 3d 3e 20 27 c3 88 27 2c 0a 20 20 27 c3 a9 27 20 3d 3e 20 27 c3 89 | ',...'..'.=>.'..',...'..'.=>.'.. |
2b860 | 27 2c 0a 20 20 27 c3 aa 27 20 3d 3e 20 27 c3 8a 27 2c 0a 20 20 27 c3 ab 27 20 3d 3e 20 27 c3 8b | ',...'..'.=>.'..',...'..'.=>.'.. |
2b880 | 27 2c 0a 20 20 27 c3 ac 27 20 3d 3e 20 27 c3 8c 27 2c 0a 20 20 27 c3 ad 27 20 3d 3e 20 27 c3 8d | ',...'..'.=>.'..',...'..'.=>.'.. |
2b8a0 | 27 2c 0a 20 20 27 c3 ae 27 20 3d 3e 20 27 c3 8e 27 2c 0a 20 20 27 c3 af 27 20 3d 3e 20 27 c3 8f | ',...'..'.=>.'..',...'..'.=>.'.. |
2b8c0 | 27 2c 0a 20 20 27 c3 b0 27 20 3d 3e 20 27 c3 90 27 2c 0a 20 20 27 c3 b1 27 20 3d 3e 20 27 c3 91 | ',...'..'.=>.'..',...'..'.=>.'.. |
2b8e0 | 27 2c 0a 20 20 27 c3 b2 27 20 3d 3e 20 27 c3 92 27 2c 0a 20 20 27 c3 b3 27 20 3d 3e 20 27 c3 93 | ',...'..'.=>.'..',...'..'.=>.'.. |
2b900 | 27 2c 0a 20 20 27 c3 b4 27 20 3d 3e 20 27 c3 94 27 2c 0a 20 20 27 c3 b5 27 20 3d 3e 20 27 c3 95 | ',...'..'.=>.'..',...'..'.=>.'.. |
2b920 | 27 2c 0a 20 20 27 c3 b6 27 20 3d 3e 20 27 c3 96 27 2c 0a 20 20 27 c3 b8 27 20 3d 3e 20 27 c3 98 | ',...'..'.=>.'..',...'..'.=>.'.. |
2b940 | 27 2c 0a 20 20 27 c3 b9 27 20 3d 3e 20 27 c3 99 27 2c 0a 20 20 27 c3 ba 27 20 3d 3e 20 27 c3 9a | ',...'..'.=>.'..',...'..'.=>.'.. |
2b960 | 27 2c 0a 20 20 27 c3 bb 27 20 3d 3e 20 27 c3 9b 27 2c 0a 20 20 27 c3 bc 27 20 3d 3e 20 27 c3 9c | ',...'..'.=>.'..',...'..'.=>.'.. |
2b980 | 27 2c 0a 20 20 27 c3 bd 27 20 3d 3e 20 27 c3 9d 27 2c 0a 20 20 27 c3 be 27 20 3d 3e 20 27 c3 9e | ',...'..'.=>.'..',...'..'.=>.'.. |
2b9a0 | 27 2c 0a 20 20 27 c3 bf 27 20 3d 3e 20 27 c5 b8 27 2c 0a 20 20 27 c4 81 27 20 3d 3e 20 27 c4 80 | ',...'..'.=>.'..',...'..'.=>.'.. |
2b9c0 | 27 2c 0a 20 20 27 c4 83 27 20 3d 3e 20 27 c4 82 27 2c 0a 20 20 27 c4 85 27 20 3d 3e 20 27 c4 84 | ',...'..'.=>.'..',...'..'.=>.'.. |
2b9e0 | 27 2c 0a 20 20 27 c4 87 27 20 3d 3e 20 27 c4 86 27 2c 0a 20 20 27 c4 89 27 20 3d 3e 20 27 c4 88 | ',...'..'.=>.'..',...'..'.=>.'.. |
2ba00 | 27 2c 0a 20 20 27 c4 8b 27 20 3d 3e 20 27 c4 8a 27 2c 0a 20 20 27 c4 8d 27 20 3d 3e 20 27 c4 8c | ',...'..'.=>.'..',...'..'.=>.'.. |
2ba20 | 27 2c 0a 20 20 27 c4 8f 27 20 3d 3e 20 27 c4 8e 27 2c 0a 20 20 27 c4 91 27 20 3d 3e 20 27 c4 90 | ',...'..'.=>.'..',...'..'.=>.'.. |
2ba40 | 27 2c 0a 20 20 27 c4 93 27 20 3d 3e 20 27 c4 92 27 2c 0a 20 20 27 c4 95 27 20 3d 3e 20 27 c4 94 | ',...'..'.=>.'..',...'..'.=>.'.. |
2ba60 | 27 2c 0a 20 20 27 c4 97 27 20 3d 3e 20 27 c4 96 27 2c 0a 20 20 27 c4 99 27 20 3d 3e 20 27 c4 98 | ',...'..'.=>.'..',...'..'.=>.'.. |
2ba80 | 27 2c 0a 20 20 27 c4 9b 27 20 3d 3e 20 27 c4 9a 27 2c 0a 20 20 27 c4 9d 27 20 3d 3e 20 27 c4 9c | ',...'..'.=>.'..',...'..'.=>.'.. |
2baa0 | 27 2c 0a 20 20 27 c4 9f 27 20 3d 3e 20 27 c4 9e 27 2c 0a 20 20 27 c4 a1 27 20 3d 3e 20 27 c4 a0 | ',...'..'.=>.'..',...'..'.=>.'.. |
2bac0 | 27 2c 0a 20 20 27 c4 a3 27 20 3d 3e 20 27 c4 a2 27 2c 0a 20 20 27 c4 a5 27 20 3d 3e 20 27 c4 a4 | ',...'..'.=>.'..',...'..'.=>.'.. |
2bae0 | 27 2c 0a 20 20 27 c4 a7 27 20 3d 3e 20 27 c4 a6 27 2c 0a 20 20 27 c4 a9 27 20 3d 3e 20 27 c4 a8 | ',...'..'.=>.'..',...'..'.=>.'.. |
2bb00 | 27 2c 0a 20 20 27 c4 ab 27 20 3d 3e 20 27 c4 aa 27 2c 0a 20 20 27 c4 ad 27 20 3d 3e 20 27 c4 ac | ',...'..'.=>.'..',...'..'.=>.'.. |
2bb20 | 27 2c 0a 20 20 27 c4 af 27 20 3d 3e 20 27 c4 ae 27 2c 0a 20 20 27 c4 b1 27 20 3d 3e 20 27 49 27 | ',...'..'.=>.'..',...'..'.=>.'I' |
2bb40 | 2c 0a 20 20 27 c4 b3 27 20 3d 3e 20 27 c4 b2 27 2c 0a 20 20 27 c4 b5 27 20 3d 3e 20 27 c4 b4 27 | ,...'..'.=>.'..',...'..'.=>.'..' |
2bb60 | 2c 0a 20 20 27 c4 b7 27 20 3d 3e 20 27 c4 b6 27 2c 0a 20 20 27 c4 ba 27 20 3d 3e 20 27 c4 b9 27 | ,...'..'.=>.'..',...'..'.=>.'..' |
2bb80 | 2c 0a 20 20 27 c4 bc 27 20 3d 3e 20 27 c4 bb 27 2c 0a 20 20 27 c4 be 27 20 3d 3e 20 27 c4 bd 27 | ,...'..'.=>.'..',...'..'.=>.'..' |
2bba0 | 2c 0a 20 20 27 c5 80 27 20 3d 3e 20 27 c4 bf 27 2c 0a 20 20 27 c5 82 27 20 3d 3e 20 27 c5 81 27 | ,...'..'.=>.'..',...'..'.=>.'..' |
2bbc0 | 2c 0a 20 20 27 c5 84 27 20 3d 3e 20 27 c5 83 27 2c 0a 20 20 27 c5 86 27 20 3d 3e 20 27 c5 85 27 | ,...'..'.=>.'..',...'..'.=>.'..' |
2bbe0 | 2c 0a 20 20 27 c5 88 27 20 3d 3e 20 27 c5 87 27 2c 0a 20 20 27 c5 8b 27 20 3d 3e 20 27 c5 8a 27 | ,...'..'.=>.'..',...'..'.=>.'..' |
2bc00 | 2c 0a 20 20 27 c5 8d 27 20 3d 3e 20 27 c5 8c 27 2c 0a 20 20 27 c5 8f 27 20 3d 3e 20 27 c5 8e 27 | ,...'..'.=>.'..',...'..'.=>.'..' |
2bc20 | 2c 0a 20 20 27 c5 91 27 20 3d 3e 20 27 c5 90 27 2c 0a 20 20 27 c5 93 27 20 3d 3e 20 27 c5 92 27 | ,...'..'.=>.'..',...'..'.=>.'..' |
2bc40 | 2c 0a 20 20 27 c5 95 27 20 3d 3e 20 27 c5 94 27 2c 0a 20 20 27 c5 97 27 20 3d 3e 20 27 c5 96 27 | ,...'..'.=>.'..',...'..'.=>.'..' |
2bc60 | 2c 0a 20 20 27 c5 99 27 20 3d 3e 20 27 c5 98 27 2c 0a 20 20 27 c5 9b 27 20 3d 3e 20 27 c5 9a 27 | ,...'..'.=>.'..',...'..'.=>.'..' |
2bc80 | 2c 0a 20 20 27 c5 9d 27 20 3d 3e 20 27 c5 9c 27 2c 0a 20 20 27 c5 9f 27 20 3d 3e 20 27 c5 9e 27 | ,...'..'.=>.'..',...'..'.=>.'..' |
2bca0 | 2c 0a 20 20 27 c5 a1 27 20 3d 3e 20 27 c5 a0 27 2c 0a 20 20 27 c5 a3 27 20 3d 3e 20 27 c5 a2 27 | ,...'..'.=>.'..',...'..'.=>.'..' |
2bcc0 | 2c 0a 20 20 27 c5 a5 27 20 3d 3e 20 27 c5 a4 27 2c 0a 20 20 27 c5 a7 27 20 3d 3e 20 27 c5 a6 27 | ,...'..'.=>.'..',...'..'.=>.'..' |
2bce0 | 2c 0a 20 20 27 c5 a9 27 20 3d 3e 20 27 c5 a8 27 2c 0a 20 20 27 c5 ab 27 20 3d 3e 20 27 c5 aa 27 | ,...'..'.=>.'..',...'..'.=>.'..' |
2bd00 | 2c 0a 20 20 27 c5 ad 27 20 3d 3e 20 27 c5 ac 27 2c 0a 20 20 27 c5 af 27 20 3d 3e 20 27 c5 ae 27 | ,...'..'.=>.'..',...'..'.=>.'..' |
2bd20 | 2c 0a 20 20 27 c5 b1 27 20 3d 3e 20 27 c5 b0 27 2c 0a 20 20 27 c5 b3 27 20 3d 3e 20 27 c5 b2 27 | ,...'..'.=>.'..',...'..'.=>.'..' |
2bd40 | 2c 0a 20 20 27 c5 b5 27 20 3d 3e 20 27 c5 b4 27 2c 0a 20 20 27 c5 b7 27 20 3d 3e 20 27 c5 b6 27 | ,...'..'.=>.'..',...'..'.=>.'..' |
2bd60 | 2c 0a 20 20 27 c5 ba 27 20 3d 3e 20 27 c5 b9 27 2c 0a 20 20 27 c5 bc 27 20 3d 3e 20 27 c5 bb 27 | ,...'..'.=>.'..',...'..'.=>.'..' |
2bd80 | 2c 0a 20 20 27 c5 be 27 20 3d 3e 20 27 c5 bd 27 2c 0a 20 20 27 c5 bf 27 20 3d 3e 20 27 53 27 2c | ,...'..'.=>.'..',...'..'.=>.'S', |
2bda0 | 0a 20 20 27 c6 80 27 20 3d 3e 20 27 c9 83 27 2c 0a 20 20 27 c6 83 27 20 3d 3e 20 27 c6 82 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2bdc0 | 0a 20 20 27 c6 85 27 20 3d 3e 20 27 c6 84 27 2c 0a 20 20 27 c6 88 27 20 3d 3e 20 27 c6 87 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2bde0 | 0a 20 20 27 c6 8c 27 20 3d 3e 20 27 c6 8b 27 2c 0a 20 20 27 c6 92 27 20 3d 3e 20 27 c6 91 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2be00 | 0a 20 20 27 c6 95 27 20 3d 3e 20 27 c7 b6 27 2c 0a 20 20 27 c6 99 27 20 3d 3e 20 27 c6 98 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2be20 | 0a 20 20 27 c6 9a 27 20 3d 3e 20 27 c8 bd 27 2c 0a 20 20 27 c6 9e 27 20 3d 3e 20 27 c8 a0 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2be40 | 0a 20 20 27 c6 a1 27 20 3d 3e 20 27 c6 a0 27 2c 0a 20 20 27 c6 a3 27 20 3d 3e 20 27 c6 a2 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2be60 | 0a 20 20 27 c6 a5 27 20 3d 3e 20 27 c6 a4 27 2c 0a 20 20 27 c6 a8 27 20 3d 3e 20 27 c6 a7 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2be80 | 0a 20 20 27 c6 ad 27 20 3d 3e 20 27 c6 ac 27 2c 0a 20 20 27 c6 b0 27 20 3d 3e 20 27 c6 af 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2bea0 | 0a 20 20 27 c6 b4 27 20 3d 3e 20 27 c6 b3 27 2c 0a 20 20 27 c6 b6 27 20 3d 3e 20 27 c6 b5 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2bec0 | 0a 20 20 27 c6 b9 27 20 3d 3e 20 27 c6 b8 27 2c 0a 20 20 27 c6 bd 27 20 3d 3e 20 27 c6 bc 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2bee0 | 0a 20 20 27 c6 bf 27 20 3d 3e 20 27 c7 b7 27 2c 0a 20 20 27 c7 85 27 20 3d 3e 20 27 c7 84 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2bf00 | 0a 20 20 27 c7 86 27 20 3d 3e 20 27 c7 84 27 2c 0a 20 20 27 c7 88 27 20 3d 3e 20 27 c7 87 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2bf20 | 0a 20 20 27 c7 89 27 20 3d 3e 20 27 c7 87 27 2c 0a 20 20 27 c7 8b 27 20 3d 3e 20 27 c7 8a 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2bf40 | 0a 20 20 27 c7 8c 27 20 3d 3e 20 27 c7 8a 27 2c 0a 20 20 27 c7 8e 27 20 3d 3e 20 27 c7 8d 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2bf60 | 0a 20 20 27 c7 90 27 20 3d 3e 20 27 c7 8f 27 2c 0a 20 20 27 c7 92 27 20 3d 3e 20 27 c7 91 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2bf80 | 0a 20 20 27 c7 94 27 20 3d 3e 20 27 c7 93 27 2c 0a 20 20 27 c7 96 27 20 3d 3e 20 27 c7 95 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2bfa0 | 0a 20 20 27 c7 98 27 20 3d 3e 20 27 c7 97 27 2c 0a 20 20 27 c7 9a 27 20 3d 3e 20 27 c7 99 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2bfc0 | 0a 20 20 27 c7 9c 27 20 3d 3e 20 27 c7 9b 27 2c 0a 20 20 27 c7 9d 27 20 3d 3e 20 27 c6 8e 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2bfe0 | 0a 20 20 27 c7 9f 27 20 3d 3e 20 27 c7 9e 27 2c 0a 20 20 27 c7 a1 27 20 3d 3e 20 27 c7 a0 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2c000 | 0a 20 20 27 c7 a3 27 20 3d 3e 20 27 c7 a2 27 2c 0a 20 20 27 c7 a5 27 20 3d 3e 20 27 c7 a4 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2c020 | 0a 20 20 27 c7 a7 27 20 3d 3e 20 27 c7 a6 27 2c 0a 20 20 27 c7 a9 27 20 3d 3e 20 27 c7 a8 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2c040 | 0a 20 20 27 c7 ab 27 20 3d 3e 20 27 c7 aa 27 2c 0a 20 20 27 c7 ad 27 20 3d 3e 20 27 c7 ac 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2c060 | 0a 20 20 27 c7 af 27 20 3d 3e 20 27 c7 ae 27 2c 0a 20 20 27 c7 b2 27 20 3d 3e 20 27 c7 b1 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2c080 | 0a 20 20 27 c7 b3 27 20 3d 3e 20 27 c7 b1 27 2c 0a 20 20 27 c7 b5 27 20 3d 3e 20 27 c7 b4 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2c0a0 | 0a 20 20 27 c7 b9 27 20 3d 3e 20 27 c7 b8 27 2c 0a 20 20 27 c7 bb 27 20 3d 3e 20 27 c7 ba 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2c0c0 | 0a 20 20 27 c7 bd 27 20 3d 3e 20 27 c7 bc 27 2c 0a 20 20 27 c7 bf 27 20 3d 3e 20 27 c7 be 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2c0e0 | 0a 20 20 27 c8 81 27 20 3d 3e 20 27 c8 80 27 2c 0a 20 20 27 c8 83 27 20 3d 3e 20 27 c8 82 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2c100 | 0a 20 20 27 c8 85 27 20 3d 3e 20 27 c8 84 27 2c 0a 20 20 27 c8 87 27 20 3d 3e 20 27 c8 86 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2c120 | 0a 20 20 27 c8 89 27 20 3d 3e 20 27 c8 88 27 2c 0a 20 20 27 c8 8b 27 20 3d 3e 20 27 c8 8a 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2c140 | 0a 20 20 27 c8 8d 27 20 3d 3e 20 27 c8 8c 27 2c 0a 20 20 27 c8 8f 27 20 3d 3e 20 27 c8 8e 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2c160 | 0a 20 20 27 c8 91 27 20 3d 3e 20 27 c8 90 27 2c 0a 20 20 27 c8 93 27 20 3d 3e 20 27 c8 92 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2c180 | 0a 20 20 27 c8 95 27 20 3d 3e 20 27 c8 94 27 2c 0a 20 20 27 c8 97 27 20 3d 3e 20 27 c8 96 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2c1a0 | 0a 20 20 27 c8 99 27 20 3d 3e 20 27 c8 98 27 2c 0a 20 20 27 c8 9b 27 20 3d 3e 20 27 c8 9a 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2c1c0 | 0a 20 20 27 c8 9d 27 20 3d 3e 20 27 c8 9c 27 2c 0a 20 20 27 c8 9f 27 20 3d 3e 20 27 c8 9e 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2c1e0 | 0a 20 20 27 c8 a3 27 20 3d 3e 20 27 c8 a2 27 2c 0a 20 20 27 c8 a5 27 20 3d 3e 20 27 c8 a4 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2c200 | 0a 20 20 27 c8 a7 27 20 3d 3e 20 27 c8 a6 27 2c 0a 20 20 27 c8 a9 27 20 3d 3e 20 27 c8 a8 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2c220 | 0a 20 20 27 c8 ab 27 20 3d 3e 20 27 c8 aa 27 2c 0a 20 20 27 c8 ad 27 20 3d 3e 20 27 c8 ac 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2c240 | 0a 20 20 27 c8 af 27 20 3d 3e 20 27 c8 ae 27 2c 0a 20 20 27 c8 b1 27 20 3d 3e 20 27 c8 b0 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2c260 | 0a 20 20 27 c8 b3 27 20 3d 3e 20 27 c8 b2 27 2c 0a 20 20 27 c8 bc 27 20 3d 3e 20 27 c8 bb 27 2c | ...'..'.=>.'..',...'..'.=>.'..', |
2c280 | 0a 20 20 27 c8 bf 27 20 3d 3e 20 27 e2 b1 be 27 2c 0a 20 20 27 c9 80 27 20 3d 3e 20 27 e2 b1 bf | ...'..'.=>.'...',...'..'.=>.'... |
2c2a0 | 27 2c 0a 20 20 27 c9 82 27 20 3d 3e 20 27 c9 81 27 2c 0a 20 20 27 c9 87 27 20 3d 3e 20 27 c9 86 | ',...'..'.=>.'..',...'..'.=>.'.. |
2c2c0 | 27 2c 0a 20 20 27 c9 89 27 20 3d 3e 20 27 c9 88 27 2c 0a 20 20 27 c9 8b 27 20 3d 3e 20 27 c9 8a | ',...'..'.=>.'..',...'..'.=>.'.. |
2c2e0 | 27 2c 0a 20 20 27 c9 8d 27 20 3d 3e 20 27 c9 8c 27 2c 0a 20 20 27 c9 8f 27 20 3d 3e 20 27 c9 8e | ',...'..'.=>.'..',...'..'.=>.'.. |
2c300 | 27 2c 0a 20 20 27 c9 90 27 20 3d 3e 20 27 e2 b1 af 27 2c 0a 20 20 27 c9 91 27 20 3d 3e 20 27 e2 | ',...'..'.=>.'...',...'..'.=>.'. |
2c320 | b1 ad 27 2c 0a 20 20 27 c9 92 27 20 3d 3e 20 27 e2 b1 b0 27 2c 0a 20 20 27 c9 93 27 20 3d 3e 20 | ..',...'..'.=>.'...',...'..'.=>. |
2c340 | 27 c6 81 27 2c 0a 20 20 27 c9 94 27 20 3d 3e 20 27 c6 86 27 2c 0a 20 20 27 c9 96 27 20 3d 3e 20 | '..',...'..'.=>.'..',...'..'.=>. |
2c360 | 27 c6 89 27 2c 0a 20 20 27 c9 97 27 20 3d 3e 20 27 c6 8a 27 2c 0a 20 20 27 c9 99 27 20 3d 3e 20 | '..',...'..'.=>.'..',...'..'.=>. |
2c380 | 27 c6 8f 27 2c 0a 20 20 27 c9 9b 27 20 3d 3e 20 27 c6 90 27 2c 0a 20 20 27 c9 9c 27 20 3d 3e 20 | '..',...'..'.=>.'..',...'..'.=>. |
2c3a0 | 27 ea 9e ab 27 2c 0a 20 20 27 c9 a0 27 20 3d 3e 20 27 c6 93 27 2c 0a 20 20 27 c9 a1 27 20 3d 3e | '...',...'..'.=>.'..',...'..'.=> |
2c3c0 | 20 27 ea 9e ac 27 2c 0a 20 20 27 c9 a3 27 20 3d 3e 20 27 c6 94 27 2c 0a 20 20 27 c9 a5 27 20 3d | .'...',...'..'.=>.'..',...'..'.= |
2c3e0 | 3e 20 27 ea 9e 8d 27 2c 0a 20 20 27 c9 a6 27 20 3d 3e 20 27 ea 9e aa 27 2c 0a 20 20 27 c9 a8 27 | >.'...',...'..'.=>.'...',...'..' |
2c400 | 20 3d 3e 20 27 c6 97 27 2c 0a 20 20 27 c9 a9 27 20 3d 3e 20 27 c6 96 27 2c 0a 20 20 27 c9 ab 27 | .=>.'..',...'..'.=>.'..',...'..' |
2c420 | 20 3d 3e 20 27 e2 b1 a2 27 2c 0a 20 20 27 c9 ac 27 20 3d 3e 20 27 ea 9e ad 27 2c 0a 20 20 27 c9 | .=>.'...',...'..'.=>.'...',...'. |
2c440 | af 27 20 3d 3e 20 27 c6 9c 27 2c 0a 20 20 27 c9 b1 27 20 3d 3e 20 27 e2 b1 ae 27 2c 0a 20 20 27 | .'.=>.'..',...'..'.=>.'...',...' |
2c460 | c9 b2 27 20 3d 3e 20 27 c6 9d 27 2c 0a 20 20 27 c9 b5 27 20 3d 3e 20 27 c6 9f 27 2c 0a 20 20 27 | ..'.=>.'..',...'..'.=>.'..',...' |
2c480 | c9 bd 27 20 3d 3e 20 27 e2 b1 a4 27 2c 0a 20 20 27 ca 80 27 20 3d 3e 20 27 c6 a6 27 2c 0a 20 20 | ..'.=>.'...',...'..'.=>.'..',... |
2c4a0 | 27 ca 83 27 20 3d 3e 20 27 c6 a9 27 2c 0a 20 20 27 ca 87 27 20 3d 3e 20 27 ea 9e b1 27 2c 0a 20 | '..'.=>.'..',...'..'.=>.'...',.. |
2c4c0 | 20 27 ca 88 27 20 3d 3e 20 27 c6 ae 27 2c 0a 20 20 27 ca 89 27 20 3d 3e 20 27 c9 84 27 2c 0a 20 | .'..'.=>.'..',...'..'.=>.'..',.. |
2c4e0 | 20 27 ca 8a 27 20 3d 3e 20 27 c6 b1 27 2c 0a 20 20 27 ca 8b 27 20 3d 3e 20 27 c6 b2 27 2c 0a 20 | .'..'.=>.'..',...'..'.=>.'..',.. |
2c500 | 20 27 ca 8c 27 20 3d 3e 20 27 c9 85 27 2c 0a 20 20 27 ca 92 27 20 3d 3e 20 27 c6 b7 27 2c 0a 20 | .'..'.=>.'..',...'..'.=>.'..',.. |
2c520 | 20 27 ca 9e 27 20 3d 3e 20 27 ea 9e b0 27 2c 0a 20 20 27 cd 85 27 20 3d 3e 20 27 ce 99 27 2c 0a | .'..'.=>.'...',...'..'.=>.'..',. |
2c540 | 20 20 27 cd b1 27 20 3d 3e 20 27 cd b0 27 2c 0a 20 20 27 cd b3 27 20 3d 3e 20 27 cd b2 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c560 | 20 20 27 cd b7 27 20 3d 3e 20 27 cd b6 27 2c 0a 20 20 27 cd bb 27 20 3d 3e 20 27 cf bd 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c580 | 20 20 27 cd bc 27 20 3d 3e 20 27 cf be 27 2c 0a 20 20 27 cd bd 27 20 3d 3e 20 27 cf bf 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c5a0 | 20 20 27 ce ac 27 20 3d 3e 20 27 ce 86 27 2c 0a 20 20 27 ce ad 27 20 3d 3e 20 27 ce 88 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c5c0 | 20 20 27 ce ae 27 20 3d 3e 20 27 ce 89 27 2c 0a 20 20 27 ce af 27 20 3d 3e 20 27 ce 8a 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c5e0 | 20 20 27 ce b1 27 20 3d 3e 20 27 ce 91 27 2c 0a 20 20 27 ce b2 27 20 3d 3e 20 27 ce 92 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c600 | 20 20 27 ce b3 27 20 3d 3e 20 27 ce 93 27 2c 0a 20 20 27 ce b4 27 20 3d 3e 20 27 ce 94 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c620 | 20 20 27 ce b5 27 20 3d 3e 20 27 ce 95 27 2c 0a 20 20 27 ce b6 27 20 3d 3e 20 27 ce 96 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c640 | 20 20 27 ce b7 27 20 3d 3e 20 27 ce 97 27 2c 0a 20 20 27 ce b8 27 20 3d 3e 20 27 ce 98 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c660 | 20 20 27 ce b9 27 20 3d 3e 20 27 ce 99 27 2c 0a 20 20 27 ce ba 27 20 3d 3e 20 27 ce 9a 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c680 | 20 20 27 ce bb 27 20 3d 3e 20 27 ce 9b 27 2c 0a 20 20 27 ce bc 27 20 3d 3e 20 27 ce 9c 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c6a0 | 20 20 27 ce bd 27 20 3d 3e 20 27 ce 9d 27 2c 0a 20 20 27 ce be 27 20 3d 3e 20 27 ce 9e 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c6c0 | 20 20 27 ce bf 27 20 3d 3e 20 27 ce 9f 27 2c 0a 20 20 27 cf 80 27 20 3d 3e 20 27 ce a0 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c6e0 | 20 20 27 cf 81 27 20 3d 3e 20 27 ce a1 27 2c 0a 20 20 27 cf 82 27 20 3d 3e 20 27 ce a3 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c700 | 20 20 27 cf 83 27 20 3d 3e 20 27 ce a3 27 2c 0a 20 20 27 cf 84 27 20 3d 3e 20 27 ce a4 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c720 | 20 20 27 cf 85 27 20 3d 3e 20 27 ce a5 27 2c 0a 20 20 27 cf 86 27 20 3d 3e 20 27 ce a6 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c740 | 20 20 27 cf 87 27 20 3d 3e 20 27 ce a7 27 2c 0a 20 20 27 cf 88 27 20 3d 3e 20 27 ce a8 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c760 | 20 20 27 cf 89 27 20 3d 3e 20 27 ce a9 27 2c 0a 20 20 27 cf 8a 27 20 3d 3e 20 27 ce aa 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c780 | 20 20 27 cf 8b 27 20 3d 3e 20 27 ce ab 27 2c 0a 20 20 27 cf 8c 27 20 3d 3e 20 27 ce 8c 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c7a0 | 20 20 27 cf 8d 27 20 3d 3e 20 27 ce 8e 27 2c 0a 20 20 27 cf 8e 27 20 3d 3e 20 27 ce 8f 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c7c0 | 20 20 27 cf 90 27 20 3d 3e 20 27 ce 92 27 2c 0a 20 20 27 cf 91 27 20 3d 3e 20 27 ce 98 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c7e0 | 20 20 27 cf 95 27 20 3d 3e 20 27 ce a6 27 2c 0a 20 20 27 cf 96 27 20 3d 3e 20 27 ce a0 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c800 | 20 20 27 cf 97 27 20 3d 3e 20 27 cf 8f 27 2c 0a 20 20 27 cf 99 27 20 3d 3e 20 27 cf 98 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c820 | 20 20 27 cf 9b 27 20 3d 3e 20 27 cf 9a 27 2c 0a 20 20 27 cf 9d 27 20 3d 3e 20 27 cf 9c 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c840 | 20 20 27 cf 9f 27 20 3d 3e 20 27 cf 9e 27 2c 0a 20 20 27 cf a1 27 20 3d 3e 20 27 cf a0 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c860 | 20 20 27 cf a3 27 20 3d 3e 20 27 cf a2 27 2c 0a 20 20 27 cf a5 27 20 3d 3e 20 27 cf a4 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c880 | 20 20 27 cf a7 27 20 3d 3e 20 27 cf a6 27 2c 0a 20 20 27 cf a9 27 20 3d 3e 20 27 cf a8 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c8a0 | 20 20 27 cf ab 27 20 3d 3e 20 27 cf aa 27 2c 0a 20 20 27 cf ad 27 20 3d 3e 20 27 cf ac 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c8c0 | 20 20 27 cf af 27 20 3d 3e 20 27 cf ae 27 2c 0a 20 20 27 cf b0 27 20 3d 3e 20 27 ce 9a 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c8e0 | 20 20 27 cf b1 27 20 3d 3e 20 27 ce a1 27 2c 0a 20 20 27 cf b2 27 20 3d 3e 20 27 cf b9 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c900 | 20 20 27 cf b3 27 20 3d 3e 20 27 cd bf 27 2c 0a 20 20 27 cf b5 27 20 3d 3e 20 27 ce 95 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c920 | 20 20 27 cf b8 27 20 3d 3e 20 27 cf b7 27 2c 0a 20 20 27 cf bb 27 20 3d 3e 20 27 cf ba 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c940 | 20 20 27 d0 b0 27 20 3d 3e 20 27 d0 90 27 2c 0a 20 20 27 d0 b1 27 20 3d 3e 20 27 d0 91 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c960 | 20 20 27 d0 b2 27 20 3d 3e 20 27 d0 92 27 2c 0a 20 20 27 d0 b3 27 20 3d 3e 20 27 d0 93 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c980 | 20 20 27 d0 b4 27 20 3d 3e 20 27 d0 94 27 2c 0a 20 20 27 d0 b5 27 20 3d 3e 20 27 d0 95 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c9a0 | 20 20 27 d0 b6 27 20 3d 3e 20 27 d0 96 27 2c 0a 20 20 27 d0 b7 27 20 3d 3e 20 27 d0 97 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c9c0 | 20 20 27 d0 b8 27 20 3d 3e 20 27 d0 98 27 2c 0a 20 20 27 d0 b9 27 20 3d 3e 20 27 d0 99 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2c9e0 | 20 20 27 d0 ba 27 20 3d 3e 20 27 d0 9a 27 2c 0a 20 20 27 d0 bb 27 20 3d 3e 20 27 d0 9b 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2ca00 | 20 20 27 d0 bc 27 20 3d 3e 20 27 d0 9c 27 2c 0a 20 20 27 d0 bd 27 20 3d 3e 20 27 d0 9d 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2ca20 | 20 20 27 d0 be 27 20 3d 3e 20 27 d0 9e 27 2c 0a 20 20 27 d0 bf 27 20 3d 3e 20 27 d0 9f 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2ca40 | 20 20 27 d1 80 27 20 3d 3e 20 27 d0 a0 27 2c 0a 20 20 27 d1 81 27 20 3d 3e 20 27 d0 a1 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2ca60 | 20 20 27 d1 82 27 20 3d 3e 20 27 d0 a2 27 2c 0a 20 20 27 d1 83 27 20 3d 3e 20 27 d0 a3 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2ca80 | 20 20 27 d1 84 27 20 3d 3e 20 27 d0 a4 27 2c 0a 20 20 27 d1 85 27 20 3d 3e 20 27 d0 a5 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2caa0 | 20 20 27 d1 86 27 20 3d 3e 20 27 d0 a6 27 2c 0a 20 20 27 d1 87 27 20 3d 3e 20 27 d0 a7 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cac0 | 20 20 27 d1 88 27 20 3d 3e 20 27 d0 a8 27 2c 0a 20 20 27 d1 89 27 20 3d 3e 20 27 d0 a9 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cae0 | 20 20 27 d1 8a 27 20 3d 3e 20 27 d0 aa 27 2c 0a 20 20 27 d1 8b 27 20 3d 3e 20 27 d0 ab 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cb00 | 20 20 27 d1 8c 27 20 3d 3e 20 27 d0 ac 27 2c 0a 20 20 27 d1 8d 27 20 3d 3e 20 27 d0 ad 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cb20 | 20 20 27 d1 8e 27 20 3d 3e 20 27 d0 ae 27 2c 0a 20 20 27 d1 8f 27 20 3d 3e 20 27 d0 af 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cb40 | 20 20 27 d1 90 27 20 3d 3e 20 27 d0 80 27 2c 0a 20 20 27 d1 91 27 20 3d 3e 20 27 d0 81 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cb60 | 20 20 27 d1 92 27 20 3d 3e 20 27 d0 82 27 2c 0a 20 20 27 d1 93 27 20 3d 3e 20 27 d0 83 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cb80 | 20 20 27 d1 94 27 20 3d 3e 20 27 d0 84 27 2c 0a 20 20 27 d1 95 27 20 3d 3e 20 27 d0 85 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cba0 | 20 20 27 d1 96 27 20 3d 3e 20 27 d0 86 27 2c 0a 20 20 27 d1 97 27 20 3d 3e 20 27 d0 87 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cbc0 | 20 20 27 d1 98 27 20 3d 3e 20 27 d0 88 27 2c 0a 20 20 27 d1 99 27 20 3d 3e 20 27 d0 89 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cbe0 | 20 20 27 d1 9a 27 20 3d 3e 20 27 d0 8a 27 2c 0a 20 20 27 d1 9b 27 20 3d 3e 20 27 d0 8b 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cc00 | 20 20 27 d1 9c 27 20 3d 3e 20 27 d0 8c 27 2c 0a 20 20 27 d1 9d 27 20 3d 3e 20 27 d0 8d 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cc20 | 20 20 27 d1 9e 27 20 3d 3e 20 27 d0 8e 27 2c 0a 20 20 27 d1 9f 27 20 3d 3e 20 27 d0 8f 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cc40 | 20 20 27 d1 a1 27 20 3d 3e 20 27 d1 a0 27 2c 0a 20 20 27 d1 a3 27 20 3d 3e 20 27 d1 a2 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cc60 | 20 20 27 d1 a5 27 20 3d 3e 20 27 d1 a4 27 2c 0a 20 20 27 d1 a7 27 20 3d 3e 20 27 d1 a6 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cc80 | 20 20 27 d1 a9 27 20 3d 3e 20 27 d1 a8 27 2c 0a 20 20 27 d1 ab 27 20 3d 3e 20 27 d1 aa 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cca0 | 20 20 27 d1 ad 27 20 3d 3e 20 27 d1 ac 27 2c 0a 20 20 27 d1 af 27 20 3d 3e 20 27 d1 ae 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2ccc0 | 20 20 27 d1 b1 27 20 3d 3e 20 27 d1 b0 27 2c 0a 20 20 27 d1 b3 27 20 3d 3e 20 27 d1 b2 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cce0 | 20 20 27 d1 b5 27 20 3d 3e 20 27 d1 b4 27 2c 0a 20 20 27 d1 b7 27 20 3d 3e 20 27 d1 b6 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cd00 | 20 20 27 d1 b9 27 20 3d 3e 20 27 d1 b8 27 2c 0a 20 20 27 d1 bb 27 20 3d 3e 20 27 d1 ba 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cd20 | 20 20 27 d1 bd 27 20 3d 3e 20 27 d1 bc 27 2c 0a 20 20 27 d1 bf 27 20 3d 3e 20 27 d1 be 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cd40 | 20 20 27 d2 81 27 20 3d 3e 20 27 d2 80 27 2c 0a 20 20 27 d2 8b 27 20 3d 3e 20 27 d2 8a 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cd60 | 20 20 27 d2 8d 27 20 3d 3e 20 27 d2 8c 27 2c 0a 20 20 27 d2 8f 27 20 3d 3e 20 27 d2 8e 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cd80 | 20 20 27 d2 91 27 20 3d 3e 20 27 d2 90 27 2c 0a 20 20 27 d2 93 27 20 3d 3e 20 27 d2 92 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cda0 | 20 20 27 d2 95 27 20 3d 3e 20 27 d2 94 27 2c 0a 20 20 27 d2 97 27 20 3d 3e 20 27 d2 96 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cdc0 | 20 20 27 d2 99 27 20 3d 3e 20 27 d2 98 27 2c 0a 20 20 27 d2 9b 27 20 3d 3e 20 27 d2 9a 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cde0 | 20 20 27 d2 9d 27 20 3d 3e 20 27 d2 9c 27 2c 0a 20 20 27 d2 9f 27 20 3d 3e 20 27 d2 9e 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2ce00 | 20 20 27 d2 a1 27 20 3d 3e 20 27 d2 a0 27 2c 0a 20 20 27 d2 a3 27 20 3d 3e 20 27 d2 a2 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2ce20 | 20 20 27 d2 a5 27 20 3d 3e 20 27 d2 a4 27 2c 0a 20 20 27 d2 a7 27 20 3d 3e 20 27 d2 a6 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2ce40 | 20 20 27 d2 a9 27 20 3d 3e 20 27 d2 a8 27 2c 0a 20 20 27 d2 ab 27 20 3d 3e 20 27 d2 aa 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2ce60 | 20 20 27 d2 ad 27 20 3d 3e 20 27 d2 ac 27 2c 0a 20 20 27 d2 af 27 20 3d 3e 20 27 d2 ae 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2ce80 | 20 20 27 d2 b1 27 20 3d 3e 20 27 d2 b0 27 2c 0a 20 20 27 d2 b3 27 20 3d 3e 20 27 d2 b2 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cea0 | 20 20 27 d2 b5 27 20 3d 3e 20 27 d2 b4 27 2c 0a 20 20 27 d2 b7 27 20 3d 3e 20 27 d2 b6 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cec0 | 20 20 27 d2 b9 27 20 3d 3e 20 27 d2 b8 27 2c 0a 20 20 27 d2 bb 27 20 3d 3e 20 27 d2 ba 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cee0 | 20 20 27 d2 bd 27 20 3d 3e 20 27 d2 bc 27 2c 0a 20 20 27 d2 bf 27 20 3d 3e 20 27 d2 be 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cf00 | 20 20 27 d3 82 27 20 3d 3e 20 27 d3 81 27 2c 0a 20 20 27 d3 84 27 20 3d 3e 20 27 d3 83 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cf20 | 20 20 27 d3 86 27 20 3d 3e 20 27 d3 85 27 2c 0a 20 20 27 d3 88 27 20 3d 3e 20 27 d3 87 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cf40 | 20 20 27 d3 8a 27 20 3d 3e 20 27 d3 89 27 2c 0a 20 20 27 d3 8c 27 20 3d 3e 20 27 d3 8b 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cf60 | 20 20 27 d3 8e 27 20 3d 3e 20 27 d3 8d 27 2c 0a 20 20 27 d3 8f 27 20 3d 3e 20 27 d3 80 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cf80 | 20 20 27 d3 91 27 20 3d 3e 20 27 d3 90 27 2c 0a 20 20 27 d3 93 27 20 3d 3e 20 27 d3 92 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cfa0 | 20 20 27 d3 95 27 20 3d 3e 20 27 d3 94 27 2c 0a 20 20 27 d3 97 27 20 3d 3e 20 27 d3 96 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cfc0 | 20 20 27 d3 99 27 20 3d 3e 20 27 d3 98 27 2c 0a 20 20 27 d3 9b 27 20 3d 3e 20 27 d3 9a 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2cfe0 | 20 20 27 d3 9d 27 20 3d 3e 20 27 d3 9c 27 2c 0a 20 20 27 d3 9f 27 20 3d 3e 20 27 d3 9e 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d000 | 20 20 27 d3 a1 27 20 3d 3e 20 27 d3 a0 27 2c 0a 20 20 27 d3 a3 27 20 3d 3e 20 27 d3 a2 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d020 | 20 20 27 d3 a5 27 20 3d 3e 20 27 d3 a4 27 2c 0a 20 20 27 d3 a7 27 20 3d 3e 20 27 d3 a6 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d040 | 20 20 27 d3 a9 27 20 3d 3e 20 27 d3 a8 27 2c 0a 20 20 27 d3 ab 27 20 3d 3e 20 27 d3 aa 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d060 | 20 20 27 d3 ad 27 20 3d 3e 20 27 d3 ac 27 2c 0a 20 20 27 d3 af 27 20 3d 3e 20 27 d3 ae 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d080 | 20 20 27 d3 b1 27 20 3d 3e 20 27 d3 b0 27 2c 0a 20 20 27 d3 b3 27 20 3d 3e 20 27 d3 b2 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d0a0 | 20 20 27 d3 b5 27 20 3d 3e 20 27 d3 b4 27 2c 0a 20 20 27 d3 b7 27 20 3d 3e 20 27 d3 b6 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d0c0 | 20 20 27 d3 b9 27 20 3d 3e 20 27 d3 b8 27 2c 0a 20 20 27 d3 bb 27 20 3d 3e 20 27 d3 ba 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d0e0 | 20 20 27 d3 bd 27 20 3d 3e 20 27 d3 bc 27 2c 0a 20 20 27 d3 bf 27 20 3d 3e 20 27 d3 be 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d100 | 20 20 27 d4 81 27 20 3d 3e 20 27 d4 80 27 2c 0a 20 20 27 d4 83 27 20 3d 3e 20 27 d4 82 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d120 | 20 20 27 d4 85 27 20 3d 3e 20 27 d4 84 27 2c 0a 20 20 27 d4 87 27 20 3d 3e 20 27 d4 86 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d140 | 20 20 27 d4 89 27 20 3d 3e 20 27 d4 88 27 2c 0a 20 20 27 d4 8b 27 20 3d 3e 20 27 d4 8a 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d160 | 20 20 27 d4 8d 27 20 3d 3e 20 27 d4 8c 27 2c 0a 20 20 27 d4 8f 27 20 3d 3e 20 27 d4 8e 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d180 | 20 20 27 d4 91 27 20 3d 3e 20 27 d4 90 27 2c 0a 20 20 27 d4 93 27 20 3d 3e 20 27 d4 92 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d1a0 | 20 20 27 d4 95 27 20 3d 3e 20 27 d4 94 27 2c 0a 20 20 27 d4 97 27 20 3d 3e 20 27 d4 96 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d1c0 | 20 20 27 d4 99 27 20 3d 3e 20 27 d4 98 27 2c 0a 20 20 27 d4 9b 27 20 3d 3e 20 27 d4 9a 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d1e0 | 20 20 27 d4 9d 27 20 3d 3e 20 27 d4 9c 27 2c 0a 20 20 27 d4 9f 27 20 3d 3e 20 27 d4 9e 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d200 | 20 20 27 d4 a1 27 20 3d 3e 20 27 d4 a0 27 2c 0a 20 20 27 d4 a3 27 20 3d 3e 20 27 d4 a2 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d220 | 20 20 27 d4 a5 27 20 3d 3e 20 27 d4 a4 27 2c 0a 20 20 27 d4 a7 27 20 3d 3e 20 27 d4 a6 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d240 | 20 20 27 d4 a9 27 20 3d 3e 20 27 d4 a8 27 2c 0a 20 20 27 d4 ab 27 20 3d 3e 20 27 d4 aa 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d260 | 20 20 27 d4 ad 27 20 3d 3e 20 27 d4 ac 27 2c 0a 20 20 27 d4 af 27 20 3d 3e 20 27 d4 ae 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d280 | 20 20 27 d5 a1 27 20 3d 3e 20 27 d4 b1 27 2c 0a 20 20 27 d5 a2 27 20 3d 3e 20 27 d4 b2 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d2a0 | 20 20 27 d5 a3 27 20 3d 3e 20 27 d4 b3 27 2c 0a 20 20 27 d5 a4 27 20 3d 3e 20 27 d4 b4 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d2c0 | 20 20 27 d5 a5 27 20 3d 3e 20 27 d4 b5 27 2c 0a 20 20 27 d5 a6 27 20 3d 3e 20 27 d4 b6 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d2e0 | 20 20 27 d5 a7 27 20 3d 3e 20 27 d4 b7 27 2c 0a 20 20 27 d5 a8 27 20 3d 3e 20 27 d4 b8 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d300 | 20 20 27 d5 a9 27 20 3d 3e 20 27 d4 b9 27 2c 0a 20 20 27 d5 aa 27 20 3d 3e 20 27 d4 ba 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d320 | 20 20 27 d5 ab 27 20 3d 3e 20 27 d4 bb 27 2c 0a 20 20 27 d5 ac 27 20 3d 3e 20 27 d4 bc 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d340 | 20 20 27 d5 ad 27 20 3d 3e 20 27 d4 bd 27 2c 0a 20 20 27 d5 ae 27 20 3d 3e 20 27 d4 be 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d360 | 20 20 27 d5 af 27 20 3d 3e 20 27 d4 bf 27 2c 0a 20 20 27 d5 b0 27 20 3d 3e 20 27 d5 80 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d380 | 20 20 27 d5 b1 27 20 3d 3e 20 27 d5 81 27 2c 0a 20 20 27 d5 b2 27 20 3d 3e 20 27 d5 82 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d3a0 | 20 20 27 d5 b3 27 20 3d 3e 20 27 d5 83 27 2c 0a 20 20 27 d5 b4 27 20 3d 3e 20 27 d5 84 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d3c0 | 20 20 27 d5 b5 27 20 3d 3e 20 27 d5 85 27 2c 0a 20 20 27 d5 b6 27 20 3d 3e 20 27 d5 86 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d3e0 | 20 20 27 d5 b7 27 20 3d 3e 20 27 d5 87 27 2c 0a 20 20 27 d5 b8 27 20 3d 3e 20 27 d5 88 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d400 | 20 20 27 d5 b9 27 20 3d 3e 20 27 d5 89 27 2c 0a 20 20 27 d5 ba 27 20 3d 3e 20 27 d5 8a 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d420 | 20 20 27 d5 bb 27 20 3d 3e 20 27 d5 8b 27 2c 0a 20 20 27 d5 bc 27 20 3d 3e 20 27 d5 8c 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d440 | 20 20 27 d5 bd 27 20 3d 3e 20 27 d5 8d 27 2c 0a 20 20 27 d5 be 27 20 3d 3e 20 27 d5 8e 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d460 | 20 20 27 d5 bf 27 20 3d 3e 20 27 d5 8f 27 2c 0a 20 20 27 d6 80 27 20 3d 3e 20 27 d5 90 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d480 | 20 20 27 d6 81 27 20 3d 3e 20 27 d5 91 27 2c 0a 20 20 27 d6 82 27 20 3d 3e 20 27 d5 92 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d4a0 | 20 20 27 d6 83 27 20 3d 3e 20 27 d5 93 27 2c 0a 20 20 27 d6 84 27 20 3d 3e 20 27 d5 94 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d4c0 | 20 20 27 d6 85 27 20 3d 3e 20 27 d5 95 27 2c 0a 20 20 27 d6 86 27 20 3d 3e 20 27 d5 96 27 2c 0a | ..'..'.=>.'..',...'..'.=>.'..',. |
2d4e0 | 20 20 27 e1 b5 b9 27 20 3d 3e 20 27 ea 9d bd 27 2c 0a 20 20 27 e1 b5 bd 27 20 3d 3e 20 27 e2 b1 | ..'...'.=>.'...',...'...'.=>.'.. |
2d500 | a3 27 2c 0a 20 20 27 e1 b8 81 27 20 3d 3e 20 27 e1 b8 80 27 2c 0a 20 20 27 e1 b8 83 27 20 3d 3e | .',...'...'.=>.'...',...'...'.=> |
2d520 | 20 27 e1 b8 82 27 2c 0a 20 20 27 e1 b8 85 27 20 3d 3e 20 27 e1 b8 84 27 2c 0a 20 20 27 e1 b8 87 | .'...',...'...'.=>.'...',...'... |
2d540 | 27 20 3d 3e 20 27 e1 b8 86 27 2c 0a 20 20 27 e1 b8 89 27 20 3d 3e 20 27 e1 b8 88 27 2c 0a 20 20 | '.=>.'...',...'...'.=>.'...',... |
2d560 | 27 e1 b8 8b 27 20 3d 3e 20 27 e1 b8 8a 27 2c 0a 20 20 27 e1 b8 8d 27 20 3d 3e 20 27 e1 b8 8c 27 | '...'.=>.'...',...'...'.=>.'...' |
2d580 | 2c 0a 20 20 27 e1 b8 8f 27 20 3d 3e 20 27 e1 b8 8e 27 2c 0a 20 20 27 e1 b8 91 27 20 3d 3e 20 27 | ,...'...'.=>.'...',...'...'.=>.' |
2d5a0 | e1 b8 90 27 2c 0a 20 20 27 e1 b8 93 27 20 3d 3e 20 27 e1 b8 92 27 2c 0a 20 20 27 e1 b8 95 27 20 | ...',...'...'.=>.'...',...'...'. |
2d5c0 | 3d 3e 20 27 e1 b8 94 27 2c 0a 20 20 27 e1 b8 97 27 20 3d 3e 20 27 e1 b8 96 27 2c 0a 20 20 27 e1 | =>.'...',...'...'.=>.'...',...'. |
2d5e0 | b8 99 27 20 3d 3e 20 27 e1 b8 98 27 2c 0a 20 20 27 e1 b8 9b 27 20 3d 3e 20 27 e1 b8 9a 27 2c 0a | ..'.=>.'...',...'...'.=>.'...',. |
2d600 | 20 20 27 e1 b8 9d 27 20 3d 3e 20 27 e1 b8 9c 27 2c 0a 20 20 27 e1 b8 9f 27 20 3d 3e 20 27 e1 b8 | ..'...'.=>.'...',...'...'.=>.'.. |
2d620 | 9e 27 2c 0a 20 20 27 e1 b8 a1 27 20 3d 3e 20 27 e1 b8 a0 27 2c 0a 20 20 27 e1 b8 a3 27 20 3d 3e | .',...'...'.=>.'...',...'...'.=> |
2d640 | 20 27 e1 b8 a2 27 2c 0a 20 20 27 e1 b8 a5 27 20 3d 3e 20 27 e1 b8 a4 27 2c 0a 20 20 27 e1 b8 a7 | .'...',...'...'.=>.'...',...'... |
2d660 | 27 20 3d 3e 20 27 e1 b8 a6 27 2c 0a 20 20 27 e1 b8 a9 27 20 3d 3e 20 27 e1 b8 a8 27 2c 0a 20 20 | '.=>.'...',...'...'.=>.'...',... |
2d680 | 27 e1 b8 ab 27 20 3d 3e 20 27 e1 b8 aa 27 2c 0a 20 20 27 e1 b8 ad 27 20 3d 3e 20 27 e1 b8 ac 27 | '...'.=>.'...',...'...'.=>.'...' |
2d6a0 | 2c 0a 20 20 27 e1 b8 af 27 20 3d 3e 20 27 e1 b8 ae 27 2c 0a 20 20 27 e1 b8 b1 27 20 3d 3e 20 27 | ,...'...'.=>.'...',...'...'.=>.' |
2d6c0 | e1 b8 b0 27 2c 0a 20 20 27 e1 b8 b3 27 20 3d 3e 20 27 e1 b8 b2 27 2c 0a 20 20 27 e1 b8 b5 27 20 | ...',...'...'.=>.'...',...'...'. |
2d6e0 | 3d 3e 20 27 e1 b8 b4 27 2c 0a 20 20 27 e1 b8 b7 27 20 3d 3e 20 27 e1 b8 b6 27 2c 0a 20 20 27 e1 | =>.'...',...'...'.=>.'...',...'. |
2d700 | b8 b9 27 20 3d 3e 20 27 e1 b8 b8 27 2c 0a 20 20 27 e1 b8 bb 27 20 3d 3e 20 27 e1 b8 ba 27 2c 0a | ..'.=>.'...',...'...'.=>.'...',. |
2d720 | 20 20 27 e1 b8 bd 27 20 3d 3e 20 27 e1 b8 bc 27 2c 0a 20 20 27 e1 b8 bf 27 20 3d 3e 20 27 e1 b8 | ..'...'.=>.'...',...'...'.=>.'.. |
2d740 | be 27 2c 0a 20 20 27 e1 b9 81 27 20 3d 3e 20 27 e1 b9 80 27 2c 0a 20 20 27 e1 b9 83 27 20 3d 3e | .',...'...'.=>.'...',...'...'.=> |
2d760 | 20 27 e1 b9 82 27 2c 0a 20 20 27 e1 b9 85 27 20 3d 3e 20 27 e1 b9 84 27 2c 0a 20 20 27 e1 b9 87 | .'...',...'...'.=>.'...',...'... |
2d780 | 27 20 3d 3e 20 27 e1 b9 86 27 2c 0a 20 20 27 e1 b9 89 27 20 3d 3e 20 27 e1 b9 88 27 2c 0a 20 20 | '.=>.'...',...'...'.=>.'...',... |
2d7a0 | 27 e1 b9 8b 27 20 3d 3e 20 27 e1 b9 8a 27 2c 0a 20 20 27 e1 b9 8d 27 20 3d 3e 20 27 e1 b9 8c 27 | '...'.=>.'...',...'...'.=>.'...' |
2d7c0 | 2c 0a 20 20 27 e1 b9 8f 27 20 3d 3e 20 27 e1 b9 8e 27 2c 0a 20 20 27 e1 b9 91 27 20 3d 3e 20 27 | ,...'...'.=>.'...',...'...'.=>.' |
2d7e0 | e1 b9 90 27 2c 0a 20 20 27 e1 b9 93 27 20 3d 3e 20 27 e1 b9 92 27 2c 0a 20 20 27 e1 b9 95 27 20 | ...',...'...'.=>.'...',...'...'. |
2d800 | 3d 3e 20 27 e1 b9 94 27 2c 0a 20 20 27 e1 b9 97 27 20 3d 3e 20 27 e1 b9 96 27 2c 0a 20 20 27 e1 | =>.'...',...'...'.=>.'...',...'. |
2d820 | b9 99 27 20 3d 3e 20 27 e1 b9 98 27 2c 0a 20 20 27 e1 b9 9b 27 20 3d 3e 20 27 e1 b9 9a 27 2c 0a | ..'.=>.'...',...'...'.=>.'...',. |
2d840 | 20 20 27 e1 b9 9d 27 20 3d 3e 20 27 e1 b9 9c 27 2c 0a 20 20 27 e1 b9 9f 27 20 3d 3e 20 27 e1 b9 | ..'...'.=>.'...',...'...'.=>.'.. |
2d860 | 9e 27 2c 0a 20 20 27 e1 b9 a1 27 20 3d 3e 20 27 e1 b9 a0 27 2c 0a 20 20 27 e1 b9 a3 27 20 3d 3e | .',...'...'.=>.'...',...'...'.=> |
2d880 | 20 27 e1 b9 a2 27 2c 0a 20 20 27 e1 b9 a5 27 20 3d 3e 20 27 e1 b9 a4 27 2c 0a 20 20 27 e1 b9 a7 | .'...',...'...'.=>.'...',...'... |
2d8a0 | 27 20 3d 3e 20 27 e1 b9 a6 27 2c 0a 20 20 27 e1 b9 a9 27 20 3d 3e 20 27 e1 b9 a8 27 2c 0a 20 20 | '.=>.'...',...'...'.=>.'...',... |
2d8c0 | 27 e1 b9 ab 27 20 3d 3e 20 27 e1 b9 aa 27 2c 0a 20 20 27 e1 b9 ad 27 20 3d 3e 20 27 e1 b9 ac 27 | '...'.=>.'...',...'...'.=>.'...' |
2d8e0 | 2c 0a 20 20 27 e1 b9 af 27 20 3d 3e 20 27 e1 b9 ae 27 2c 0a 20 20 27 e1 b9 b1 27 20 3d 3e 20 27 | ,...'...'.=>.'...',...'...'.=>.' |
2d900 | e1 b9 b0 27 2c 0a 20 20 27 e1 b9 b3 27 20 3d 3e 20 27 e1 b9 b2 27 2c 0a 20 20 27 e1 b9 b5 27 20 | ...',...'...'.=>.'...',...'...'. |
2d920 | 3d 3e 20 27 e1 b9 b4 27 2c 0a 20 20 27 e1 b9 b7 27 20 3d 3e 20 27 e1 b9 b6 27 2c 0a 20 20 27 e1 | =>.'...',...'...'.=>.'...',...'. |
2d940 | b9 b9 27 20 3d 3e 20 27 e1 b9 b8 27 2c 0a 20 20 27 e1 b9 bb 27 20 3d 3e 20 27 e1 b9 ba 27 2c 0a | ..'.=>.'...',...'...'.=>.'...',. |
2d960 | 20 20 27 e1 b9 bd 27 20 3d 3e 20 27 e1 b9 bc 27 2c 0a 20 20 27 e1 b9 bf 27 20 3d 3e 20 27 e1 b9 | ..'...'.=>.'...',...'...'.=>.'.. |
2d980 | be 27 2c 0a 20 20 27 e1 ba 81 27 20 3d 3e 20 27 e1 ba 80 27 2c 0a 20 20 27 e1 ba 83 27 20 3d 3e | .',...'...'.=>.'...',...'...'.=> |
2d9a0 | 20 27 e1 ba 82 27 2c 0a 20 20 27 e1 ba 85 27 20 3d 3e 20 27 e1 ba 84 27 2c 0a 20 20 27 e1 ba 87 | .'...',...'...'.=>.'...',...'... |
2d9c0 | 27 20 3d 3e 20 27 e1 ba 86 27 2c 0a 20 20 27 e1 ba 89 27 20 3d 3e 20 27 e1 ba 88 27 2c 0a 20 20 | '.=>.'...',...'...'.=>.'...',... |
2d9e0 | 27 e1 ba 8b 27 20 3d 3e 20 27 e1 ba 8a 27 2c 0a 20 20 27 e1 ba 8d 27 20 3d 3e 20 27 e1 ba 8c 27 | '...'.=>.'...',...'...'.=>.'...' |
2da00 | 2c 0a 20 20 27 e1 ba 8f 27 20 3d 3e 20 27 e1 ba 8e 27 2c 0a 20 20 27 e1 ba 91 27 20 3d 3e 20 27 | ,...'...'.=>.'...',...'...'.=>.' |
2da20 | e1 ba 90 27 2c 0a 20 20 27 e1 ba 93 27 20 3d 3e 20 27 e1 ba 92 27 2c 0a 20 20 27 e1 ba 95 27 20 | ...',...'...'.=>.'...',...'...'. |
2da40 | 3d 3e 20 27 e1 ba 94 27 2c 0a 20 20 27 e1 ba 9b 27 20 3d 3e 20 27 e1 b9 a0 27 2c 0a 20 20 27 e1 | =>.'...',...'...'.=>.'...',...'. |
2da60 | ba a1 27 20 3d 3e 20 27 e1 ba a0 27 2c 0a 20 20 27 e1 ba a3 27 20 3d 3e 20 27 e1 ba a2 27 2c 0a | ..'.=>.'...',...'...'.=>.'...',. |
2da80 | 20 20 27 e1 ba a5 27 20 3d 3e 20 27 e1 ba a4 27 2c 0a 20 20 27 e1 ba a7 27 20 3d 3e 20 27 e1 ba | ..'...'.=>.'...',...'...'.=>.'.. |
2daa0 | a6 27 2c 0a 20 20 27 e1 ba a9 27 20 3d 3e 20 27 e1 ba a8 27 2c 0a 20 20 27 e1 ba ab 27 20 3d 3e | .',...'...'.=>.'...',...'...'.=> |
2dac0 | 20 27 e1 ba aa 27 2c 0a 20 20 27 e1 ba ad 27 20 3d 3e 20 27 e1 ba ac 27 2c 0a 20 20 27 e1 ba af | .'...',...'...'.=>.'...',...'... |
2dae0 | 27 20 3d 3e 20 27 e1 ba ae 27 2c 0a 20 20 27 e1 ba b1 27 20 3d 3e 20 27 e1 ba b0 27 2c 0a 20 20 | '.=>.'...',...'...'.=>.'...',... |
2db00 | 27 e1 ba b3 27 20 3d 3e 20 27 e1 ba b2 27 2c 0a 20 20 27 e1 ba b5 27 20 3d 3e 20 27 e1 ba b4 27 | '...'.=>.'...',...'...'.=>.'...' |
2db20 | 2c 0a 20 20 27 e1 ba b7 27 20 3d 3e 20 27 e1 ba b6 27 2c 0a 20 20 27 e1 ba b9 27 20 3d 3e 20 27 | ,...'...'.=>.'...',...'...'.=>.' |
2db40 | e1 ba b8 27 2c 0a 20 20 27 e1 ba bb 27 20 3d 3e 20 27 e1 ba ba 27 2c 0a 20 20 27 e1 ba bd 27 20 | ...',...'...'.=>.'...',...'...'. |
2db60 | 3d 3e 20 27 e1 ba bc 27 2c 0a 20 20 27 e1 ba bf 27 20 3d 3e 20 27 e1 ba be 27 2c 0a 20 20 27 e1 | =>.'...',...'...'.=>.'...',...'. |
2db80 | bb 81 27 20 3d 3e 20 27 e1 bb 80 27 2c 0a 20 20 27 e1 bb 83 27 20 3d 3e 20 27 e1 bb 82 27 2c 0a | ..'.=>.'...',...'...'.=>.'...',. |
2dba0 | 20 20 27 e1 bb 85 27 20 3d 3e 20 27 e1 bb 84 27 2c 0a 20 20 27 e1 bb 87 27 20 3d 3e 20 27 e1 bb | ..'...'.=>.'...',...'...'.=>.'.. |
2dbc0 | 86 27 2c 0a 20 20 27 e1 bb 89 27 20 3d 3e 20 27 e1 bb 88 27 2c 0a 20 20 27 e1 bb 8b 27 20 3d 3e | .',...'...'.=>.'...',...'...'.=> |
2dbe0 | 20 27 e1 bb 8a 27 2c 0a 20 20 27 e1 bb 8d 27 20 3d 3e 20 27 e1 bb 8c 27 2c 0a 20 20 27 e1 bb 8f | .'...',...'...'.=>.'...',...'... |
2dc00 | 27 20 3d 3e 20 27 e1 bb 8e 27 2c 0a 20 20 27 e1 bb 91 27 20 3d 3e 20 27 e1 bb 90 27 2c 0a 20 20 | '.=>.'...',...'...'.=>.'...',... |
2dc20 | 27 e1 bb 93 27 20 3d 3e 20 27 e1 bb 92 27 2c 0a 20 20 27 e1 bb 95 27 20 3d 3e 20 27 e1 bb 94 27 | '...'.=>.'...',...'...'.=>.'...' |
2dc40 | 2c 0a 20 20 27 e1 bb 97 27 20 3d 3e 20 27 e1 bb 96 27 2c 0a 20 20 27 e1 bb 99 27 20 3d 3e 20 27 | ,...'...'.=>.'...',...'...'.=>.' |
2dc60 | e1 bb 98 27 2c 0a 20 20 27 e1 bb 9b 27 20 3d 3e 20 27 e1 bb 9a 27 2c 0a 20 20 27 e1 bb 9d 27 20 | ...',...'...'.=>.'...',...'...'. |
2dc80 | 3d 3e 20 27 e1 bb 9c 27 2c 0a 20 20 27 e1 bb 9f 27 20 3d 3e 20 27 e1 bb 9e 27 2c 0a 20 20 27 e1 | =>.'...',...'...'.=>.'...',...'. |
2dca0 | bb a1 27 20 3d 3e 20 27 e1 bb a0 27 2c 0a 20 20 27 e1 bb a3 27 20 3d 3e 20 27 e1 bb a2 27 2c 0a | ..'.=>.'...',...'...'.=>.'...',. |
2dcc0 | 20 20 27 e1 bb a5 27 20 3d 3e 20 27 e1 bb a4 27 2c 0a 20 20 27 e1 bb a7 27 20 3d 3e 20 27 e1 bb | ..'...'.=>.'...',...'...'.=>.'.. |
2dce0 | a6 27 2c 0a 20 20 27 e1 bb a9 27 20 3d 3e 20 27 e1 bb a8 27 2c 0a 20 20 27 e1 bb ab 27 20 3d 3e | .',...'...'.=>.'...',...'...'.=> |
2dd00 | 20 27 e1 bb aa 27 2c 0a 20 20 27 e1 bb ad 27 20 3d 3e 20 27 e1 bb ac 27 2c 0a 20 20 27 e1 bb af | .'...',...'...'.=>.'...',...'... |
2dd20 | 27 20 3d 3e 20 27 e1 bb ae 27 2c 0a 20 20 27 e1 bb b1 27 20 3d 3e 20 27 e1 bb b0 27 2c 0a 20 20 | '.=>.'...',...'...'.=>.'...',... |
2dd40 | 27 e1 bb b3 27 20 3d 3e 20 27 e1 bb b2 27 2c 0a 20 20 27 e1 bb b5 27 20 3d 3e 20 27 e1 bb b4 27 | '...'.=>.'...',...'...'.=>.'...' |
2dd60 | 2c 0a 20 20 27 e1 bb b7 27 20 3d 3e 20 27 e1 bb b6 27 2c 0a 20 20 27 e1 bb b9 27 20 3d 3e 20 27 | ,...'...'.=>.'...',...'...'.=>.' |
2dd80 | e1 bb b8 27 2c 0a 20 20 27 e1 bb bb 27 20 3d 3e 20 27 e1 bb ba 27 2c 0a 20 20 27 e1 bb bd 27 20 | ...',...'...'.=>.'...',...'...'. |
2dda0 | 3d 3e 20 27 e1 bb bc 27 2c 0a 20 20 27 e1 bb bf 27 20 3d 3e 20 27 e1 bb be 27 2c 0a 20 20 27 e1 | =>.'...',...'...'.=>.'...',...'. |
2ddc0 | bc 80 27 20 3d 3e 20 27 e1 bc 88 27 2c 0a 20 20 27 e1 bc 81 27 20 3d 3e 20 27 e1 bc 89 27 2c 0a | ..'.=>.'...',...'...'.=>.'...',. |
2dde0 | 20 20 27 e1 bc 82 27 20 3d 3e 20 27 e1 bc 8a 27 2c 0a 20 20 27 e1 bc 83 27 20 3d 3e 20 27 e1 bc | ..'...'.=>.'...',...'...'.=>.'.. |
2de00 | 8b 27 2c 0a 20 20 27 e1 bc 84 27 20 3d 3e 20 27 e1 bc 8c 27 2c 0a 20 20 27 e1 bc 85 27 20 3d 3e | .',...'...'.=>.'...',...'...'.=> |
2de20 | 20 27 e1 bc 8d 27 2c 0a 20 20 27 e1 bc 86 27 20 3d 3e 20 27 e1 bc 8e 27 2c 0a 20 20 27 e1 bc 87 | .'...',...'...'.=>.'...',...'... |
2de40 | 27 20 3d 3e 20 27 e1 bc 8f 27 2c 0a 20 20 27 e1 bc 90 27 20 3d 3e 20 27 e1 bc 98 27 2c 0a 20 20 | '.=>.'...',...'...'.=>.'...',... |
2de60 | 27 e1 bc 91 27 20 3d 3e 20 27 e1 bc 99 27 2c 0a 20 20 27 e1 bc 92 27 20 3d 3e 20 27 e1 bc 9a 27 | '...'.=>.'...',...'...'.=>.'...' |
2de80 | 2c 0a 20 20 27 e1 bc 93 27 20 3d 3e 20 27 e1 bc 9b 27 2c 0a 20 20 27 e1 bc 94 27 20 3d 3e 20 27 | ,...'...'.=>.'...',...'...'.=>.' |
2dea0 | e1 bc 9c 27 2c 0a 20 20 27 e1 bc 95 27 20 3d 3e 20 27 e1 bc 9d 27 2c 0a 20 20 27 e1 bc a0 27 20 | ...',...'...'.=>.'...',...'...'. |
2dec0 | 3d 3e 20 27 e1 bc a8 27 2c 0a 20 20 27 e1 bc a1 27 20 3d 3e 20 27 e1 bc a9 27 2c 0a 20 20 27 e1 | =>.'...',...'...'.=>.'...',...'. |
2dee0 | bc a2 27 20 3d 3e 20 27 e1 bc aa 27 2c 0a 20 20 27 e1 bc a3 27 20 3d 3e 20 27 e1 bc ab 27 2c 0a | ..'.=>.'...',...'...'.=>.'...',. |
2df00 | 20 20 27 e1 bc a4 27 20 3d 3e 20 27 e1 bc ac 27 2c 0a 20 20 27 e1 bc a5 27 20 3d 3e 20 27 e1 bc | ..'...'.=>.'...',...'...'.=>.'.. |
2df20 | ad 27 2c 0a 20 20 27 e1 bc a6 27 20 3d 3e 20 27 e1 bc ae 27 2c 0a 20 20 27 e1 bc a7 27 20 3d 3e | .',...'...'.=>.'...',...'...'.=> |
2df40 | 20 27 e1 bc af 27 2c 0a 20 20 27 e1 bc b0 27 20 3d 3e 20 27 e1 bc b8 27 2c 0a 20 20 27 e1 bc b1 | .'...',...'...'.=>.'...',...'... |
2df60 | 27 20 3d 3e 20 27 e1 bc b9 27 2c 0a 20 20 27 e1 bc b2 27 20 3d 3e 20 27 e1 bc ba 27 2c 0a 20 20 | '.=>.'...',...'...'.=>.'...',... |
2df80 | 27 e1 bc b3 27 20 3d 3e 20 27 e1 bc bb 27 2c 0a 20 20 27 e1 bc b4 27 20 3d 3e 20 27 e1 bc bc 27 | '...'.=>.'...',...'...'.=>.'...' |
2dfa0 | 2c 0a 20 20 27 e1 bc b5 27 20 3d 3e 20 27 e1 bc bd 27 2c 0a 20 20 27 e1 bc b6 27 20 3d 3e 20 27 | ,...'...'.=>.'...',...'...'.=>.' |
2dfc0 | e1 bc be 27 2c 0a 20 20 27 e1 bc b7 27 20 3d 3e 20 27 e1 bc bf 27 2c 0a 20 20 27 e1 bd 80 27 20 | ...',...'...'.=>.'...',...'...'. |
2dfe0 | 3d 3e 20 27 e1 bd 88 27 2c 0a 20 20 27 e1 bd 81 27 20 3d 3e 20 27 e1 bd 89 27 2c 0a 20 20 27 e1 | =>.'...',...'...'.=>.'...',...'. |
2e000 | bd 82 27 20 3d 3e 20 27 e1 bd 8a 27 2c 0a 20 20 27 e1 bd 83 27 20 3d 3e 20 27 e1 bd 8b 27 2c 0a | ..'.=>.'...',...'...'.=>.'...',. |
2e020 | 20 20 27 e1 bd 84 27 20 3d 3e 20 27 e1 bd 8c 27 2c 0a 20 20 27 e1 bd 85 27 20 3d 3e 20 27 e1 bd | ..'...'.=>.'...',...'...'.=>.'.. |
2e040 | 8d 27 2c 0a 20 20 27 e1 bd 91 27 20 3d 3e 20 27 e1 bd 99 27 2c 0a 20 20 27 e1 bd 93 27 20 3d 3e | .',...'...'.=>.'...',...'...'.=> |
2e060 | 20 27 e1 bd 9b 27 2c 0a 20 20 27 e1 bd 95 27 20 3d 3e 20 27 e1 bd 9d 27 2c 0a 20 20 27 e1 bd 97 | .'...',...'...'.=>.'...',...'... |
2e080 | 27 20 3d 3e 20 27 e1 bd 9f 27 2c 0a 20 20 27 e1 bd a0 27 20 3d 3e 20 27 e1 bd a8 27 2c 0a 20 20 | '.=>.'...',...'...'.=>.'...',... |
2e0a0 | 27 e1 bd a1 27 20 3d 3e 20 27 e1 bd a9 27 2c 0a 20 20 27 e1 bd a2 27 20 3d 3e 20 27 e1 bd aa 27 | '...'.=>.'...',...'...'.=>.'...' |
2e0c0 | 2c 0a 20 20 27 e1 bd a3 27 20 3d 3e 20 27 e1 bd ab 27 2c 0a 20 20 27 e1 bd a4 27 20 3d 3e 20 27 | ,...'...'.=>.'...',...'...'.=>.' |
2e0e0 | e1 bd ac 27 2c 0a 20 20 27 e1 bd a5 27 20 3d 3e 20 27 e1 bd ad 27 2c 0a 20 20 27 e1 bd a6 27 20 | ...',...'...'.=>.'...',...'...'. |
2e100 | 3d 3e 20 27 e1 bd ae 27 2c 0a 20 20 27 e1 bd a7 27 20 3d 3e 20 27 e1 bd af 27 2c 0a 20 20 27 e1 | =>.'...',...'...'.=>.'...',...'. |
2e120 | bd b0 27 20 3d 3e 20 27 e1 be ba 27 2c 0a 20 20 27 e1 bd b1 27 20 3d 3e 20 27 e1 be bb 27 2c 0a | ..'.=>.'...',...'...'.=>.'...',. |
2e140 | 20 20 27 e1 bd b2 27 20 3d 3e 20 27 e1 bf 88 27 2c 0a 20 20 27 e1 bd b3 27 20 3d 3e 20 27 e1 bf | ..'...'.=>.'...',...'...'.=>.'.. |
2e160 | 89 27 2c 0a 20 20 27 e1 bd b4 27 20 3d 3e 20 27 e1 bf 8a 27 2c 0a 20 20 27 e1 bd b5 27 20 3d 3e | .',...'...'.=>.'...',...'...'.=> |
2e180 | 20 27 e1 bf 8b 27 2c 0a 20 20 27 e1 bd b6 27 20 3d 3e 20 27 e1 bf 9a 27 2c 0a 20 20 27 e1 bd b7 | .'...',...'...'.=>.'...',...'... |
2e1a0 | 27 20 3d 3e 20 27 e1 bf 9b 27 2c 0a 20 20 27 e1 bd b8 27 20 3d 3e 20 27 e1 bf b8 27 2c 0a 20 20 | '.=>.'...',...'...'.=>.'...',... |
2e1c0 | 27 e1 bd b9 27 20 3d 3e 20 27 e1 bf b9 27 2c 0a 20 20 27 e1 bd ba 27 20 3d 3e 20 27 e1 bf aa 27 | '...'.=>.'...',...'...'.=>.'...' |
2e1e0 | 2c 0a 20 20 27 e1 bd bb 27 20 3d 3e 20 27 e1 bf ab 27 2c 0a 20 20 27 e1 bd bc 27 20 3d 3e 20 27 | ,...'...'.=>.'...',...'...'.=>.' |
2e200 | e1 bf ba 27 2c 0a 20 20 27 e1 bd bd 27 20 3d 3e 20 27 e1 bf bb 27 2c 0a 20 20 27 e1 be 80 27 20 | ...',...'...'.=>.'...',...'...'. |
2e220 | 3d 3e 20 27 e1 be 88 27 2c 0a 20 20 27 e1 be 81 27 20 3d 3e 20 27 e1 be 89 27 2c 0a 20 20 27 e1 | =>.'...',...'...'.=>.'...',...'. |
2e240 | be 82 27 20 3d 3e 20 27 e1 be 8a 27 2c 0a 20 20 27 e1 be 83 27 20 3d 3e 20 27 e1 be 8b 27 2c 0a | ..'.=>.'...',...'...'.=>.'...',. |
2e260 | 20 20 27 e1 be 84 27 20 3d 3e 20 27 e1 be 8c 27 2c 0a 20 20 27 e1 be 85 27 20 3d 3e 20 27 e1 be | ..'...'.=>.'...',...'...'.=>.'.. |
2e280 | 8d 27 2c 0a 20 20 27 e1 be 86 27 20 3d 3e 20 27 e1 be 8e 27 2c 0a 20 20 27 e1 be 87 27 20 3d 3e | .',...'...'.=>.'...',...'...'.=> |
2e2a0 | 20 27 e1 be 8f 27 2c 0a 20 20 27 e1 be 90 27 20 3d 3e 20 27 e1 be 98 27 2c 0a 20 20 27 e1 be 91 | .'...',...'...'.=>.'...',...'... |
2e2c0 | 27 20 3d 3e 20 27 e1 be 99 27 2c 0a 20 20 27 e1 be 92 27 20 3d 3e 20 27 e1 be 9a 27 2c 0a 20 20 | '.=>.'...',...'...'.=>.'...',... |
2e2e0 | 27 e1 be 93 27 20 3d 3e 20 27 e1 be 9b 27 2c 0a 20 20 27 e1 be 94 27 20 3d 3e 20 27 e1 be 9c 27 | '...'.=>.'...',...'...'.=>.'...' |
2e300 | 2c 0a 20 20 27 e1 be 95 27 20 3d 3e 20 27 e1 be 9d 27 2c 0a 20 20 27 e1 be 96 27 20 3d 3e 20 27 | ,...'...'.=>.'...',...'...'.=>.' |
2e320 | e1 be 9e 27 2c 0a 20 20 27 e1 be 97 27 20 3d 3e 20 27 e1 be 9f 27 2c 0a 20 20 27 e1 be a0 27 20 | ...',...'...'.=>.'...',...'...'. |
2e340 | 3d 3e 20 27 e1 be a8 27 2c 0a 20 20 27 e1 be a1 27 20 3d 3e 20 27 e1 be a9 27 2c 0a 20 20 27 e1 | =>.'...',...'...'.=>.'...',...'. |
2e360 | be a2 27 20 3d 3e 20 27 e1 be aa 27 2c 0a 20 20 27 e1 be a3 27 20 3d 3e 20 27 e1 be ab 27 2c 0a | ..'.=>.'...',...'...'.=>.'...',. |
2e380 | 20 20 27 e1 be a4 27 20 3d 3e 20 27 e1 be ac 27 2c 0a 20 20 27 e1 be a5 27 20 3d 3e 20 27 e1 be | ..'...'.=>.'...',...'...'.=>.'.. |
2e3a0 | ad 27 2c 0a 20 20 27 e1 be a6 27 20 3d 3e 20 27 e1 be ae 27 2c 0a 20 20 27 e1 be a7 27 20 3d 3e | .',...'...'.=>.'...',...'...'.=> |
2e3c0 | 20 27 e1 be af 27 2c 0a 20 20 27 e1 be b0 27 20 3d 3e 20 27 e1 be b8 27 2c 0a 20 20 27 e1 be b1 | .'...',...'...'.=>.'...',...'... |
2e3e0 | 27 20 3d 3e 20 27 e1 be b9 27 2c 0a 20 20 27 e1 be b3 27 20 3d 3e 20 27 e1 be bc 27 2c 0a 20 20 | '.=>.'...',...'...'.=>.'...',... |
2e400 | 27 e1 be be 27 20 3d 3e 20 27 ce 99 27 2c 0a 20 20 27 e1 bf 83 27 20 3d 3e 20 27 e1 bf 8c 27 2c | '...'.=>.'..',...'...'.=>.'...', |
2e420 | 0a 20 20 27 e1 bf 90 27 20 3d 3e 20 27 e1 bf 98 27 2c 0a 20 20 27 e1 bf 91 27 20 3d 3e 20 27 e1 | ...'...'.=>.'...',...'...'.=>.'. |
2e440 | bf 99 27 2c 0a 20 20 27 e1 bf a0 27 20 3d 3e 20 27 e1 bf a8 27 2c 0a 20 20 27 e1 bf a1 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
2e460 | 3e 20 27 e1 bf a9 27 2c 0a 20 20 27 e1 bf a5 27 20 3d 3e 20 27 e1 bf ac 27 2c 0a 20 20 27 e1 bf | >.'...',...'...'.=>.'...',...'.. |
2e480 | b3 27 20 3d 3e 20 27 e1 bf bc 27 2c 0a 20 20 27 e2 85 8e 27 20 3d 3e 20 27 e2 84 b2 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
2e4a0 | 20 27 e2 85 b0 27 20 3d 3e 20 27 e2 85 a0 27 2c 0a 20 20 27 e2 85 b1 27 20 3d 3e 20 27 e2 85 a1 | .'...'.=>.'...',...'...'.=>.'... |
2e4c0 | 27 2c 0a 20 20 27 e2 85 b2 27 20 3d 3e 20 27 e2 85 a2 27 2c 0a 20 20 27 e2 85 b3 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
2e4e0 | 27 e2 85 a3 27 2c 0a 20 20 27 e2 85 b4 27 20 3d 3e 20 27 e2 85 a4 27 2c 0a 20 20 27 e2 85 b5 27 | '...',...'...'.=>.'...',...'...' |
2e500 | 20 3d 3e 20 27 e2 85 a5 27 2c 0a 20 20 27 e2 85 b6 27 20 3d 3e 20 27 e2 85 a6 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
2e520 | e2 85 b7 27 20 3d 3e 20 27 e2 85 a7 27 2c 0a 20 20 27 e2 85 b8 27 20 3d 3e 20 27 e2 85 a8 27 2c | ...'.=>.'...',...'...'.=>.'...', |
2e540 | 0a 20 20 27 e2 85 b9 27 20 3d 3e 20 27 e2 85 a9 27 2c 0a 20 20 27 e2 85 ba 27 20 3d 3e 20 27 e2 | ...'...'.=>.'...',...'...'.=>.'. |
2e560 | 85 aa 27 2c 0a 20 20 27 e2 85 bb 27 20 3d 3e 20 27 e2 85 ab 27 2c 0a 20 20 27 e2 85 bc 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
2e580 | 3e 20 27 e2 85 ac 27 2c 0a 20 20 27 e2 85 bd 27 20 3d 3e 20 27 e2 85 ad 27 2c 0a 20 20 27 e2 85 | >.'...',...'...'.=>.'...',...'.. |
2e5a0 | be 27 20 3d 3e 20 27 e2 85 ae 27 2c 0a 20 20 27 e2 85 bf 27 20 3d 3e 20 27 e2 85 af 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
2e5c0 | 20 27 e2 86 84 27 20 3d 3e 20 27 e2 86 83 27 2c 0a 20 20 27 e2 93 90 27 20 3d 3e 20 27 e2 92 b6 | .'...'.=>.'...',...'...'.=>.'... |
2e5e0 | 27 2c 0a 20 20 27 e2 93 91 27 20 3d 3e 20 27 e2 92 b7 27 2c 0a 20 20 27 e2 93 92 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
2e600 | 27 e2 92 b8 27 2c 0a 20 20 27 e2 93 93 27 20 3d 3e 20 27 e2 92 b9 27 2c 0a 20 20 27 e2 93 94 27 | '...',...'...'.=>.'...',...'...' |
2e620 | 20 3d 3e 20 27 e2 92 ba 27 2c 0a 20 20 27 e2 93 95 27 20 3d 3e 20 27 e2 92 bb 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
2e640 | e2 93 96 27 20 3d 3e 20 27 e2 92 bc 27 2c 0a 20 20 27 e2 93 97 27 20 3d 3e 20 27 e2 92 bd 27 2c | ...'.=>.'...',...'...'.=>.'...', |
2e660 | 0a 20 20 27 e2 93 98 27 20 3d 3e 20 27 e2 92 be 27 2c 0a 20 20 27 e2 93 99 27 20 3d 3e 20 27 e2 | ...'...'.=>.'...',...'...'.=>.'. |
2e680 | 92 bf 27 2c 0a 20 20 27 e2 93 9a 27 20 3d 3e 20 27 e2 93 80 27 2c 0a 20 20 27 e2 93 9b 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
2e6a0 | 3e 20 27 e2 93 81 27 2c 0a 20 20 27 e2 93 9c 27 20 3d 3e 20 27 e2 93 82 27 2c 0a 20 20 27 e2 93 | >.'...',...'...'.=>.'...',...'.. |
2e6c0 | 9d 27 20 3d 3e 20 27 e2 93 83 27 2c 0a 20 20 27 e2 93 9e 27 20 3d 3e 20 27 e2 93 84 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
2e6e0 | 20 27 e2 93 9f 27 20 3d 3e 20 27 e2 93 85 27 2c 0a 20 20 27 e2 93 a0 27 20 3d 3e 20 27 e2 93 86 | .'...'.=>.'...',...'...'.=>.'... |
2e700 | 27 2c 0a 20 20 27 e2 93 a1 27 20 3d 3e 20 27 e2 93 87 27 2c 0a 20 20 27 e2 93 a2 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
2e720 | 27 e2 93 88 27 2c 0a 20 20 27 e2 93 a3 27 20 3d 3e 20 27 e2 93 89 27 2c 0a 20 20 27 e2 93 a4 27 | '...',...'...'.=>.'...',...'...' |
2e740 | 20 3d 3e 20 27 e2 93 8a 27 2c 0a 20 20 27 e2 93 a5 27 20 3d 3e 20 27 e2 93 8b 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
2e760 | e2 93 a6 27 20 3d 3e 20 27 e2 93 8c 27 2c 0a 20 20 27 e2 93 a7 27 20 3d 3e 20 27 e2 93 8d 27 2c | ...'.=>.'...',...'...'.=>.'...', |
2e780 | 0a 20 20 27 e2 93 a8 27 20 3d 3e 20 27 e2 93 8e 27 2c 0a 20 20 27 e2 93 a9 27 20 3d 3e 20 27 e2 | ...'...'.=>.'...',...'...'.=>.'. |
2e7a0 | 93 8f 27 2c 0a 20 20 27 e2 b0 b0 27 20 3d 3e 20 27 e2 b0 80 27 2c 0a 20 20 27 e2 b0 b1 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
2e7c0 | 3e 20 27 e2 b0 81 27 2c 0a 20 20 27 e2 b0 b2 27 20 3d 3e 20 27 e2 b0 82 27 2c 0a 20 20 27 e2 b0 | >.'...',...'...'.=>.'...',...'.. |
2e7e0 | b3 27 20 3d 3e 20 27 e2 b0 83 27 2c 0a 20 20 27 e2 b0 b4 27 20 3d 3e 20 27 e2 b0 84 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
2e800 | 20 27 e2 b0 b5 27 20 3d 3e 20 27 e2 b0 85 27 2c 0a 20 20 27 e2 b0 b6 27 20 3d 3e 20 27 e2 b0 86 | .'...'.=>.'...',...'...'.=>.'... |
2e820 | 27 2c 0a 20 20 27 e2 b0 b7 27 20 3d 3e 20 27 e2 b0 87 27 2c 0a 20 20 27 e2 b0 b8 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
2e840 | 27 e2 b0 88 27 2c 0a 20 20 27 e2 b0 b9 27 20 3d 3e 20 27 e2 b0 89 27 2c 0a 20 20 27 e2 b0 ba 27 | '...',...'...'.=>.'...',...'...' |
2e860 | 20 3d 3e 20 27 e2 b0 8a 27 2c 0a 20 20 27 e2 b0 bb 27 20 3d 3e 20 27 e2 b0 8b 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
2e880 | e2 b0 bc 27 20 3d 3e 20 27 e2 b0 8c 27 2c 0a 20 20 27 e2 b0 bd 27 20 3d 3e 20 27 e2 b0 8d 27 2c | ...'.=>.'...',...'...'.=>.'...', |
2e8a0 | 0a 20 20 27 e2 b0 be 27 20 3d 3e 20 27 e2 b0 8e 27 2c 0a 20 20 27 e2 b0 bf 27 20 3d 3e 20 27 e2 | ...'...'.=>.'...',...'...'.=>.'. |
2e8c0 | b0 8f 27 2c 0a 20 20 27 e2 b1 80 27 20 3d 3e 20 27 e2 b0 90 27 2c 0a 20 20 27 e2 b1 81 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
2e8e0 | 3e 20 27 e2 b0 91 27 2c 0a 20 20 27 e2 b1 82 27 20 3d 3e 20 27 e2 b0 92 27 2c 0a 20 20 27 e2 b1 | >.'...',...'...'.=>.'...',...'.. |
2e900 | 83 27 20 3d 3e 20 27 e2 b0 93 27 2c 0a 20 20 27 e2 b1 84 27 20 3d 3e 20 27 e2 b0 94 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
2e920 | 20 27 e2 b1 85 27 20 3d 3e 20 27 e2 b0 95 27 2c 0a 20 20 27 e2 b1 86 27 20 3d 3e 20 27 e2 b0 96 | .'...'.=>.'...',...'...'.=>.'... |
2e940 | 27 2c 0a 20 20 27 e2 b1 87 27 20 3d 3e 20 27 e2 b0 97 27 2c 0a 20 20 27 e2 b1 88 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
2e960 | 27 e2 b0 98 27 2c 0a 20 20 27 e2 b1 89 27 20 3d 3e 20 27 e2 b0 99 27 2c 0a 20 20 27 e2 b1 8a 27 | '...',...'...'.=>.'...',...'...' |
2e980 | 20 3d 3e 20 27 e2 b0 9a 27 2c 0a 20 20 27 e2 b1 8b 27 20 3d 3e 20 27 e2 b0 9b 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
2e9a0 | e2 b1 8c 27 20 3d 3e 20 27 e2 b0 9c 27 2c 0a 20 20 27 e2 b1 8d 27 20 3d 3e 20 27 e2 b0 9d 27 2c | ...'.=>.'...',...'...'.=>.'...', |
2e9c0 | 0a 20 20 27 e2 b1 8e 27 20 3d 3e 20 27 e2 b0 9e 27 2c 0a 20 20 27 e2 b1 8f 27 20 3d 3e 20 27 e2 | ...'...'.=>.'...',...'...'.=>.'. |
2e9e0 | b0 9f 27 2c 0a 20 20 27 e2 b1 90 27 20 3d 3e 20 27 e2 b0 a0 27 2c 0a 20 20 27 e2 b1 91 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
2ea00 | 3e 20 27 e2 b0 a1 27 2c 0a 20 20 27 e2 b1 92 27 20 3d 3e 20 27 e2 b0 a2 27 2c 0a 20 20 27 e2 b1 | >.'...',...'...'.=>.'...',...'.. |
2ea20 | 93 27 20 3d 3e 20 27 e2 b0 a3 27 2c 0a 20 20 27 e2 b1 94 27 20 3d 3e 20 27 e2 b0 a4 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
2ea40 | 20 27 e2 b1 95 27 20 3d 3e 20 27 e2 b0 a5 27 2c 0a 20 20 27 e2 b1 96 27 20 3d 3e 20 27 e2 b0 a6 | .'...'.=>.'...',...'...'.=>.'... |
2ea60 | 27 2c 0a 20 20 27 e2 b1 97 27 20 3d 3e 20 27 e2 b0 a7 27 2c 0a 20 20 27 e2 b1 98 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
2ea80 | 27 e2 b0 a8 27 2c 0a 20 20 27 e2 b1 99 27 20 3d 3e 20 27 e2 b0 a9 27 2c 0a 20 20 27 e2 b1 9a 27 | '...',...'...'.=>.'...',...'...' |
2eaa0 | 20 3d 3e 20 27 e2 b0 aa 27 2c 0a 20 20 27 e2 b1 9b 27 20 3d 3e 20 27 e2 b0 ab 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
2eac0 | e2 b1 9c 27 20 3d 3e 20 27 e2 b0 ac 27 2c 0a 20 20 27 e2 b1 9d 27 20 3d 3e 20 27 e2 b0 ad 27 2c | ...'.=>.'...',...'...'.=>.'...', |
2eae0 | 0a 20 20 27 e2 b1 9e 27 20 3d 3e 20 27 e2 b0 ae 27 2c 0a 20 20 27 e2 b1 a1 27 20 3d 3e 20 27 e2 | ...'...'.=>.'...',...'...'.=>.'. |
2eb00 | b1 a0 27 2c 0a 20 20 27 e2 b1 a5 27 20 3d 3e 20 27 c8 ba 27 2c 0a 20 20 27 e2 b1 a6 27 20 3d 3e | ..',...'...'.=>.'..',...'...'.=> |
2eb20 | 20 27 c8 be 27 2c 0a 20 20 27 e2 b1 a8 27 20 3d 3e 20 27 e2 b1 a7 27 2c 0a 20 20 27 e2 b1 aa 27 | .'..',...'...'.=>.'...',...'...' |
2eb40 | 20 3d 3e 20 27 e2 b1 a9 27 2c 0a 20 20 27 e2 b1 ac 27 20 3d 3e 20 27 e2 b1 ab 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
2eb60 | e2 b1 b3 27 20 3d 3e 20 27 e2 b1 b2 27 2c 0a 20 20 27 e2 b1 b6 27 20 3d 3e 20 27 e2 b1 b5 27 2c | ...'.=>.'...',...'...'.=>.'...', |
2eb80 | 0a 20 20 27 e2 b2 81 27 20 3d 3e 20 27 e2 b2 80 27 2c 0a 20 20 27 e2 b2 83 27 20 3d 3e 20 27 e2 | ...'...'.=>.'...',...'...'.=>.'. |
2eba0 | b2 82 27 2c 0a 20 20 27 e2 b2 85 27 20 3d 3e 20 27 e2 b2 84 27 2c 0a 20 20 27 e2 b2 87 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
2ebc0 | 3e 20 27 e2 b2 86 27 2c 0a 20 20 27 e2 b2 89 27 20 3d 3e 20 27 e2 b2 88 27 2c 0a 20 20 27 e2 b2 | >.'...',...'...'.=>.'...',...'.. |
2ebe0 | 8b 27 20 3d 3e 20 27 e2 b2 8a 27 2c 0a 20 20 27 e2 b2 8d 27 20 3d 3e 20 27 e2 b2 8c 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
2ec00 | 20 27 e2 b2 8f 27 20 3d 3e 20 27 e2 b2 8e 27 2c 0a 20 20 27 e2 b2 91 27 20 3d 3e 20 27 e2 b2 90 | .'...'.=>.'...',...'...'.=>.'... |
2ec20 | 27 2c 0a 20 20 27 e2 b2 93 27 20 3d 3e 20 27 e2 b2 92 27 2c 0a 20 20 27 e2 b2 95 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
2ec40 | 27 e2 b2 94 27 2c 0a 20 20 27 e2 b2 97 27 20 3d 3e 20 27 e2 b2 96 27 2c 0a 20 20 27 e2 b2 99 27 | '...',...'...'.=>.'...',...'...' |
2ec60 | 20 3d 3e 20 27 e2 b2 98 27 2c 0a 20 20 27 e2 b2 9b 27 20 3d 3e 20 27 e2 b2 9a 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
2ec80 | e2 b2 9d 27 20 3d 3e 20 27 e2 b2 9c 27 2c 0a 20 20 27 e2 b2 9f 27 20 3d 3e 20 27 e2 b2 9e 27 2c | ...'.=>.'...',...'...'.=>.'...', |
2eca0 | 0a 20 20 27 e2 b2 a1 27 20 3d 3e 20 27 e2 b2 a0 27 2c 0a 20 20 27 e2 b2 a3 27 20 3d 3e 20 27 e2 | ...'...'.=>.'...',...'...'.=>.'. |
2ecc0 | b2 a2 27 2c 0a 20 20 27 e2 b2 a5 27 20 3d 3e 20 27 e2 b2 a4 27 2c 0a 20 20 27 e2 b2 a7 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
2ece0 | 3e 20 27 e2 b2 a6 27 2c 0a 20 20 27 e2 b2 a9 27 20 3d 3e 20 27 e2 b2 a8 27 2c 0a 20 20 27 e2 b2 | >.'...',...'...'.=>.'...',...'.. |
2ed00 | ab 27 20 3d 3e 20 27 e2 b2 aa 27 2c 0a 20 20 27 e2 b2 ad 27 20 3d 3e 20 27 e2 b2 ac 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
2ed20 | 20 27 e2 b2 af 27 20 3d 3e 20 27 e2 b2 ae 27 2c 0a 20 20 27 e2 b2 b1 27 20 3d 3e 20 27 e2 b2 b0 | .'...'.=>.'...',...'...'.=>.'... |
2ed40 | 27 2c 0a 20 20 27 e2 b2 b3 27 20 3d 3e 20 27 e2 b2 b2 27 2c 0a 20 20 27 e2 b2 b5 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
2ed60 | 27 e2 b2 b4 27 2c 0a 20 20 27 e2 b2 b7 27 20 3d 3e 20 27 e2 b2 b6 27 2c 0a 20 20 27 e2 b2 b9 27 | '...',...'...'.=>.'...',...'...' |
2ed80 | 20 3d 3e 20 27 e2 b2 b8 27 2c 0a 20 20 27 e2 b2 bb 27 20 3d 3e 20 27 e2 b2 ba 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
2eda0 | e2 b2 bd 27 20 3d 3e 20 27 e2 b2 bc 27 2c 0a 20 20 27 e2 b2 bf 27 20 3d 3e 20 27 e2 b2 be 27 2c | ...'.=>.'...',...'...'.=>.'...', |
2edc0 | 0a 20 20 27 e2 b3 81 27 20 3d 3e 20 27 e2 b3 80 27 2c 0a 20 20 27 e2 b3 83 27 20 3d 3e 20 27 e2 | ...'...'.=>.'...',...'...'.=>.'. |
2ede0 | b3 82 27 2c 0a 20 20 27 e2 b3 85 27 20 3d 3e 20 27 e2 b3 84 27 2c 0a 20 20 27 e2 b3 87 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
2ee00 | 3e 20 27 e2 b3 86 27 2c 0a 20 20 27 e2 b3 89 27 20 3d 3e 20 27 e2 b3 88 27 2c 0a 20 20 27 e2 b3 | >.'...',...'...'.=>.'...',...'.. |
2ee20 | 8b 27 20 3d 3e 20 27 e2 b3 8a 27 2c 0a 20 20 27 e2 b3 8d 27 20 3d 3e 20 27 e2 b3 8c 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
2ee40 | 20 27 e2 b3 8f 27 20 3d 3e 20 27 e2 b3 8e 27 2c 0a 20 20 27 e2 b3 91 27 20 3d 3e 20 27 e2 b3 90 | .'...'.=>.'...',...'...'.=>.'... |
2ee60 | 27 2c 0a 20 20 27 e2 b3 93 27 20 3d 3e 20 27 e2 b3 92 27 2c 0a 20 20 27 e2 b3 95 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
2ee80 | 27 e2 b3 94 27 2c 0a 20 20 27 e2 b3 97 27 20 3d 3e 20 27 e2 b3 96 27 2c 0a 20 20 27 e2 b3 99 27 | '...',...'...'.=>.'...',...'...' |
2eea0 | 20 3d 3e 20 27 e2 b3 98 27 2c 0a 20 20 27 e2 b3 9b 27 20 3d 3e 20 27 e2 b3 9a 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
2eec0 | e2 b3 9d 27 20 3d 3e 20 27 e2 b3 9c 27 2c 0a 20 20 27 e2 b3 9f 27 20 3d 3e 20 27 e2 b3 9e 27 2c | ...'.=>.'...',...'...'.=>.'...', |
2eee0 | 0a 20 20 27 e2 b3 a1 27 20 3d 3e 20 27 e2 b3 a0 27 2c 0a 20 20 27 e2 b3 a3 27 20 3d 3e 20 27 e2 | ...'...'.=>.'...',...'...'.=>.'. |
2ef00 | b3 a2 27 2c 0a 20 20 27 e2 b3 ac 27 20 3d 3e 20 27 e2 b3 ab 27 2c 0a 20 20 27 e2 b3 ae 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
2ef20 | 3e 20 27 e2 b3 ad 27 2c 0a 20 20 27 e2 b3 b3 27 20 3d 3e 20 27 e2 b3 b2 27 2c 0a 20 20 27 e2 b4 | >.'...',...'...'.=>.'...',...'.. |
2ef40 | 80 27 20 3d 3e 20 27 e1 82 a0 27 2c 0a 20 20 27 e2 b4 81 27 20 3d 3e 20 27 e1 82 a1 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
2ef60 | 20 27 e2 b4 82 27 20 3d 3e 20 27 e1 82 a2 27 2c 0a 20 20 27 e2 b4 83 27 20 3d 3e 20 27 e1 82 a3 | .'...'.=>.'...',...'...'.=>.'... |
2ef80 | 27 2c 0a 20 20 27 e2 b4 84 27 20 3d 3e 20 27 e1 82 a4 27 2c 0a 20 20 27 e2 b4 85 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
2efa0 | 27 e1 82 a5 27 2c 0a 20 20 27 e2 b4 86 27 20 3d 3e 20 27 e1 82 a6 27 2c 0a 20 20 27 e2 b4 87 27 | '...',...'...'.=>.'...',...'...' |
2efc0 | 20 3d 3e 20 27 e1 82 a7 27 2c 0a 20 20 27 e2 b4 88 27 20 3d 3e 20 27 e1 82 a8 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
2efe0 | e2 b4 89 27 20 3d 3e 20 27 e1 82 a9 27 2c 0a 20 20 27 e2 b4 8a 27 20 3d 3e 20 27 e1 82 aa 27 2c | ...'.=>.'...',...'...'.=>.'...', |
2f000 | 0a 20 20 27 e2 b4 8b 27 20 3d 3e 20 27 e1 82 ab 27 2c 0a 20 20 27 e2 b4 8c 27 20 3d 3e 20 27 e1 | ...'...'.=>.'...',...'...'.=>.'. |
2f020 | 82 ac 27 2c 0a 20 20 27 e2 b4 8d 27 20 3d 3e 20 27 e1 82 ad 27 2c 0a 20 20 27 e2 b4 8e 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
2f040 | 3e 20 27 e1 82 ae 27 2c 0a 20 20 27 e2 b4 8f 27 20 3d 3e 20 27 e1 82 af 27 2c 0a 20 20 27 e2 b4 | >.'...',...'...'.=>.'...',...'.. |
2f060 | 90 27 20 3d 3e 20 27 e1 82 b0 27 2c 0a 20 20 27 e2 b4 91 27 20 3d 3e 20 27 e1 82 b1 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
2f080 | 20 27 e2 b4 92 27 20 3d 3e 20 27 e1 82 b2 27 2c 0a 20 20 27 e2 b4 93 27 20 3d 3e 20 27 e1 82 b3 | .'...'.=>.'...',...'...'.=>.'... |
2f0a0 | 27 2c 0a 20 20 27 e2 b4 94 27 20 3d 3e 20 27 e1 82 b4 27 2c 0a 20 20 27 e2 b4 95 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
2f0c0 | 27 e1 82 b5 27 2c 0a 20 20 27 e2 b4 96 27 20 3d 3e 20 27 e1 82 b6 27 2c 0a 20 20 27 e2 b4 97 27 | '...',...'...'.=>.'...',...'...' |
2f0e0 | 20 3d 3e 20 27 e1 82 b7 27 2c 0a 20 20 27 e2 b4 98 27 20 3d 3e 20 27 e1 82 b8 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
2f100 | e2 b4 99 27 20 3d 3e 20 27 e1 82 b9 27 2c 0a 20 20 27 e2 b4 9a 27 20 3d 3e 20 27 e1 82 ba 27 2c | ...'.=>.'...',...'...'.=>.'...', |
2f120 | 0a 20 20 27 e2 b4 9b 27 20 3d 3e 20 27 e1 82 bb 27 2c 0a 20 20 27 e2 b4 9c 27 20 3d 3e 20 27 e1 | ...'...'.=>.'...',...'...'.=>.'. |
2f140 | 82 bc 27 2c 0a 20 20 27 e2 b4 9d 27 20 3d 3e 20 27 e1 82 bd 27 2c 0a 20 20 27 e2 b4 9e 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
2f160 | 3e 20 27 e1 82 be 27 2c 0a 20 20 27 e2 b4 9f 27 20 3d 3e 20 27 e1 82 bf 27 2c 0a 20 20 27 e2 b4 | >.'...',...'...'.=>.'...',...'.. |
2f180 | a0 27 20 3d 3e 20 27 e1 83 80 27 2c 0a 20 20 27 e2 b4 a1 27 20 3d 3e 20 27 e1 83 81 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
2f1a0 | 20 27 e2 b4 a2 27 20 3d 3e 20 27 e1 83 82 27 2c 0a 20 20 27 e2 b4 a3 27 20 3d 3e 20 27 e1 83 83 | .'...'.=>.'...',...'...'.=>.'... |
2f1c0 | 27 2c 0a 20 20 27 e2 b4 a4 27 20 3d 3e 20 27 e1 83 84 27 2c 0a 20 20 27 e2 b4 a5 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
2f1e0 | 27 e1 83 85 27 2c 0a 20 20 27 e2 b4 a7 27 20 3d 3e 20 27 e1 83 87 27 2c 0a 20 20 27 e2 b4 ad 27 | '...',...'...'.=>.'...',...'...' |
2f200 | 20 3d 3e 20 27 e1 83 8d 27 2c 0a 20 20 27 ea 99 81 27 20 3d 3e 20 27 ea 99 80 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
2f220 | ea 99 83 27 20 3d 3e 20 27 ea 99 82 27 2c 0a 20 20 27 ea 99 85 27 20 3d 3e 20 27 ea 99 84 27 2c | ...'.=>.'...',...'...'.=>.'...', |
2f240 | 0a 20 20 27 ea 99 87 27 20 3d 3e 20 27 ea 99 86 27 2c 0a 20 20 27 ea 99 89 27 20 3d 3e 20 27 ea | ...'...'.=>.'...',...'...'.=>.'. |
2f260 | 99 88 27 2c 0a 20 20 27 ea 99 8b 27 20 3d 3e 20 27 ea 99 8a 27 2c 0a 20 20 27 ea 99 8d 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
2f280 | 3e 20 27 ea 99 8c 27 2c 0a 20 20 27 ea 99 8f 27 20 3d 3e 20 27 ea 99 8e 27 2c 0a 20 20 27 ea 99 | >.'...',...'...'.=>.'...',...'.. |
2f2a0 | 91 27 20 3d 3e 20 27 ea 99 90 27 2c 0a 20 20 27 ea 99 93 27 20 3d 3e 20 27 ea 99 92 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
2f2c0 | 20 27 ea 99 95 27 20 3d 3e 20 27 ea 99 94 27 2c 0a 20 20 27 ea 99 97 27 20 3d 3e 20 27 ea 99 96 | .'...'.=>.'...',...'...'.=>.'... |
2f2e0 | 27 2c 0a 20 20 27 ea 99 99 27 20 3d 3e 20 27 ea 99 98 27 2c 0a 20 20 27 ea 99 9b 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
2f300 | 27 ea 99 9a 27 2c 0a 20 20 27 ea 99 9d 27 20 3d 3e 20 27 ea 99 9c 27 2c 0a 20 20 27 ea 99 9f 27 | '...',...'...'.=>.'...',...'...' |
2f320 | 20 3d 3e 20 27 ea 99 9e 27 2c 0a 20 20 27 ea 99 a1 27 20 3d 3e 20 27 ea 99 a0 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
2f340 | ea 99 a3 27 20 3d 3e 20 27 ea 99 a2 27 2c 0a 20 20 27 ea 99 a5 27 20 3d 3e 20 27 ea 99 a4 27 2c | ...'.=>.'...',...'...'.=>.'...', |
2f360 | 0a 20 20 27 ea 99 a7 27 20 3d 3e 20 27 ea 99 a6 27 2c 0a 20 20 27 ea 99 a9 27 20 3d 3e 20 27 ea | ...'...'.=>.'...',...'...'.=>.'. |
2f380 | 99 a8 27 2c 0a 20 20 27 ea 99 ab 27 20 3d 3e 20 27 ea 99 aa 27 2c 0a 20 20 27 ea 99 ad 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
2f3a0 | 3e 20 27 ea 99 ac 27 2c 0a 20 20 27 ea 9a 81 27 20 3d 3e 20 27 ea 9a 80 27 2c 0a 20 20 27 ea 9a | >.'...',...'...'.=>.'...',...'.. |
2f3c0 | 83 27 20 3d 3e 20 27 ea 9a 82 27 2c 0a 20 20 27 ea 9a 85 27 20 3d 3e 20 27 ea 9a 84 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
2f3e0 | 20 27 ea 9a 87 27 20 3d 3e 20 27 ea 9a 86 27 2c 0a 20 20 27 ea 9a 89 27 20 3d 3e 20 27 ea 9a 88 | .'...'.=>.'...',...'...'.=>.'... |
2f400 | 27 2c 0a 20 20 27 ea 9a 8b 27 20 3d 3e 20 27 ea 9a 8a 27 2c 0a 20 20 27 ea 9a 8d 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
2f420 | 27 ea 9a 8c 27 2c 0a 20 20 27 ea 9a 8f 27 20 3d 3e 20 27 ea 9a 8e 27 2c 0a 20 20 27 ea 9a 91 27 | '...',...'...'.=>.'...',...'...' |
2f440 | 20 3d 3e 20 27 ea 9a 90 27 2c 0a 20 20 27 ea 9a 93 27 20 3d 3e 20 27 ea 9a 92 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
2f460 | ea 9a 95 27 20 3d 3e 20 27 ea 9a 94 27 2c 0a 20 20 27 ea 9a 97 27 20 3d 3e 20 27 ea 9a 96 27 2c | ...'.=>.'...',...'...'.=>.'...', |
2f480 | 0a 20 20 27 ea 9a 99 27 20 3d 3e 20 27 ea 9a 98 27 2c 0a 20 20 27 ea 9a 9b 27 20 3d 3e 20 27 ea | ...'...'.=>.'...',...'...'.=>.'. |
2f4a0 | 9a 9a 27 2c 0a 20 20 27 ea 9c a3 27 20 3d 3e 20 27 ea 9c a2 27 2c 0a 20 20 27 ea 9c a5 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
2f4c0 | 3e 20 27 ea 9c a4 27 2c 0a 20 20 27 ea 9c a7 27 20 3d 3e 20 27 ea 9c a6 27 2c 0a 20 20 27 ea 9c | >.'...',...'...'.=>.'...',...'.. |
2f4e0 | a9 27 20 3d 3e 20 27 ea 9c a8 27 2c 0a 20 20 27 ea 9c ab 27 20 3d 3e 20 27 ea 9c aa 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
2f500 | 20 27 ea 9c ad 27 20 3d 3e 20 27 ea 9c ac 27 2c 0a 20 20 27 ea 9c af 27 20 3d 3e 20 27 ea 9c ae | .'...'.=>.'...',...'...'.=>.'... |
2f520 | 27 2c 0a 20 20 27 ea 9c b3 27 20 3d 3e 20 27 ea 9c b2 27 2c 0a 20 20 27 ea 9c b5 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
2f540 | 27 ea 9c b4 27 2c 0a 20 20 27 ea 9c b7 27 20 3d 3e 20 27 ea 9c b6 27 2c 0a 20 20 27 ea 9c b9 27 | '...',...'...'.=>.'...',...'...' |
2f560 | 20 3d 3e 20 27 ea 9c b8 27 2c 0a 20 20 27 ea 9c bb 27 20 3d 3e 20 27 ea 9c ba 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
2f580 | ea 9c bd 27 20 3d 3e 20 27 ea 9c bc 27 2c 0a 20 20 27 ea 9c bf 27 20 3d 3e 20 27 ea 9c be 27 2c | ...'.=>.'...',...'...'.=>.'...', |
2f5a0 | 0a 20 20 27 ea 9d 81 27 20 3d 3e 20 27 ea 9d 80 27 2c 0a 20 20 27 ea 9d 83 27 20 3d 3e 20 27 ea | ...'...'.=>.'...',...'...'.=>.'. |
2f5c0 | 9d 82 27 2c 0a 20 20 27 ea 9d 85 27 20 3d 3e 20 27 ea 9d 84 27 2c 0a 20 20 27 ea 9d 87 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
2f5e0 | 3e 20 27 ea 9d 86 27 2c 0a 20 20 27 ea 9d 89 27 20 3d 3e 20 27 ea 9d 88 27 2c 0a 20 20 27 ea 9d | >.'...',...'...'.=>.'...',...'.. |
2f600 | 8b 27 20 3d 3e 20 27 ea 9d 8a 27 2c 0a 20 20 27 ea 9d 8d 27 20 3d 3e 20 27 ea 9d 8c 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
2f620 | 20 27 ea 9d 8f 27 20 3d 3e 20 27 ea 9d 8e 27 2c 0a 20 20 27 ea 9d 91 27 20 3d 3e 20 27 ea 9d 90 | .'...'.=>.'...',...'...'.=>.'... |
2f640 | 27 2c 0a 20 20 27 ea 9d 93 27 20 3d 3e 20 27 ea 9d 92 27 2c 0a 20 20 27 ea 9d 95 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
2f660 | 27 ea 9d 94 27 2c 0a 20 20 27 ea 9d 97 27 20 3d 3e 20 27 ea 9d 96 27 2c 0a 20 20 27 ea 9d 99 27 | '...',...'...'.=>.'...',...'...' |
2f680 | 20 3d 3e 20 27 ea 9d 98 27 2c 0a 20 20 27 ea 9d 9b 27 20 3d 3e 20 27 ea 9d 9a 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
2f6a0 | ea 9d 9d 27 20 3d 3e 20 27 ea 9d 9c 27 2c 0a 20 20 27 ea 9d 9f 27 20 3d 3e 20 27 ea 9d 9e 27 2c | ...'.=>.'...',...'...'.=>.'...', |
2f6c0 | 0a 20 20 27 ea 9d a1 27 20 3d 3e 20 27 ea 9d a0 27 2c 0a 20 20 27 ea 9d a3 27 20 3d 3e 20 27 ea | ...'...'.=>.'...',...'...'.=>.'. |
2f6e0 | 9d a2 27 2c 0a 20 20 27 ea 9d a5 27 20 3d 3e 20 27 ea 9d a4 27 2c 0a 20 20 27 ea 9d a7 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
2f700 | 3e 20 27 ea 9d a6 27 2c 0a 20 20 27 ea 9d a9 27 20 3d 3e 20 27 ea 9d a8 27 2c 0a 20 20 27 ea 9d | >.'...',...'...'.=>.'...',...'.. |
2f720 | ab 27 20 3d 3e 20 27 ea 9d aa 27 2c 0a 20 20 27 ea 9d ad 27 20 3d 3e 20 27 ea 9d ac 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
2f740 | 20 27 ea 9d af 27 20 3d 3e 20 27 ea 9d ae 27 2c 0a 20 20 27 ea 9d ba 27 20 3d 3e 20 27 ea 9d b9 | .'...'.=>.'...',...'...'.=>.'... |
2f760 | 27 2c 0a 20 20 27 ea 9d bc 27 20 3d 3e 20 27 ea 9d bb 27 2c 0a 20 20 27 ea 9d bf 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
2f780 | 27 ea 9d be 27 2c 0a 20 20 27 ea 9e 81 27 20 3d 3e 20 27 ea 9e 80 27 2c 0a 20 20 27 ea 9e 83 27 | '...',...'...'.=>.'...',...'...' |
2f7a0 | 20 3d 3e 20 27 ea 9e 82 27 2c 0a 20 20 27 ea 9e 85 27 20 3d 3e 20 27 ea 9e 84 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
2f7c0 | ea 9e 87 27 20 3d 3e 20 27 ea 9e 86 27 2c 0a 20 20 27 ea 9e 8c 27 20 3d 3e 20 27 ea 9e 8b 27 2c | ...'.=>.'...',...'...'.=>.'...', |
2f7e0 | 0a 20 20 27 ea 9e 91 27 20 3d 3e 20 27 ea 9e 90 27 2c 0a 20 20 27 ea 9e 93 27 20 3d 3e 20 27 ea | ...'...'.=>.'...',...'...'.=>.'. |
2f800 | 9e 92 27 2c 0a 20 20 27 ea 9e 97 27 20 3d 3e 20 27 ea 9e 96 27 2c 0a 20 20 27 ea 9e 99 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
2f820 | 3e 20 27 ea 9e 98 27 2c 0a 20 20 27 ea 9e 9b 27 20 3d 3e 20 27 ea 9e 9a 27 2c 0a 20 20 27 ea 9e | >.'...',...'...'.=>.'...',...'.. |
2f840 | 9d 27 20 3d 3e 20 27 ea 9e 9c 27 2c 0a 20 20 27 ea 9e 9f 27 20 3d 3e 20 27 ea 9e 9e 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
2f860 | 20 27 ea 9e a1 27 20 3d 3e 20 27 ea 9e a0 27 2c 0a 20 20 27 ea 9e a3 27 20 3d 3e 20 27 ea 9e a2 | .'...'.=>.'...',...'...'.=>.'... |
2f880 | 27 2c 0a 20 20 27 ea 9e a5 27 20 3d 3e 20 27 ea 9e a4 27 2c 0a 20 20 27 ea 9e a7 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
2f8a0 | 27 ea 9e a6 27 2c 0a 20 20 27 ea 9e a9 27 20 3d 3e 20 27 ea 9e a8 27 2c 0a 20 20 27 ef bd 81 27 | '...',...'...'.=>.'...',...'...' |
2f8c0 | 20 3d 3e 20 27 ef bc a1 27 2c 0a 20 20 27 ef bd 82 27 20 3d 3e 20 27 ef bc a2 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
2f8e0 | ef bd 83 27 20 3d 3e 20 27 ef bc a3 27 2c 0a 20 20 27 ef bd 84 27 20 3d 3e 20 27 ef bc a4 27 2c | ...'.=>.'...',...'...'.=>.'...', |
2f900 | 0a 20 20 27 ef bd 85 27 20 3d 3e 20 27 ef bc a5 27 2c 0a 20 20 27 ef bd 86 27 20 3d 3e 20 27 ef | ...'...'.=>.'...',...'...'.=>.'. |
2f920 | bc a6 27 2c 0a 20 20 27 ef bd 87 27 20 3d 3e 20 27 ef bc a7 27 2c 0a 20 20 27 ef bd 88 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
2f940 | 3e 20 27 ef bc a8 27 2c 0a 20 20 27 ef bd 89 27 20 3d 3e 20 27 ef bc a9 27 2c 0a 20 20 27 ef bd | >.'...',...'...'.=>.'...',...'.. |
2f960 | 8a 27 20 3d 3e 20 27 ef bc aa 27 2c 0a 20 20 27 ef bd 8b 27 20 3d 3e 20 27 ef bc ab 27 2c 0a 20 | .'.=>.'...',...'...'.=>.'...',.. |
2f980 | 20 27 ef bd 8c 27 20 3d 3e 20 27 ef bc ac 27 2c 0a 20 20 27 ef bd 8d 27 20 3d 3e 20 27 ef bc ad | .'...'.=>.'...',...'...'.=>.'... |
2f9a0 | 27 2c 0a 20 20 27 ef bd 8e 27 20 3d 3e 20 27 ef bc ae 27 2c 0a 20 20 27 ef bd 8f 27 20 3d 3e 20 | ',...'...'.=>.'...',...'...'.=>. |
2f9c0 | 27 ef bc af 27 2c 0a 20 20 27 ef bd 90 27 20 3d 3e 20 27 ef bc b0 27 2c 0a 20 20 27 ef bd 91 27 | '...',...'...'.=>.'...',...'...' |
2f9e0 | 20 3d 3e 20 27 ef bc b1 27 2c 0a 20 20 27 ef bd 92 27 20 3d 3e 20 27 ef bc b2 27 2c 0a 20 20 27 | .=>.'...',...'...'.=>.'...',...' |
2fa00 | ef bd 93 27 20 3d 3e 20 27 ef bc b3 27 2c 0a 20 20 27 ef bd 94 27 20 3d 3e 20 27 ef bc b4 27 2c | ...'.=>.'...',...'...'.=>.'...', |
2fa20 | 0a 20 20 27 ef bd 95 27 20 3d 3e 20 27 ef bc b5 27 2c 0a 20 20 27 ef bd 96 27 20 3d 3e 20 27 ef | ...'...'.=>.'...',...'...'.=>.'. |
2fa40 | bc b6 27 2c 0a 20 20 27 ef bd 97 27 20 3d 3e 20 27 ef bc b7 27 2c 0a 20 20 27 ef bd 98 27 20 3d | ..',...'...'.=>.'...',...'...'.= |
2fa60 | 3e 20 27 ef bc b8 27 2c 0a 20 20 27 ef bd 99 27 20 3d 3e 20 27 ef bc b9 27 2c 0a 20 20 27 ef bd | >.'...',...'...'.=>.'...',...'.. |
2fa80 | 9a 27 20 3d 3e 20 27 ef bc ba 27 2c 0a 20 20 27 f0 90 90 a8 27 20 3d 3e 20 27 f0 90 90 80 27 2c | .'.=>.'...',...'....'.=>.'....', |
2faa0 | 0a 20 20 27 f0 90 90 a9 27 20 3d 3e 20 27 f0 90 90 81 27 2c 0a 20 20 27 f0 90 90 aa 27 20 3d 3e | ...'....'.=>.'....',...'....'.=> |
2fac0 | 20 27 f0 90 90 82 27 2c 0a 20 20 27 f0 90 90 ab 27 20 3d 3e 20 27 f0 90 90 83 27 2c 0a 20 20 27 | .'....',...'....'.=>.'....',...' |
2fae0 | f0 90 90 ac 27 20 3d 3e 20 27 f0 90 90 84 27 2c 0a 20 20 27 f0 90 90 ad 27 20 3d 3e 20 27 f0 90 | ....'.=>.'....',...'....'.=>.'.. |
2fb00 | 90 85 27 2c 0a 20 20 27 f0 90 90 ae 27 20 3d 3e 20 27 f0 90 90 86 27 2c 0a 20 20 27 f0 90 90 af | ..',...'....'.=>.'....',...'.... |
2fb20 | 27 20 3d 3e 20 27 f0 90 90 87 27 2c 0a 20 20 27 f0 90 90 b0 27 20 3d 3e 20 27 f0 90 90 88 27 2c | '.=>.'....',...'....'.=>.'....', |
2fb40 | 0a 20 20 27 f0 90 90 b1 27 20 3d 3e 20 27 f0 90 90 89 27 2c 0a 20 20 27 f0 90 90 b2 27 20 3d 3e | ...'....'.=>.'....',...'....'.=> |
2fb60 | 20 27 f0 90 90 8a 27 2c 0a 20 20 27 f0 90 90 b3 27 20 3d 3e 20 27 f0 90 90 8b 27 2c 0a 20 20 27 | .'....',...'....'.=>.'....',...' |
2fb80 | f0 90 90 b4 27 20 3d 3e 20 27 f0 90 90 8c 27 2c 0a 20 20 27 f0 90 90 b5 27 20 3d 3e 20 27 f0 90 | ....'.=>.'....',...'....'.=>.'.. |
2fba0 | 90 8d 27 2c 0a 20 20 27 f0 90 90 b6 27 20 3d 3e 20 27 f0 90 90 8e 27 2c 0a 20 20 27 f0 90 90 b7 | ..',...'....'.=>.'....',...'.... |
2fbc0 | 27 20 3d 3e 20 27 f0 90 90 8f 27 2c 0a 20 20 27 f0 90 90 b8 27 20 3d 3e 20 27 f0 90 90 90 27 2c | '.=>.'....',...'....'.=>.'....', |
2fbe0 | 0a 20 20 27 f0 90 90 b9 27 20 3d 3e 20 27 f0 90 90 91 27 2c 0a 20 20 27 f0 90 90 ba 27 20 3d 3e | ...'....'.=>.'....',...'....'.=> |
2fc00 | 20 27 f0 90 90 92 27 2c 0a 20 20 27 f0 90 90 bb 27 20 3d 3e 20 27 f0 90 90 93 27 2c 0a 20 20 27 | .'....',...'....'.=>.'....',...' |
2fc20 | f0 90 90 bc 27 20 3d 3e 20 27 f0 90 90 94 27 2c 0a 20 20 27 f0 90 90 bd 27 20 3d 3e 20 27 f0 90 | ....'.=>.'....',...'....'.=>.'.. |
2fc40 | 90 95 27 2c 0a 20 20 27 f0 90 90 be 27 20 3d 3e 20 27 f0 90 90 96 27 2c 0a 20 20 27 f0 90 90 bf | ..',...'....'.=>.'....',...'.... |
2fc60 | 27 20 3d 3e 20 27 f0 90 90 97 27 2c 0a 20 20 27 f0 90 91 80 27 20 3d 3e 20 27 f0 90 90 98 27 2c | '.=>.'....',...'....'.=>.'....', |
2fc80 | 0a 20 20 27 f0 90 91 81 27 20 3d 3e 20 27 f0 90 90 99 27 2c 0a 20 20 27 f0 90 91 82 27 20 3d 3e | ...'....'.=>.'....',...'....'.=> |
2fca0 | 20 27 f0 90 90 9a 27 2c 0a 20 20 27 f0 90 91 83 27 20 3d 3e 20 27 f0 90 90 9b 27 2c 0a 20 20 27 | .'....',...'....'.=>.'....',...' |
2fcc0 | f0 90 91 84 27 20 3d 3e 20 27 f0 90 90 9c 27 2c 0a 20 20 27 f0 90 91 85 27 20 3d 3e 20 27 f0 90 | ....'.=>.'....',...'....'.=>.'.. |
2fce0 | 90 9d 27 2c 0a 20 20 27 f0 90 91 86 27 20 3d 3e 20 27 f0 90 90 9e 27 2c 0a 20 20 27 f0 90 91 87 | ..',...'....'.=>.'....',...'.... |
2fd00 | 27 20 3d 3e 20 27 f0 90 90 9f 27 2c 0a 20 20 27 f0 90 91 88 27 20 3d 3e 20 27 f0 90 90 a0 27 2c | '.=>.'....',...'....'.=>.'....', |
2fd20 | 0a 20 20 27 f0 90 91 89 27 20 3d 3e 20 27 f0 90 90 a1 27 2c 0a 20 20 27 f0 90 91 8a 27 20 3d 3e | ...'....'.=>.'....',...'....'.=> |
2fd40 | 20 27 f0 90 90 a2 27 2c 0a 20 20 27 f0 90 91 8b 27 20 3d 3e 20 27 f0 90 90 a3 27 2c 0a 20 20 27 | .'....',...'....'.=>.'....',...' |
2fd60 | f0 90 91 8c 27 20 3d 3e 20 27 f0 90 90 a4 27 2c 0a 20 20 27 f0 90 91 8d 27 20 3d 3e 20 27 f0 90 | ....'.=>.'....',...'....'.=>.'.. |
2fd80 | 90 a5 27 2c 0a 20 20 27 f0 90 91 8e 27 20 3d 3e 20 27 f0 90 90 a6 27 2c 0a 20 20 27 f0 90 91 8f | ..',...'....'.=>.'....',...'.... |
2fda0 | 27 20 3d 3e 20 27 f0 90 90 a7 27 2c 0a 20 20 27 f0 91 a3 80 27 20 3d 3e 20 27 f0 91 a2 a0 27 2c | '.=>.'....',...'....'.=>.'....', |
2fdc0 | 0a 20 20 27 f0 91 a3 81 27 20 3d 3e 20 27 f0 91 a2 a1 27 2c 0a 20 20 27 f0 91 a3 82 27 20 3d 3e | ...'....'.=>.'....',...'....'.=> |
2fde0 | 20 27 f0 91 a2 a2 27 2c 0a 20 20 27 f0 91 a3 83 27 20 3d 3e 20 27 f0 91 a2 a3 27 2c 0a 20 20 27 | .'....',...'....'.=>.'....',...' |
2fe00 | f0 91 a3 84 27 20 3d 3e 20 27 f0 91 a2 a4 27 2c 0a 20 20 27 f0 91 a3 85 27 20 3d 3e 20 27 f0 91 | ....'.=>.'....',...'....'.=>.'.. |
2fe20 | a2 a5 27 2c 0a 20 20 27 f0 91 a3 86 27 20 3d 3e 20 27 f0 91 a2 a6 27 2c 0a 20 20 27 f0 91 a3 87 | ..',...'....'.=>.'....',...'.... |
2fe40 | 27 20 3d 3e 20 27 f0 91 a2 a7 27 2c 0a 20 20 27 f0 91 a3 88 27 20 3d 3e 20 27 f0 91 a2 a8 27 2c | '.=>.'....',...'....'.=>.'....', |
2fe60 | 0a 20 20 27 f0 91 a3 89 27 20 3d 3e 20 27 f0 91 a2 a9 27 2c 0a 20 20 27 f0 91 a3 8a 27 20 3d 3e | ...'....'.=>.'....',...'....'.=> |
2fe80 | 20 27 f0 91 a2 aa 27 2c 0a 20 20 27 f0 91 a3 8b 27 20 3d 3e 20 27 f0 91 a2 ab 27 2c 0a 20 20 27 | .'....',...'....'.=>.'....',...' |
2fea0 | f0 91 a3 8c 27 20 3d 3e 20 27 f0 91 a2 ac 27 2c 0a 20 20 27 f0 91 a3 8d 27 20 3d 3e 20 27 f0 91 | ....'.=>.'....',...'....'.=>.'.. |
2fec0 | a2 ad 27 2c 0a 20 20 27 f0 91 a3 8e 27 20 3d 3e 20 27 f0 91 a2 ae 27 2c 0a 20 20 27 f0 91 a3 8f | ..',...'....'.=>.'....',...'.... |
2fee0 | 27 20 3d 3e 20 27 f0 91 a2 af 27 2c 0a 20 20 27 f0 91 a3 90 27 20 3d 3e 20 27 f0 91 a2 b0 27 2c | '.=>.'....',...'....'.=>.'....', |
2ff00 | 0a 20 20 27 f0 91 a3 91 27 20 3d 3e 20 27 f0 91 a2 b1 27 2c 0a 20 20 27 f0 91 a3 92 27 20 3d 3e | ...'....'.=>.'....',...'....'.=> |
2ff20 | 20 27 f0 91 a2 b2 27 2c 0a 20 20 27 f0 91 a3 93 27 20 3d 3e 20 27 f0 91 a2 b3 27 2c 0a 20 20 27 | .'....',...'....'.=>.'....',...' |
2ff40 | f0 91 a3 94 27 20 3d 3e 20 27 f0 91 a2 b4 27 2c 0a 20 20 27 f0 91 a3 95 27 20 3d 3e 20 27 f0 91 | ....'.=>.'....',...'....'.=>.'.. |
2ff60 | a2 b5 27 2c 0a 20 20 27 f0 91 a3 96 27 20 3d 3e 20 27 f0 91 a2 b6 27 2c 0a 20 20 27 f0 91 a3 97 | ..',...'....'.=>.'....',...'.... |
2ff80 | 27 20 3d 3e 20 27 f0 91 a2 b7 27 2c 0a 20 20 27 f0 91 a3 98 27 20 3d 3e 20 27 f0 91 a2 b8 27 2c | '.=>.'....',...'....'.=>.'....', |
2ffa0 | 0a 20 20 27 f0 91 a3 99 27 20 3d 3e 20 27 f0 91 a2 b9 27 2c 0a 20 20 27 f0 91 a3 9a 27 20 3d 3e | ...'....'.=>.'....',...'....'.=> |
2ffc0 | 20 27 f0 91 a2 ba 27 2c 0a 20 20 27 f0 91 a3 9b 27 20 3d 3e 20 27 f0 91 a2 bb 27 2c 0a 20 20 27 | .'....',...'....'.=>.'....',...' |
2ffe0 | f0 91 a3 9c 27 20 3d 3e 20 27 f0 91 a2 bc 27 2c 0a 20 20 27 f0 91 a3 9d 27 20 3d 3e 20 27 f0 91 | ....'.=>.'....',...'....'.=>.'.. |
30000 | a2 bd 27 2c 0a 20 20 27 f0 91 a3 9e 27 20 3d 3e 20 27 f0 91 a2 be 27 2c 0a 20 20 27 f0 91 a3 9f | ..',...'....'.=>.'....',...'.... |
30020 | 27 20 3d 3e 20 27 f0 91 a2 bf 27 2c 0a 29 3b 0a 0a 24 72 65 73 75 6c 74 20 3d 26 20 24 64 61 74 | '.=>.'....',.);..$result.=&.$dat |
30040 | 61 3b 0a 75 6e 73 65 74 28 24 64 61 74 61 29 3b 0a 0a 72 65 74 75 72 6e 20 24 72 65 73 75 6c 74 | a;.unset($data);..return.$result |
30060 | 3b 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 | ;.<?php../*..*.This.file.is.part |
30080 | 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 | .of.the.Symfony.package...*..*.( |
300a0 | 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 | c).Fabien.Potencier.<fabien@symf |
300c0 | 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 | ony.com>..*..*.For.the.full.copy |
300e0 | 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 | right.and.license.information,.p |
30100 | 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 | lease.view.the.LICENSE..*.file.t |
30120 | 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f | hat.was.distributed.with.this.so |
30140 | 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e | urce.code...*/..namespace.Symfon |
30160 | 79 5c 50 6f 6c 79 66 69 6c 6c 5c 4d 62 73 74 72 69 6e 67 3b 0a 0a 2f 2a 2a 0a 20 2a 20 50 61 72 | y\Polyfill\Mbstring;../**..*.Par |
30180 | 74 69 61 6c 20 6d 62 73 74 72 69 6e 67 20 69 6d 70 6c 65 6d 65 6e 74 61 74 69 6f 6e 20 69 6e 20 | tial.mbstring.implementation.in. |
301a0 | 50 48 50 2c 20 69 63 6f 6e 76 20 62 61 73 65 64 2c 20 55 54 46 2d 38 20 63 65 6e 74 72 69 63 2e | PHP,.iconv.based,.UTF-8.centric. |
301c0 | 0a 20 2a 0a 20 2a 20 49 6d 70 6c 65 6d 65 6e 74 65 64 3a 0a 20 2a 20 2d 20 6d 62 5f 63 6f 6e 76 | ..*..*.Implemented:..*.-.mb_conv |
301e0 | 65 72 74 5f 65 6e 63 6f 64 69 6e 67 20 20 20 20 20 2d 20 43 6f 6e 76 65 72 74 20 63 68 61 72 61 | ert_encoding.....-.Convert.chara |
30200 | 63 74 65 72 20 65 6e 63 6f 64 69 6e 67 0a 20 2a 20 2d 20 6d 62 5f 63 6f 6e 76 65 72 74 5f 76 61 | cter.encoding..*.-.mb_convert_va |
30220 | 72 69 61 62 6c 65 73 20 20 20 20 2d 20 43 6f 6e 76 65 72 74 20 63 68 61 72 61 63 74 65 72 20 63 | riables....-.Convert.character.c |
30240 | 6f 64 65 20 69 6e 20 76 61 72 69 61 62 6c 65 28 73 29 0a 20 2a 20 2d 20 6d 62 5f 64 65 63 6f 64 | ode.in.variable(s)..*.-.mb_decod |
30260 | 65 5f 6d 69 6d 65 68 65 61 64 65 72 20 20 20 20 2d 20 44 65 63 6f 64 65 20 73 74 72 69 6e 67 20 | e_mimeheader....-.Decode.string. |
30280 | 69 6e 20 4d 49 4d 45 20 68 65 61 64 65 72 20 66 69 65 6c 64 0a 20 2a 20 2d 20 6d 62 5f 65 6e 63 | in.MIME.header.field..*.-.mb_enc |
302a0 | 6f 64 65 5f 6d 69 6d 65 68 65 61 64 65 72 20 20 20 20 2d 20 45 6e 63 6f 64 65 20 73 74 72 69 6e | ode_mimeheader....-.Encode.strin |
302c0 | 67 20 66 6f 72 20 4d 49 4d 45 20 68 65 61 64 65 72 20 58 58 58 20 4e 41 54 49 56 45 20 49 4d 50 | g.for.MIME.header.XXX.NATIVE.IMP |
302e0 | 4c 45 4d 45 4e 54 41 54 49 4f 4e 20 49 53 20 52 45 41 4c 4c 59 20 42 55 47 47 45 44 0a 20 2a 20 | LEMENTATION.IS.REALLY.BUGGED..*. |
30300 | 2d 20 6d 62 5f 63 6f 6e 76 65 72 74 5f 63 61 73 65 20 20 20 20 20 20 20 20 20 2d 20 50 65 72 66 | -.mb_convert_case.........-.Perf |
30320 | 6f 72 6d 20 63 61 73 65 20 66 6f 6c 64 69 6e 67 20 6f 6e 20 61 20 73 74 72 69 6e 67 0a 20 2a 20 | orm.case.folding.on.a.string..*. |
30340 | 2d 20 6d 62 5f 67 65 74 5f 69 6e 66 6f 20 20 20 20 20 20 20 20 20 20 20 20 20 2d 20 47 65 74 20 | -.mb_get_info.............-.Get. |
30360 | 69 6e 74 65 72 6e 61 6c 20 73 65 74 74 69 6e 67 73 20 6f 66 20 6d 62 73 74 72 69 6e 67 0a 20 2a | internal.settings.of.mbstring..* |
30380 | 20 2d 20 6d 62 5f 68 74 74 70 5f 69 6e 70 75 74 20 20 20 20 20 20 20 20 20 20 20 2d 20 44 65 74 | .-.mb_http_input...........-.Det |
303a0 | 65 63 74 20 48 54 54 50 20 69 6e 70 75 74 20 63 68 61 72 61 63 74 65 72 20 65 6e 63 6f 64 69 6e | ect.HTTP.input.character.encodin |
303c0 | 67 0a 20 2a 20 2d 20 6d 62 5f 68 74 74 70 5f 6f 75 74 70 75 74 20 20 20 20 20 20 20 20 20 20 2d | g..*.-.mb_http_output..........- |
303e0 | 20 53 65 74 2f 47 65 74 20 48 54 54 50 20 6f 75 74 70 75 74 20 63 68 61 72 61 63 74 65 72 20 65 | .Set/Get.HTTP.output.character.e |
30400 | 6e 63 6f 64 69 6e 67 0a 20 2a 20 2d 20 6d 62 5f 69 6e 74 65 72 6e 61 6c 5f 65 6e 63 6f 64 69 6e | ncoding..*.-.mb_internal_encodin |
30420 | 67 20 20 20 20 2d 20 53 65 74 2f 47 65 74 20 69 6e 74 65 72 6e 61 6c 20 63 68 61 72 61 63 74 65 | g....-.Set/Get.internal.characte |
30440 | 72 20 65 6e 63 6f 64 69 6e 67 0a 20 2a 20 2d 20 6d 62 5f 6c 69 73 74 5f 65 6e 63 6f 64 69 6e 67 | r.encoding..*.-.mb_list_encoding |
30460 | 73 20 20 20 20 20 20 20 2d 20 52 65 74 75 72 6e 73 20 61 6e 20 61 72 72 61 79 20 6f 66 20 61 6c | s.......-.Returns.an.array.of.al |
30480 | 6c 20 73 75 70 70 6f 72 74 65 64 20 65 6e 63 6f 64 69 6e 67 73 0a 20 2a 20 2d 20 6d 62 5f 6f 75 | l.supported.encodings..*.-.mb_ou |
304a0 | 74 70 75 74 5f 68 61 6e 64 6c 65 72 20 20 20 20 20 20 20 2d 20 43 61 6c 6c 62 61 63 6b 20 66 75 | tput_handler.......-.Callback.fu |
304c0 | 6e 63 74 69 6f 6e 20 63 6f 6e 76 65 72 74 73 20 63 68 61 72 61 63 74 65 72 20 65 6e 63 6f 64 69 | nction.converts.character.encodi |
304e0 | 6e 67 20 69 6e 20 6f 75 74 70 75 74 20 62 75 66 66 65 72 0a 20 2a 20 2d 20 6d 62 5f 73 74 72 6c | ng.in.output.buffer..*.-.mb_strl |
30500 | 65 6e 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2d 20 47 65 74 20 73 74 72 69 6e 67 20 6c 65 | en...............-.Get.string.le |
30520 | 6e 67 74 68 0a 20 2a 20 2d 20 6d 62 5f 73 74 72 70 6f 73 20 20 20 20 20 20 20 20 20 20 20 20 20 | ngth..*.-.mb_strpos............. |
30540 | 20 20 2d 20 46 69 6e 64 20 70 6f 73 69 74 69 6f 6e 20 6f 66 20 66 69 72 73 74 20 6f 63 63 75 72 | ..-.Find.position.of.first.occur |
30560 | 72 65 6e 63 65 20 6f 66 20 73 74 72 69 6e 67 20 69 6e 20 61 20 73 74 72 69 6e 67 0a 20 2a 20 2d | rence.of.string.in.a.string..*.- |
30580 | 20 6d 62 5f 73 74 72 72 70 6f 73 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2d 20 46 69 6e 64 20 | .mb_strrpos..............-.Find. |
305a0 | 70 6f 73 69 74 69 6f 6e 20 6f 66 20 6c 61 73 74 20 6f 63 63 75 72 72 65 6e 63 65 20 6f 66 20 61 | position.of.last.occurrence.of.a |
305c0 | 20 73 74 72 69 6e 67 20 69 6e 20 61 20 73 74 72 69 6e 67 0a 20 2a 20 2d 20 6d 62 5f 73 74 72 74 | .string.in.a.string..*.-.mb_strt |
305e0 | 6f 6c 6f 77 65 72 20 20 20 20 20 20 20 20 20 20 20 2d 20 4d 61 6b 65 20 61 20 73 74 72 69 6e 67 | olower...........-.Make.a.string |
30600 | 20 6c 6f 77 65 72 63 61 73 65 0a 20 2a 20 2d 20 6d 62 5f 73 74 72 74 6f 75 70 70 65 72 20 20 20 | .lowercase..*.-.mb_strtoupper... |
30620 | 20 20 20 20 20 20 20 20 2d 20 4d 61 6b 65 20 61 20 73 74 72 69 6e 67 20 75 70 70 65 72 63 61 73 | ........-.Make.a.string.uppercas |
30640 | 65 0a 20 2a 20 2d 20 6d 62 5f 73 75 62 73 74 69 74 75 74 65 5f 63 68 61 72 61 63 74 65 72 20 2d | e..*.-.mb_substitute_character.- |
30660 | 20 53 65 74 2f 47 65 74 20 73 75 62 73 74 69 74 75 74 69 6f 6e 20 63 68 61 72 61 63 74 65 72 0a | .Set/Get.substitution.character. |
30680 | 20 2a 20 2d 20 6d 62 5f 73 75 62 73 74 72 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2d 20 47 | .*.-.mb_substr...............-.G |
306a0 | 65 74 20 70 61 72 74 20 6f 66 20 73 74 72 69 6e 67 0a 20 2a 20 2d 20 6d 62 5f 73 74 72 69 70 6f | et.part.of.string..*.-.mb_stripo |
306c0 | 73 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2d 20 46 69 6e 64 73 20 70 6f 73 69 74 69 6f 6e 20 | s..............-.Finds.position. |
306e0 | 6f 66 20 66 69 72 73 74 20 6f 63 63 75 72 72 65 6e 63 65 20 6f 66 20 61 20 73 74 72 69 6e 67 20 | of.first.occurrence.of.a.string. |
30700 | 77 69 74 68 69 6e 20 61 6e 6f 74 68 65 72 2c 20 63 61 73 65 20 69 6e 73 65 6e 73 69 74 69 76 65 | within.another,.case.insensitive |
30720 | 0a 20 2a 20 2d 20 6d 62 5f 73 74 72 69 73 74 72 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2d 20 | ..*.-.mb_stristr..............-. |
30740 | 46 69 6e 64 73 20 66 69 72 73 74 20 6f 63 63 75 72 72 65 6e 63 65 20 6f 66 20 61 20 73 74 72 69 | Finds.first.occurrence.of.a.stri |
30760 | 6e 67 20 77 69 74 68 69 6e 20 61 6e 6f 74 68 65 72 2c 20 63 61 73 65 20 69 6e 73 65 6e 73 69 74 | ng.within.another,.case.insensit |
30780 | 69 76 65 0a 20 2a 20 2d 20 6d 62 5f 73 74 72 72 63 68 72 20 20 20 20 20 20 20 20 20 20 20 20 20 | ive..*.-.mb_strrchr............. |
307a0 | 20 2d 20 46 69 6e 64 73 20 74 68 65 20 6c 61 73 74 20 6f 63 63 75 72 72 65 6e 63 65 20 6f 66 20 | .-.Finds.the.last.occurrence.of. |
307c0 | 61 20 63 68 61 72 61 63 74 65 72 20 69 6e 20 61 20 73 74 72 69 6e 67 20 77 69 74 68 69 6e 20 61 | a.character.in.a.string.within.a |
307e0 | 6e 6f 74 68 65 72 0a 20 2a 20 2d 20 6d 62 5f 73 74 72 72 69 63 68 72 20 20 20 20 20 20 20 20 20 | nother..*.-.mb_strrichr......... |
30800 | 20 20 20 20 2d 20 46 69 6e 64 73 20 74 68 65 20 6c 61 73 74 20 6f 63 63 75 72 72 65 6e 63 65 20 | ....-.Finds.the.last.occurrence. |
30820 | 6f 66 20 61 20 63 68 61 72 61 63 74 65 72 20 69 6e 20 61 20 73 74 72 69 6e 67 20 77 69 74 68 69 | of.a.character.in.a.string.withi |
30840 | 6e 20 61 6e 6f 74 68 65 72 2c 20 63 61 73 65 20 69 6e 73 65 6e 73 69 74 69 76 65 0a 20 2a 20 2d | n.another,.case.insensitive..*.- |
30860 | 20 6d 62 5f 73 74 72 72 69 70 6f 73 20 20 20 20 20 20 20 20 20 20 20 20 20 2d 20 46 69 6e 64 73 | .mb_strripos.............-.Finds |
30880 | 20 70 6f 73 69 74 69 6f 6e 20 6f 66 20 6c 61 73 74 20 6f 63 63 75 72 72 65 6e 63 65 20 6f 66 20 | .position.of.last.occurrence.of. |
308a0 | 61 20 73 74 72 69 6e 67 20 77 69 74 68 69 6e 20 61 6e 6f 74 68 65 72 2c 20 63 61 73 65 20 69 6e | a.string.within.another,.case.in |
308c0 | 73 65 6e 73 69 74 69 76 65 0a 20 2a 20 2d 20 6d 62 5f 73 74 72 73 74 72 20 20 20 20 20 20 20 20 | sensitive..*.-.mb_strstr........ |
308e0 | 20 20 20 20 20 20 20 2d 20 46 69 6e 64 73 20 66 69 72 73 74 20 6f 63 63 75 72 72 65 6e 63 65 20 | .......-.Finds.first.occurrence. |
30900 | 6f 66 20 61 20 73 74 72 69 6e 67 20 77 69 74 68 69 6e 20 61 6e 6f 74 68 65 72 73 0a 20 2a 20 2d | of.a.string.within.anothers..*.- |
30920 | 20 6d 62 5f 73 74 72 77 69 64 74 68 20 20 20 20 20 20 20 20 20 20 20 20 20 2d 20 52 65 74 75 72 | .mb_strwidth.............-.Retur |
30940 | 6e 20 77 69 64 74 68 20 6f 66 20 73 74 72 69 6e 67 0a 20 2a 20 2d 20 6d 62 5f 73 75 62 73 74 72 | n.width.of.string..*.-.mb_substr |
30960 | 5f 63 6f 75 6e 74 20 20 20 20 20 20 20 20 20 2d 20 43 6f 75 6e 74 20 74 68 65 20 6e 75 6d 62 65 | _count.........-.Count.the.numbe |
30980 | 72 20 6f 66 20 73 75 62 73 74 72 69 6e 67 20 6f 63 63 75 72 72 65 6e 63 65 73 0a 20 2a 0a 20 2a | r.of.substring.occurrences..*..* |
309a0 | 20 4e 6f 74 20 69 6d 70 6c 65 6d 65 6e 74 65 64 3a 0a 20 2a 20 2d 20 6d 62 5f 63 6f 6e 76 65 72 | .Not.implemented:..*.-.mb_conver |
309c0 | 74 5f 6b 61 6e 61 20 20 20 20 20 20 20 20 20 2d 20 43 6f 6e 76 65 72 74 20 22 6b 61 6e 61 22 20 | t_kana.........-.Convert."kana". |
309e0 | 6f 6e 65 20 66 72 6f 6d 20 61 6e 6f 74 68 65 72 20 28 22 7a 65 6e 2d 6b 61 6b 75 22 2c 20 22 68 | one.from.another.("zen-kaku",."h |
30a00 | 61 6e 2d 6b 61 6b 75 22 20 61 6e 64 20 6d 6f 72 65 29 0a 20 2a 20 2d 20 6d 62 5f 64 65 63 6f 64 | an-kaku".and.more)..*.-.mb_decod |
30a20 | 65 5f 6e 75 6d 65 72 69 63 65 6e 74 69 74 79 20 2d 20 44 65 63 6f 64 65 20 48 54 4d 4c 20 6e 75 | e_numericentity.-.Decode.HTML.nu |
30a40 | 6d 65 72 69 63 20 73 74 72 69 6e 67 20 72 65 66 65 72 65 6e 63 65 20 74 6f 20 63 68 61 72 61 63 | meric.string.reference.to.charac |
30a60 | 74 65 72 0a 20 2a 20 2d 20 6d 62 5f 65 6e 63 6f 64 65 5f 6e 75 6d 65 72 69 63 65 6e 74 69 74 79 | ter..*.-.mb_encode_numericentity |
30a80 | 20 2d 20 45 6e 63 6f 64 65 20 63 68 61 72 61 63 74 65 72 20 74 6f 20 48 54 4d 4c 20 6e 75 6d 65 | .-.Encode.character.to.HTML.nume |
30aa0 | 72 69 63 20 73 74 72 69 6e 67 20 72 65 66 65 72 65 6e 63 65 0a 20 2a 20 2d 20 6d 62 5f 65 72 65 | ric.string.reference..*.-.mb_ere |
30ac0 | 67 5f 2a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2d 20 52 65 67 75 6c 61 72 20 65 78 70 72 | g_*...............-.Regular.expr |
30ae0 | 65 73 73 69 6f 6e 20 77 69 74 68 20 6d 75 6c 74 69 62 79 74 65 20 73 75 70 70 6f 72 74 0a 20 2a | ession.with.multibyte.support..* |
30b00 | 20 2d 20 6d 62 5f 70 61 72 73 65 5f 73 74 72 20 20 20 20 20 20 20 20 20 20 20 20 2d 20 50 61 72 | .-.mb_parse_str............-.Par |
30b20 | 73 65 20 47 45 54 2f 50 4f 53 54 2f 43 4f 4f 4b 49 45 20 64 61 74 61 20 61 6e 64 20 73 65 74 20 | se.GET/POST/COOKIE.data.and.set. |
30b40 | 67 6c 6f 62 61 6c 20 76 61 72 69 61 62 6c 65 0a 20 2a 20 2d 20 6d 62 5f 70 72 65 66 65 72 72 65 | global.variable..*.-.mb_preferre |
30b60 | 64 5f 6d 69 6d 65 5f 6e 61 6d 65 20 20 2d 20 47 65 74 20 4d 49 4d 45 20 63 68 61 72 73 65 74 20 | d_mime_name..-.Get.MIME.charset. |
30b80 | 73 74 72 69 6e 67 0a 20 2a 20 2d 20 6d 62 5f 72 65 67 65 78 5f 65 6e 63 6f 64 69 6e 67 20 20 20 | string..*.-.mb_regex_encoding... |
30ba0 | 20 20 20 20 2d 20 52 65 74 75 72 6e 73 20 63 75 72 72 65 6e 74 20 65 6e 63 6f 64 69 6e 67 20 66 | ....-.Returns.current.encoding.f |
30bc0 | 6f 72 20 6d 75 6c 74 69 62 79 74 65 20 72 65 67 65 78 20 61 73 20 73 74 72 69 6e 67 0a 20 2a 20 | or.multibyte.regex.as.string..*. |
30be0 | 2d 20 6d 62 5f 72 65 67 65 78 5f 73 65 74 5f 6f 70 74 69 6f 6e 73 20 20 20 20 2d 20 53 65 74 2f | -.mb_regex_set_options....-.Set/ |
30c00 | 47 65 74 20 74 68 65 20 64 65 66 61 75 6c 74 20 6f 70 74 69 6f 6e 73 20 66 6f 72 20 6d 62 72 65 | Get.the.default.options.for.mbre |
30c20 | 67 65 78 20 66 75 6e 63 74 69 6f 6e 73 0a 20 2a 20 2d 20 6d 62 5f 73 65 6e 64 5f 6d 61 69 6c 20 | gex.functions..*.-.mb_send_mail. |
30c40 | 20 20 20 20 20 20 20 20 20 20 20 2d 20 53 65 6e 64 20 65 6e 63 6f 64 65 64 20 6d 61 69 6c 0a 20 | ...........-.Send.encoded.mail.. |
30c60 | 2a 20 2d 20 6d 62 5f 73 70 6c 69 74 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2d 20 53 70 | *.-.mb_split................-.Sp |
30c80 | 6c 69 74 20 6d 75 6c 74 69 62 79 74 65 20 73 74 72 69 6e 67 20 75 73 69 6e 67 20 72 65 67 75 6c | lit.multibyte.string.using.regul |
30ca0 | 61 72 20 65 78 70 72 65 73 73 69 6f 6e 0a 20 2a 20 2d 20 6d 62 5f 73 74 72 63 75 74 20 20 20 20 | ar.expression..*.-.mb_strcut.... |
30cc0 | 20 20 20 20 20 20 20 20 20 20 20 2d 20 47 65 74 20 70 61 72 74 20 6f 66 20 73 74 72 69 6e 67 0a | ...........-.Get.part.of.string. |
30ce0 | 20 2a 20 2d 20 6d 62 5f 73 74 72 69 6d 77 69 64 74 68 20 20 20 20 20 20 20 20 20 20 20 2d 20 47 | .*.-.mb_strimwidth...........-.G |
30d00 | 65 74 20 74 72 75 6e 63 61 74 65 64 20 73 74 72 69 6e 67 20 77 69 74 68 20 73 70 65 63 69 66 69 | et.truncated.string.with.specifi |
30d20 | 65 64 20 77 69 64 74 68 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 4e 69 63 6f 6c 61 73 20 47 | ed.width..*..*.@author.Nicolas.G |
30d40 | 72 65 6b 61 73 20 3c 70 40 74 63 68 77 6f 72 6b 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 40 69 6e 74 | rekas.<p@tchwork.com>..*..*.@int |
30d60 | 65 72 6e 61 6c 0a 20 2a 2f 0a 66 69 6e 61 6c 20 63 6c 61 73 73 20 4d 62 73 74 72 69 6e 67 0a 7b | ernal..*/.final.class.Mbstring.{ |
30d80 | 0a 20 20 20 20 63 6f 6e 73 74 20 4d 42 5f 43 41 53 45 5f 46 4f 4c 44 20 3d 20 50 48 50 5f 49 4e | .....const.MB_CASE_FOLD.=.PHP_IN |
30da0 | 54 5f 4d 41 58 3b 0a 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 24 65 6e 63 6f | T_MAX;......private.static.$enco |
30dc0 | 64 69 6e 67 4c 69 73 74 20 3d 20 61 72 72 61 79 28 27 41 53 43 49 49 27 2c 20 27 55 54 46 2d 38 | dingList.=.array('ASCII',.'UTF-8 |
30de0 | 27 29 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 24 6c 61 6e 67 75 61 67 65 | ');.....private.static.$language |
30e00 | 20 3d 20 27 6e 65 75 74 72 61 6c 27 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 | .=.'neutral';.....private.static |
30e20 | 20 24 69 6e 74 65 72 6e 61 6c 45 6e 63 6f 64 69 6e 67 20 3d 20 27 55 54 46 2d 38 27 3b 0a 20 20 | .$internalEncoding.=.'UTF-8';... |
30e40 | 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 24 63 61 73 65 46 6f 6c 64 20 3d 20 61 72 72 | ..private.static.$caseFold.=.arr |
30e60 | 61 79 28 0a 20 20 20 20 20 20 20 20 61 72 72 61 79 28 27 c2 b5 27 2c 27 c5 bf 27 2c 22 5c 78 43 | ay(.........array('..','..',"\xC |
30e80 | 44 5c 78 38 35 22 2c 27 cf 82 27 2c 22 5c 78 43 46 5c 78 39 30 22 2c 22 5c 78 43 46 5c 78 39 31 | D\x85",'..',"\xCF\x90","\xCF\x91 |
30ea0 | 22 2c 22 5c 78 43 46 5c 78 39 35 22 2c 22 5c 78 43 46 5c 78 39 36 22 2c 22 5c 78 43 46 5c 78 42 | ","\xCF\x95","\xCF\x96","\xCF\xB |
30ec0 | 30 22 2c 22 5c 78 43 46 5c 78 42 31 22 2c 22 5c 78 43 46 5c 78 42 35 22 2c 22 5c 78 45 31 5c 78 | 0","\xCF\xB1","\xCF\xB5","\xE1\x |
30ee0 | 42 41 5c 78 39 42 22 2c 22 5c 78 45 31 5c 78 42 45 5c 78 42 45 22 29 2c 0a 20 20 20 20 20 20 20 | BA\x9B","\xE1\xBE\xBE"),........ |
30f00 | 20 61 72 72 61 79 28 27 ce bc 27 2c 27 73 27 2c 27 ce b9 27 2c 20 20 20 20 20 20 20 27 cf 83 27 | .array('..','s','..',.......'..' |
30f20 | 2c 27 ce b2 27 2c 20 20 20 20 20 20 20 27 ce b8 27 2c 20 20 20 20 20 20 20 27 cf 86 27 2c 20 20 | ,'..',.......'..',.......'..',.. |
30f40 | 20 20 20 20 20 27 cf 80 27 2c 20 20 20 20 20 20 20 27 ce ba 27 2c 20 20 20 20 20 20 20 27 cf 81 | .....'..',.......'..',.......'.. |
30f60 | 27 2c 20 20 20 20 20 20 20 27 ce b5 27 2c 20 20 20 20 20 20 20 22 5c 78 45 31 5c 78 42 39 5c 78 | ',.......'..',......."\xE1\xB9\x |
30f80 | 41 31 22 2c 27 ce b9 27 29 2c 0a 20 20 20 20 29 3b 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 | A1",'..'),.....);......public.st |
30fa0 | 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 63 6f 6e 76 65 72 74 5f 65 6e 63 6f 64 69 6e | atic.function.mb_convert_encodin |
30fc0 | 67 28 24 73 2c 20 24 74 6f 45 6e 63 6f 64 69 6e 67 2c 20 24 66 72 6f 6d 45 6e 63 6f 64 69 6e 67 | g($s,.$toEncoding,.$fromEncoding |
30fe0 | 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 69 73 5f 61 72 | .=.null).....{.........if.(is_ar |
31000 | 72 61 79 28 24 66 72 6f 6d 45 6e 63 6f 64 69 6e 67 29 20 7c 7c 20 66 61 6c 73 65 20 21 3d 3d 20 | ray($fromEncoding).||.false.!==. |
31020 | 73 74 72 70 6f 73 28 24 66 72 6f 6d 45 6e 63 6f 64 69 6e 67 2c 20 27 2c 27 29 29 20 7b 0a 20 20 | strpos($fromEncoding,.',')).{... |
31040 | 20 20 20 20 20 20 20 20 20 20 24 66 72 6f 6d 45 6e 63 6f 64 69 6e 67 20 3d 20 73 65 6c 66 3a 3a | ..........$fromEncoding.=.self:: |
31060 | 6d 62 5f 64 65 74 65 63 74 5f 65 6e 63 6f 64 69 6e 67 28 24 73 2c 20 24 66 72 6f 6d 45 6e 63 6f | mb_detect_encoding($s,.$fromEnco |
31080 | 64 69 6e 67 29 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 | ding);.........}.else.{......... |
310a0 | 20 20 20 20 24 66 72 6f 6d 45 6e 63 6f 64 69 6e 67 20 3d 20 73 65 6c 66 3a 3a 67 65 74 45 6e 63 | ....$fromEncoding.=.self::getEnc |
310c0 | 6f 64 69 6e 67 28 24 66 72 6f 6d 45 6e 63 6f 64 69 6e 67 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a | oding($fromEncoding);.........}. |
310e0 | 0a 20 20 20 20 20 20 20 20 24 74 6f 45 6e 63 6f 64 69 6e 67 20 3d 20 73 65 6c 66 3a 3a 67 65 74 | .........$toEncoding.=.self::get |
31100 | 45 6e 63 6f 64 69 6e 67 28 24 74 6f 45 6e 63 6f 64 69 6e 67 29 3b 0a 0a 20 20 20 20 20 20 20 20 | Encoding($toEncoding);.......... |
31120 | 69 66 20 28 27 42 41 53 45 36 34 27 20 3d 3d 3d 20 24 66 72 6f 6d 45 6e 63 6f 64 69 6e 67 29 20 | if.('BASE64'.===.$fromEncoding). |
31140 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 73 20 3d 20 62 61 73 65 36 34 5f 64 65 63 6f 64 65 | {.............$s.=.base64_decode |
31160 | 28 24 73 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 66 72 6f 6d 45 6e 63 6f 64 69 6e 67 20 | ($s);.............$fromEncoding. |
31180 | 3d 20 24 74 6f 45 6e 63 6f 64 69 6e 67 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 | =.$toEncoding;.........}........ |
311a0 | 20 20 69 66 20 28 27 42 41 53 45 36 34 27 20 3d 3d 3d 20 24 74 6f 45 6e 63 6f 64 69 6e 67 29 20 | ..if.('BASE64'.===.$toEncoding). |
311c0 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 62 61 73 65 36 34 5f 65 6e 63 6f | {.............return.base64_enco |
311e0 | 64 65 28 24 73 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 27 | de($s);.........}..........if.(' |
31200 | 48 54 4d 4c 2d 45 4e 54 49 54 49 45 53 27 20 3d 3d 3d 20 24 74 6f 45 6e 63 6f 64 69 6e 67 20 7c | HTML-ENTITIES'.===.$toEncoding.| |
31220 | 7c 20 27 48 54 4d 4c 27 20 3d 3d 3d 20 24 74 6f 45 6e 63 6f 64 69 6e 67 29 20 7b 0a 20 20 20 20 | |.'HTML'.===.$toEncoding).{..... |
31240 | 20 20 20 20 20 20 20 20 69 66 20 28 27 48 54 4d 4c 2d 45 4e 54 49 54 49 45 53 27 20 3d 3d 3d 20 | ........if.('HTML-ENTITIES'.===. |
31260 | 24 66 72 6f 6d 45 6e 63 6f 64 69 6e 67 20 7c 7c 20 27 48 54 4d 4c 27 20 3d 3d 3d 20 24 66 72 6f | $fromEncoding.||.'HTML'.===.$fro |
31280 | 6d 45 6e 63 6f 64 69 6e 67 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 66 72 | mEncoding).{.................$fr |
312a0 | 6f 6d 45 6e 63 6f 64 69 6e 67 20 3d 20 27 57 69 6e 64 6f 77 73 2d 31 32 35 32 27 3b 0a 20 20 20 | omEncoding.=.'Windows-1252';.... |
312c0 | 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 27 55 54 46 2d | .........}.............if.('UTF- |
312e0 | 38 27 20 21 3d 3d 20 24 66 72 6f 6d 45 6e 63 6f 64 69 6e 67 29 20 7b 0a 20 20 20 20 20 20 20 20 | 8'.!==.$fromEncoding).{......... |
31300 | 20 20 20 20 20 20 20 20 24 73 20 3d 20 69 63 6f 6e 76 28 24 66 72 6f 6d 45 6e 63 6f 64 69 6e 67 | ........$s.=.iconv($fromEncoding |
31320 | 2c 20 27 55 54 46 2d 38 27 2c 20 24 73 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 | ,.'UTF-8',.$s);.............}... |
31340 | 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 70 72 65 67 5f 72 65 70 6c 61 63 65 5f 63 | ...........return.preg_replace_c |
31360 | 61 6c 6c 62 61 63 6b 28 27 2f 5b 5c 78 38 30 2d 5c 78 46 46 5d 2b 2f 27 2c 20 61 72 72 61 79 28 | allback('/[\x80-\xFF]+/',.array( |
31380 | 5f 5f 43 4c 41 53 53 5f 5f 2c 20 27 68 74 6d 6c 5f 65 6e 63 6f 64 69 6e 67 5f 63 61 6c 6c 62 61 | __CLASS__,.'html_encoding_callba |
313a0 | 63 6b 27 29 2c 20 24 73 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 | ck'),.$s);.........}..........if |
313c0 | 20 28 27 48 54 4d 4c 2d 45 4e 54 49 54 49 45 53 27 20 3d 3d 3d 20 24 66 72 6f 6d 45 6e 63 6f 64 | .('HTML-ENTITIES'.===.$fromEncod |
313e0 | 69 6e 67 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 73 20 3d 20 68 74 6d 6c 5f 65 6e 74 | ing).{.............$s.=.html_ent |
31400 | 69 74 79 5f 64 65 63 6f 64 65 28 24 73 2c 20 45 4e 54 5f 43 4f 4d 50 41 54 2c 20 27 55 54 46 2d | ity_decode($s,.ENT_COMPAT,.'UTF- |
31420 | 38 27 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 66 72 6f 6d 45 6e 63 6f 64 69 6e 67 20 3d | 8');.............$fromEncoding.= |
31440 | 20 27 55 54 46 2d 38 27 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 | .'UTF-8';.........}..........ret |
31460 | 75 72 6e 20 69 63 6f 6e 76 28 24 66 72 6f 6d 45 6e 63 6f 64 69 6e 67 2c 20 24 74 6f 45 6e 63 6f | urn.iconv($fromEncoding,.$toEnco |
31480 | 64 69 6e 67 2c 20 24 73 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 | ding,.$s);.....}......public.sta |
314a0 | 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 63 6f 6e 76 65 72 74 5f 76 61 72 69 61 62 6c 65 | tic.function.mb_convert_variable |
314c0 | 73 28 24 74 6f 45 6e 63 6f 64 69 6e 67 2c 20 24 66 72 6f 6d 45 6e 63 6f 64 69 6e 67 2c 20 26 24 | s($toEncoding,.$fromEncoding,.&$ |
314e0 | 61 20 3d 20 6e 75 6c 6c 2c 20 26 24 62 20 3d 20 6e 75 6c 6c 2c 20 26 24 63 20 3d 20 6e 75 6c 6c | a.=.null,.&$b.=.null,.&$c.=.null |
31500 | 2c 20 26 24 64 20 3d 20 6e 75 6c 6c 2c 20 26 24 65 20 3d 20 6e 75 6c 6c 2c 20 26 24 66 20 3d 20 | ,.&$d.=.null,.&$e.=.null,.&$f.=. |
31520 | 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 76 61 72 73 20 3d 20 61 72 72 61 | null).....{.........$vars.=.arra |
31540 | 79 28 26 24 61 2c 20 26 24 62 2c 20 26 24 63 2c 20 26 24 64 2c 20 26 24 65 2c 20 26 24 66 29 3b | y(&$a,.&$b,.&$c,.&$d,.&$e,.&$f); |
31560 | 0a 0a 20 20 20 20 20 20 20 20 24 6f 6b 20 3d 20 74 72 75 65 3b 0a 20 20 20 20 20 20 20 20 61 72 | ..........$ok.=.true;.........ar |
31580 | 72 61 79 5f 77 61 6c 6b 5f 72 65 63 75 72 73 69 76 65 28 24 76 61 72 73 2c 20 66 75 6e 63 74 69 | ray_walk_recursive($vars,.functi |
315a0 | 6f 6e 20 28 26 24 76 29 20 75 73 65 20 28 26 24 6f 6b 2c 20 24 74 6f 45 6e 63 6f 64 69 6e 67 2c | on.(&$v).use.(&$ok,.$toEncoding, |
315c0 | 20 24 66 72 6f 6d 45 6e 63 6f 64 69 6e 67 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 | .$fromEncoding).{.............if |
315e0 | 20 28 66 61 6c 73 65 20 3d 3d 3d 20 24 76 20 3d 20 4d 62 73 74 72 69 6e 67 3a 3a 6d 62 5f 63 6f | .(false.===.$v.=.Mbstring::mb_co |
31600 | 6e 76 65 72 74 5f 65 6e 63 6f 64 69 6e 67 28 24 76 2c 20 24 74 6f 45 6e 63 6f 64 69 6e 67 2c 20 | nvert_encoding($v,.$toEncoding,. |
31620 | 24 66 72 6f 6d 45 6e 63 6f 64 69 6e 67 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | $fromEncoding)).{............... |
31640 | 20 20 24 6f 6b 20 3d 20 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 | ..$ok.=.false;.............}.... |
31660 | 20 20 20 20 20 7d 29 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 6f 6b 20 3f 20 24 | .....});..........return.$ok.?.$ |
31680 | 66 72 6f 6d 45 6e 63 6f 64 69 6e 67 20 3a 20 66 61 6c 73 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 | fromEncoding.:.false;.....}..... |
316a0 | 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 64 65 63 6f 64 | .public.static.function.mb_decod |
316c0 | 65 5f 6d 69 6d 65 68 65 61 64 65 72 28 24 73 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 | e_mimeheader($s).....{.........r |
316e0 | 65 74 75 72 6e 20 69 63 6f 6e 76 5f 6d 69 6d 65 5f 64 65 63 6f 64 65 28 24 73 2c 20 32 2c 20 73 | eturn.iconv_mime_decode($s,.2,.s |
31700 | 65 6c 66 3a 3a 24 69 6e 74 65 72 6e 61 6c 45 6e 63 6f 64 69 6e 67 29 3b 0a 20 20 20 20 7d 0a 0a | elf::$internalEncoding);.....}.. |
31720 | 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 65 6e | ....public.static.function.mb_en |
31740 | 63 6f 64 65 5f 6d 69 6d 65 68 65 61 64 65 72 28 24 73 2c 20 24 63 68 61 72 73 65 74 20 3d 20 6e | code_mimeheader($s,.$charset.=.n |
31760 | 75 6c 6c 2c 20 24 74 72 61 6e 73 66 65 72 45 6e 63 6f 64 69 6e 67 20 3d 20 6e 75 6c 6c 2c 20 24 | ull,.$transferEncoding.=.null,.$ |
31780 | 6c 69 6e 65 66 65 65 64 20 3d 20 6e 75 6c 6c 2c 20 24 69 6e 64 65 6e 74 20 3d 20 6e 75 6c 6c 29 | linefeed.=.null,.$indent.=.null) |
317a0 | 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 74 72 69 67 67 65 72 5f 65 72 72 6f 72 28 27 6d 62 | .....{.........trigger_error('mb |
317c0 | 5f 65 6e 63 6f 64 65 5f 6d 69 6d 65 68 65 61 64 65 72 28 29 20 69 73 20 62 75 67 67 65 64 2e 20 | _encode_mimeheader().is.bugged.. |
317e0 | 50 6c 65 61 73 65 20 75 73 65 20 69 63 6f 6e 76 5f 6d 69 6d 65 5f 65 6e 63 6f 64 65 28 29 20 69 | Please.use.iconv_mime_encode().i |
31800 | 6e 73 74 65 61 64 27 2c 20 45 5f 55 53 45 52 5f 57 41 52 4e 49 4e 47 29 3b 0a 20 20 20 20 7d 0a | nstead',.E_USER_WARNING);.....}. |
31820 | 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 63 | .....public.static.function.mb_c |
31840 | 6f 6e 76 65 72 74 5f 63 61 73 65 28 24 73 2c 20 24 6d 6f 64 65 2c 20 24 65 6e 63 6f 64 69 6e 67 | onvert_case($s,.$mode,.$encoding |
31860 | 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 27 27 20 3d 3d | .=.null).....{.........if.(''.== |
31880 | 3d 20 24 73 20 2e 3d 20 27 27 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e | =.$s..=.'').{.............return |
318a0 | 20 27 27 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 65 6e 63 6f 64 69 6e | .'';.........}..........$encodin |
318c0 | 67 20 3d 20 73 65 6c 66 3a 3a 67 65 74 45 6e 63 6f 64 69 6e 67 28 24 65 6e 63 6f 64 69 6e 67 29 | g.=.self::getEncoding($encoding) |
318e0 | 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 27 55 54 46 2d 38 27 20 3d 3d 3d 20 24 65 6e 63 6f | ;..........if.('UTF-8'.===.$enco |
31900 | 64 69 6e 67 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 65 6e 63 6f 64 69 6e 67 20 3d 20 | ding).{.............$encoding.=. |
31920 | 6e 75 6c 6c 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 | null;.........}.else.{.......... |
31940 | 20 20 20 24 73 20 3d 20 69 63 6f 6e 76 28 24 65 6e 63 6f 64 69 6e 67 2c 20 27 55 54 46 2d 38 27 | ...$s.=.iconv($encoding,.'UTF-8' |
31960 | 2c 20 24 73 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 4d 42 | ,.$s);.........}..........if.(MB |
31980 | 5f 43 41 53 45 5f 54 49 54 4c 45 20 3d 3d 20 24 6d 6f 64 65 29 20 7b 0a 20 20 20 20 20 20 20 20 | _CASE_TITLE.==.$mode).{......... |
319a0 | 20 20 20 20 24 73 20 3d 20 70 72 65 67 5f 72 65 70 6c 61 63 65 5f 63 61 6c 6c 62 61 63 6b 28 27 | ....$s.=.preg_replace_callback(' |
319c0 | 2f 5c 62 5c 70 7b 4c 6c 7d 2f 75 27 2c 20 61 72 72 61 79 28 5f 5f 43 4c 41 53 53 5f 5f 2c 20 27 | /\b\p{Ll}/u',.array(__CLASS__,.' |
319e0 | 74 69 74 6c 65 5f 63 61 73 65 5f 75 70 70 65 72 27 29 2c 20 24 73 29 3b 0a 20 20 20 20 20 20 20 | title_case_upper'),.$s);........ |
31a00 | 20 20 20 20 20 24 73 20 3d 20 70 72 65 67 5f 72 65 70 6c 61 63 65 5f 63 61 6c 6c 62 61 63 6b 28 | .....$s.=.preg_replace_callback( |
31a20 | 27 2f 5c 42 5b 5c 70 7b 4c 75 7d 5c 70 7b 4c 74 7d 5d 2b 2f 75 27 2c 20 61 72 72 61 79 28 5f 5f | '/\B[\p{Lu}\p{Lt}]+/u',.array(__ |
31a40 | 43 4c 41 53 53 5f 5f 2c 20 27 74 69 74 6c 65 5f 63 61 73 65 5f 6c 6f 77 65 72 27 29 2c 20 24 73 | CLASS__,.'title_case_lower'),.$s |
31a60 | 29 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | );.........}.else.{............. |
31a80 | 69 66 20 28 4d 42 5f 43 41 53 45 5f 55 50 50 45 52 20 3d 3d 20 24 6d 6f 64 65 29 20 7b 0a 20 20 | if.(MB_CASE_UPPER.==.$mode).{... |
31aa0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 73 74 61 74 69 63 20 24 75 70 70 65 72 20 3d 20 6e 75 | ..............static.$upper.=.nu |
31ac0 | 6c 6c 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d | ll;.................if.(null.=== |
31ae0 | 20 24 75 70 70 65 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 | .$upper).{.....................$ |
31b00 | 75 70 70 65 72 20 3d 20 73 65 6c 66 3a 3a 67 65 74 44 61 74 61 28 27 75 70 70 65 72 43 61 73 65 | upper.=.self::getData('upperCase |
31b20 | 27 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 | ');.................}........... |
31b40 | 20 20 20 20 20 20 24 6d 61 70 20 3d 20 24 75 70 70 65 72 3b 0a 20 20 20 20 20 20 20 20 20 20 20 | ......$map.=.$upper;............ |
31b60 | 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 73 65 | .}.else.{.................if.(se |
31b80 | 6c 66 3a 3a 4d 42 5f 43 41 53 45 5f 46 4f 4c 44 20 3d 3d 3d 20 24 6d 6f 64 65 29 20 7b 0a 20 20 | lf::MB_CASE_FOLD.===.$mode).{... |
31ba0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 73 20 3d 20 73 74 72 5f 72 65 70 6c 61 | ..................$s.=.str_repla |
31bc0 | 63 65 28 73 65 6c 66 3a 3a 24 63 61 73 65 46 6f 6c 64 5b 30 5d 2c 20 73 65 6c 66 3a 3a 24 63 61 | ce(self::$caseFold[0],.self::$ca |
31be0 | 73 65 46 6f 6c 64 5b 31 5d 2c 20 24 73 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | seFold[1],.$s);................. |
31c00 | 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 73 74 61 74 69 63 20 24 6c 6f 77 65 72 | }..................static.$lower |
31c20 | 20 3d 20 6e 75 6c 6c 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c | .=.null;.................if.(nul |
31c40 | 6c 20 3d 3d 3d 20 24 6c 6f 77 65 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | l.===.$lower).{................. |
31c60 | 20 20 20 20 24 6c 6f 77 65 72 20 3d 20 73 65 6c 66 3a 3a 67 65 74 44 61 74 61 28 27 6c 6f 77 65 | ....$lower.=.self::getData('lowe |
31c80 | 72 43 61 73 65 27 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 | rCase');.................}...... |
31ca0 | 20 20 20 20 20 20 20 20 20 20 20 24 6d 61 70 20 3d 20 24 6c 6f 77 65 72 3b 0a 20 20 20 20 20 20 | ...........$map.=.$lower;....... |
31cc0 | 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 73 74 61 74 69 63 20 24 75 6c 65 | ......}..............static.$ule |
31ce0 | 6e 4d 61 73 6b 20 3d 20 61 72 72 61 79 28 22 5c 78 43 30 22 20 3d 3e 20 32 2c 20 22 5c 78 44 30 | nMask.=.array("\xC0".=>.2,."\xD0 |
31d00 | 22 20 3d 3e 20 32 2c 20 22 5c 78 45 30 22 20 3d 3e 20 33 2c 20 22 5c 78 46 30 22 20 3d 3e 20 34 | ".=>.2,."\xE0".=>.3,."\xF0".=>.4 |
31d20 | 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 69 20 3d 20 30 3b 0a 20 20 20 20 20 20 20 20 | );..............$i.=.0;......... |
31d40 | 20 20 20 20 24 6c 65 6e 20 3d 20 73 74 72 6c 65 6e 28 24 73 29 3b 0a 0a 20 20 20 20 20 20 20 20 | ....$len.=.strlen($s);.......... |
31d60 | 20 20 20 20 77 68 69 6c 65 20 28 24 69 20 3c 20 24 6c 65 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 | ....while.($i.<.$len).{......... |
31d80 | 20 20 20 20 20 20 20 20 24 75 6c 65 6e 20 3d 20 24 73 5b 24 69 5d 20 3c 20 22 5c 78 38 30 22 20 | ........$ulen.=.$s[$i].<."\x80". |
31da0 | 3f 20 31 20 3a 20 24 75 6c 65 6e 4d 61 73 6b 5b 24 73 5b 24 69 5d 20 26 20 22 5c 78 46 30 22 5d | ?.1.:.$ulenMask[$s[$i].&."\xF0"] |
31dc0 | 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 75 63 68 72 20 3d 20 73 75 62 73 74 72 | ;.................$uchr.=.substr |
31de0 | 28 24 73 2c 20 24 69 2c 20 24 75 6c 65 6e 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ($s,.$i,.$ulen);................ |
31e00 | 20 24 69 20 2b 3d 20 24 75 6c 65 6e 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 | .$i.+=.$ulen;..................i |
31e20 | 66 20 28 69 73 73 65 74 28 24 6d 61 70 5b 24 75 63 68 72 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 | f.(isset($map[$uchr])).{........ |
31e40 | 20 20 20 20 20 20 20 20 20 20 20 20 20 24 75 63 68 72 20 3d 20 24 6d 61 70 5b 24 75 63 68 72 5d | .............$uchr.=.$map[$uchr] |
31e60 | 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6e 6c 65 6e 20 3d 20 73 74 | ;.....................$nlen.=.st |
31e80 | 72 6c 65 6e 28 24 75 63 68 72 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | rlen($uchr);.................... |
31ea0 | 20 20 69 66 20 28 24 6e 6c 65 6e 20 3d 3d 20 24 75 6c 65 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 | ..if.($nlen.==.$ulen).{......... |
31ec0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6e 6c 65 6e 20 3d 20 24 69 3b 0a 20 20 20 20 | ................$nlen.=.$i;..... |
31ee0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 64 6f 20 7b 0a 20 20 20 20 20 20 20 | ....................do.{........ |
31f00 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 73 5b 2d 2d 24 6e 6c 65 6e 5d | .....................$s[--$nlen] |
31f20 | 20 3d 20 24 75 63 68 72 5b 2d 2d 24 75 6c 65 6e 5d 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | .=.$uchr[--$ulen];.............. |
31f40 | 20 20 20 20 20 20 20 20 20 20 20 7d 20 77 68 69 6c 65 20 28 24 75 6c 65 6e 29 3b 0a 20 20 20 20 | ...........}.while.($ulen);..... |
31f60 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 | ................}.else.{........ |
31f80 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 73 20 3d 20 73 75 62 73 74 72 5f 72 65 70 | .................$s.=.substr_rep |
31fa0 | 6c 61 63 65 28 24 73 2c 20 24 75 63 68 72 2c 20 24 69 20 2d 20 24 75 6c 65 6e 2c 20 24 75 6c 65 | lace($s,.$uchr,.$i.-.$ulen,.$ule |
31fc0 | 6e 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 65 6e | n);.........................$len |
31fe0 | 20 2b 3d 20 24 6e 6c 65 6e 20 2d 20 24 75 6c 65 6e 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | .+=.$nlen.-.$ulen;.............. |
32000 | 20 20 20 20 20 20 20 20 20 20 20 24 69 20 20 20 2b 3d 20 24 6e 6c 65 6e 20 2d 20 24 75 6c 65 6e | ...........$i...+=.$nlen.-.$ulen |
32020 | 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 | ;.....................}......... |
32040 | 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 | ........}.............}......... |
32060 | 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 65 6e 63 6f 64 69 6e | }..........if.(null.===.$encodin |
32080 | 67 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 73 3b 0a 20 20 20 20 | g).{.............return.$s;..... |
320a0 | 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 69 63 6f 6e 76 28 27 55 54 46 | ....}..........return.iconv('UTF |
320c0 | 2d 38 27 2c 20 24 65 6e 63 6f 64 69 6e 67 2c 20 24 73 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 | -8',.$encoding,.$s);.....}...... |
320e0 | 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 69 6e 74 65 72 6e | public.static.function.mb_intern |
32100 | 61 6c 5f 65 6e 63 6f 64 69 6e 67 28 24 65 6e 63 6f 64 69 6e 67 20 3d 20 6e 75 6c 6c 29 0a 20 20 | al_encoding($encoding.=.null)... |
32120 | 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 65 6e 63 6f 64 69 | ..{.........if.(null.===.$encodi |
32140 | 6e 67 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 3a 3a 24 | ng).{.............return.self::$ |
32160 | 69 6e 74 65 72 6e 61 6c 45 6e 63 6f 64 69 6e 67 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 | internalEncoding;.........}..... |
32180 | 20 20 20 20 20 24 65 6e 63 6f 64 69 6e 67 20 3d 20 73 65 6c 66 3a 3a 67 65 74 45 6e 63 6f 64 69 | .....$encoding.=.self::getEncodi |
321a0 | 6e 67 28 24 65 6e 63 6f 64 69 6e 67 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 27 55 54 46 | ng($encoding);..........if.('UTF |
321c0 | 2d 38 27 20 3d 3d 3d 20 24 65 6e 63 6f 64 69 6e 67 20 7c 7c 20 66 61 6c 73 65 20 21 3d 3d 20 40 | -8'.===.$encoding.||.false.!==.@ |
321e0 | 69 63 6f 6e 76 28 24 65 6e 63 6f 64 69 6e 67 2c 20 24 65 6e 63 6f 64 69 6e 67 2c 20 27 20 27 29 | iconv($encoding,.$encoding,.'.') |
32200 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 73 65 6c 66 3a 3a 24 69 6e 74 65 72 6e 61 6c 45 | ).{.............self::$internalE |
32220 | 6e 63 6f 64 69 6e 67 20 3d 20 24 65 6e 63 6f 64 69 6e 67 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 | ncoding.=.$encoding;............ |
32240 | 20 20 72 65 74 75 72 6e 20 74 72 75 65 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 | ..return.true;.........}........ |
32260 | 20 20 72 65 74 75 72 6e 20 66 61 6c 73 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 | ..return.false;.....}......publi |
32280 | 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 6c 61 6e 67 75 61 67 65 28 24 6c | c.static.function.mb_language($l |
322a0 | 61 6e 67 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 | ang.=.null).....{.........if.(nu |
322c0 | 6c 6c 20 3d 3d 3d 20 24 6c 61 6e 67 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 | ll.===.$lang).{.............retu |
322e0 | 72 6e 20 73 65 6c 66 3a 3a 24 6c 61 6e 67 75 61 67 65 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 | rn.self::$language;.........}... |
32300 | 20 20 20 20 20 20 20 73 77 69 74 63 68 20 28 24 6c 61 6e 67 20 3d 20 73 74 72 74 6f 6c 6f 77 65 | .......switch.($lang.=.strtolowe |
32320 | 72 28 24 6c 61 6e 67 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 63 61 73 65 20 27 75 6e | r($lang)).{.............case.'un |
32340 | 69 27 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 63 61 73 65 20 27 6e 65 75 74 72 61 6c 27 3a 0a | i':.............case.'neutral':. |
32360 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 73 65 6c 66 3a 3a 24 6c 61 6e 67 75 61 67 65 20 | ................self::$language. |
32380 | 3d 20 24 6c 61 6e 67 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e | =.$lang;..................return |
323a0 | 20 74 72 75 65 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e | .true;.........}..........return |
323c0 | 20 66 61 6c 73 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 | .false;.....}......public.static |
323e0 | 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 6c 69 73 74 5f 65 6e 63 6f 64 69 6e 67 73 28 29 0a 20 20 | .function.mb_list_encodings()... |
32400 | 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 61 72 72 61 79 28 27 55 54 46 2d 38 27 | ..{.........return.array('UTF-8' |
32420 | 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 | );.....}......public.static.func |
32440 | 74 69 6f 6e 20 6d 62 5f 65 6e 63 6f 64 69 6e 67 5f 61 6c 69 61 73 65 73 28 24 65 6e 63 6f 64 69 | tion.mb_encoding_aliases($encodi |
32460 | 6e 67 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 73 77 69 74 63 68 20 28 73 74 72 74 6f 75 | ng).....{.........switch.(strtou |
32480 | 70 70 65 72 28 24 65 6e 63 6f 64 69 6e 67 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 63 | pper($encoding)).{.............c |
324a0 | 61 73 65 20 27 55 54 46 38 27 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 63 61 73 65 20 27 55 54 | ase.'UTF8':.............case.'UT |
324c0 | 46 2d 38 27 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 61 72 72 | F-8':.................return.arr |
324e0 | 61 79 28 27 75 74 66 38 27 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 | ay('utf8');.........}..........r |
32500 | 65 74 75 72 6e 20 66 61 6c 73 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 73 | eturn.false;.....}......public.s |
32520 | 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 63 68 65 63 6b 5f 65 6e 63 6f 64 69 6e 67 | tatic.function.mb_check_encoding |
32540 | 28 24 76 61 72 20 3d 20 6e 75 6c 6c 2c 20 24 65 6e 63 6f 64 69 6e 67 20 3d 20 6e 75 6c 6c 29 0a | ($var.=.null,.$encoding.=.null). |
32560 | 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 65 6e 63 6f | ....{.........if.(null.===.$enco |
32580 | 64 69 6e 67 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d | ding).{.............if.(null.=== |
325a0 | 20 24 76 61 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 | .$var).{.................return. |
325c0 | 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 | false;.............}............ |
325e0 | 20 24 65 6e 63 6f 64 69 6e 67 20 3d 20 73 65 6c 66 3a 3a 24 69 6e 74 65 72 6e 61 6c 45 6e 63 6f | .$encoding.=.self::$internalEnco |
32600 | 64 69 6e 67 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 | ding;.........}..........return. |
32620 | 73 65 6c 66 3a 3a 6d 62 5f 64 65 74 65 63 74 5f 65 6e 63 6f 64 69 6e 67 28 24 76 61 72 2c 20 61 | self::mb_detect_encoding($var,.a |
32640 | 72 72 61 79 28 24 65 6e 63 6f 64 69 6e 67 29 29 20 7c 7c 20 66 61 6c 73 65 20 21 3d 3d 20 40 69 | rray($encoding)).||.false.!==.@i |
32660 | 63 6f 6e 76 28 24 65 6e 63 6f 64 69 6e 67 2c 20 24 65 6e 63 6f 64 69 6e 67 2c 20 24 76 61 72 29 | conv($encoding,.$encoding,.$var) |
32680 | 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 | ;.....}......public.static.funct |
326a0 | 69 6f 6e 20 6d 62 5f 64 65 74 65 63 74 5f 65 6e 63 6f 64 69 6e 67 28 24 73 74 72 2c 20 24 65 6e | ion.mb_detect_encoding($str,.$en |
326c0 | 63 6f 64 69 6e 67 4c 69 73 74 20 3d 20 6e 75 6c 6c 2c 20 24 73 74 72 69 63 74 20 3d 20 66 61 6c | codingList.=.null,.$strict.=.fal |
326e0 | 73 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 | se).....{.........if.(null.===.$ |
32700 | 65 6e 63 6f 64 69 6e 67 4c 69 73 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 65 6e 63 | encodingList).{.............$enc |
32720 | 6f 64 69 6e 67 4c 69 73 74 20 3d 20 73 65 6c 66 3a 3a 24 65 6e 63 6f 64 69 6e 67 4c 69 73 74 3b | odingList.=.self::$encodingList; |
32740 | 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 | .........}.else.{.............if |
32760 | 20 28 21 69 73 5f 61 72 72 61 79 28 24 65 6e 63 6f 64 69 6e 67 4c 69 73 74 29 29 20 7b 0a 20 20 | .(!is_array($encodingList)).{... |
32780 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 65 6e 63 6f 64 69 6e 67 4c 69 73 74 20 3d 20 61 72 | ..............$encodingList.=.ar |
327a0 | 72 61 79 5f 6d 61 70 28 27 74 72 69 6d 27 2c 20 65 78 70 6c 6f 64 65 28 27 2c 27 2c 20 24 65 6e | ray_map('trim',.explode(',',.$en |
327c0 | 63 6f 64 69 6e 67 4c 69 73 74 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 | codingList));.............}..... |
327e0 | 20 20 20 20 20 20 20 20 24 65 6e 63 6f 64 69 6e 67 4c 69 73 74 20 3d 20 61 72 72 61 79 5f 6d 61 | ........$encodingList.=.array_ma |
32800 | 70 28 27 73 74 72 74 6f 75 70 70 65 72 27 2c 20 24 65 6e 63 6f 64 69 6e 67 4c 69 73 74 29 3b 0a | p('strtoupper',.$encodingList);. |
32820 | 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 65 6e 63 | ........}..........foreach.($enc |
32840 | 6f 64 69 6e 67 4c 69 73 74 20 61 73 20 24 65 6e 63 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | odingList.as.$enc).{............ |
32860 | 20 73 77 69 74 63 68 20 28 24 65 6e 63 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | .switch.($enc).{................ |
32880 | 20 63 61 73 65 20 27 41 53 43 49 49 27 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | .case.'ASCII':.................. |
328a0 | 20 20 20 69 66 20 28 21 70 72 65 67 5f 6d 61 74 63 68 28 27 2f 5b 5c 78 38 30 2d 5c 78 46 46 5d | ...if.(!preg_match('/[\x80-\xFF] |
328c0 | 2f 27 2c 20 24 73 74 72 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | /',.$str)).{.................... |
328e0 | 20 20 20 20 20 72 65 74 75 72 6e 20 24 65 6e 63 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | .....return.$enc;............... |
32900 | 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 62 72 65 61 | ......}.....................brea |
32920 | 6b 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 63 61 73 65 20 27 55 54 46 38 27 3a | k;..................case.'UTF8': |
32940 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 63 61 73 65 20 27 55 54 46 2d 38 27 3a 0a 20 | .................case.'UTF-8':.. |
32960 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 70 72 65 67 5f 6d 61 74 63 | ...................if.(preg_matc |
32980 | 68 28 27 2f 2f 75 27 2c 20 24 73 74 72 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | h('//u',.$str)).{............... |
329a0 | 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 27 55 54 46 2d 38 27 3b 0a 20 20 20 20 20 20 | ..........return.'UTF-8';....... |
329c0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ..............}................. |
329e0 | 20 20 20 20 62 72 65 61 6b 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 64 65 66 61 | ....break;..................defa |
32a00 | 75 6c 74 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 30 20 3d | ult:.....................if.(0.= |
32a20 | 3d 3d 20 73 74 72 6e 63 6d 70 28 24 65 6e 63 2c 20 27 49 53 4f 2d 38 38 35 39 2d 27 2c 20 39 29 | ==.strncmp($enc,.'ISO-8859-',.9) |
32a40 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 | ).{.........................retu |
32a60 | 72 6e 20 24 65 6e 63 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 | rn.$enc;.....................}.. |
32a80 | 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 | ...........}.........}.......... |
32aa0 | 72 65 74 75 72 6e 20 66 61 6c 73 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 | return.false;.....}......public. |
32ac0 | 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 64 65 74 65 63 74 5f 6f 72 64 65 72 28 | static.function.mb_detect_order( |
32ae0 | 24 65 6e 63 6f 64 69 6e 67 4c 69 73 74 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 | $encodingList.=.null).....{..... |
32b00 | 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 65 6e 63 6f 64 69 6e 67 4c 69 73 74 29 20 | ....if.(null.===.$encodingList). |
32b20 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 3a 3a 24 65 6e 63 6f | {.............return.self::$enco |
32b40 | 64 69 6e 67 4c 69 73 74 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 | dingList;.........}..........if. |
32b60 | 28 21 69 73 5f 61 72 72 61 79 28 24 65 6e 63 6f 64 69 6e 67 4c 69 73 74 29 29 20 7b 0a 20 20 20 | (!is_array($encodingList)).{.... |
32b80 | 20 20 20 20 20 20 20 20 20 24 65 6e 63 6f 64 69 6e 67 4c 69 73 74 20 3d 20 61 72 72 61 79 5f 6d | .........$encodingList.=.array_m |
32ba0 | 61 70 28 27 74 72 69 6d 27 2c 20 65 78 70 6c 6f 64 65 28 27 2c 27 2c 20 24 65 6e 63 6f 64 69 6e | ap('trim',.explode(',',.$encodin |
32bc0 | 67 4c 69 73 74 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 24 65 6e 63 6f | gList));.........}.........$enco |
32be0 | 64 69 6e 67 4c 69 73 74 20 3d 20 61 72 72 61 79 5f 6d 61 70 28 27 73 74 72 74 6f 75 70 70 65 72 | dingList.=.array_map('strtoupper |
32c00 | 27 2c 20 24 65 6e 63 6f 64 69 6e 67 4c 69 73 74 29 3b 0a 0a 20 20 20 20 20 20 20 20 66 6f 72 65 | ',.$encodingList);..........fore |
32c20 | 61 63 68 20 28 24 65 6e 63 6f 64 69 6e 67 4c 69 73 74 20 61 73 20 24 65 6e 63 29 20 7b 0a 20 20 | ach.($encodingList.as.$enc).{... |
32c40 | 20 20 20 20 20 20 20 20 20 20 73 77 69 74 63 68 20 28 24 65 6e 63 29 20 7b 0a 20 20 20 20 20 20 | ..........switch.($enc).{....... |
32c60 | 20 20 20 20 20 20 20 20 20 20 64 65 66 61 75 6c 74 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | ..........default:.............. |
32c80 | 20 20 20 20 20 20 20 69 66 20 28 73 74 72 6e 63 6d 70 28 24 65 6e 63 2c 20 27 49 53 4f 2d 38 38 | .......if.(strncmp($enc,.'ISO-88 |
32ca0 | 35 39 2d 27 2c 20 39 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | 59-',.9)).{..................... |
32cc0 | 20 20 20 20 72 65 74 75 72 6e 20 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ....return.false;............... |
32ce0 | 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 63 61 73 65 20 27 41 53 | ......}.................case.'AS |
32d00 | 43 49 49 27 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 63 61 73 65 20 27 55 54 46 38 | CII':.................case.'UTF8 |
32d20 | 27 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 63 61 73 65 20 27 55 54 46 2d 38 27 3a | ':.................case.'UTF-8': |
32d40 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 | .............}.........}........ |
32d60 | 20 20 73 65 6c 66 3a 3a 24 65 6e 63 6f 64 69 6e 67 4c 69 73 74 20 3d 20 24 65 6e 63 6f 64 69 6e | ..self::$encodingList.=.$encodin |
32d80 | 67 4c 69 73 74 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 74 72 75 65 3b 0a 20 20 20 | gList;..........return.true;.... |
32da0 | 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 6d | .}......public.static.function.m |
32dc0 | 62 5f 73 74 72 6c 65 6e 28 24 73 2c 20 24 65 6e 63 6f 64 69 6e 67 20 3d 20 6e 75 6c 6c 29 0a 20 | b_strlen($s,.$encoding.=.null).. |
32de0 | 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 65 6e 63 6f 64 69 6e 67 20 3d 20 73 65 6c 66 3a 3a 67 | ...{.........$encoding.=.self::g |
32e00 | 65 74 45 6e 63 6f 64 69 6e 67 28 24 65 6e 63 6f 64 69 6e 67 29 3b 0a 0a 20 20 20 20 20 20 20 20 | etEncoding($encoding);.......... |
32e20 | 72 65 74 75 72 6e 20 69 63 6f 6e 76 5f 73 74 72 6c 65 6e 28 24 73 2c 20 24 65 6e 63 6f 64 69 6e | return.iconv_strlen($s,.$encodin |
32e40 | 67 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e | g);.....}......public.static.fun |
32e60 | 63 74 69 6f 6e 20 6d 62 5f 73 74 72 70 6f 73 28 24 68 61 79 73 74 61 63 6b 2c 20 24 6e 65 65 64 | ction.mb_strpos($haystack,.$need |
32e80 | 6c 65 2c 20 24 6f 66 66 73 65 74 20 3d 20 30 2c 20 24 65 6e 63 6f 64 69 6e 67 20 3d 20 6e 75 6c | le,.$offset.=.0,.$encoding.=.nul |
32ea0 | 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 65 6e 63 6f 64 69 6e 67 20 3d 20 73 65 6c | l).....{.........$encoding.=.sel |
32ec0 | 66 3a 3a 67 65 74 45 6e 63 6f 64 69 6e 67 28 24 65 6e 63 6f 64 69 6e 67 29 3b 0a 0a 20 20 20 20 | f::getEncoding($encoding);...... |
32ee0 | 20 20 20 20 69 66 20 28 27 27 20 3d 3d 3d 20 24 6e 65 65 64 6c 65 20 2e 3d 20 27 27 29 20 7b 0a | ....if.(''.===.$needle..=.'').{. |
32f00 | 20 20 20 20 20 20 20 20 20 20 20 20 74 72 69 67 67 65 72 5f 65 72 72 6f 72 28 5f 5f 4d 45 54 48 | ............trigger_error(__METH |
32f20 | 4f 44 5f 5f 2e 27 3a 20 45 6d 70 74 79 20 64 65 6c 69 6d 69 74 65 72 27 2c 20 45 5f 55 53 45 52 | OD__.':.Empty.delimiter',.E_USER |
32f40 | 5f 57 41 52 4e 49 4e 47 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 66 | _WARNING);..............return.f |
32f60 | 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 | alse;.........}..........return. |
32f80 | 69 63 6f 6e 76 5f 73 74 72 70 6f 73 28 24 68 61 79 73 74 61 63 6b 2c 20 24 6e 65 65 64 6c 65 2c | iconv_strpos($haystack,.$needle, |
32fa0 | 20 24 6f 66 66 73 65 74 2c 20 24 65 6e 63 6f 64 69 6e 67 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 | .$offset,.$encoding);.....}..... |
32fc0 | 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 73 74 72 72 70 | .public.static.function.mb_strrp |
32fe0 | 6f 73 28 24 68 61 79 73 74 61 63 6b 2c 20 24 6e 65 65 64 6c 65 2c 20 24 6f 66 66 73 65 74 20 3d | os($haystack,.$needle,.$offset.= |
33000 | 20 30 2c 20 24 65 6e 63 6f 64 69 6e 67 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 | .0,.$encoding.=.null).....{..... |
33020 | 20 20 20 20 24 65 6e 63 6f 64 69 6e 67 20 3d 20 73 65 6c 66 3a 3a 67 65 74 45 6e 63 6f 64 69 6e | ....$encoding.=.self::getEncodin |
33040 | 67 28 24 65 6e 63 6f 64 69 6e 67 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 6f 66 66 73 | g($encoding);..........if.($offs |
33060 | 65 74 20 21 3d 20 28 69 6e 74 29 20 24 6f 66 66 73 65 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | et.!=.(int).$offset).{.......... |
33080 | 20 20 20 24 6f 66 66 73 65 74 20 3d 20 30 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 | ...$offset.=.0;.........}.elseif |
330a0 | 20 28 24 6f 66 66 73 65 74 20 3d 20 28 69 6e 74 29 20 24 6f 66 66 73 65 74 29 20 7b 0a 20 20 20 | .($offset.=.(int).$offset).{.... |
330c0 | 20 20 20 20 20 20 20 20 20 69 66 20 28 24 6f 66 66 73 65 74 20 3c 20 30 29 20 7b 0a 20 20 20 20 | .........if.($offset.<.0).{..... |
330e0 | 20 20 20 20 20 20 20 20 20 20 20 20 24 68 61 79 73 74 61 63 6b 20 3d 20 73 65 6c 66 3a 3a 6d 62 | ............$haystack.=.self::mb |
33100 | 5f 73 75 62 73 74 72 28 24 68 61 79 73 74 61 63 6b 2c 20 30 2c 20 24 6f 66 66 73 65 74 2c 20 24 | _substr($haystack,.0,.$offset,.$ |
33120 | 65 6e 63 6f 64 69 6e 67 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 66 66 73 | encoding);.................$offs |
33140 | 65 74 20 3d 20 30 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 | et.=.0;.............}.else.{.... |
33160 | 20 20 20 20 20 20 20 20 20 20 20 20 20 24 68 61 79 73 74 61 63 6b 20 3d 20 73 65 6c 66 3a 3a 6d | .............$haystack.=.self::m |
33180 | 62 5f 73 75 62 73 74 72 28 24 68 61 79 73 74 61 63 6b 2c 20 24 6f 66 66 73 65 74 2c 20 32 31 34 | b_substr($haystack,.$offset,.214 |
331a0 | 37 34 38 33 36 34 37 2c 20 24 65 6e 63 6f 64 69 6e 67 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 | 7483647,.$encoding);............ |
331c0 | 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 70 6f 73 20 3d 20 69 63 6f | .}.........}..........$pos.=.ico |
331e0 | 6e 76 5f 73 74 72 72 70 6f 73 28 24 68 61 79 73 74 61 63 6b 2c 20 24 6e 65 65 64 6c 65 2c 20 24 | nv_strrpos($haystack,.$needle,.$ |
33200 | 65 6e 63 6f 64 69 6e 67 29 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 66 61 6c 73 65 | encoding);..........return.false |
33220 | 20 21 3d 3d 20 24 70 6f 73 20 3f 20 24 6f 66 66 73 65 74 20 2b 20 24 70 6f 73 20 3a 20 66 61 6c | .!==.$pos.?.$offset.+.$pos.:.fal |
33240 | 73 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e | se;.....}......public.static.fun |
33260 | 63 74 69 6f 6e 20 6d 62 5f 73 74 72 74 6f 6c 6f 77 65 72 28 24 73 2c 20 24 65 6e 63 6f 64 69 6e | ction.mb_strtolower($s,.$encodin |
33280 | 67 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 | g.=.null).....{.........return.s |
332a0 | 65 6c 66 3a 3a 6d 62 5f 63 6f 6e 76 65 72 74 5f 63 61 73 65 28 24 73 2c 20 4d 42 5f 43 41 53 45 | elf::mb_convert_case($s,.MB_CASE |
332c0 | 5f 4c 4f 57 45 52 2c 20 24 65 6e 63 6f 64 69 6e 67 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 | _LOWER,.$encoding);.....}......p |
332e0 | 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 73 74 72 74 6f 75 70 | ublic.static.function.mb_strtoup |
33300 | 70 65 72 28 24 73 2c 20 24 65 6e 63 6f 64 69 6e 67 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a | per($s,.$encoding.=.null).....{. |
33320 | 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 3a 3a 6d 62 5f 63 6f 6e 76 65 72 74 5f | ........return.self::mb_convert_ |
33340 | 63 61 73 65 28 24 73 2c 20 4d 42 5f 43 41 53 45 5f 55 50 50 45 52 2c 20 24 65 6e 63 6f 64 69 6e | case($s,.MB_CASE_UPPER,.$encodin |
33360 | 67 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e | g);.....}......public.static.fun |
33380 | 63 74 69 6f 6e 20 6d 62 5f 73 75 62 73 74 69 74 75 74 65 5f 63 68 61 72 61 63 74 65 72 28 24 63 | ction.mb_substitute_character($c |
333a0 | 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 30 20 3d 3d 3d | .=.null).....{.........if.(0.=== |
333c0 | 20 73 74 72 63 61 73 65 63 6d 70 28 24 63 2c 20 27 6e 6f 6e 65 27 29 29 20 7b 0a 20 20 20 20 20 | .strcasecmp($c,.'none')).{...... |
333e0 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 74 72 75 65 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 | .......return.true;.........}... |
33400 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6e 75 6c 6c 20 21 3d 3d 20 24 63 20 3f 20 66 61 6c 73 | .......return.null.!==.$c.?.fals |
33420 | 65 20 3a 20 27 6e 6f 6e 65 27 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 | e.:.'none';.....}......public.st |
33440 | 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 73 75 62 73 74 72 28 24 73 2c 20 24 73 74 61 | atic.function.mb_substr($s,.$sta |
33460 | 72 74 2c 20 24 6c 65 6e 67 74 68 20 3d 20 6e 75 6c 6c 2c 20 24 65 6e 63 6f 64 69 6e 67 20 3d 20 | rt,.$length.=.null,.$encoding.=. |
33480 | 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 65 6e 63 6f 64 69 6e 67 20 3d 20 | null).....{.........$encoding.=. |
334a0 | 73 65 6c 66 3a 3a 67 65 74 45 6e 63 6f 64 69 6e 67 28 24 65 6e 63 6f 64 69 6e 67 29 3b 0a 0a 20 | self::getEncoding($encoding);... |
334c0 | 20 20 20 20 20 20 20 69 66 20 28 24 73 74 61 72 74 20 3c 20 30 29 20 7b 0a 20 20 20 20 20 20 20 | .......if.($start.<.0).{........ |
334e0 | 20 20 20 20 20 24 73 74 61 72 74 20 3d 20 69 63 6f 6e 76 5f 73 74 72 6c 65 6e 28 24 73 2c 20 24 | .....$start.=.iconv_strlen($s,.$ |
33500 | 65 6e 63 6f 64 69 6e 67 29 20 2b 20 24 73 74 61 72 74 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | encoding).+.$start;............. |
33520 | 69 66 20 28 24 73 74 61 72 74 20 3c 20 30 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | if.($start.<.0).{............... |
33540 | 20 20 24 73 74 61 72 74 20 3d 20 30 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 | ..$start.=.0;.............}..... |
33560 | 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 6c 65 6e | ....}..........if.(null.===.$len |
33580 | 67 74 68 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 65 6e 67 74 68 20 3d 20 32 31 34 | gth).{.............$length.=.214 |
335a0 | 37 34 38 33 36 34 37 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 24 6c 65 6e 67 | 7483647;.........}.elseif.($leng |
335c0 | 74 68 20 3c 20 30 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 65 6e 67 74 68 20 3d 20 | th.<.0).{.............$length.=. |
335e0 | 69 63 6f 6e 76 5f 73 74 72 6c 65 6e 28 24 73 2c 20 24 65 6e 63 6f 64 69 6e 67 29 20 2b 20 24 6c | iconv_strlen($s,.$encoding).+.$l |
33600 | 65 6e 67 74 68 20 2d 20 24 73 74 61 72 74 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 | ength.-.$start;.............if.( |
33620 | 24 6c 65 6e 67 74 68 20 3c 20 30 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 | $length.<.0).{.................r |
33640 | 65 74 75 72 6e 20 27 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 | eturn.'';.............}......... |
33660 | 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 69 63 6f 6e 76 5f 73 75 62 73 74 72 28 24 | }..........return.iconv_substr($ |
33680 | 73 2c 20 24 73 74 61 72 74 2c 20 24 6c 65 6e 67 74 68 2c 20 24 65 6e 63 6f 64 69 6e 67 29 2e 27 | s,.$start,.$length,.$encoding).' |
336a0 | 27 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 | ';.....}......public.static.func |
336c0 | 74 69 6f 6e 20 6d 62 5f 73 74 72 69 70 6f 73 28 24 68 61 79 73 74 61 63 6b 2c 20 24 6e 65 65 64 | tion.mb_stripos($haystack,.$need |
336e0 | 6c 65 2c 20 24 6f 66 66 73 65 74 20 3d 20 30 2c 20 24 65 6e 63 6f 64 69 6e 67 20 3d 20 6e 75 6c | le,.$offset.=.0,.$encoding.=.nul |
33700 | 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 68 61 79 73 74 61 63 6b 20 3d 20 73 65 6c | l).....{.........$haystack.=.sel |
33720 | 66 3a 3a 6d 62 5f 63 6f 6e 76 65 72 74 5f 63 61 73 65 28 24 68 61 79 73 74 61 63 6b 2c 20 73 65 | f::mb_convert_case($haystack,.se |
33740 | 6c 66 3a 3a 4d 42 5f 43 41 53 45 5f 46 4f 4c 44 2c 20 24 65 6e 63 6f 64 69 6e 67 29 3b 0a 20 20 | lf::MB_CASE_FOLD,.$encoding);... |
33760 | 20 20 20 20 20 20 24 6e 65 65 64 6c 65 20 3d 20 73 65 6c 66 3a 3a 6d 62 5f 63 6f 6e 76 65 72 74 | ......$needle.=.self::mb_convert |
33780 | 5f 63 61 73 65 28 24 6e 65 65 64 6c 65 2c 20 73 65 6c 66 3a 3a 4d 42 5f 43 41 53 45 5f 46 4f 4c | _case($needle,.self::MB_CASE_FOL |
337a0 | 44 2c 20 24 65 6e 63 6f 64 69 6e 67 29 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 | D,.$encoding);..........return.s |
337c0 | 65 6c 66 3a 3a 6d 62 5f 73 74 72 70 6f 73 28 24 68 61 79 73 74 61 63 6b 2c 20 24 6e 65 65 64 6c | elf::mb_strpos($haystack,.$needl |
337e0 | 65 2c 20 24 6f 66 66 73 65 74 2c 20 24 65 6e 63 6f 64 69 6e 67 29 3b 0a 20 20 20 20 7d 0a 0a 20 | e,.$offset,.$encoding);.....}... |
33800 | 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 73 74 72 | ...public.static.function.mb_str |
33820 | 69 73 74 72 28 24 68 61 79 73 74 61 63 6b 2c 20 24 6e 65 65 64 6c 65 2c 20 24 70 61 72 74 20 3d | istr($haystack,.$needle,.$part.= |
33840 | 20 66 61 6c 73 65 2c 20 24 65 6e 63 6f 64 69 6e 67 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a | .false,.$encoding.=.null).....{. |
33860 | 20 20 20 20 20 20 20 20 24 70 6f 73 20 3d 20 73 65 6c 66 3a 3a 6d 62 5f 73 74 72 69 70 6f 73 28 | ........$pos.=.self::mb_stripos( |
33880 | 24 68 61 79 73 74 61 63 6b 2c 20 24 6e 65 65 64 6c 65 2c 20 30 2c 20 24 65 6e 63 6f 64 69 6e 67 | $haystack,.$needle,.0,.$encoding |
338a0 | 29 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 3a 3a 67 65 74 53 75 62 70 | );..........return.self::getSubp |
338c0 | 61 72 74 28 24 70 6f 73 2c 20 24 70 61 72 74 2c 20 24 68 61 79 73 74 61 63 6b 2c 20 24 65 6e 63 | art($pos,.$part,.$haystack,.$enc |
338e0 | 6f 64 69 6e 67 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 | oding);.....}......public.static |
33900 | 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 73 74 72 72 63 68 72 28 24 68 61 79 73 74 61 63 6b 2c 20 | .function.mb_strrchr($haystack,. |
33920 | 24 6e 65 65 64 6c 65 2c 20 24 70 61 72 74 20 3d 20 66 61 6c 73 65 2c 20 24 65 6e 63 6f 64 69 6e | $needle,.$part.=.false,.$encodin |
33940 | 67 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 65 6e 63 6f 64 69 6e | g.=.null).....{.........$encodin |
33960 | 67 20 3d 20 73 65 6c 66 3a 3a 67 65 74 45 6e 63 6f 64 69 6e 67 28 24 65 6e 63 6f 64 69 6e 67 29 | g.=.self::getEncoding($encoding) |
33980 | 3b 0a 20 20 20 20 20 20 20 20 24 6e 65 65 64 6c 65 20 3d 20 73 65 6c 66 3a 3a 6d 62 5f 73 75 62 | ;.........$needle.=.self::mb_sub |
339a0 | 73 74 72 28 24 6e 65 65 64 6c 65 2c 20 30 2c 20 31 2c 20 24 65 6e 63 6f 64 69 6e 67 29 3b 0a 20 | str($needle,.0,.1,.$encoding);.. |
339c0 | 20 20 20 20 20 20 20 24 70 6f 73 20 3d 20 69 63 6f 6e 76 5f 73 74 72 72 70 6f 73 28 24 68 61 79 | .......$pos.=.iconv_strrpos($hay |
339e0 | 73 74 61 63 6b 2c 20 24 6e 65 65 64 6c 65 2c 20 24 65 6e 63 6f 64 69 6e 67 29 3b 0a 0a 20 20 20 | stack,.$needle,.$encoding);..... |
33a00 | 20 20 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 3a 3a 67 65 74 53 75 62 70 61 72 74 28 24 70 6f | .....return.self::getSubpart($po |
33a20 | 73 2c 20 24 70 61 72 74 2c 20 24 68 61 79 73 74 61 63 6b 2c 20 24 65 6e 63 6f 64 69 6e 67 29 3b | s,.$part,.$haystack,.$encoding); |
33a40 | 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 | .....}......public.static.functi |
33a60 | 6f 6e 20 6d 62 5f 73 74 72 72 69 63 68 72 28 24 68 61 79 73 74 61 63 6b 2c 20 24 6e 65 65 64 6c | on.mb_strrichr($haystack,.$needl |
33a80 | 65 2c 20 24 70 61 72 74 20 3d 20 66 61 6c 73 65 2c 20 24 65 6e 63 6f 64 69 6e 67 20 3d 20 6e 75 | e,.$part.=.false,.$encoding.=.nu |
33aa0 | 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 6e 65 65 64 6c 65 20 3d 20 73 65 6c 66 | ll).....{.........$needle.=.self |
33ac0 | 3a 3a 6d 62 5f 73 75 62 73 74 72 28 24 6e 65 65 64 6c 65 2c 20 30 2c 20 31 2c 20 24 65 6e 63 6f | ::mb_substr($needle,.0,.1,.$enco |
33ae0 | 64 69 6e 67 29 3b 0a 20 20 20 20 20 20 20 20 24 70 6f 73 20 3d 20 73 65 6c 66 3a 3a 6d 62 5f 73 | ding);.........$pos.=.self::mb_s |
33b00 | 74 72 72 69 70 6f 73 28 24 68 61 79 73 74 61 63 6b 2c 20 24 6e 65 65 64 6c 65 2c 20 24 65 6e 63 | trripos($haystack,.$needle,.$enc |
33b20 | 6f 64 69 6e 67 29 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 3a 3a 67 65 | oding);..........return.self::ge |
33b40 | 74 53 75 62 70 61 72 74 28 24 70 6f 73 2c 20 24 70 61 72 74 2c 20 24 68 61 79 73 74 61 63 6b 2c | tSubpart($pos,.$part,.$haystack, |
33b60 | 20 24 65 6e 63 6f 64 69 6e 67 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 73 | .$encoding);.....}......public.s |
33b80 | 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 73 74 72 72 69 70 6f 73 28 24 68 61 79 73 | tatic.function.mb_strripos($hays |
33ba0 | 74 61 63 6b 2c 20 24 6e 65 65 64 6c 65 2c 20 24 6f 66 66 73 65 74 20 3d 20 30 2c 20 24 65 6e 63 | tack,.$needle,.$offset.=.0,.$enc |
33bc0 | 6f 64 69 6e 67 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 68 61 79 | oding.=.null).....{.........$hay |
33be0 | 73 74 61 63 6b 20 3d 20 73 65 6c 66 3a 3a 6d 62 5f 63 6f 6e 76 65 72 74 5f 63 61 73 65 28 24 68 | stack.=.self::mb_convert_case($h |
33c00 | 61 79 73 74 61 63 6b 2c 20 73 65 6c 66 3a 3a 4d 42 5f 43 41 53 45 5f 46 4f 4c 44 2c 20 24 65 6e | aystack,.self::MB_CASE_FOLD,.$en |
33c20 | 63 6f 64 69 6e 67 29 3b 0a 20 20 20 20 20 20 20 20 24 6e 65 65 64 6c 65 20 3d 20 73 65 6c 66 3a | coding);.........$needle.=.self: |
33c40 | 3a 6d 62 5f 63 6f 6e 76 65 72 74 5f 63 61 73 65 28 24 6e 65 65 64 6c 65 2c 20 73 65 6c 66 3a 3a | :mb_convert_case($needle,.self:: |
33c60 | 4d 42 5f 43 41 53 45 5f 46 4f 4c 44 2c 20 24 65 6e 63 6f 64 69 6e 67 29 3b 0a 0a 20 20 20 20 20 | MB_CASE_FOLD,.$encoding);....... |
33c80 | 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 3a 3a 6d 62 5f 73 74 72 72 70 6f 73 28 24 68 61 79 73 | ...return.self::mb_strrpos($hays |
33ca0 | 74 61 63 6b 2c 20 24 6e 65 65 64 6c 65 2c 20 24 6f 66 66 73 65 74 2c 20 24 65 6e 63 6f 64 69 6e | tack,.$needle,.$offset,.$encodin |
33cc0 | 67 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e | g);.....}......public.static.fun |
33ce0 | 63 74 69 6f 6e 20 6d 62 5f 73 74 72 73 74 72 28 24 68 61 79 73 74 61 63 6b 2c 20 24 6e 65 65 64 | ction.mb_strstr($haystack,.$need |
33d00 | 6c 65 2c 20 24 70 61 72 74 20 3d 20 66 61 6c 73 65 2c 20 24 65 6e 63 6f 64 69 6e 67 20 3d 20 6e | le,.$part.=.false,.$encoding.=.n |
33d20 | 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 70 6f 73 20 3d 20 73 74 72 70 6f 73 | ull).....{.........$pos.=.strpos |
33d40 | 28 24 68 61 79 73 74 61 63 6b 2c 20 24 6e 65 65 64 6c 65 29 3b 0a 20 20 20 20 20 20 20 20 69 66 | ($haystack,.$needle);.........if |
33d60 | 20 28 66 61 6c 73 65 20 3d 3d 3d 20 24 70 6f 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | .(false.===.$pos).{............. |
33d80 | 72 65 74 75 72 6e 20 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 | return.false;.........}......... |
33da0 | 69 66 20 28 24 70 61 72 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 | if.($part).{.............return. |
33dc0 | 73 75 62 73 74 72 28 24 68 61 79 73 74 61 63 6b 2c 20 30 2c 20 24 70 6f 73 29 3b 0a 20 20 20 20 | substr($haystack,.0,.$pos);..... |
33de0 | 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 75 62 73 74 72 28 24 68 61 | ....}..........return.substr($ha |
33e00 | 79 73 74 61 63 6b 2c 20 24 70 6f 73 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 | ystack,.$pos);.....}......public |
33e20 | 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 67 65 74 5f 69 6e 66 6f 28 24 74 79 | .static.function.mb_get_info($ty |
33e40 | 70 65 20 3d 20 27 61 6c 6c 27 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 69 6e 66 6f 20 | pe.=.'all').....{.........$info. |
33e60 | 3d 20 61 72 72 61 79 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 69 6e 74 65 72 6e 61 6c 5f 65 | =.array(.............'internal_e |
33e80 | 6e 63 6f 64 69 6e 67 27 20 3d 3e 20 73 65 6c 66 3a 3a 24 69 6e 74 65 72 6e 61 6c 45 6e 63 6f 64 | ncoding'.=>.self::$internalEncod |
33ea0 | 69 6e 67 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 68 74 74 70 5f 6f 75 74 70 75 74 27 20 3d | ing,.............'http_output'.= |
33ec0 | 3e 20 27 70 61 73 73 27 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 68 74 74 70 5f 6f 75 74 70 | >.'pass',.............'http_outp |
33ee0 | 75 74 5f 63 6f 6e 76 5f 6d 69 6d 65 74 79 70 65 73 27 20 3d 3e 20 27 5e 28 74 65 78 74 2f 7c 61 | ut_conv_mimetypes'.=>.'^(text/|a |
33f00 | 70 70 6c 69 63 61 74 69 6f 6e 2f 78 68 74 6d 6c 5c 2b 78 6d 6c 29 27 2c 0a 20 20 20 20 20 20 20 | pplication/xhtml\+xml)',........ |
33f20 | 20 20 20 20 20 27 66 75 6e 63 5f 6f 76 65 72 6c 6f 61 64 27 20 3d 3e 20 30 2c 0a 20 20 20 20 20 | .....'func_overload'.=>.0,...... |
33f40 | 20 20 20 20 20 20 20 27 66 75 6e 63 5f 6f 76 65 72 6c 6f 61 64 5f 6c 69 73 74 27 20 3d 3e 20 27 | .......'func_overload_list'.=>.' |
33f60 | 6e 6f 20 6f 76 65 72 6c 6f 61 64 27 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 6d 61 69 6c 5f | no.overload',.............'mail_ |
33f80 | 63 68 61 72 73 65 74 27 20 3d 3e 20 27 55 54 46 2d 38 27 2c 0a 20 20 20 20 20 20 20 20 20 20 20 | charset'.=>.'UTF-8',............ |
33fa0 | 20 27 6d 61 69 6c 5f 68 65 61 64 65 72 5f 65 6e 63 6f 64 69 6e 67 27 20 3d 3e 20 27 42 41 53 45 | .'mail_header_encoding'.=>.'BASE |
33fc0 | 36 34 27 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 6d 61 69 6c 5f 62 6f 64 79 5f 65 6e 63 6f | 64',.............'mail_body_enco |
33fe0 | 64 69 6e 67 27 20 3d 3e 20 27 42 41 53 45 36 34 27 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 | ding'.=>.'BASE64',.............' |
34000 | 69 6c 6c 65 67 61 6c 5f 63 68 61 72 73 27 20 3d 3e 20 30 2c 0a 20 20 20 20 20 20 20 20 20 20 20 | illegal_chars'.=>.0,............ |
34020 | 20 27 65 6e 63 6f 64 69 6e 67 5f 74 72 61 6e 73 6c 61 74 69 6f 6e 27 20 3d 3e 20 27 4f 66 66 27 | .'encoding_translation'.=>.'Off' |
34040 | 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 6c 61 6e 67 75 61 67 65 27 20 3d 3e 20 73 65 6c 66 | ,.............'language'.=>.self |
34060 | 3a 3a 24 6c 61 6e 67 75 61 67 65 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 64 65 74 65 63 74 | ::$language,.............'detect |
34080 | 5f 6f 72 64 65 72 27 20 3d 3e 20 73 65 6c 66 3a 3a 24 65 6e 63 6f 64 69 6e 67 4c 69 73 74 2c 0a | _order'.=>.self::$encodingList,. |
340a0 | 20 20 20 20 20 20 20 20 20 20 20 20 27 73 75 62 73 74 69 74 75 74 65 5f 63 68 61 72 61 63 74 65 | ............'substitute_characte |
340c0 | 72 27 20 3d 3e 20 27 6e 6f 6e 65 27 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 73 74 72 69 63 | r'.=>.'none',.............'stric |
340e0 | 74 5f 64 65 74 65 63 74 69 6f 6e 27 20 3d 3e 20 27 4f 66 66 27 2c 0a 20 20 20 20 20 20 20 20 29 | t_detection'.=>.'Off',.........) |
34100 | 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 27 61 6c 6c 27 20 3d 3d 3d 20 24 74 79 70 65 29 20 | ;..........if.('all'.===.$type). |
34120 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 69 6e 66 6f 3b 0a 20 20 20 20 | {.............return.$info;..... |
34140 | 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 69 73 73 65 74 28 24 69 6e 66 6f 5b 24 74 | ....}.........if.(isset($info[$t |
34160 | 79 70 65 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 69 6e 66 | ype])).{.............return.$inf |
34180 | 6f 5b 24 74 79 70 65 5d 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 | o[$type];.........}..........ret |
341a0 | 75 72 6e 20 66 61 6c 73 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 | urn.false;.....}......public.sta |
341c0 | 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 68 74 74 70 5f 69 6e 70 75 74 28 24 74 79 70 65 | tic.function.mb_http_input($type |
341e0 | 20 3d 20 27 27 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 66 61 6c 73 | .=.'').....{.........return.fals |
34200 | 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 | e;.....}......public.static.func |
34220 | 74 69 6f 6e 20 6d 62 5f 68 74 74 70 5f 6f 75 74 70 75 74 28 24 65 6e 63 6f 64 69 6e 67 20 3d 20 | tion.mb_http_output($encoding.=. |
34240 | 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6e 75 6c 6c 20 | null).....{.........return.null. |
34260 | 21 3d 3d 20 24 65 6e 63 6f 64 69 6e 67 20 3f 20 27 70 61 73 73 27 20 3d 3d 3d 20 24 65 6e 63 6f | !==.$encoding.?.'pass'.===.$enco |
34280 | 64 69 6e 67 20 3a 20 27 70 61 73 73 27 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 | ding.:.'pass';.....}......public |
342a0 | 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 73 74 72 77 69 64 74 68 28 24 73 2c | .static.function.mb_strwidth($s, |
342c0 | 20 24 65 6e 63 6f 64 69 6e 67 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 | .$encoding.=.null).....{........ |
342e0 | 20 24 65 6e 63 6f 64 69 6e 67 20 3d 20 73 65 6c 66 3a 3a 67 65 74 45 6e 63 6f 64 69 6e 67 28 24 | .$encoding.=.self::getEncoding($ |
34300 | 65 6e 63 6f 64 69 6e 67 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 27 55 54 46 2d 38 27 20 | encoding);..........if.('UTF-8'. |
34320 | 21 3d 3d 20 24 65 6e 63 6f 64 69 6e 67 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 73 20 | !==.$encoding).{.............$s. |
34340 | 3d 20 69 63 6f 6e 76 28 24 65 6e 63 6f 64 69 6e 67 2c 20 27 55 54 46 2d 38 27 2c 20 24 73 29 3b | =.iconv($encoding,.'UTF-8',.$s); |
34360 | 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 73 20 3d 20 70 72 65 67 5f 72 65 | .........}..........$s.=.preg_re |
34380 | 70 6c 61 63 65 28 27 2f 5b 5c 78 7b 31 31 30 30 7d 2d 5c 78 7b 31 31 35 46 7d 5c 78 7b 32 33 32 | place('/[\x{1100}-\x{115F}\x{232 |
343a0 | 39 7d 5c 78 7b 32 33 32 41 7d 5c 78 7b 32 45 38 30 7d 2d 5c 78 7b 33 30 33 45 7d 5c 78 7b 33 30 | 9}\x{232A}\x{2E80}-\x{303E}\x{30 |
343c0 | 34 30 7d 2d 5c 78 7b 41 34 43 46 7d 5c 78 7b 41 43 30 30 7d 2d 5c 78 7b 44 37 41 33 7d 5c 78 7b | 40}-\x{A4CF}\x{AC00}-\x{D7A3}\x{ |
343e0 | 46 39 30 30 7d 2d 5c 78 7b 46 41 46 46 7d 5c 78 7b 46 45 31 30 7d 2d 5c 78 7b 46 45 31 39 7d 5c | F900}-\x{FAFF}\x{FE10}-\x{FE19}\ |
34400 | 78 7b 46 45 33 30 7d 2d 5c 78 7b 46 45 36 46 7d 5c 78 7b 46 46 30 30 7d 2d 5c 78 7b 46 46 36 30 | x{FE30}-\x{FE6F}\x{FF00}-\x{FF60 |
34420 | 7d 5c 78 7b 46 46 45 30 7d 2d 5c 78 7b 46 46 45 36 7d 5c 78 7b 32 30 30 30 30 7d 2d 5c 78 7b 32 | }\x{FFE0}-\x{FFE6}\x{20000}-\x{2 |
34440 | 46 46 46 44 7d 5c 78 7b 33 30 30 30 30 7d 2d 5c 78 7b 33 46 46 46 44 7d 5d 2f 75 27 2c 20 27 27 | FFFD}\x{30000}-\x{3FFFD}]/u',.'' |
34460 | 2c 20 24 73 2c 20 2d 31 2c 20 24 77 69 64 65 29 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 | ,.$s,.-1,.$wide);..........retur |
34480 | 6e 20 28 24 77 69 64 65 20 3c 3c 20 31 29 20 2b 20 69 63 6f 6e 76 5f 73 74 72 6c 65 6e 28 24 73 | n.($wide.<<.1).+.iconv_strlen($s |
344a0 | 2c 20 27 55 54 46 2d 38 27 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 | ,.'UTF-8');.....}......public.st |
344c0 | 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 73 75 62 73 74 72 5f 63 6f 75 6e 74 28 24 68 | atic.function.mb_substr_count($h |
344e0 | 61 79 73 74 61 63 6b 2c 20 24 6e 65 65 64 6c 65 2c 20 24 65 6e 63 6f 64 69 6e 67 20 3d 20 6e 75 | aystack,.$needle,.$encoding.=.nu |
34500 | 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 75 62 73 74 72 5f | ll).....{.........return.substr_ |
34520 | 63 6f 75 6e 74 28 24 68 61 79 73 74 61 63 6b 2c 20 24 6e 65 65 64 6c 65 29 3b 0a 20 20 20 20 7d | count($haystack,.$needle);.....} |
34540 | 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f | ......public.static.function.mb_ |
34560 | 6f 75 74 70 75 74 5f 68 61 6e 64 6c 65 72 28 24 63 6f 6e 74 65 6e 74 73 2c 20 24 73 74 61 74 75 | output_handler($contents,.$statu |
34580 | 73 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 63 6f 6e 74 65 6e 74 | s).....{.........return.$content |
345a0 | 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 66 75 6e | s;.....}......private.static.fun |
345c0 | 63 74 69 6f 6e 20 67 65 74 53 75 62 70 61 72 74 28 24 70 6f 73 2c 20 24 70 61 72 74 2c 20 24 68 | ction.getSubpart($pos,.$part,.$h |
345e0 | 61 79 73 74 61 63 6b 2c 20 24 65 6e 63 6f 64 69 6e 67 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 | aystack,.$encoding).....{....... |
34600 | 20 20 69 66 20 28 66 61 6c 73 65 20 3d 3d 3d 20 24 70 6f 73 29 20 7b 0a 20 20 20 20 20 20 20 20 | ..if.(false.===.$pos).{......... |
34620 | 20 20 20 20 72 65 74 75 72 6e 20 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 | ....return.false;.........}..... |
34640 | 20 20 20 20 69 66 20 28 24 70 61 72 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 | ....if.($part).{.............ret |
34660 | 75 72 6e 20 73 65 6c 66 3a 3a 6d 62 5f 73 75 62 73 74 72 28 24 68 61 79 73 74 61 63 6b 2c 20 30 | urn.self::mb_substr($haystack,.0 |
34680 | 2c 20 24 70 6f 73 2c 20 24 65 6e 63 6f 64 69 6e 67 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 | ,.$pos,.$encoding);.........}... |
346a0 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 3a 3a 6d 62 5f 73 75 62 73 74 72 28 24 68 | .......return.self::mb_substr($h |
346c0 | 61 79 73 74 61 63 6b 2c 20 24 70 6f 73 2c 20 6e 75 6c 6c 2c 20 24 65 6e 63 6f 64 69 6e 67 29 3b | aystack,.$pos,.null,.$encoding); |
346e0 | 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 66 75 6e 63 74 | .....}......private.static.funct |
34700 | 69 6f 6e 20 68 74 6d 6c 5f 65 6e 63 6f 64 69 6e 67 5f 63 61 6c 6c 62 61 63 6b 28 24 6d 29 0a 20 | ion.html_encoding_callback($m).. |
34720 | 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 69 20 3d 20 31 3b 0a 20 20 20 20 20 20 20 20 24 65 6e | ...{.........$i.=.1;.........$en |
34740 | 74 69 74 69 65 73 20 3d 20 27 27 3b 0a 20 20 20 20 20 20 20 20 24 6d 20 3d 20 75 6e 70 61 63 6b | tities.=.'';.........$m.=.unpack |
34760 | 28 27 43 2a 27 2c 20 68 74 6d 6c 65 6e 74 69 74 69 65 73 28 24 6d 5b 30 5d 2c 20 45 4e 54 5f 43 | ('C*',.htmlentities($m[0],.ENT_C |
34780 | 4f 4d 50 41 54 2c 20 27 55 54 46 2d 38 27 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 77 68 69 6c 65 | OMPAT,.'UTF-8'));..........while |
347a0 | 20 28 69 73 73 65 74 28 24 6d 5b 24 69 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 | .(isset($m[$i])).{.............i |
347c0 | 66 20 28 30 78 38 30 20 3e 20 24 6d 5b 24 69 5d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | f.(0x80.>.$m[$i]).{............. |
347e0 | 20 20 20 20 24 65 6e 74 69 74 69 65 73 20 2e 3d 20 63 68 72 28 24 6d 5b 24 69 2b 2b 5d 29 3b 0a | ....$entities..=.chr($m[$i++]);. |
34800 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 63 6f 6e 74 69 6e 75 65 3b 0a 20 20 20 20 20 20 | ................continue;....... |
34820 | 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 30 78 46 30 20 3c 3d 20 | ......}.............if.(0xF0.<=. |
34840 | 24 6d 5b 24 69 5d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 63 20 3d 20 28 | $m[$i]).{.................$c.=.( |
34860 | 28 24 6d 5b 24 69 2b 2b 5d 20 2d 20 30 78 46 30 29 20 3c 3c 20 31 38 29 20 2b 20 28 28 24 6d 5b | ($m[$i++].-.0xF0).<<.18).+.(($m[ |
34880 | 24 69 2b 2b 5d 20 2d 20 30 78 38 30 29 20 3c 3c 20 31 32 29 20 2b 20 28 28 24 6d 5b 24 69 2b 2b | $i++].-.0x80).<<.12).+.(($m[$i++ |
348a0 | 5d 20 2d 20 30 78 38 30 29 20 3c 3c 20 36 29 20 2b 20 24 6d 5b 24 69 2b 2b 5d 20 2d 20 30 78 38 | ].-.0x80).<<.6).+.$m[$i++].-.0x8 |
348c0 | 30 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 30 78 45 30 20 3c 3d | 0;.............}.elseif.(0xE0.<= |
348e0 | 20 24 6d 5b 24 69 5d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 63 20 3d 20 | .$m[$i]).{.................$c.=. |
34900 | 28 28 24 6d 5b 24 69 2b 2b 5d 20 2d 20 30 78 45 30 29 20 3c 3c 20 31 32 29 20 2b 20 28 28 24 6d | (($m[$i++].-.0xE0).<<.12).+.(($m |
34920 | 5b 24 69 2b 2b 5d 20 2d 20 30 78 38 30 29 20 3c 3c 20 36 29 20 2b 20 24 6d 5b 24 69 2b 2b 5d 20 | [$i++].-.0x80).<<.6).+.$m[$i++]. |
34940 | 2d 20 30 78 38 30 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 | -.0x80;.............}.else.{.... |
34960 | 20 20 20 20 20 20 20 20 20 20 20 20 20 24 63 20 3d 20 28 28 24 6d 5b 24 69 2b 2b 5d 20 2d 20 30 | .............$c.=.(($m[$i++].-.0 |
34980 | 78 43 30 29 20 3c 3c 20 36 29 20 2b 20 24 6d 5b 24 69 2b 2b 5d 20 2d 20 30 78 38 30 3b 0a 20 20 | xC0).<<.6).+.$m[$i++].-.0x80;... |
349a0 | 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 65 6e 74 69 74 69 | ..........}..............$entiti |
349c0 | 65 73 20 2e 3d 20 27 26 23 27 2e 24 63 2e 27 3b 27 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 | es..=.'&#'.$c.';';.........}.... |
349e0 | 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 65 6e 74 69 74 69 65 73 3b 0a 20 20 20 20 7d 0a 0a 20 | ......return.$entities;.....}... |
34a00 | 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 74 69 74 6c 65 | ...private.static.function.title |
34a20 | 5f 63 61 73 65 5f 6c 6f 77 65 72 28 24 73 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 | _case_lower($s).....{.........re |
34a40 | 74 75 72 6e 20 73 65 6c 66 3a 3a 6d 62 5f 63 6f 6e 76 65 72 74 5f 63 61 73 65 28 24 73 5b 30 5d | turn.self::mb_convert_case($s[0] |
34a60 | 2c 20 4d 42 5f 43 41 53 45 5f 4c 4f 57 45 52 2c 20 27 55 54 46 2d 38 27 29 3b 0a 20 20 20 20 7d | ,.MB_CASE_LOWER,.'UTF-8');.....} |
34a80 | 0a 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 74 69 | ......private.static.function.ti |
34aa0 | 74 6c 65 5f 63 61 73 65 5f 75 70 70 65 72 28 24 73 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 | tle_case_upper($s).....{........ |
34ac0 | 20 72 65 74 75 72 6e 20 73 65 6c 66 3a 3a 6d 62 5f 63 6f 6e 76 65 72 74 5f 63 61 73 65 28 24 73 | .return.self::mb_convert_case($s |
34ae0 | 5b 30 5d 2c 20 4d 42 5f 43 41 53 45 5f 55 50 50 45 52 2c 20 27 55 54 46 2d 38 27 29 3b 0a 20 20 | [0],.MB_CASE_UPPER,.'UTF-8');... |
34b00 | 20 20 7d 0a 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e | ..}......private.static.function |
34b20 | 20 67 65 74 44 61 74 61 28 24 66 69 6c 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 | .getData($file).....{.........if |
34b40 | 20 28 66 69 6c 65 5f 65 78 69 73 74 73 28 24 66 69 6c 65 20 3d 20 5f 5f 44 49 52 5f 5f 2e 27 2f | .(file_exists($file.=.__DIR__.'/ |
34b60 | 52 65 73 6f 75 72 63 65 73 2f 75 6e 69 64 61 74 61 2f 27 2e 24 66 69 6c 65 2e 27 2e 70 68 70 27 | Resources/unidata/'.$file.'.php' |
34b80 | 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 72 65 71 75 69 72 65 20 | )).{.............return.require. |
34ba0 | 24 66 69 6c 65 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e | $file;.........}..........return |
34bc0 | 20 66 61 6c 73 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 | .false;.....}......private.stati |
34be0 | 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 45 6e 63 6f 64 69 6e 67 28 24 65 6e 63 6f 64 69 6e 67 | c.function.getEncoding($encoding |
34c00 | 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 65 6e | ).....{.........if.(null.===.$en |
34c20 | 63 6f 64 69 6e 67 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 65 6c | coding).{.............return.sel |
34c40 | 66 3a 3a 24 69 6e 74 65 72 6e 61 6c 45 6e 63 6f 64 69 6e 67 3b 0a 20 20 20 20 20 20 20 20 7d 0a | f::$internalEncoding;.........}. |
34c60 | 0a 20 20 20 20 20 20 20 20 24 65 6e 63 6f 64 69 6e 67 20 3d 20 73 74 72 74 6f 75 70 70 65 72 28 | .........$encoding.=.strtoupper( |
34c80 | 24 65 6e 63 6f 64 69 6e 67 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 27 38 42 49 54 27 20 | $encoding);..........if.('8BIT'. |
34ca0 | 3d 3d 3d 20 24 65 6e 63 6f 64 69 6e 67 20 7c 7c 20 27 42 49 4e 41 52 59 27 20 3d 3d 3d 20 24 65 | ===.$encoding.||.'BINARY'.===.$e |
34cc0 | 6e 63 6f 64 69 6e 67 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 27 43 | ncoding).{.............return.'C |
34ce0 | 50 38 35 30 27 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 27 55 54 | P850';.........}.........if.('UT |
34d00 | 46 38 27 20 3d 3d 3d 20 24 65 6e 63 6f 64 69 6e 67 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | F8'.===.$encoding).{............ |
34d20 | 20 72 65 74 75 72 6e 20 27 55 54 46 2d 38 27 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 | .return.'UTF-8';.........}...... |
34d40 | 20 20 20 20 72 65 74 75 72 6e 20 24 65 6e 63 6f 64 69 6e 67 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f | ....return.$encoding;.....}.}.<? |
34d60 | 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 | php../*..*.This.file.is.part.of. |
34d80 | 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 | the.Symfony.package...*..*.(c).F |
34da0 | 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e | abien.Potencier.<fabien@symfony. |
34dc0 | 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 | com>..*..*.For.the.full.copyrigh |
34de0 | 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 | t.and.license.information,.pleas |
34e00 | 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 | e.view.the.LICENSE..*.file.that. |
34e20 | 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 | was.distributed.with.this.source |
34e40 | 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 50 6f 6c 79 66 69 6c 6c | .code...*/..use.Symfony\Polyfill |
34e60 | 5c 4d 62 73 74 72 69 6e 67 20 61 73 20 70 3b 0a 0a 69 66 20 28 21 66 75 6e 63 74 69 6f 6e 5f 65 | \Mbstring.as.p;..if.(!function_e |
34e80 | 78 69 73 74 73 28 27 6d 62 5f 73 74 72 6c 65 6e 27 29 29 20 7b 0a 20 20 20 20 64 65 66 69 6e 65 | xists('mb_strlen')).{.....define |
34ea0 | 28 27 4d 42 5f 43 41 53 45 5f 55 50 50 45 52 27 2c 20 30 29 3b 0a 20 20 20 20 64 65 66 69 6e 65 | ('MB_CASE_UPPER',.0);.....define |
34ec0 | 28 27 4d 42 5f 43 41 53 45 5f 4c 4f 57 45 52 27 2c 20 31 29 3b 0a 20 20 20 20 64 65 66 69 6e 65 | ('MB_CASE_LOWER',.1);.....define |
34ee0 | 28 27 4d 42 5f 43 41 53 45 5f 54 49 54 4c 45 27 2c 20 32 29 3b 0a 0a 20 20 20 20 66 75 6e 63 74 | ('MB_CASE_TITLE',.2);......funct |
34f00 | 69 6f 6e 20 6d 62 5f 63 6f 6e 76 65 72 74 5f 65 6e 63 6f 64 69 6e 67 28 24 73 2c 20 24 74 6f 2c | ion.mb_convert_encoding($s,.$to, |
34f20 | 20 24 66 72 6f 6d 20 3d 20 6e 75 6c 6c 29 20 7b 20 72 65 74 75 72 6e 20 70 5c 4d 62 73 74 72 69 | .$from.=.null).{.return.p\Mbstri |
34f40 | 6e 67 3a 3a 6d 62 5f 63 6f 6e 76 65 72 74 5f 65 6e 63 6f 64 69 6e 67 28 24 73 2c 20 24 74 6f 2c | ng::mb_convert_encoding($s,.$to, |
34f60 | 20 24 66 72 6f 6d 29 3b 20 7d 0a 20 20 20 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 64 65 63 6f 64 | .$from);.}.....function.mb_decod |
34f80 | 65 5f 6d 69 6d 65 68 65 61 64 65 72 28 24 73 29 20 7b 20 72 65 74 75 72 6e 20 70 5c 4d 62 73 74 | e_mimeheader($s).{.return.p\Mbst |
34fa0 | 72 69 6e 67 3a 3a 6d 62 5f 64 65 63 6f 64 65 5f 6d 69 6d 65 68 65 61 64 65 72 28 24 73 29 3b 20 | ring::mb_decode_mimeheader($s);. |
34fc0 | 7d 0a 20 20 20 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 65 6e 63 6f 64 65 5f 6d 69 6d 65 68 65 61 | }.....function.mb_encode_mimehea |
34fe0 | 64 65 72 28 24 73 2c 20 24 63 68 61 72 73 65 74 20 3d 20 6e 75 6c 6c 2c 20 24 74 72 61 6e 73 66 | der($s,.$charset.=.null,.$transf |
35000 | 65 72 45 6e 63 20 3d 20 6e 75 6c 6c 2c 20 24 6c 66 20 3d 20 6e 75 6c 6c 2c 20 24 69 6e 64 65 6e | erEnc.=.null,.$lf.=.null,.$inden |
35020 | 74 20 3d 20 6e 75 6c 6c 29 20 7b 20 72 65 74 75 72 6e 20 70 5c 4d 62 73 74 72 69 6e 67 3a 3a 6d | t.=.null).{.return.p\Mbstring::m |
35040 | 62 5f 65 6e 63 6f 64 65 5f 6d 69 6d 65 68 65 61 64 65 72 28 24 73 2c 20 24 63 68 61 72 73 65 74 | b_encode_mimeheader($s,.$charset |
35060 | 2c 20 24 74 72 61 6e 73 66 65 72 45 6e 63 2c 20 24 6c 66 2c 20 24 69 6e 64 65 6e 74 29 3b 20 7d | ,.$transferEnc,.$lf,.$indent);.} |
35080 | 0a 20 20 20 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 63 6f 6e 76 65 72 74 5f 63 61 73 65 28 24 73 | .....function.mb_convert_case($s |
350a0 | 2c 20 24 6d 6f 64 65 2c 20 24 65 6e 63 20 3d 20 6e 75 6c 6c 29 20 7b 20 72 65 74 75 72 6e 20 70 | ,.$mode,.$enc.=.null).{.return.p |
350c0 | 5c 4d 62 73 74 72 69 6e 67 3a 3a 6d 62 5f 63 6f 6e 76 65 72 74 5f 63 61 73 65 28 24 73 2c 20 24 | \Mbstring::mb_convert_case($s,.$ |
350e0 | 6d 6f 64 65 2c 20 24 65 6e 63 29 3b 20 7d 0a 20 20 20 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 69 | mode,.$enc);.}.....function.mb_i |
35100 | 6e 74 65 72 6e 61 6c 5f 65 6e 63 6f 64 69 6e 67 28 24 65 6e 63 20 3d 20 6e 75 6c 6c 29 20 7b 20 | nternal_encoding($enc.=.null).{. |
35120 | 72 65 74 75 72 6e 20 70 5c 4d 62 73 74 72 69 6e 67 3a 3a 6d 62 5f 69 6e 74 65 72 6e 61 6c 5f 65 | return.p\Mbstring::mb_internal_e |
35140 | 6e 63 6f 64 69 6e 67 28 24 65 6e 63 29 3b 20 7d 0a 20 20 20 20 66 75 6e 63 74 69 6f 6e 20 6d 62 | ncoding($enc);.}.....function.mb |
35160 | 5f 6c 61 6e 67 75 61 67 65 28 24 6c 61 6e 67 20 3d 20 6e 75 6c 6c 29 20 7b 20 72 65 74 75 72 6e | _language($lang.=.null).{.return |
35180 | 20 70 5c 4d 62 73 74 72 69 6e 67 3a 3a 6d 62 5f 6c 61 6e 67 75 61 67 65 28 24 6c 61 6e 67 29 3b | .p\Mbstring::mb_language($lang); |
351a0 | 20 7d 0a 20 20 20 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 6c 69 73 74 5f 65 6e 63 6f 64 69 6e 67 | .}.....function.mb_list_encoding |
351c0 | 73 28 29 20 7b 20 72 65 74 75 72 6e 20 70 5c 4d 62 73 74 72 69 6e 67 3a 3a 6d 62 5f 6c 69 73 74 | s().{.return.p\Mbstring::mb_list |
351e0 | 5f 65 6e 63 6f 64 69 6e 67 73 28 29 3b 20 7d 0a 20 20 20 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f | _encodings();.}.....function.mb_ |
35200 | 65 6e 63 6f 64 69 6e 67 5f 61 6c 69 61 73 65 73 28 24 65 6e 63 6f 64 69 6e 67 29 20 7b 20 72 65 | encoding_aliases($encoding).{.re |
35220 | 74 75 72 6e 20 70 5c 4d 62 73 74 72 69 6e 67 3a 3a 6d 62 5f 65 6e 63 6f 64 69 6e 67 5f 61 6c 69 | turn.p\Mbstring::mb_encoding_ali |
35240 | 61 73 65 73 28 24 65 6e 63 6f 64 69 6e 67 29 3b 20 7d 0a 20 20 20 20 66 75 6e 63 74 69 6f 6e 20 | ases($encoding);.}.....function. |
35260 | 6d 62 5f 63 68 65 63 6b 5f 65 6e 63 6f 64 69 6e 67 28 24 76 61 72 20 3d 20 6e 75 6c 6c 2c 20 24 | mb_check_encoding($var.=.null,.$ |
35280 | 65 6e 63 6f 64 69 6e 67 20 3d 20 6e 75 6c 6c 29 20 7b 20 72 65 74 75 72 6e 20 70 5c 4d 62 73 74 | encoding.=.null).{.return.p\Mbst |
352a0 | 72 69 6e 67 3a 3a 6d 62 5f 63 68 65 63 6b 5f 65 6e 63 6f 64 69 6e 67 28 24 76 61 72 2c 20 24 65 | ring::mb_check_encoding($var,.$e |
352c0 | 6e 63 6f 64 69 6e 67 29 3b 20 7d 0a 20 20 20 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 64 65 74 65 | ncoding);.}.....function.mb_dete |
352e0 | 63 74 5f 65 6e 63 6f 64 69 6e 67 28 24 73 74 72 2c 20 24 65 6e 63 6f 64 69 6e 67 4c 69 73 74 20 | ct_encoding($str,.$encodingList. |
35300 | 3d 20 6e 75 6c 6c 2c 20 24 73 74 72 69 63 74 20 3d 20 66 61 6c 73 65 29 20 7b 20 72 65 74 75 72 | =.null,.$strict.=.false).{.retur |
35320 | 6e 20 70 5c 4d 62 73 74 72 69 6e 67 3a 3a 6d 62 5f 64 65 74 65 63 74 5f 65 6e 63 6f 64 69 6e 67 | n.p\Mbstring::mb_detect_encoding |
35340 | 28 24 73 74 72 2c 20 24 65 6e 63 6f 64 69 6e 67 4c 69 73 74 2c 20 24 73 74 72 69 63 74 29 3b 20 | ($str,.$encodingList,.$strict);. |
35360 | 7d 0a 20 20 20 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 64 65 74 65 63 74 5f 6f 72 64 65 72 28 24 | }.....function.mb_detect_order($ |
35380 | 65 6e 63 6f 64 69 6e 67 4c 69 73 74 20 3d 20 6e 75 6c 6c 29 20 7b 20 72 65 74 75 72 6e 20 70 5c | encodingList.=.null).{.return.p\ |
353a0 | 4d 62 73 74 72 69 6e 67 3a 3a 6d 62 5f 64 65 74 65 63 74 5f 6f 72 64 65 72 28 24 65 6e 63 6f 64 | Mbstring::mb_detect_order($encod |
353c0 | 69 6e 67 4c 69 73 74 29 3b 20 7d 0a 20 20 20 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 70 61 72 73 | ingList);.}.....function.mb_pars |
353e0 | 65 5f 73 74 72 28 24 73 2c 20 26 24 72 65 73 75 6c 74 20 3d 20 61 72 72 61 79 28 29 29 20 7b 20 | e_str($s,.&$result.=.array()).{. |
35400 | 70 61 72 73 65 5f 73 74 72 28 24 73 2c 20 24 72 65 73 75 6c 74 29 3b 20 7d 0a 20 20 20 20 66 75 | parse_str($s,.$result);.}.....fu |
35420 | 6e 63 74 69 6f 6e 20 6d 62 5f 73 74 72 6c 65 6e 28 24 73 2c 20 24 65 6e 63 20 3d 20 6e 75 6c 6c | nction.mb_strlen($s,.$enc.=.null |
35440 | 29 20 7b 20 72 65 74 75 72 6e 20 70 5c 4d 62 73 74 72 69 6e 67 3a 3a 6d 62 5f 73 74 72 6c 65 6e | ).{.return.p\Mbstring::mb_strlen |
35460 | 28 24 73 2c 20 24 65 6e 63 29 3b 20 7d 0a 20 20 20 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 73 74 | ($s,.$enc);.}.....function.mb_st |
35480 | 72 70 6f 73 28 24 73 2c 20 24 6e 65 65 64 6c 65 2c 20 24 6f 66 66 73 65 74 20 3d 20 30 2c 20 24 | rpos($s,.$needle,.$offset.=.0,.$ |
354a0 | 65 6e 63 20 3d 20 6e 75 6c 6c 29 20 7b 20 72 65 74 75 72 6e 20 70 5c 4d 62 73 74 72 69 6e 67 3a | enc.=.null).{.return.p\Mbstring: |
354c0 | 3a 6d 62 5f 73 74 72 70 6f 73 28 24 73 2c 20 24 6e 65 65 64 6c 65 2c 20 24 6f 66 66 73 65 74 2c | :mb_strpos($s,.$needle,.$offset, |
354e0 | 20 24 65 6e 63 29 3b 20 7d 0a 20 20 20 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 73 74 72 74 6f 6c | .$enc);.}.....function.mb_strtol |
35500 | 6f 77 65 72 28 24 73 2c 20 24 65 6e 63 20 3d 20 6e 75 6c 6c 29 20 7b 20 72 65 74 75 72 6e 20 70 | ower($s,.$enc.=.null).{.return.p |
35520 | 5c 4d 62 73 74 72 69 6e 67 3a 3a 6d 62 5f 73 74 72 74 6f 6c 6f 77 65 72 28 24 73 2c 20 24 65 6e | \Mbstring::mb_strtolower($s,.$en |
35540 | 63 29 3b 20 7d 0a 20 20 20 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 73 74 72 74 6f 75 70 70 65 72 | c);.}.....function.mb_strtoupper |
35560 | 28 24 73 2c 20 24 65 6e 63 20 3d 20 6e 75 6c 6c 29 20 7b 20 72 65 74 75 72 6e 20 70 5c 4d 62 73 | ($s,.$enc.=.null).{.return.p\Mbs |
35580 | 74 72 69 6e 67 3a 3a 6d 62 5f 73 74 72 74 6f 75 70 70 65 72 28 24 73 2c 20 24 65 6e 63 29 3b 20 | tring::mb_strtoupper($s,.$enc);. |
355a0 | 7d 0a 20 20 20 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 73 75 62 73 74 69 74 75 74 65 5f 63 68 61 | }.....function.mb_substitute_cha |
355c0 | 72 61 63 74 65 72 28 24 63 68 61 72 20 3d 20 6e 75 6c 6c 29 20 7b 20 72 65 74 75 72 6e 20 70 5c | racter($char.=.null).{.return.p\ |
355e0 | 4d 62 73 74 72 69 6e 67 3a 3a 6d 62 5f 73 75 62 73 74 69 74 75 74 65 5f 63 68 61 72 61 63 74 65 | Mbstring::mb_substitute_characte |
35600 | 72 28 24 63 68 61 72 29 3b 20 7d 0a 20 20 20 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 73 75 62 73 | r($char);.}.....function.mb_subs |
35620 | 74 72 28 24 73 2c 20 24 73 74 61 72 74 2c 20 24 6c 65 6e 67 74 68 20 3d 20 32 31 34 37 34 38 33 | tr($s,.$start,.$length.=.2147483 |
35640 | 36 34 37 2c 20 24 65 6e 63 20 3d 20 6e 75 6c 6c 29 20 7b 20 72 65 74 75 72 6e 20 70 5c 4d 62 73 | 647,.$enc.=.null).{.return.p\Mbs |
35660 | 74 72 69 6e 67 3a 3a 6d 62 5f 73 75 62 73 74 72 28 24 73 2c 20 24 73 74 61 72 74 2c 20 24 6c 65 | tring::mb_substr($s,.$start,.$le |
35680 | 6e 67 74 68 2c 20 24 65 6e 63 29 3b 20 7d 0a 20 20 20 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 73 | ngth,.$enc);.}.....function.mb_s |
356a0 | 74 72 69 70 6f 73 28 24 73 2c 20 24 6e 65 65 64 6c 65 2c 20 24 6f 66 66 73 65 74 20 3d 20 30 2c | tripos($s,.$needle,.$offset.=.0, |
356c0 | 20 24 65 6e 63 20 3d 20 6e 75 6c 6c 29 20 7b 20 72 65 74 75 72 6e 20 70 5c 4d 62 73 74 72 69 6e | .$enc.=.null).{.return.p\Mbstrin |
356e0 | 67 3a 3a 6d 62 5f 73 74 72 69 70 6f 73 28 24 73 2c 20 24 6e 65 65 64 6c 65 2c 20 24 6f 66 66 73 | g::mb_stripos($s,.$needle,.$offs |
35700 | 65 74 2c 20 24 65 6e 63 29 3b 20 7d 0a 20 20 20 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 73 74 72 | et,.$enc);.}.....function.mb_str |
35720 | 69 73 74 72 28 24 73 2c 20 24 6e 65 65 64 6c 65 2c 20 24 70 61 72 74 20 3d 20 66 61 6c 73 65 2c | istr($s,.$needle,.$part.=.false, |
35740 | 20 24 65 6e 63 20 3d 20 6e 75 6c 6c 29 20 7b 20 72 65 74 75 72 6e 20 70 5c 4d 62 73 74 72 69 6e | .$enc.=.null).{.return.p\Mbstrin |
35760 | 67 3a 3a 6d 62 5f 73 74 72 69 73 74 72 28 24 73 2c 20 24 6e 65 65 64 6c 65 2c 20 24 70 61 72 74 | g::mb_stristr($s,.$needle,.$part |
35780 | 2c 20 24 65 6e 63 29 3b 20 7d 0a 20 20 20 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 73 74 72 72 63 | ,.$enc);.}.....function.mb_strrc |
357a0 | 68 72 28 24 73 2c 20 24 6e 65 65 64 6c 65 2c 20 24 70 61 72 74 20 3d 20 66 61 6c 73 65 2c 20 24 | hr($s,.$needle,.$part.=.false,.$ |
357c0 | 65 6e 63 20 3d 20 6e 75 6c 6c 29 20 7b 20 72 65 74 75 72 6e 20 70 5c 4d 62 73 74 72 69 6e 67 3a | enc.=.null).{.return.p\Mbstring: |
357e0 | 3a 6d 62 5f 73 74 72 72 63 68 72 28 24 73 2c 20 24 6e 65 65 64 6c 65 2c 20 24 70 61 72 74 2c 20 | :mb_strrchr($s,.$needle,.$part,. |
35800 | 24 65 6e 63 29 3b 20 7d 0a 20 20 20 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 73 74 72 72 69 63 68 | $enc);.}.....function.mb_strrich |
35820 | 72 28 24 73 2c 20 24 6e 65 65 64 6c 65 2c 20 24 70 61 72 74 20 3d 20 66 61 6c 73 65 2c 20 24 65 | r($s,.$needle,.$part.=.false,.$e |
35840 | 6e 63 20 3d 20 6e 75 6c 6c 29 20 7b 20 72 65 74 75 72 6e 20 70 5c 4d 62 73 74 72 69 6e 67 3a 3a | nc.=.null).{.return.p\Mbstring:: |
35860 | 6d 62 5f 73 74 72 72 69 63 68 72 28 24 73 2c 20 24 6e 65 65 64 6c 65 2c 20 24 70 61 72 74 2c 20 | mb_strrichr($s,.$needle,.$part,. |
35880 | 24 65 6e 63 29 3b 20 7d 0a 20 20 20 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 73 74 72 72 69 70 6f | $enc);.}.....function.mb_strripo |
358a0 | 73 28 24 73 2c 20 24 6e 65 65 64 6c 65 2c 20 24 6f 66 66 73 65 74 20 3d 20 30 2c 20 24 65 6e 63 | s($s,.$needle,.$offset.=.0,.$enc |
358c0 | 20 3d 20 6e 75 6c 6c 29 20 7b 20 72 65 74 75 72 6e 20 70 5c 4d 62 73 74 72 69 6e 67 3a 3a 6d 62 | .=.null).{.return.p\Mbstring::mb |
358e0 | 5f 73 74 72 72 69 70 6f 73 28 24 73 2c 20 24 6e 65 65 64 6c 65 2c 20 24 6f 66 66 73 65 74 2c 20 | _strripos($s,.$needle,.$offset,. |
35900 | 24 65 6e 63 29 3b 20 7d 0a 20 20 20 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 73 74 72 72 70 6f 73 | $enc);.}.....function.mb_strrpos |
35920 | 28 24 73 2c 20 24 6e 65 65 64 6c 65 2c 20 24 6f 66 66 73 65 74 20 3d 20 30 2c 20 24 65 6e 63 20 | ($s,.$needle,.$offset.=.0,.$enc. |
35940 | 3d 20 6e 75 6c 6c 29 20 7b 20 72 65 74 75 72 6e 20 70 5c 4d 62 73 74 72 69 6e 67 3a 3a 6d 62 5f | =.null).{.return.p\Mbstring::mb_ |
35960 | 73 74 72 72 70 6f 73 28 24 73 2c 20 24 6e 65 65 64 6c 65 2c 20 24 6f 66 66 73 65 74 2c 20 24 65 | strrpos($s,.$needle,.$offset,.$e |
35980 | 6e 63 29 3b 20 7d 0a 20 20 20 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 73 74 72 73 74 72 28 24 73 | nc);.}.....function.mb_strstr($s |
359a0 | 2c 20 24 6e 65 65 64 6c 65 2c 20 24 70 61 72 74 20 3d 20 66 61 6c 73 65 2c 20 24 65 6e 63 20 3d | ,.$needle,.$part.=.false,.$enc.= |
359c0 | 20 6e 75 6c 6c 29 20 7b 20 72 65 74 75 72 6e 20 70 5c 4d 62 73 74 72 69 6e 67 3a 3a 6d 62 5f 73 | .null).{.return.p\Mbstring::mb_s |
359e0 | 74 72 73 74 72 28 24 73 2c 20 24 6e 65 65 64 6c 65 2c 20 24 70 61 72 74 2c 20 24 65 6e 63 29 3b | trstr($s,.$needle,.$part,.$enc); |
35a00 | 20 7d 0a 20 20 20 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 67 65 74 5f 69 6e 66 6f 28 24 74 79 70 | .}.....function.mb_get_info($typ |
35a20 | 65 20 3d 20 27 61 6c 6c 27 29 20 7b 20 72 65 74 75 72 6e 20 70 5c 4d 62 73 74 72 69 6e 67 3a 3a | e.=.'all').{.return.p\Mbstring:: |
35a40 | 6d 62 5f 67 65 74 5f 69 6e 66 6f 28 24 74 79 70 65 29 3b 20 7d 0a 20 20 20 20 66 75 6e 63 74 69 | mb_get_info($type);.}.....functi |
35a60 | 6f 6e 20 6d 62 5f 68 74 74 70 5f 6f 75 74 70 75 74 28 24 65 6e 63 20 3d 20 6e 75 6c 6c 29 20 7b | on.mb_http_output($enc.=.null).{ |
35a80 | 20 72 65 74 75 72 6e 20 70 5c 4d 62 73 74 72 69 6e 67 3a 3a 6d 62 5f 68 74 74 70 5f 6f 75 74 70 | .return.p\Mbstring::mb_http_outp |
35aa0 | 75 74 28 24 65 6e 63 29 3b 20 7d 0a 20 20 20 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 73 74 72 77 | ut($enc);.}.....function.mb_strw |
35ac0 | 69 64 74 68 28 24 73 2c 20 24 65 6e 63 20 3d 20 6e 75 6c 6c 29 20 7b 20 72 65 74 75 72 6e 20 70 | idth($s,.$enc.=.null).{.return.p |
35ae0 | 5c 4d 62 73 74 72 69 6e 67 3a 3a 6d 62 5f 73 74 72 77 69 64 74 68 28 24 73 2c 20 24 65 6e 63 29 | \Mbstring::mb_strwidth($s,.$enc) |
35b00 | 3b 20 7d 0a 20 20 20 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 73 75 62 73 74 72 5f 63 6f 75 6e 74 | ;.}.....function.mb_substr_count |
35b20 | 28 24 68 61 79 73 74 61 63 6b 2c 20 24 6e 65 65 64 6c 65 2c 20 24 65 6e 63 20 3d 20 6e 75 6c 6c | ($haystack,.$needle,.$enc.=.null |
35b40 | 29 20 7b 20 72 65 74 75 72 6e 20 70 5c 4d 62 73 74 72 69 6e 67 3a 3a 6d 62 5f 73 75 62 73 74 72 | ).{.return.p\Mbstring::mb_substr |
35b60 | 5f 63 6f 75 6e 74 28 24 68 61 79 73 74 61 63 6b 2c 20 24 6e 65 65 64 6c 65 2c 20 24 65 6e 63 29 | _count($haystack,.$needle,.$enc) |
35b80 | 3b 20 7d 0a 20 20 20 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 6f 75 74 70 75 74 5f 68 61 6e 64 6c | ;.}.....function.mb_output_handl |
35ba0 | 65 72 28 24 63 6f 6e 74 65 6e 74 73 2c 20 24 73 74 61 74 75 73 29 20 7b 20 72 65 74 75 72 6e 20 | er($contents,.$status).{.return. |
35bc0 | 70 5c 4d 62 73 74 72 69 6e 67 3a 3a 6d 62 5f 6f 75 74 70 75 74 5f 68 61 6e 64 6c 65 72 28 24 63 | p\Mbstring::mb_output_handler($c |
35be0 | 6f 6e 74 65 6e 74 73 2c 20 24 73 74 61 74 75 73 29 3b 20 7d 0a 20 20 20 20 66 75 6e 63 74 69 6f | ontents,.$status);.}.....functio |
35c00 | 6e 20 6d 62 5f 68 74 74 70 5f 69 6e 70 75 74 28 24 74 79 70 65 20 3d 20 27 27 29 20 7b 20 72 65 | n.mb_http_input($type.=.'').{.re |
35c20 | 74 75 72 6e 20 70 5c 4d 62 73 74 72 69 6e 67 3a 3a 6d 62 5f 68 74 74 70 5f 69 6e 70 75 74 28 24 | turn.p\Mbstring::mb_http_input($ |
35c40 | 74 79 70 65 29 3b 20 7d 0a 20 20 20 20 66 75 6e 63 74 69 6f 6e 20 6d 62 5f 63 6f 6e 76 65 72 74 | type);.}.....function.mb_convert |
35c60 | 5f 76 61 72 69 61 62 6c 65 73 28 24 74 6f 45 6e 63 6f 64 69 6e 67 2c 20 24 66 72 6f 6d 45 6e 63 | _variables($toEncoding,.$fromEnc |
35c80 | 6f 64 69 6e 67 2c 20 26 24 61 20 3d 20 6e 75 6c 6c 2c 20 26 24 62 20 3d 20 6e 75 6c 6c 2c 20 26 | oding,.&$a.=.null,.&$b.=.null,.& |
35ca0 | 24 63 20 3d 20 6e 75 6c 6c 2c 20 26 24 64 20 3d 20 6e 75 6c 6c 2c 20 26 24 65 20 3d 20 6e 75 6c | $c.=.null,.&$d.=.null,.&$e.=.nul |
35cc0 | 6c 2c 20 26 24 66 20 3d 20 6e 75 6c 6c 29 20 7b 20 72 65 74 75 72 6e 20 70 5c 4d 62 73 74 72 69 | l,.&$f.=.null).{.return.p\Mbstri |
35ce0 | 6e 67 3a 3a 6d 62 5f 63 6f 6e 76 65 72 74 5f 76 61 72 69 61 62 6c 65 73 28 24 74 6f 45 6e 63 6f | ng::mb_convert_variables($toEnco |
35d00 | 64 69 6e 67 2c 20 24 66 72 6f 6d 45 6e 63 6f 64 69 6e 67 2c 20 24 76 30 2c 20 24 61 2c 20 24 62 | ding,.$fromEncoding,.$v0,.$a,.$b |
35d20 | 2c 20 24 63 2c 20 24 64 2c 20 24 65 2c 20 24 66 29 3b 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a | ,.$c,.$d,.$e,.$f);.}.}.<?php../* |
35d40 | 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d | ..*.This.file.is.part.of.the.Sym |
35d60 | 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 | fony.package...*..*.(c).Fabien.P |
35d80 | 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a | otencier.<fabien@symfony.com>..* |
35da0 | 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c | ..*.For.the.full.copyright.and.l |
35dc0 | 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 | icense.information,.please.view. |
35de0 | 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 | the.LICENSE..*.file.that.was.dis |
35e00 | 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a | tributed.with.this.source.code.. |
35e20 | 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 | .*/..namespace.Symfony\Component |
35e40 | 5c 43 6f 6e 73 6f 6c 65 5c 45 76 65 6e 74 3b 0a 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d | \Console\Event;..use.Symfony\Com |
35e60 | 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 43 6f 6d 6d 61 6e 64 5c 43 6f 6d 6d 61 6e 64 3b 0a | ponent\Console\Command\Command;. |
35e80 | 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e | use.Symfony\Component\Console\In |
35ea0 | 70 75 74 5c 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c | put\InputInterface;.use.Symfony\ |
35ec0 | 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 4f 75 74 70 75 74 5c 4f 75 74 70 75 74 49 | Component\Console\Output\OutputI |
35ee0 | 6e 74 65 72 66 61 63 65 3b 0a 0a 2f 2a 2a 0a 20 2a 20 41 6c 6c 6f 77 73 20 74 6f 20 68 61 6e 64 | nterface;../**..*.Allows.to.hand |
35f00 | 6c 65 20 65 78 63 65 70 74 69 6f 6e 20 74 68 72 6f 77 6e 20 69 6e 20 61 20 63 6f 6d 6d 61 6e 64 | le.exception.thrown.in.a.command |
35f20 | 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 | ...*..*.@author.Fabien.Potencier |
35f40 | 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 | .<fabien@symfony.com>..*/.class. |
35f60 | 43 6f 6e 73 6f 6c 65 45 78 63 65 70 74 69 6f 6e 45 76 65 6e 74 20 65 78 74 65 6e 64 73 20 43 6f | ConsoleExceptionEvent.extends.Co |
35f80 | 6e 73 6f 6c 65 45 76 65 6e 74 0a 7b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 65 78 63 65 70 74 | nsoleEvent.{.....private.$except |
35fa0 | 69 6f 6e 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 65 78 69 74 43 6f 64 65 3b 0a 0a 20 20 20 | ion;.....private.$exitCode;..... |
35fc0 | 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 74 28 43 6f 6d | .public.function.__construct(Com |
35fe0 | 6d 61 6e 64 20 24 63 6f 6d 6d 61 6e 64 2c 20 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 69 | mand.$command,.InputInterface.$i |
36000 | 6e 70 75 74 2c 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 2c 20 5c | nput,.OutputInterface.$output,.\ |
36020 | 45 78 63 65 70 74 69 6f 6e 20 24 65 78 63 65 70 74 69 6f 6e 2c 20 24 65 78 69 74 43 6f 64 65 29 | Exception.$exception,.$exitCode) |
36040 | 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 70 61 72 65 6e 74 3a 3a 5f 5f 63 6f 6e 73 74 72 75 | .....{.........parent::__constru |
36060 | 63 74 28 24 63 6f 6d 6d 61 6e 64 2c 20 24 69 6e 70 75 74 2c 20 24 6f 75 74 70 75 74 29 3b 0a 0a | ct($command,.$input,.$output);.. |
36080 | 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 65 74 45 78 63 65 70 74 69 6f 6e 28 24 65 78 63 | ........$this->setException($exc |
360a0 | 65 70 74 69 6f 6e 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 65 78 69 74 43 6f 64 65 | eption);.........$this->exitCode |
360c0 | 20 3d 20 28 69 6e 74 29 20 24 65 78 69 74 43 6f 64 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f | .=.(int).$exitCode;.....}....../ |
360e0 | 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 74 68 65 20 74 68 72 6f 77 6e 20 65 78 63 | **......*.Returns.the.thrown.exc |
36100 | 65 70 74 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 5c 45 | eption.......*......*.@return.\E |
36120 | 78 63 65 70 74 69 6f 6e 20 54 68 65 20 74 68 72 6f 77 6e 20 65 78 63 65 70 74 69 6f 6e 0a 20 20 | xception.The.thrown.exception... |
36140 | 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 45 78 63 | ...*/.....public.function.getExc |
36160 | 65 70 74 69 6f 6e 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 | eption().....{.........return.$t |
36180 | 68 69 73 2d 3e 65 78 63 65 70 74 69 6f 6e 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 | his->exception;.....}....../**.. |
361a0 | 20 20 20 20 2a 20 52 65 70 6c 61 63 65 73 20 74 68 65 20 74 68 72 6f 77 6e 20 65 78 63 65 70 74 | ....*.Replaces.the.thrown.except |
361c0 | 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 54 68 69 73 20 65 78 63 65 70 74 69 6f | ion.......*......*.This.exceptio |
361e0 | 6e 20 77 69 6c 6c 20 62 65 20 74 68 72 6f 77 6e 20 69 66 20 6e 6f 20 72 65 73 70 6f 6e 73 65 20 | n.will.be.thrown.if.no.response. |
36200 | 69 73 20 73 65 74 20 69 6e 20 74 68 65 20 65 76 65 6e 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 | is.set.in.the.event.......*..... |
36220 | 20 2a 20 40 70 61 72 61 6d 20 5c 45 78 63 65 70 74 69 6f 6e 20 24 65 78 63 65 70 74 69 6f 6e 20 | .*.@param.\Exception.$exception. |
36240 | 54 68 65 20 74 68 72 6f 77 6e 20 65 78 63 65 70 74 69 6f 6e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 | The.thrown.exception......*/.... |
36260 | 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 45 78 63 65 70 74 69 6f 6e 28 5c 45 | .public.function.setException(\E |
36280 | 78 63 65 70 74 69 6f 6e 20 24 65 78 63 65 70 74 69 6f 6e 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 | xception.$exception).....{...... |
362a0 | 20 20 20 24 74 68 69 73 2d 3e 65 78 63 65 70 74 69 6f 6e 20 3d 20 24 65 78 63 65 70 74 69 6f 6e | ...$this->exception.=.$exception |
362c0 | 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 | ;.....}....../**......*.Gets.the |
362e0 | 20 65 78 69 74 20 63 6f 64 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 | .exit.code.......*......*.@retur |
36300 | 6e 20 69 6e 74 20 54 68 65 20 63 6f 6d 6d 61 6e 64 20 65 78 69 74 20 63 6f 64 65 0a 20 20 20 20 | n.int.The.command.exit.code..... |
36320 | 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 45 78 69 74 43 | .*/.....public.function.getExitC |
36340 | 6f 64 65 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 | ode().....{.........return.$this |
36360 | 2d 3e 65 78 69 74 43 6f 64 65 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a | ->exitCode;.....}.}.<?php../*..* |
36380 | 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e | .This.file.is.part.of.the.Symfon |
363a0 | 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 | y.package...*..*.(c).Fabien.Pote |
363c0 | 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a | ncier.<fabien@symfony.com>..*..* |
363e0 | 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 | .For.the.full.copyright.and.lice |
36400 | 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 | nse.information,.please.view.the |
36420 | 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 | .LICENSE..*.file.that.was.distri |
36440 | 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f | buted.with.this.source.code...*/ |
36460 | 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f | ..namespace.Symfony\Component\Co |
36480 | 6e 73 6f 6c 65 5c 45 76 65 6e 74 3b 0a 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e | nsole\Event;..use.Symfony\Compon |
364a0 | 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 43 6f 6d 6d 61 6e 64 5c 43 6f 6d 6d 61 6e 64 3b 0a 75 73 65 | ent\Console\Command\Command;.use |
364c0 | 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 | .Symfony\Component\Console\Input |
364e0 | 5c 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d | \InputInterface;.use.Symfony\Com |
36500 | 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 4f 75 74 70 75 74 5c 4f 75 74 70 75 74 49 6e 74 65 | ponent\Console\Output\OutputInte |
36520 | 72 66 61 63 65 3b 0a 0a 2f 2a 2a 0a 20 2a 20 41 6c 6c 6f 77 73 20 74 6f 20 6d 61 6e 69 70 75 6c | rface;../**..*.Allows.to.manipul |
36540 | 61 74 65 20 74 68 65 20 65 78 69 74 20 63 6f 64 65 20 6f 66 20 61 20 63 6f 6d 6d 61 6e 64 20 61 | ate.the.exit.code.of.a.command.a |
36560 | 66 74 65 72 20 69 74 73 20 65 78 65 63 75 74 69 6f 6e 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f | fter.its.execution...*..*.@autho |
36580 | 72 20 46 72 61 6e 63 65 73 63 6f 20 4c 65 76 6f 72 61 74 6f 20 3c 67 69 74 40 66 6c 65 76 6f 75 | r.Francesco.Levorato.<git@flevou |
365a0 | 72 2e 6e 65 74 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 43 6f 6e 73 6f 6c 65 54 65 72 6d 69 6e 61 74 | r.net>..*/.class.ConsoleTerminat |
365c0 | 65 45 76 65 6e 74 20 65 78 74 65 6e 64 73 20 43 6f 6e 73 6f 6c 65 45 76 65 6e 74 0a 7b 0a 20 20 | eEvent.extends.ConsoleEvent.{... |
365e0 | 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 54 68 65 20 65 78 69 74 20 63 6f 64 65 20 6f 66 20 74 68 | ../**......*.The.exit.code.of.th |
36600 | 65 20 63 6f 6d 6d 61 6e 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 76 61 72 20 69 6e | e.command.......*......*.@var.in |
36620 | 74 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 65 78 69 74 43 6f 64 65 3b | t......*/.....private.$exitCode; |
36640 | 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 | ......public.function.__construc |
36660 | 74 28 43 6f 6d 6d 61 6e 64 20 24 63 6f 6d 6d 61 6e 64 2c 20 49 6e 70 75 74 49 6e 74 65 72 66 61 | t(Command.$command,.InputInterfa |
36680 | 63 65 20 24 69 6e 70 75 74 2c 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 | ce.$input,.OutputInterface.$outp |
366a0 | 75 74 2c 20 24 65 78 69 74 43 6f 64 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 70 61 72 | ut,.$exitCode).....{.........par |
366c0 | 65 6e 74 3a 3a 5f 5f 63 6f 6e 73 74 72 75 63 74 28 24 63 6f 6d 6d 61 6e 64 2c 20 24 69 6e 70 75 | ent::__construct($command,.$inpu |
366e0 | 74 2c 20 24 6f 75 74 70 75 74 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 65 74 | t,.$output);..........$this->set |
36700 | 45 78 69 74 43 6f 64 65 28 24 65 78 69 74 43 6f 64 65 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 | ExitCode($exitCode);.....}...... |
36720 | 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 74 68 65 20 65 78 69 74 20 63 6f 64 65 2e 0a 20 | /**......*.Sets.the.exit.code... |
36740 | 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 69 6e 74 20 24 65 78 69 74 43 6f 64 | ....*......*.@param.int.$exitCod |
36760 | 65 20 54 68 65 20 63 6f 6d 6d 61 6e 64 20 65 78 69 74 20 63 6f 64 65 0a 20 20 20 20 20 2a 2f 0a | e.The.command.exit.code......*/. |
36780 | 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 45 78 69 74 43 6f 64 65 28 | ....public.function.setExitCode( |
367a0 | 24 65 78 69 74 43 6f 64 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e | $exitCode).....{.........$this-> |
367c0 | 65 78 69 74 43 6f 64 65 20 3d 20 28 69 6e 74 29 20 24 65 78 69 74 43 6f 64 65 3b 0a 20 20 20 20 | exitCode.=.(int).$exitCode;..... |
367e0 | 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 65 78 69 74 20 | }....../**......*.Gets.the.exit. |
36800 | 63 6f 64 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 69 6e 74 20 | code.......*......*.@return.int. |
36820 | 54 68 65 20 63 6f 6d 6d 61 6e 64 20 65 78 69 74 20 63 6f 64 65 0a 20 20 20 20 20 2a 2f 0a 20 20 | The.command.exit.code......*/... |
36840 | 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 45 78 69 74 43 6f 64 65 28 29 0a | ..public.function.getExitCode(). |
36860 | 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 65 78 69 74 | ....{.........return.$this->exit |
36880 | 43 6f 64 65 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 | Code;.....}.}.<?php../*..*.This. |
368a0 | 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b | file.is.part.of.the.Symfony.pack |
368c0 | 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 | age...*..*.(c).Fabien.Potencier. |
368e0 | 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 | <fabien@symfony.com>..*..*.For.t |
36900 | 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e | he.full.copyright.and.license.in |
36920 | 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e | formation,.please.view.the.LICEN |
36940 | 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 | SE..*.file.that.was.distributed. |
36960 | 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 | with.this.source.code...*/..name |
36980 | 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c | space.Symfony\Component\Console\ |
369a0 | 45 76 65 6e 74 3b 0a 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f | Event;..use.Symfony\Component\Co |
369c0 | 6e 73 6f 6c 65 5c 43 6f 6d 6d 61 6e 64 5c 43 6f 6d 6d 61 6e 64 3b 0a 75 73 65 20 53 79 6d 66 6f | nsole\Command\Command;.use.Symfo |
369e0 | 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 5c 49 6e 70 75 74 | ny\Component\Console\Input\Input |
36a00 | 49 6e 74 65 72 66 61 63 65 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 | Interface;.use.Symfony\Component |
36a20 | 5c 43 6f 6e 73 6f 6c 65 5c 4f 75 74 70 75 74 5c 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 3b | \Console\Output\OutputInterface; |
36a40 | 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 45 76 65 6e 74 44 69 73 70 | .use.Symfony\Component\EventDisp |
36a60 | 61 74 63 68 65 72 5c 45 76 65 6e 74 3b 0a 0a 2f 2a 2a 0a 20 2a 20 41 6c 6c 6f 77 73 20 74 6f 20 | atcher\Event;../**..*.Allows.to. |
36a80 | 69 6e 73 70 65 63 74 20 69 6e 70 75 74 20 61 6e 64 20 6f 75 74 70 75 74 20 6f 66 20 61 20 63 6f | inspect.input.and.output.of.a.co |
36aa0 | 6d 6d 61 6e 64 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 46 72 61 6e 63 65 73 63 6f 20 4c | mmand...*..*.@author.Francesco.L |
36ac0 | 65 76 6f 72 61 74 6f 20 3c 67 69 74 40 66 6c 65 76 6f 75 72 2e 6e 65 74 3e 0a 20 2a 2f 0a 63 6c | evorato.<git@flevour.net>..*/.cl |
36ae0 | 61 73 73 20 43 6f 6e 73 6f 6c 65 45 76 65 6e 74 20 65 78 74 65 6e 64 73 20 45 76 65 6e 74 0a 7b | ass.ConsoleEvent.extends.Event.{ |
36b00 | 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 24 63 6f 6d 6d 61 6e 64 3b 0a 0a 20 20 20 20 70 72 | .....protected.$command;......pr |
36b20 | 69 76 61 74 65 20 24 69 6e 70 75 74 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 6f 75 74 70 75 | ivate.$input;.....private.$outpu |
36b40 | 74 3b 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 63 6f 6e 73 74 72 | t;......public.function.__constr |
36b60 | 75 63 74 28 43 6f 6d 6d 61 6e 64 20 24 63 6f 6d 6d 61 6e 64 2c 20 49 6e 70 75 74 49 6e 74 65 72 | uct(Command.$command,.InputInter |
36b80 | 66 61 63 65 20 24 69 6e 70 75 74 2c 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 | face.$input,.OutputInterface.$ou |
36ba0 | 74 70 75 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 63 6f 6d 6d 61 | tput).....{.........$this->comma |
36bc0 | 6e 64 20 3d 20 24 63 6f 6d 6d 61 6e 64 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 69 6e | nd.=.$command;.........$this->in |
36be0 | 70 75 74 20 3d 20 24 69 6e 70 75 74 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6f 75 74 | put.=.$input;.........$this->out |
36c00 | 70 75 74 20 3d 20 24 6f 75 74 70 75 74 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 | put.=.$output;.....}....../**... |
36c20 | 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 63 6f 6d 6d 61 6e 64 20 74 68 61 74 20 69 73 20 65 78 | ...*.Gets.the.command.that.is.ex |
36c40 | 65 63 75 74 65 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 43 6f | ecuted.......*......*.@return.Co |
36c60 | 6d 6d 61 6e 64 20 41 20 43 6f 6d 6d 61 6e 64 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 2f | mmand.A.Command.instance......*/ |
36c80 | 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 43 6f 6d 6d 61 6e 64 28 | .....public.function.getCommand( |
36ca0 | 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 63 6f | ).....{.........return.$this->co |
36cc0 | 6d 6d 61 6e 64 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 | mmand;.....}....../**......*.Get |
36ce0 | 73 20 74 68 65 20 69 6e 70 75 74 20 69 6e 73 74 61 6e 63 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 | s.the.input.instance.......*.... |
36d00 | 20 20 2a 20 40 72 65 74 75 72 6e 20 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 20 41 6e 20 49 6e | ..*.@return.InputInterface.An.In |
36d20 | 70 75 74 49 6e 74 65 72 66 61 63 65 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 | putInterface.instance......*/... |
36d40 | 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 49 6e 70 75 74 28 29 0a 20 20 20 | ..public.function.getInput().... |
36d60 | 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 69 6e 70 75 74 3b 0a | .{.........return.$this->input;. |
36d80 | 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 6f | ....}....../**......*.Gets.the.o |
36da0 | 75 74 70 75 74 20 69 6e 73 74 61 6e 63 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 | utput.instance.......*......*.@r |
36dc0 | 65 74 75 72 6e 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 41 6e 20 4f 75 74 70 75 74 49 | eturn.OutputInterface.An.OutputI |
36de0 | 6e 74 65 72 66 61 63 65 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 | nterface.instance......*/.....pu |
36e00 | 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 4f 75 74 70 75 74 28 29 0a 20 20 20 20 7b 0a | blic.function.getOutput().....{. |
36e20 | 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 3b 0a 20 20 | ........return.$this->output;... |
36e40 | 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 | ..}.}.<?php../*..*.This.file.is. |
36e60 | 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a | part.of.the.Symfony.package...*. |
36e80 | 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 | .*.(c).Fabien.Potencier.<fabien@ |
36ea0 | 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 | symfony.com>..*..*.For.the.full. |
36ec0 | 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f | copyright.and.license.informatio |
36ee0 | 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 | n,.please.view.the.LICENSE..*.fi |
36f00 | 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 | le.that.was.distributed.with.thi |
36f20 | 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 | s.source.code...*/..namespace.Sy |
36f40 | 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 76 65 6e 74 3b 0a 0a | mfony\Component\Console\Event;.. |
36f60 | 2f 2a 2a 0a 20 2a 20 41 6c 6c 6f 77 73 20 74 6f 20 64 6f 20 74 68 69 6e 67 73 20 62 65 66 6f 72 | /**..*.Allows.to.do.things.befor |
36f80 | 65 20 74 68 65 20 63 6f 6d 6d 61 6e 64 20 69 73 20 65 78 65 63 75 74 65 64 2c 20 6c 69 6b 65 20 | e.the.command.is.executed,.like. |
36fa0 | 73 6b 69 70 70 69 6e 67 20 74 68 65 20 63 6f 6d 6d 61 6e 64 20 6f 72 20 63 68 61 6e 67 69 6e 67 | skipping.the.command.or.changing |
36fc0 | 20 74 68 65 20 69 6e 70 75 74 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 46 61 62 69 65 6e | .the.input...*..*.@author.Fabien |
36fe0 | 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a | .Potencier.<fabien@symfony.com>. |
37000 | 20 2a 2f 0a 63 6c 61 73 73 20 43 6f 6e 73 6f 6c 65 43 6f 6d 6d 61 6e 64 45 76 65 6e 74 20 65 78 | .*/.class.ConsoleCommandEvent.ex |
37020 | 74 65 6e 64 73 20 43 6f 6e 73 6f 6c 65 45 76 65 6e 74 0a 7b 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 | tends.ConsoleEvent.{...../**.... |
37040 | 20 20 2a 20 54 68 65 20 72 65 74 75 72 6e 20 63 6f 64 65 20 66 6f 72 20 73 6b 69 70 70 65 64 20 | ..*.The.return.code.for.skipped. |
37060 | 63 6f 6d 6d 61 6e 64 73 2c 20 74 68 69 73 20 77 69 6c 6c 20 61 6c 73 6f 20 62 65 20 70 61 73 73 | commands,.this.will.also.be.pass |
37080 | 65 64 20 69 6e 74 6f 20 74 68 65 20 74 65 72 6d 69 6e 61 74 65 20 65 76 65 6e 74 2e 0a 20 20 20 | ed.into.the.terminate.event..... |
370a0 | 20 20 2a 2f 0a 20 20 20 20 63 6f 6e 73 74 20 52 45 54 55 52 4e 5f 43 4f 44 45 5f 44 49 53 41 42 | ..*/.....const.RETURN_CODE_DISAB |
370c0 | 4c 45 44 20 3d 20 31 31 33 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 49 6e 64 69 63 | LED.=.113;....../**......*.Indic |
370e0 | 61 74 65 73 20 69 66 20 74 68 65 20 63 6f 6d 6d 61 6e 64 20 73 68 6f 75 6c 64 20 62 65 20 72 75 | ates.if.the.command.should.be.ru |
37100 | 6e 20 6f 72 20 73 6b 69 70 70 65 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 76 61 72 | n.or.skipped.......*......*.@var |
37120 | 20 62 6f 6f 6c 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 63 6f 6d 6d 61 | .bool......*/.....private.$comma |
37140 | 6e 64 53 68 6f 75 6c 64 52 75 6e 20 3d 20 74 72 75 65 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 | ndShouldRun.=.true;....../**.... |
37160 | 20 20 2a 20 44 69 73 61 62 6c 65 73 20 74 68 65 20 63 6f 6d 6d 61 6e 64 2c 20 73 6f 20 69 74 20 | ..*.Disables.the.command,.so.it. |
37180 | 77 6f 6e 27 74 20 62 65 20 72 75 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 | won't.be.run.......*......*.@ret |
371a0 | 75 72 6e 20 62 6f 6f 6c 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 | urn.bool......*/.....public.func |
371c0 | 74 69 6f 6e 20 64 69 73 61 62 6c 65 43 6f 6d 6d 61 6e 64 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 | tion.disableCommand().....{..... |
371e0 | 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 63 6f 6d 6d 61 6e 64 53 68 6f 75 6c 64 52 | ....return.$this->commandShouldR |
37200 | 75 6e 20 3d 20 66 61 6c 73 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 | un.=.false;.....}....../**...... |
37220 | 2a 20 45 6e 61 62 6c 65 73 20 74 68 65 20 63 6f 6d 6d 61 6e 64 2e 0a 20 20 20 20 20 2a 0a 20 20 | *.Enables.the.command.......*... |
37240 | 20 20 20 2a 20 40 72 65 74 75 72 6e 20 62 6f 6f 6c 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 | ...*.@return.bool......*/.....pu |
37260 | 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 65 6e 61 62 6c 65 43 6f 6d 6d 61 6e 64 28 29 0a 20 20 | blic.function.enableCommand()... |
37280 | 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 63 6f 6d 6d 61 6e | ..{.........return.$this->comman |
372a0 | 64 53 68 6f 75 6c 64 52 75 6e 20 3d 20 74 72 75 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a | dShouldRun.=.true;.....}....../* |
372c0 | 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 74 72 75 65 20 69 66 20 74 68 65 20 63 6f 6d | *......*.Returns.true.if.the.com |
372e0 | 6d 61 6e 64 20 69 73 20 72 75 6e 6e 61 62 6c 65 2c 20 66 61 6c 73 65 20 6f 74 68 65 72 77 69 73 | mand.is.runnable,.false.otherwis |
37300 | 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 62 6f 6f 6c 0a 20 20 | e.......*......*.@return.bool... |
37320 | 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 63 6f 6d 6d 61 6e | ...*/.....public.function.comman |
37340 | 64 53 68 6f 75 6c 64 52 75 6e 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 | dShouldRun().....{.........retur |
37360 | 6e 20 24 74 68 69 73 2d 3e 63 6f 6d 6d 61 6e 64 53 68 6f 75 6c 64 52 75 6e 3b 0a 20 20 20 20 7d | n.$this->commandShouldRun;.....} |
37380 | 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 | .}.<?php../*..*.This.file.is.par |
373a0 | 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 | t.of.the.Symfony.package...*..*. |
373c0 | 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d | (c).Fabien.Potencier.<fabien@sym |
373e0 | 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 | fony.com>..*..*.For.the.full.cop |
37400 | 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 | yright.and.license.information,. |
37420 | 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 | please.view.the.LICENSE..*.file. |
37440 | 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 | that.was.distributed.with.this.s |
37460 | 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f | ource.code...*/..namespace.Symfo |
37480 | 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 53 74 79 6c 65 3b 0a 0a 75 73 65 | ny\Component\Console\Style;..use |
374a0 | 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 46 6f 72 6d 61 | .Symfony\Component\Console\Forma |
374c0 | 74 74 65 72 5c 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 49 6e 74 65 72 66 61 63 65 3b 0a 75 | tter\OutputFormatterInterface;.u |
374e0 | 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 48 65 6c | se.Symfony\Component\Console\Hel |
37500 | 70 65 72 5c 50 72 6f 67 72 65 73 73 42 61 72 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d | per\ProgressBar;.use.Symfony\Com |
37520 | 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 4f 75 74 70 75 74 5c 4f 75 74 70 75 74 49 6e 74 65 | ponent\Console\Output\OutputInte |
37540 | 72 66 61 63 65 3b 0a 0a 2f 2a 2a 0a 20 2a 20 44 65 63 6f 72 61 74 65 73 20 6f 75 74 70 75 74 20 | rface;../**..*.Decorates.output. |
37560 | 74 6f 20 61 64 64 20 63 6f 6e 73 6f 6c 65 20 73 74 79 6c 65 20 67 75 69 64 65 20 68 65 6c 70 65 | to.add.console.style.guide.helpe |
37580 | 72 73 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 4b 65 76 69 6e 20 42 6f 6e 64 20 3c 6b 65 | rs...*..*.@author.Kevin.Bond.<ke |
375a0 | 76 69 6e 62 6f 6e 64 40 67 6d 61 69 6c 2e 63 6f 6d 3e 0a 20 2a 2f 0a 61 62 73 74 72 61 63 74 20 | vinbond@gmail.com>..*/.abstract. |
375c0 | 63 6c 61 73 73 20 4f 75 74 70 75 74 53 74 79 6c 65 20 69 6d 70 6c 65 6d 65 6e 74 73 20 4f 75 74 | class.OutputStyle.implements.Out |
375e0 | 70 75 74 49 6e 74 65 72 66 61 63 65 2c 20 53 74 79 6c 65 49 6e 74 65 72 66 61 63 65 0a 7b 0a 20 | putInterface,.StyleInterface.{.. |
37600 | 20 20 20 70 72 69 76 61 74 65 20 24 6f 75 74 70 75 74 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 | ...private.$output;....../**.... |
37620 | 20 20 2a 20 40 70 61 72 61 6d 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 | ..*.@param.OutputInterface.$outp |
37640 | 75 74 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f | ut......*/.....public.function._ |
37660 | 5f 63 6f 6e 73 74 72 75 63 74 28 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 | _construct(OutputInterface.$outp |
37680 | 75 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 20 | ut).....{.........$this->output. |
376a0 | 3d 20 24 6f 75 74 70 75 74 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a | =.$output;.....}....../**......* |
376c0 | 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 | .{@inheritdoc}......*/.....publi |
376e0 | 63 20 66 75 6e 63 74 69 6f 6e 20 6e 65 77 4c 69 6e 65 28 24 63 6f 75 6e 74 20 3d 20 31 29 0a 20 | c.function.newLine($count.=.1).. |
37700 | 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 2d 3e 77 72 69 74 | ...{.........$this->output->writ |
37720 | 65 28 73 74 72 5f 72 65 70 65 61 74 28 50 48 50 5f 45 4f 4c 2c 20 24 63 6f 75 6e 74 29 29 3b 0a | e(str_repeat(PHP_EOL,.$count));. |
37740 | 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 69 6e 74 | ....}....../**......*.@param.int |
37760 | 20 24 6d 61 78 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 50 72 6f 67 | .$max......*......*.@return.Prog |
37780 | 72 65 73 73 42 61 72 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 | ressBar......*/.....public.funct |
377a0 | 69 6f 6e 20 63 72 65 61 74 65 50 72 6f 67 72 65 73 73 42 61 72 28 24 6d 61 78 20 3d 20 30 29 0a | ion.createProgressBar($max.=.0). |
377c0 | 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6e 65 77 20 50 72 6f 67 72 65 73 | ....{.........return.new.Progres |
377e0 | 73 42 61 72 28 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 2c 20 24 6d 61 78 29 3b 0a 20 20 20 20 7d | sBar($this->output,.$max);.....} |
37800 | 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 | ....../**......*.{@inheritdoc}.. |
37820 | 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 77 72 69 74 65 | ....*/.....public.function.write |
37840 | 28 24 6d 65 73 73 61 67 65 73 2c 20 24 6e 65 77 6c 69 6e 65 20 3d 20 66 61 6c 73 65 2c 20 24 74 | ($messages,.$newline.=.false,.$t |
37860 | 79 70 65 20 3d 20 73 65 6c 66 3a 3a 4f 55 54 50 55 54 5f 4e 4f 52 4d 41 4c 29 0a 20 20 20 20 7b | ype.=.self::OUTPUT_NORMAL).....{ |
37880 | 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 28 24 6d | .........$this->output->write($m |
378a0 | 65 73 73 61 67 65 73 2c 20 24 6e 65 77 6c 69 6e 65 2c 20 24 74 79 70 65 29 3b 0a 20 20 20 20 7d | essages,.$newline,.$type);.....} |
378c0 | 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 | ....../**......*.{@inheritdoc}.. |
378e0 | 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 77 72 69 74 65 | ....*/.....public.function.write |
37900 | 6c 6e 28 24 6d 65 73 73 61 67 65 73 2c 20 24 74 79 70 65 20 3d 20 73 65 6c 66 3a 3a 4f 55 54 50 | ln($messages,.$type.=.self::OUTP |
37920 | 55 54 5f 4e 4f 52 4d 41 4c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e | UT_NORMAL).....{.........$this-> |
37940 | 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 24 6d 65 73 73 61 67 65 73 2c 20 24 74 79 70 65 | output->writeln($messages,.$type |
37960 | 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 | );.....}....../**......*.{@inher |
37980 | 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 | itdoc}......*/.....public.functi |
379a0 | 6f 6e 20 73 65 74 56 65 72 62 6f 73 69 74 79 28 24 6c 65 76 65 6c 29 0a 20 20 20 20 7b 0a 20 20 | on.setVerbosity($level).....{... |
379c0 | 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 2d 3e 73 65 74 56 65 72 62 6f 73 69 74 | ......$this->output->setVerbosit |
379e0 | 79 28 24 6c 65 76 65 6c 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a | y($level);.....}....../**......* |
37a00 | 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 | .{@inheritdoc}......*/.....publi |
37a20 | 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 56 65 72 62 6f 73 69 74 79 28 29 0a 20 20 20 20 7b 0a | c.function.getVerbosity().....{. |
37a40 | 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 2d 3e 67 65 | ........return.$this->output->ge |
37a60 | 74 56 65 72 62 6f 73 69 74 79 28 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 | tVerbosity();.....}....../**.... |
37a80 | 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 | ..*.{@inheritdoc}......*/.....pu |
37aa0 | 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 44 65 63 6f 72 61 74 65 64 28 24 64 65 63 6f | blic.function.setDecorated($deco |
37ac0 | 72 61 74 65 64 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6f 75 74 70 | rated).....{.........$this->outp |
37ae0 | 75 74 2d 3e 73 65 74 44 65 63 6f 72 61 74 65 64 28 24 64 65 63 6f 72 61 74 65 64 29 3b 0a 20 20 | ut->setDecorated($decorated);... |
37b00 | 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 | ..}....../**......*.{@inheritdoc |
37b20 | 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 69 73 | }......*/.....public.function.is |
37b40 | 44 65 63 6f 72 61 74 65 64 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e | Decorated().....{.........return |
37b60 | 20 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 2d 3e 69 73 44 65 63 6f 72 61 74 65 64 28 29 3b 0a 20 | .$this->output->isDecorated();.. |
37b80 | 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f | ...}....../**......*.{@inheritdo |
37ba0 | 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 | c}......*/.....public.function.s |
37bc0 | 65 74 46 6f 72 6d 61 74 74 65 72 28 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 49 6e 74 65 72 | etFormatter(OutputFormatterInter |
37be0 | 66 61 63 65 20 24 66 6f 72 6d 61 74 74 65 72 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 | face.$formatter).....{.........$ |
37c00 | 74 68 69 73 2d 3e 6f 75 74 70 75 74 2d 3e 73 65 74 46 6f 72 6d 61 74 74 65 72 28 24 66 6f 72 6d | this->output->setFormatter($form |
37c20 | 61 74 74 65 72 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 | atter);.....}....../**......*.{@ |
37c40 | 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 | inheritdoc}......*/.....public.f |
37c60 | 75 6e 63 74 69 6f 6e 20 67 65 74 46 6f 72 6d 61 74 74 65 72 28 29 0a 20 20 20 20 7b 0a 20 20 20 | unction.getFormatter().....{.... |
37c80 | 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 2d 3e 67 65 74 46 6f | .....return.$this->output->getFo |
37ca0 | 72 6d 61 74 74 65 72 28 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a | rmatter();.....}....../**......* |
37cc0 | 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 | .{@inheritdoc}......*/.....publi |
37ce0 | 63 20 66 75 6e 63 74 69 6f 6e 20 69 73 51 75 69 65 74 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 | c.function.isQuiet().....{...... |
37d00 | 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 2d 3e 69 73 51 75 69 65 74 | ...return.$this->output->isQuiet |
37d20 | 28 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 | ();.....}....../**......*.{@inhe |
37d40 | 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 | ritdoc}......*/.....public.funct |
37d60 | 69 6f 6e 20 69 73 56 65 72 62 6f 73 65 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 | ion.isVerbose().....{.........re |
37d80 | 74 75 72 6e 20 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 2d 3e 69 73 56 65 72 62 6f 73 65 28 29 3b | turn.$this->output->isVerbose(); |
37da0 | 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 | .....}....../**......*.{@inherit |
37dc0 | 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e | doc}......*/.....public.function |
37de0 | 20 69 73 56 65 72 79 56 65 72 62 6f 73 65 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 | .isVeryVerbose().....{.........r |
37e00 | 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 2d 3e 69 73 56 65 72 79 56 65 72 62 6f | eturn.$this->output->isVeryVerbo |
37e20 | 73 65 28 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e | se();.....}....../**......*.{@in |
37e40 | 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e | heritdoc}......*/.....public.fun |
37e60 | 63 74 69 6f 6e 20 69 73 44 65 62 75 67 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 | ction.isDebug().....{.........re |
37e80 | 74 75 72 6e 20 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 2d 3e 69 73 44 65 62 75 67 28 29 3b 0a 20 | turn.$this->output->isDebug();.. |
37ea0 | 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 | ...}.}.<?php../*..*.This.file.is |
37ec0 | 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a | .part.of.the.Symfony.package...* |
37ee0 | 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e | ..*.(c).Fabien.Potencier.<fabien |
37f00 | 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c | @symfony.com>..*..*.For.the.full |
37f20 | 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 | .copyright.and.license.informati |
37f40 | 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 | on,.please.view.the.LICENSE..*.f |
37f60 | 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 | ile.that.was.distributed.with.th |
37f80 | 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 | is.source.code...*/..namespace.S |
37fa0 | 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 53 74 79 6c 65 3b 0a | ymfony\Component\Console\Style;. |
37fc0 | 0a 2f 2a 2a 0a 20 2a 20 4f 75 74 70 75 74 20 73 74 79 6c 65 20 68 65 6c 70 65 72 73 2e 0a 20 2a | ./**..*.Output.style.helpers...* |
37fe0 | 0a 20 2a 20 40 61 75 74 68 6f 72 20 4b 65 76 69 6e 20 42 6f 6e 64 20 3c 6b 65 76 69 6e 62 6f 6e | ..*.@author.Kevin.Bond.<kevinbon |
38000 | 64 40 67 6d 61 69 6c 2e 63 6f 6d 3e 0a 20 2a 2f 0a 69 6e 74 65 72 66 61 63 65 20 53 74 79 6c 65 | d@gmail.com>..*/.interface.Style |
38020 | 49 6e 74 65 72 66 61 63 65 0a 7b 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 46 6f 72 6d 61 | Interface.{...../**......*.Forma |
38040 | 74 73 20 61 20 63 6f 6d 6d 61 6e 64 20 74 69 74 6c 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 | ts.a.command.title.......*...... |
38060 | 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6d 65 73 73 61 67 65 0a 20 20 20 20 20 2a 2f | *.@param.string.$message......*/ |
38080 | 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 74 69 74 6c 65 28 24 6d 65 73 73 | .....public.function.title($mess |
380a0 | 61 67 65 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 46 6f 72 6d 61 74 73 20 61 20 | age);....../**......*.Formats.a. |
380c0 | 73 65 63 74 69 6f 6e 20 74 69 74 6c 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 | section.title.......*......*.@pa |
380e0 | 72 61 6d 20 73 74 72 69 6e 67 20 24 6d 65 73 73 61 67 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 | ram.string.$message......*/..... |
38100 | 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 63 74 69 6f 6e 28 24 6d 65 73 73 61 67 65 | public.function.section($message |
38120 | 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 46 6f 72 6d 61 74 73 20 61 20 6c 69 73 | );....../**......*.Formats.a.lis |
38140 | 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 24 65 | t.......*......*.@param.array.$e |
38160 | 6c 65 6d 65 6e 74 73 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 | lements......*/.....public.funct |
38180 | 69 6f 6e 20 6c 69 73 74 69 6e 67 28 61 72 72 61 79 20 24 65 6c 65 6d 65 6e 74 73 29 3b 0a 0a 20 | ion.listing(array.$elements);... |
381a0 | 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 46 6f 72 6d 61 74 73 20 69 6e 66 6f 72 6d 61 74 69 6f | .../**......*.Formats.informatio |
381c0 | 6e 61 6c 20 74 65 78 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 | nal.text.......*......*.@param.s |
381e0 | 74 72 69 6e 67 7c 61 72 72 61 79 20 24 6d 65 73 73 61 67 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 | tring|array.$message......*/.... |
38200 | 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 74 65 78 74 28 24 6d 65 73 73 61 67 65 29 3b | .public.function.text($message); |
38220 | 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 46 6f 72 6d 61 74 73 20 61 20 73 75 63 63 65 | ....../**......*.Formats.a.succe |
38240 | 73 73 20 72 65 73 75 6c 74 20 62 61 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 | ss.result.bar.......*......*.@pa |
38260 | 72 61 6d 20 73 74 72 69 6e 67 7c 61 72 72 61 79 20 24 6d 65 73 73 61 67 65 0a 20 20 20 20 20 2a | ram.string|array.$message......* |
38280 | 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 75 63 63 65 73 73 28 24 6d | /.....public.function.success($m |
382a0 | 65 73 73 61 67 65 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 46 6f 72 6d 61 74 73 | essage);....../**......*.Formats |
382c0 | 20 61 6e 20 65 72 72 6f 72 20 72 65 73 75 6c 74 20 62 61 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 | .an.error.result.bar.......*.... |
382e0 | 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 7c 61 72 72 61 79 20 24 6d 65 73 73 61 67 65 | ..*.@param.string|array.$message |
38300 | 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 65 72 72 | ......*/.....public.function.err |
38320 | 6f 72 28 24 6d 65 73 73 61 67 65 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 46 6f | or($message);....../**......*.Fo |
38340 | 72 6d 61 74 73 20 61 6e 20 77 61 72 6e 69 6e 67 20 72 65 73 75 6c 74 20 62 61 72 2e 0a 20 20 20 | rmats.an.warning.result.bar..... |
38360 | 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 7c 61 72 72 61 79 20 24 | ..*......*.@param.string|array.$ |
38380 | 6d 65 73 73 61 67 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 | message......*/.....public.funct |
383a0 | 69 6f 6e 20 77 61 72 6e 69 6e 67 28 24 6d 65 73 73 61 67 65 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a | ion.warning($message);....../**. |
383c0 | 20 20 20 20 20 2a 20 46 6f 72 6d 61 74 73 20 61 20 6e 6f 74 65 20 61 64 6d 6f 6e 69 74 69 6f 6e | .....*.Formats.a.note.admonition |
383e0 | 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 7c 61 72 | .......*......*.@param.string|ar |
38400 | 72 61 79 20 24 6d 65 73 73 61 67 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 | ray.$message......*/.....public. |
38420 | 66 75 6e 63 74 69 6f 6e 20 6e 6f 74 65 28 24 6d 65 73 73 61 67 65 29 3b 0a 0a 20 20 20 20 2f 2a | function.note($message);....../* |
38440 | 2a 0a 20 20 20 20 20 2a 20 46 6f 72 6d 61 74 73 20 61 20 63 61 75 74 69 6f 6e 20 61 64 6d 6f 6e | *......*.Formats.a.caution.admon |
38460 | 69 74 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 | ition.......*......*.@param.stri |
38480 | 6e 67 7c 61 72 72 61 79 20 24 6d 65 73 73 61 67 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 | ng|array.$message......*/.....pu |
384a0 | 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 63 61 75 74 69 6f 6e 28 24 6d 65 73 73 61 67 65 29 3b | blic.function.caution($message); |
384c0 | 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 46 6f 72 6d 61 74 73 20 61 20 74 61 62 6c 65 | ....../**......*.Formats.a.table |
384e0 | 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 24 68 65 | .......*......*.@param.array.$he |
38500 | 61 64 65 72 73 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 24 72 6f 77 73 0a | aders......*.@param.array.$rows. |
38520 | 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 74 61 62 6c | .....*/.....public.function.tabl |
38540 | 65 28 61 72 72 61 79 20 24 68 65 61 64 65 72 73 2c 20 61 72 72 61 79 20 24 72 6f 77 73 29 3b 0a | e(array.$headers,.array.$rows);. |
38560 | 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 41 73 6b 73 20 61 20 71 75 65 73 74 69 6f 6e 2e | ...../**......*.Asks.a.question. |
38580 | 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 20 20 20 | ......*......*.@param.string.... |
385a0 | 20 20 20 20 24 71 75 65 73 74 69 6f 6e 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 | ....$question......*.@param.stri |
385c0 | 6e 67 7c 6e 75 6c 6c 20 20 20 24 64 65 66 61 75 6c 74 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d | ng|null...$default......*.@param |
385e0 | 20 63 61 6c 6c 61 62 6c 65 7c 6e 75 6c 6c 20 24 76 61 6c 69 64 61 74 6f 72 0a 20 20 20 20 20 2a | .callable|null.$validator......* |
38600 | 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 0a 20 20 20 20 20 2a 2f 0a 20 | ......*.@return.string......*/.. |
38620 | 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 61 73 6b 28 24 71 75 65 73 74 69 6f 6e | ...public.function.ask($question |
38640 | 2c 20 24 64 65 66 61 75 6c 74 20 3d 20 6e 75 6c 6c 2c 20 24 76 61 6c 69 64 61 74 6f 72 20 3d 20 | ,.$default.=.null,.$validator.=. |
38660 | 6e 75 6c 6c 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 41 73 6b 73 20 61 20 71 75 | null);....../**......*.Asks.a.qu |
38680 | 65 73 74 69 6f 6e 20 77 69 74 68 20 74 68 65 20 75 73 65 72 20 69 6e 70 75 74 20 68 69 64 64 65 | estion.with.the.user.input.hidde |
386a0 | 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 20 | n.......*......*.@param.string.. |
386c0 | 20 20 20 20 20 20 24 71 75 65 73 74 69 6f 6e 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 63 61 | ......$question......*.@param.ca |
386e0 | 6c 6c 61 62 6c 65 7c 6e 75 6c 6c 20 24 76 61 6c 69 64 61 74 6f 72 0a 20 20 20 20 20 2a 0a 20 20 | llable|null.$validator......*... |
38700 | 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 | ...*.@return.string......*/..... |
38720 | 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 61 73 6b 48 69 64 64 65 6e 28 24 71 75 65 73 74 | public.function.askHidden($quest |
38740 | 69 6f 6e 2c 20 24 76 61 6c 69 64 61 74 6f 72 20 3d 20 6e 75 6c 6c 29 3b 0a 0a 20 20 20 20 2f 2a | ion,.$validator.=.null);....../* |
38760 | 2a 0a 20 20 20 20 20 2a 20 41 73 6b 73 20 66 6f 72 20 63 6f 6e 66 69 72 6d 61 74 69 6f 6e 2e 0a | *......*.Asks.for.confirmation.. |
38780 | 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 71 75 65 | .....*......*.@param.string.$que |
387a0 | 73 74 69 6f 6e 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 62 6f 6f 6c 20 20 20 24 64 65 66 61 | stion......*.@param.bool...$defa |
387c0 | 75 6c 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 62 6f 6f 6c 0a 20 | ult......*......*.@return.bool.. |
387e0 | 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 63 6f 6e 66 69 | ....*/.....public.function.confi |
38800 | 72 6d 28 24 71 75 65 73 74 69 6f 6e 2c 20 24 64 65 66 61 75 6c 74 20 3d 20 74 72 75 65 29 3b 0a | rm($question,.$default.=.true);. |
38820 | 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 41 73 6b 73 20 61 20 63 68 6f 69 63 65 20 71 75 | ...../**......*.Asks.a.choice.qu |
38840 | 65 73 74 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 | estion.......*......*.@param.str |
38860 | 69 6e 67 20 20 20 20 20 20 20 20 20 20 24 71 75 65 73 74 69 6f 6e 0a 20 20 20 20 20 2a 20 40 70 | ing..........$question......*.@p |
38880 | 61 72 61 6d 20 61 72 72 61 79 20 20 20 20 20 20 20 20 20 20 20 24 63 68 6f 69 63 65 73 0a 20 20 | aram.array...........$choices... |
388a0 | 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 7c 69 6e 74 7c 6e 75 6c 6c 20 24 64 65 66 | ...*.@param.string|int|null.$def |
388c0 | 61 75 6c 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e | ault......*......*.@return.strin |
388e0 | 67 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 63 68 | g......*/.....public.function.ch |
38900 | 6f 69 63 65 28 24 71 75 65 73 74 69 6f 6e 2c 20 61 72 72 61 79 20 24 63 68 6f 69 63 65 73 2c 20 | oice($question,.array.$choices,. |
38920 | 24 64 65 66 61 75 6c 74 20 3d 20 6e 75 6c 6c 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 | $default.=.null);....../**...... |
38940 | 2a 20 41 64 64 20 6e 65 77 6c 69 6e 65 28 73 29 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 | *.Add.newline(s).......*......*. |
38960 | 40 70 61 72 61 6d 20 69 6e 74 20 24 63 6f 75 6e 74 20 54 68 65 20 6e 75 6d 62 65 72 20 6f 66 20 | @param.int.$count.The.number.of. |
38980 | 6e 65 77 6c 69 6e 65 73 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 | newlines......*/.....public.func |
389a0 | 74 69 6f 6e 20 6e 65 77 4c 69 6e 65 28 24 63 6f 75 6e 74 20 3d 20 31 29 3b 0a 0a 20 20 20 20 2f | tion.newLine($count.=.1);....../ |
389c0 | 2a 2a 0a 20 20 20 20 20 2a 20 53 74 61 72 74 73 20 74 68 65 20 70 72 6f 67 72 65 73 73 20 6f 75 | **......*.Starts.the.progress.ou |
389e0 | 74 70 75 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 69 6e 74 20 24 | tput.......*......*.@param.int.$ |
38a00 | 6d 61 78 20 4d 61 78 69 6d 75 6d 20 73 74 65 70 73 20 28 30 20 69 66 20 75 6e 6b 6e 6f 77 6e 29 | max.Maximum.steps.(0.if.unknown) |
38a20 | 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 70 72 6f | ......*/.....public.function.pro |
38a40 | 67 72 65 73 73 53 74 61 72 74 28 24 6d 61 78 20 3d 20 30 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 | gressStart($max.=.0);....../**.. |
38a60 | 20 20 20 20 2a 20 41 64 76 61 6e 63 65 73 20 74 68 65 20 70 72 6f 67 72 65 73 73 20 6f 75 74 70 | ....*.Advances.the.progress.outp |
38a80 | 75 74 20 58 20 73 74 65 70 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d | ut.X.steps.......*......*.@param |
38aa0 | 20 69 6e 74 20 24 73 74 65 70 20 4e 75 6d 62 65 72 20 6f 66 20 73 74 65 70 73 20 74 6f 20 61 64 | .int.$step.Number.of.steps.to.ad |
38ac0 | 76 61 6e 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f | vance......*/.....public.functio |
38ae0 | 6e 20 70 72 6f 67 72 65 73 73 41 64 76 61 6e 63 65 28 24 73 74 65 70 20 3d 20 31 29 3b 0a 0a 20 | n.progressAdvance($step.=.1);... |
38b00 | 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 46 69 6e 69 73 68 65 73 20 74 68 65 20 70 72 6f 67 72 | .../**......*.Finishes.the.progr |
38b20 | 65 73 73 20 6f 75 74 70 75 74 2e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 | ess.output.......*/.....public.f |
38b40 | 75 6e 63 74 69 6f 6e 20 70 72 6f 67 72 65 73 73 46 69 6e 69 73 68 28 29 3b 0a 7d 0a 3c 3f 70 68 | unction.progressFinish();.}.<?ph |
38b60 | 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 | p../*..*.This.file.is.part.of.th |
38b80 | 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 | e.Symfony.package...*..*.(c).Fab |
38ba0 | 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f | ien.Potencier.<fabien@symfony.co |
38bc0 | 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 | m>..*..*.For.the.full.copyright. |
38be0 | 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 | and.license.information,.please. |
38c00 | 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 | view.the.LICENSE..*.file.that.wa |
38c20 | 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 | s.distributed.with.this.source.c |
38c40 | 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 | ode...*/..namespace.Symfony\Comp |
38c60 | 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 53 74 79 6c 65 3b 0a 0a 75 73 65 20 53 79 6d 66 6f 6e | onent\Console\Style;..use.Symfon |
38c80 | 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 41 70 70 6c 69 63 61 74 69 6f 6e 3b | y\Component\Console\Application; |
38ca0 | 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 | .use.Symfony\Component\Console\E |
38cc0 | 78 63 65 70 74 69 6f 6e 5c 52 75 6e 74 69 6d 65 45 78 63 65 70 74 69 6f 6e 3b 0a 75 73 65 20 53 | xception\RuntimeException;.use.S |
38ce0 | 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 46 6f 72 6d 61 74 74 | ymfony\Component\Console\Formatt |
38d00 | 65 72 5c 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c | er\OutputFormatter;.use.Symfony\ |
38d20 | 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 48 65 6c 70 65 72 5c 48 65 6c 70 65 72 3b | Component\Console\Helper\Helper; |
38d40 | 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 48 | .use.Symfony\Component\Console\H |
38d60 | 65 6c 70 65 72 5c 50 72 6f 67 72 65 73 73 42 61 72 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 | elper\ProgressBar;.use.Symfony\C |
38d80 | 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 48 65 6c 70 65 72 5c 53 79 6d 66 6f 6e 79 51 | omponent\Console\Helper\SymfonyQ |
38da0 | 75 65 73 74 69 6f 6e 48 65 6c 70 65 72 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f | uestionHelper;.use.Symfony\Compo |
38dc0 | 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 48 65 6c 70 65 72 5c 54 61 62 6c 65 3b 0a 75 73 65 20 53 | nent\Console\Helper\Table;.use.S |
38de0 | 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 5c 49 | ymfony\Component\Console\Input\I |
38e00 | 6e 70 75 74 49 6e 74 65 72 66 61 63 65 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f | nputInterface;.use.Symfony\Compo |
38e20 | 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 4f 75 74 70 75 74 5c 42 75 66 66 65 72 65 64 4f 75 74 70 | nent\Console\Output\BufferedOutp |
38e40 | 75 74 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c | ut;.use.Symfony\Component\Consol |
38e60 | 65 5c 4f 75 74 70 75 74 5c 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 3b 0a 75 73 65 20 53 79 | e\Output\OutputInterface;.use.Sy |
38e80 | 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 51 75 65 73 74 69 6f 6e | mfony\Component\Console\Question |
38ea0 | 5c 43 68 6f 69 63 65 51 75 65 73 74 69 6f 6e 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d | \ChoiceQuestion;.use.Symfony\Com |
38ec0 | 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 51 75 65 73 74 69 6f 6e 5c 43 6f 6e 66 69 72 6d 61 | ponent\Console\Question\Confirma |
38ee0 | 74 69 6f 6e 51 75 65 73 74 69 6f 6e 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e | tionQuestion;.use.Symfony\Compon |
38f00 | 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 51 75 65 73 74 69 6f 6e 5c 51 75 65 73 74 69 6f 6e 3b 0a 0a | ent\Console\Question\Question;.. |
38f20 | 2f 2a 2a 0a 20 2a 20 4f 75 74 70 75 74 20 64 65 63 6f 72 61 74 6f 72 20 68 65 6c 70 65 72 73 20 | /**..*.Output.decorator.helpers. |
38f40 | 66 6f 72 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 53 74 79 6c 65 20 47 75 69 64 65 2e 0a 20 2a 0a | for.the.Symfony.Style.Guide...*. |
38f60 | 20 2a 20 40 61 75 74 68 6f 72 20 4b 65 76 69 6e 20 42 6f 6e 64 20 3c 6b 65 76 69 6e 62 6f 6e 64 | .*.@author.Kevin.Bond.<kevinbond |
38f80 | 40 67 6d 61 69 6c 2e 63 6f 6d 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 53 79 6d 66 6f 6e 79 53 74 79 | @gmail.com>..*/.class.SymfonySty |
38fa0 | 6c 65 20 65 78 74 65 6e 64 73 20 4f 75 74 70 75 74 53 74 79 6c 65 0a 7b 0a 20 20 20 20 63 6f 6e | le.extends.OutputStyle.{.....con |
38fc0 | 73 74 20 4d 41 58 5f 4c 49 4e 45 5f 4c 45 4e 47 54 48 20 3d 20 31 32 30 3b 0a 0a 20 20 20 20 70 | st.MAX_LINE_LENGTH.=.120;......p |
38fe0 | 72 69 76 61 74 65 20 24 69 6e 70 75 74 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 71 75 65 73 | rivate.$input;.....private.$ques |
39000 | 74 69 6f 6e 48 65 6c 70 65 72 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 70 72 6f 67 72 65 73 | tionHelper;.....private.$progres |
39020 | 73 42 61 72 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 6c 69 6e 65 4c 65 6e 67 74 68 3b 0a 20 | sBar;.....private.$lineLength;.. |
39040 | 20 20 20 70 72 69 76 61 74 65 20 24 62 75 66 66 65 72 65 64 4f 75 74 70 75 74 3b 0a 0a 20 20 20 | ...private.$bufferedOutput;..... |
39060 | 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 49 6e 70 75 74 49 6e 74 65 72 66 61 63 | ./**......*.@param.InputInterfac |
39080 | 65 20 20 24 69 6e 70 75 74 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 4f 75 74 70 75 74 49 6e | e..$input......*.@param.OutputIn |
390a0 | 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c | terface.$output......*/.....publ |
390c0 | 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 74 28 49 6e 70 75 74 49 6e 74 | ic.function.__construct(InputInt |
390e0 | 65 72 66 61 63 65 20 24 69 6e 70 75 74 2c 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 | erface.$input,.OutputInterface.$ |
39100 | 6f 75 74 70 75 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 69 6e 70 | output).....{.........$this->inp |
39120 | 75 74 20 3d 20 24 69 6e 70 75 74 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 62 75 66 66 | ut.=.$input;.........$this->buff |
39140 | 65 72 65 64 4f 75 74 70 75 74 20 3d 20 6e 65 77 20 42 75 66 66 65 72 65 64 4f 75 74 70 75 74 28 | eredOutput.=.new.BufferedOutput( |
39160 | 24 6f 75 74 70 75 74 2d 3e 67 65 74 56 65 72 62 6f 73 69 74 79 28 29 2c 20 66 61 6c 73 65 2c 20 | $output->getVerbosity(),.false,. |
39180 | 63 6c 6f 6e 65 20 24 6f 75 74 70 75 74 2d 3e 67 65 74 46 6f 72 6d 61 74 74 65 72 28 29 29 3b 0a | clone.$output->getFormatter());. |
391a0 | 20 20 20 20 20 20 20 20 2f 2f 20 57 69 6e 64 6f 77 73 20 63 6d 64 20 77 72 61 70 73 20 6c 69 6e | ........//.Windows.cmd.wraps.lin |
391c0 | 65 73 20 61 73 20 73 6f 6f 6e 20 61 73 20 74 68 65 20 74 65 72 6d 69 6e 61 6c 20 77 69 64 74 68 | es.as.soon.as.the.terminal.width |
391e0 | 20 69 73 20 72 65 61 63 68 65 64 2c 20 77 68 65 74 68 65 72 20 74 68 65 72 65 20 61 72 65 20 66 | .is.reached,.whether.there.are.f |
39200 | 6f 6c 6c 6f 77 69 6e 67 20 63 68 61 72 73 20 6f 72 20 6e 6f 74 2e 0a 20 20 20 20 20 20 20 20 24 | ollowing.chars.or.not..........$ |
39220 | 74 68 69 73 2d 3e 6c 69 6e 65 4c 65 6e 67 74 68 20 3d 20 6d 69 6e 28 24 74 68 69 73 2d 3e 67 65 | this->lineLength.=.min($this->ge |
39240 | 74 54 65 72 6d 69 6e 61 6c 57 69 64 74 68 28 29 20 2d 20 28 69 6e 74 29 20 28 44 49 52 45 43 54 | tTerminalWidth().-.(int).(DIRECT |
39260 | 4f 52 59 5f 53 45 50 41 52 41 54 4f 52 20 3d 3d 3d 20 27 5c 5c 27 29 2c 20 73 65 6c 66 3a 3a 4d | ORY_SEPARATOR.===.'\\'),.self::M |
39280 | 41 58 5f 4c 49 4e 45 5f 4c 45 4e 47 54 48 29 3b 0a 0a 20 20 20 20 20 20 20 20 70 61 72 65 6e 74 | AX_LINE_LENGTH);..........parent |
392a0 | 3a 3a 5f 5f 63 6f 6e 73 74 72 75 63 74 28 24 6f 75 74 70 75 74 29 3b 0a 20 20 20 20 7d 0a 0a 20 | ::__construct($output);.....}... |
392c0 | 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 46 6f 72 6d 61 74 73 20 61 20 6d 65 73 73 61 67 65 20 | .../**......*.Formats.a.message. |
392e0 | 61 73 20 61 20 62 6c 6f 63 6b 20 6f 66 20 74 65 78 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 | as.a.block.of.text.......*...... |
39300 | 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 7c 61 72 72 61 79 20 24 6d 65 73 73 61 67 65 73 20 | *.@param.string|array.$messages. |
39320 | 54 68 65 20 6d 65 73 73 61 67 65 20 74 6f 20 77 72 69 74 65 20 69 6e 20 74 68 65 20 62 6c 6f 63 | The.message.to.write.in.the.bloc |
39340 | 6b 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 7c 6e 75 6c 6c 20 20 24 74 79 | k......*.@param.string|null..$ty |
39360 | 70 65 20 20 20 20 20 54 68 65 20 62 6c 6f 63 6b 20 74 79 70 65 20 28 61 64 64 65 64 20 69 6e 20 | pe.....The.block.type.(added.in. |
39380 | 5b 5d 20 6f 6e 20 66 69 72 73 74 20 6c 69 6e 65 29 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 | [].on.first.line)......*.@param. |
393a0 | 73 74 72 69 6e 67 7c 6e 75 6c 6c 20 20 24 73 74 79 6c 65 20 20 20 20 54 68 65 20 73 74 79 6c 65 | string|null..$style....The.style |
393c0 | 20 74 6f 20 61 70 70 6c 79 20 74 6f 20 74 68 65 20 77 68 6f 6c 65 20 62 6c 6f 63 6b 0a 20 20 20 | .to.apply.to.the.whole.block.... |
393e0 | 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 20 20 20 20 20 20 24 70 72 65 66 69 78 20 | ..*.@param.string.......$prefix. |
39400 | 20 20 54 68 65 20 70 72 65 66 69 78 20 66 6f 72 20 74 68 65 20 62 6c 6f 63 6b 0a 20 20 20 20 20 | ..The.prefix.for.the.block...... |
39420 | 2a 20 40 70 61 72 61 6d 20 62 6f 6f 6c 20 20 20 20 20 20 20 20 20 24 70 61 64 64 69 6e 67 20 20 | *.@param.bool.........$padding.. |
39440 | 57 68 65 74 68 65 72 20 74 6f 20 61 64 64 20 76 65 72 74 69 63 61 6c 20 70 61 64 64 69 6e 67 0a | Whether.to.add.vertical.padding. |
39460 | 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 62 6c 6f 63 | .....*/.....public.function.bloc |
39480 | 6b 28 24 6d 65 73 73 61 67 65 73 2c 20 24 74 79 70 65 20 3d 20 6e 75 6c 6c 2c 20 24 73 74 79 6c | k($messages,.$type.=.null,.$styl |
394a0 | 65 20 3d 20 6e 75 6c 6c 2c 20 24 70 72 65 66 69 78 20 3d 20 27 20 27 2c 20 24 70 61 64 64 69 6e | e.=.null,.$prefix.=.'.',.$paddin |
394c0 | 67 20 3d 20 66 61 6c 73 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 | g.=.false).....{.........$messag |
394e0 | 65 73 20 3d 20 69 73 5f 61 72 72 61 79 28 24 6d 65 73 73 61 67 65 73 29 20 3f 20 61 72 72 61 79 | es.=.is_array($messages).?.array |
39500 | 5f 76 61 6c 75 65 73 28 24 6d 65 73 73 61 67 65 73 29 20 3a 20 61 72 72 61 79 28 24 6d 65 73 73 | _values($messages).:.array($mess |
39520 | 61 67 65 73 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 61 75 74 6f 50 72 65 70 65 | ages);..........$this->autoPrepe |
39540 | 6e 64 42 6c 6f 63 6b 28 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 6c | ndBlock();.........$this->writel |
39560 | 6e 28 24 74 68 69 73 2d 3e 63 72 65 61 74 65 42 6c 6f 63 6b 28 24 6d 65 73 73 61 67 65 73 2c 20 | n($this->createBlock($messages,. |
39580 | 24 74 79 70 65 2c 20 24 73 74 79 6c 65 2c 20 24 70 72 65 66 69 78 2c 20 24 70 61 64 64 69 6e 67 | $type,.$style,.$prefix,.$padding |
395a0 | 2c 20 74 72 75 65 29 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6e 65 77 4c 69 6e 65 | ,.true));.........$this->newLine |
395c0 | 28 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 | ();.....}....../**......*.{@inhe |
395e0 | 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 | ritdoc}......*/.....public.funct |
39600 | 69 6f 6e 20 74 69 74 6c 65 28 24 6d 65 73 73 61 67 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 | ion.title($message).....{....... |
39620 | 20 20 24 74 68 69 73 2d 3e 61 75 74 6f 50 72 65 70 65 6e 64 42 6c 6f 63 6b 28 29 3b 0a 20 20 20 | ..$this->autoPrependBlock();.... |
39640 | 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 6c 6e 28 61 72 72 61 79 28 0a 20 20 20 20 20 | .....$this->writeln(array(...... |
39660 | 20 20 20 20 20 20 20 73 70 72 69 6e 74 66 28 27 3c 63 6f 6d 6d 65 6e 74 3e 25 73 3c 2f 3e 27 2c | .......sprintf('<comment>%s</>', |
39680 | 20 24 6d 65 73 73 61 67 65 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 73 70 72 69 6e 74 66 28 | .$message),.............sprintf( |
396a0 | 27 3c 63 6f 6d 6d 65 6e 74 3e 25 73 3c 2f 3e 27 2c 20 73 74 72 5f 72 65 70 65 61 74 28 27 3d 27 | '<comment>%s</>',.str_repeat('=' |
396c0 | 2c 20 48 65 6c 70 65 72 3a 3a 73 74 72 6c 65 6e 57 69 74 68 6f 75 74 44 65 63 6f 72 61 74 69 6f | ,.Helper::strlenWithoutDecoratio |
396e0 | 6e 28 24 74 68 69 73 2d 3e 67 65 74 46 6f 72 6d 61 74 74 65 72 28 29 2c 20 24 6d 65 73 73 61 67 | n($this->getFormatter(),.$messag |
39700 | 65 29 29 29 2c 0a 20 20 20 20 20 20 20 20 29 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d | e))),.........));.........$this- |
39720 | 3e 6e 65 77 4c 69 6e 65 28 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 | >newLine();.....}....../**...... |
39740 | 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c | *.{@inheritdoc}......*/.....publ |
39760 | 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 63 74 69 6f 6e 28 24 6d 65 73 73 61 67 65 29 0a 20 20 | ic.function.section($message)... |
39780 | 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 61 75 74 6f 50 72 65 70 65 6e 64 42 6c | ..{.........$this->autoPrependBl |
397a0 | 6f 63 6b 28 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 6c 6e 28 61 72 | ock();.........$this->writeln(ar |
397c0 | 72 61 79 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 73 70 72 69 6e 74 66 28 27 3c 63 6f 6d 6d 65 | ray(.............sprintf('<comme |
397e0 | 6e 74 3e 25 73 3c 2f 3e 27 2c 20 24 6d 65 73 73 61 67 65 29 2c 0a 20 20 20 20 20 20 20 20 20 20 | nt>%s</>',.$message),........... |
39800 | 20 20 73 70 72 69 6e 74 66 28 27 3c 63 6f 6d 6d 65 6e 74 3e 25 73 3c 2f 3e 27 2c 20 73 74 72 5f | ..sprintf('<comment>%s</>',.str_ |
39820 | 72 65 70 65 61 74 28 27 2d 27 2c 20 48 65 6c 70 65 72 3a 3a 73 74 72 6c 65 6e 57 69 74 68 6f 75 | repeat('-',.Helper::strlenWithou |
39840 | 74 44 65 63 6f 72 61 74 69 6f 6e 28 24 74 68 69 73 2d 3e 67 65 74 46 6f 72 6d 61 74 74 65 72 28 | tDecoration($this->getFormatter( |
39860 | 29 2c 20 24 6d 65 73 73 61 67 65 29 29 29 2c 0a 20 20 20 20 20 20 20 20 29 29 3b 0a 20 20 20 20 | ),.$message))),.........));..... |
39880 | 20 20 20 20 24 74 68 69 73 2d 3e 6e 65 77 4c 69 6e 65 28 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 | ....$this->newLine();.....}..... |
398a0 | 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a | ./**......*.{@inheritdoc}......* |
398c0 | 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 6c 69 73 74 69 6e 67 28 61 72 | /.....public.function.listing(ar |
398e0 | 72 61 79 20 24 65 6c 65 6d 65 6e 74 73 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 | ray.$elements).....{.........$th |
39900 | 69 73 2d 3e 61 75 74 6f 50 72 65 70 65 6e 64 54 65 78 74 28 29 3b 0a 20 20 20 20 20 20 20 20 24 | is->autoPrependText();.........$ |
39920 | 65 6c 65 6d 65 6e 74 73 20 3d 20 61 72 72 61 79 5f 6d 61 70 28 66 75 6e 63 74 69 6f 6e 20 28 24 | elements.=.array_map(function.($ |
39940 | 65 6c 65 6d 65 6e 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 70 | element).{.............return.sp |
39960 | 72 69 6e 74 66 28 27 20 2a 20 25 73 27 2c 20 24 65 6c 65 6d 65 6e 74 29 3b 0a 20 20 20 20 20 20 | rintf('.*.%s',.$element);....... |
39980 | 20 20 7d 2c 20 24 65 6c 65 6d 65 6e 74 73 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d | ..},.$elements);..........$this- |
399a0 | 3e 77 72 69 74 65 6c 6e 28 24 65 6c 65 6d 65 6e 74 73 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 | >writeln($elements);.........$th |
399c0 | 69 73 2d 3e 6e 65 77 4c 69 6e 65 28 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 | is->newLine();.....}....../**... |
399e0 | 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 | ...*.{@inheritdoc}......*/.....p |
39a00 | 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 74 65 78 74 28 24 6d 65 73 73 61 67 65 29 0a 20 20 | ublic.function.text($message)... |
39a20 | 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 61 75 74 6f 50 72 65 70 65 6e 64 54 65 | ..{.........$this->autoPrependTe |
39a40 | 78 74 28 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 73 20 3d 20 69 73 5f 61 72 | xt();..........$messages.=.is_ar |
39a60 | 72 61 79 28 24 6d 65 73 73 61 67 65 29 20 3f 20 61 72 72 61 79 5f 76 61 6c 75 65 73 28 24 6d 65 | ray($message).?.array_values($me |
39a80 | 73 73 61 67 65 29 20 3a 20 61 72 72 61 79 28 24 6d 65 73 73 61 67 65 29 3b 0a 20 20 20 20 20 20 | ssage).:.array($message);....... |
39aa0 | 20 20 66 6f 72 65 61 63 68 20 28 24 6d 65 73 73 61 67 65 73 20 61 73 20 24 6d 65 73 73 61 67 65 | ..foreach.($messages.as.$message |
39ac0 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 6c 6e 28 73 | ).{.............$this->writeln(s |
39ae0 | 70 72 69 6e 74 66 28 27 20 25 73 27 2c 20 24 6d 65 73 73 61 67 65 29 29 3b 0a 20 20 20 20 20 20 | printf('.%s',.$message));....... |
39b00 | 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 46 6f 72 6d 61 74 | ..}.....}....../**......*.Format |
39b20 | 73 20 61 20 63 6f 6d 6d 61 6e 64 20 63 6f 6d 6d 65 6e 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 | s.a.command.comment.......*..... |
39b40 | 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 7c 61 72 72 61 79 20 24 6d 65 73 73 61 67 65 0a | .*.@param.string|array.$message. |
39b60 | 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 63 6f 6d 6d | .....*/.....public.function.comm |
39b80 | 65 6e 74 28 24 6d 65 73 73 61 67 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 6d 65 73 | ent($message).....{.........$mes |
39ba0 | 73 61 67 65 73 20 3d 20 69 73 5f 61 72 72 61 79 28 24 6d 65 73 73 61 67 65 29 20 3f 20 61 72 72 | sages.=.is_array($message).?.arr |
39bc0 | 61 79 5f 76 61 6c 75 65 73 28 24 6d 65 73 73 61 67 65 29 20 3a 20 61 72 72 61 79 28 24 6d 65 73 | ay_values($message).:.array($mes |
39be0 | 73 61 67 65 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 61 75 74 6f 50 72 65 70 65 | sage);..........$this->autoPrepe |
39c00 | 6e 64 42 6c 6f 63 6b 28 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 6c | ndBlock();.........$this->writel |
39c20 | 6e 28 24 74 68 69 73 2d 3e 63 72 65 61 74 65 42 6c 6f 63 6b 28 24 6d 65 73 73 61 67 65 73 2c 20 | n($this->createBlock($messages,. |
39c40 | 6e 75 6c 6c 2c 20 6e 75 6c 6c 2c 20 27 3c 66 67 3d 64 65 66 61 75 6c 74 3b 62 67 3d 64 65 66 61 | null,.null,.'<fg=default;bg=defa |
39c60 | 75 6c 74 3e 20 2f 2f 20 3c 2f 3e 27 29 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6e | ult>.//.</>'));.........$this->n |
39c80 | 65 77 4c 69 6e 65 28 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 | ewLine();.....}....../**......*. |
39ca0 | 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 | {@inheritdoc}......*/.....public |
39cc0 | 20 66 75 6e 63 74 69 6f 6e 20 73 75 63 63 65 73 73 28 24 6d 65 73 73 61 67 65 29 0a 20 20 20 20 | .function.success($message)..... |
39ce0 | 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 62 6c 6f 63 6b 28 24 6d 65 73 73 61 67 65 2c | {.........$this->block($message, |
39d00 | 20 27 4f 4b 27 2c 20 27 66 67 3d 62 6c 61 63 6b 3b 62 67 3d 67 72 65 65 6e 27 2c 20 27 20 27 2c | .'OK',.'fg=black;bg=green',.'.', |
39d20 | 20 74 72 75 65 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 | .true);.....}....../**......*.{@ |
39d40 | 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 | inheritdoc}......*/.....public.f |
39d60 | 75 6e 63 74 69 6f 6e 20 65 72 72 6f 72 28 24 6d 65 73 73 61 67 65 29 0a 20 20 20 20 7b 0a 20 20 | unction.error($message).....{... |
39d80 | 20 20 20 20 20 20 24 74 68 69 73 2d 3e 62 6c 6f 63 6b 28 24 6d 65 73 73 61 67 65 2c 20 27 45 52 | ......$this->block($message,.'ER |
39da0 | 52 4f 52 27 2c 20 27 66 67 3d 77 68 69 74 65 3b 62 67 3d 72 65 64 27 2c 20 27 20 27 2c 20 74 72 | ROR',.'fg=white;bg=red',.'.',.tr |
39dc0 | 75 65 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 | ue);.....}....../**......*.{@inh |
39de0 | 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 | eritdoc}......*/.....public.func |
39e00 | 74 69 6f 6e 20 77 61 72 6e 69 6e 67 28 24 6d 65 73 73 61 67 65 29 0a 20 20 20 20 7b 0a 20 20 20 | tion.warning($message).....{.... |
39e20 | 20 20 20 20 20 24 74 68 69 73 2d 3e 62 6c 6f 63 6b 28 24 6d 65 73 73 61 67 65 2c 20 27 57 41 52 | .....$this->block($message,.'WAR |
39e40 | 4e 49 4e 47 27 2c 20 27 66 67 3d 77 68 69 74 65 3b 62 67 3d 72 65 64 27 2c 20 27 20 27 2c 20 74 | NING',.'fg=white;bg=red',.'.',.t |
39e60 | 72 75 65 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e | rue);.....}....../**......*.{@in |
39e80 | 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e | heritdoc}......*/.....public.fun |
39ea0 | 63 74 69 6f 6e 20 6e 6f 74 65 28 24 6d 65 73 73 61 67 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 | ction.note($message).....{...... |
39ec0 | 20 20 20 24 74 68 69 73 2d 3e 62 6c 6f 63 6b 28 24 6d 65 73 73 61 67 65 2c 20 27 4e 4f 54 45 27 | ...$this->block($message,.'NOTE' |
39ee0 | 2c 20 27 66 67 3d 79 65 6c 6c 6f 77 27 2c 20 27 20 21 20 27 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 | ,.'fg=yellow',.'.!.');.....}.... |
39f00 | 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 | ../**......*.{@inheritdoc}...... |
39f20 | 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 63 61 75 74 69 6f 6e 28 24 | */.....public.function.caution($ |
39f40 | 6d 65 73 73 61 67 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 62 6c | message).....{.........$this->bl |
39f60 | 6f 63 6b 28 24 6d 65 73 73 61 67 65 2c 20 27 43 41 55 54 49 4f 4e 27 2c 20 27 66 67 3d 77 68 69 | ock($message,.'CAUTION',.'fg=whi |
39f80 | 74 65 3b 62 67 3d 72 65 64 27 2c 20 27 20 21 20 27 2c 20 74 72 75 65 29 3b 0a 20 20 20 20 7d 0a | te;bg=red',.'.!.',.true);.....}. |
39fa0 | 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 | ...../**......*.{@inheritdoc}... |
39fc0 | 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 74 61 62 6c 65 28 | ...*/.....public.function.table( |
39fe0 | 61 72 72 61 79 20 24 68 65 61 64 65 72 73 2c 20 61 72 72 61 79 20 24 72 6f 77 73 29 0a 20 20 20 | array.$headers,.array.$rows).... |
3a000 | 20 7b 0a 20 20 20 20 20 20 20 20 24 73 74 79 6c 65 20 3d 20 63 6c 6f 6e 65 20 54 61 62 6c 65 3a | .{.........$style.=.clone.Table: |
3a020 | 3a 67 65 74 53 74 79 6c 65 44 65 66 69 6e 69 74 69 6f 6e 28 27 73 79 6d 66 6f 6e 79 2d 73 74 79 | :getStyleDefinition('symfony-sty |
3a040 | 6c 65 2d 67 75 69 64 65 27 29 3b 0a 20 20 20 20 20 20 20 20 24 73 74 79 6c 65 2d 3e 73 65 74 43 | le-guide');.........$style->setC |
3a060 | 65 6c 6c 48 65 61 64 65 72 46 6f 72 6d 61 74 28 27 3c 69 6e 66 6f 3e 25 73 3c 2f 69 6e 66 6f 3e | ellHeaderFormat('<info>%s</info> |
3a080 | 27 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 74 61 62 6c 65 20 3d 20 6e 65 77 20 54 61 62 6c 65 28 | ');..........$table.=.new.Table( |
3a0a0 | 24 74 68 69 73 29 3b 0a 20 20 20 20 20 20 20 20 24 74 61 62 6c 65 2d 3e 73 65 74 48 65 61 64 65 | $this);.........$table->setHeade |
3a0c0 | 72 73 28 24 68 65 61 64 65 72 73 29 3b 0a 20 20 20 20 20 20 20 20 24 74 61 62 6c 65 2d 3e 73 65 | rs($headers);.........$table->se |
3a0e0 | 74 52 6f 77 73 28 24 72 6f 77 73 29 3b 0a 20 20 20 20 20 20 20 20 24 74 61 62 6c 65 2d 3e 73 65 | tRows($rows);.........$table->se |
3a100 | 74 53 74 79 6c 65 28 24 73 74 79 6c 65 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 74 61 62 6c 65 2d | tStyle($style);..........$table- |
3a120 | 3e 72 65 6e 64 65 72 28 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6e 65 77 4c 69 6e | >render();.........$this->newLin |
3a140 | 65 28 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 | e();.....}....../**......*.{@inh |
3a160 | 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 | eritdoc}......*/.....public.func |
3a180 | 74 69 6f 6e 20 61 73 6b 28 24 71 75 65 73 74 69 6f 6e 2c 20 24 64 65 66 61 75 6c 74 20 3d 20 6e | tion.ask($question,.$default.=.n |
3a1a0 | 75 6c 6c 2c 20 24 76 61 6c 69 64 61 74 6f 72 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 | ull,.$validator.=.null).....{... |
3a1c0 | 20 20 20 20 20 20 24 71 75 65 73 74 69 6f 6e 20 3d 20 6e 65 77 20 51 75 65 73 74 69 6f 6e 28 24 | ......$question.=.new.Question($ |
3a1e0 | 71 75 65 73 74 69 6f 6e 2c 20 24 64 65 66 61 75 6c 74 29 3b 0a 20 20 20 20 20 20 20 20 24 71 75 | question,.$default);.........$qu |
3a200 | 65 73 74 69 6f 6e 2d 3e 73 65 74 56 61 6c 69 64 61 74 6f 72 28 24 76 61 6c 69 64 61 74 6f 72 29 | estion->setValidator($validator) |
3a220 | 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 61 73 6b 51 75 65 73 | ;..........return.$this->askQues |
3a240 | 74 69 6f 6e 28 24 71 75 65 73 74 69 6f 6e 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a | tion($question);.....}....../**. |
3a260 | 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 | .....*.{@inheritdoc}......*/.... |
3a280 | 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 61 73 6b 48 69 64 64 65 6e 28 24 71 75 65 73 | .public.function.askHidden($ques |
3a2a0 | 74 69 6f 6e 2c 20 24 76 61 6c 69 64 61 74 6f 72 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 | tion,.$validator.=.null).....{.. |
3a2c0 | 20 20 20 20 20 20 20 24 71 75 65 73 74 69 6f 6e 20 3d 20 6e 65 77 20 51 75 65 73 74 69 6f 6e 28 | .......$question.=.new.Question( |
3a2e0 | 24 71 75 65 73 74 69 6f 6e 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 71 75 65 73 74 69 6f 6e 2d 3e | $question);..........$question-> |
3a300 | 73 65 74 48 69 64 64 65 6e 28 74 72 75 65 29 3b 0a 20 20 20 20 20 20 20 20 24 71 75 65 73 74 69 | setHidden(true);.........$questi |
3a320 | 6f 6e 2d 3e 73 65 74 56 61 6c 69 64 61 74 6f 72 28 24 76 61 6c 69 64 61 74 6f 72 29 3b 0a 0a 20 | on->setValidator($validator);... |
3a340 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 61 73 6b 51 75 65 73 74 69 6f 6e | .......return.$this->askQuestion |
3a360 | 28 24 71 75 65 73 74 69 6f 6e 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 | ($question);.....}....../**..... |
3a380 | 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 | .*.{@inheritdoc}......*/.....pub |
3a3a0 | 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 63 6f 6e 66 69 72 6d 28 24 71 75 65 73 74 69 6f 6e 2c 20 | lic.function.confirm($question,. |
3a3c0 | 24 64 65 66 61 75 6c 74 20 3d 20 74 72 75 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 | $default.=.true).....{.........r |
3a3e0 | 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 61 73 6b 51 75 65 73 74 69 6f 6e 28 6e 65 77 20 43 6f 6e | eturn.$this->askQuestion(new.Con |
3a400 | 66 69 72 6d 61 74 69 6f 6e 51 75 65 73 74 69 6f 6e 28 24 71 75 65 73 74 69 6f 6e 2c 20 24 64 65 | firmationQuestion($question,.$de |
3a420 | 66 61 75 6c 74 29 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b | fault));.....}....../**......*.{ |
3a440 | 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 | @inheritdoc}......*/.....public. |
3a460 | 66 75 6e 63 74 69 6f 6e 20 63 68 6f 69 63 65 28 24 71 75 65 73 74 69 6f 6e 2c 20 61 72 72 61 79 | function.choice($question,.array |
3a480 | 20 24 63 68 6f 69 63 65 73 2c 20 24 64 65 66 61 75 6c 74 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 | .$choices,.$default.=.null)..... |
3a4a0 | 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 21 3d 3d 20 24 64 65 66 61 75 6c 74 29 | {.........if.(null.!==.$default) |
3a4c0 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 76 61 6c 75 65 73 20 3d 20 61 72 72 61 79 5f 66 | .{.............$values.=.array_f |
3a4e0 | 6c 69 70 28 24 63 68 6f 69 63 65 73 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 64 65 66 61 | lip($choices);.............$defa |
3a500 | 75 6c 74 20 3d 20 24 76 61 6c 75 65 73 5b 24 64 65 66 61 75 6c 74 5d 3b 0a 20 20 20 20 20 20 20 | ult.=.$values[$default];........ |
3a520 | 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 61 73 6b 51 75 65 | .}..........return.$this->askQue |
3a540 | 73 74 69 6f 6e 28 6e 65 77 20 43 68 6f 69 63 65 51 75 65 73 74 69 6f 6e 28 24 71 75 65 73 74 69 | stion(new.ChoiceQuestion($questi |
3a560 | 6f 6e 2c 20 24 63 68 6f 69 63 65 73 2c 20 24 64 65 66 61 75 6c 74 29 29 3b 0a 20 20 20 20 7d 0a | on,.$choices,.$default));.....}. |
3a580 | 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 | ...../**......*.{@inheritdoc}... |
3a5a0 | 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 70 72 6f 67 72 65 | ...*/.....public.function.progre |
3a5c0 | 73 73 53 74 61 72 74 28 24 6d 61 78 20 3d 20 30 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | ssStart($max.=.0).....{......... |
3a5e0 | 24 74 68 69 73 2d 3e 70 72 6f 67 72 65 73 73 42 61 72 20 3d 20 24 74 68 69 73 2d 3e 63 72 65 61 | $this->progressBar.=.$this->crea |
3a600 | 74 65 50 72 6f 67 72 65 73 73 42 61 72 28 24 6d 61 78 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 | teProgressBar($max);.........$th |
3a620 | 69 73 2d 3e 70 72 6f 67 72 65 73 73 42 61 72 2d 3e 73 74 61 72 74 28 29 3b 0a 20 20 20 20 7d 0a | is->progressBar->start();.....}. |
3a640 | 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 | ...../**......*.{@inheritdoc}... |
3a660 | 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 70 72 6f 67 72 65 | ...*/.....public.function.progre |
3a680 | 73 73 41 64 76 61 6e 63 65 28 24 73 74 65 70 20 3d 20 31 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 | ssAdvance($step.=.1).....{...... |
3a6a0 | 20 20 20 24 74 68 69 73 2d 3e 67 65 74 50 72 6f 67 72 65 73 73 42 61 72 28 29 2d 3e 61 64 76 61 | ...$this->getProgressBar()->adva |
3a6c0 | 6e 63 65 28 24 73 74 65 70 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 | nce($step);.....}....../**...... |
3a6e0 | 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c | *.{@inheritdoc}......*/.....publ |
3a700 | 69 63 20 66 75 6e 63 74 69 6f 6e 20 70 72 6f 67 72 65 73 73 46 69 6e 69 73 68 28 29 0a 20 20 20 | ic.function.progressFinish().... |
3a720 | 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 67 65 74 50 72 6f 67 72 65 73 73 42 61 72 | .{.........$this->getProgressBar |
3a740 | 28 29 2d 3e 66 69 6e 69 73 68 28 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6e 65 77 | ()->finish();.........$this->new |
3a760 | 4c 69 6e 65 28 32 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 70 72 6f 67 72 65 73 73 | Line(2);.........$this->progress |
3a780 | 42 61 72 20 3d 20 6e 75 6c 6c 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 | Bar.=.null;.....}....../**...... |
3a7a0 | 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c | *.{@inheritdoc}......*/.....publ |
3a7c0 | 69 63 20 66 75 6e 63 74 69 6f 6e 20 63 72 65 61 74 65 50 72 6f 67 72 65 73 73 42 61 72 28 24 6d | ic.function.createProgressBar($m |
3a7e0 | 61 78 20 3d 20 30 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 70 72 6f 67 72 65 73 73 42 | ax.=.0).....{.........$progressB |
3a800 | 61 72 20 3d 20 70 61 72 65 6e 74 3a 3a 63 72 65 61 74 65 50 72 6f 67 72 65 73 73 42 61 72 28 24 | ar.=.parent::createProgressBar($ |
3a820 | 6d 61 78 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 27 5c 5c 27 20 21 3d 3d 20 44 49 52 45 | max);..........if.('\\'.!==.DIRE |
3a840 | 43 54 4f 52 59 5f 53 45 50 41 52 41 54 4f 52 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 | CTORY_SEPARATOR).{.............$ |
3a860 | 70 72 6f 67 72 65 73 73 42 61 72 2d 3e 73 65 74 45 6d 70 74 79 42 61 72 43 68 61 72 61 63 74 65 | progressBar->setEmptyBarCharacte |
3a880 | 72 28 27 e2 96 91 27 29 3b 20 2f 2f 20 6c 69 67 68 74 20 73 68 61 64 65 20 63 68 61 72 61 63 74 | r('...');.//.light.shade.charact |
3a8a0 | 65 72 20 5c 75 32 35 39 31 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 70 72 6f 67 72 65 73 73 42 | er.\u2591.............$progressB |
3a8c0 | 61 72 2d 3e 73 65 74 50 72 6f 67 72 65 73 73 43 68 61 72 61 63 74 65 72 28 27 27 29 3b 0a 20 20 | ar->setProgressCharacter('');... |
3a8e0 | 20 20 20 20 20 20 20 20 20 20 24 70 72 6f 67 72 65 73 73 42 61 72 2d 3e 73 65 74 42 61 72 43 68 | ..........$progressBar->setBarCh |
3a900 | 61 72 61 63 74 65 72 28 27 e2 96 93 27 29 3b 20 2f 2f 20 64 61 72 6b 20 73 68 61 64 65 20 63 68 | aracter('...');.//.dark.shade.ch |
3a920 | 61 72 61 63 74 65 72 20 5c 75 32 35 39 33 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 | aracter.\u2593.........}........ |
3a940 | 20 20 72 65 74 75 72 6e 20 24 70 72 6f 67 72 65 73 73 42 61 72 3b 0a 20 20 20 20 7d 0a 0a 20 20 | ..return.$progressBar;.....}.... |
3a960 | 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 51 75 65 73 74 69 6f 6e 20 24 71 75 | ../**......*.@param.Question.$qu |
3a980 | 65 73 74 69 6f 6e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 | estion......*......*.@return.str |
3a9a0 | 69 6e 67 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 | ing......*/.....public.function. |
3a9c0 | 61 73 6b 51 75 65 73 74 69 6f 6e 28 51 75 65 73 74 69 6f 6e 20 24 71 75 65 73 74 69 6f 6e 29 0a | askQuestion(Question.$question). |
3a9e0 | 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 74 68 69 73 2d 3e 69 6e 70 75 74 2d 3e | ....{.........if.($this->input-> |
3aa00 | 69 73 49 6e 74 65 72 61 63 74 69 76 65 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 | isInteractive()).{.............$ |
3aa20 | 74 68 69 73 2d 3e 61 75 74 6f 50 72 65 70 65 6e 64 42 6c 6f 63 6b 28 29 3b 0a 20 20 20 20 20 20 | this->autoPrependBlock();....... |
3aa40 | 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 24 74 68 69 73 2d 3e 71 75 65 73 74 69 6f | ..}..........if.(!$this->questio |
3aa60 | 6e 48 65 6c 70 65 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 71 75 | nHelper).{.............$this->qu |
3aa80 | 65 73 74 69 6f 6e 48 65 6c 70 65 72 20 3d 20 6e 65 77 20 53 79 6d 66 6f 6e 79 51 75 65 73 74 69 | estionHelper.=.new.SymfonyQuesti |
3aaa0 | 6f 6e 48 65 6c 70 65 72 28 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 | onHelper();.........}..........$ |
3aac0 | 61 6e 73 77 65 72 20 3d 20 24 74 68 69 73 2d 3e 71 75 65 73 74 69 6f 6e 48 65 6c 70 65 72 2d 3e | answer.=.$this->questionHelper-> |
3aae0 | 61 73 6b 28 24 74 68 69 73 2d 3e 69 6e 70 75 74 2c 20 24 74 68 69 73 2c 20 24 71 75 65 73 74 69 | ask($this->input,.$this,.$questi |
3ab00 | 6f 6e 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 74 68 69 73 2d 3e 69 6e 70 75 74 2d 3e | on);..........if.($this->input-> |
3ab20 | 69 73 49 6e 74 65 72 61 63 74 69 76 65 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 | isInteractive()).{.............$ |
3ab40 | 74 68 69 73 2d 3e 6e 65 77 4c 69 6e 65 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 | this->newLine();.............$th |
3ab60 | 69 73 2d 3e 62 75 66 66 65 72 65 64 4f 75 74 70 75 74 2d 3e 77 72 69 74 65 28 22 5c 6e 22 29 3b | is->bufferedOutput->write("\n"); |
3ab80 | 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 61 6e 73 77 | .........}..........return.$answ |
3aba0 | 65 72 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 | er;.....}....../**......*.{@inhe |
3abc0 | 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 | ritdoc}......*/.....public.funct |
3abe0 | 69 6f 6e 20 77 72 69 74 65 6c 6e 28 24 6d 65 73 73 61 67 65 73 2c 20 24 74 79 70 65 20 3d 20 73 | ion.writeln($messages,.$type.=.s |
3ac00 | 65 6c 66 3a 3a 4f 55 54 50 55 54 5f 4e 4f 52 4d 41 4c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 | elf::OUTPUT_NORMAL).....{....... |
3ac20 | 20 20 70 61 72 65 6e 74 3a 3a 77 72 69 74 65 6c 6e 28 24 6d 65 73 73 61 67 65 73 2c 20 24 74 79 | ..parent::writeln($messages,.$ty |
3ac40 | 70 65 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 62 75 66 66 65 72 65 64 4f 75 74 70 | pe);.........$this->bufferedOutp |
3ac60 | 75 74 2d 3e 77 72 69 74 65 6c 6e 28 24 74 68 69 73 2d 3e 72 65 64 75 63 65 42 75 66 66 65 72 28 | ut->writeln($this->reduceBuffer( |
3ac80 | 24 6d 65 73 73 61 67 65 73 29 2c 20 24 74 79 70 65 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f | $messages),.$type);.....}....../ |
3aca0 | 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a | **......*.{@inheritdoc}......*/. |
3acc0 | 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 77 72 69 74 65 28 24 6d 65 73 73 61 | ....public.function.write($messa |
3ace0 | 67 65 73 2c 20 24 6e 65 77 6c 69 6e 65 20 3d 20 66 61 6c 73 65 2c 20 24 74 79 70 65 20 3d 20 73 | ges,.$newline.=.false,.$type.=.s |
3ad00 | 65 6c 66 3a 3a 4f 55 54 50 55 54 5f 4e 4f 52 4d 41 4c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 | elf::OUTPUT_NORMAL).....{....... |
3ad20 | 20 20 70 61 72 65 6e 74 3a 3a 77 72 69 74 65 28 24 6d 65 73 73 61 67 65 73 2c 20 24 6e 65 77 6c | ..parent::write($messages,.$newl |
3ad40 | 69 6e 65 2c 20 24 74 79 70 65 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 62 75 66 66 | ine,.$type);.........$this->buff |
3ad60 | 65 72 65 64 4f 75 74 70 75 74 2d 3e 77 72 69 74 65 28 24 74 68 69 73 2d 3e 72 65 64 75 63 65 42 | eredOutput->write($this->reduceB |
3ad80 | 75 66 66 65 72 28 24 6d 65 73 73 61 67 65 73 29 2c 20 24 6e 65 77 6c 69 6e 65 2c 20 24 74 79 70 | uffer($messages),.$newline,.$typ |
3ada0 | 65 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 | e);.....}....../**......*.{@inhe |
3adc0 | 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 | ritdoc}......*/.....public.funct |
3ade0 | 69 6f 6e 20 6e 65 77 4c 69 6e 65 28 24 63 6f 75 6e 74 20 3d 20 31 29 0a 20 20 20 20 7b 0a 20 20 | ion.newLine($count.=.1).....{... |
3ae00 | 20 20 20 20 20 20 70 61 72 65 6e 74 3a 3a 6e 65 77 4c 69 6e 65 28 24 63 6f 75 6e 74 29 3b 0a 20 | ......parent::newLine($count);.. |
3ae20 | 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 62 75 66 66 65 72 65 64 4f 75 74 70 75 74 2d 3e 77 72 | .......$this->bufferedOutput->wr |
3ae40 | 69 74 65 28 73 74 72 5f 72 65 70 65 61 74 28 22 5c 6e 22 2c 20 24 63 6f 75 6e 74 29 29 3b 0a 20 | ite(str_repeat("\n",.$count));.. |
3ae60 | 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 50 72 6f | ...}....../**......*.@return.Pro |
3ae80 | 67 72 65 73 73 42 61 72 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e | gressBar......*/.....private.fun |
3aea0 | 63 74 69 6f 6e 20 67 65 74 50 72 6f 67 72 65 73 73 42 61 72 28 29 0a 20 20 20 20 7b 0a 20 20 20 | ction.getProgressBar().....{.... |
3aec0 | 20 20 20 20 20 69 66 20 28 21 24 74 68 69 73 2d 3e 70 72 6f 67 72 65 73 73 42 61 72 29 20 7b 0a | .....if.(!$this->progressBar).{. |
3aee0 | 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 52 75 6e 74 69 6d 65 45 78 63 | ............throw.new.RuntimeExc |
3af00 | 65 70 74 69 6f 6e 28 27 54 68 65 20 50 72 6f 67 72 65 73 73 42 61 72 20 69 73 20 6e 6f 74 20 73 | eption('The.ProgressBar.is.not.s |
3af20 | 74 61 72 74 65 64 2e 27 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 | tarted.');.........}..........re |
3af40 | 74 75 72 6e 20 24 74 68 69 73 2d 3e 70 72 6f 67 72 65 73 73 42 61 72 3b 0a 20 20 20 20 7d 0a 0a | turn.$this->progressBar;.....}.. |
3af60 | 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 54 65 72 6d 69 6e 61 6c | ....private.function.getTerminal |
3af80 | 57 69 64 74 68 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 61 70 70 6c 69 63 61 74 69 | Width().....{.........$applicati |
3afa0 | 6f 6e 20 3d 20 6e 65 77 20 41 70 70 6c 69 63 61 74 69 6f 6e 28 29 3b 0a 20 20 20 20 20 20 20 20 | on.=.new.Application();......... |
3afc0 | 24 64 69 6d 65 6e 73 69 6f 6e 73 20 3d 20 24 61 70 70 6c 69 63 61 74 69 6f 6e 2d 3e 67 65 74 54 | $dimensions.=.$application->getT |
3afe0 | 65 72 6d 69 6e 61 6c 44 69 6d 65 6e 73 69 6f 6e 73 28 29 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 | erminalDimensions();..........re |
3b000 | 74 75 72 6e 20 24 64 69 6d 65 6e 73 69 6f 6e 73 5b 30 5d 20 3f 3a 20 73 65 6c 66 3a 3a 4d 41 58 | turn.$dimensions[0].?:.self::MAX |
3b020 | 5f 4c 49 4e 45 5f 4c 45 4e 47 54 48 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 72 69 76 61 74 65 | _LINE_LENGTH;.....}......private |
3b040 | 20 66 75 6e 63 74 69 6f 6e 20 61 75 74 6f 50 72 65 70 65 6e 64 42 6c 6f 63 6b 28 29 0a 20 20 20 | .function.autoPrependBlock().... |
3b060 | 20 7b 0a 20 20 20 20 20 20 20 20 24 63 68 61 72 73 20 3d 20 73 75 62 73 74 72 28 73 74 72 5f 72 | .{.........$chars.=.substr(str_r |
3b080 | 65 70 6c 61 63 65 28 50 48 50 5f 45 4f 4c 2c 20 22 5c 6e 22 2c 20 24 74 68 69 73 2d 3e 62 75 66 | eplace(PHP_EOL,."\n",.$this->buf |
3b0a0 | 66 65 72 65 64 4f 75 74 70 75 74 2d 3e 66 65 74 63 68 28 29 29 2c 20 2d 32 29 3b 0a 0a 20 20 20 | feredOutput->fetch()),.-2);..... |
3b0c0 | 20 20 20 20 20 69 66 20 28 21 69 73 73 65 74 28 24 63 68 61 72 73 5b 30 5d 29 29 20 7b 0a 20 20 | .....if.(!isset($chars[0])).{... |
3b0e0 | 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 6e 65 77 4c 69 6e 65 28 | ..........return.$this->newLine( |
3b100 | 29 3b 20 2f 2f 65 6d 70 74 79 20 68 69 73 74 6f 72 79 2c 20 73 6f 20 77 65 20 73 68 6f 75 6c 64 | );.//empty.history,.so.we.should |
3b120 | 20 73 74 61 72 74 20 77 69 74 68 20 61 20 6e 65 77 20 6c 69 6e 65 2e 0a 20 20 20 20 20 20 20 20 | .start.with.a.new.line.......... |
3b140 | 7d 0a 20 20 20 20 20 20 20 20 2f 2f 50 72 65 70 65 6e 64 20 6e 65 77 20 6c 69 6e 65 20 66 6f 72 | }.........//Prepend.new.line.for |
3b160 | 20 65 61 63 68 20 6e 6f 6e 20 4c 46 20 63 68 61 72 73 20 28 54 68 69 73 20 6d 65 61 6e 73 20 6e | .each.non.LF.chars.(This.means.n |
3b180 | 6f 20 62 6c 61 6e 6b 20 6c 69 6e 65 20 77 61 73 20 6f 75 74 70 75 74 20 62 65 66 6f 72 65 29 0a | o.blank.line.was.output.before). |
3b1a0 | 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6e 65 77 4c 69 6e 65 28 32 20 2d 20 73 75 62 73 74 | ........$this->newLine(2.-.subst |
3b1c0 | 72 5f 63 6f 75 6e 74 28 24 63 68 61 72 73 2c 20 22 5c 6e 22 29 29 3b 0a 20 20 20 20 7d 0a 0a 20 | r_count($chars,."\n"));.....}... |
3b1e0 | 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 61 75 74 6f 50 72 65 70 65 6e 64 54 | ...private.function.autoPrependT |
3b200 | 65 78 74 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 66 65 74 63 68 65 64 20 3d 20 24 | ext().....{.........$fetched.=.$ |
3b220 | 74 68 69 73 2d 3e 62 75 66 66 65 72 65 64 4f 75 74 70 75 74 2d 3e 66 65 74 63 68 28 29 3b 0a 20 | this->bufferedOutput->fetch();.. |
3b240 | 20 20 20 20 20 20 20 2f 2f 50 72 65 70 65 6e 64 20 6e 65 77 20 6c 69 6e 65 20 69 66 20 6c 61 73 | .......//Prepend.new.line.if.las |
3b260 | 74 20 63 68 61 72 20 69 73 6e 27 74 20 45 4f 4c 3a 0a 20 20 20 20 20 20 20 20 69 66 20 28 22 5c | t.char.isn't.EOL:.........if.("\ |
3b280 | 6e 22 20 21 3d 3d 20 73 75 62 73 74 72 28 24 66 65 74 63 68 65 64 2c 20 2d 31 29 29 20 7b 0a 20 | n".!==.substr($fetched,.-1)).{.. |
3b2a0 | 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6e 65 77 4c 69 6e 65 28 29 3b 0a 20 20 20 | ...........$this->newLine();.... |
3b2c0 | 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 | .....}.....}......private.functi |
3b2e0 | 6f 6e 20 72 65 64 75 63 65 42 75 66 66 65 72 28 24 6d 65 73 73 61 67 65 73 29 0a 20 20 20 20 7b | on.reduceBuffer($messages).....{ |
3b300 | 0a 20 20 20 20 20 20 20 20 2f 2f 20 57 65 20 6e 65 65 64 20 74 6f 20 6b 6e 6f 77 20 69 66 20 74 | .........//.We.need.to.know.if.t |
3b320 | 68 65 20 74 77 6f 20 6c 61 73 74 20 63 68 61 72 73 20 61 72 65 20 50 48 50 5f 45 4f 4c 0a 20 20 | he.two.last.chars.are.PHP_EOL... |
3b340 | 20 20 20 20 20 20 2f 2f 20 50 72 65 73 65 72 76 65 20 74 68 65 20 6c 61 73 74 20 34 20 63 68 61 | ......//.Preserve.the.last.4.cha |
3b360 | 72 73 20 69 6e 73 65 72 74 65 64 20 28 50 48 50 5f 45 4f 4c 20 6f 6e 20 77 69 6e 64 6f 77 73 20 | rs.inserted.(PHP_EOL.on.windows. |
3b380 | 69 73 20 74 77 6f 20 63 68 61 72 73 29 20 69 6e 20 74 68 65 20 68 69 73 74 6f 72 79 20 62 75 66 | is.two.chars).in.the.history.buf |
3b3a0 | 66 65 72 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 61 72 72 61 79 5f 6d 61 70 28 66 75 6e | fer.........return.array_map(fun |
3b3c0 | 63 74 69 6f 6e 20 28 24 76 61 6c 75 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 | ction.($value).{.............ret |
3b3e0 | 75 72 6e 20 73 75 62 73 74 72 28 24 76 61 6c 75 65 2c 20 2d 34 29 3b 0a 20 20 20 20 20 20 20 20 | urn.substr($value,.-4);......... |
3b400 | 7d 2c 20 61 72 72 61 79 5f 6d 65 72 67 65 28 61 72 72 61 79 28 24 74 68 69 73 2d 3e 62 75 66 66 | },.array_merge(array($this->buff |
3b420 | 65 72 65 64 4f 75 74 70 75 74 2d 3e 66 65 74 63 68 28 29 29 2c 20 28 61 72 72 61 79 29 20 24 6d | eredOutput->fetch()),.(array).$m |
3b440 | 65 73 73 61 67 65 73 29 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 | essages));.....}......private.fu |
3b460 | 6e 63 74 69 6f 6e 20 63 72 65 61 74 65 42 6c 6f 63 6b 28 24 6d 65 73 73 61 67 65 73 2c 20 24 74 | nction.createBlock($messages,.$t |
3b480 | 79 70 65 20 3d 20 6e 75 6c 6c 2c 20 24 73 74 79 6c 65 20 3d 20 6e 75 6c 6c 2c 20 24 70 72 65 66 | ype.=.null,.$style.=.null,.$pref |
3b4a0 | 69 78 20 3d 20 27 20 27 2c 20 24 70 61 64 64 69 6e 67 20 3d 20 66 61 6c 73 65 2c 20 24 65 73 63 | ix.=.'.',.$padding.=.false,.$esc |
3b4c0 | 61 70 65 20 3d 20 66 61 6c 73 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 69 6e 64 65 | ape.=.false).....{.........$inde |
3b4e0 | 6e 74 4c 65 6e 67 74 68 20 3d 20 30 3b 0a 20 20 20 20 20 20 20 20 24 70 72 65 66 69 78 4c 65 6e | ntLength.=.0;.........$prefixLen |
3b500 | 67 74 68 20 3d 20 48 65 6c 70 65 72 3a 3a 73 74 72 6c 65 6e 57 69 74 68 6f 75 74 44 65 63 6f 72 | gth.=.Helper::strlenWithoutDecor |
3b520 | 61 74 69 6f 6e 28 24 74 68 69 73 2d 3e 67 65 74 46 6f 72 6d 61 74 74 65 72 28 29 2c 20 24 70 72 | ation($this->getFormatter(),.$pr |
3b540 | 65 66 69 78 29 3b 0a 20 20 20 20 20 20 20 20 24 6c 69 6e 65 73 20 3d 20 61 72 72 61 79 28 29 3b | efix);.........$lines.=.array(); |
3b560 | 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 21 3d 3d 20 24 74 79 70 65 29 20 7b 0a | ..........if.(null.!==.$type).{. |
3b580 | 20 20 20 20 20 20 20 20 20 20 20 20 24 74 79 70 65 20 3d 20 73 70 72 69 6e 74 66 28 27 5b 25 73 | ............$type.=.sprintf('[%s |
3b5a0 | 5d 20 27 2c 20 24 74 79 70 65 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 69 6e 64 65 6e 74 | ].',.$type);.............$indent |
3b5c0 | 4c 65 6e 67 74 68 20 3d 20 73 74 72 6c 65 6e 28 24 74 79 70 65 29 3b 0a 20 20 20 20 20 20 20 20 | Length.=.strlen($type);......... |
3b5e0 | 20 20 20 20 24 6c 69 6e 65 49 6e 64 65 6e 74 61 74 69 6f 6e 20 3d 20 73 74 72 5f 72 65 70 65 61 | ....$lineIndentation.=.str_repea |
3b600 | 74 28 27 20 27 2c 20 24 69 6e 64 65 6e 74 4c 65 6e 67 74 68 29 3b 0a 20 20 20 20 20 20 20 20 7d | t('.',.$indentLength);.........} |
3b620 | 0a 0a 20 20 20 20 20 20 20 20 2f 2f 20 77 72 61 70 20 61 6e 64 20 61 64 64 20 6e 65 77 6c 69 6e | ..........//.wrap.and.add.newlin |
3b640 | 65 73 20 66 6f 72 20 65 61 63 68 20 65 6c 65 6d 65 6e 74 0a 20 20 20 20 20 20 20 20 66 6f 72 65 | es.for.each.element.........fore |
3b660 | 61 63 68 20 28 24 6d 65 73 73 61 67 65 73 20 61 73 20 24 6b 65 79 20 3d 3e 20 24 6d 65 73 73 61 | ach.($messages.as.$key.=>.$messa |
3b680 | 67 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 65 73 63 61 70 65 29 20 7b | ge).{.............if.($escape).{ |
3b6a0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 20 3d 20 4f 75 74 70 | .................$message.=.Outp |
3b6c0 | 75 74 46 6f 72 6d 61 74 74 65 72 3a 3a 65 73 63 61 70 65 28 24 6d 65 73 73 61 67 65 29 3b 0a 20 | utFormatter::escape($message);.. |
3b6e0 | 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 69 6e 65 73 | ...........}..............$lines |
3b700 | 20 3d 20 61 72 72 61 79 5f 6d 65 72 67 65 28 24 6c 69 6e 65 73 2c 20 65 78 70 6c 6f 64 65 28 50 | .=.array_merge($lines,.explode(P |
3b720 | 48 50 5f 45 4f 4c 2c 20 77 6f 72 64 77 72 61 70 28 24 6d 65 73 73 61 67 65 2c 20 24 74 68 69 73 | HP_EOL,.wordwrap($message,.$this |
3b740 | 2d 3e 6c 69 6e 65 4c 65 6e 67 74 68 20 2d 20 24 70 72 65 66 69 78 4c 65 6e 67 74 68 20 2d 20 24 | ->lineLength.-.$prefixLength.-.$ |
3b760 | 69 6e 64 65 6e 74 4c 65 6e 67 74 68 2c 20 50 48 50 5f 45 4f 4c 2c 20 74 72 75 65 29 29 29 3b 0a | indentLength,.PHP_EOL,.true)));. |
3b780 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 63 6f 75 6e 74 28 24 6d 65 73 73 61 67 65 73 | .............if.(count($messages |
3b7a0 | 29 20 3e 20 31 20 26 26 20 24 6b 65 79 20 3c 20 63 6f 75 6e 74 28 24 6d 65 73 73 61 67 65 73 29 | ).>.1.&&.$key.<.count($messages) |
3b7c0 | 20 2d 20 31 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 69 6e 65 73 5b 5d | .-.1).{.................$lines[] |
3b7e0 | 20 3d 20 27 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a | .=.'';.............}.........}.. |
3b800 | 20 20 20 20 20 20 20 20 24 66 69 72 73 74 4c 69 6e 65 49 6e 64 65 78 20 3d 20 30 3b 0a 20 20 20 | ........$firstLineIndex.=.0;.... |
3b820 | 20 20 20 20 20 69 66 20 28 24 70 61 64 64 69 6e 67 20 26 26 20 24 74 68 69 73 2d 3e 69 73 44 65 | .....if.($padding.&&.$this->isDe |
3b840 | 63 6f 72 61 74 65 64 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 66 69 72 73 74 4c | corated()).{.............$firstL |
3b860 | 69 6e 65 49 6e 64 65 78 20 3d 20 31 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 61 72 72 61 79 5f | ineIndex.=.1;.............array_ |
3b880 | 75 6e 73 68 69 66 74 28 24 6c 69 6e 65 73 2c 20 27 27 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 | unshift($lines,.'');............ |
3b8a0 | 20 24 6c 69 6e 65 73 5b 5d 20 3d 20 27 27 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 | .$lines[].=.'';.........}....... |
3b8c0 | 20 20 20 66 6f 72 65 61 63 68 20 28 24 6c 69 6e 65 73 20 61 73 20 24 69 20 3d 3e 20 26 24 6c 69 | ...foreach.($lines.as.$i.=>.&$li |
3b8e0 | 6e 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 21 3d 3d 20 24 | ne).{.............if.(null.!==.$ |
3b900 | 74 79 70 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 69 6e 65 20 3d 20 | type).{.................$line.=. |
3b920 | 24 66 69 72 73 74 4c 69 6e 65 49 6e 64 65 78 20 3d 3d 3d 20 24 69 20 3f 20 24 74 79 70 65 2e 24 | $firstLineIndex.===.$i.?.$type.$ |
3b940 | 6c 69 6e 65 20 3a 20 24 6c 69 6e 65 49 6e 64 65 6e 74 61 74 69 6f 6e 2e 24 6c 69 6e 65 3b 0a 20 | line.:.$lineIndentation.$line;.. |
3b960 | 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 69 6e 65 20 | ...........}..............$line. |
3b980 | 3d 20 24 70 72 65 66 69 78 2e 24 6c 69 6e 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 69 | =.$prefix.$line;.............$li |
3b9a0 | 6e 65 20 2e 3d 20 73 74 72 5f 72 65 70 65 61 74 28 27 20 27 2c 20 24 74 68 69 73 2d 3e 6c 69 6e | ne..=.str_repeat('.',.$this->lin |
3b9c0 | 65 4c 65 6e 67 74 68 20 2d 20 48 65 6c 70 65 72 3a 3a 73 74 72 6c 65 6e 57 69 74 68 6f 75 74 44 | eLength.-.Helper::strlenWithoutD |
3b9e0 | 65 63 6f 72 61 74 69 6f 6e 28 24 74 68 69 73 2d 3e 67 65 74 46 6f 72 6d 61 74 74 65 72 28 29 2c | ecoration($this->getFormatter(), |
3ba00 | 20 24 6c 69 6e 65 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 73 74 79 6c | .$line));..............if.($styl |
3ba20 | 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 69 6e 65 20 3d 20 73 70 72 | e).{.................$line.=.spr |
3ba40 | 69 6e 74 66 28 27 3c 25 73 3e 25 73 3c 2f 3e 27 2c 20 24 73 74 79 6c 65 2c 20 24 6c 69 6e 65 29 | intf('<%s>%s</>',.$style,.$line) |
3ba60 | 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 | ;.............}.........}....... |
3ba80 | 20 20 20 72 65 74 75 72 6e 20 24 6c 69 6e 65 73 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a | ...return.$lines;.....}.}.<?php. |
3baa0 | 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 | ./*..*.This.file.is.part.of.the. |
3bac0 | 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 | Symfony.package...*..*.(c).Fabie |
3bae0 | 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e | n.Potencier.<fabien@symfony.com> |
3bb00 | 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e | ..*..*.For.the.full.copyright.an |
3bb20 | 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 | d.license.information,.please.vi |
3bb40 | 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 | ew.the.LICENSE..*.file.that.was. |
3bb60 | 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 | distributed.with.this.source.cod |
3bb80 | 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e | e...*/..namespace.Symfony\Compon |
3bba0 | 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 4f 75 74 70 75 74 3b 0a 0a 2f 2a 2a 0a 20 2a 20 43 6f 6e 73 | ent\Console\Output;../**..*.Cons |
3bbc0 | 6f 6c 65 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 69 73 20 74 68 65 20 69 6e 74 65 72 66 | oleOutputInterface.is.the.interf |
3bbe0 | 61 63 65 20 69 6d 70 6c 65 6d 65 6e 74 65 64 20 62 79 20 43 6f 6e 73 6f 6c 65 4f 75 74 70 75 74 | ace.implemented.by.ConsoleOutput |
3bc00 | 20 63 6c 61 73 73 2e 0a 20 2a 20 54 68 69 73 20 61 64 64 73 20 69 6e 66 6f 72 6d 61 74 69 6f 6e | .class...*.This.adds.information |
3bc20 | 20 61 62 6f 75 74 20 73 74 64 65 72 72 20 6f 75 74 70 75 74 20 73 74 72 65 61 6d 2e 0a 20 2a 0a | .about.stderr.output.stream...*. |
3bc40 | 20 2a 20 40 61 75 74 68 6f 72 20 44 61 72 69 75 73 7a 20 47 c3 b3 72 65 63 6b 69 20 3c 64 61 72 | .*.@author.Dariusz.G..recki.<dar |
3bc60 | 65 6b 2e 6b 72 6b 40 67 6d 61 69 6c 2e 63 6f 6d 3e 0a 20 2a 2f 0a 69 6e 74 65 72 66 61 63 65 20 | ek.krk@gmail.com>..*/.interface. |
3bc80 | 43 6f 6e 73 6f 6c 65 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 65 78 74 65 6e 64 73 20 4f | ConsoleOutputInterface.extends.O |
3bca0 | 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 0a 7b 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 | utputInterface.{...../**......*. |
3bcc0 | 47 65 74 73 20 74 68 65 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 66 6f 72 20 65 72 72 | Gets.the.OutputInterface.for.err |
3bce0 | 6f 72 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 4f 75 74 70 75 | ors.......*......*.@return.Outpu |
3bd00 | 74 49 6e 74 65 72 66 61 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 | tInterface......*/.....public.fu |
3bd20 | 6e 63 74 69 6f 6e 20 67 65 74 45 72 72 6f 72 4f 75 74 70 75 74 28 29 3b 0a 0a 20 20 20 20 2f 2a | nction.getErrorOutput();....../* |
3bd40 | 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 74 68 65 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 | *......*.Sets.the.OutputInterfac |
3bd60 | 65 20 75 73 65 64 20 66 6f 72 20 65 72 72 6f 72 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a | e.used.for.errors.......*......* |
3bd80 | 20 40 70 61 72 61 6d 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 65 72 72 6f 72 0a 20 | .@param.OutputInterface.$error.. |
3bda0 | 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 45 72 | ....*/.....public.function.setEr |
3bdc0 | 72 6f 72 4f 75 74 70 75 74 28 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 65 72 72 6f 72 | rorOutput(OutputInterface.$error |
3bde0 | 29 3b 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 | );.}.<?php../*..*.This.file.is.p |
3be00 | 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 | art.of.the.Symfony.package...*.. |
3be20 | 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 | *.(c).Fabien.Potencier.<fabien@s |
3be40 | 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 | ymfony.com>..*..*.For.the.full.c |
3be60 | 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e | opyright.and.license.information |
3be80 | 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c | ,.please.view.the.LICENSE..*.fil |
3bea0 | 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 | e.that.was.distributed.with.this |
3bec0 | 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d | .source.code...*/..namespace.Sym |
3bee0 | 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 4f 75 74 70 75 74 3b 0a 0a | fony\Component\Console\Output;.. |
3bf00 | 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 78 | use.Symfony\Component\Console\Ex |
3bf20 | 63 65 70 74 69 6f 6e 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e | ception\InvalidArgumentException |
3bf40 | 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c | ;.use.Symfony\Component\Console\ |
3bf60 | 45 78 63 65 70 74 69 6f 6e 5c 52 75 6e 74 69 6d 65 45 78 63 65 70 74 69 6f 6e 3b 0a 75 73 65 20 | Exception\RuntimeException;.use. |
3bf80 | 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 46 6f 72 6d 61 74 | Symfony\Component\Console\Format |
3bfa0 | 74 65 72 5c 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 49 6e 74 65 72 66 61 63 65 3b 0a 0a 2f | ter\OutputFormatterInterface;../ |
3bfc0 | 2a 2a 0a 20 2a 20 53 74 72 65 61 6d 4f 75 74 70 75 74 20 77 72 69 74 65 73 20 74 68 65 20 6f 75 | **..*.StreamOutput.writes.the.ou |
3bfe0 | 74 70 75 74 20 74 6f 20 61 20 67 69 76 65 6e 20 73 74 72 65 61 6d 2e 0a 20 2a 0a 20 2a 20 55 73 | tput.to.a.given.stream...*..*.Us |
3c000 | 61 67 65 3a 0a 20 2a 0a 20 2a 20 24 6f 75 74 70 75 74 20 3d 20 6e 65 77 20 53 74 72 65 61 6d 4f | age:..*..*.$output.=.new.StreamO |
3c020 | 75 74 70 75 74 28 66 6f 70 65 6e 28 27 70 68 70 3a 2f 2f 73 74 64 6f 75 74 27 2c 20 27 77 27 29 | utput(fopen('php://stdout',.'w') |
3c040 | 29 3b 0a 20 2a 0a 20 2a 20 41 73 20 60 53 74 72 65 61 6d 4f 75 74 70 75 74 60 20 63 61 6e 20 75 | );..*..*.As.`StreamOutput`.can.u |
3c060 | 73 65 20 61 6e 79 20 73 74 72 65 61 6d 2c 20 79 6f 75 20 63 61 6e 20 61 6c 73 6f 20 75 73 65 20 | se.any.stream,.you.can.also.use. |
3c080 | 61 20 66 69 6c 65 3a 0a 20 2a 0a 20 2a 20 24 6f 75 74 70 75 74 20 3d 20 6e 65 77 20 53 74 72 65 | a.file:..*..*.$output.=.new.Stre |
3c0a0 | 61 6d 4f 75 74 70 75 74 28 66 6f 70 65 6e 28 27 2f 70 61 74 68 2f 74 6f 2f 6f 75 74 70 75 74 2e | amOutput(fopen('/path/to/output. |
3c0c0 | 6c 6f 67 27 2c 20 27 61 27 2c 20 66 61 6c 73 65 29 29 3b 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f | log',.'a',.false));..*..*.@autho |
3c0e0 | 72 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f | r.Fabien.Potencier.<fabien@symfo |
3c100 | 6e 79 2e 63 6f 6d 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 53 74 72 65 61 6d 4f 75 74 70 75 74 20 65 | ny.com>..*/.class.StreamOutput.e |
3c120 | 78 74 65 6e 64 73 20 4f 75 74 70 75 74 0a 7b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 73 74 72 | xtends.Output.{.....private.$str |
3c140 | 65 61 6d 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 43 6f 6e 73 74 72 75 63 74 6f 72 | eam;....../**......*.Constructor |
3c160 | 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 72 65 73 6f 75 72 63 65 20 | .......*......*.@param.resource. |
3c180 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 73 74 72 65 61 6d 20 20 20 20 | .....................$stream.... |
3c1a0 | 41 20 73 74 72 65 61 6d 20 72 65 73 6f 75 72 63 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 | A.stream.resource......*.@param. |
3c1c0 | 69 6e 74 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 76 | int...........................$v |
3c1e0 | 65 72 62 6f 73 69 74 79 20 54 68 65 20 76 65 72 62 6f 73 69 74 79 20 6c 65 76 65 6c 20 28 6f 6e | erbosity.The.verbosity.level.(on |
3c200 | 65 20 6f 66 20 74 68 65 20 56 45 52 42 4f 53 49 54 59 20 63 6f 6e 73 74 61 6e 74 73 20 69 6e 20 | e.of.the.VERBOSITY.constants.in. |
3c220 | 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 29 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 62 | OutputInterface)......*.@param.b |
3c240 | 6f 6f 6c 7c 6e 75 6c 6c 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 64 65 | ool|null.....................$de |
3c260 | 63 6f 72 61 74 65 64 20 57 68 65 74 68 65 72 20 74 6f 20 64 65 63 6f 72 61 74 65 20 6d 65 73 73 | corated.Whether.to.decorate.mess |
3c280 | 61 67 65 73 20 28 6e 75 6c 6c 20 66 6f 72 20 61 75 74 6f 2d 67 75 65 73 73 69 6e 67 29 0a 20 20 | ages.(null.for.auto-guessing)... |
3c2a0 | 20 20 20 2a 20 40 70 61 72 61 6d 20 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 49 6e 74 65 72 | ...*.@param.OutputFormatterInter |
3c2c0 | 66 61 63 65 7c 6e 75 6c 6c 20 24 66 6f 72 6d 61 74 74 65 72 20 4f 75 74 70 75 74 20 66 6f 72 6d | face|null.$formatter.Output.form |
3c2e0 | 61 74 74 65 72 20 69 6e 73 74 61 6e 63 65 20 28 6e 75 6c 6c 20 74 6f 20 75 73 65 20 64 65 66 61 | atter.instance.(null.to.use.defa |
3c300 | 75 6c 74 20 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 29 0a 20 20 20 20 20 2a 0a 20 20 20 20 | ult.OutputFormatter)......*..... |
3c320 | 20 2a 20 40 74 68 72 6f 77 73 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 | .*.@throws.InvalidArgumentExcept |
3c340 | 69 6f 6e 20 57 68 65 6e 20 66 69 72 73 74 20 61 72 67 75 6d 65 6e 74 20 69 73 20 6e 6f 74 20 61 | ion.When.first.argument.is.not.a |
3c360 | 20 72 65 61 6c 20 73 74 72 65 61 6d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 | .real.stream......*/.....public. |
3c380 | 66 75 6e 63 74 69 6f 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 74 28 24 73 74 72 65 61 6d 2c 20 24 76 | function.__construct($stream,.$v |
3c3a0 | 65 72 62 6f 73 69 74 79 20 3d 20 73 65 6c 66 3a 3a 56 45 52 42 4f 53 49 54 59 5f 4e 4f 52 4d 41 | erbosity.=.self::VERBOSITY_NORMA |
3c3c0 | 4c 2c 20 24 64 65 63 6f 72 61 74 65 64 20 3d 20 6e 75 6c 6c 2c 20 4f 75 74 70 75 74 46 6f 72 6d | L,.$decorated.=.null,.OutputForm |
3c3e0 | 61 74 74 65 72 49 6e 74 65 72 66 61 63 65 20 24 66 6f 72 6d 61 74 74 65 72 20 3d 20 6e 75 6c 6c | atterInterface.$formatter.=.null |
3c400 | 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 69 73 5f 72 65 73 6f 75 72 63 65 | ).....{.........if.(!is_resource |
3c420 | 28 24 73 74 72 65 61 6d 29 20 7c 7c 20 27 73 74 72 65 61 6d 27 20 21 3d 3d 20 67 65 74 5f 72 65 | ($stream).||.'stream'.!==.get_re |
3c440 | 73 6f 75 72 63 65 5f 74 79 70 65 28 24 73 74 72 65 61 6d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 | source_type($stream)).{......... |
3c460 | 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 | ....throw.new.InvalidArgumentExc |
3c480 | 65 70 74 69 6f 6e 28 27 54 68 65 20 53 74 72 65 61 6d 4f 75 74 70 75 74 20 63 6c 61 73 73 20 6e | eption('The.StreamOutput.class.n |
3c4a0 | 65 65 64 73 20 61 20 73 74 72 65 61 6d 20 61 73 20 69 74 73 20 66 69 72 73 74 20 61 72 67 75 6d | eeds.a.stream.as.its.first.argum |
3c4c0 | 65 6e 74 2e 27 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 | ent.');.........}..........$this |
3c4e0 | 2d 3e 73 74 72 65 61 6d 20 3d 20 24 73 74 72 65 61 6d 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 | ->stream.=.$stream;..........if. |
3c500 | 28 6e 75 6c 6c 20 3d 3d 3d 20 24 64 65 63 6f 72 61 74 65 64 29 20 7b 0a 20 20 20 20 20 20 20 20 | (null.===.$decorated).{......... |
3c520 | 20 20 20 20 24 64 65 63 6f 72 61 74 65 64 20 3d 20 24 74 68 69 73 2d 3e 68 61 73 43 6f 6c 6f 72 | ....$decorated.=.$this->hasColor |
3c540 | 53 75 70 70 6f 72 74 28 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 70 61 | Support();.........}..........pa |
3c560 | 72 65 6e 74 3a 3a 5f 5f 63 6f 6e 73 74 72 75 63 74 28 24 76 65 72 62 6f 73 69 74 79 2c 20 24 64 | rent::__construct($verbosity,.$d |
3c580 | 65 63 6f 72 61 74 65 64 2c 20 24 66 6f 72 6d 61 74 74 65 72 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 | ecorated,.$formatter);.....}.... |
3c5a0 | 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 73 74 72 65 61 6d 20 61 74 74 | ../**......*.Gets.the.stream.att |
3c5c0 | 61 63 68 65 64 20 74 6f 20 74 68 69 73 20 53 74 72 65 61 6d 4f 75 74 70 75 74 20 69 6e 73 74 61 | ached.to.this.StreamOutput.insta |
3c5e0 | 6e 63 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 72 65 73 6f 75 | nce.......*......*.@return.resou |
3c600 | 72 63 65 20 41 20 73 74 72 65 61 6d 20 72 65 73 6f 75 72 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 | rce.A.stream.resource......*/... |
3c620 | 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 53 74 72 65 61 6d 28 29 0a 20 20 | ..public.function.getStream()... |
3c640 | 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 73 74 72 65 61 6d | ..{.........return.$this->stream |
3c660 | 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 | ;.....}....../**......*.{@inheri |
3c680 | 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 | tdoc}......*/.....protected.func |
3c6a0 | 74 69 6f 6e 20 64 6f 57 72 69 74 65 28 24 6d 65 73 73 61 67 65 2c 20 24 6e 65 77 6c 69 6e 65 29 | tion.doWrite($message,.$newline) |
3c6c0 | 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 66 61 6c 73 65 20 3d 3d 3d 20 40 66 77 | .....{.........if.(false.===.@fw |
3c6e0 | 72 69 74 65 28 24 74 68 69 73 2d 3e 73 74 72 65 61 6d 2c 20 24 6d 65 73 73 61 67 65 29 20 7c 7c | rite($this->stream,.$message).|| |
3c700 | 20 28 24 6e 65 77 6c 69 6e 65 20 26 26 20 28 66 61 6c 73 65 20 3d 3d 3d 20 40 66 77 72 69 74 65 | .($newline.&&.(false.===.@fwrite |
3c720 | 28 24 74 68 69 73 2d 3e 73 74 72 65 61 6d 2c 20 50 48 50 5f 45 4f 4c 29 29 29 29 20 7b 0a 20 20 | ($this->stream,.PHP_EOL)))).{... |
3c740 | 20 20 20 20 20 20 20 20 20 20 2f 2f 20 73 68 6f 75 6c 64 20 6e 65 76 65 72 20 68 61 70 70 65 6e | ..........//.should.never.happen |
3c760 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 52 75 6e 74 69 6d 65 45 78 | .............throw.new.RuntimeEx |
3c780 | 63 65 70 74 69 6f 6e 28 27 55 6e 61 62 6c 65 20 74 6f 20 77 72 69 74 65 20 6f 75 74 70 75 74 2e | ception('Unable.to.write.output. |
3c7a0 | 27 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 66 66 6c 75 73 68 28 24 74 | ');.........}..........fflush($t |
3c7c0 | 68 69 73 2d 3e 73 74 72 65 61 6d 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 | his->stream);.....}....../**.... |
3c7e0 | 20 20 2a 20 52 65 74 75 72 6e 73 20 74 72 75 65 20 69 66 20 74 68 65 20 73 74 72 65 61 6d 20 73 | ..*.Returns.true.if.the.stream.s |
3c800 | 75 70 70 6f 72 74 73 20 63 6f 6c 6f 72 69 7a 61 74 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 | upports.colorization.......*.... |
3c820 | 20 20 2a 20 43 6f 6c 6f 72 69 7a 61 74 69 6f 6e 20 69 73 20 64 69 73 61 62 6c 65 64 20 69 66 20 | ..*.Colorization.is.disabled.if. |
3c840 | 6e 6f 74 20 73 75 70 70 6f 72 74 65 64 20 62 79 20 74 68 65 20 73 74 72 65 61 6d 3a 0a 20 20 20 | not.supported.by.the.stream:.... |
3c860 | 20 20 2a 0a 20 20 20 20 20 2a 20 20 2d 20 20 57 69 6e 64 6f 77 73 20 21 3d 20 31 30 2e 30 2e 31 | ..*......*..-..Windows.!=.10.0.1 |
3c880 | 30 35 38 36 20 77 69 74 68 6f 75 74 20 41 6e 73 69 63 6f 6e 2c 20 43 6f 6e 45 6d 75 20 6f 72 20 | 0586.without.Ansicon,.ConEmu.or. |
3c8a0 | 4d 69 6e 74 74 79 0a 20 20 20 20 20 2a 20 20 2d 20 20 6e 6f 6e 20 74 74 79 20 63 6f 6e 73 6f 6c | Mintty......*..-..non.tty.consol |
3c8c0 | 65 73 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 62 6f 6f 6c 20 74 72 | es......*......*.@return.bool.tr |
3c8e0 | 75 65 20 69 66 20 74 68 65 20 73 74 72 65 61 6d 20 73 75 70 70 6f 72 74 73 20 63 6f 6c 6f 72 69 | ue.if.the.stream.supports.colori |
3c900 | 7a 61 74 69 6f 6e 2c 20 66 61 6c 73 65 20 6f 74 68 65 72 77 69 73 65 0a 20 20 20 20 20 2a 2f 0a | zation,.false.otherwise......*/. |
3c920 | 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 68 61 73 43 6f 6c 6f 72 53 | ....protected.function.hasColorS |
3c940 | 75 70 70 6f 72 74 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 44 49 52 45 43 | upport().....{.........if.(DIREC |
3c960 | 54 4f 52 59 5f 53 45 50 41 52 41 54 4f 52 20 3d 3d 3d 20 27 5c 5c 27 29 20 7b 0a 20 20 20 20 20 | TORY_SEPARATOR.===.'\\').{...... |
3c980 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 27 31 | .......return.................'1 |
3c9a0 | 30 2e 30 2e 31 30 35 38 36 27 20 3d 3d 3d 20 50 48 50 5f 57 49 4e 44 4f 57 53 5f 56 45 52 53 49 | 0.0.10586'.===.PHP_WINDOWS_VERSI |
3c9c0 | 4f 4e 5f 4d 41 4a 4f 52 2e 27 2e 27 2e 50 48 50 5f 57 49 4e 44 4f 57 53 5f 56 45 52 53 49 4f 4e | ON_MAJOR.'.'.PHP_WINDOWS_VERSION |
3c9e0 | 5f 4d 49 4e 4f 52 2e 27 2e 27 2e 50 48 50 5f 57 49 4e 44 4f 57 53 5f 56 45 52 53 49 4f 4e 5f 42 | _MINOR.'.'.PHP_WINDOWS_VERSION_B |
3ca00 | 55 49 4c 44 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7c 7c 20 66 61 6c 73 65 20 21 3d | UILD.................||.false.!= |
3ca20 | 3d 20 67 65 74 65 6e 76 28 27 41 4e 53 49 43 4f 4e 27 29 0a 20 20 20 20 20 20 20 20 20 20 20 20 | =.getenv('ANSICON')............. |
3ca40 | 20 20 20 20 7c 7c 20 27 4f 4e 27 20 3d 3d 3d 20 67 65 74 65 6e 76 28 27 43 6f 6e 45 6d 75 41 4e | ....||.'ON'.===.getenv('ConEmuAN |
3ca60 | 53 49 27 29 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7c 7c 20 27 78 74 65 72 6d 27 20 | SI').................||.'xterm'. |
3ca80 | 3d 3d 3d 20 67 65 74 65 6e 76 28 27 54 45 52 4d 27 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 | ===.getenv('TERM');.........}... |
3caa0 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 66 75 6e 63 74 69 6f 6e 5f 65 78 69 73 74 73 28 27 70 | .......return.function_exists('p |
3cac0 | 6f 73 69 78 5f 69 73 61 74 74 79 27 29 20 26 26 20 40 70 6f 73 69 78 5f 69 73 61 74 74 79 28 24 | osix_isatty').&&.@posix_isatty($ |
3cae0 | 74 68 69 73 2d 3e 73 74 72 65 61 6d 29 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a | this->stream);.....}.}.<?php../* |
3cb00 | 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d | ..*.This.file.is.part.of.the.Sym |
3cb20 | 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 | fony.package...*..*.(c).Fabien.P |
3cb40 | 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a | otencier.<fabien@symfony.com>..* |
3cb60 | 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c | ..*.For.the.full.copyright.and.l |
3cb80 | 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 | icense.information,.please.view. |
3cba0 | 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 | the.LICENSE..*.file.that.was.dis |
3cbc0 | 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a | tributed.with.this.source.code.. |
3cbe0 | 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 | .*/..namespace.Symfony\Component |
3cc00 | 5c 43 6f 6e 73 6f 6c 65 5c 4f 75 74 70 75 74 3b 0a 0a 2f 2a 2a 0a 20 2a 20 40 61 75 74 68 6f 72 | \Console\Output;../**..*.@author |
3cc20 | 20 4a 65 61 6e 2d 46 72 61 6e c3 a7 6f 69 73 20 53 69 6d 6f 6e 20 3c 63 6f 6e 74 61 63 74 40 6a | .Jean-Fran..ois.Simon.<contact@j |
3cc40 | 66 73 69 6d 6f 6e 2e 66 72 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 42 75 66 66 65 72 65 64 4f 75 74 | fsimon.fr>..*/.class.BufferedOut |
3cc60 | 70 75 74 20 65 78 74 65 6e 64 73 20 4f 75 74 70 75 74 0a 7b 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 | put.extends.Output.{...../**.... |
3cc80 | 20 20 2a 20 40 76 61 72 20 73 74 72 69 6e 67 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 | ..*.@var.string......*/.....priv |
3cca0 | 61 74 65 20 24 62 75 66 66 65 72 20 3d 20 27 27 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 | ate.$buffer.=.'';....../**...... |
3ccc0 | 2a 20 45 6d 70 74 69 65 73 20 62 75 66 66 65 72 20 61 6e 64 20 72 65 74 75 72 6e 73 20 69 74 73 | *.Empties.buffer.and.returns.its |
3cce0 | 20 63 6f 6e 74 65 6e 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 | .content.......*......*.@return. |
3cd00 | 73 74 72 69 6e 67 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 | string......*/.....public.functi |
3cd20 | 6f 6e 20 66 65 74 63 68 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 63 6f 6e 74 65 6e | on.fetch().....{.........$conten |
3cd40 | 74 20 3d 20 24 74 68 69 73 2d 3e 62 75 66 66 65 72 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 | t.=.$this->buffer;.........$this |
3cd60 | 2d 3e 62 75 66 66 65 72 20 3d 20 27 27 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 | ->buffer.=.'';..........return.$ |
3cd80 | 63 6f 6e 74 65 6e 74 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b | content;.....}....../**......*.{ |
3cda0 | 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 6f 74 65 63 74 | @inheritdoc}......*/.....protect |
3cdc0 | 65 64 20 66 75 6e 63 74 69 6f 6e 20 64 6f 57 72 69 74 65 28 24 6d 65 73 73 61 67 65 2c 20 24 6e | ed.function.doWrite($message,.$n |
3cde0 | 65 77 6c 69 6e 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 62 75 66 | ewline).....{.........$this->buf |
3ce00 | 66 65 72 20 2e 3d 20 24 6d 65 73 73 61 67 65 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 6e | fer..=.$message;..........if.($n |
3ce20 | 65 77 6c 69 6e 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 62 75 66 | ewline).{.............$this->buf |
3ce40 | 66 65 72 20 2e 3d 20 22 5c 6e 22 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 7d 0a 3c | fer..=."\n";.........}.....}.}.< |
3ce60 | 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 | ?php../*..*.This.file.is.part.of |
3ce80 | 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 | .the.Symfony.package...*..*.(c). |
3cea0 | 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 | Fabien.Potencier.<fabien@symfony |
3cec0 | 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 | .com>..*..*.For.the.full.copyrig |
3cee0 | 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 | ht.and.license.information,.plea |
3cf00 | 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 | se.view.the.LICENSE..*.file.that |
3cf20 | 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 | .was.distributed.with.this.sourc |
3cf40 | 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 | e.code...*/..namespace.Symfony\C |
3cf60 | 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 4f 75 74 70 75 74 3b 0a 0a 75 73 65 20 53 79 | omponent\Console\Output;..use.Sy |
3cf80 | 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 46 6f 72 6d 61 74 74 65 | mfony\Component\Console\Formatte |
3cfa0 | 72 5c 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 | r\OutputFormatter;.use.Symfony\C |
3cfc0 | 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 46 6f 72 6d 61 74 74 65 72 5c 4f 75 74 70 75 | omponent\Console\Formatter\Outpu |
3cfe0 | 74 46 6f 72 6d 61 74 74 65 72 49 6e 74 65 72 66 61 63 65 3b 0a 0a 2f 2a 2a 0a 20 2a 20 4e 75 6c | tFormatterInterface;../**..*.Nul |
3d000 | 6c 4f 75 74 70 75 74 20 73 75 70 70 72 65 73 73 65 73 20 61 6c 6c 20 6f 75 74 70 75 74 2e 0a 20 | lOutput.suppresses.all.output... |
3d020 | 2a 0a 20 2a 20 20 20 20 20 24 6f 75 74 70 75 74 20 3d 20 6e 65 77 20 4e 75 6c 6c 4f 75 74 70 75 | *..*.....$output.=.new.NullOutpu |
3d040 | 74 28 29 3b 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 | t();..*..*.@author.Fabien.Potenc |
3d060 | 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 20 40 61 75 74 | ier.<fabien@symfony.com>..*.@aut |
3d080 | 68 6f 72 20 54 6f 62 69 61 73 20 53 63 68 75 6c 74 7a 65 20 3c 68 74 74 70 3a 2f 2f 74 6f 62 69 | hor.Tobias.Schultze.<http://tobi |
3d0a0 | 6f 6e 2e 64 65 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 4e 75 6c 6c 4f 75 74 70 75 74 20 69 6d 70 6c | on.de>..*/.class.NullOutput.impl |
3d0c0 | 65 6d 65 6e 74 73 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 0a 7b 0a 20 20 20 20 2f 2a 2a | ements.OutputInterface.{...../** |
3d0e0 | 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 | ......*.{@inheritdoc}......*/... |
3d100 | 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 46 6f 72 6d 61 74 74 65 72 28 4f | ..public.function.setFormatter(O |
3d120 | 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 49 6e 74 65 72 66 61 63 65 20 24 66 6f 72 6d 61 74 74 | utputFormatterInterface.$formatt |
3d140 | 65 72 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 2f 2f 20 64 6f 20 6e 6f 74 68 69 6e 67 0a | er).....{.........//.do.nothing. |
3d160 | 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 | ....}....../**......*.{@inheritd |
3d180 | 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 | oc}......*/.....public.function. |
3d1a0 | 67 65 74 46 6f 72 6d 61 74 74 65 72 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 2f 2f 20 | getFormatter().....{.........//. |
3d1c0 | 74 6f 20 63 6f 6d 70 6c 79 20 77 69 74 68 20 74 68 65 20 69 6e 74 65 72 66 61 63 65 20 77 65 20 | to.comply.with.the.interface.we. |
3d1e0 | 6d 75 73 74 20 72 65 74 75 72 6e 20 61 20 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 49 6e 74 | must.return.a.OutputFormatterInt |
3d200 | 65 72 66 61 63 65 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6e 65 77 20 4f 75 74 70 75 74 | erface.........return.new.Output |
3d220 | 46 6f 72 6d 61 74 74 65 72 28 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 | Formatter();.....}....../**..... |
3d240 | 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 | .*.{@inheritdoc}......*/.....pub |
3d260 | 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 44 65 63 6f 72 61 74 65 64 28 24 64 65 63 6f 72 | lic.function.setDecorated($decor |
3d280 | 61 74 65 64 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 2f 2f 20 64 6f 20 6e 6f 74 68 69 6e | ated).....{.........//.do.nothin |
3d2a0 | 67 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 | g.....}....../**......*.{@inheri |
3d2c0 | 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f | tdoc}......*/.....public.functio |
3d2e0 | 6e 20 69 73 44 65 63 6f 72 61 74 65 64 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 | n.isDecorated().....{.........re |
3d300 | 74 75 72 6e 20 66 61 6c 73 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 | turn.false;.....}....../**...... |
3d320 | 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c | *.{@inheritdoc}......*/.....publ |
3d340 | 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 56 65 72 62 6f 73 69 74 79 28 24 6c 65 76 65 6c 29 | ic.function.setVerbosity($level) |
3d360 | 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 2f 2f 20 64 6f 20 6e 6f 74 68 69 6e 67 0a 20 20 20 | .....{.........//.do.nothing.... |
3d380 | 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d | .}....../**......*.{@inheritdoc} |
3d3a0 | 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 | ......*/.....public.function.get |
3d3c0 | 56 65 72 62 6f 73 69 74 79 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e | Verbosity().....{.........return |
3d3e0 | 20 73 65 6c 66 3a 3a 56 45 52 42 4f 53 49 54 59 5f 51 55 49 45 54 3b 0a 20 20 20 20 7d 0a 0a 20 | .self::VERBOSITY_QUIET;.....}... |
3d400 | 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 | .../**......*.{@inheritdoc}..... |
3d420 | 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 69 73 51 75 69 65 74 28 | .*/.....public.function.isQuiet( |
3d440 | 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 74 72 75 65 3b 0a 20 20 20 | ).....{.........return.true;.... |
3d460 | 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d | .}....../**......*.{@inheritdoc} |
3d480 | 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 69 73 56 | ......*/.....public.function.isV |
3d4a0 | 65 72 62 6f 73 65 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 66 61 | erbose().....{.........return.fa |
3d4c0 | 6c 73 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 | lse;.....}....../**......*.{@inh |
3d4e0 | 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 | eritdoc}......*/.....public.func |
3d500 | 74 69 6f 6e 20 69 73 56 65 72 79 56 65 72 62 6f 73 65 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 | tion.isVeryVerbose().....{...... |
3d520 | 20 20 20 72 65 74 75 72 6e 20 66 61 6c 73 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a | ...return.false;.....}....../**. |
3d540 | 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 | .....*.{@inheritdoc}......*/.... |
3d560 | 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 69 73 44 65 62 75 67 28 29 0a 20 20 20 20 7b | .public.function.isDebug().....{ |
3d580 | 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 66 61 6c 73 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 | .........return.false;.....}.... |
3d5a0 | 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 | ../**......*.{@inheritdoc}...... |
3d5c0 | 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 77 72 69 74 65 6c 6e 28 24 | */.....public.function.writeln($ |
3d5e0 | 6d 65 73 73 61 67 65 73 2c 20 24 6f 70 74 69 6f 6e 73 20 3d 20 73 65 6c 66 3a 3a 4f 55 54 50 55 | messages,.$options.=.self::OUTPU |
3d600 | 54 5f 4e 4f 52 4d 41 4c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 2f 2f 20 64 6f 20 6e 6f | T_NORMAL).....{.........//.do.no |
3d620 | 74 68 69 6e 67 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e | thing.....}....../**......*.{@in |
3d640 | 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e | heritdoc}......*/.....public.fun |
3d660 | 63 74 69 6f 6e 20 77 72 69 74 65 28 24 6d 65 73 73 61 67 65 73 2c 20 24 6e 65 77 6c 69 6e 65 20 | ction.write($messages,.$newline. |
3d680 | 3d 20 66 61 6c 73 65 2c 20 24 6f 70 74 69 6f 6e 73 20 3d 20 73 65 6c 66 3a 3a 4f 55 54 50 55 54 | =.false,.$options.=.self::OUTPUT |
3d6a0 | 5f 4e 4f 52 4d 41 4c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 2f 2f 20 64 6f 20 6e 6f 74 | _NORMAL).....{.........//.do.not |
3d6c0 | 68 69 6e 67 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 | hing.....}.}.<?php../*..*.This.f |
3d6e0 | 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 | ile.is.part.of.the.Symfony.packa |
3d700 | 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c | ge...*..*.(c).Fabien.Potencier.< |
3d720 | 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 | fabien@symfony.com>..*..*.For.th |
3d740 | 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 | e.full.copyright.and.license.inf |
3d760 | 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 | ormation,.please.view.the.LICENS |
3d780 | 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 | E..*.file.that.was.distributed.w |
3d7a0 | 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 | ith.this.source.code...*/..names |
3d7c0 | 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 4f | pace.Symfony\Component\Console\O |
3d7e0 | 75 74 70 75 74 3b 0a 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f | utput;..use.Symfony\Component\Co |
3d800 | 6e 73 6f 6c 65 5c 46 6f 72 6d 61 74 74 65 72 5c 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 49 | nsole\Formatter\OutputFormatterI |
3d820 | 6e 74 65 72 66 61 63 65 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c | nterface;.use.Symfony\Component\ |
3d840 | 43 6f 6e 73 6f 6c 65 5c 46 6f 72 6d 61 74 74 65 72 5c 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 | Console\Formatter\OutputFormatte |
3d860 | 72 3b 0a 0a 2f 2a 2a 0a 20 2a 20 42 61 73 65 20 63 6c 61 73 73 20 66 6f 72 20 6f 75 74 70 75 74 | r;../**..*.Base.class.for.output |
3d880 | 20 63 6c 61 73 73 65 73 2e 0a 20 2a 0a 20 2a 20 54 68 65 72 65 20 61 72 65 20 66 69 76 65 20 6c | .classes...*..*.There.are.five.l |
3d8a0 | 65 76 65 6c 73 20 6f 66 20 76 65 72 62 6f 73 69 74 79 3a 0a 20 2a 0a 20 2a 20 20 2a 20 6e 6f 72 | evels.of.verbosity:..*..*..*.nor |
3d8c0 | 6d 61 6c 3a 20 6e 6f 20 6f 70 74 69 6f 6e 20 70 61 73 73 65 64 20 28 6e 6f 72 6d 61 6c 20 6f 75 | mal:.no.option.passed.(normal.ou |
3d8e0 | 74 70 75 74 29 0a 20 2a 20 20 2a 20 76 65 72 62 6f 73 65 3a 20 2d 76 20 28 6d 6f 72 65 20 6f 75 | tput)..*..*.verbose:.-v.(more.ou |
3d900 | 74 70 75 74 29 0a 20 2a 20 20 2a 20 76 65 72 79 20 76 65 72 62 6f 73 65 3a 20 2d 76 76 20 28 68 | tput)..*..*.very.verbose:.-vv.(h |
3d920 | 69 67 68 6c 79 20 65 78 74 65 6e 64 65 64 20 6f 75 74 70 75 74 29 0a 20 2a 20 20 2a 20 64 65 62 | ighly.extended.output)..*..*.deb |
3d940 | 75 67 3a 20 2d 76 76 76 20 28 61 6c 6c 20 64 65 62 75 67 20 6f 75 74 70 75 74 29 0a 20 2a 20 20 | ug:.-vvv.(all.debug.output)..*.. |
3d960 | 2a 20 71 75 69 65 74 3a 20 2d 71 20 28 6e 6f 20 6f 75 74 70 75 74 29 0a 20 2a 0a 20 2a 20 40 61 | *.quiet:.-q.(no.output)..*..*.@a |
3d980 | 75 74 68 6f 72 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 | uthor.Fabien.Potencier.<fabien@s |
3d9a0 | 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 2f 0a 61 62 73 74 72 61 63 74 20 63 6c 61 73 73 20 4f | ymfony.com>..*/.abstract.class.O |
3d9c0 | 75 74 70 75 74 20 69 6d 70 6c 65 6d 65 6e 74 73 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 | utput.implements.OutputInterface |
3d9e0 | 0a 7b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 76 65 72 62 6f 73 69 74 79 3b 0a 20 20 20 20 70 | .{.....private.$verbosity;.....p |
3da00 | 72 69 76 61 74 65 20 24 66 6f 72 6d 61 74 74 65 72 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 | rivate.$formatter;....../**..... |
3da20 | 20 2a 20 43 6f 6e 73 74 72 75 63 74 6f 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 | .*.Constructor.......*......*.@p |
3da40 | 61 72 61 6d 20 69 6e 74 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | aram.int........................ |
3da60 | 20 20 20 24 76 65 72 62 6f 73 69 74 79 20 54 68 65 20 76 65 72 62 6f 73 69 74 79 20 6c 65 76 65 | ...$verbosity.The.verbosity.leve |
3da80 | 6c 20 28 6f 6e 65 20 6f 66 20 74 68 65 20 56 45 52 42 4f 53 49 54 59 20 63 6f 6e 73 74 61 6e 74 | l.(one.of.the.VERBOSITY.constant |
3daa0 | 73 20 69 6e 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 29 0a 20 20 20 20 20 2a 20 40 70 61 | s.in.OutputInterface)......*.@pa |
3dac0 | 72 61 6d 20 62 6f 6f 6c 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ram.bool........................ |
3dae0 | 20 20 24 64 65 63 6f 72 61 74 65 64 20 57 68 65 74 68 65 72 20 74 6f 20 64 65 63 6f 72 61 74 65 | ..$decorated.Whether.to.decorate |
3db00 | 20 6d 65 73 73 61 67 65 73 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 4f 75 74 70 75 74 46 6f | .messages......*.@param.OutputFo |
3db20 | 72 6d 61 74 74 65 72 49 6e 74 65 72 66 61 63 65 7c 6e 75 6c 6c 20 24 66 6f 72 6d 61 74 74 65 72 | rmatterInterface|null.$formatter |
3db40 | 20 4f 75 74 70 75 74 20 66 6f 72 6d 61 74 74 65 72 20 69 6e 73 74 61 6e 63 65 20 28 6e 75 6c 6c | .Output.formatter.instance.(null |
3db60 | 20 74 6f 20 75 73 65 20 64 65 66 61 75 6c 74 20 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 29 | .to.use.default.OutputFormatter) |
3db80 | 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 63 | ......*/.....public.function.__c |
3dba0 | 6f 6e 73 74 72 75 63 74 28 24 76 65 72 62 6f 73 69 74 79 20 3d 20 73 65 6c 66 3a 3a 56 45 52 42 | onstruct($verbosity.=.self::VERB |
3dbc0 | 4f 53 49 54 59 5f 4e 4f 52 4d 41 4c 2c 20 24 64 65 63 6f 72 61 74 65 64 20 3d 20 66 61 6c 73 65 | OSITY_NORMAL,.$decorated.=.false |
3dbe0 | 2c 20 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 49 6e 74 65 72 66 61 63 65 20 24 66 6f 72 6d | ,.OutputFormatterInterface.$form |
3dc00 | 61 74 74 65 72 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 | atter.=.null).....{.........$thi |
3dc20 | 73 2d 3e 76 65 72 62 6f 73 69 74 79 20 3d 20 6e 75 6c 6c 20 3d 3d 3d 20 24 76 65 72 62 6f 73 69 | s->verbosity.=.null.===.$verbosi |
3dc40 | 74 79 20 3f 20 73 65 6c 66 3a 3a 56 45 52 42 4f 53 49 54 59 5f 4e 4f 52 4d 41 4c 20 3a 20 24 76 | ty.?.self::VERBOSITY_NORMAL.:.$v |
3dc60 | 65 72 62 6f 73 69 74 79 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 66 6f 72 6d 61 74 74 | erbosity;.........$this->formatt |
3dc80 | 65 72 20 3d 20 24 66 6f 72 6d 61 74 74 65 72 20 3f 3a 20 6e 65 77 20 4f 75 74 70 75 74 46 6f 72 | er.=.$formatter.?:.new.OutputFor |
3dca0 | 6d 61 74 74 65 72 28 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 66 6f 72 6d 61 74 74 | matter();.........$this->formatt |
3dcc0 | 65 72 2d 3e 73 65 74 44 65 63 6f 72 61 74 65 64 28 24 64 65 63 6f 72 61 74 65 64 29 3b 0a 20 20 | er->setDecorated($decorated);... |
3dce0 | 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 | ..}....../**......*.{@inheritdoc |
3dd00 | 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 | }......*/.....public.function.se |
3dd20 | 74 46 6f 72 6d 61 74 74 65 72 28 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 49 6e 74 65 72 66 | tFormatter(OutputFormatterInterf |
3dd40 | 61 63 65 20 24 66 6f 72 6d 61 74 74 65 72 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 | ace.$formatter).....{.........$t |
3dd60 | 68 69 73 2d 3e 66 6f 72 6d 61 74 74 65 72 20 3d 20 24 66 6f 72 6d 61 74 74 65 72 3b 0a 20 20 20 | his->formatter.=.$formatter;.... |
3dd80 | 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d | .}....../**......*.{@inheritdoc} |
3dda0 | 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 | ......*/.....public.function.get |
3ddc0 | 46 6f 72 6d 61 74 74 65 72 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e | Formatter().....{.........return |
3dde0 | 20 24 74 68 69 73 2d 3e 66 6f 72 6d 61 74 74 65 72 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a | .$this->formatter;.....}....../* |
3de00 | 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 | *......*.{@inheritdoc}......*/.. |
3de20 | 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 44 65 63 6f 72 61 74 65 64 28 | ...public.function.setDecorated( |
3de40 | 24 64 65 63 6f 72 61 74 65 64 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d | $decorated).....{.........$this- |
3de60 | 3e 66 6f 72 6d 61 74 74 65 72 2d 3e 73 65 74 44 65 63 6f 72 61 74 65 64 28 24 64 65 63 6f 72 61 | >formatter->setDecorated($decora |
3de80 | 74 65 64 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e | ted);.....}....../**......*.{@in |
3dea0 | 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e | heritdoc}......*/.....public.fun |
3dec0 | 63 74 69 6f 6e 20 69 73 44 65 63 6f 72 61 74 65 64 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 | ction.isDecorated().....{....... |
3dee0 | 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 66 6f 72 6d 61 74 74 65 72 2d 3e 69 73 44 65 63 | ..return.$this->formatter->isDec |
3df00 | 6f 72 61 74 65 64 28 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 | orated();.....}....../**......*. |
3df20 | 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 | {@inheritdoc}......*/.....public |
3df40 | 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 56 65 72 62 6f 73 69 74 79 28 24 6c 65 76 65 6c 29 0a 20 | .function.setVerbosity($level).. |
3df60 | 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 76 65 72 62 6f 73 69 74 79 20 3d 20 | ...{.........$this->verbosity.=. |
3df80 | 28 69 6e 74 29 20 24 6c 65 76 65 6c 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 | (int).$level;.....}....../**.... |
3dfa0 | 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 | ..*.{@inheritdoc}......*/.....pu |
3dfc0 | 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 56 65 72 62 6f 73 69 74 79 28 29 0a 20 20 20 | blic.function.getVerbosity().... |
3dfe0 | 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 76 65 72 62 6f 73 69 | .{.........return.$this->verbosi |
3e000 | 74 79 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 | ty;.....}....../**......*.{@inhe |
3e020 | 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 | ritdoc}......*/.....public.funct |
3e040 | 69 6f 6e 20 69 73 51 75 69 65 74 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 | ion.isQuiet().....{.........retu |
3e060 | 72 6e 20 73 65 6c 66 3a 3a 56 45 52 42 4f 53 49 54 59 5f 51 55 49 45 54 20 3d 3d 3d 20 24 74 68 | rn.self::VERBOSITY_QUIET.===.$th |
3e080 | 69 73 2d 3e 76 65 72 62 6f 73 69 74 79 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 | is->verbosity;.....}....../**... |
3e0a0 | 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 | ...*.{@inheritdoc}......*/.....p |
3e0c0 | 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 69 73 56 65 72 62 6f 73 65 28 29 0a 20 20 20 20 7b | ublic.function.isVerbose().....{ |
3e0e0 | 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 3a 3a 56 45 52 42 4f 53 49 54 59 5f | .........return.self::VERBOSITY_ |
3e100 | 56 45 52 42 4f 53 45 20 3c 3d 20 24 74 68 69 73 2d 3e 76 65 72 62 6f 73 69 74 79 3b 0a 20 20 20 | VERBOSE.<=.$this->verbosity;.... |
3e120 | 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d | .}....../**......*.{@inheritdoc} |
3e140 | 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 69 73 56 | ......*/.....public.function.isV |
3e160 | 65 72 79 56 65 72 62 6f 73 65 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 | eryVerbose().....{.........retur |
3e180 | 6e 20 73 65 6c 66 3a 3a 56 45 52 42 4f 53 49 54 59 5f 56 45 52 59 5f 56 45 52 42 4f 53 45 20 3c | n.self::VERBOSITY_VERY_VERBOSE.< |
3e1a0 | 3d 20 24 74 68 69 73 2d 3e 76 65 72 62 6f 73 69 74 79 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f | =.$this->verbosity;.....}....../ |
3e1c0 | 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a | **......*.{@inheritdoc}......*/. |
3e1e0 | 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 69 73 44 65 62 75 67 28 29 0a 20 20 | ....public.function.isDebug()... |
3e200 | 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 3a 3a 56 45 52 42 4f 53 49 | ..{.........return.self::VERBOSI |
3e220 | 54 59 5f 44 45 42 55 47 20 3c 3d 20 24 74 68 69 73 2d 3e 76 65 72 62 6f 73 69 74 79 3b 0a 20 20 | TY_DEBUG.<=.$this->verbosity;... |
3e240 | 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 | ..}....../**......*.{@inheritdoc |
3e260 | 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 77 72 | }......*/.....public.function.wr |
3e280 | 69 74 65 6c 6e 28 24 6d 65 73 73 61 67 65 73 2c 20 24 6f 70 74 69 6f 6e 73 20 3d 20 73 65 6c 66 | iteln($messages,.$options.=.self |
3e2a0 | 3a 3a 4f 55 54 50 55 54 5f 4e 4f 52 4d 41 4c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 | ::OUTPUT_NORMAL).....{.........$ |
3e2c0 | 74 68 69 73 2d 3e 77 72 69 74 65 28 24 6d 65 73 73 61 67 65 73 2c 20 74 72 75 65 2c 20 24 6f 70 | this->write($messages,.true,.$op |
3e2e0 | 74 69 6f 6e 73 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 | tions);.....}....../**......*.{@ |
3e300 | 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 | inheritdoc}......*/.....public.f |
3e320 | 75 6e 63 74 69 6f 6e 20 77 72 69 74 65 28 24 6d 65 73 73 61 67 65 73 2c 20 24 6e 65 77 6c 69 6e | unction.write($messages,.$newlin |
3e340 | 65 20 3d 20 66 61 6c 73 65 2c 20 24 6f 70 74 69 6f 6e 73 20 3d 20 73 65 6c 66 3a 3a 4f 55 54 50 | e.=.false,.$options.=.self::OUTP |
3e360 | 55 54 5f 4e 4f 52 4d 41 4c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 | UT_NORMAL).....{.........$messag |
3e380 | 65 73 20 3d 20 28 61 72 72 61 79 29 20 24 6d 65 73 73 61 67 65 73 3b 0a 0a 20 20 20 20 20 20 20 | es.=.(array).$messages;......... |
3e3a0 | 20 24 74 79 70 65 73 20 3d 20 73 65 6c 66 3a 3a 4f 55 54 50 55 54 5f 4e 4f 52 4d 41 4c 20 7c 20 | .$types.=.self::OUTPUT_NORMAL.|. |
3e3c0 | 73 65 6c 66 3a 3a 4f 55 54 50 55 54 5f 52 41 57 20 7c 20 73 65 6c 66 3a 3a 4f 55 54 50 55 54 5f | self::OUTPUT_RAW.|.self::OUTPUT_ |
3e3e0 | 50 4c 41 49 4e 3b 0a 20 20 20 20 20 20 20 20 24 74 79 70 65 20 3d 20 24 74 79 70 65 73 20 26 20 | PLAIN;.........$type.=.$types.&. |
3e400 | 24 6f 70 74 69 6f 6e 73 20 3f 3a 20 73 65 6c 66 3a 3a 4f 55 54 50 55 54 5f 4e 4f 52 4d 41 4c 3b | $options.?:.self::OUTPUT_NORMAL; |
3e420 | 0a 0a 20 20 20 20 20 20 20 20 24 76 65 72 62 6f 73 69 74 69 65 73 20 3d 20 73 65 6c 66 3a 3a 56 | ..........$verbosities.=.self::V |
3e440 | 45 52 42 4f 53 49 54 59 5f 51 55 49 45 54 20 7c 20 73 65 6c 66 3a 3a 56 45 52 42 4f 53 49 54 59 | ERBOSITY_QUIET.|.self::VERBOSITY |
3e460 | 5f 4e 4f 52 4d 41 4c 20 7c 20 73 65 6c 66 3a 3a 56 45 52 42 4f 53 49 54 59 5f 56 45 52 42 4f 53 | _NORMAL.|.self::VERBOSITY_VERBOS |
3e480 | 45 20 7c 20 73 65 6c 66 3a 3a 56 45 52 42 4f 53 49 54 59 5f 56 45 52 59 5f 56 45 52 42 4f 53 45 | E.|.self::VERBOSITY_VERY_VERBOSE |
3e4a0 | 20 7c 20 73 65 6c 66 3a 3a 56 45 52 42 4f 53 49 54 59 5f 44 45 42 55 47 3b 0a 20 20 20 20 20 20 | .|.self::VERBOSITY_DEBUG;....... |
3e4c0 | 20 20 24 76 65 72 62 6f 73 69 74 79 20 3d 20 24 76 65 72 62 6f 73 69 74 69 65 73 20 26 20 24 6f | ..$verbosity.=.$verbosities.&.$o |
3e4e0 | 70 74 69 6f 6e 73 20 3f 3a 20 73 65 6c 66 3a 3a 56 45 52 42 4f 53 49 54 59 5f 4e 4f 52 4d 41 4c | ptions.?:.self::VERBOSITY_NORMAL |
3e500 | 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 76 65 72 62 6f 73 69 74 79 20 3e 20 24 74 68 69 | ;..........if.($verbosity.>.$thi |
3e520 | 73 2d 3e 67 65 74 56 65 72 62 6f 73 69 74 79 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | s->getVerbosity()).{............ |
3e540 | 20 72 65 74 75 72 6e 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 66 6f 72 65 | .return;.........}..........fore |
3e560 | 61 63 68 20 28 24 6d 65 73 73 61 67 65 73 20 61 73 20 24 6d 65 73 73 61 67 65 29 20 7b 0a 20 20 | ach.($messages.as.$message).{... |
3e580 | 20 20 20 20 20 20 20 20 20 20 73 77 69 74 63 68 20 28 24 74 79 70 65 29 20 7b 0a 20 20 20 20 20 | ..........switch.($type).{...... |
3e5a0 | 20 20 20 20 20 20 20 20 20 20 20 63 61 73 65 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 3a | ...........case.OutputInterface: |
3e5c0 | 3a 4f 55 54 50 55 54 5f 4e 4f 52 4d 41 4c 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | :OUTPUT_NORMAL:................. |
3e5e0 | 20 20 20 20 24 6d 65 73 73 61 67 65 20 3d 20 24 74 68 69 73 2d 3e 66 6f 72 6d 61 74 74 65 72 2d | ....$message.=.$this->formatter- |
3e600 | 3e 66 6f 72 6d 61 74 28 24 6d 65 73 73 61 67 65 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | >format($message);.............. |
3e620 | 20 20 20 20 20 20 20 62 72 65 61 6b 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 63 61 | .......break;.................ca |
3e640 | 73 65 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 3a 3a 4f 55 54 50 55 54 5f 52 41 57 3a 0a | se.OutputInterface::OUTPUT_RAW:. |
3e660 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 62 72 65 61 6b 3b 0a 20 20 20 20 20 | ....................break;...... |
3e680 | 20 20 20 20 20 20 20 20 20 20 20 63 61 73 65 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 3a | ...........case.OutputInterface: |
3e6a0 | 3a 4f 55 54 50 55 54 5f 50 4c 41 49 4e 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | :OUTPUT_PLAIN:.................. |
3e6c0 | 20 20 20 24 6d 65 73 73 61 67 65 20 3d 20 73 74 72 69 70 5f 74 61 67 73 28 24 74 68 69 73 2d 3e | ...$message.=.strip_tags($this-> |
3e6e0 | 66 6f 72 6d 61 74 74 65 72 2d 3e 66 6f 72 6d 61 74 28 24 6d 65 73 73 61 67 65 29 29 3b 0a 20 20 | formatter->format($message));... |
3e700 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 62 72 65 61 6b 3b 0a 20 20 20 20 20 20 20 | ..................break;........ |
3e720 | 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 64 6f 57 72 69 | .....}..............$this->doWri |
3e740 | 74 65 28 24 6d 65 73 73 61 67 65 2c 20 24 6e 65 77 6c 69 6e 65 29 3b 0a 20 20 20 20 20 20 20 20 | te($message,.$newline);......... |
3e760 | 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 57 72 69 74 65 73 20 61 | }.....}....../**......*.Writes.a |
3e780 | 20 6d 65 73 73 61 67 65 20 74 6f 20 74 68 65 20 6f 75 74 70 75 74 2e 0a 20 20 20 20 20 2a 0a 20 | .message.to.the.output.......*.. |
3e7a0 | 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6d 65 73 73 61 67 65 20 41 20 6d | ....*.@param.string.$message.A.m |
3e7c0 | 65 73 73 61 67 65 20 74 6f 20 77 72 69 74 65 20 74 6f 20 74 68 65 20 6f 75 74 70 75 74 0a 20 20 | essage.to.write.to.the.output... |
3e7e0 | 20 20 20 2a 20 40 70 61 72 61 6d 20 62 6f 6f 6c 20 20 20 24 6e 65 77 6c 69 6e 65 20 57 68 65 74 | ...*.@param.bool...$newline.Whet |
3e800 | 68 65 72 20 74 6f 20 61 64 64 20 61 20 6e 65 77 6c 69 6e 65 20 6f 72 20 6e 6f 74 0a 20 20 20 20 | her.to.add.a.newline.or.not..... |
3e820 | 20 2a 2f 0a 20 20 20 20 61 62 73 74 72 61 63 74 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 | .*/.....abstract.protected.funct |
3e840 | 69 6f 6e 20 64 6f 57 72 69 74 65 28 24 6d 65 73 73 61 67 65 2c 20 24 6e 65 77 6c 69 6e 65 29 3b | ion.doWrite($message,.$newline); |
3e860 | 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 | .}.<?php../*..*.This.file.is.par |
3e880 | 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 | t.of.the.Symfony.package...*..*. |
3e8a0 | 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d | (c).Fabien.Potencier.<fabien@sym |
3e8c0 | 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 | fony.com>..*..*.For.the.full.cop |
3e8e0 | 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 | yright.and.license.information,. |
3e900 | 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 | please.view.the.LICENSE..*.file. |
3e920 | 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 | that.was.distributed.with.this.s |
3e940 | 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f | ource.code...*/..namespace.Symfo |
3e960 | 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 4f 75 74 70 75 74 3b 0a 0a 75 73 | ny\Component\Console\Output;..us |
3e980 | 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 46 6f 72 6d | e.Symfony\Component\Console\Form |
3e9a0 | 61 74 74 65 72 5c 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 49 6e 74 65 72 66 61 63 65 3b 0a | atter\OutputFormatterInterface;. |
3e9c0 | 0a 2f 2a 2a 0a 20 2a 20 43 6f 6e 73 6f 6c 65 4f 75 74 70 75 74 20 69 73 20 74 68 65 20 64 65 66 | ./**..*.ConsoleOutput.is.the.def |
3e9e0 | 61 75 6c 74 20 63 6c 61 73 73 20 66 6f 72 20 61 6c 6c 20 43 4c 49 20 6f 75 74 70 75 74 2e 20 49 | ault.class.for.all.CLI.output..I |
3ea00 | 74 20 75 73 65 73 20 53 54 44 4f 55 54 20 61 6e 64 20 53 54 44 45 52 52 2e 0a 20 2a 0a 20 2a 20 | t.uses.STDOUT.and.STDERR...*..*. |
3ea20 | 54 68 69 73 20 63 6c 61 73 73 20 69 73 20 61 20 63 6f 6e 76 65 6e 69 65 6e 74 20 77 72 61 70 70 | This.class.is.a.convenient.wrapp |
3ea40 | 65 72 20 61 72 6f 75 6e 64 20 60 53 74 72 65 61 6d 4f 75 74 70 75 74 60 20 66 6f 72 20 62 6f 74 | er.around.`StreamOutput`.for.bot |
3ea60 | 68 20 53 54 44 4f 55 54 20 61 6e 64 20 53 54 44 45 52 52 2e 0a 20 2a 0a 20 2a 20 20 20 20 20 24 | h.STDOUT.and.STDERR...*..*.....$ |
3ea80 | 6f 75 74 70 75 74 20 3d 20 6e 65 77 20 43 6f 6e 73 6f 6c 65 4f 75 74 70 75 74 28 29 3b 0a 20 2a | output.=.new.ConsoleOutput();..* |
3eaa0 | 0a 20 2a 20 54 68 69 73 20 69 73 20 65 71 75 69 76 61 6c 65 6e 74 20 74 6f 3a 0a 20 2a 0a 20 2a | ..*.This.is.equivalent.to:..*..* |
3eac0 | 20 20 20 20 20 24 6f 75 74 70 75 74 20 3d 20 6e 65 77 20 53 74 72 65 61 6d 4f 75 74 70 75 74 28 | .....$output.=.new.StreamOutput( |
3eae0 | 66 6f 70 65 6e 28 27 70 68 70 3a 2f 2f 73 74 64 6f 75 74 27 2c 20 27 77 27 29 29 3b 0a 20 2a 20 | fopen('php://stdout',.'w'));..*. |
3eb00 | 20 20 20 20 24 73 74 64 45 72 72 20 3d 20 6e 65 77 20 53 74 72 65 61 6d 4f 75 74 70 75 74 28 66 | ....$stdErr.=.new.StreamOutput(f |
3eb20 | 6f 70 65 6e 28 27 70 68 70 3a 2f 2f 73 74 64 65 72 72 27 2c 20 27 77 27 29 29 3b 0a 20 2a 0a 20 | open('php://stderr',.'w'));..*.. |
3eb40 | 2a 20 40 61 75 74 68 6f 72 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 | *.@author.Fabien.Potencier.<fabi |
3eb60 | 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 43 6f 6e 73 6f 6c | en@symfony.com>..*/.class.Consol |
3eb80 | 65 4f 75 74 70 75 74 20 65 78 74 65 6e 64 73 20 53 74 72 65 61 6d 4f 75 74 70 75 74 20 69 6d 70 | eOutput.extends.StreamOutput.imp |
3eba0 | 6c 65 6d 65 6e 74 73 20 43 6f 6e 73 6f 6c 65 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 0a 7b | lements.ConsoleOutputInterface.{ |
3ebc0 | 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 76 61 72 20 53 74 72 65 61 6d 4f 75 74 70 75 | ...../**......*.@var.StreamOutpu |
3ebe0 | 74 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 73 74 64 65 72 72 3b 0a 0a | t......*/.....private.$stderr;.. |
3ec00 | 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 43 6f 6e 73 74 72 75 63 74 6f 72 2e 0a 20 20 20 20 | ..../**......*.Constructor...... |
3ec20 | 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 69 6e 74 20 20 20 20 20 20 20 20 20 20 20 20 | .*......*.@param.int............ |
3ec40 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 76 65 72 62 6f 73 69 74 79 20 54 68 65 20 76 65 | ...............$verbosity.The.ve |
3ec60 | 72 62 6f 73 69 74 79 20 6c 65 76 65 6c 20 28 6f 6e 65 20 6f 66 20 74 68 65 20 56 45 52 42 4f 53 | rbosity.level.(one.of.the.VERBOS |
3ec80 | 49 54 59 20 63 6f 6e 73 74 61 6e 74 73 20 69 6e 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 | ITY.constants.in.OutputInterface |
3eca0 | 29 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 62 6f 6f 6c 7c 6e 75 6c 6c 20 20 20 20 20 20 20 | )......*.@param.bool|null....... |
3ecc0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 64 65 63 6f 72 61 74 65 64 20 57 68 65 74 68 65 72 | ..............$decorated.Whether |
3ece0 | 20 74 6f 20 64 65 63 6f 72 61 74 65 20 6d 65 73 73 61 67 65 73 20 28 6e 75 6c 6c 20 66 6f 72 20 | .to.decorate.messages.(null.for. |
3ed00 | 61 75 74 6f 2d 67 75 65 73 73 69 6e 67 29 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 4f 75 74 | auto-guessing)......*.@param.Out |
3ed20 | 70 75 74 46 6f 72 6d 61 74 74 65 72 49 6e 74 65 72 66 61 63 65 7c 6e 75 6c 6c 20 24 66 6f 72 6d | putFormatterInterface|null.$form |
3ed40 | 61 74 74 65 72 20 4f 75 74 70 75 74 20 66 6f 72 6d 61 74 74 65 72 20 69 6e 73 74 61 6e 63 65 20 | atter.Output.formatter.instance. |
3ed60 | 28 6e 75 6c 6c 20 74 6f 20 75 73 65 20 64 65 66 61 75 6c 74 20 4f 75 74 70 75 74 46 6f 72 6d 61 | (null.to.use.default.OutputForma |
3ed80 | 74 74 65 72 29 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f | tter)......*/.....public.functio |
3eda0 | 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 74 28 24 76 65 72 62 6f 73 69 74 79 20 3d 20 73 65 6c 66 3a | n.__construct($verbosity.=.self: |
3edc0 | 3a 56 45 52 42 4f 53 49 54 59 5f 4e 4f 52 4d 41 4c 2c 20 24 64 65 63 6f 72 61 74 65 64 20 3d 20 | :VERBOSITY_NORMAL,.$decorated.=. |
3ede0 | 6e 75 6c 6c 2c 20 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 49 6e 74 65 72 66 61 63 65 20 24 | null,.OutputFormatterInterface.$ |
3ee00 | 66 6f 72 6d 61 74 74 65 72 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | formatter.=.null).....{......... |
3ee20 | 70 61 72 65 6e 74 3a 3a 5f 5f 63 6f 6e 73 74 72 75 63 74 28 24 74 68 69 73 2d 3e 6f 70 65 6e 4f | parent::__construct($this->openO |
3ee40 | 75 74 70 75 74 53 74 72 65 61 6d 28 29 2c 20 24 76 65 72 62 6f 73 69 74 79 2c 20 24 64 65 63 6f | utputStream(),.$verbosity,.$deco |
3ee60 | 72 61 74 65 64 2c 20 24 66 6f 72 6d 61 74 74 65 72 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 61 63 | rated,.$formatter);..........$ac |
3ee80 | 74 75 61 6c 44 65 63 6f 72 61 74 65 64 20 3d 20 24 74 68 69 73 2d 3e 69 73 44 65 63 6f 72 61 74 | tualDecorated.=.$this->isDecorat |
3eea0 | 65 64 28 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 74 64 65 72 72 20 3d 20 6e 65 | ed();.........$this->stderr.=.ne |
3eec0 | 77 20 53 74 72 65 61 6d 4f 75 74 70 75 74 28 24 74 68 69 73 2d 3e 6f 70 65 6e 45 72 72 6f 72 53 | w.StreamOutput($this->openErrorS |
3eee0 | 74 72 65 61 6d 28 29 2c 20 24 76 65 72 62 6f 73 69 74 79 2c 20 24 64 65 63 6f 72 61 74 65 64 2c | tream(),.$verbosity,.$decorated, |
3ef00 | 20 24 74 68 69 73 2d 3e 67 65 74 46 6f 72 6d 61 74 74 65 72 28 29 29 3b 0a 0a 20 20 20 20 20 20 | .$this->getFormatter());........ |
3ef20 | 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 64 65 63 6f 72 61 74 65 64 29 20 7b 0a 20 20 20 | ..if.(null.===.$decorated).{.... |
3ef40 | 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 65 74 44 65 63 6f 72 61 74 65 64 28 24 61 63 | .........$this->setDecorated($ac |
3ef60 | 74 75 61 6c 44 65 63 6f 72 61 74 65 64 20 26 26 20 24 74 68 69 73 2d 3e 73 74 64 65 72 72 2d 3e | tualDecorated.&&.$this->stderr-> |
3ef80 | 69 73 44 65 63 6f 72 61 74 65 64 28 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a | isDecorated());.........}.....}. |
3efa0 | 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 | ...../**......*.{@inheritdoc}... |
3efc0 | 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 44 65 63 | ...*/.....public.function.setDec |
3efe0 | 6f 72 61 74 65 64 28 24 64 65 63 6f 72 61 74 65 64 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 | orated($decorated).....{........ |
3f000 | 20 70 61 72 65 6e 74 3a 3a 73 65 74 44 65 63 6f 72 61 74 65 64 28 24 64 65 63 6f 72 61 74 65 64 | .parent::setDecorated($decorated |
3f020 | 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 74 64 65 72 72 2d 3e 73 65 74 44 65 63 | );.........$this->stderr->setDec |
3f040 | 6f 72 61 74 65 64 28 24 64 65 63 6f 72 61 74 65 64 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f | orated($decorated);.....}....../ |
3f060 | 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a | **......*.{@inheritdoc}......*/. |
3f080 | 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 46 6f 72 6d 61 74 74 65 72 | ....public.function.setFormatter |
3f0a0 | 28 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 49 6e 74 65 72 66 61 63 65 20 24 66 6f 72 6d 61 | (OutputFormatterInterface.$forma |
3f0c0 | 74 74 65 72 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 70 61 72 65 6e 74 3a 3a 73 65 74 46 | tter).....{.........parent::setF |
3f0e0 | 6f 72 6d 61 74 74 65 72 28 24 66 6f 72 6d 61 74 74 65 72 29 3b 0a 20 20 20 20 20 20 20 20 24 74 | ormatter($formatter);.........$t |
3f100 | 68 69 73 2d 3e 73 74 64 65 72 72 2d 3e 73 65 74 46 6f 72 6d 61 74 74 65 72 28 24 66 6f 72 6d 61 | his->stderr->setFormatter($forma |
3f120 | 74 74 65 72 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 | tter);.....}....../**......*.{@i |
3f140 | 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 | nheritdoc}......*/.....public.fu |
3f160 | 6e 63 74 69 6f 6e 20 73 65 74 56 65 72 62 6f 73 69 74 79 28 24 6c 65 76 65 6c 29 0a 20 20 20 20 | nction.setVerbosity($level)..... |
3f180 | 7b 0a 20 20 20 20 20 20 20 20 70 61 72 65 6e 74 3a 3a 73 65 74 56 65 72 62 6f 73 69 74 79 28 24 | {.........parent::setVerbosity($ |
3f1a0 | 6c 65 76 65 6c 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 74 64 65 72 72 2d 3e 73 | level);.........$this->stderr->s |
3f1c0 | 65 74 56 65 72 62 6f 73 69 74 79 28 24 6c 65 76 65 6c 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 | etVerbosity($level);.....}...... |
3f1e0 | 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f | /**......*.{@inheritdoc}......*/ |
3f200 | 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 45 72 72 6f 72 4f 75 74 | .....public.function.getErrorOut |
3f220 | 70 75 74 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 | put().....{.........return.$this |
3f240 | 2d 3e 73 74 64 65 72 72 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 | ->stderr;.....}....../**......*. |
3f260 | 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 | {@inheritdoc}......*/.....public |
3f280 | 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 45 72 72 6f 72 4f 75 74 70 75 74 28 4f 75 74 70 75 74 49 | .function.setErrorOutput(OutputI |
3f2a0 | 6e 74 65 72 66 61 63 65 20 24 65 72 72 6f 72 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 | nterface.$error).....{.........$ |
3f2c0 | 74 68 69 73 2d 3e 73 74 64 65 72 72 20 3d 20 24 65 72 72 6f 72 3b 0a 20 20 20 20 7d 0a 0a 20 20 | this->stderr.=.$error;.....}.... |
3f2e0 | 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 74 72 75 65 20 69 66 20 63 75 72 | ../**......*.Returns.true.if.cur |
3f300 | 72 65 6e 74 20 65 6e 76 69 72 6f 6e 6d 65 6e 74 20 73 75 70 70 6f 72 74 73 20 77 72 69 74 69 6e | rent.environment.supports.writin |
3f320 | 67 20 63 6f 6e 73 6f 6c 65 20 6f 75 74 70 75 74 20 74 6f 0a 20 20 20 20 20 2a 20 53 54 44 4f 55 | g.console.output.to......*.STDOU |
3f340 | 54 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 62 6f 6f 6c 0a 20 20 | T.......*......*.@return.bool... |
3f360 | 20 20 20 2a 2f 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 68 61 73 | ...*/.....protected.function.has |
3f380 | 53 74 64 6f 75 74 53 75 70 70 6f 72 74 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 | StdoutSupport().....{.........re |
3f3a0 | 74 75 72 6e 20 66 61 6c 73 65 20 3d 3d 3d 20 24 74 68 69 73 2d 3e 69 73 52 75 6e 6e 69 6e 67 4f | turn.false.===.$this->isRunningO |
3f3c0 | 53 34 30 30 28 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 | S400();.....}....../**......*.Re |
3f3e0 | 74 75 72 6e 73 20 74 72 75 65 20 69 66 20 63 75 72 72 65 6e 74 20 65 6e 76 69 72 6f 6e 6d 65 6e | turns.true.if.current.environmen |
3f400 | 74 20 73 75 70 70 6f 72 74 73 20 77 72 69 74 69 6e 67 20 63 6f 6e 73 6f 6c 65 20 6f 75 74 70 75 | t.supports.writing.console.outpu |
3f420 | 74 20 74 6f 0a 20 20 20 20 20 2a 20 53 54 44 45 52 52 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 | t.to......*.STDERR.......*...... |
3f440 | 2a 20 40 72 65 74 75 72 6e 20 62 6f 6f 6c 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 6f 74 65 | *.@return.bool......*/.....prote |
3f460 | 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 68 61 73 53 74 64 65 72 72 53 75 70 70 6f 72 74 28 29 | cted.function.hasStderrSupport() |
3f480 | 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 66 61 6c 73 65 20 3d 3d 3d 20 | .....{.........return.false.===. |
3f4a0 | 24 74 68 69 73 2d 3e 69 73 52 75 6e 6e 69 6e 67 4f 53 34 30 30 28 29 3b 0a 20 20 20 20 7d 0a 0a | $this->isRunningOS400();.....}.. |
3f4c0 | 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 43 68 65 63 6b 73 20 69 66 20 63 75 72 72 65 6e 74 | ..../**......*.Checks.if.current |
3f4e0 | 20 65 78 65 63 75 74 69 6e 67 20 65 6e 76 69 72 6f 6e 6d 65 6e 74 20 69 73 20 49 42 4d 20 69 53 | .executing.environment.is.IBM.iS |
3f500 | 65 72 69 65 73 20 28 4f 53 34 30 30 29 2c 20 77 68 69 63 68 0a 20 20 20 20 20 2a 20 64 6f 65 73 | eries.(OS400),.which......*.does |
3f520 | 6e 27 74 20 70 72 6f 70 65 72 6c 79 20 63 6f 6e 76 65 72 74 20 63 68 61 72 61 63 74 65 72 2d 65 | n't.properly.convert.character-e |
3f540 | 6e 63 6f 64 69 6e 67 73 20 62 65 74 77 65 65 6e 20 41 53 43 49 49 20 74 6f 20 45 42 43 44 49 43 | ncodings.between.ASCII.to.EBCDIC |
3f560 | 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 62 6f 6f 6c 0a 20 20 20 | .......*......*.@return.bool.... |
3f580 | 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 69 73 52 75 6e 6e | ..*/.....private.function.isRunn |
3f5a0 | 69 6e 67 4f 53 34 30 30 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 63 68 65 63 6b 73 | ingOS400().....{.........$checks |
3f5c0 | 20 3d 20 61 72 72 61 79 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 66 75 6e 63 74 69 6f 6e 5f 65 | .=.array(.............function_e |
3f5e0 | 78 69 73 74 73 28 27 70 68 70 5f 75 6e 61 6d 65 27 29 20 3f 20 70 68 70 5f 75 6e 61 6d 65 28 27 | xists('php_uname').?.php_uname(' |
3f600 | 73 27 29 20 3a 20 27 27 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 67 65 74 65 6e 76 28 27 4f 53 | s').:.'',.............getenv('OS |
3f620 | 54 59 50 45 27 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 50 48 50 5f 4f 53 2c 0a 20 20 20 20 | TYPE'),.............PHP_OS,..... |
3f640 | 20 20 20 20 29 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 66 61 6c 73 65 20 21 3d 3d | ....);..........return.false.!== |
3f660 | 20 73 74 72 69 70 6f 73 28 69 6d 70 6c 6f 64 65 28 27 3b 27 2c 20 24 63 68 65 63 6b 73 29 2c 20 | .stripos(implode(';',.$checks),. |
3f680 | 27 4f 53 34 30 30 27 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 | 'OS400');.....}....../**......*. |
3f6a0 | 40 72 65 74 75 72 6e 20 72 65 73 6f 75 72 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 | @return.resource......*/.....pri |
3f6c0 | 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 6f 70 65 6e 4f 75 74 70 75 74 53 74 72 65 61 6d 28 29 | vate.function.openOutputStream() |
3f6e0 | 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 24 74 68 69 73 2d 3e 68 61 73 53 74 | .....{.........if.(!$this->hasSt |
3f700 | 64 6f 75 74 53 75 70 70 6f 72 74 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 | doutSupport()).{.............ret |
3f720 | 75 72 6e 20 66 6f 70 65 6e 28 27 70 68 70 3a 2f 2f 6f 75 74 70 75 74 27 2c 20 27 77 27 29 3b 0a | urn.fopen('php://output',.'w');. |
3f740 | 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 40 66 6f 70 65 6e | ........}..........return.@fopen |
3f760 | 28 27 70 68 70 3a 2f 2f 73 74 64 6f 75 74 27 2c 20 27 77 27 29 20 3f 3a 20 66 6f 70 65 6e 28 27 | ('php://stdout',.'w').?:.fopen(' |
3f780 | 70 68 70 3a 2f 2f 6f 75 74 70 75 74 27 2c 20 27 77 27 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 | php://output',.'w');.....}...... |
3f7a0 | 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 72 65 73 6f 75 72 63 65 0a 20 20 20 20 | /**......*.@return.resource..... |
3f7c0 | 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 6f 70 65 6e 45 72 72 | .*/.....private.function.openErr |
3f7e0 | 6f 72 53 74 72 65 61 6d 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 | orStream().....{.........return. |
3f800 | 66 6f 70 65 6e 28 24 74 68 69 73 2d 3e 68 61 73 53 74 64 65 72 72 53 75 70 70 6f 72 74 28 29 20 | fopen($this->hasStderrSupport(). |
3f820 | 3f 20 27 70 68 70 3a 2f 2f 73 74 64 65 72 72 27 20 3a 20 27 70 68 70 3a 2f 2f 6f 75 74 70 75 74 | ?.'php://stderr'.:.'php://output |
3f840 | 27 2c 20 27 77 27 29 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 | ',.'w');.....}.}.<?php../*..*.Th |
3f860 | 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 | is.file.is.part.of.the.Symfony.p |
3f880 | 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 | ackage...*..*.(c).Fabien.Potenci |
3f8a0 | 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f | er.<fabien@symfony.com>..*..*.Fo |
3f8c0 | 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 | r.the.full.copyright.and.license |
3f8e0 | 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 | .information,.please.view.the.LI |
3f900 | 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 | CENSE..*.file.that.was.distribut |
3f920 | 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e | ed.with.this.source.code...*/..n |
3f940 | 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f | amespace.Symfony\Component\Conso |
3f960 | 6c 65 5c 4f 75 74 70 75 74 3b 0a 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e | le\Output;..use.Symfony\Componen |
3f980 | 74 5c 43 6f 6e 73 6f 6c 65 5c 46 6f 72 6d 61 74 74 65 72 5c 4f 75 74 70 75 74 46 6f 72 6d 61 74 | t\Console\Formatter\OutputFormat |
3f9a0 | 74 65 72 49 6e 74 65 72 66 61 63 65 3b 0a 0a 2f 2a 2a 0a 20 2a 20 4f 75 74 70 75 74 49 6e 74 65 | terInterface;../**..*.OutputInte |
3f9c0 | 72 66 61 63 65 20 69 73 20 74 68 65 20 69 6e 74 65 72 66 61 63 65 20 69 6d 70 6c 65 6d 65 6e 74 | rface.is.the.interface.implement |
3f9e0 | 65 64 20 62 79 20 61 6c 6c 20 4f 75 74 70 75 74 20 63 6c 61 73 73 65 73 2e 0a 20 2a 0a 20 2a 20 | ed.by.all.Output.classes...*..*. |
3fa00 | 40 61 75 74 68 6f 72 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e | @author.Fabien.Potencier.<fabien |
3fa20 | 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 2f 0a 69 6e 74 65 72 66 61 63 65 20 4f 75 74 70 | @symfony.com>..*/.interface.Outp |
3fa40 | 75 74 49 6e 74 65 72 66 61 63 65 0a 7b 0a 20 20 20 20 63 6f 6e 73 74 20 56 45 52 42 4f 53 49 54 | utInterface.{.....const.VERBOSIT |
3fa60 | 59 5f 51 55 49 45 54 20 3d 20 31 36 3b 0a 20 20 20 20 63 6f 6e 73 74 20 56 45 52 42 4f 53 49 54 | Y_QUIET.=.16;.....const.VERBOSIT |
3fa80 | 59 5f 4e 4f 52 4d 41 4c 20 3d 20 33 32 3b 0a 20 20 20 20 63 6f 6e 73 74 20 56 45 52 42 4f 53 49 | Y_NORMAL.=.32;.....const.VERBOSI |
3faa0 | 54 59 5f 56 45 52 42 4f 53 45 20 3d 20 36 34 3b 0a 20 20 20 20 63 6f 6e 73 74 20 56 45 52 42 4f | TY_VERBOSE.=.64;.....const.VERBO |
3fac0 | 53 49 54 59 5f 56 45 52 59 5f 56 45 52 42 4f 53 45 20 3d 20 31 32 38 3b 0a 20 20 20 20 63 6f 6e | SITY_VERY_VERBOSE.=.128;.....con |
3fae0 | 73 74 20 56 45 52 42 4f 53 49 54 59 5f 44 45 42 55 47 20 3d 20 32 35 36 3b 0a 0a 20 20 20 20 63 | st.VERBOSITY_DEBUG.=.256;......c |
3fb00 | 6f 6e 73 74 20 4f 55 54 50 55 54 5f 4e 4f 52 4d 41 4c 20 3d 20 31 3b 0a 20 20 20 20 63 6f 6e 73 | onst.OUTPUT_NORMAL.=.1;.....cons |
3fb20 | 74 20 4f 55 54 50 55 54 5f 52 41 57 20 3d 20 32 3b 0a 20 20 20 20 63 6f 6e 73 74 20 4f 55 54 50 | t.OUTPUT_RAW.=.2;.....const.OUTP |
3fb40 | 55 54 5f 50 4c 41 49 4e 20 3d 20 34 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 57 72 | UT_PLAIN.=.4;....../**......*.Wr |
3fb60 | 69 74 65 73 20 61 20 6d 65 73 73 61 67 65 20 74 6f 20 74 68 65 20 6f 75 74 70 75 74 2e 0a 20 20 | ites.a.message.to.the.output.... |
3fb80 | 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 7c 61 72 72 61 79 20 | ...*......*.@param.string|array. |
3fba0 | 24 6d 65 73 73 61 67 65 73 20 54 68 65 20 6d 65 73 73 61 67 65 20 61 73 20 61 6e 20 61 72 72 61 | $messages.The.message.as.an.arra |
3fbc0 | 79 20 6f 66 20 6c 69 6e 65 73 20 6f 72 20 61 20 73 69 6e 67 6c 65 20 73 74 72 69 6e 67 0a 20 20 | y.of.lines.or.a.single.string... |
3fbe0 | 20 20 20 2a 20 40 70 61 72 61 6d 20 62 6f 6f 6c 20 20 20 20 20 20 20 20 20 24 6e 65 77 6c 69 6e | ...*.@param.bool.........$newlin |
3fc00 | 65 20 20 57 68 65 74 68 65 72 20 74 6f 20 61 64 64 20 61 20 6e 65 77 6c 69 6e 65 0a 20 20 20 20 | e..Whether.to.add.a.newline..... |
3fc20 | 20 2a 20 40 70 61 72 61 6d 20 69 6e 74 20 20 20 20 20 20 20 20 20 20 24 6f 70 74 69 6f 6e 73 20 | .*.@param.int..........$options. |
3fc40 | 20 41 20 62 69 74 6d 61 73 6b 20 6f 66 20 6f 70 74 69 6f 6e 73 20 28 6f 6e 65 20 6f 66 20 74 68 | .A.bitmask.of.options.(one.of.th |
3fc60 | 65 20 4f 55 54 50 55 54 20 6f 72 20 56 45 52 42 4f 53 49 54 59 20 63 6f 6e 73 74 61 6e 74 73 29 | e.OUTPUT.or.VERBOSITY.constants) |
3fc80 | 2c 20 30 20 69 73 20 63 6f 6e 73 69 64 65 72 65 64 20 74 68 65 20 73 61 6d 65 20 61 73 20 73 65 | ,.0.is.considered.the.same.as.se |
3fca0 | 6c 66 3a 3a 4f 55 54 50 55 54 5f 4e 4f 52 4d 41 4c 20 7c 20 73 65 6c 66 3a 3a 56 45 52 42 4f 53 | lf::OUTPUT_NORMAL.|.self::VERBOS |
3fcc0 | 49 54 59 5f 4e 4f 52 4d 41 4c 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 | ITY_NORMAL......*/.....public.fu |
3fce0 | 6e 63 74 69 6f 6e 20 77 72 69 74 65 28 24 6d 65 73 73 61 67 65 73 2c 20 24 6e 65 77 6c 69 6e 65 | nction.write($messages,.$newline |
3fd00 | 20 3d 20 66 61 6c 73 65 2c 20 24 6f 70 74 69 6f 6e 73 20 3d 20 30 29 3b 0a 0a 20 20 20 20 2f 2a | .=.false,.$options.=.0);....../* |
3fd20 | 2a 0a 20 20 20 20 20 2a 20 57 72 69 74 65 73 20 61 20 6d 65 73 73 61 67 65 20 74 6f 20 74 68 65 | *......*.Writes.a.message.to.the |
3fd40 | 20 6f 75 74 70 75 74 20 61 6e 64 20 61 64 64 73 20 61 20 6e 65 77 6c 69 6e 65 20 61 74 20 74 68 | .output.and.adds.a.newline.at.th |
3fd60 | 65 20 65 6e 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 | e.end.......*......*.@param.stri |
3fd80 | 6e 67 7c 61 72 72 61 79 20 24 6d 65 73 73 61 67 65 73 20 54 68 65 20 6d 65 73 73 61 67 65 20 61 | ng|array.$messages.The.message.a |
3fda0 | 73 20 61 6e 20 61 72 72 61 79 20 6f 66 20 6c 69 6e 65 73 20 6f 66 20 61 20 73 69 6e 67 6c 65 20 | s.an.array.of.lines.of.a.single. |
3fdc0 | 73 74 72 69 6e 67 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 69 6e 74 20 20 20 20 20 20 20 20 | string......*.@param.int........ |
3fde0 | 20 20 24 6f 70 74 69 6f 6e 73 20 20 41 20 62 69 74 6d 61 73 6b 20 6f 66 20 6f 70 74 69 6f 6e 73 | ..$options..A.bitmask.of.options |
3fe00 | 20 28 6f 6e 65 20 6f 66 20 74 68 65 20 4f 55 54 50 55 54 20 6f 72 20 56 45 52 42 4f 53 49 54 59 | .(one.of.the.OUTPUT.or.VERBOSITY |
3fe20 | 20 63 6f 6e 73 74 61 6e 74 73 29 2c 20 30 20 69 73 20 63 6f 6e 73 69 64 65 72 65 64 20 74 68 65 | .constants),.0.is.considered.the |
3fe40 | 20 73 61 6d 65 20 61 73 20 73 65 6c 66 3a 3a 4f 55 54 50 55 54 5f 4e 4f 52 4d 41 4c 20 7c 20 73 | .same.as.self::OUTPUT_NORMAL.|.s |
3fe60 | 65 6c 66 3a 3a 56 45 52 42 4f 53 49 54 59 5f 4e 4f 52 4d 41 4c 0a 20 20 20 20 20 2a 2f 0a 20 20 | elf::VERBOSITY_NORMAL......*/... |
3fe80 | 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 77 72 69 74 65 6c 6e 28 24 6d 65 73 73 61 | ..public.function.writeln($messa |
3fea0 | 67 65 73 2c 20 24 6f 70 74 69 6f 6e 73 20 3d 20 30 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 | ges,.$options.=.0);....../**.... |
3fec0 | 20 20 2a 20 53 65 74 73 20 74 68 65 20 76 65 72 62 6f 73 69 74 79 20 6f 66 20 74 68 65 20 6f 75 | ..*.Sets.the.verbosity.of.the.ou |
3fee0 | 74 70 75 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 69 6e 74 20 24 | tput.......*......*.@param.int.$ |
3ff00 | 6c 65 76 65 6c 20 54 68 65 20 6c 65 76 65 6c 20 6f 66 20 76 65 72 62 6f 73 69 74 79 20 28 6f 6e | level.The.level.of.verbosity.(on |
3ff20 | 65 20 6f 66 20 74 68 65 20 56 45 52 42 4f 53 49 54 59 20 63 6f 6e 73 74 61 6e 74 73 29 0a 20 20 | e.of.the.VERBOSITY.constants)... |
3ff40 | 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 56 65 72 | ...*/.....public.function.setVer |
3ff60 | 62 6f 73 69 74 79 28 24 6c 65 76 65 6c 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 | bosity($level);....../**......*. |
3ff80 | 47 65 74 73 20 74 68 65 20 63 75 72 72 65 6e 74 20 76 65 72 62 6f 73 69 74 79 20 6f 66 20 74 68 | Gets.the.current.verbosity.of.th |
3ffa0 | 65 20 6f 75 74 70 75 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 | e.output.......*......*.@return. |
3ffc0 | 69 6e 74 20 54 68 65 20 63 75 72 72 65 6e 74 20 6c 65 76 65 6c 20 6f 66 20 76 65 72 62 6f 73 69 | int.The.current.level.of.verbosi |
3ffe0 | 74 79 20 28 6f 6e 65 20 6f 66 20 74 68 65 20 56 45 52 42 4f 53 49 54 59 20 63 6f 6e 73 74 61 6e | ty.(one.of.the.VERBOSITY.constan |
40000 | 74 73 29 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 | ts)......*/.....public.function. |
40020 | 67 65 74 56 65 72 62 6f 73 69 74 79 28 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 | getVerbosity();....../**......*. |
40040 | 52 65 74 75 72 6e 73 20 77 68 65 74 68 65 72 20 76 65 72 62 6f 73 69 74 79 20 69 73 20 71 75 69 | Returns.whether.verbosity.is.qui |
40060 | 65 74 20 28 2d 71 29 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 62 | et.(-q).......*......*.@return.b |
40080 | 6f 6f 6c 20 74 72 75 65 20 69 66 20 76 65 72 62 6f 73 69 74 79 20 69 73 20 73 65 74 20 74 6f 20 | ool.true.if.verbosity.is.set.to. |
400a0 | 56 45 52 42 4f 53 49 54 59 5f 51 55 49 45 54 2c 20 66 61 6c 73 65 20 6f 74 68 65 72 77 69 73 65 | VERBOSITY_QUIET,.false.otherwise |
400c0 | 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 69 73 51 | ......*/.....public.function.isQ |
400e0 | 75 69 65 74 28 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 | uiet();....../**......*.Returns. |
40100 | 77 68 65 74 68 65 72 20 76 65 72 62 6f 73 69 74 79 20 69 73 20 76 65 72 62 6f 73 65 20 28 2d 76 | whether.verbosity.is.verbose.(-v |
40120 | 29 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 62 6f 6f 6c 20 74 72 | ).......*......*.@return.bool.tr |
40140 | 75 65 20 69 66 20 76 65 72 62 6f 73 69 74 79 20 69 73 20 73 65 74 20 74 6f 20 56 45 52 42 4f 53 | ue.if.verbosity.is.set.to.VERBOS |
40160 | 49 54 59 5f 56 45 52 42 4f 53 45 2c 20 66 61 6c 73 65 20 6f 74 68 65 72 77 69 73 65 0a 20 20 20 | ITY_VERBOSE,.false.otherwise.... |
40180 | 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 69 73 56 65 72 62 6f | ..*/.....public.function.isVerbo |
401a0 | 73 65 28 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 77 68 | se();....../**......*.Returns.wh |
401c0 | 65 74 68 65 72 20 76 65 72 62 6f 73 69 74 79 20 69 73 20 76 65 72 79 20 76 65 72 62 6f 73 65 20 | ether.verbosity.is.very.verbose. |
401e0 | 28 2d 76 76 29 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 62 6f 6f | (-vv).......*......*.@return.boo |
40200 | 6c 20 74 72 75 65 20 69 66 20 76 65 72 62 6f 73 69 74 79 20 69 73 20 73 65 74 20 74 6f 20 56 45 | l.true.if.verbosity.is.set.to.VE |
40220 | 52 42 4f 53 49 54 59 5f 56 45 52 59 5f 56 45 52 42 4f 53 45 2c 20 66 61 6c 73 65 20 6f 74 68 65 | RBOSITY_VERY_VERBOSE,.false.othe |
40240 | 72 77 69 73 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f | rwise......*/.....public.functio |
40260 | 6e 20 69 73 56 65 72 79 56 65 72 62 6f 73 65 28 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 | n.isVeryVerbose();....../**..... |
40280 | 20 2a 20 52 65 74 75 72 6e 73 20 77 68 65 74 68 65 72 20 76 65 72 62 6f 73 69 74 79 20 69 73 20 | .*.Returns.whether.verbosity.is. |
402a0 | 64 65 62 75 67 20 28 2d 76 76 76 29 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 | debug.(-vvv).......*......*.@ret |
402c0 | 75 72 6e 20 62 6f 6f 6c 20 74 72 75 65 20 69 66 20 76 65 72 62 6f 73 69 74 79 20 69 73 20 73 65 | urn.bool.true.if.verbosity.is.se |
402e0 | 74 20 74 6f 20 56 45 52 42 4f 53 49 54 59 5f 44 45 42 55 47 2c 20 66 61 6c 73 65 20 6f 74 68 65 | t.to.VERBOSITY_DEBUG,.false.othe |
40300 | 72 77 69 73 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f | rwise......*/.....public.functio |
40320 | 6e 20 69 73 44 65 62 75 67 28 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 | n.isDebug();....../**......*.Set |
40340 | 73 20 74 68 65 20 64 65 63 6f 72 61 74 65 64 20 66 6c 61 67 2e 0a 20 20 20 20 20 2a 0a 20 20 20 | s.the.decorated.flag.......*.... |
40360 | 20 20 2a 20 40 70 61 72 61 6d 20 62 6f 6f 6c 20 24 64 65 63 6f 72 61 74 65 64 20 57 68 65 74 68 | ..*.@param.bool.$decorated.Wheth |
40380 | 65 72 20 74 6f 20 64 65 63 6f 72 61 74 65 20 74 68 65 20 6d 65 73 73 61 67 65 73 0a 20 20 20 20 | er.to.decorate.the.messages..... |
403a0 | 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 44 65 63 6f 72 | .*/.....public.function.setDecor |
403c0 | 61 74 65 64 28 24 64 65 63 6f 72 61 74 65 64 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 | ated($decorated);....../**...... |
403e0 | 2a 20 47 65 74 73 20 74 68 65 20 64 65 63 6f 72 61 74 65 64 20 66 6c 61 67 2e 0a 20 20 20 20 20 | *.Gets.the.decorated.flag....... |
40400 | 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 62 6f 6f 6c 20 74 72 75 65 20 69 66 20 74 68 | *......*.@return.bool.true.if.th |
40420 | 65 20 6f 75 74 70 75 74 20 77 69 6c 6c 20 64 65 63 6f 72 61 74 65 20 6d 65 73 73 61 67 65 73 2c | e.output.will.decorate.messages, |
40440 | 20 66 61 6c 73 65 20 6f 74 68 65 72 77 69 73 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 | .false.otherwise......*/.....pub |
40460 | 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 69 73 44 65 63 6f 72 61 74 65 64 28 29 3b 0a 0a 20 20 20 | lic.function.isDecorated();..... |
40480 | 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 6f 75 74 70 75 74 20 66 6f 72 6d 61 74 74 65 | ./**......*.Sets.output.formatte |
404a0 | 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 4f 75 74 70 75 74 46 6f | r.......*......*.@param.OutputFo |
404c0 | 72 6d 61 74 74 65 72 49 6e 74 65 72 66 61 63 65 20 24 66 6f 72 6d 61 74 74 65 72 0a 20 20 20 20 | rmatterInterface.$formatter..... |
404e0 | 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 46 6f 72 6d 61 | .*/.....public.function.setForma |
40500 | 74 74 65 72 28 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 49 6e 74 65 72 66 61 63 65 20 24 66 | tter(OutputFormatterInterface.$f |
40520 | 6f 72 6d 61 74 74 65 72 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 | ormatter);....../**......*.Retur |
40540 | 6e 73 20 63 75 72 72 65 6e 74 20 6f 75 74 70 75 74 20 66 6f 72 6d 61 74 74 65 72 20 69 6e 73 74 | ns.current.output.formatter.inst |
40560 | 61 6e 63 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 4f 75 74 70 | ance.......*......*.@return.Outp |
40580 | 75 74 46 6f 72 6d 61 74 74 65 72 49 6e 74 65 72 66 61 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 | utFormatterInterface......*/.... |
405a0 | 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 46 6f 72 6d 61 74 74 65 72 28 29 3b | .public.function.getFormatter(); |
405c0 | 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 | .}.<?php../*..*.This.file.is.par |
405e0 | 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 | t.of.the.Symfony.package...*..*. |
40600 | 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d | (c).Fabien.Potencier.<fabien@sym |
40620 | 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 | fony.com>..*..*.For.the.full.cop |
40640 | 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 | yright.and.license.information,. |
40660 | 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 | please.view.the.LICENSE..*.file. |
40680 | 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 | that.was.distributed.with.this.s |
406a0 | 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f | ource.code...*/..namespace.Symfo |
406c0 | 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 3b 0a 0a 75 73 65 | ny\Component\Console\Input;..use |
406e0 | 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 78 63 65 70 | .Symfony\Component\Console\Excep |
40700 | 74 69 6f 6e 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 3b 0a 75 | tion\InvalidArgumentException;.u |
40720 | 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 78 63 | se.Symfony\Component\Console\Exc |
40740 | 65 70 74 69 6f 6e 5c 4c 6f 67 69 63 45 78 63 65 70 74 69 6f 6e 3b 0a 0a 2f 2a 2a 0a 20 2a 20 41 | eption\LogicException;../**..*.A |
40760 | 20 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 20 72 65 70 72 65 73 65 6e 74 73 20 61 20 73 65 | .InputDefinition.represents.a.se |
40780 | 74 20 6f 66 20 76 61 6c 69 64 20 63 6f 6d 6d 61 6e 64 20 6c 69 6e 65 20 61 72 67 75 6d 65 6e 74 | t.of.valid.command.line.argument |
407a0 | 73 20 61 6e 64 20 6f 70 74 69 6f 6e 73 2e 0a 20 2a 0a 20 2a 20 55 73 61 67 65 3a 0a 20 2a 0a 20 | s.and.options...*..*.Usage:..*.. |
407c0 | 2a 20 20 20 20 20 24 64 65 66 69 6e 69 74 69 6f 6e 20 3d 20 6e 65 77 20 49 6e 70 75 74 44 65 66 | *.....$definition.=.new.InputDef |
407e0 | 69 6e 69 74 69 6f 6e 28 61 72 72 61 79 28 0a 20 2a 20 20 20 20 20 20 20 6e 65 77 20 49 6e 70 75 | inition(array(..*.......new.Inpu |
40800 | 74 41 72 67 75 6d 65 6e 74 28 27 6e 61 6d 65 27 2c 20 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 3a | tArgument('name',.InputArgument: |
40820 | 3a 52 45 51 55 49 52 45 44 29 2c 0a 20 2a 20 20 20 20 20 20 20 6e 65 77 20 49 6e 70 75 74 4f 70 | :REQUIRED),..*.......new.InputOp |
40840 | 74 69 6f 6e 28 27 66 6f 6f 27 2c 20 27 66 27 2c 20 49 6e 70 75 74 4f 70 74 69 6f 6e 3a 3a 56 41 | tion('foo',.'f',.InputOption::VA |
40860 | 4c 55 45 5f 52 45 51 55 49 52 45 44 29 2c 0a 20 2a 20 20 20 20 20 29 29 3b 0a 20 2a 0a 20 2a 20 | LUE_REQUIRED),..*.....));..*..*. |
40880 | 40 61 75 74 68 6f 72 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e | @author.Fabien.Potencier.<fabien |
408a0 | 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 49 6e 70 75 74 44 65 66 | @symfony.com>..*/.class.InputDef |
408c0 | 69 6e 69 74 69 6f 6e 0a 7b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 61 72 67 75 6d 65 6e 74 73 | inition.{.....private.$arguments |
408e0 | 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 72 65 71 75 69 72 65 64 43 6f 75 6e 74 3b 0a 20 20 | ;.....private.$requiredCount;... |
40900 | 20 20 70 72 69 76 61 74 65 20 24 68 61 73 41 6e 41 72 72 61 79 41 72 67 75 6d 65 6e 74 20 3d 20 | ..private.$hasAnArrayArgument.=. |
40920 | 66 61 6c 73 65 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 68 61 73 4f 70 74 69 6f 6e 61 6c 3b | false;.....private.$hasOptional; |
40940 | 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 6f 70 74 69 6f 6e 73 3b 0a 20 20 20 20 70 72 69 76 61 | .....private.$options;.....priva |
40960 | 74 65 20 24 73 68 6f 72 74 63 75 74 73 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 43 | te.$shortcuts;....../**......*.C |
40980 | 6f 6e 73 74 72 75 63 74 6f 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d | onstructor.......*......*.@param |
409a0 | 20 61 72 72 61 79 20 24 64 65 66 69 6e 69 74 69 6f 6e 20 41 6e 20 61 72 72 61 79 20 6f 66 20 49 | .array.$definition.An.array.of.I |
409c0 | 6e 70 75 74 41 72 67 75 6d 65 6e 74 20 61 6e 64 20 49 6e 70 75 74 4f 70 74 69 6f 6e 20 69 6e 73 | nputArgument.and.InputOption.ins |
409e0 | 74 61 6e 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f | tance......*/.....public.functio |
40a00 | 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 74 28 61 72 72 61 79 20 24 64 65 66 69 6e 69 74 69 6f 6e 20 | n.__construct(array.$definition. |
40a20 | 3d 20 61 72 72 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e | =.array()).....{.........$this-> |
40a40 | 73 65 74 44 65 66 69 6e 69 74 69 6f 6e 28 24 64 65 66 69 6e 69 74 69 6f 6e 29 3b 0a 20 20 20 20 | setDefinition($definition);..... |
40a60 | 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 74 68 65 20 64 65 66 69 6e | }....../**......*.Sets.the.defin |
40a80 | 69 74 69 6f 6e 20 6f 66 20 74 68 65 20 69 6e 70 75 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 | ition.of.the.input.......*...... |
40aa0 | 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 24 64 65 66 69 6e 69 74 69 6f 6e 20 54 68 65 20 64 | *.@param.array.$definition.The.d |
40ac0 | 65 66 69 6e 69 74 69 6f 6e 20 61 72 72 61 79 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c | efinition.array......*/.....publ |
40ae0 | 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 44 65 66 69 6e 69 74 69 6f 6e 28 61 72 72 61 79 20 | ic.function.setDefinition(array. |
40b00 | 24 64 65 66 69 6e 69 74 69 6f 6e 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 61 72 67 75 | $definition).....{.........$argu |
40b20 | 6d 65 6e 74 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 24 6f 70 74 69 6f 6e | ments.=.array();.........$option |
40b40 | 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 64 | s.=.array();.........foreach.($d |
40b60 | 65 66 69 6e 69 74 69 6f 6e 20 61 73 20 24 69 74 65 6d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | efinition.as.$item).{........... |
40b80 | 20 20 69 66 20 28 24 69 74 65 6d 20 69 6e 73 74 61 6e 63 65 6f 66 20 49 6e 70 75 74 4f 70 74 69 | ..if.($item.instanceof.InputOpti |
40ba0 | 6f 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 70 74 69 6f 6e 73 5b 5d | on).{.................$options[] |
40bc0 | 20 3d 20 24 69 74 65 6d 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 | .=.$item;.............}.else.{.. |
40be0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 61 72 67 75 6d 65 6e 74 73 5b 5d 20 3d 20 24 69 | ...............$arguments[].=.$i |
40c00 | 74 65 6d 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 | tem;.............}.........}.... |
40c20 | 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 65 74 41 72 67 75 6d 65 6e 74 73 28 24 61 72 67 75 6d | ......$this->setArguments($argum |
40c40 | 65 6e 74 73 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 65 74 4f 70 74 69 6f 6e 73 | ents);.........$this->setOptions |
40c60 | 28 24 6f 70 74 69 6f 6e 73 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 | ($options);.....}....../**...... |
40c80 | 2a 20 53 65 74 73 20 74 68 65 20 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 20 6f 62 6a 65 63 74 73 | *.Sets.the.InputArgument.objects |
40ca0 | 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 49 6e 70 75 74 41 72 67 75 | .......*......*.@param.InputArgu |
40cc0 | 6d 65 6e 74 5b 5d 20 24 61 72 67 75 6d 65 6e 74 73 20 41 6e 20 61 72 72 61 79 20 6f 66 20 49 6e | ment[].$arguments.An.array.of.In |
40ce0 | 70 75 74 41 72 67 75 6d 65 6e 74 20 6f 62 6a 65 63 74 73 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 | putArgument.objects......*/..... |
40d00 | 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 41 72 67 75 6d 65 6e 74 73 28 24 61 72 | public.function.setArguments($ar |
40d20 | 67 75 6d 65 6e 74 73 20 3d 20 61 72 72 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 | guments.=.array()).....{........ |
40d40 | 20 24 74 68 69 73 2d 3e 61 72 67 75 6d 65 6e 74 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 | .$this->arguments.=.array();.... |
40d60 | 20 20 20 20 20 24 74 68 69 73 2d 3e 72 65 71 75 69 72 65 64 43 6f 75 6e 74 20 3d 20 30 3b 0a 20 | .....$this->requiredCount.=.0;.. |
40d80 | 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 68 61 73 4f 70 74 69 6f 6e 61 6c 20 3d 20 66 61 6c 73 | .......$this->hasOptional.=.fals |
40da0 | 65 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 68 61 73 41 6e 41 72 72 61 79 41 72 67 75 | e;.........$this->hasAnArrayArgu |
40dc0 | 6d 65 6e 74 20 3d 20 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 61 64 64 | ment.=.false;.........$this->add |
40de0 | 41 72 67 75 6d 65 6e 74 73 28 24 61 72 67 75 6d 65 6e 74 73 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 | Arguments($arguments);.....}.... |
40e00 | 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 41 64 64 73 20 61 6e 20 61 72 72 61 79 20 6f 66 20 49 6e | ../**......*.Adds.an.array.of.In |
40e20 | 70 75 74 41 72 67 75 6d 65 6e 74 20 6f 62 6a 65 63 74 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 | putArgument.objects.......*..... |
40e40 | 20 2a 20 40 70 61 72 61 6d 20 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 5b 5d 20 24 61 72 67 75 6d | .*.@param.InputArgument[].$argum |
40e60 | 65 6e 74 73 20 41 6e 20 61 72 72 61 79 20 6f 66 20 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 20 6f | ents.An.array.of.InputArgument.o |
40e80 | 62 6a 65 63 74 73 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 | bjects......*/.....public.functi |
40ea0 | 6f 6e 20 61 64 64 41 72 67 75 6d 65 6e 74 73 28 24 61 72 67 75 6d 65 6e 74 73 20 3d 20 61 72 72 | on.addArguments($arguments.=.arr |
40ec0 | 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 21 3d 3d | ay()).....{.........if.(null.!== |
40ee0 | 20 24 61 72 67 75 6d 65 6e 74 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 | .$arguments).{.............forea |
40f00 | 63 68 20 28 24 61 72 67 75 6d 65 6e 74 73 20 61 73 20 24 61 72 67 75 6d 65 6e 74 29 20 7b 0a 20 | ch.($arguments.as.$argument).{.. |
40f20 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 61 64 64 41 72 67 75 6d 65 6e | ...............$this->addArgumen |
40f40 | 74 28 24 61 72 67 75 6d 65 6e 74 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 | t($argument);.............}..... |
40f60 | 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 41 64 64 73 | ....}.....}....../**......*.Adds |
40f80 | 20 61 6e 20 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 20 6f 62 6a 65 63 74 2e 0a 20 20 20 20 20 2a | .an.InputArgument.object.......* |
40fa0 | 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 20 24 61 72 | ......*.@param.InputArgument.$ar |
40fc0 | 67 75 6d 65 6e 74 20 41 6e 20 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 20 6f 62 6a 65 63 74 0a 20 | gument.An.InputArgument.object.. |
40fe0 | 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 4c 6f 67 69 63 45 78 63 65 70 74 | ....*......*.@throws.LogicExcept |
41000 | 69 6f 6e 20 57 68 65 6e 20 69 6e 63 6f 72 72 65 63 74 20 61 72 67 75 6d 65 6e 74 20 69 73 20 67 | ion.When.incorrect.argument.is.g |
41020 | 69 76 65 6e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e | iven......*/.....public.function |
41040 | 20 61 64 64 41 72 67 75 6d 65 6e 74 28 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 20 24 61 72 67 75 | .addArgument(InputArgument.$argu |
41060 | 6d 65 6e 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 69 73 73 65 74 28 24 74 | ment).....{.........if.(isset($t |
41080 | 68 69 73 2d 3e 61 72 67 75 6d 65 6e 74 73 5b 24 61 72 67 75 6d 65 6e 74 2d 3e 67 65 74 4e 61 6d | his->arguments[$argument->getNam |
410a0 | 65 28 29 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 4c | e()])).{.............throw.new.L |
410c0 | 6f 67 69 63 45 78 63 65 70 74 69 6f 6e 28 73 70 72 69 6e 74 66 28 27 41 6e 20 61 72 67 75 6d 65 | ogicException(sprintf('An.argume |
410e0 | 6e 74 20 77 69 74 68 20 6e 61 6d 65 20 22 25 73 22 20 61 6c 72 65 61 64 79 20 65 78 69 73 74 73 | nt.with.name."%s".already.exists |
41100 | 2e 27 2c 20 24 61 72 67 75 6d 65 6e 74 2d 3e 67 65 74 4e 61 6d 65 28 29 29 29 3b 0a 20 20 20 20 | .',.$argument->getName()));..... |
41120 | 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 74 68 69 73 2d 3e 68 61 73 41 6e 41 | ....}..........if.($this->hasAnA |
41140 | 72 72 61 79 41 72 67 75 6d 65 6e 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f | rrayArgument).{.............thro |
41160 | 77 20 6e 65 77 20 4c 6f 67 69 63 45 78 63 65 70 74 69 6f 6e 28 27 43 61 6e 6e 6f 74 20 61 64 64 | w.new.LogicException('Cannot.add |
41180 | 20 61 6e 20 61 72 67 75 6d 65 6e 74 20 61 66 74 65 72 20 61 6e 20 61 72 72 61 79 20 61 72 67 75 | .an.argument.after.an.array.argu |
411a0 | 6d 65 6e 74 2e 27 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 | ment.');.........}..........if.( |
411c0 | 24 61 72 67 75 6d 65 6e 74 2d 3e 69 73 52 65 71 75 69 72 65 64 28 29 20 26 26 20 24 74 68 69 73 | $argument->isRequired().&&.$this |
411e0 | 2d 3e 68 61 73 4f 70 74 69 6f 6e 61 6c 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 | ->hasOptional).{.............thr |
41200 | 6f 77 20 6e 65 77 20 4c 6f 67 69 63 45 78 63 65 70 74 69 6f 6e 28 27 43 61 6e 6e 6f 74 20 61 64 | ow.new.LogicException('Cannot.ad |
41220 | 64 20 61 20 72 65 71 75 69 72 65 64 20 61 72 67 75 6d 65 6e 74 20 61 66 74 65 72 20 61 6e 20 6f | d.a.required.argument.after.an.o |
41240 | 70 74 69 6f 6e 61 6c 20 6f 6e 65 2e 27 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 | ptional.one.');.........}....... |
41260 | 20 20 20 69 66 20 28 24 61 72 67 75 6d 65 6e 74 2d 3e 69 73 41 72 72 61 79 28 29 29 20 7b 0a 20 | ...if.($argument->isArray()).{.. |
41280 | 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 68 61 73 41 6e 41 72 72 61 79 41 72 67 75 | ...........$this->hasAnArrayArgu |
412a0 | 6d 65 6e 74 20 3d 20 74 72 75 65 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 | ment.=.true;.........}.......... |
412c0 | 69 66 20 28 24 61 72 67 75 6d 65 6e 74 2d 3e 69 73 52 65 71 75 69 72 65 64 28 29 29 20 7b 0a 20 | if.($argument->isRequired()).{.. |
412e0 | 20 20 20 20 20 20 20 20 20 20 20 2b 2b 24 74 68 69 73 2d 3e 72 65 71 75 69 72 65 64 43 6f 75 6e | ...........++$this->requiredCoun |
41300 | 74 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | t;.........}.else.{............. |
41320 | 24 74 68 69 73 2d 3e 68 61 73 4f 70 74 69 6f 6e 61 6c 20 3d 20 74 72 75 65 3b 0a 20 20 20 20 20 | $this->hasOptional.=.true;...... |
41340 | 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 61 72 67 75 6d 65 6e 74 73 5b 24 | ...}..........$this->arguments[$ |
41360 | 61 72 67 75 6d 65 6e 74 2d 3e 67 65 74 4e 61 6d 65 28 29 5d 20 3d 20 24 61 72 67 75 6d 65 6e 74 | argument->getName()].=.$argument |
41380 | 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 | ;.....}....../**......*.Returns. |
413a0 | 61 6e 20 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 20 62 79 20 6e 61 6d 65 20 6f 72 20 62 79 20 70 | an.InputArgument.by.name.or.by.p |
413c0 | 6f 73 69 74 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 | osition.......*......*.@param.st |
413e0 | 72 69 6e 67 7c 69 6e 74 20 24 6e 61 6d 65 20 54 68 65 20 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 | ring|int.$name.The.InputArgument |
41400 | 20 6e 61 6d 65 20 6f 72 20 70 6f 73 69 74 69 6f 6e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 | .name.or.position......*......*. |
41420 | 40 72 65 74 75 72 6e 20 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 20 41 6e 20 49 6e 70 75 74 41 72 | @return.InputArgument.An.InputAr |
41440 | 67 75 6d 65 6e 74 20 6f 62 6a 65 63 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 | gument.object......*......*.@thr |
41460 | 6f 77 73 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 20 57 68 65 | ows.InvalidArgumentException.Whe |
41480 | 6e 20 61 72 67 75 6d 65 6e 74 20 67 69 76 65 6e 20 64 6f 65 73 6e 27 74 20 65 78 69 73 74 0a 20 | n.argument.given.doesn't.exist.. |
414a0 | 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 41 72 | ....*/.....public.function.getAr |
414c0 | 67 75 6d 65 6e 74 28 24 6e 61 6d 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 | gument($name).....{.........if.( |
414e0 | 21 24 74 68 69 73 2d 3e 68 61 73 41 72 67 75 6d 65 6e 74 28 24 6e 61 6d 65 29 29 20 7b 0a 20 20 | !$this->hasArgument($name)).{... |
41500 | 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 61 6c 69 64 41 72 67 75 6d | ..........throw.new.InvalidArgum |
41520 | 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 73 70 72 69 6e 74 66 28 27 54 68 65 20 22 25 73 22 20 61 | entException(sprintf('The."%s".a |
41540 | 72 67 75 6d 65 6e 74 20 64 6f 65 73 20 6e 6f 74 20 65 78 69 73 74 2e 27 2c 20 24 6e 61 6d 65 29 | rgument.does.not.exist.',.$name) |
41560 | 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 61 72 67 75 6d 65 6e 74 73 | );.........}..........$arguments |
41580 | 20 3d 20 69 73 5f 69 6e 74 28 24 6e 61 6d 65 29 20 3f 20 61 72 72 61 79 5f 76 61 6c 75 65 73 28 | .=.is_int($name).?.array_values( |
415a0 | 24 74 68 69 73 2d 3e 61 72 67 75 6d 65 6e 74 73 29 20 3a 20 24 74 68 69 73 2d 3e 61 72 67 75 6d | $this->arguments).:.$this->argum |
415c0 | 65 6e 74 73 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 61 72 67 75 6d 65 6e 74 73 | ents;..........return.$arguments |
415e0 | 5b 24 6e 61 6d 65 5d 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 | [$name];.....}....../**......*.R |
41600 | 65 74 75 72 6e 73 20 74 72 75 65 20 69 66 20 61 6e 20 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 20 | eturns.true.if.an.InputArgument. |
41620 | 6f 62 6a 65 63 74 20 65 78 69 73 74 73 20 62 79 20 6e 61 6d 65 20 6f 72 20 70 6f 73 69 74 69 6f | object.exists.by.name.or.positio |
41640 | 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 7c 69 | n.......*......*.@param.string|i |
41660 | 6e 74 20 24 6e 61 6d 65 20 54 68 65 20 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 20 6e 61 6d 65 20 | nt.$name.The.InputArgument.name. |
41680 | 6f 72 20 70 6f 73 69 74 69 6f 6e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 | or.position......*......*.@retur |
416a0 | 6e 20 62 6f 6f 6c 20 74 72 75 65 20 69 66 20 74 68 65 20 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 | n.bool.true.if.the.InputArgument |
416c0 | 20 6f 62 6a 65 63 74 20 65 78 69 73 74 73 2c 20 66 61 6c 73 65 20 6f 74 68 65 72 77 69 73 65 0a | .object.exists,.false.otherwise. |
416e0 | 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 68 61 73 41 | .....*/.....public.function.hasA |
41700 | 72 67 75 6d 65 6e 74 28 24 6e 61 6d 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 61 72 | rgument($name).....{.........$ar |
41720 | 67 75 6d 65 6e 74 73 20 3d 20 69 73 5f 69 6e 74 28 24 6e 61 6d 65 29 20 3f 20 61 72 72 61 79 5f | guments.=.is_int($name).?.array_ |
41740 | 76 61 6c 75 65 73 28 24 74 68 69 73 2d 3e 61 72 67 75 6d 65 6e 74 73 29 20 3a 20 24 74 68 69 73 | values($this->arguments).:.$this |
41760 | 2d 3e 61 72 67 75 6d 65 6e 74 73 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 69 73 73 | ->arguments;..........return.iss |
41780 | 65 74 28 24 61 72 67 75 6d 65 6e 74 73 5b 24 6e 61 6d 65 5d 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 | et($arguments[$name]);.....}.... |
417a0 | 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 61 72 72 61 79 20 6f 66 20 49 | ../**......*.Gets.the.array.of.I |
417c0 | 6e 70 75 74 41 72 67 75 6d 65 6e 74 20 6f 62 6a 65 63 74 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 | nputArgument.objects.......*.... |
417e0 | 20 20 2a 20 40 72 65 74 75 72 6e 20 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 5b 5d 20 41 6e 20 61 | ..*.@return.InputArgument[].An.a |
41800 | 72 72 61 79 20 6f 66 20 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 20 6f 62 6a 65 63 74 73 0a 20 20 | rray.of.InputArgument.objects... |
41820 | 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 41 72 67 | ...*/.....public.function.getArg |
41840 | 75 6d 65 6e 74 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 | uments().....{.........return.$t |
41860 | 68 69 73 2d 3e 61 72 67 75 6d 65 6e 74 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 | his->arguments;.....}....../**.. |
41880 | 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 74 68 65 20 6e 75 6d 62 65 72 20 6f 66 20 49 6e 70 75 | ....*.Returns.the.number.of.Inpu |
418a0 | 74 41 72 67 75 6d 65 6e 74 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 | tArguments.......*......*.@retur |
418c0 | 6e 20 69 6e 74 20 54 68 65 20 6e 75 6d 62 65 72 20 6f 66 20 49 6e 70 75 74 41 72 67 75 6d 65 6e | n.int.The.number.of.InputArgumen |
418e0 | 74 73 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 | ts......*/.....public.function.g |
41900 | 65 74 41 72 67 75 6d 65 6e 74 43 6f 75 6e 74 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | etArgumentCount().....{......... |
41920 | 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 68 61 73 41 6e 41 72 72 61 79 41 72 67 75 6d 65 6e 74 | return.$this->hasAnArrayArgument |
41940 | 20 3f 20 50 48 50 5f 49 4e 54 5f 4d 41 58 20 3a 20 63 6f 75 6e 74 28 24 74 68 69 73 2d 3e 61 72 | .?.PHP_INT_MAX.:.count($this->ar |
41960 | 67 75 6d 65 6e 74 73 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 | guments);.....}....../**......*. |
41980 | 52 65 74 75 72 6e 73 20 74 68 65 20 6e 75 6d 62 65 72 20 6f 66 20 72 65 71 75 69 72 65 64 20 49 | Returns.the.number.of.required.I |
419a0 | 6e 70 75 74 41 72 67 75 6d 65 6e 74 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 | nputArguments.......*......*.@re |
419c0 | 74 75 72 6e 20 69 6e 74 20 54 68 65 20 6e 75 6d 62 65 72 20 6f 66 20 72 65 71 75 69 72 65 64 20 | turn.int.The.number.of.required. |
419e0 | 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 73 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 | InputArguments......*/.....publi |
41a00 | 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 41 72 67 75 6d 65 6e 74 52 65 71 75 69 72 65 64 43 6f | c.function.getArgumentRequiredCo |
41a20 | 75 6e 74 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 | unt().....{.........return.$this |
41a40 | 2d 3e 72 65 71 75 69 72 65 64 43 6f 75 6e 74 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a | ->requiredCount;.....}....../**. |
41a60 | 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 64 65 66 61 75 6c 74 20 76 61 6c 75 65 73 2e 0a | .....*.Gets.the.default.values.. |
41a80 | 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 61 72 72 61 79 20 41 6e 20 61 | .....*......*.@return.array.An.a |
41aa0 | 72 72 61 79 20 6f 66 20 64 65 66 61 75 6c 74 20 76 61 6c 75 65 73 0a 20 20 20 20 20 2a 2f 0a 20 | rray.of.default.values......*/.. |
41ac0 | 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 41 72 67 75 6d 65 6e 74 44 65 | ...public.function.getArgumentDe |
41ae0 | 66 61 75 6c 74 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 76 61 6c 75 65 73 20 3d | faults().....{.........$values.= |
41b00 | 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 74 68 69 73 | .array();.........foreach.($this |
41b20 | 2d 3e 61 72 67 75 6d 65 6e 74 73 20 61 73 20 24 61 72 67 75 6d 65 6e 74 29 20 7b 0a 20 20 20 20 | ->arguments.as.$argument).{..... |
41b40 | 20 20 20 20 20 20 20 20 24 76 61 6c 75 65 73 5b 24 61 72 67 75 6d 65 6e 74 2d 3e 67 65 74 4e 61 | ........$values[$argument->getNa |
41b60 | 6d 65 28 29 5d 20 3d 20 24 61 72 67 75 6d 65 6e 74 2d 3e 67 65 74 44 65 66 61 75 6c 74 28 29 3b | me()].=.$argument->getDefault(); |
41b80 | 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 76 61 6c 75 | .........}..........return.$valu |
41ba0 | 65 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 74 | es;.....}....../**......*.Sets.t |
41bc0 | 68 65 20 49 6e 70 75 74 4f 70 74 69 6f 6e 20 6f 62 6a 65 63 74 73 2e 0a 20 20 20 20 20 2a 0a 20 | he.InputOption.objects.......*.. |
41be0 | 20 20 20 20 2a 20 40 70 61 72 61 6d 20 49 6e 70 75 74 4f 70 74 69 6f 6e 5b 5d 20 24 6f 70 74 69 | ....*.@param.InputOption[].$opti |
41c00 | 6f 6e 73 20 41 6e 20 61 72 72 61 79 20 6f 66 20 49 6e 70 75 74 4f 70 74 69 6f 6e 20 6f 62 6a 65 | ons.An.array.of.InputOption.obje |
41c20 | 63 74 73 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 | cts......*/.....public.function. |
41c40 | 73 65 74 4f 70 74 69 6f 6e 73 28 24 6f 70 74 69 6f 6e 73 20 3d 20 61 72 72 61 79 28 29 29 0a 20 | setOptions($options.=.array()).. |
41c60 | 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6f 70 74 69 6f 6e 73 20 3d 20 61 72 | ...{.........$this->options.=.ar |
41c80 | 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 68 6f 72 74 63 75 74 73 20 | ray();.........$this->shortcuts. |
41ca0 | 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 61 64 64 4f 70 74 | =.array();.........$this->addOpt |
41cc0 | 69 6f 6e 73 28 24 6f 70 74 69 6f 6e 73 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 | ions($options);.....}....../**.. |
41ce0 | 20 20 20 20 2a 20 41 64 64 73 20 61 6e 20 61 72 72 61 79 20 6f 66 20 49 6e 70 75 74 4f 70 74 69 | ....*.Adds.an.array.of.InputOpti |
41d00 | 6f 6e 20 6f 62 6a 65 63 74 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d | on.objects.......*......*.@param |
41d20 | 20 49 6e 70 75 74 4f 70 74 69 6f 6e 5b 5d 20 24 6f 70 74 69 6f 6e 73 20 41 6e 20 61 72 72 61 79 | .InputOption[].$options.An.array |
41d40 | 20 6f 66 20 49 6e 70 75 74 4f 70 74 69 6f 6e 20 6f 62 6a 65 63 74 73 0a 20 20 20 20 20 2a 2f 0a | .of.InputOption.objects......*/. |
41d60 | 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 61 64 64 4f 70 74 69 6f 6e 73 28 24 | ....public.function.addOptions($ |
41d80 | 6f 70 74 69 6f 6e 73 20 3d 20 61 72 72 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 | options.=.array()).....{........ |
41da0 | 20 66 6f 72 65 61 63 68 20 28 24 6f 70 74 69 6f 6e 73 20 61 73 20 24 6f 70 74 69 6f 6e 29 20 7b | .foreach.($options.as.$option).{ |
41dc0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 61 64 64 4f 70 74 69 6f 6e 28 24 6f | .............$this->addOption($o |
41de0 | 70 74 69 6f 6e 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a | ption);.........}.....}....../** |
41e00 | 0a 20 20 20 20 20 2a 20 41 64 64 73 20 61 6e 20 49 6e 70 75 74 4f 70 74 69 6f 6e 20 6f 62 6a 65 | ......*.Adds.an.InputOption.obje |
41e20 | 63 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 49 6e 70 75 74 4f 70 | ct.......*......*.@param.InputOp |
41e40 | 74 69 6f 6e 20 24 6f 70 74 69 6f 6e 20 41 6e 20 49 6e 70 75 74 4f 70 74 69 6f 6e 20 6f 62 6a 65 | tion.$option.An.InputOption.obje |
41e60 | 63 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 4c 6f 67 69 63 45 78 | ct......*......*.@throws.LogicEx |
41e80 | 63 65 70 74 69 6f 6e 20 57 68 65 6e 20 6f 70 74 69 6f 6e 20 67 69 76 65 6e 20 61 6c 72 65 61 64 | ception.When.option.given.alread |
41ea0 | 79 20 65 78 69 73 74 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 | y.exist......*/.....public.funct |
41ec0 | 69 6f 6e 20 61 64 64 4f 70 74 69 6f 6e 28 49 6e 70 75 74 4f 70 74 69 6f 6e 20 24 6f 70 74 69 6f | ion.addOption(InputOption.$optio |
41ee0 | 6e 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 69 73 73 65 74 28 24 74 68 69 73 | n).....{.........if.(isset($this |
41f00 | 2d 3e 6f 70 74 69 6f 6e 73 5b 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 4e 61 6d 65 28 29 5d 29 20 26 | ->options[$option->getName()]).& |
41f20 | 26 20 21 24 6f 70 74 69 6f 6e 2d 3e 65 71 75 61 6c 73 28 24 74 68 69 73 2d 3e 6f 70 74 69 6f 6e | &.!$option->equals($this->option |
41f40 | 73 5b 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 4e 61 6d 65 28 29 5d 29 29 20 7b 0a 20 20 20 20 20 20 | s[$option->getName()])).{....... |
41f60 | 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 4c 6f 67 69 63 45 78 63 65 70 74 69 6f 6e 28 73 | ......throw.new.LogicException(s |
41f80 | 70 72 69 6e 74 66 28 27 41 6e 20 6f 70 74 69 6f 6e 20 6e 61 6d 65 64 20 22 25 73 22 20 61 6c 72 | printf('An.option.named."%s".alr |
41fa0 | 65 61 64 79 20 65 78 69 73 74 73 2e 27 2c 20 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 4e 61 6d 65 28 | eady.exists.',.$option->getName( |
41fc0 | 29 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 6f 70 74 | )));.........}..........if.($opt |
41fe0 | 69 6f 6e 2d 3e 67 65 74 53 68 6f 72 74 63 75 74 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | ion->getShortcut()).{........... |
42000 | 20 20 66 6f 72 65 61 63 68 20 28 65 78 70 6c 6f 64 65 28 27 7c 27 2c 20 24 6f 70 74 69 6f 6e 2d | ..foreach.(explode('|',.$option- |
42020 | 3e 67 65 74 53 68 6f 72 74 63 75 74 28 29 29 20 61 73 20 24 73 68 6f 72 74 63 75 74 29 20 7b 0a | >getShortcut()).as.$shortcut).{. |
42040 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 69 73 73 65 74 28 24 74 68 69 73 2d | ................if.(isset($this- |
42060 | 3e 73 68 6f 72 74 63 75 74 73 5b 24 73 68 6f 72 74 63 75 74 5d 29 20 26 26 20 21 24 6f 70 74 69 | >shortcuts[$shortcut]).&&.!$opti |
42080 | 6f 6e 2d 3e 65 71 75 61 6c 73 28 24 74 68 69 73 2d 3e 6f 70 74 69 6f 6e 73 5b 24 74 68 69 73 2d | on->equals($this->options[$this- |
420a0 | 3e 73 68 6f 72 74 63 75 74 73 5b 24 73 68 6f 72 74 63 75 74 5d 5d 29 29 20 7b 0a 20 20 20 20 20 | >shortcuts[$shortcut]])).{...... |
420c0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 4c 6f 67 69 63 45 78 | ...............throw.new.LogicEx |
420e0 | 63 65 70 74 69 6f 6e 28 73 70 72 69 6e 74 66 28 27 41 6e 20 6f 70 74 69 6f 6e 20 77 69 74 68 20 | ception(sprintf('An.option.with. |
42100 | 73 68 6f 72 74 63 75 74 20 22 25 73 22 20 61 6c 72 65 61 64 79 20 65 78 69 73 74 73 2e 27 2c 20 | shortcut."%s".already.exists.',. |
42120 | 24 73 68 6f 72 74 63 75 74 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 | $shortcut));.................}.. |
42140 | 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 | ...........}.........}.......... |
42160 | 24 74 68 69 73 2d 3e 6f 70 74 69 6f 6e 73 5b 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 4e 61 6d 65 28 | $this->options[$option->getName( |
42180 | 29 5d 20 3d 20 24 6f 70 74 69 6f 6e 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 6f 70 74 69 6f | )].=.$option;.........if.($optio |
421a0 | 6e 2d 3e 67 65 74 53 68 6f 72 74 63 75 74 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | n->getShortcut()).{............. |
421c0 | 66 6f 72 65 61 63 68 20 28 65 78 70 6c 6f 64 65 28 27 7c 27 2c 20 24 6f 70 74 69 6f 6e 2d 3e 67 | foreach.(explode('|',.$option->g |
421e0 | 65 74 53 68 6f 72 74 63 75 74 28 29 29 20 61 73 20 24 73 68 6f 72 74 63 75 74 29 20 7b 0a 20 20 | etShortcut()).as.$shortcut).{... |
42200 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 68 6f 72 74 63 75 74 73 5b 24 | ..............$this->shortcuts[$ |
42220 | 73 68 6f 72 74 63 75 74 5d 20 3d 20 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 4e 61 6d 65 28 29 3b 0a | shortcut].=.$option->getName();. |
42240 | 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 | ............}.........}.....}... |
42260 | 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 61 6e 20 49 6e 70 75 74 4f 70 | .../**......*.Returns.an.InputOp |
42280 | 74 69 6f 6e 20 62 79 20 6e 61 6d 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 | tion.by.name.......*......*.@par |
422a0 | 61 6d 20 73 74 72 69 6e 67 20 24 6e 61 6d 65 20 54 68 65 20 49 6e 70 75 74 4f 70 74 69 6f 6e 20 | am.string.$name.The.InputOption. |
422c0 | 6e 61 6d 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 49 6e 70 75 74 | name......*......*.@return.Input |
422e0 | 4f 70 74 69 6f 6e 20 41 20 49 6e 70 75 74 4f 70 74 69 6f 6e 20 6f 62 6a 65 63 74 0a 20 20 20 20 | Option.A.InputOption.object..... |
42300 | 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e | .*......*.@throws.InvalidArgumen |
42320 | 74 45 78 63 65 70 74 69 6f 6e 20 57 68 65 6e 20 6f 70 74 69 6f 6e 20 67 69 76 65 6e 20 64 6f 65 | tException.When.option.given.doe |
42340 | 73 6e 27 74 20 65 78 69 73 74 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 | sn't.exist......*/.....public.fu |
42360 | 6e 63 74 69 6f 6e 20 67 65 74 4f 70 74 69 6f 6e 28 24 6e 61 6d 65 29 0a 20 20 20 20 7b 0a 20 20 | nction.getOption($name).....{... |
42380 | 20 20 20 20 20 20 69 66 20 28 21 24 74 68 69 73 2d 3e 68 61 73 4f 70 74 69 6f 6e 28 24 6e 61 6d | ......if.(!$this->hasOption($nam |
423a0 | 65 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 61 | e)).{.............throw.new.Inva |
423c0 | 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 73 70 72 69 6e 74 66 28 27 54 68 | lidArgumentException(sprintf('Th |
423e0 | 65 20 22 2d 2d 25 73 22 20 6f 70 74 69 6f 6e 20 64 6f 65 73 20 6e 6f 74 20 65 78 69 73 74 2e 27 | e."--%s".option.does.not.exist.' |
42400 | 2c 20 24 6e 61 6d 65 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 | ,.$name));.........}..........re |
42420 | 74 75 72 6e 20 24 74 68 69 73 2d 3e 6f 70 74 69 6f 6e 73 5b 24 6e 61 6d 65 5d 3b 0a 20 20 20 20 | turn.$this->options[$name];..... |
42440 | 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 74 72 75 65 20 69 | }....../**......*.Returns.true.i |
42460 | 66 20 61 6e 20 49 6e 70 75 74 4f 70 74 69 6f 6e 20 6f 62 6a 65 63 74 20 65 78 69 73 74 73 20 62 | f.an.InputOption.object.exists.b |
42480 | 79 20 6e 61 6d 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 54 68 69 73 20 6d 65 74 68 6f | y.name.......*......*.This.metho |
424a0 | 64 20 63 61 6e 27 74 20 62 65 20 75 73 65 64 20 74 6f 20 63 68 65 63 6b 20 69 66 20 74 68 65 20 | d.can't.be.used.to.check.if.the. |
424c0 | 75 73 65 72 20 69 6e 63 6c 75 64 65 64 20 74 68 65 20 6f 70 74 69 6f 6e 20 77 68 65 6e 0a 20 20 | user.included.the.option.when... |
424e0 | 20 20 20 2a 20 65 78 65 63 75 74 69 6e 67 20 74 68 65 20 63 6f 6d 6d 61 6e 64 20 28 75 73 65 20 | ...*.executing.the.command.(use. |
42500 | 67 65 74 4f 70 74 69 6f 6e 28 29 20 69 6e 73 74 65 61 64 29 2e 0a 20 20 20 20 20 2a 0a 20 20 20 | getOption().instead).......*.... |
42520 | 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6e 61 6d 65 20 54 68 65 20 49 6e 70 75 | ..*.@param.string.$name.The.Inpu |
42540 | 74 4f 70 74 69 6f 6e 20 6e 61 6d 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 | tOption.name......*......*.@retu |
42560 | 72 6e 20 62 6f 6f 6c 20 74 72 75 65 20 69 66 20 74 68 65 20 49 6e 70 75 74 4f 70 74 69 6f 6e 20 | rn.bool.true.if.the.InputOption. |
42580 | 6f 62 6a 65 63 74 20 65 78 69 73 74 73 2c 20 66 61 6c 73 65 20 6f 74 68 65 72 77 69 73 65 0a 20 | object.exists,.false.otherwise.. |
425a0 | 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 68 61 73 4f 70 | ....*/.....public.function.hasOp |
425c0 | 74 69 6f 6e 28 24 6e 61 6d 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e | tion($name).....{.........return |
425e0 | 20 69 73 73 65 74 28 24 74 68 69 73 2d 3e 6f 70 74 69 6f 6e 73 5b 24 6e 61 6d 65 5d 29 3b 0a 20 | .isset($this->options[$name]);.. |
42600 | 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 61 72 | ...}....../**......*.Gets.the.ar |
42620 | 72 61 79 20 6f 66 20 49 6e 70 75 74 4f 70 74 69 6f 6e 20 6f 62 6a 65 63 74 73 2e 0a 20 20 20 20 | ray.of.InputOption.objects...... |
42640 | 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 49 6e 70 75 74 4f 70 74 69 6f 6e 5b 5d 20 | .*......*.@return.InputOption[]. |
42660 | 41 6e 20 61 72 72 61 79 20 6f 66 20 49 6e 70 75 74 4f 70 74 69 6f 6e 20 6f 62 6a 65 63 74 73 0a | An.array.of.InputOption.objects. |
42680 | 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 4f | .....*/.....public.function.getO |
426a0 | 70 74 69 6f 6e 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 | ptions().....{.........return.$t |
426c0 | 68 69 73 2d 3e 6f 70 74 69 6f 6e 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 | his->options;.....}....../**.... |
426e0 | 20 20 2a 20 52 65 74 75 72 6e 73 20 74 72 75 65 20 69 66 20 61 6e 20 49 6e 70 75 74 4f 70 74 69 | ..*.Returns.true.if.an.InputOpti |
42700 | 6f 6e 20 6f 62 6a 65 63 74 20 65 78 69 73 74 73 20 62 79 20 73 68 6f 72 74 63 75 74 2e 0a 20 20 | on.object.exists.by.shortcut.... |
42720 | 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6e 61 6d 65 20 | ...*......*.@param.string.$name. |
42740 | 54 68 65 20 49 6e 70 75 74 4f 70 74 69 6f 6e 20 73 68 6f 72 74 63 75 74 0a 20 20 20 20 20 2a 0a | The.InputOption.shortcut......*. |
42760 | 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 62 6f 6f 6c 20 74 72 75 65 20 69 66 20 74 68 65 20 | .....*.@return.bool.true.if.the. |
42780 | 49 6e 70 75 74 4f 70 74 69 6f 6e 20 6f 62 6a 65 63 74 20 65 78 69 73 74 73 2c 20 66 61 6c 73 65 | InputOption.object.exists,.false |
427a0 | 20 6f 74 68 65 72 77 69 73 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 | .otherwise......*/.....public.fu |
427c0 | 6e 63 74 69 6f 6e 20 68 61 73 53 68 6f 72 74 63 75 74 28 24 6e 61 6d 65 29 0a 20 20 20 20 7b 0a | nction.hasShortcut($name).....{. |
427e0 | 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 69 73 73 65 74 28 24 74 68 69 73 2d 3e 73 68 6f 72 | ........return.isset($this->shor |
42800 | 74 63 75 74 73 5b 24 6e 61 6d 65 5d 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 | tcuts[$name]);.....}....../**... |
42820 | 20 20 20 2a 20 47 65 74 73 20 61 6e 20 49 6e 70 75 74 4f 70 74 69 6f 6e 20 62 79 20 73 68 6f 72 | ...*.Gets.an.InputOption.by.shor |
42840 | 74 63 75 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e | tcut.......*......*.@param.strin |
42860 | 67 20 24 73 68 6f 72 74 63 75 74 20 74 68 65 20 53 68 6f 72 74 63 75 74 20 6e 61 6d 65 0a 20 20 | g.$shortcut.the.Shortcut.name... |
42880 | 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 49 6e 70 75 74 4f 70 74 69 6f 6e 20 | ...*......*.@return.InputOption. |
428a0 | 41 6e 20 49 6e 70 75 74 4f 70 74 69 6f 6e 20 6f 62 6a 65 63 74 0a 20 20 20 20 20 2a 2f 0a 20 20 | An.InputOption.object......*/... |
428c0 | 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 4f 70 74 69 6f 6e 46 6f 72 53 68 | ..public.function.getOptionForSh |
428e0 | 6f 72 74 63 75 74 28 24 73 68 6f 72 74 63 75 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | ortcut($shortcut).....{......... |
42900 | 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 67 65 74 4f 70 74 69 6f 6e 28 24 74 68 69 73 2d 3e 73 | return.$this->getOption($this->s |
42920 | 68 6f 72 74 63 75 74 54 6f 4e 61 6d 65 28 24 73 68 6f 72 74 63 75 74 29 29 3b 0a 20 20 20 20 7d | hortcutToName($shortcut));.....} |
42940 | 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 61 6e 20 61 72 72 61 79 20 6f | ....../**......*.Gets.an.array.o |
42960 | 66 20 64 65 66 61 75 6c 74 20 76 61 6c 75 65 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 | f.default.values.......*......*. |
42980 | 40 72 65 74 75 72 6e 20 61 72 72 61 79 20 41 6e 20 61 72 72 61 79 20 6f 66 20 61 6c 6c 20 64 65 | @return.array.An.array.of.all.de |
429a0 | 66 61 75 6c 74 20 76 61 6c 75 65 73 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 | fault.values......*/.....public. |
429c0 | 66 75 6e 63 74 69 6f 6e 20 67 65 74 4f 70 74 69 6f 6e 44 65 66 61 75 6c 74 73 28 29 0a 20 20 20 | function.getOptionDefaults().... |
429e0 | 20 7b 0a 20 20 20 20 20 20 20 20 24 76 61 6c 75 65 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 | .{.........$values.=.array();... |
42a00 | 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 74 68 69 73 2d 3e 6f 70 74 69 6f 6e 73 20 61 73 | ......foreach.($this->options.as |
42a20 | 20 24 6f 70 74 69 6f 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 76 61 6c 75 65 73 5b | .$option).{.............$values[ |
42a40 | 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 4e 61 6d 65 28 29 5d 20 3d 20 24 6f 70 74 69 6f 6e 2d 3e 67 | $option->getName()].=.$option->g |
42a60 | 65 74 44 65 66 61 75 6c 74 28 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 | etDefault();.........}.......... |
42a80 | 72 65 74 75 72 6e 20 24 76 61 6c 75 65 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 | return.$values;.....}....../**.. |
42aa0 | 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 74 68 65 20 49 6e 70 75 74 4f 70 74 69 6f 6e 20 6e 61 | ....*.Returns.the.InputOption.na |
42ac0 | 6d 65 20 67 69 76 65 6e 20 61 20 73 68 6f 72 74 63 75 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 | me.given.a.shortcut.......*..... |
42ae0 | 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 73 68 6f 72 74 63 75 74 20 54 68 65 20 73 | .*.@param.string.$shortcut.The.s |
42b00 | 68 6f 72 74 63 75 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 | hortcut......*......*.@return.st |
42b20 | 72 69 6e 67 20 54 68 65 20 49 6e 70 75 74 4f 70 74 69 6f 6e 20 6e 61 6d 65 0a 20 20 20 20 20 2a | ring.The.InputOption.name......* |
42b40 | 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 | ......*.@throws.InvalidArgumentE |
42b60 | 78 63 65 70 74 69 6f 6e 20 57 68 65 6e 20 6f 70 74 69 6f 6e 20 67 69 76 65 6e 20 64 6f 65 73 20 | xception.When.option.given.does. |
42b80 | 6e 6f 74 20 65 78 69 73 74 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 | not.exist......*/.....private.fu |
42ba0 | 6e 63 74 69 6f 6e 20 73 68 6f 72 74 63 75 74 54 6f 4e 61 6d 65 28 24 73 68 6f 72 74 63 75 74 29 | nction.shortcutToName($shortcut) |
42bc0 | 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 69 73 73 65 74 28 24 74 68 69 73 2d | .....{.........if.(!isset($this- |
42be0 | 3e 73 68 6f 72 74 63 75 74 73 5b 24 73 68 6f 72 74 63 75 74 5d 29 29 20 7b 0a 20 20 20 20 20 20 | >shortcuts[$shortcut])).{....... |
42c00 | 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 | ......throw.new.InvalidArgumentE |
42c20 | 78 63 65 70 74 69 6f 6e 28 73 70 72 69 6e 74 66 28 27 54 68 65 20 22 2d 25 73 22 20 6f 70 74 69 | xception(sprintf('The."-%s".opti |
42c40 | 6f 6e 20 64 6f 65 73 20 6e 6f 74 20 65 78 69 73 74 2e 27 2c 20 24 73 68 6f 72 74 63 75 74 29 29 | on.does.not.exist.',.$shortcut)) |
42c60 | 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 | ;.........}..........return.$thi |
42c80 | 73 2d 3e 73 68 6f 72 74 63 75 74 73 5b 24 73 68 6f 72 74 63 75 74 5d 3b 0a 20 20 20 20 7d 0a 0a | s->shortcuts[$shortcut];.....}.. |
42ca0 | 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 73 79 6e 6f 70 73 69 73 | ..../**......*.Gets.the.synopsis |
42cc0 | 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 62 6f 6f 6c 20 24 73 68 6f | .......*......*.@param.bool.$sho |
42ce0 | 72 74 20 57 68 65 74 68 65 72 20 74 6f 20 72 65 74 75 72 6e 20 74 68 65 20 73 68 6f 72 74 20 76 | rt.Whether.to.return.the.short.v |
42d00 | 65 72 73 69 6f 6e 20 28 77 69 74 68 20 6f 70 74 69 6f 6e 73 20 66 6f 6c 64 65 64 29 20 6f 72 20 | ersion.(with.options.folded).or. |
42d20 | 6e 6f 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 | not......*......*.@return.string |
42d40 | 20 54 68 65 20 73 79 6e 6f 70 73 69 73 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 | .The.synopsis......*/.....public |
42d60 | 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 53 79 6e 6f 70 73 69 73 28 24 73 68 6f 72 74 20 3d 20 66 | .function.getSynopsis($short.=.f |
42d80 | 61 6c 73 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 65 6c 65 6d 65 6e 74 73 20 3d 20 | alse).....{.........$elements.=. |
42da0 | 61 72 72 61 79 28 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 73 68 6f 72 74 20 26 26 20 | array();..........if.($short.&&. |
42dc0 | 24 74 68 69 73 2d 3e 67 65 74 4f 70 74 69 6f 6e 73 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | $this->getOptions()).{.......... |
42de0 | 20 20 20 24 65 6c 65 6d 65 6e 74 73 5b 5d 20 3d 20 27 5b 6f 70 74 69 6f 6e 73 5d 27 3b 0a 20 20 | ...$elements[].=.'[options]';... |
42e00 | 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 21 24 73 68 6f 72 74 29 20 7b 0a 20 20 20 20 20 | ......}.elseif.(!$short).{...... |
42e20 | 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 74 68 69 73 2d 3e 67 65 74 4f 70 74 69 6f 6e | .......foreach.($this->getOption |
42e40 | 73 28 29 20 61 73 20 24 6f 70 74 69 6f 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | s().as.$option).{............... |
42e60 | 20 20 24 76 61 6c 75 65 20 3d 20 27 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 | ..$value.=.'';.................i |
42e80 | 66 20 28 24 6f 70 74 69 6f 6e 2d 3e 61 63 63 65 70 74 56 61 6c 75 65 28 29 29 20 7b 0a 20 20 20 | f.($option->acceptValue()).{.... |
42ea0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 76 61 6c 75 65 20 3d 20 73 70 72 69 6e 74 | .................$value.=.sprint |
42ec0 | 66 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 27 20 25 73 25 | f(.........................'.%s% |
42ee0 | 73 25 73 27 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6f | s%s',.........................$o |
42f00 | 70 74 69 6f 6e 2d 3e 69 73 56 61 6c 75 65 4f 70 74 69 6f 6e 61 6c 28 29 20 3f 20 27 5b 27 20 3a | ption->isValueOptional().?.'['.: |
42f20 | 20 27 27 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 73 74 72 | .'',.........................str |
42f40 | 74 6f 75 70 70 65 72 28 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 4e 61 6d 65 28 29 29 2c 0a 20 20 20 | toupper($option->getName()),.... |
42f60 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 70 74 69 6f 6e 2d 3e 69 73 | .....................$option->is |
42f80 | 56 61 6c 75 65 4f 70 74 69 6f 6e 61 6c 28 29 20 3f 20 27 5d 27 20 3a 20 27 27 0a 20 20 20 20 20 | ValueOptional().?.']'.:.''...... |
42fa0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ...............);............... |
42fc0 | 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 73 68 6f 72 74 63 75 74 20 3d | ..}..................$shortcut.= |
42fe0 | 20 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 53 68 6f 72 74 63 75 74 28 29 20 3f 20 73 70 72 69 6e 74 | .$option->getShortcut().?.sprint |
43000 | 66 28 27 2d 25 73 7c 27 2c 20 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 53 68 6f 72 74 63 75 74 28 29 | f('-%s|',.$option->getShortcut() |
43020 | 29 20 3a 20 27 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 65 6c 65 6d 65 6e 74 | ).:.'';.................$element |
43040 | 73 5b 5d 20 3d 20 73 70 72 69 6e 74 66 28 27 5b 25 73 2d 2d 25 73 25 73 5d 27 2c 20 24 73 68 6f | s[].=.sprintf('[%s--%s%s]',.$sho |
43060 | 72 74 63 75 74 2c 20 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 4e 61 6d 65 28 29 2c 20 24 76 61 6c 75 | rtcut,.$option->getName(),.$valu |
43080 | 65 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 | e);.............}.........}..... |
430a0 | 20 20 20 20 20 69 66 20 28 63 6f 75 6e 74 28 24 65 6c 65 6d 65 6e 74 73 29 20 26 26 20 24 74 68 | .....if.(count($elements).&&.$th |
430c0 | 69 73 2d 3e 67 65 74 41 72 67 75 6d 65 6e 74 73 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | is->getArguments()).{........... |
430e0 | 20 20 24 65 6c 65 6d 65 6e 74 73 5b 5d 20 3d 20 27 5b 2d 2d 5d 27 3b 0a 20 20 20 20 20 20 20 20 | ..$elements[].=.'[--]';......... |
43100 | 7d 0a 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 74 68 69 73 2d 3e 67 65 74 41 72 | }..........foreach.($this->getAr |
43120 | 67 75 6d 65 6e 74 73 28 29 20 61 73 20 24 61 72 67 75 6d 65 6e 74 29 20 7b 0a 20 20 20 20 20 20 | guments().as.$argument).{....... |
43140 | 20 20 20 20 20 20 24 65 6c 65 6d 65 6e 74 20 3d 20 27 3c 27 2e 24 61 72 67 75 6d 65 6e 74 2d 3e | ......$element.=.'<'.$argument-> |
43160 | 67 65 74 4e 61 6d 65 28 29 2e 27 3e 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 21 | getName().'>';.............if.(! |
43180 | 24 61 72 67 75 6d 65 6e 74 2d 3e 69 73 52 65 71 75 69 72 65 64 28 29 29 20 7b 0a 20 20 20 20 20 | $argument->isRequired()).{...... |
431a0 | 20 20 20 20 20 20 20 20 20 20 20 24 65 6c 65 6d 65 6e 74 20 3d 20 27 5b 27 2e 24 65 6c 65 6d 65 | ...........$element.=.'['.$eleme |
431c0 | 6e 74 2e 27 5d 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 24 61 | nt.']';.............}.elseif.($a |
431e0 | 72 67 75 6d 65 6e 74 2d 3e 69 73 41 72 72 61 79 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | rgument->isArray()).{........... |
43200 | 20 20 20 20 20 20 24 65 6c 65 6d 65 6e 74 20 3d 20 24 65 6c 65 6d 65 6e 74 2e 27 20 28 27 2e 24 | ......$element.=.$element.'.('.$ |
43220 | 65 6c 65 6d 65 6e 74 2e 27 29 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 | element.')';.............}...... |
43240 | 20 20 20 20 20 20 20 20 69 66 20 28 24 61 72 67 75 6d 65 6e 74 2d 3e 69 73 41 72 72 61 79 28 29 | ........if.($argument->isArray() |
43260 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 65 6c 65 6d 65 6e 74 20 2e 3d 20 | ).{.................$element..=. |
43280 | 27 2e 2e 2e 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 | '...';.............}............ |
432a0 | 20 20 24 65 6c 65 6d 65 6e 74 73 5b 5d 20 3d 20 24 65 6c 65 6d 65 6e 74 3b 0a 20 20 20 20 20 20 | ..$elements[].=.$element;....... |
432c0 | 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 69 6d 70 6c 6f 64 65 28 27 20 27 2c | ..}..........return.implode('.', |
432e0 | 20 24 65 6c 65 6d 65 6e 74 73 29 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 | .$elements);.....}.}.<?php../*.. |
43300 | 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f | *.This.file.is.part.of.the.Symfo |
43320 | 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 | ny.package...*..*.(c).Fabien.Pot |
43340 | 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 | encier.<fabien@symfony.com>..*.. |
43360 | 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 | *.For.the.full.copyright.and.lic |
43380 | 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 | ense.information,.please.view.th |
433a0 | 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 | e.LICENSE..*.file.that.was.distr |
433c0 | 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a | ibuted.with.this.source.code...* |
433e0 | 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 | /..namespace.Symfony\Component\C |
43400 | 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 3b 0a 0a 2f 2a 2a 0a 20 2a 20 49 6e 70 75 74 41 77 61 72 65 | onsole\Input;../**..*.InputAware |
43420 | 49 6e 74 65 72 66 61 63 65 20 73 68 6f 75 6c 64 20 62 65 20 69 6d 70 6c 65 6d 65 6e 74 65 64 20 | Interface.should.be.implemented. |
43440 | 62 79 20 63 6c 61 73 73 65 73 20 74 68 61 74 20 64 65 70 65 6e 64 73 20 6f 6e 20 74 68 65 0a 20 | by.classes.that.depends.on.the.. |
43460 | 2a 20 43 6f 6e 73 6f 6c 65 20 49 6e 70 75 74 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 57 | *.Console.Input...*..*.@author.W |
43480 | 6f 75 74 65 72 20 4a 20 3c 77 61 6c 64 69 6f 2e 77 65 62 64 65 73 69 67 6e 40 67 6d 61 69 6c 2e | outer.J.<waldio.webdesign@gmail. |
434a0 | 63 6f 6d 3e 0a 20 2a 2f 0a 69 6e 74 65 72 66 61 63 65 20 49 6e 70 75 74 41 77 61 72 65 49 6e 74 | com>..*/.interface.InputAwareInt |
434c0 | 65 72 66 61 63 65 0a 7b 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 74 68 65 | erface.{...../**......*.Sets.the |
434e0 | 20 43 6f 6e 73 6f 6c 65 20 49 6e 70 75 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 | .Console.Input.......*......*.@p |
43500 | 61 72 61 6d 20 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 | aram.InputInterface......*/..... |
43520 | 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 49 6e 70 75 74 28 49 6e 70 75 74 49 6e | public.function.setInput(InputIn |
43540 | 74 65 72 66 61 63 65 20 24 69 6e 70 75 74 29 3b 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 | terface.$input);.}.<?php../*..*. |
43560 | 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 | This.file.is.part.of.the.Symfony |
43580 | 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e | .package...*..*.(c).Fabien.Poten |
435a0 | 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 | cier.<fabien@symfony.com>..*..*. |
435c0 | 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e | For.the.full.copyright.and.licen |
435e0 | 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 | se.information,.please.view.the. |
43600 | 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 | LICENSE..*.file.that.was.distrib |
43620 | 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a | uted.with.this.source.code...*/. |
43640 | 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e | .namespace.Symfony\Component\Con |
43660 | 73 6f 6c 65 5c 49 6e 70 75 74 3b 0a 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 | sole\Input;..use.Symfony\Compone |
43680 | 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 78 63 65 70 74 69 6f 6e 5c 49 6e 76 61 6c 69 64 41 72 67 75 | nt\Console\Exception\InvalidArgu |
436a0 | 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 3b 0a 0a 2f 2a 2a 0a 20 2a 20 53 74 72 69 6e 67 49 6e 70 | mentException;../**..*.StringInp |
436c0 | 75 74 20 72 65 70 72 65 73 65 6e 74 73 20 61 6e 20 69 6e 70 75 74 20 70 72 6f 76 69 64 65 64 20 | ut.represents.an.input.provided. |
436e0 | 61 73 20 61 20 73 74 72 69 6e 67 2e 0a 20 2a 0a 20 2a 20 55 73 61 67 65 3a 0a 20 2a 0a 20 2a 20 | as.a.string...*..*.Usage:..*..*. |
43700 | 20 20 20 20 24 69 6e 70 75 74 20 3d 20 6e 65 77 20 53 74 72 69 6e 67 49 6e 70 75 74 28 27 66 6f | ....$input.=.new.StringInput('fo |
43720 | 6f 20 2d 2d 62 61 72 3d 22 66 6f 6f 62 61 72 22 27 29 3b 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f | o.--bar="foobar"');..*..*.@autho |
43740 | 72 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f | r.Fabien.Potencier.<fabien@symfo |
43760 | 6e 79 2e 63 6f 6d 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 53 74 72 69 6e 67 49 6e 70 75 74 20 65 78 | ny.com>..*/.class.StringInput.ex |
43780 | 74 65 6e 64 73 20 41 72 67 76 49 6e 70 75 74 0a 7b 0a 20 20 20 20 63 6f 6e 73 74 20 52 45 47 45 | tends.ArgvInput.{.....const.REGE |
437a0 | 58 5f 53 54 52 49 4e 47 20 3d 20 27 28 5b 5e 5c 73 5d 2b 3f 29 28 3f 3a 5c 73 7c 28 3f 3c 21 5c | X_STRING.=.'([^\s]+?)(?:\s|(?<!\ |
437c0 | 5c 5c 5c 29 22 7c 28 3f 3c 21 5c 5c 5c 5c 29 5c 27 7c 24 29 27 3b 0a 20 20 20 20 63 6f 6e 73 74 | \\\)"|(?<!\\\\)\'|$)';.....const |
437e0 | 20 52 45 47 45 58 5f 51 55 4f 54 45 44 5f 53 54 52 49 4e 47 20 3d 20 27 28 3f 3a 22 28 5b 5e 22 | .REGEX_QUOTED_STRING.=.'(?:"([^" |
43800 | 5c 5c 5c 5c 5d 2a 28 3f 3a 5c 5c 5c 5c 2e 5b 5e 22 5c 5c 5c 5c 5d 2a 29 2a 29 22 7c 5c 27 28 5b | \\\\]*(?:\\\\.[^"\\\\]*)*)"|\'([ |
43820 | 5e 5c 27 5c 5c 5c 5c 5d 2a 28 3f 3a 5c 5c 5c 5c 2e 5b 5e 5c 27 5c 5c 5c 5c 5d 2a 29 2a 29 5c 27 | ^\'\\\\]*(?:\\\\.[^\'\\\\]*)*)\' |
43840 | 29 27 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 43 6f 6e 73 74 72 75 63 74 6f 72 2e | )';....../**......*.Constructor. |
43860 | 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 69 6e | ......*......*.@param.string.$in |
43880 | 70 75 74 20 41 6e 20 61 72 72 61 79 20 6f 66 20 70 61 72 61 6d 65 74 65 72 73 20 66 72 6f 6d 20 | put.An.array.of.parameters.from. |
438a0 | 74 68 65 20 43 4c 49 20 28 69 6e 20 74 68 65 20 61 72 67 76 20 66 6f 72 6d 61 74 29 0a 20 20 20 | the.CLI.(in.the.argv.format).... |
438c0 | 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 63 6f 6e 73 74 | ..*/.....public.function.__const |
438e0 | 72 75 63 74 28 24 69 6e 70 75 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 70 61 72 65 6e | ruct($input).....{.........paren |
43900 | 74 3a 3a 5f 5f 63 6f 6e 73 74 72 75 63 74 28 61 72 72 61 79 28 29 29 3b 0a 0a 20 20 20 20 20 20 | t::__construct(array());........ |
43920 | 20 20 24 74 68 69 73 2d 3e 73 65 74 54 6f 6b 65 6e 73 28 24 74 68 69 73 2d 3e 74 6f 6b 65 6e 69 | ..$this->setTokens($this->tokeni |
43940 | 7a 65 28 24 69 6e 70 75 74 29 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 | ze($input));.....}....../**..... |
43960 | 20 2a 20 54 6f 6b 65 6e 69 7a 65 73 20 61 20 73 74 72 69 6e 67 2e 0a 20 20 20 20 20 2a 0a 20 20 | .*.Tokenizes.a.string.......*... |
43980 | 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 69 6e 70 75 74 20 54 68 65 20 69 6e | ...*.@param.string.$input.The.in |
439a0 | 70 75 74 20 74 6f 20 74 6f 6b 65 6e 69 7a 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 | put.to.tokenize......*......*.@r |
439c0 | 65 74 75 72 6e 20 61 72 72 61 79 20 41 6e 20 61 72 72 61 79 20 6f 66 20 74 6f 6b 65 6e 73 0a 20 | eturn.array.An.array.of.tokens.. |
439e0 | 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 49 6e 76 61 6c 69 64 41 72 67 75 | ....*......*.@throws.InvalidArgu |
43a00 | 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 20 57 68 65 6e 20 75 6e 61 62 6c 65 20 74 6f 20 70 61 72 | mentException.When.unable.to.par |
43a20 | 73 65 20 69 6e 70 75 74 20 28 73 68 6f 75 6c 64 20 6e 65 76 65 72 20 68 61 70 70 65 6e 29 0a 20 | se.input.(should.never.happen).. |
43a40 | 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 74 6f 6b 65 | ....*/.....private.function.toke |
43a60 | 6e 69 7a 65 28 24 69 6e 70 75 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 6f 6b 65 | nize($input).....{.........$toke |
43a80 | 6e 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 24 6c 65 6e 67 74 68 20 3d 20 | ns.=.array();.........$length.=. |
43aa0 | 73 74 72 6c 65 6e 28 24 69 6e 70 75 74 29 3b 0a 20 20 20 20 20 20 20 20 24 63 75 72 73 6f 72 20 | strlen($input);.........$cursor. |
43ac0 | 3d 20 30 3b 0a 20 20 20 20 20 20 20 20 77 68 69 6c 65 20 28 24 63 75 72 73 6f 72 20 3c 20 24 6c | =.0;.........while.($cursor.<.$l |
43ae0 | 65 6e 67 74 68 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 70 72 65 67 5f 6d 61 | ength).{.............if.(preg_ma |
43b00 | 74 63 68 28 27 2f 5c 73 2b 2f 41 27 2c 20 24 69 6e 70 75 74 2c 20 24 6d 61 74 63 68 2c 20 6e 75 | tch('/\s+/A',.$input,.$match,.nu |
43b20 | 6c 6c 2c 20 24 63 75 72 73 6f 72 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c | ll,.$cursor)).{.............}.el |
43b40 | 73 65 69 66 20 28 70 72 65 67 5f 6d 61 74 63 68 28 27 2f 28 5b 5e 3d 22 5c 27 5c 73 5d 2b 3f 29 | seif.(preg_match('/([^="\'\s]+?) |
43b60 | 28 3d 3f 29 28 27 2e 73 65 6c 66 3a 3a 52 45 47 45 58 5f 51 55 4f 54 45 44 5f 53 54 52 49 4e 47 | (=?)('.self::REGEX_QUOTED_STRING |
43b80 | 2e 27 2b 29 2f 41 27 2c 20 24 69 6e 70 75 74 2c 20 24 6d 61 74 63 68 2c 20 6e 75 6c 6c 2c 20 24 | .'+)/A',.$input,.$match,.null,.$ |
43ba0 | 63 75 72 73 6f 72 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 6f 6b 65 | cursor)).{.................$toke |
43bc0 | 6e 73 5b 5d 20 3d 20 24 6d 61 74 63 68 5b 31 5d 2e 24 6d 61 74 63 68 5b 32 5d 2e 73 74 72 69 70 | ns[].=.$match[1].$match[2].strip |
43be0 | 63 73 6c 61 73 68 65 73 28 73 74 72 5f 72 65 70 6c 61 63 65 28 61 72 72 61 79 28 27 22 5c 27 27 | cslashes(str_replace(array('"\'' |
43c00 | 2c 20 27 5c 27 22 27 2c 20 27 5c 27 5c 27 27 2c 20 27 22 22 27 29 2c 20 27 27 2c 20 73 75 62 73 | ,.'\'"',.'\'\'',.'""'),.'',.subs |
43c20 | 74 72 28 24 6d 61 74 63 68 5b 33 5d 2c 20 31 2c 20 73 74 72 6c 65 6e 28 24 6d 61 74 63 68 5b 33 | tr($match[3],.1,.strlen($match[3 |
43c40 | 5d 29 20 2d 20 32 29 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 | ]).-.2)));.............}.elseif. |
43c60 | 28 70 72 65 67 5f 6d 61 74 63 68 28 27 2f 27 2e 73 65 6c 66 3a 3a 52 45 47 45 58 5f 51 55 4f 54 | (preg_match('/'.self::REGEX_QUOT |
43c80 | 45 44 5f 53 54 52 49 4e 47 2e 27 2f 41 27 2c 20 24 69 6e 70 75 74 2c 20 24 6d 61 74 63 68 2c 20 | ED_STRING.'/A',.$input,.$match,. |
43ca0 | 6e 75 6c 6c 2c 20 24 63 75 72 73 6f 72 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | null,.$cursor)).{............... |
43cc0 | 20 20 24 74 6f 6b 65 6e 73 5b 5d 20 3d 20 73 74 72 69 70 63 73 6c 61 73 68 65 73 28 73 75 62 73 | ..$tokens[].=.stripcslashes(subs |
43ce0 | 74 72 28 24 6d 61 74 63 68 5b 30 5d 2c 20 31 2c 20 73 74 72 6c 65 6e 28 24 6d 61 74 63 68 5b 30 | tr($match[0],.1,.strlen($match[0 |
43d00 | 5d 29 20 2d 20 32 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 | ]).-.2));.............}.elseif.( |
43d20 | 70 72 65 67 5f 6d 61 74 63 68 28 27 2f 27 2e 73 65 6c 66 3a 3a 52 45 47 45 58 5f 53 54 52 49 4e | preg_match('/'.self::REGEX_STRIN |
43d40 | 47 2e 27 2f 41 27 2c 20 24 69 6e 70 75 74 2c 20 24 6d 61 74 63 68 2c 20 6e 75 6c 6c 2c 20 24 63 | G.'/A',.$input,.$match,.null,.$c |
43d60 | 75 72 73 6f 72 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 6f 6b 65 6e | ursor)).{.................$token |
43d80 | 73 5b 5d 20 3d 20 73 74 72 69 70 63 73 6c 61 73 68 65 73 28 24 6d 61 74 63 68 5b 31 5d 29 3b 0a | s[].=.stripcslashes($match[1]);. |
43da0 | 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | ............}.else.{............ |
43dc0 | 20 20 20 20 20 2f 2f 20 73 68 6f 75 6c 64 20 6e 65 76 65 72 20 68 61 70 70 65 6e 0a 20 20 20 20 | .....//.should.never.happen..... |
43de0 | 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 61 6c 69 64 41 72 67 | ............throw.new.InvalidArg |
43e00 | 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 73 70 72 69 6e 74 66 28 27 55 6e 61 62 6c 65 20 74 | umentException(sprintf('Unable.t |
43e20 | 6f 20 70 61 72 73 65 20 69 6e 70 75 74 20 6e 65 61 72 20 22 2e 2e 2e 20 25 73 20 2e 2e 2e 22 27 | o.parse.input.near."....%s...."' |
43e40 | 2c 20 73 75 62 73 74 72 28 24 69 6e 70 75 74 2c 20 24 63 75 72 73 6f 72 2c 20 31 30 29 29 29 3b | ,.substr($input,.$cursor,.10))); |
43e60 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 63 75 72 | .............}..............$cur |
43e80 | 73 6f 72 20 2b 3d 20 73 74 72 6c 65 6e 28 24 6d 61 74 63 68 5b 30 5d 29 3b 0a 20 20 20 20 20 20 | sor.+=.strlen($match[0]);....... |
43ea0 | 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 6f 6b 65 6e 73 3b 0a 20 20 20 | ..}..........return.$tokens;.... |
43ec0 | 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 | .}.}.<?php../*..*.This.file.is.p |
43ee0 | 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 | art.of.the.Symfony.package...*.. |
43f00 | 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 | *.(c).Fabien.Potencier.<fabien@s |
43f20 | 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 | ymfony.com>..*..*.For.the.full.c |
43f40 | 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e | opyright.and.license.information |
43f60 | 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c | ,.please.view.the.LICENSE..*.fil |
43f80 | 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 | e.that.was.distributed.with.this |
43fa0 | 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d | .source.code...*/..namespace.Sym |
43fc0 | 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 3b 0a 0a 75 | fony\Component\Console\Input;..u |
43fe0 | 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 78 63 | se.Symfony\Component\Console\Exc |
44000 | 65 70 74 69 6f 6e 5c 52 75 6e 74 69 6d 65 45 78 63 65 70 74 69 6f 6e 3b 0a 0a 2f 2a 2a 0a 20 2a | eption\RuntimeException;../**..* |
44020 | 20 41 72 67 76 49 6e 70 75 74 20 72 65 70 72 65 73 65 6e 74 73 20 61 6e 20 69 6e 70 75 74 20 63 | .ArgvInput.represents.an.input.c |
44040 | 6f 6d 69 6e 67 20 66 72 6f 6d 20 74 68 65 20 43 4c 49 20 61 72 67 75 6d 65 6e 74 73 2e 0a 20 2a | oming.from.the.CLI.arguments...* |
44060 | 0a 20 2a 20 55 73 61 67 65 3a 0a 20 2a 0a 20 2a 20 20 20 20 20 24 69 6e 70 75 74 20 3d 20 6e 65 | ..*.Usage:..*..*.....$input.=.ne |
44080 | 77 20 41 72 67 76 49 6e 70 75 74 28 29 3b 0a 20 2a 0a 20 2a 20 42 79 20 64 65 66 61 75 6c 74 2c | w.ArgvInput();..*..*.By.default, |
440a0 | 20 74 68 65 20 60 24 5f 53 45 52 56 45 52 5b 27 61 72 67 76 27 5d 60 20 61 72 72 61 79 20 69 73 | .the.`$_SERVER['argv']`.array.is |
440c0 | 20 75 73 65 64 20 66 6f 72 20 74 68 65 20 69 6e 70 75 74 20 76 61 6c 75 65 73 2e 0a 20 2a 0a 20 | .used.for.the.input.values...*.. |
440e0 | 2a 20 54 68 69 73 20 63 61 6e 20 62 65 20 6f 76 65 72 72 69 64 64 65 6e 20 62 79 20 65 78 70 6c | *.This.can.be.overridden.by.expl |
44100 | 69 63 69 74 6c 79 20 70 61 73 73 69 6e 67 20 74 68 65 20 69 6e 70 75 74 20 76 61 6c 75 65 73 20 | icitly.passing.the.input.values. |
44120 | 69 6e 20 74 68 65 20 63 6f 6e 73 74 72 75 63 74 6f 72 3a 0a 20 2a 0a 20 2a 20 20 20 20 20 24 69 | in.the.constructor:..*..*.....$i |
44140 | 6e 70 75 74 20 3d 20 6e 65 77 20 41 72 67 76 49 6e 70 75 74 28 24 5f 53 45 52 56 45 52 5b 27 61 | nput.=.new.ArgvInput($_SERVER['a |
44160 | 72 67 76 27 5d 29 3b 0a 20 2a 0a 20 2a 20 49 66 20 79 6f 75 20 70 61 73 73 20 69 74 20 79 6f 75 | rgv']);..*..*.If.you.pass.it.you |
44180 | 72 73 65 6c 66 2c 20 64 6f 6e 27 74 20 66 6f 72 67 65 74 20 74 68 61 74 20 74 68 65 20 66 69 72 | rself,.don't.forget.that.the.fir |
441a0 | 73 74 20 65 6c 65 6d 65 6e 74 20 6f 66 20 74 68 65 20 61 72 72 61 79 0a 20 2a 20 69 73 20 74 68 | st.element.of.the.array..*.is.th |
441c0 | 65 20 6e 61 6d 65 20 6f 66 20 74 68 65 20 72 75 6e 6e 69 6e 67 20 61 70 70 6c 69 63 61 74 69 6f | e.name.of.the.running.applicatio |
441e0 | 6e 2e 0a 20 2a 0a 20 2a 20 57 68 65 6e 20 70 61 73 73 69 6e 67 20 61 6e 20 61 72 67 75 6d 65 6e | n...*..*.When.passing.an.argumen |
44200 | 74 20 74 6f 20 74 68 65 20 63 6f 6e 73 74 72 75 63 74 6f 72 2c 20 62 65 20 73 75 72 65 20 74 68 | t.to.the.constructor,.be.sure.th |
44220 | 61 74 20 69 74 20 72 65 73 70 65 63 74 73 0a 20 2a 20 74 68 65 20 73 61 6d 65 20 72 75 6c 65 73 | at.it.respects..*.the.same.rules |
44240 | 20 61 73 20 74 68 65 20 61 72 67 76 20 6f 6e 65 2e 20 49 74 27 73 20 61 6c 6d 6f 73 74 20 61 6c | .as.the.argv.one..It's.almost.al |
44260 | 77 61 79 73 20 62 65 74 74 65 72 20 74 6f 20 75 73 65 20 74 68 65 0a 20 2a 20 60 53 74 72 69 6e | ways.better.to.use.the..*.`Strin |
44280 | 67 49 6e 70 75 74 60 20 77 68 65 6e 20 79 6f 75 20 77 61 6e 74 20 74 6f 20 70 72 6f 76 69 64 65 | gInput`.when.you.want.to.provide |
442a0 | 20 79 6f 75 72 20 6f 77 6e 20 69 6e 70 75 74 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 46 | .your.own.input...*..*.@author.F |
442c0 | 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e | abien.Potencier.<fabien@symfony. |
442e0 | 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 40 73 65 65 20 68 74 74 70 3a 2f 2f 77 77 77 2e 67 6e 75 2e 6f | com>..*..*.@see.http://www.gnu.o |
44300 | 72 67 2f 73 6f 66 74 77 61 72 65 2f 6c 69 62 63 2f 6d 61 6e 75 61 6c 2f 68 74 6d 6c 5f 6e 6f 64 | rg/software/libc/manual/html_nod |
44320 | 65 2f 41 72 67 75 6d 65 6e 74 2d 53 79 6e 74 61 78 2e 68 74 6d 6c 0a 20 2a 20 40 73 65 65 20 68 | e/Argument-Syntax.html..*.@see.h |
44340 | 74 74 70 3a 2f 2f 77 77 77 2e 6f 70 65 6e 67 72 6f 75 70 2e 6f 72 67 2f 6f 6e 6c 69 6e 65 70 75 | ttp://www.opengroup.org/onlinepu |
44360 | 62 73 2f 30 30 39 36 39 35 33 39 39 2f 62 61 73 65 64 65 66 73 2f 78 62 64 5f 63 68 61 70 31 32 | bs/009695399/basedefs/xbd_chap12 |
44380 | 2e 68 74 6d 6c 23 74 61 67 5f 31 32 5f 30 32 0a 20 2a 2f 0a 63 6c 61 73 73 20 41 72 67 76 49 6e | .html#tag_12_02..*/.class.ArgvIn |
443a0 | 70 75 74 20 65 78 74 65 6e 64 73 20 49 6e 70 75 74 0a 7b 0a 20 20 20 20 70 72 69 76 61 74 65 20 | put.extends.Input.{.....private. |
443c0 | 24 74 6f 6b 65 6e 73 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 70 61 72 73 65 64 3b 0a 0a 20 | $tokens;.....private.$parsed;... |
443e0 | 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 43 6f 6e 73 74 72 75 63 74 6f 72 2e 0a 20 20 20 20 20 | .../**......*.Constructor....... |
44400 | 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 7c 6e 75 6c 6c 20 20 20 20 20 20 | *......*.@param.array|null...... |
44420 | 20 20 20 20 20 24 61 72 67 76 20 20 20 20 20 20 20 41 6e 20 61 72 72 61 79 20 6f 66 20 70 61 72 | .....$argv.......An.array.of.par |
44440 | 61 6d 65 74 65 72 73 20 66 72 6f 6d 20 74 68 65 20 43 4c 49 20 28 69 6e 20 74 68 65 20 61 72 67 | ameters.from.the.CLI.(in.the.arg |
44460 | 76 20 66 6f 72 6d 61 74 29 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 49 6e 70 75 74 44 65 66 | v.format)......*.@param.InputDef |
44480 | 69 6e 69 74 69 6f 6e 7c 6e 75 6c 6c 20 24 64 65 66 69 6e 69 74 69 6f 6e 20 41 20 49 6e 70 75 74 | inition|null.$definition.A.Input |
444a0 | 44 65 66 69 6e 69 74 69 6f 6e 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 | Definition.instance......*/..... |
444c0 | 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 74 28 61 72 72 61 | public.function.__construct(arra |
444e0 | 79 20 24 61 72 67 76 20 3d 20 6e 75 6c 6c 2c 20 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 20 | y.$argv.=.null,.InputDefinition. |
44500 | 24 64 65 66 69 6e 69 74 69 6f 6e 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 | $definition.=.null).....{....... |
44520 | 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 61 72 67 76 29 20 7b 0a 20 20 20 20 20 20 20 20 | ..if.(null.===.$argv).{......... |
44540 | 20 20 20 20 24 61 72 67 76 20 3d 20 24 5f 53 45 52 56 45 52 5b 27 61 72 67 76 27 5d 3b 0a 20 20 | ....$argv.=.$_SERVER['argv'];... |
44560 | 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 2f 2f 20 73 74 72 69 70 20 74 68 65 20 61 70 | ......}..........//.strip.the.ap |
44580 | 70 6c 69 63 61 74 69 6f 6e 20 6e 61 6d 65 0a 20 20 20 20 20 20 20 20 61 72 72 61 79 5f 73 68 69 | plication.name.........array_shi |
445a0 | 66 74 28 24 61 72 67 76 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 74 6f 6b 65 6e | ft($argv);..........$this->token |
445c0 | 73 20 3d 20 24 61 72 67 76 3b 0a 0a 20 20 20 20 20 20 20 20 70 61 72 65 6e 74 3a 3a 5f 5f 63 6f | s.=.$argv;..........parent::__co |
445e0 | 6e 73 74 72 75 63 74 28 24 64 65 66 69 6e 69 74 69 6f 6e 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 | nstruct($definition);.....}..... |
44600 | 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 54 6f 6b 65 6e 73 28 61 72 | .protected.function.setTokens(ar |
44620 | 72 61 79 20 24 74 6f 6b 65 6e 73 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 | ray.$tokens).....{.........$this |
44640 | 2d 3e 74 6f 6b 65 6e 73 20 3d 20 24 74 6f 6b 65 6e 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f | ->tokens.=.$tokens;.....}....../ |
44660 | 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a | **......*.{@inheritdoc}......*/. |
44680 | 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 70 61 72 73 65 28 29 0a 20 | ....protected.function.parse().. |
446a0 | 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 70 61 72 73 65 4f 70 74 69 6f 6e 73 20 3d 20 74 72 75 | ...{.........$parseOptions.=.tru |
446c0 | 65 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 70 61 72 73 65 64 20 3d 20 24 74 68 69 73 | e;.........$this->parsed.=.$this |
446e0 | 2d 3e 74 6f 6b 65 6e 73 3b 0a 20 20 20 20 20 20 20 20 77 68 69 6c 65 20 28 6e 75 6c 6c 20 21 3d | ->tokens;.........while.(null.!= |
44700 | 3d 20 24 74 6f 6b 65 6e 20 3d 20 61 72 72 61 79 5f 73 68 69 66 74 28 24 74 68 69 73 2d 3e 70 61 | =.$token.=.array_shift($this->pa |
44720 | 72 73 65 64 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 70 61 72 73 65 4f | rsed)).{.............if.($parseO |
44740 | 70 74 69 6f 6e 73 20 26 26 20 27 27 20 3d 3d 20 24 74 6f 6b 65 6e 29 20 7b 0a 20 20 20 20 20 20 | ptions.&&.''.==.$token).{....... |
44760 | 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 70 61 72 73 65 41 72 67 75 6d 65 6e 74 28 24 | ..........$this->parseArgument($ |
44780 | 74 6f 6b 65 6e 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 24 70 | token);.............}.elseif.($p |
447a0 | 61 72 73 65 4f 70 74 69 6f 6e 73 20 26 26 20 27 2d 2d 27 20 3d 3d 20 24 74 6f 6b 65 6e 29 20 7b | arseOptions.&&.'--'.==.$token).{ |
447c0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 70 61 72 73 65 4f 70 74 69 6f 6e 73 20 3d | .................$parseOptions.= |
447e0 | 20 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 24 70 | .false;.............}.elseif.($p |
44800 | 61 72 73 65 4f 70 74 69 6f 6e 73 20 26 26 20 30 20 3d 3d 3d 20 73 74 72 70 6f 73 28 24 74 6f 6b | arseOptions.&&.0.===.strpos($tok |
44820 | 65 6e 2c 20 27 2d 2d 27 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 | en,.'--')).{.................$th |
44840 | 69 73 2d 3e 70 61 72 73 65 4c 6f 6e 67 4f 70 74 69 6f 6e 28 24 74 6f 6b 65 6e 29 3b 0a 20 20 20 | is->parseLongOption($token);.... |
44860 | 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 24 70 61 72 73 65 4f 70 74 69 6f 6e 73 | .........}.elseif.($parseOptions |
44880 | 20 26 26 20 27 2d 27 20 3d 3d 3d 20 24 74 6f 6b 65 6e 5b 30 5d 20 26 26 20 27 2d 27 20 21 3d 3d | .&&.'-'.===.$token[0].&&.'-'.!== |
448a0 | 20 24 74 6f 6b 65 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 | .$token).{.................$this |
448c0 | 2d 3e 70 61 72 73 65 53 68 6f 72 74 4f 70 74 69 6f 6e 28 24 74 6f 6b 65 6e 29 3b 0a 20 20 20 20 | ->parseShortOption($token);..... |
448e0 | 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ........}.else.{................ |
44900 | 20 24 74 68 69 73 2d 3e 70 61 72 73 65 41 72 67 75 6d 65 6e 74 28 24 74 6f 6b 65 6e 29 3b 0a 20 | .$this->parseArgument($token);.. |
44920 | 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 | ...........}.........}.....}.... |
44940 | 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 50 61 72 73 65 73 20 61 20 73 68 6f 72 74 20 6f 70 74 69 | ../**......*.Parses.a.short.opti |
44960 | 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 | on.......*......*.@param.string. |
44980 | 24 74 6f 6b 65 6e 20 54 68 65 20 63 75 72 72 65 6e 74 20 74 6f 6b 65 6e 0a 20 20 20 20 20 2a 2f | $token.The.current.token......*/ |
449a0 | 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 70 61 72 73 65 53 68 6f 72 74 | .....private.function.parseShort |
449c0 | 4f 70 74 69 6f 6e 28 24 74 6f 6b 65 6e 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 6e 61 | Option($token).....{.........$na |
449e0 | 6d 65 20 3d 20 73 75 62 73 74 72 28 24 74 6f 6b 65 6e 2c 20 31 29 3b 0a 0a 20 20 20 20 20 20 20 | me.=.substr($token,.1);......... |
44a00 | 20 69 66 20 28 73 74 72 6c 65 6e 28 24 6e 61 6d 65 29 20 3e 20 31 29 20 7b 0a 20 20 20 20 20 20 | .if.(strlen($name).>.1).{....... |
44a20 | 20 20 20 20 20 20 69 66 20 28 24 74 68 69 73 2d 3e 64 65 66 69 6e 69 74 69 6f 6e 2d 3e 68 61 73 | ......if.($this->definition->has |
44a40 | 53 68 6f 72 74 63 75 74 28 24 6e 61 6d 65 5b 30 5d 29 20 26 26 20 24 74 68 69 73 2d 3e 64 65 66 | Shortcut($name[0]).&&.$this->def |
44a60 | 69 6e 69 74 69 6f 6e 2d 3e 67 65 74 4f 70 74 69 6f 6e 46 6f 72 53 68 6f 72 74 63 75 74 28 24 6e | inition->getOptionForShortcut($n |
44a80 | 61 6d 65 5b 30 5d 29 2d 3e 61 63 63 65 70 74 56 61 6c 75 65 28 29 29 20 7b 0a 20 20 20 20 20 20 | ame[0])->acceptValue()).{....... |
44aa0 | 20 20 20 20 20 20 20 20 20 20 2f 2f 20 61 6e 20 6f 70 74 69 6f 6e 20 77 69 74 68 20 61 20 76 61 | ..........//.an.option.with.a.va |
44ac0 | 6c 75 65 20 28 77 69 74 68 20 6e 6f 20 73 70 61 63 65 29 0a 20 20 20 20 20 20 20 20 20 20 20 20 | lue.(with.no.space)............. |
44ae0 | 20 20 20 20 24 74 68 69 73 2d 3e 61 64 64 53 68 6f 72 74 4f 70 74 69 6f 6e 28 24 6e 61 6d 65 5b | ....$this->addShortOption($name[ |
44b00 | 30 5d 2c 20 73 75 62 73 74 72 28 24 6e 61 6d 65 2c 20 31 29 29 3b 0a 20 20 20 20 20 20 20 20 20 | 0],.substr($name,.1));.......... |
44b20 | 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 | ...}.else.{.................$thi |
44b40 | 73 2d 3e 70 61 72 73 65 53 68 6f 72 74 4f 70 74 69 6f 6e 53 65 74 28 24 6e 61 6d 65 29 3b 0a 20 | s->parseShortOptionSet($name);.. |
44b60 | 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 | ...........}.........}.else.{... |
44b80 | 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 61 64 64 53 68 6f 72 74 4f 70 74 69 6f 6e 28 | ..........$this->addShortOption( |
44ba0 | 24 6e 61 6d 65 2c 20 6e 75 6c 6c 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 | $name,.null);.........}.....}... |
44bc0 | 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 50 61 72 73 65 73 20 61 20 73 68 6f 72 74 20 6f 70 74 | .../**......*.Parses.a.short.opt |
44be0 | 69 6f 6e 20 73 65 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 | ion.set.......*......*.@param.st |
44c00 | 72 69 6e 67 20 24 6e 61 6d 65 20 54 68 65 20 63 75 72 72 65 6e 74 20 74 6f 6b 65 6e 0a 20 20 20 | ring.$name.The.current.token.... |
44c20 | 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 52 75 6e 74 69 6d 65 45 78 63 65 70 74 | ..*......*.@throws.RuntimeExcept |
44c40 | 69 6f 6e 20 57 68 65 6e 20 6f 70 74 69 6f 6e 20 67 69 76 65 6e 20 64 6f 65 73 6e 27 74 20 65 78 | ion.When.option.given.doesn't.ex |
44c60 | 69 73 74 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e | ist......*/.....private.function |
44c80 | 20 70 61 72 73 65 53 68 6f 72 74 4f 70 74 69 6f 6e 53 65 74 28 24 6e 61 6d 65 29 0a 20 20 20 20 | .parseShortOptionSet($name)..... |
44ca0 | 7b 0a 20 20 20 20 20 20 20 20 24 6c 65 6e 20 3d 20 73 74 72 6c 65 6e 28 24 6e 61 6d 65 29 3b 0a | {.........$len.=.strlen($name);. |
44cc0 | 20 20 20 20 20 20 20 20 66 6f 72 20 28 24 69 20 3d 20 30 3b 20 24 69 20 3c 20 24 6c 65 6e 3b 20 | ........for.($i.=.0;.$i.<.$len;. |
44ce0 | 2b 2b 24 69 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 21 24 74 68 69 73 2d 3e | ++$i).{.............if.(!$this-> |
44d00 | 64 65 66 69 6e 69 74 69 6f 6e 2d 3e 68 61 73 53 68 6f 72 74 63 75 74 28 24 6e 61 6d 65 5b 24 69 | definition->hasShortcut($name[$i |
44d20 | 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 | ])).{.................throw.new. |
44d40 | 52 75 6e 74 69 6d 65 45 78 63 65 70 74 69 6f 6e 28 73 70 72 69 6e 74 66 28 27 54 68 65 20 22 2d | RuntimeException(sprintf('The."- |
44d60 | 25 73 22 20 6f 70 74 69 6f 6e 20 64 6f 65 73 20 6e 6f 74 20 65 78 69 73 74 2e 27 2c 20 24 6e 61 | %s".option.does.not.exist.',.$na |
44d80 | 6d 65 5b 24 69 5d 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 | me[$i]));.............}......... |
44da0 | 20 20 20 20 20 24 6f 70 74 69 6f 6e 20 3d 20 24 74 68 69 73 2d 3e 64 65 66 69 6e 69 74 69 6f 6e | .....$option.=.$this->definition |
44dc0 | 2d 3e 67 65 74 4f 70 74 69 6f 6e 46 6f 72 53 68 6f 72 74 63 75 74 28 24 6e 61 6d 65 5b 24 69 5d | ->getOptionForShortcut($name[$i] |
44de0 | 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 6f 70 74 69 6f 6e 2d 3e 61 63 63 65 | );.............if.($option->acce |
44e00 | 70 74 56 61 6c 75 65 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 | ptValue()).{.................$th |
44e20 | 69 73 2d 3e 61 64 64 4c 6f 6e 67 4f 70 74 69 6f 6e 28 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 4e 61 | is->addLongOption($option->getNa |
44e40 | 6d 65 28 29 2c 20 24 69 20 3d 3d 3d 20 24 6c 65 6e 20 2d 20 31 20 3f 20 6e 75 6c 6c 20 3a 20 73 | me(),.$i.===.$len.-.1.?.null.:.s |
44e60 | 75 62 73 74 72 28 24 6e 61 6d 65 2c 20 24 69 20 2b 20 31 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 | ubstr($name,.$i.+.1));.......... |
44e80 | 20 20 20 20 20 20 20 20 62 72 65 61 6b 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 | ........break;.............}.els |
44ea0 | 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 61 64 64 4c 6f | e.{.................$this->addLo |
44ec0 | 6e 67 4f 70 74 69 6f 6e 28 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 4e 61 6d 65 28 29 2c 20 6e 75 6c | ngOption($option->getName(),.nul |
44ee0 | 6c 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 | l);.............}.........}..... |
44f00 | 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 50 61 72 73 65 73 20 61 20 6c 6f 6e 67 20 | }....../**......*.Parses.a.long. |
44f20 | 6f 70 74 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 | option.......*......*.@param.str |
44f40 | 69 6e 67 20 24 74 6f 6b 65 6e 20 54 68 65 20 63 75 72 72 65 6e 74 20 74 6f 6b 65 6e 0a 20 20 20 | ing.$token.The.current.token.... |
44f60 | 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 70 61 72 73 65 4c | ..*/.....private.function.parseL |
44f80 | 6f 6e 67 4f 70 74 69 6f 6e 28 24 74 6f 6b 65 6e 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | ongOption($token).....{......... |
44fa0 | 24 6e 61 6d 65 20 3d 20 73 75 62 73 74 72 28 24 74 6f 6b 65 6e 2c 20 32 29 3b 0a 0a 20 20 20 20 | $name.=.substr($token,.2);...... |
44fc0 | 20 20 20 20 69 66 20 28 66 61 6c 73 65 20 21 3d 3d 20 24 70 6f 73 20 3d 20 73 74 72 70 6f 73 28 | ....if.(false.!==.$pos.=.strpos( |
44fe0 | 24 6e 61 6d 65 2c 20 27 3d 27 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 30 | $name,.'=')).{.............if.(0 |
45000 | 20 3d 3d 3d 20 73 74 72 6c 65 6e 28 24 76 61 6c 75 65 20 3d 20 73 75 62 73 74 72 28 24 6e 61 6d | .===.strlen($value.=.substr($nam |
45020 | 65 2c 20 24 70 6f 73 20 2b 20 31 29 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | e,.$pos.+.1))).{................ |
45040 | 20 61 72 72 61 79 5f 75 6e 73 68 69 66 74 28 24 74 68 69 73 2d 3e 70 61 72 73 65 64 2c 20 6e 75 | .array_unshift($this->parsed,.nu |
45060 | 6c 6c 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 | ll);.............}.............$ |
45080 | 74 68 69 73 2d 3e 61 64 64 4c 6f 6e 67 4f 70 74 69 6f 6e 28 73 75 62 73 74 72 28 24 6e 61 6d 65 | this->addLongOption(substr($name |
450a0 | 2c 20 30 2c 20 24 70 6f 73 29 2c 20 24 76 61 6c 75 65 29 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 | ,.0,.$pos),.$value);.........}.e |
450c0 | 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 61 64 64 4c 6f 6e 67 | lse.{.............$this->addLong |
450e0 | 4f 70 74 69 6f 6e 28 24 6e 61 6d 65 2c 20 6e 75 6c 6c 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 | Option($name,.null);.........}.. |
45100 | 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 50 61 72 73 65 73 20 61 6e 20 61 | ...}....../**......*.Parses.an.a |
45120 | 72 67 75 6d 65 6e 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 | rgument.......*......*.@param.st |
45140 | 72 69 6e 67 20 24 74 6f 6b 65 6e 20 54 68 65 20 63 75 72 72 65 6e 74 20 74 6f 6b 65 6e 0a 20 20 | ring.$token.The.current.token... |
45160 | 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 52 75 6e 74 69 6d 65 45 78 63 65 70 | ...*......*.@throws.RuntimeExcep |
45180 | 74 69 6f 6e 20 57 68 65 6e 20 74 6f 6f 20 6d 61 6e 79 20 61 72 67 75 6d 65 6e 74 73 20 61 72 65 | tion.When.too.many.arguments.are |
451a0 | 20 67 69 76 65 6e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 | .given......*/.....private.funct |
451c0 | 69 6f 6e 20 70 61 72 73 65 41 72 67 75 6d 65 6e 74 28 24 74 6f 6b 65 6e 29 0a 20 20 20 20 7b 0a | ion.parseArgument($token).....{. |
451e0 | 20 20 20 20 20 20 20 20 24 63 20 3d 20 63 6f 75 6e 74 28 24 74 68 69 73 2d 3e 61 72 67 75 6d 65 | ........$c.=.count($this->argume |
45200 | 6e 74 73 29 3b 0a 0a 20 20 20 20 20 20 20 20 2f 2f 20 69 66 20 69 6e 70 75 74 20 69 73 20 65 78 | nts);..........//.if.input.is.ex |
45220 | 70 65 63 74 69 6e 67 20 61 6e 6f 74 68 65 72 20 61 72 67 75 6d 65 6e 74 2c 20 61 64 64 20 69 74 | pecting.another.argument,.add.it |
45240 | 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 74 68 69 73 2d 3e 64 65 66 69 6e 69 74 69 6f 6e 2d 3e | .........if.($this->definition-> |
45260 | 68 61 73 41 72 67 75 6d 65 6e 74 28 24 63 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 | hasArgument($c)).{.............$ |
45280 | 61 72 67 20 3d 20 24 74 68 69 73 2d 3e 64 65 66 69 6e 69 74 69 6f 6e 2d 3e 67 65 74 41 72 67 75 | arg.=.$this->definition->getArgu |
452a0 | 6d 65 6e 74 28 24 63 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 61 72 67 | ment($c);.............$this->arg |
452c0 | 75 6d 65 6e 74 73 5b 24 61 72 67 2d 3e 67 65 74 4e 61 6d 65 28 29 5d 20 3d 20 24 61 72 67 2d 3e | uments[$arg->getName()].=.$arg-> |
452e0 | 69 73 41 72 72 61 79 28 29 20 3f 20 61 72 72 61 79 28 24 74 6f 6b 65 6e 29 20 3a 20 24 74 6f 6b | isArray().?.array($token).:.$tok |
45300 | 65 6e 3b 0a 0a 20 20 20 20 20 20 20 20 2f 2f 20 69 66 20 6c 61 73 74 20 61 72 67 75 6d 65 6e 74 | en;..........//.if.last.argument |
45320 | 20 69 73 41 72 72 61 79 28 29 2c 20 61 70 70 65 6e 64 20 74 6f 6b 65 6e 20 74 6f 20 6c 61 73 74 | .isArray(),.append.token.to.last |
45340 | 20 61 72 67 75 6d 65 6e 74 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 24 74 68 69 | .argument.........}.elseif.($thi |
45360 | 73 2d 3e 64 65 66 69 6e 69 74 69 6f 6e 2d 3e 68 61 73 41 72 67 75 6d 65 6e 74 28 24 63 20 2d 20 | s->definition->hasArgument($c.-. |
45380 | 31 29 20 26 26 20 24 74 68 69 73 2d 3e 64 65 66 69 6e 69 74 69 6f 6e 2d 3e 67 65 74 41 72 67 75 | 1).&&.$this->definition->getArgu |
453a0 | 6d 65 6e 74 28 24 63 20 2d 20 31 29 2d 3e 69 73 41 72 72 61 79 28 29 29 20 7b 0a 20 20 20 20 20 | ment($c.-.1)->isArray()).{...... |
453c0 | 20 20 20 20 20 20 20 24 61 72 67 20 3d 20 24 74 68 69 73 2d 3e 64 65 66 69 6e 69 74 69 6f 6e 2d | .......$arg.=.$this->definition- |
453e0 | 3e 67 65 74 41 72 67 75 6d 65 6e 74 28 24 63 20 2d 20 31 29 3b 0a 20 20 20 20 20 20 20 20 20 20 | >getArgument($c.-.1);........... |
45400 | 20 20 24 74 68 69 73 2d 3e 61 72 67 75 6d 65 6e 74 73 5b 24 61 72 67 2d 3e 67 65 74 4e 61 6d 65 | ..$this->arguments[$arg->getName |
45420 | 28 29 5d 5b 5d 20 3d 20 24 74 6f 6b 65 6e 3b 0a 0a 20 20 20 20 20 20 20 20 2f 2f 20 75 6e 65 78 | ()][].=.$token;..........//.unex |
45440 | 70 65 63 74 65 64 20 61 72 67 75 6d 65 6e 74 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b | pected.argument.........}.else.{ |
45460 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 61 6c 6c 20 3d 20 24 74 68 69 73 2d 3e 64 65 66 69 6e | .............$all.=.$this->defin |
45480 | 69 74 69 6f 6e 2d 3e 67 65 74 41 72 67 75 6d 65 6e 74 73 28 29 3b 0a 20 20 20 20 20 20 20 20 20 | ition->getArguments();.......... |
454a0 | 20 20 20 69 66 20 28 63 6f 75 6e 74 28 24 61 6c 6c 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | ...if.(count($all)).{........... |
454c0 | 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 52 75 6e 74 69 6d 65 45 78 63 65 70 74 69 6f 6e | ......throw.new.RuntimeException |
454e0 | 28 73 70 72 69 6e 74 66 28 27 54 6f 6f 20 6d 61 6e 79 20 61 72 67 75 6d 65 6e 74 73 2c 20 65 78 | (sprintf('Too.many.arguments,.ex |
45500 | 70 65 63 74 65 64 20 61 72 67 75 6d 65 6e 74 73 20 22 25 73 22 2e 27 2c 20 69 6d 70 6c 6f 64 65 | pected.arguments."%s".',.implode |
45520 | 28 27 22 20 22 27 2c 20 61 72 72 61 79 5f 6b 65 79 73 28 24 61 6c 6c 29 29 29 29 3b 0a 20 20 20 | ('"."',.array_keys($all))));.... |
45540 | 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 | .........}..............throw.ne |
45560 | 77 20 52 75 6e 74 69 6d 65 45 78 63 65 70 74 69 6f 6e 28 73 70 72 69 6e 74 66 28 27 4e 6f 20 61 | w.RuntimeException(sprintf('No.a |
45580 | 72 67 75 6d 65 6e 74 73 20 65 78 70 65 63 74 65 64 2c 20 67 6f 74 20 22 25 73 22 2e 27 2c 20 24 | rguments.expected,.got."%s".',.$ |
455a0 | 74 6f 6b 65 6e 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a | token));.........}.....}....../* |
455c0 | 2a 0a 20 20 20 20 20 2a 20 41 64 64 73 20 61 20 73 68 6f 72 74 20 6f 70 74 69 6f 6e 20 76 61 6c | *......*.Adds.a.short.option.val |
455e0 | 75 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 | ue.......*......*.@param.string. |
45600 | 24 73 68 6f 72 74 63 75 74 20 54 68 65 20 73 68 6f 72 74 20 6f 70 74 69 6f 6e 20 6b 65 79 0a 20 | $shortcut.The.short.option.key.. |
45620 | 20 20 20 20 2a 20 40 70 61 72 61 6d 20 6d 69 78 65 64 20 20 24 76 61 6c 75 65 20 20 20 20 54 68 | ....*.@param.mixed..$value....Th |
45640 | 65 20 76 61 6c 75 65 20 66 6f 72 20 74 68 65 20 6f 70 74 69 6f 6e 0a 20 20 20 20 20 2a 0a 20 20 | e.value.for.the.option......*... |
45660 | 20 20 20 2a 20 40 74 68 72 6f 77 73 20 52 75 6e 74 69 6d 65 45 78 63 65 70 74 69 6f 6e 20 57 68 | ...*.@throws.RuntimeException.Wh |
45680 | 65 6e 20 6f 70 74 69 6f 6e 20 67 69 76 65 6e 20 64 6f 65 73 6e 27 74 20 65 78 69 73 74 0a 20 20 | en.option.given.doesn't.exist... |
456a0 | 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 61 64 64 53 68 | ...*/.....private.function.addSh |
456c0 | 6f 72 74 4f 70 74 69 6f 6e 28 24 73 68 6f 72 74 63 75 74 2c 20 24 76 61 6c 75 65 29 0a 20 20 20 | ortOption($shortcut,.$value).... |
456e0 | 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 24 74 68 69 73 2d 3e 64 65 66 69 6e 69 74 69 6f | .{.........if.(!$this->definitio |
45700 | 6e 2d 3e 68 61 73 53 68 6f 72 74 63 75 74 28 24 73 68 6f 72 74 63 75 74 29 29 20 7b 0a 20 20 20 | n->hasShortcut($shortcut)).{.... |
45720 | 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 52 75 6e 74 69 6d 65 45 78 63 65 70 74 | .........throw.new.RuntimeExcept |
45740 | 69 6f 6e 28 73 70 72 69 6e 74 66 28 27 54 68 65 20 22 2d 25 73 22 20 6f 70 74 69 6f 6e 20 64 6f | ion(sprintf('The."-%s".option.do |
45760 | 65 73 20 6e 6f 74 20 65 78 69 73 74 2e 27 2c 20 24 73 68 6f 72 74 63 75 74 29 29 3b 0a 20 20 20 | es.not.exist.',.$shortcut));.... |
45780 | 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 61 64 64 4c 6f 6e 67 4f 70 | .....}..........$this->addLongOp |
457a0 | 74 69 6f 6e 28 24 74 68 69 73 2d 3e 64 65 66 69 6e 69 74 69 6f 6e 2d 3e 67 65 74 4f 70 74 69 6f | tion($this->definition->getOptio |
457c0 | 6e 46 6f 72 53 68 6f 72 74 63 75 74 28 24 73 68 6f 72 74 63 75 74 29 2d 3e 67 65 74 4e 61 6d 65 | nForShortcut($shortcut)->getName |
457e0 | 28 29 2c 20 24 76 61 6c 75 65 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 | (),.$value);.....}....../**..... |
45800 | 20 2a 20 41 64 64 73 20 61 20 6c 6f 6e 67 20 6f 70 74 69 6f 6e 20 76 61 6c 75 65 2e 0a 20 20 20 | .*.Adds.a.long.option.value..... |
45820 | 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6e 61 6d 65 20 20 | ..*......*.@param.string.$name.. |
45840 | 54 68 65 20 6c 6f 6e 67 20 6f 70 74 69 6f 6e 20 6b 65 79 0a 20 20 20 20 20 2a 20 40 70 61 72 61 | The.long.option.key......*.@para |
45860 | 6d 20 6d 69 78 65 64 20 20 24 76 61 6c 75 65 20 54 68 65 20 76 61 6c 75 65 20 66 6f 72 20 74 68 | m.mixed..$value.The.value.for.th |
45880 | 65 20 6f 70 74 69 6f 6e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 52 | e.option......*......*.@throws.R |
458a0 | 75 6e 74 69 6d 65 45 78 63 65 70 74 69 6f 6e 20 57 68 65 6e 20 6f 70 74 69 6f 6e 20 67 69 76 65 | untimeException.When.option.give |
458c0 | 6e 20 64 6f 65 73 6e 27 74 20 65 78 69 73 74 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 | n.doesn't.exist......*/.....priv |
458e0 | 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 61 64 64 4c 6f 6e 67 4f 70 74 69 6f 6e 28 24 6e 61 6d 65 | ate.function.addLongOption($name |
45900 | 2c 20 24 76 61 6c 75 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 24 74 68 | ,.$value).....{.........if.(!$th |
45920 | 69 73 2d 3e 64 65 66 69 6e 69 74 69 6f 6e 2d 3e 68 61 73 4f 70 74 69 6f 6e 28 24 6e 61 6d 65 29 | is->definition->hasOption($name) |
45940 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 52 75 6e 74 69 6d | ).{.............throw.new.Runtim |
45960 | 65 45 78 63 65 70 74 69 6f 6e 28 73 70 72 69 6e 74 66 28 27 54 68 65 20 22 2d 2d 25 73 22 20 6f | eException(sprintf('The."--%s".o |
45980 | 70 74 69 6f 6e 20 64 6f 65 73 20 6e 6f 74 20 65 78 69 73 74 2e 27 2c 20 24 6e 61 6d 65 29 29 3b | ption.does.not.exist.',.$name)); |
459a0 | 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 6f 70 74 69 6f 6e 20 3d 20 24 74 | .........}..........$option.=.$t |
459c0 | 68 69 73 2d 3e 64 65 66 69 6e 69 74 69 6f 6e 2d 3e 67 65 74 4f 70 74 69 6f 6e 28 24 6e 61 6d 65 | his->definition->getOption($name |
459e0 | 29 3b 0a 0a 20 20 20 20 20 20 20 20 2f 2f 20 43 6f 6e 76 65 72 74 20 65 6d 70 74 79 20 76 61 6c | );..........//.Convert.empty.val |
45a00 | 75 65 73 20 74 6f 20 6e 75 6c 6c 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 69 73 73 65 74 28 24 | ues.to.null.........if.(!isset($ |
45a20 | 76 61 6c 75 65 5b 30 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 76 61 6c 75 65 20 | value[0])).{.............$value. |
45a40 | 3d 20 6e 75 6c 6c 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e | =.null;.........}..........if.(n |
45a60 | 75 6c 6c 20 21 3d 3d 20 24 76 61 6c 75 65 20 26 26 20 21 24 6f 70 74 69 6f 6e 2d 3e 61 63 63 65 | ull.!==.$value.&&.!$option->acce |
45a80 | 70 74 56 61 6c 75 65 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e | ptValue()).{.............throw.n |
45aa0 | 65 77 20 52 75 6e 74 69 6d 65 45 78 63 65 70 74 69 6f 6e 28 73 70 72 69 6e 74 66 28 27 54 68 65 | ew.RuntimeException(sprintf('The |
45ac0 | 20 22 2d 2d 25 73 22 20 6f 70 74 69 6f 6e 20 64 6f 65 73 20 6e 6f 74 20 61 63 63 65 70 74 20 61 | ."--%s".option.does.not.accept.a |
45ae0 | 20 76 61 6c 75 65 2e 27 2c 20 24 6e 61 6d 65 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 | .value.',.$name));.........}.... |
45b00 | 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 76 61 6c 75 65 20 26 26 20 24 6f 70 | ......if.(null.===.$value.&&.$op |
45b20 | 74 69 6f 6e 2d 3e 61 63 63 65 70 74 56 61 6c 75 65 28 29 20 26 26 20 63 6f 75 6e 74 28 24 74 68 | tion->acceptValue().&&.count($th |
45b40 | 69 73 2d 3e 70 61 72 73 65 64 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 69 66 | is->parsed)).{.............//.if |
45b60 | 20 6f 70 74 69 6f 6e 20 61 63 63 65 70 74 73 20 61 6e 20 6f 70 74 69 6f 6e 61 6c 20 6f 72 20 6d | .option.accepts.an.optional.or.m |
45b80 | 61 6e 64 61 74 6f 72 79 20 61 72 67 75 6d 65 6e 74 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f | andatory.argument.............// |
45ba0 | 20 6c 65 74 27 73 20 73 65 65 20 69 66 20 74 68 65 72 65 20 69 73 20 6f 6e 65 20 70 72 6f 76 69 | .let's.see.if.there.is.one.provi |
45bc0 | 64 65 64 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6e 65 78 74 20 3d 20 61 72 72 61 79 5f 73 68 | ded.............$next.=.array_sh |
45be0 | 69 66 74 28 24 74 68 69 73 2d 3e 70 61 72 73 65 64 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ift($this->parsed);............. |
45c00 | 69 66 20 28 69 73 73 65 74 28 24 6e 65 78 74 5b 30 5d 29 20 26 26 20 27 2d 27 20 21 3d 3d 20 24 | if.(isset($next[0]).&&.'-'.!==.$ |
45c20 | 6e 65 78 74 5b 30 5d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 76 61 6c 75 | next[0]).{.................$valu |
45c40 | 65 20 3d 20 24 6e 65 78 74 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 | e.=.$next;.............}.elseif. |
45c60 | 28 65 6d 70 74 79 28 24 6e 65 78 74 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | (empty($next)).{................ |
45c80 | 20 24 76 61 6c 75 65 20 3d 20 6e 75 6c 6c 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c | .$value.=.null;.............}.el |
45ca0 | 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 61 72 72 61 79 5f 75 6e 73 68 69 | se.{.................array_unshi |
45cc0 | 66 74 28 24 74 68 69 73 2d 3e 70 61 72 73 65 64 2c 20 24 6e 65 78 74 29 3b 0a 20 20 20 20 20 20 | ft($this->parsed,.$next);....... |
45ce0 | 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e | ......}.........}..........if.(n |
45d00 | 75 6c 6c 20 3d 3d 3d 20 24 76 61 6c 75 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 | ull.===.$value).{.............if |
45d20 | 20 28 24 6f 70 74 69 6f 6e 2d 3e 69 73 56 61 6c 75 65 52 65 71 75 69 72 65 64 28 29 29 20 7b 0a | .($option->isValueRequired()).{. |
45d40 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 52 75 6e 74 69 6d | ................throw.new.Runtim |
45d60 | 65 45 78 63 65 70 74 69 6f 6e 28 73 70 72 69 6e 74 66 28 27 54 68 65 20 22 2d 2d 25 73 22 20 6f | eException(sprintf('The."--%s".o |
45d80 | 70 74 69 6f 6e 20 72 65 71 75 69 72 65 73 20 61 20 76 61 6c 75 65 2e 27 2c 20 24 6e 61 6d 65 29 | ption.requires.a.value.',.$name) |
45da0 | 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 | );.............}..............if |
45dc0 | 20 28 21 24 6f 70 74 69 6f 6e 2d 3e 69 73 41 72 72 61 79 28 29 29 20 7b 0a 20 20 20 20 20 20 20 | .(!$option->isArray()).{........ |
45de0 | 20 20 20 20 20 20 20 20 20 24 76 61 6c 75 65 20 3d 20 24 6f 70 74 69 6f 6e 2d 3e 69 73 56 61 6c | .........$value.=.$option->isVal |
45e00 | 75 65 4f 70 74 69 6f 6e 61 6c 28 29 20 3f 20 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 44 65 66 61 75 | ueOptional().?.$option->getDefau |
45e20 | 6c 74 28 29 20 3a 20 74 72 75 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 | lt().:.true;.............}...... |
45e40 | 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 6f 70 74 69 6f 6e 2d 3e 69 73 41 72 72 | ...}..........if.($option->isArr |
45e60 | 61 79 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6f 70 74 69 6f | ay()).{.............$this->optio |
45e80 | 6e 73 5b 24 6e 61 6d 65 5d 5b 5d 20 3d 20 24 76 61 6c 75 65 3b 0a 20 20 20 20 20 20 20 20 7d 20 | ns[$name][].=.$value;.........}. |
45ea0 | 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6f 70 74 69 6f 6e | else.{.............$this->option |
45ec0 | 73 5b 24 6e 61 6d 65 5d 20 3d 20 24 76 61 6c 75 65 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 | s[$name].=.$value;.........}.... |
45ee0 | 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d | .}....../**......*.{@inheritdoc} |
45f00 | 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 | ......*/.....public.function.get |
45f20 | 46 69 72 73 74 41 72 67 75 6d 65 6e 74 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 66 6f | FirstArgument().....{.........fo |
45f40 | 72 65 61 63 68 20 28 24 74 68 69 73 2d 3e 74 6f 6b 65 6e 73 20 61 73 20 24 74 6f 6b 65 6e 29 20 | reach.($this->tokens.as.$token). |
45f60 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 74 6f 6b 65 6e 20 26 26 20 27 2d 27 20 | {.............if.($token.&&.'-'. |
45f80 | 3d 3d 3d 20 24 74 6f 6b 65 6e 5b 30 5d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ===.$token[0]).{................ |
45fa0 | 20 63 6f 6e 74 69 6e 75 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 | .continue;.............}........ |
45fc0 | 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 6f 6b 65 6e 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 | ......return.$token;.........}.. |
45fe0 | 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f | ...}....../**......*.{@inheritdo |
46000 | 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 68 | c}......*/.....public.function.h |
46020 | 61 73 50 61 72 61 6d 65 74 65 72 4f 70 74 69 6f 6e 28 24 76 61 6c 75 65 73 2c 20 24 6f 6e 6c 79 | asParameterOption($values,.$only |
46040 | 50 61 72 61 6d 73 20 3d 20 66 61 6c 73 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 76 | Params.=.false).....{.........$v |
46060 | 61 6c 75 65 73 20 3d 20 28 61 72 72 61 79 29 20 24 76 61 6c 75 65 73 3b 0a 0a 20 20 20 20 20 20 | alues.=.(array).$values;........ |
46080 | 20 20 66 6f 72 65 61 63 68 20 28 24 74 68 69 73 2d 3e 74 6f 6b 65 6e 73 20 61 73 20 24 74 6f 6b | ..foreach.($this->tokens.as.$tok |
460a0 | 65 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 6f 6e 6c 79 50 61 72 61 6d | en).{.............if.($onlyParam |
460c0 | 73 20 26 26 20 24 74 6f 6b 65 6e 20 3d 3d 3d 20 27 2d 2d 27 29 20 7b 0a 20 20 20 20 20 20 20 20 | s.&&.$token.===.'--').{......... |
460e0 | 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 20 20 | ........return.false;........... |
46100 | 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 76 61 6c 75 65 73 | ..}.............foreach.($values |
46120 | 20 61 73 20 24 76 61 6c 75 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 | .as.$value).{.................if |
46140 | 20 28 24 74 6f 6b 65 6e 20 3d 3d 3d 20 24 76 61 6c 75 65 20 7c 7c 20 30 20 3d 3d 3d 20 73 74 72 | .($token.===.$value.||.0.===.str |
46160 | 70 6f 73 28 24 74 6f 6b 65 6e 2c 20 24 76 61 6c 75 65 2e 27 3d 27 29 29 20 7b 0a 20 20 20 20 20 | pos($token,.$value.'=')).{...... |
46180 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 74 72 75 65 3b 0a 20 20 20 20 | ...............return.true;..... |
461a0 | 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 | ............}.............}..... |
461c0 | 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 66 61 6c 73 65 3b 0a 20 20 20 | ....}..........return.false;.... |
461e0 | 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d | .}....../**......*.{@inheritdoc} |
46200 | 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 | ......*/.....public.function.get |
46220 | 50 61 72 61 6d 65 74 65 72 4f 70 74 69 6f 6e 28 24 76 61 6c 75 65 73 2c 20 24 64 65 66 61 75 6c | ParameterOption($values,.$defaul |
46240 | 74 20 3d 20 66 61 6c 73 65 2c 20 24 6f 6e 6c 79 50 61 72 61 6d 73 20 3d 20 66 61 6c 73 65 29 0a | t.=.false,.$onlyParams.=.false). |
46260 | 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 76 61 6c 75 65 73 20 3d 20 28 61 72 72 61 79 29 20 | ....{.........$values.=.(array). |
46280 | 24 76 61 6c 75 65 73 3b 0a 20 20 20 20 20 20 20 20 24 74 6f 6b 65 6e 73 20 3d 20 24 74 68 69 73 | $values;.........$tokens.=.$this |
462a0 | 2d 3e 74 6f 6b 65 6e 73 3b 0a 0a 20 20 20 20 20 20 20 20 77 68 69 6c 65 20 28 30 20 3c 20 63 6f | ->tokens;..........while.(0.<.co |
462c0 | 75 6e 74 28 24 74 6f 6b 65 6e 73 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 6f 6b | unt($tokens)).{.............$tok |
462e0 | 65 6e 20 3d 20 61 72 72 61 79 5f 73 68 69 66 74 28 24 74 6f 6b 65 6e 73 29 3b 0a 20 20 20 20 20 | en.=.array_shift($tokens);...... |
46300 | 20 20 20 20 20 20 20 69 66 20 28 24 6f 6e 6c 79 50 61 72 61 6d 73 20 26 26 20 24 74 6f 6b 65 6e | .......if.($onlyParams.&&.$token |
46320 | 20 3d 3d 3d 20 27 2d 2d 27 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 | .===.'--').{.................ret |
46340 | 75 72 6e 20 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 | urn.false;.............}........ |
46360 | 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 76 61 6c 75 65 73 20 61 73 20 24 76 61 6c 75 65 | ......foreach.($values.as.$value |
46380 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 74 6f 6b 65 6e 20 3d | ).{.................if.($token.= |
463a0 | 3d 3d 20 24 76 61 6c 75 65 20 7c 7c 20 30 20 3d 3d 3d 20 73 74 72 70 6f 73 28 24 74 6f 6b 65 6e | ==.$value.||.0.===.strpos($token |
463c0 | 2c 20 24 76 61 6c 75 65 2e 27 3d 27 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ,.$value.'=')).{................ |
463e0 | 20 20 20 20 20 69 66 20 28 66 61 6c 73 65 20 21 3d 3d 20 24 70 6f 73 20 3d 20 73 74 72 70 6f 73 | .....if.(false.!==.$pos.=.strpos |
46400 | 28 24 74 6f 6b 65 6e 2c 20 27 3d 27 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ($token,.'=')).{................ |
46420 | 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 75 62 73 74 72 28 24 74 6f 6b 65 6e 2c 20 24 | .........return.substr($token,.$ |
46440 | 70 6f 73 20 2b 20 31 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a | pos.+.1);.....................}. |
46460 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 61 72 72 61 | .....................return.arra |
46480 | 79 5f 73 68 69 66 74 28 24 74 6f 6b 65 6e 73 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | y_shift($tokens);............... |
464a0 | 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 | ..}.............}.........}..... |
464c0 | 20 20 20 20 20 72 65 74 75 72 6e 20 24 64 65 66 61 75 6c 74 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 | .....return.$default;.....}..... |
464e0 | 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 61 20 73 74 72 69 6e 67 69 66 69 65 | ./**......*.Returns.a.stringifie |
46500 | 64 20 72 65 70 72 65 73 65 6e 74 61 74 69 6f 6e 20 6f 66 20 74 68 65 20 61 72 67 73 20 70 61 73 | d.representation.of.the.args.pas |
46520 | 73 65 64 20 74 6f 20 74 68 65 20 63 6f 6d 6d 61 6e 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 | sed.to.the.command.......*...... |
46540 | 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 | *.@return.string......*/.....pub |
46560 | 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 74 6f 53 74 72 69 6e 67 28 29 0a 20 20 20 20 7b 0a | lic.function.__toString().....{. |
46580 | 20 20 20 20 20 20 20 20 24 74 6f 6b 65 6e 73 20 3d 20 61 72 72 61 79 5f 6d 61 70 28 66 75 6e 63 | ........$tokens.=.array_map(func |
465a0 | 74 69 6f 6e 20 28 24 74 6f 6b 65 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 | tion.($token).{.............if.( |
465c0 | 70 72 65 67 5f 6d 61 74 63 68 28 27 7b 5e 28 2d 5b 5e 3d 5d 2b 3d 29 28 2e 2b 29 7d 27 2c 20 24 | preg_match('{^(-[^=]+=)(.+)}',.$ |
465e0 | 74 6f 6b 65 6e 2c 20 24 6d 61 74 63 68 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | token,.$match)).{............... |
46600 | 20 20 72 65 74 75 72 6e 20 24 6d 61 74 63 68 5b 31 5d 2e 24 74 68 69 73 2d 3e 65 73 63 61 70 65 | ..return.$match[1].$this->escape |
46620 | 54 6f 6b 65 6e 28 24 6d 61 74 63 68 5b 32 5d 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a | Token($match[2]);.............}. |
46640 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 74 6f 6b 65 6e 20 26 26 20 24 74 6f 6b 65 | .............if.($token.&&.$toke |
46660 | 6e 5b 30 5d 20 21 3d 3d 20 27 2d 27 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | n[0].!==.'-').{................. |
46680 | 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 65 73 63 61 70 65 54 6f 6b 65 6e 28 24 74 6f 6b 65 6e | return.$this->escapeToken($token |
466a0 | 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 | );.............}..............re |
466c0 | 74 75 72 6e 20 24 74 6f 6b 65 6e 3b 0a 20 20 20 20 20 20 20 20 7d 2c 20 24 74 68 69 73 2d 3e 74 | turn.$token;.........},.$this->t |
466e0 | 6f 6b 65 6e 73 29 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 69 6d 70 6c 6f 64 65 28 | okens);..........return.implode( |
46700 | 27 20 27 2c 20 24 74 6f 6b 65 6e 73 29 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a | '.',.$tokens);.....}.}.<?php../* |
46720 | 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d | ..*.This.file.is.part.of.the.Sym |
46740 | 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 | fony.package...*..*.(c).Fabien.P |
46760 | 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a | otencier.<fabien@symfony.com>..* |
46780 | 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c | ..*.For.the.full.copyright.and.l |
467a0 | 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 | icense.information,.please.view. |
467c0 | 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 | the.LICENSE..*.file.that.was.dis |
467e0 | 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a | tributed.with.this.source.code.. |
46800 | 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 | .*/..namespace.Symfony\Component |
46820 | 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 3b 0a 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d | \Console\Input;..use.Symfony\Com |
46840 | 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 78 63 65 70 74 69 6f 6e 5c 49 6e 76 61 6c 69 64 | ponent\Console\Exception\Invalid |
46860 | 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 | ArgumentException;.use.Symfony\C |
46880 | 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 78 63 65 70 74 69 6f 6e 5c 49 6e 76 61 6c | omponent\Console\Exception\Inval |
468a0 | 69 64 4f 70 74 69 6f 6e 45 78 63 65 70 74 69 6f 6e 3b 0a 0a 2f 2a 2a 0a 20 2a 20 41 72 72 61 79 | idOptionException;../**..*.Array |
468c0 | 49 6e 70 75 74 20 72 65 70 72 65 73 65 6e 74 73 20 61 6e 20 69 6e 70 75 74 20 70 72 6f 76 69 64 | Input.represents.an.input.provid |
468e0 | 65 64 20 61 73 20 61 6e 20 61 72 72 61 79 2e 0a 20 2a 0a 20 2a 20 55 73 61 67 65 3a 0a 20 2a 0a | ed.as.an.array...*..*.Usage:..*. |
46900 | 20 2a 20 20 20 20 20 24 69 6e 70 75 74 20 3d 20 6e 65 77 20 41 72 72 61 79 49 6e 70 75 74 28 61 | .*.....$input.=.new.ArrayInput(a |
46920 | 72 72 61 79 28 27 6e 61 6d 65 27 20 3d 3e 20 27 66 6f 6f 27 2c 20 27 2d 2d 62 61 72 27 20 3d 3e | rray('name'.=>.'foo',.'--bar'.=> |
46940 | 20 27 66 6f 6f 62 61 72 27 29 29 3b 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 46 61 62 69 65 | .'foobar'));..*..*.@author.Fabie |
46960 | 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e | n.Potencier.<fabien@symfony.com> |
46980 | 0a 20 2a 2f 0a 63 6c 61 73 73 20 41 72 72 61 79 49 6e 70 75 74 20 65 78 74 65 6e 64 73 20 49 6e | ..*/.class.ArrayInput.extends.In |
469a0 | 70 75 74 0a 7b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 70 61 72 61 6d 65 74 65 72 73 3b 0a 0a | put.{.....private.$parameters;.. |
469c0 | 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 43 6f 6e 73 74 72 75 63 74 6f 72 2e 0a 20 20 20 20 | ..../**......*.Constructor...... |
469e0 | 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 20 20 20 20 20 20 20 20 20 | .*......*.@param.array.......... |
46a00 | 20 20 20 20 20 20 24 70 61 72 61 6d 65 74 65 72 73 20 41 6e 20 61 72 72 61 79 20 6f 66 20 70 61 | ......$parameters.An.array.of.pa |
46a20 | 72 61 6d 65 74 65 72 73 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 49 6e 70 75 74 44 65 66 69 | rameters......*.@param.InputDefi |
46a40 | 6e 69 74 69 6f 6e 7c 6e 75 6c 6c 20 24 64 65 66 69 6e 69 74 69 6f 6e 20 41 20 49 6e 70 75 74 44 | nition|null.$definition.A.InputD |
46a60 | 65 66 69 6e 69 74 69 6f 6e 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 | efinition.instance......*/.....p |
46a80 | 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 74 28 61 72 72 61 79 | ublic.function.__construct(array |
46aa0 | 20 24 70 61 72 61 6d 65 74 65 72 73 2c 20 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 20 24 64 | .$parameters,.InputDefinition.$d |
46ac0 | 65 66 69 6e 69 74 69 6f 6e 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | efinition.=.null).....{......... |
46ae0 | 24 74 68 69 73 2d 3e 70 61 72 61 6d 65 74 65 72 73 20 3d 20 24 70 61 72 61 6d 65 74 65 72 73 3b | $this->parameters.=.$parameters; |
46b00 | 0a 0a 20 20 20 20 20 20 20 20 70 61 72 65 6e 74 3a 3a 5f 5f 63 6f 6e 73 74 72 75 63 74 28 24 64 | ..........parent::__construct($d |
46b20 | 65 66 69 6e 69 74 69 6f 6e 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 | efinition);.....}....../**...... |
46b40 | 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c | *.{@inheritdoc}......*/.....publ |
46b60 | 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 46 69 72 73 74 41 72 67 75 6d 65 6e 74 28 29 0a 20 | ic.function.getFirstArgument().. |
46b80 | 20 20 20 7b 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 74 68 69 73 2d 3e 70 61 72 | ...{.........foreach.($this->par |
46ba0 | 61 6d 65 74 65 72 73 20 61 73 20 24 6b 65 79 20 3d 3e 20 24 76 61 6c 75 65 29 20 7b 0a 20 20 20 | ameters.as.$key.=>.$value).{.... |
46bc0 | 20 20 20 20 20 20 20 20 20 69 66 20 28 24 6b 65 79 20 26 26 20 27 2d 27 20 3d 3d 3d 20 24 6b 65 | .........if.($key.&&.'-'.===.$ke |
46be0 | 79 5b 30 5d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 63 6f 6e 74 69 6e 75 65 | y[0]).{.................continue |
46c00 | 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 | ;.............}..............ret |
46c20 | 75 72 6e 20 24 76 61 6c 75 65 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 | urn.$value;.........}.....}..... |
46c40 | 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a | ./**......*.{@inheritdoc}......* |
46c60 | 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 68 61 73 50 61 72 61 6d 65 74 | /.....public.function.hasParamet |
46c80 | 65 72 4f 70 74 69 6f 6e 28 24 76 61 6c 75 65 73 2c 20 24 6f 6e 6c 79 50 61 72 61 6d 73 20 3d 20 | erOption($values,.$onlyParams.=. |
46ca0 | 66 61 6c 73 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 76 61 6c 75 65 73 20 3d 20 28 | false).....{.........$values.=.( |
46cc0 | 61 72 72 61 79 29 20 24 76 61 6c 75 65 73 3b 0a 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 | array).$values;..........foreach |
46ce0 | 20 28 24 74 68 69 73 2d 3e 70 61 72 61 6d 65 74 65 72 73 20 61 73 20 24 6b 20 3d 3e 20 24 76 29 | .($this->parameters.as.$k.=>.$v) |
46d00 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 21 69 73 5f 69 6e 74 28 24 6b 29 29 20 | .{.............if.(!is_int($k)). |
46d20 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 76 20 3d 20 24 6b 3b 0a 20 20 20 20 20 | {.................$v.=.$k;...... |
46d40 | 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 6f 6e 6c 79 50 | .......}..............if.($onlyP |
46d60 | 61 72 61 6d 73 20 26 26 20 24 76 20 3d 3d 3d 20 27 2d 2d 27 29 20 7b 0a 20 20 20 20 20 20 20 20 | arams.&&.$v.===.'--').{......... |
46d80 | 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 20 20 | ........return.false;........... |
46da0 | 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 69 6e 5f 61 72 72 61 79 28 24 76 | ..}..............if.(in_array($v |
46dc0 | 2c 20 24 76 61 6c 75 65 73 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 | ,.$values)).{.................re |
46de0 | 74 75 72 6e 20 74 72 75 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 | turn.true;.............}........ |
46e00 | 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 66 61 6c 73 65 3b 0a 20 20 20 20 7d 0a | .}..........return.false;.....}. |
46e20 | 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 | ...../**......*.{@inheritdoc}... |
46e40 | 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 50 61 72 | ...*/.....public.function.getPar |
46e60 | 61 6d 65 74 65 72 4f 70 74 69 6f 6e 28 24 76 61 6c 75 65 73 2c 20 24 64 65 66 61 75 6c 74 20 3d | ameterOption($values,.$default.= |
46e80 | 20 66 61 6c 73 65 2c 20 24 6f 6e 6c 79 50 61 72 61 6d 73 20 3d 20 66 61 6c 73 65 29 0a 20 20 20 | .false,.$onlyParams.=.false).... |
46ea0 | 20 7b 0a 20 20 20 20 20 20 20 20 24 76 61 6c 75 65 73 20 3d 20 28 61 72 72 61 79 29 20 24 76 61 | .{.........$values.=.(array).$va |
46ec0 | 6c 75 65 73 3b 0a 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 74 68 69 73 2d 3e 70 | lues;..........foreach.($this->p |
46ee0 | 61 72 61 6d 65 74 65 72 73 20 61 73 20 24 6b 20 3d 3e 20 24 76 29 20 7b 0a 20 20 20 20 20 20 20 | arameters.as.$k.=>.$v).{........ |
46f00 | 20 20 20 20 20 69 66 20 28 24 6f 6e 6c 79 50 61 72 61 6d 73 20 26 26 20 28 24 6b 20 3d 3d 3d 20 | .....if.($onlyParams.&&.($k.===. |
46f20 | 27 2d 2d 27 20 7c 7c 20 28 69 73 5f 69 6e 74 28 24 6b 29 20 26 26 20 24 76 20 3d 3d 3d 20 27 2d | '--'.||.(is_int($k).&&.$v.===.'- |
46f40 | 2d 27 29 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 66 | -'))).{.................return.f |
46f60 | 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 | alse;.............}............. |
46f80 | 20 69 66 20 28 69 73 5f 69 6e 74 28 24 6b 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | .if.(is_int($k)).{.............. |
46fa0 | 20 20 20 69 66 20 28 69 6e 5f 61 72 72 61 79 28 24 76 2c 20 24 76 61 6c 75 65 73 29 29 20 7b 0a | ...if.(in_array($v,.$values)).{. |
46fc0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 74 72 75 65 3b | ....................return.true; |
46fe0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d | .................}.............} |
47000 | 20 65 6c 73 65 69 66 20 28 69 6e 5f 61 72 72 61 79 28 24 6b 2c 20 24 76 61 6c 75 65 73 29 29 20 | .elseif.(in_array($k,.$values)). |
47020 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 76 3b 0a 20 20 20 | {.................return.$v;.... |
47040 | 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 | .........}.........}..........re |
47060 | 74 75 72 6e 20 24 64 65 66 61 75 6c 74 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 | turn.$default;.....}....../**... |
47080 | 20 20 20 2a 20 52 65 74 75 72 6e 73 20 61 20 73 74 72 69 6e 67 69 66 69 65 64 20 72 65 70 72 65 | ...*.Returns.a.stringified.repre |
470a0 | 73 65 6e 74 61 74 69 6f 6e 20 6f 66 20 74 68 65 20 61 72 67 73 20 70 61 73 73 65 64 20 74 6f 20 | sentation.of.the.args.passed.to. |
470c0 | 74 68 65 20 63 6f 6d 6d 61 6e 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 | the.command.......*......*.@retu |
470e0 | 72 6e 20 73 74 72 69 6e 67 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e | rn.string......*/.....public.fun |
47100 | 63 74 69 6f 6e 20 5f 5f 74 6f 53 74 72 69 6e 67 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 | ction.__toString().....{........ |
47120 | 20 24 70 61 72 61 6d 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 65 | .$params.=.array();.........fore |
47140 | 61 63 68 20 28 24 74 68 69 73 2d 3e 70 61 72 61 6d 65 74 65 72 73 20 61 73 20 24 70 61 72 61 6d | ach.($this->parameters.as.$param |
47160 | 20 3d 3e 20 24 76 61 6c 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 70 61 72 | .=>.$val).{.............if.($par |
47180 | 61 6d 20 26 26 20 27 2d 27 20 3d 3d 3d 20 24 70 61 72 61 6d 5b 30 5d 29 20 7b 0a 20 20 20 20 20 | am.&&.'-'.===.$param[0]).{...... |
471a0 | 20 20 20 20 20 20 20 20 20 20 20 24 70 61 72 61 6d 73 5b 5d 20 3d 20 24 70 61 72 61 6d 2e 28 27 | ...........$params[].=.$param.(' |
471c0 | 27 20 21 3d 20 24 76 61 6c 20 3f 20 27 3d 27 2e 24 74 68 69 73 2d 3e 65 73 63 61 70 65 54 6f 6b | '.!=.$val.?.'='.$this->escapeTok |
471e0 | 65 6e 28 24 76 61 6c 29 20 3a 20 27 27 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c | en($val).:.'');.............}.el |
47200 | 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 70 61 72 61 6d 73 5b 5d 20 3d | se.{.................$params[].= |
47220 | 20 24 74 68 69 73 2d 3e 65 73 63 61 70 65 54 6f 6b 65 6e 28 24 76 61 6c 29 3b 0a 20 20 20 20 20 | .$this->escapeToken($val);...... |
47240 | 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 | .......}.........}..........retu |
47260 | 72 6e 20 69 6d 70 6c 6f 64 65 28 27 20 27 2c 20 24 70 61 72 61 6d 73 29 3b 0a 20 20 20 20 7d 0a | rn.implode('.',.$params);.....}. |
47280 | 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 | ...../**......*.{@inheritdoc}... |
472a0 | 20 20 20 2a 2f 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 70 61 72 | ...*/.....protected.function.par |
472c0 | 73 65 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 74 68 69 | se().....{.........foreach.($thi |
472e0 | 73 2d 3e 70 61 72 61 6d 65 74 65 72 73 20 61 73 20 24 6b 65 79 20 3d 3e 20 24 76 61 6c 75 65 29 | s->parameters.as.$key.=>.$value) |
47300 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 6b 65 79 20 3d 3d 3d 20 27 2d 2d 27 | .{.............if.($key.===.'--' |
47320 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 3b 0a 20 20 20 20 | ).{.................return;..... |
47340 | 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 30 20 3d 3d 3d 20 | ........}.............if.(0.===. |
47360 | 73 74 72 70 6f 73 28 24 6b 65 79 2c 20 27 2d 2d 27 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | strpos($key,.'--')).{........... |
47380 | 20 20 20 20 20 20 24 74 68 69 73 2d 3e 61 64 64 4c 6f 6e 67 4f 70 74 69 6f 6e 28 73 75 62 73 74 | ......$this->addLongOption(subst |
473a0 | 72 28 24 6b 65 79 2c 20 32 29 2c 20 24 76 61 6c 75 65 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 | r($key,.2),.$value);............ |
473c0 | 20 7d 20 65 6c 73 65 69 66 20 28 27 2d 27 20 3d 3d 3d 20 24 6b 65 79 5b 30 5d 29 20 7b 0a 20 20 | .}.elseif.('-'.===.$key[0]).{... |
473e0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 61 64 64 53 68 6f 72 74 4f 70 74 | ..............$this->addShortOpt |
47400 | 69 6f 6e 28 73 75 62 73 74 72 28 24 6b 65 79 2c 20 31 29 2c 20 24 76 61 6c 75 65 29 3b 0a 20 20 | ion(substr($key,.1),.$value);... |
47420 | 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | ..........}.else.{.............. |
47440 | 20 20 20 24 74 68 69 73 2d 3e 61 64 64 41 72 67 75 6d 65 6e 74 28 24 6b 65 79 2c 20 24 76 61 6c | ...$this->addArgument($key,.$val |
47460 | 75 65 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 | ue);.............}.........}.... |
47480 | 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 41 64 64 73 20 61 20 73 68 6f 72 74 20 | .}....../**......*.Adds.a.short. |
474a0 | 6f 70 74 69 6f 6e 20 76 61 6c 75 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 | option.value.......*......*.@par |
474c0 | 61 6d 20 73 74 72 69 6e 67 20 24 73 68 6f 72 74 63 75 74 20 54 68 65 20 73 68 6f 72 74 20 6f 70 | am.string.$shortcut.The.short.op |
474e0 | 74 69 6f 6e 20 6b 65 79 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 6d 69 78 65 64 20 20 24 76 | tion.key......*.@param.mixed..$v |
47500 | 61 6c 75 65 20 20 20 20 54 68 65 20 76 61 6c 75 65 20 66 6f 72 20 74 68 65 20 6f 70 74 69 6f 6e | alue....The.value.for.the.option |
47520 | 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 49 6e 76 61 6c 69 64 4f 70 | ......*......*.@throws.InvalidOp |
47540 | 74 69 6f 6e 45 78 63 65 70 74 69 6f 6e 20 57 68 65 6e 20 6f 70 74 69 6f 6e 20 67 69 76 65 6e 20 | tionException.When.option.given. |
47560 | 64 6f 65 73 6e 27 74 20 65 78 69 73 74 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 | doesn't.exist......*/.....privat |
47580 | 65 20 66 75 6e 63 74 69 6f 6e 20 61 64 64 53 68 6f 72 74 4f 70 74 69 6f 6e 28 24 73 68 6f 72 74 | e.function.addShortOption($short |
475a0 | 63 75 74 2c 20 24 76 61 6c 75 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 | cut,.$value).....{.........if.(! |
475c0 | 24 74 68 69 73 2d 3e 64 65 66 69 6e 69 74 69 6f 6e 2d 3e 68 61 73 53 68 6f 72 74 63 75 74 28 24 | $this->definition->hasShortcut($ |
475e0 | 73 68 6f 72 74 63 75 74 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e | shortcut)).{.............throw.n |
47600 | 65 77 20 49 6e 76 61 6c 69 64 4f 70 74 69 6f 6e 45 78 63 65 70 74 69 6f 6e 28 73 70 72 69 6e 74 | ew.InvalidOptionException(sprint |
47620 | 66 28 27 54 68 65 20 22 2d 25 73 22 20 6f 70 74 69 6f 6e 20 64 6f 65 73 20 6e 6f 74 20 65 78 69 | f('The."-%s".option.does.not.exi |
47640 | 73 74 2e 27 2c 20 24 73 68 6f 72 74 63 75 74 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 | st.',.$shortcut));.........}.... |
47660 | 20 20 20 20 20 20 24 74 68 69 73 2d 3e 61 64 64 4c 6f 6e 67 4f 70 74 69 6f 6e 28 24 74 68 69 73 | ......$this->addLongOption($this |
47680 | 2d 3e 64 65 66 69 6e 69 74 69 6f 6e 2d 3e 67 65 74 4f 70 74 69 6f 6e 46 6f 72 53 68 6f 72 74 63 | ->definition->getOptionForShortc |
476a0 | 75 74 28 24 73 68 6f 72 74 63 75 74 29 2d 3e 67 65 74 4e 61 6d 65 28 29 2c 20 24 76 61 6c 75 65 | ut($shortcut)->getName(),.$value |
476c0 | 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 41 64 64 73 20 61 20 | );.....}....../**......*.Adds.a. |
476e0 | 6c 6f 6e 67 20 6f 70 74 69 6f 6e 20 76 61 6c 75 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a | long.option.value.......*......* |
47700 | 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6e 61 6d 65 20 20 54 68 65 20 6c 6f 6e 67 20 6f | .@param.string.$name..The.long.o |
47720 | 70 74 69 6f 6e 20 6b 65 79 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 6d 69 78 65 64 20 20 24 | ption.key......*.@param.mixed..$ |
47740 | 76 61 6c 75 65 20 54 68 65 20 76 61 6c 75 65 20 66 6f 72 20 74 68 65 20 6f 70 74 69 6f 6e 0a 20 | value.The.value.for.the.option.. |
47760 | 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 49 6e 76 61 6c 69 64 4f 70 74 69 | ....*......*.@throws.InvalidOpti |
47780 | 6f 6e 45 78 63 65 70 74 69 6f 6e 20 57 68 65 6e 20 6f 70 74 69 6f 6e 20 67 69 76 65 6e 20 64 6f | onException.When.option.given.do |
477a0 | 65 73 6e 27 74 20 65 78 69 73 74 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 49 6e 76 61 6c | esn't.exist......*.@throws.Inval |
477c0 | 69 64 4f 70 74 69 6f 6e 45 78 63 65 70 74 69 6f 6e 20 57 68 65 6e 20 61 20 72 65 71 75 69 72 65 | idOptionException.When.a.require |
477e0 | 64 20 76 61 6c 75 65 20 69 73 20 6d 69 73 73 69 6e 67 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 | d.value.is.missing......*/.....p |
47800 | 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 61 64 64 4c 6f 6e 67 4f 70 74 69 6f 6e 28 24 6e | rivate.function.addLongOption($n |
47820 | 61 6d 65 2c 20 24 76 61 6c 75 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 | ame,.$value).....{.........if.(! |
47840 | 24 74 68 69 73 2d 3e 64 65 66 69 6e 69 74 69 6f 6e 2d 3e 68 61 73 4f 70 74 69 6f 6e 28 24 6e 61 | $this->definition->hasOption($na |
47860 | 6d 65 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 | me)).{.............throw.new.Inv |
47880 | 61 6c 69 64 4f 70 74 69 6f 6e 45 78 63 65 70 74 69 6f 6e 28 73 70 72 69 6e 74 66 28 27 54 68 65 | alidOptionException(sprintf('The |
478a0 | 20 22 2d 2d 25 73 22 20 6f 70 74 69 6f 6e 20 64 6f 65 73 20 6e 6f 74 20 65 78 69 73 74 2e 27 2c | ."--%s".option.does.not.exist.', |
478c0 | 20 24 6e 61 6d 65 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 6f 70 | .$name));.........}..........$op |
478e0 | 74 69 6f 6e 20 3d 20 24 74 68 69 73 2d 3e 64 65 66 69 6e 69 74 69 6f 6e 2d 3e 67 65 74 4f 70 74 | tion.=.$this->definition->getOpt |
47900 | 69 6f 6e 28 24 6e 61 6d 65 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d | ion($name);..........if.(null.== |
47920 | 3d 20 24 76 61 6c 75 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 6f 70 74 | =.$value).{.............if.($opt |
47940 | 69 6f 6e 2d 3e 69 73 56 61 6c 75 65 52 65 71 75 69 72 65 64 28 29 29 20 7b 0a 20 20 20 20 20 20 | ion->isValueRequired()).{....... |
47960 | 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 61 6c 69 64 4f 70 74 69 6f | ..........throw.new.InvalidOptio |
47980 | 6e 45 78 63 65 70 74 69 6f 6e 28 73 70 72 69 6e 74 66 28 27 54 68 65 20 22 2d 2d 25 73 22 20 6f | nException(sprintf('The."--%s".o |
479a0 | 70 74 69 6f 6e 20 72 65 71 75 69 72 65 73 20 61 20 76 61 6c 75 65 2e 27 2c 20 24 6e 61 6d 65 29 | ption.requires.a.value.',.$name) |
479c0 | 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 76 | );.............}..............$v |
479e0 | 61 6c 75 65 20 3d 20 24 6f 70 74 69 6f 6e 2d 3e 69 73 56 61 6c 75 65 4f 70 74 69 6f 6e 61 6c 28 | alue.=.$option->isValueOptional( |
47a00 | 29 20 3f 20 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 44 65 66 61 75 6c 74 28 29 20 3a 20 74 72 75 65 | ).?.$option->getDefault().:.true |
47a20 | 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6f 70 74 69 | ;.........}..........$this->opti |
47a40 | 6f 6e 73 5b 24 6e 61 6d 65 5d 20 3d 20 24 76 61 6c 75 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 | ons[$name].=.$value;.....}...... |
47a60 | 2f 2a 2a 0a 20 20 20 20 20 2a 20 41 64 64 73 20 61 6e 20 61 72 67 75 6d 65 6e 74 20 76 61 6c 75 | /**......*.Adds.an.argument.valu |
47a80 | 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 | e.......*......*.@param.string.$ |
47aa0 | 6e 61 6d 65 20 20 54 68 65 20 61 72 67 75 6d 65 6e 74 20 6e 61 6d 65 0a 20 20 20 20 20 2a 20 40 | name..The.argument.name......*.@ |
47ac0 | 70 61 72 61 6d 20 6d 69 78 65 64 20 20 24 76 61 6c 75 65 20 54 68 65 20 76 61 6c 75 65 20 66 6f | param.mixed..$value.The.value.fo |
47ae0 | 72 20 74 68 65 20 61 72 67 75 6d 65 6e 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 | r.the.argument......*......*.@th |
47b00 | 72 6f 77 73 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 20 57 68 | rows.InvalidArgumentException.Wh |
47b20 | 65 6e 20 61 72 67 75 6d 65 6e 74 20 67 69 76 65 6e 20 64 6f 65 73 6e 27 74 20 65 78 69 73 74 0a | en.argument.given.doesn't.exist. |
47b40 | 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 61 64 64 | .....*/.....private.function.add |
47b60 | 41 72 67 75 6d 65 6e 74 28 24 6e 61 6d 65 2c 20 24 76 61 6c 75 65 29 0a 20 20 20 20 7b 0a 20 20 | Argument($name,.$value).....{... |
47b80 | 20 20 20 20 20 20 69 66 20 28 21 24 74 68 69 73 2d 3e 64 65 66 69 6e 69 74 69 6f 6e 2d 3e 68 61 | ......if.(!$this->definition->ha |
47ba0 | 73 41 72 67 75 6d 65 6e 74 28 24 6e 61 6d 65 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | sArgument($name)).{............. |
47bc0 | 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 | throw.new.InvalidArgumentExcepti |
47be0 | 6f 6e 28 73 70 72 69 6e 74 66 28 27 54 68 65 20 22 25 73 22 20 61 72 67 75 6d 65 6e 74 20 64 6f | on(sprintf('The."%s".argument.do |
47c00 | 65 73 20 6e 6f 74 20 65 78 69 73 74 2e 27 2c 20 24 6e 61 6d 65 29 29 3b 0a 20 20 20 20 20 20 20 | es.not.exist.',.$name));........ |
47c20 | 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 61 72 67 75 6d 65 6e 74 73 5b 24 6e 61 | .}..........$this->arguments[$na |
47c40 | 6d 65 5d 20 3d 20 24 76 61 6c 75 65 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a | me].=.$value;.....}.}.<?php../*. |
47c60 | 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 | .*.This.file.is.part.of.the.Symf |
47c80 | 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f | ony.package...*..*.(c).Fabien.Po |
47ca0 | 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a | tencier.<fabien@symfony.com>..*. |
47cc0 | 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 | .*.For.the.full.copyright.and.li |
47ce0 | 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 | cense.information,.please.view.t |
47d00 | 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 | he.LICENSE..*.file.that.was.dist |
47d20 | 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 | ributed.with.this.source.code... |
47d40 | 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c | */..namespace.Symfony\Component\ |
47d60 | 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 3b 0a 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 | Console\Input;..use.Symfony\Comp |
47d80 | 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 78 63 65 70 74 69 6f 6e 5c 49 6e 76 61 6c 69 64 41 | onent\Console\Exception\InvalidA |
47da0 | 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f | rgumentException;.use.Symfony\Co |
47dc0 | 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 78 63 65 70 74 69 6f 6e 5c 4c 6f 67 69 63 45 | mponent\Console\Exception\LogicE |
47de0 | 78 63 65 70 74 69 6f 6e 3b 0a 0a 2f 2a 2a 0a 20 2a 20 52 65 70 72 65 73 65 6e 74 73 20 61 20 63 | xception;../**..*.Represents.a.c |
47e00 | 6f 6d 6d 61 6e 64 20 6c 69 6e 65 20 61 72 67 75 6d 65 6e 74 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 | ommand.line.argument...*..*.@aut |
47e20 | 68 6f 72 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d | hor.Fabien.Potencier.<fabien@sym |
47e40 | 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 49 6e 70 75 74 41 72 67 75 6d 65 6e | fony.com>..*/.class.InputArgumen |
47e60 | 74 0a 7b 0a 20 20 20 20 63 6f 6e 73 74 20 52 45 51 55 49 52 45 44 20 3d 20 31 3b 0a 20 20 20 20 | t.{.....const.REQUIRED.=.1;..... |
47e80 | 63 6f 6e 73 74 20 4f 50 54 49 4f 4e 41 4c 20 3d 20 32 3b 0a 20 20 20 20 63 6f 6e 73 74 20 49 53 | const.OPTIONAL.=.2;.....const.IS |
47ea0 | 5f 41 52 52 41 59 20 3d 20 34 3b 0a 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 6e 61 6d 65 3b 0a | _ARRAY.=.4;......private.$name;. |
47ec0 | 20 20 20 20 70 72 69 76 61 74 65 20 24 6d 6f 64 65 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 | ....private.$mode;.....private.$ |
47ee0 | 64 65 66 61 75 6c 74 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 64 65 73 63 72 69 70 74 69 6f | default;.....private.$descriptio |
47f00 | 6e 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 43 6f 6e 73 74 72 75 63 74 6f 72 2e 0a | n;....../**......*.Constructor.. |
47f20 | 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6e 61 6d | .....*......*.@param.string.$nam |
47f40 | 65 20 20 20 20 20 20 20 20 54 68 65 20 61 72 67 75 6d 65 6e 74 20 6e 61 6d 65 0a 20 20 20 20 20 | e........The.argument.name...... |
47f60 | 2a 20 40 70 61 72 61 6d 20 69 6e 74 20 20 20 20 24 6d 6f 64 65 20 20 20 20 20 20 20 20 54 68 65 | *.@param.int....$mode........The |
47f80 | 20 61 72 67 75 6d 65 6e 74 20 6d 6f 64 65 3a 20 73 65 6c 66 3a 3a 52 45 51 55 49 52 45 44 20 6f | .argument.mode:.self::REQUIRED.o |
47fa0 | 72 20 73 65 6c 66 3a 3a 4f 50 54 49 4f 4e 41 4c 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 | r.self::OPTIONAL......*.@param.s |
47fc0 | 74 72 69 6e 67 20 24 64 65 73 63 72 69 70 74 69 6f 6e 20 41 20 64 65 73 63 72 69 70 74 69 6f 6e | tring.$description.A.description |
47fe0 | 20 74 65 78 74 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 6d 69 78 65 64 20 20 24 64 65 66 61 | .text......*.@param.mixed..$defa |
48000 | 75 6c 74 20 20 20 20 20 54 68 65 20 64 65 66 61 75 6c 74 20 76 61 6c 75 65 20 28 66 6f 72 20 73 | ult.....The.default.value.(for.s |
48020 | 65 6c 66 3a 3a 4f 50 54 49 4f 4e 41 4c 20 6d 6f 64 65 20 6f 6e 6c 79 29 0a 20 20 20 20 20 2a 0a | elf::OPTIONAL.mode.only)......*. |
48040 | 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 | .....*.@throws.InvalidArgumentEx |
48060 | 63 65 70 74 69 6f 6e 20 57 68 65 6e 20 61 72 67 75 6d 65 6e 74 20 6d 6f 64 65 20 69 73 20 6e 6f | ception.When.argument.mode.is.no |
48080 | 74 20 76 61 6c 69 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 | t.valid......*/.....public.funct |
480a0 | 69 6f 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 74 28 24 6e 61 6d 65 2c 20 24 6d 6f 64 65 20 3d 20 6e | ion.__construct($name,.$mode.=.n |
480c0 | 75 6c 6c 2c 20 24 64 65 73 63 72 69 70 74 69 6f 6e 20 3d 20 27 27 2c 20 24 64 65 66 61 75 6c 74 | ull,.$description.=.'',.$default |
480e0 | 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 | .=.null).....{.........if.(null. |
48100 | 3d 3d 3d 20 24 6d 6f 64 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 6f 64 65 20 3d | ===.$mode).{.............$mode.= |
48120 | 20 73 65 6c 66 3a 3a 4f 50 54 49 4f 4e 41 4c 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 | .self::OPTIONAL;.........}.elsei |
48140 | 66 20 28 21 69 73 5f 69 6e 74 28 24 6d 6f 64 65 29 20 7c 7c 20 24 6d 6f 64 65 20 3e 20 37 20 7c | f.(!is_int($mode).||.$mode.>.7.| |
48160 | 7c 20 24 6d 6f 64 65 20 3c 20 31 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 | |.$mode.<.1).{.............throw |
48180 | 20 6e 65 77 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 73 70 | .new.InvalidArgumentException(sp |
481a0 | 72 69 6e 74 66 28 27 41 72 67 75 6d 65 6e 74 20 6d 6f 64 65 20 22 25 73 22 20 69 73 20 6e 6f 74 | rintf('Argument.mode."%s".is.not |
481c0 | 20 76 61 6c 69 64 2e 27 2c 20 24 6d 6f 64 65 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 | .valid.',.$mode));.........}.... |
481e0 | 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6e 61 6d 65 20 3d 20 24 6e 61 6d 65 3b 0a 20 20 20 20 20 | ......$this->name.=.$name;...... |
48200 | 20 20 20 24 74 68 69 73 2d 3e 6d 6f 64 65 20 3d 20 24 6d 6f 64 65 3b 0a 20 20 20 20 20 20 20 20 | ...$this->mode.=.$mode;......... |
48220 | 24 74 68 69 73 2d 3e 64 65 73 63 72 69 70 74 69 6f 6e 20 3d 20 24 64 65 73 63 72 69 70 74 69 6f | $this->description.=.$descriptio |
48240 | 6e 3b 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 65 74 44 65 66 61 75 6c 74 28 24 64 | n;..........$this->setDefault($d |
48260 | 65 66 61 75 6c 74 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 | efault);.....}....../**......*.R |
48280 | 65 74 75 72 6e 73 20 74 68 65 20 61 72 67 75 6d 65 6e 74 20 6e 61 6d 65 2e 0a 20 20 20 20 20 2a | eturns.the.argument.name.......* |
482a0 | 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 20 54 68 65 20 61 72 67 75 6d | ......*.@return.string.The.argum |
482c0 | 65 6e 74 20 6e 61 6d 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 | ent.name......*/.....public.func |
482e0 | 74 69 6f 6e 20 67 65 74 4e 61 6d 65 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 | tion.getName().....{.........ret |
48300 | 75 72 6e 20 24 74 68 69 73 2d 3e 6e 61 6d 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a | urn.$this->name;.....}....../**. |
48320 | 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 74 72 75 65 20 69 66 20 74 68 65 20 61 72 67 75 6d | .....*.Returns.true.if.the.argum |
48340 | 65 6e 74 20 69 73 20 72 65 71 75 69 72 65 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 | ent.is.required.......*......*.@ |
48360 | 72 65 74 75 72 6e 20 62 6f 6f 6c 20 74 72 75 65 20 69 66 20 70 61 72 61 6d 65 74 65 72 20 6d 6f | return.bool.true.if.parameter.mo |
48380 | 64 65 20 69 73 20 73 65 6c 66 3a 3a 52 45 51 55 49 52 45 44 2c 20 66 61 6c 73 65 20 6f 74 68 65 | de.is.self::REQUIRED,.false.othe |
483a0 | 72 77 69 73 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f | rwise......*/.....public.functio |
483c0 | 6e 20 69 73 52 65 71 75 69 72 65 64 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 | n.isRequired().....{.........ret |
483e0 | 75 72 6e 20 73 65 6c 66 3a 3a 52 45 51 55 49 52 45 44 20 3d 3d 3d 20 28 73 65 6c 66 3a 3a 52 45 | urn.self::REQUIRED.===.(self::RE |
48400 | 51 55 49 52 45 44 20 26 20 24 74 68 69 73 2d 3e 6d 6f 64 65 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 | QUIRED.&.$this->mode);.....}.... |
48420 | 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 74 72 75 65 20 69 66 20 74 68 65 | ../**......*.Returns.true.if.the |
48440 | 20 61 72 67 75 6d 65 6e 74 20 63 61 6e 20 74 61 6b 65 20 6d 75 6c 74 69 70 6c 65 20 76 61 6c 75 | .argument.can.take.multiple.valu |
48460 | 65 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 62 6f 6f 6c 20 74 | es.......*......*.@return.bool.t |
48480 | 72 75 65 20 69 66 20 6d 6f 64 65 20 69 73 20 73 65 6c 66 3a 3a 49 53 5f 41 52 52 41 59 2c 20 66 | rue.if.mode.is.self::IS_ARRAY,.f |
484a0 | 61 6c 73 65 20 6f 74 68 65 72 77 69 73 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 | alse.otherwise......*/.....publi |
484c0 | 63 20 66 75 6e 63 74 69 6f 6e 20 69 73 41 72 72 61 79 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 | c.function.isArray().....{...... |
484e0 | 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 3a 3a 49 53 5f 41 52 52 41 59 20 3d 3d 3d 20 28 73 65 | ...return.self::IS_ARRAY.===.(se |
48500 | 6c 66 3a 3a 49 53 5f 41 52 52 41 59 20 26 20 24 74 68 69 73 2d 3e 6d 6f 64 65 29 3b 0a 20 20 20 | lf::IS_ARRAY.&.$this->mode);.... |
48520 | 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 74 68 65 20 64 65 66 61 | .}....../**......*.Sets.the.defa |
48540 | 75 6c 74 20 76 61 6c 75 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 | ult.value.......*......*.@param. |
48560 | 6d 69 78 65 64 20 24 64 65 66 61 75 6c 74 20 54 68 65 20 64 65 66 61 75 6c 74 20 76 61 6c 75 65 | mixed.$default.The.default.value |
48580 | 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 4c 6f 67 69 63 45 78 63 65 | ......*......*.@throws.LogicExce |
485a0 | 70 74 69 6f 6e 20 57 68 65 6e 20 69 6e 63 6f 72 72 65 63 74 20 64 65 66 61 75 6c 74 20 76 61 6c | ption.When.incorrect.default.val |
485c0 | 75 65 20 69 73 20 67 69 76 65 6e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 | ue.is.given......*/.....public.f |
485e0 | 75 6e 63 74 69 6f 6e 20 73 65 74 44 65 66 61 75 6c 74 28 24 64 65 66 61 75 6c 74 20 3d 20 6e 75 | unction.setDefault($default.=.nu |
48600 | 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 73 65 6c 66 3a 3a 52 45 51 55 | ll).....{.........if.(self::REQU |
48620 | 49 52 45 44 20 3d 3d 3d 20 24 74 68 69 73 2d 3e 6d 6f 64 65 20 26 26 20 6e 75 6c 6c 20 21 3d 3d | IRED.===.$this->mode.&&.null.!== |
48640 | 20 24 64 65 66 61 75 6c 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e | .$default).{.............throw.n |
48660 | 65 77 20 4c 6f 67 69 63 45 78 63 65 70 74 69 6f 6e 28 27 43 61 6e 6e 6f 74 20 73 65 74 20 61 20 | ew.LogicException('Cannot.set.a. |
48680 | 64 65 66 61 75 6c 74 20 76 61 6c 75 65 20 65 78 63 65 70 74 20 66 6f 72 20 49 6e 70 75 74 41 72 | default.value.except.for.InputAr |
486a0 | 67 75 6d 65 6e 74 3a 3a 4f 50 54 49 4f 4e 41 4c 20 6d 6f 64 65 2e 27 29 3b 0a 20 20 20 20 20 20 | gument::OPTIONAL.mode.');....... |
486c0 | 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 74 68 69 73 2d 3e 69 73 41 72 72 61 79 28 | ..}..........if.($this->isArray( |
486e0 | 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 64 | )).{.............if.(null.===.$d |
48700 | 65 66 61 75 6c 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 64 65 66 61 75 | efault).{.................$defau |
48720 | 6c 74 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 | lt.=.array();.............}.else |
48740 | 69 66 20 28 21 69 73 5f 61 72 72 61 79 28 24 64 65 66 61 75 6c 74 29 29 20 7b 0a 20 20 20 20 20 | if.(!is_array($default)).{...... |
48760 | 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 4c 6f 67 69 63 45 78 63 65 70 74 | ...........throw.new.LogicExcept |
48780 | 69 6f 6e 28 27 41 20 64 65 66 61 75 6c 74 20 76 61 6c 75 65 20 66 6f 72 20 61 6e 20 61 72 72 61 | ion('A.default.value.for.an.arra |
487a0 | 79 20 61 72 67 75 6d 65 6e 74 20 6d 75 73 74 20 62 65 20 61 6e 20 61 72 72 61 79 2e 27 29 3b 0a | y.argument.must.be.an.array.');. |
487c0 | 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 | ............}.........}......... |
487e0 | 20 24 74 68 69 73 2d 3e 64 65 66 61 75 6c 74 20 3d 20 24 64 65 66 61 75 6c 74 3b 0a 20 20 20 20 | .$this->default.=.$default;..... |
48800 | 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 74 68 65 20 64 65 | }....../**......*.Returns.the.de |
48820 | 66 61 75 6c 74 20 76 61 6c 75 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 | fault.value.......*......*.@retu |
48840 | 72 6e 20 6d 69 78 65 64 20 54 68 65 20 64 65 66 61 75 6c 74 20 76 61 6c 75 65 0a 20 20 20 20 20 | rn.mixed.The.default.value...... |
48860 | 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 44 65 66 61 75 6c | */.....public.function.getDefaul |
48880 | 74 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e | t().....{.........return.$this-> |
488a0 | 64 65 66 61 75 6c 74 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 | default;.....}....../**......*.R |
488c0 | 65 74 75 72 6e 73 20 74 68 65 20 64 65 73 63 72 69 70 74 69 6f 6e 20 74 65 78 74 2e 0a 20 20 20 | eturns.the.description.text..... |
488e0 | 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 20 54 68 65 20 64 65 | ..*......*.@return.string.The.de |
48900 | 73 63 72 69 70 74 69 6f 6e 20 74 65 78 74 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 | scription.text......*/.....publi |
48920 | 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 44 65 73 63 72 69 70 74 69 6f 6e 28 29 0a 20 20 20 20 | c.function.getDescription()..... |
48940 | 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 64 65 73 63 72 69 70 74 | {.........return.$this->descript |
48960 | 69 6f 6e 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 | ion;.....}.}.<?php../*..*.This.f |
48980 | 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 | ile.is.part.of.the.Symfony.packa |
489a0 | 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c | ge...*..*.(c).Fabien.Potencier.< |
489c0 | 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 | fabien@symfony.com>..*..*.For.th |
489e0 | 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 | e.full.copyright.and.license.inf |
48a00 | 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 | ormation,.please.view.the.LICENS |
48a20 | 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 | E..*.file.that.was.distributed.w |
48a40 | 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 | ith.this.source.code...*/..names |
48a60 | 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 | pace.Symfony\Component\Console\I |
48a80 | 6e 70 75 74 3b 0a 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e | nput;..use.Symfony\Component\Con |
48aa0 | 73 6f 6c 65 5c 45 78 63 65 70 74 69 6f 6e 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 | sole\Exception\InvalidArgumentEx |
48ac0 | 63 65 70 74 69 6f 6e 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 | ception;.use.Symfony\Component\C |
48ae0 | 6f 6e 73 6f 6c 65 5c 45 78 63 65 70 74 69 6f 6e 5c 4c 6f 67 69 63 45 78 63 65 70 74 69 6f 6e 3b | onsole\Exception\LogicException; |
48b00 | 0a 0a 2f 2a 2a 0a 20 2a 20 52 65 70 72 65 73 65 6e 74 73 20 61 20 63 6f 6d 6d 61 6e 64 20 6c 69 | ../**..*.Represents.a.command.li |
48b20 | 6e 65 20 6f 70 74 69 6f 6e 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 46 61 62 69 65 6e 20 | ne.option...*..*.@author.Fabien. |
48b40 | 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 | Potencier.<fabien@symfony.com>.. |
48b60 | 2a 2f 0a 63 6c 61 73 73 20 49 6e 70 75 74 4f 70 74 69 6f 6e 0a 7b 0a 20 20 20 20 63 6f 6e 73 74 | */.class.InputOption.{.....const |
48b80 | 20 56 41 4c 55 45 5f 4e 4f 4e 45 20 3d 20 31 3b 0a 20 20 20 20 63 6f 6e 73 74 20 56 41 4c 55 45 | .VALUE_NONE.=.1;.....const.VALUE |
48ba0 | 5f 52 45 51 55 49 52 45 44 20 3d 20 32 3b 0a 20 20 20 20 63 6f 6e 73 74 20 56 41 4c 55 45 5f 4f | _REQUIRED.=.2;.....const.VALUE_O |
48bc0 | 50 54 49 4f 4e 41 4c 20 3d 20 34 3b 0a 20 20 20 20 63 6f 6e 73 74 20 56 41 4c 55 45 5f 49 53 5f | PTIONAL.=.4;.....const.VALUE_IS_ |
48be0 | 41 52 52 41 59 20 3d 20 38 3b 0a 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 6e 61 6d 65 3b 0a 20 | ARRAY.=.8;......private.$name;.. |
48c00 | 20 20 20 70 72 69 76 61 74 65 20 24 73 68 6f 72 74 63 75 74 3b 0a 20 20 20 20 70 72 69 76 61 74 | ...private.$shortcut;.....privat |
48c20 | 65 20 24 6d 6f 64 65 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 64 65 66 61 75 6c 74 3b 0a 20 | e.$mode;.....private.$default;.. |
48c40 | 20 20 20 70 72 69 76 61 74 65 20 24 64 65 73 63 72 69 70 74 69 6f 6e 3b 0a 0a 20 20 20 20 2f 2a | ...private.$description;....../* |
48c60 | 2a 0a 20 20 20 20 20 2a 20 43 6f 6e 73 74 72 75 63 74 6f 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 | *......*.Constructor.......*.... |
48c80 | 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 20 20 20 20 20 20 24 6e 61 6d 65 20 20 20 | ..*.@param.string.......$name... |
48ca0 | 20 20 20 20 20 54 68 65 20 6f 70 74 69 6f 6e 20 6e 61 6d 65 0a 20 20 20 20 20 2a 20 40 70 61 72 | .....The.option.name......*.@par |
48cc0 | 61 6d 20 73 74 72 69 6e 67 7c 61 72 72 61 79 20 24 73 68 6f 72 74 63 75 74 20 20 20 20 54 68 65 | am.string|array.$shortcut....The |
48ce0 | 20 73 68 6f 72 74 63 75 74 73 2c 20 63 61 6e 20 62 65 20 6e 75 6c 6c 2c 20 61 20 73 74 72 69 6e | .shortcuts,.can.be.null,.a.strin |
48d00 | 67 20 6f 66 20 73 68 6f 72 74 63 75 74 73 20 64 65 6c 69 6d 69 74 65 64 20 62 79 20 7c 20 6f 72 | g.of.shortcuts.delimited.by.|.or |
48d20 | 20 61 6e 20 61 72 72 61 79 20 6f 66 20 73 68 6f 72 74 63 75 74 73 0a 20 20 20 20 20 2a 20 40 70 | .an.array.of.shortcuts......*.@p |
48d40 | 61 72 61 6d 20 69 6e 74 20 20 20 20 20 20 20 20 20 20 24 6d 6f 64 65 20 20 20 20 20 20 20 20 54 | aram.int..........$mode........T |
48d60 | 68 65 20 6f 70 74 69 6f 6e 20 6d 6f 64 65 3a 20 4f 6e 65 20 6f 66 20 74 68 65 20 56 41 4c 55 45 | he.option.mode:.One.of.the.VALUE |
48d80 | 5f 2a 20 63 6f 6e 73 74 61 6e 74 73 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e | _*.constants......*.@param.strin |
48da0 | 67 20 20 20 20 20 20 20 24 64 65 73 63 72 69 70 74 69 6f 6e 20 41 20 64 65 73 63 72 69 70 74 69 | g.......$description.A.descripti |
48dc0 | 6f 6e 20 74 65 78 74 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 6d 69 78 65 64 20 20 20 20 20 | on.text......*.@param.mixed..... |
48de0 | 20 20 20 24 64 65 66 61 75 6c 74 20 20 20 20 20 54 68 65 20 64 65 66 61 75 6c 74 20 76 61 6c 75 | ...$default.....The.default.valu |
48e00 | 65 20 28 6d 75 73 74 20 62 65 20 6e 75 6c 6c 20 66 6f 72 20 73 65 6c 66 3a 3a 56 41 4c 55 45 5f | e.(must.be.null.for.self::VALUE_ |
48e20 | 4e 4f 4e 45 29 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 49 6e 76 61 | NONE)......*......*.@throws.Inva |
48e40 | 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 20 49 66 20 6f 70 74 69 6f 6e 20 6d | lidArgumentException.If.option.m |
48e60 | 6f 64 65 20 69 73 20 69 6e 76 61 6c 69 64 20 6f 72 20 69 6e 63 6f 6d 70 61 74 69 62 6c 65 0a 20 | ode.is.invalid.or.incompatible.. |
48e80 | 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 63 6f 6e | ....*/.....public.function.__con |
48ea0 | 73 74 72 75 63 74 28 24 6e 61 6d 65 2c 20 24 73 68 6f 72 74 63 75 74 20 3d 20 6e 75 6c 6c 2c 20 | struct($name,.$shortcut.=.null,. |
48ec0 | 24 6d 6f 64 65 20 3d 20 6e 75 6c 6c 2c 20 24 64 65 73 63 72 69 70 74 69 6f 6e 20 3d 20 27 27 2c | $mode.=.null,.$description.=.'', |
48ee0 | 20 24 64 65 66 61 75 6c 74 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | .$default.=.null).....{......... |
48f00 | 69 66 20 28 30 20 3d 3d 3d 20 73 74 72 70 6f 73 28 24 6e 61 6d 65 2c 20 27 2d 2d 27 29 29 20 7b | if.(0.===.strpos($name,.'--')).{ |
48f20 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6e 61 6d 65 20 3d 20 73 75 62 73 74 72 28 24 6e 61 6d | .............$name.=.substr($nam |
48f40 | 65 2c 20 32 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 65 6d | e,.2);.........}..........if.(em |
48f60 | 70 74 79 28 24 6e 61 6d 65 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 | pty($name)).{.............throw. |
48f80 | 6e 65 77 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 27 41 6e | new.InvalidArgumentException('An |
48fa0 | 20 6f 70 74 69 6f 6e 20 6e 61 6d 65 20 63 61 6e 6e 6f 74 20 62 65 20 65 6d 70 74 79 2e 27 29 3b | .option.name.cannot.be.empty.'); |
48fc0 | 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 65 6d 70 74 79 28 24 73 | .........}..........if.(empty($s |
48fe0 | 68 6f 72 74 63 75 74 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 73 68 6f 72 74 63 75 | hortcut)).{.............$shortcu |
49000 | 74 20 3d 20 6e 75 6c 6c 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 | t.=.null;.........}..........if. |
49020 | 28 6e 75 6c 6c 20 21 3d 3d 20 24 73 68 6f 72 74 63 75 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | (null.!==.$shortcut).{.......... |
49040 | 20 20 20 69 66 20 28 69 73 5f 61 72 72 61 79 28 24 73 68 6f 72 74 63 75 74 29 29 20 7b 0a 20 20 | ...if.(is_array($shortcut)).{... |
49060 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 73 68 6f 72 74 63 75 74 20 3d 20 69 6d 70 6c 6f 64 | ..............$shortcut.=.implod |
49080 | 65 28 27 7c 27 2c 20 24 73 68 6f 72 74 63 75 74 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d | e('|',.$shortcut);.............} |
490a0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 73 68 6f 72 74 63 75 74 73 20 3d 20 70 72 65 67 5f 73 | .............$shortcuts.=.preg_s |
490c0 | 70 6c 69 74 28 27 7b 28 5c 7c 29 2d 3f 7d 27 2c 20 6c 74 72 69 6d 28 24 73 68 6f 72 74 63 75 74 | plit('{(\|)-?}',.ltrim($shortcut |
490e0 | 2c 20 27 2d 27 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 73 68 6f 72 74 63 75 74 73 20 | ,.'-'));.............$shortcuts. |
49100 | 3d 20 61 72 72 61 79 5f 66 69 6c 74 65 72 28 24 73 68 6f 72 74 63 75 74 73 29 3b 0a 20 20 20 20 | =.array_filter($shortcuts);..... |
49120 | 20 20 20 20 20 20 20 20 24 73 68 6f 72 74 63 75 74 20 3d 20 69 6d 70 6c 6f 64 65 28 27 7c 27 2c | ........$shortcut.=.implode('|', |
49140 | 20 24 73 68 6f 72 74 63 75 74 73 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 65 | .$shortcuts);..............if.(e |
49160 | 6d 70 74 79 28 24 73 68 6f 72 74 63 75 74 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | mpty($shortcut)).{.............. |
49180 | 20 20 20 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 | ...throw.new.InvalidArgumentExce |
491a0 | 70 74 69 6f 6e 28 27 41 6e 20 6f 70 74 69 6f 6e 20 73 68 6f 72 74 63 75 74 20 63 61 6e 6e 6f 74 | ption('An.option.shortcut.cannot |
491c0 | 20 62 65 20 65 6d 70 74 79 2e 27 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 | .be.empty.');.............}..... |
491e0 | 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 6d 6f 64 | ....}..........if.(null.===.$mod |
49200 | 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 6f 64 65 20 3d 20 73 65 6c 66 3a 3a 56 | e).{.............$mode.=.self::V |
49220 | 41 4c 55 45 5f 4e 4f 4e 45 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 21 69 73 | ALUE_NONE;.........}.elseif.(!is |
49240 | 5f 69 6e 74 28 24 6d 6f 64 65 29 20 7c 7c 20 24 6d 6f 64 65 20 3e 20 31 35 20 7c 7c 20 24 6d 6f | _int($mode).||.$mode.>.15.||.$mo |
49260 | 64 65 20 3c 20 31 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 | de.<.1).{.............throw.new. |
49280 | 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 73 70 72 69 6e 74 66 | InvalidArgumentException(sprintf |
492a0 | 28 27 4f 70 74 69 6f 6e 20 6d 6f 64 65 20 22 25 73 22 20 69 73 20 6e 6f 74 20 76 61 6c 69 64 2e | ('Option.mode."%s".is.not.valid. |
492c0 | 27 2c 20 24 6d 6f 64 65 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 | ',.$mode));.........}..........$ |
492e0 | 74 68 69 73 2d 3e 6e 61 6d 65 20 3d 20 24 6e 61 6d 65 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 | this->name.=.$name;.........$thi |
49300 | 73 2d 3e 73 68 6f 72 74 63 75 74 20 3d 20 24 73 68 6f 72 74 63 75 74 3b 0a 20 20 20 20 20 20 20 | s->shortcut.=.$shortcut;........ |
49320 | 20 24 74 68 69 73 2d 3e 6d 6f 64 65 20 3d 20 24 6d 6f 64 65 3b 0a 20 20 20 20 20 20 20 20 24 74 | .$this->mode.=.$mode;.........$t |
49340 | 68 69 73 2d 3e 64 65 73 63 72 69 70 74 69 6f 6e 20 3d 20 24 64 65 73 63 72 69 70 74 69 6f 6e 3b | his->description.=.$description; |
49360 | 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 74 68 69 73 2d 3e 69 73 41 72 72 61 79 28 29 20 26 | ..........if.($this->isArray().& |
49380 | 26 20 21 24 74 68 69 73 2d 3e 61 63 63 65 70 74 56 61 6c 75 65 28 29 29 20 7b 0a 20 20 20 20 20 | &.!$this->acceptValue()).{...... |
493a0 | 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 | .......throw.new.InvalidArgument |
493c0 | 45 78 63 65 70 74 69 6f 6e 28 27 49 6d 70 6f 73 73 69 62 6c 65 20 74 6f 20 68 61 76 65 20 61 6e | Exception('Impossible.to.have.an |
493e0 | 20 6f 70 74 69 6f 6e 20 6d 6f 64 65 20 56 41 4c 55 45 5f 49 53 5f 41 52 52 41 59 20 69 66 20 74 | .option.mode.VALUE_IS_ARRAY.if.t |
49400 | 68 65 20 6f 70 74 69 6f 6e 20 64 6f 65 73 20 6e 6f 74 20 61 63 63 65 70 74 20 61 20 76 61 6c 75 | he.option.does.not.accept.a.valu |
49420 | 65 2e 27 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e | e.');.........}..........$this-> |
49440 | 73 65 74 44 65 66 61 75 6c 74 28 24 64 65 66 61 75 6c 74 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 | setDefault($default);.....}..... |
49460 | 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 74 68 65 20 6f 70 74 69 6f 6e 20 73 | ./**......*.Returns.the.option.s |
49480 | 68 6f 72 74 63 75 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 | hortcut.......*......*.@return.s |
494a0 | 74 72 69 6e 67 20 54 68 65 20 73 68 6f 72 74 63 75 74 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 | tring.The.shortcut......*/.....p |
494c0 | 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 53 68 6f 72 74 63 75 74 28 29 0a 20 20 20 | ublic.function.getShortcut().... |
494e0 | 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 73 68 6f 72 74 63 75 | .{.........return.$this->shortcu |
49500 | 74 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 | t;.....}....../**......*.Returns |
49520 | 20 74 68 65 20 6f 70 74 69 6f 6e 20 6e 61 6d 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 | .the.option.name.......*......*. |
49540 | 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 20 54 68 65 20 6e 61 6d 65 0a 20 20 20 20 20 2a 2f 0a | @return.string.The.name......*/. |
49560 | 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 4e 61 6d 65 28 29 0a 20 20 | ....public.function.getName()... |
49580 | 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 6e 61 6d 65 3b 0a | ..{.........return.$this->name;. |
495a0 | 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 74 72 | ....}....../**......*.Returns.tr |
495c0 | 75 65 20 69 66 20 74 68 65 20 6f 70 74 69 6f 6e 20 61 63 63 65 70 74 73 20 61 20 76 61 6c 75 65 | ue.if.the.option.accepts.a.value |
495e0 | 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 62 6f 6f 6c 20 74 72 75 | .......*......*.@return.bool.tru |
49600 | 65 20 69 66 20 76 61 6c 75 65 20 6d 6f 64 65 20 69 73 20 6e 6f 74 20 73 65 6c 66 3a 3a 56 41 4c | e.if.value.mode.is.not.self::VAL |
49620 | 55 45 5f 4e 4f 4e 45 2c 20 66 61 6c 73 65 20 6f 74 68 65 72 77 69 73 65 0a 20 20 20 20 20 2a 2f | UE_NONE,.false.otherwise......*/ |
49640 | 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 61 63 63 65 70 74 56 61 6c 75 65 | .....public.function.acceptValue |
49660 | 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 69 | ().....{.........return.$this->i |
49680 | 73 56 61 6c 75 65 52 65 71 75 69 72 65 64 28 29 20 7c 7c 20 24 74 68 69 73 2d 3e 69 73 56 61 6c | sValueRequired().||.$this->isVal |
496a0 | 75 65 4f 70 74 69 6f 6e 61 6c 28 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 | ueOptional();.....}....../**.... |
496c0 | 20 20 2a 20 52 65 74 75 72 6e 73 20 74 72 75 65 20 69 66 20 74 68 65 20 6f 70 74 69 6f 6e 20 72 | ..*.Returns.true.if.the.option.r |
496e0 | 65 71 75 69 72 65 73 20 61 20 76 61 6c 75 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 | equires.a.value.......*......*.@ |
49700 | 72 65 74 75 72 6e 20 62 6f 6f 6c 20 74 72 75 65 20 69 66 20 76 61 6c 75 65 20 6d 6f 64 65 20 69 | return.bool.true.if.value.mode.i |
49720 | 73 20 73 65 6c 66 3a 3a 56 41 4c 55 45 5f 52 45 51 55 49 52 45 44 2c 20 66 61 6c 73 65 20 6f 74 | s.self::VALUE_REQUIRED,.false.ot |
49740 | 68 65 72 77 69 73 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 | herwise......*/.....public.funct |
49760 | 69 6f 6e 20 69 73 56 61 6c 75 65 52 65 71 75 69 72 65 64 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 | ion.isValueRequired().....{..... |
49780 | 20 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 3a 3a 56 41 4c 55 45 5f 52 45 51 55 49 52 45 44 20 | ....return.self::VALUE_REQUIRED. |
497a0 | 3d 3d 3d 20 28 73 65 6c 66 3a 3a 56 41 4c 55 45 5f 52 45 51 55 49 52 45 44 20 26 20 24 74 68 69 | ===.(self::VALUE_REQUIRED.&.$thi |
497c0 | 73 2d 3e 6d 6f 64 65 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 | s->mode);.....}....../**......*. |
497e0 | 52 65 74 75 72 6e 73 20 74 72 75 65 20 69 66 20 74 68 65 20 6f 70 74 69 6f 6e 20 74 61 6b 65 73 | Returns.true.if.the.option.takes |
49800 | 20 61 6e 20 6f 70 74 69 6f 6e 61 6c 20 76 61 6c 75 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 | .an.optional.value.......*...... |
49820 | 2a 20 40 72 65 74 75 72 6e 20 62 6f 6f 6c 20 74 72 75 65 20 69 66 20 76 61 6c 75 65 20 6d 6f 64 | *.@return.bool.true.if.value.mod |
49840 | 65 20 69 73 20 73 65 6c 66 3a 3a 56 41 4c 55 45 5f 4f 50 54 49 4f 4e 41 4c 2c 20 66 61 6c 73 65 | e.is.self::VALUE_OPTIONAL,.false |
49860 | 20 6f 74 68 65 72 77 69 73 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 | .otherwise......*/.....public.fu |
49880 | 6e 63 74 69 6f 6e 20 69 73 56 61 6c 75 65 4f 70 74 69 6f 6e 61 6c 28 29 0a 20 20 20 20 7b 0a 20 | nction.isValueOptional().....{.. |
498a0 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 3a 3a 56 41 4c 55 45 5f 4f 50 54 49 4f 4e | .......return.self::VALUE_OPTION |
498c0 | 41 4c 20 3d 3d 3d 20 28 73 65 6c 66 3a 3a 56 41 4c 55 45 5f 4f 50 54 49 4f 4e 41 4c 20 26 20 24 | AL.===.(self::VALUE_OPTIONAL.&.$ |
498e0 | 74 68 69 73 2d 3e 6d 6f 64 65 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 | this->mode);.....}....../**..... |
49900 | 20 2a 20 52 65 74 75 72 6e 73 20 74 72 75 65 20 69 66 20 74 68 65 20 6f 70 74 69 6f 6e 20 63 61 | .*.Returns.true.if.the.option.ca |
49920 | 6e 20 74 61 6b 65 20 6d 75 6c 74 69 70 6c 65 20 76 61 6c 75 65 73 2e 0a 20 20 20 20 20 2a 0a 20 | n.take.multiple.values.......*.. |
49940 | 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 62 6f 6f 6c 20 74 72 75 65 20 69 66 20 6d 6f 64 65 20 | ....*.@return.bool.true.if.mode. |
49960 | 69 73 20 73 65 6c 66 3a 3a 56 41 4c 55 45 5f 49 53 5f 41 52 52 41 59 2c 20 66 61 6c 73 65 20 6f | is.self::VALUE_IS_ARRAY,.false.o |
49980 | 74 68 65 72 77 69 73 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 | therwise......*/.....public.func |
499a0 | 74 69 6f 6e 20 69 73 41 72 72 61 79 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 | tion.isArray().....{.........ret |
499c0 | 75 72 6e 20 73 65 6c 66 3a 3a 56 41 4c 55 45 5f 49 53 5f 41 52 52 41 59 20 3d 3d 3d 20 28 73 65 | urn.self::VALUE_IS_ARRAY.===.(se |
499e0 | 6c 66 3a 3a 56 41 4c 55 45 5f 49 53 5f 41 52 52 41 59 20 26 20 24 74 68 69 73 2d 3e 6d 6f 64 65 | lf::VALUE_IS_ARRAY.&.$this->mode |
49a00 | 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 74 68 | );.....}....../**......*.Sets.th |
49a20 | 65 20 64 65 66 61 75 6c 74 20 76 61 6c 75 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 | e.default.value.......*......*.@ |
49a40 | 70 61 72 61 6d 20 6d 69 78 65 64 20 24 64 65 66 61 75 6c 74 20 54 68 65 20 64 65 66 61 75 6c 74 | param.mixed.$default.The.default |
49a60 | 20 76 61 6c 75 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 4c 6f 67 | .value......*......*.@throws.Log |
49a80 | 69 63 45 78 63 65 70 74 69 6f 6e 20 57 68 65 6e 20 69 6e 63 6f 72 72 65 63 74 20 64 65 66 61 75 | icException.When.incorrect.defau |
49aa0 | 6c 74 20 76 61 6c 75 65 20 69 73 20 67 69 76 65 6e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 | lt.value.is.given......*/.....pu |
49ac0 | 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 44 65 66 61 75 6c 74 28 24 64 65 66 61 75 6c | blic.function.setDefault($defaul |
49ae0 | 74 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 73 65 6c 66 | t.=.null).....{.........if.(self |
49b00 | 3a 3a 56 41 4c 55 45 5f 4e 4f 4e 45 20 3d 3d 3d 20 28 73 65 6c 66 3a 3a 56 41 4c 55 45 5f 4e 4f | ::VALUE_NONE.===.(self::VALUE_NO |
49b20 | 4e 45 20 26 20 24 74 68 69 73 2d 3e 6d 6f 64 65 29 20 26 26 20 6e 75 6c 6c 20 21 3d 3d 20 24 64 | NE.&.$this->mode).&&.null.!==.$d |
49b40 | 65 66 61 75 6c 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 | efault).{.............throw.new. |
49b60 | 4c 6f 67 69 63 45 78 63 65 70 74 69 6f 6e 28 27 43 61 6e 6e 6f 74 20 73 65 74 20 61 20 64 65 66 | LogicException('Cannot.set.a.def |
49b80 | 61 75 6c 74 20 76 61 6c 75 65 20 77 68 65 6e 20 75 73 69 6e 67 20 49 6e 70 75 74 4f 70 74 69 6f | ault.value.when.using.InputOptio |
49ba0 | 6e 3a 3a 56 41 4c 55 45 5f 4e 4f 4e 45 20 6d 6f 64 65 2e 27 29 3b 0a 20 20 20 20 20 20 20 20 7d | n::VALUE_NONE.mode.');.........} |
49bc0 | 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 74 68 69 73 2d 3e 69 73 41 72 72 61 79 28 29 29 20 | ..........if.($this->isArray()). |
49be0 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 64 65 66 61 | {.............if.(null.===.$defa |
49c00 | 75 6c 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 64 65 66 61 75 6c 74 20 | ult).{.................$default. |
49c20 | 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 | =.array();.............}.elseif. |
49c40 | 28 21 69 73 5f 61 72 72 61 79 28 24 64 65 66 61 75 6c 74 29 29 20 7b 0a 20 20 20 20 20 20 20 20 | (!is_array($default)).{......... |
49c60 | 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 4c 6f 67 69 63 45 78 63 65 70 74 69 6f 6e | ........throw.new.LogicException |
49c80 | 28 27 41 20 64 65 66 61 75 6c 74 20 76 61 6c 75 65 20 66 6f 72 20 61 6e 20 61 72 72 61 79 20 6f | ('A.default.value.for.an.array.o |
49ca0 | 70 74 69 6f 6e 20 6d 75 73 74 20 62 65 20 61 6e 20 61 72 72 61 79 2e 27 29 3b 0a 20 20 20 20 20 | ption.must.be.an.array.');...... |
49cc0 | 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 | .......}.........}..........$thi |
49ce0 | 73 2d 3e 64 65 66 61 75 6c 74 20 3d 20 24 74 68 69 73 2d 3e 61 63 63 65 70 74 56 61 6c 75 65 28 | s->default.=.$this->acceptValue( |
49d00 | 29 20 3f 20 24 64 65 66 61 75 6c 74 20 3a 20 66 61 6c 73 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 | ).?.$default.:.false;.....}..... |
49d20 | 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 74 68 65 20 64 65 66 61 75 6c 74 20 | ./**......*.Returns.the.default. |
49d40 | 76 61 6c 75 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 6d 69 78 | value.......*......*.@return.mix |
49d60 | 65 64 20 54 68 65 20 64 65 66 61 75 6c 74 20 76 61 6c 75 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 | ed.The.default.value......*/.... |
49d80 | 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 44 65 66 61 75 6c 74 28 29 0a 20 20 | .public.function.getDefault()... |
49da0 | 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 64 65 66 61 75 6c | ..{.........return.$this->defaul |
49dc0 | 74 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 | t;.....}....../**......*.Returns |
49de0 | 20 74 68 65 20 64 65 73 63 72 69 70 74 69 6f 6e 20 74 65 78 74 2e 0a 20 20 20 20 20 2a 0a 20 20 | .the.description.text.......*... |
49e00 | 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 20 54 68 65 20 64 65 73 63 72 69 70 74 | ...*.@return.string.The.descript |
49e20 | 69 6f 6e 20 74 65 78 74 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 | ion.text......*/.....public.func |
49e40 | 74 69 6f 6e 20 67 65 74 44 65 73 63 72 69 70 74 69 6f 6e 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 | tion.getDescription().....{..... |
49e60 | 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 64 65 73 63 72 69 70 74 69 6f 6e 3b 0a 20 | ....return.$this->description;.. |
49e80 | 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 43 68 65 63 6b 73 20 77 68 65 74 | ...}....../**......*.Checks.whet |
49ea0 | 68 65 72 20 74 68 65 20 67 69 76 65 6e 20 6f 70 74 69 6f 6e 20 65 71 75 61 6c 73 20 74 68 69 73 | her.the.given.option.equals.this |
49ec0 | 20 6f 6e 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 49 6e 70 75 74 | .one.......*......*.@param.Input |
49ee0 | 4f 70 74 69 6f 6e 20 24 6f 70 74 69 6f 6e 20 6f 70 74 69 6f 6e 20 74 6f 20 63 6f 6d 70 61 72 65 | Option.$option.option.to.compare |
49f00 | 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 62 6f 6f 6c 0a 20 20 20 20 | ......*......*.@return.bool..... |
49f20 | 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 65 71 75 61 6c 73 28 49 | .*/.....public.function.equals(I |
49f40 | 6e 70 75 74 4f 70 74 69 6f 6e 20 24 6f 70 74 69 6f 6e 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 | nputOption.$option).....{....... |
49f60 | 20 20 72 65 74 75 72 6e 20 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 4e 61 6d 65 28 29 20 3d 3d 3d 20 | ..return.$option->getName().===. |
49f80 | 24 74 68 69 73 2d 3e 67 65 74 4e 61 6d 65 28 29 0a 20 20 20 20 20 20 20 20 20 20 20 20 26 26 20 | $this->getName().............&&. |
49fa0 | 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 53 68 6f 72 74 63 75 74 28 29 20 3d 3d 3d 20 24 74 68 69 73 | $option->getShortcut().===.$this |
49fc0 | 2d 3e 67 65 74 53 68 6f 72 74 63 75 74 28 29 0a 20 20 20 20 20 20 20 20 20 20 20 20 26 26 20 24 | ->getShortcut().............&&.$ |
49fe0 | 6f 70 74 69 6f 6e 2d 3e 67 65 74 44 65 66 61 75 6c 74 28 29 20 3d 3d 3d 20 24 74 68 69 73 2d 3e | option->getDefault().===.$this-> |
4a000 | 67 65 74 44 65 66 61 75 6c 74 28 29 0a 20 20 20 20 20 20 20 20 20 20 20 20 26 26 20 24 6f 70 74 | getDefault().............&&.$opt |
4a020 | 69 6f 6e 2d 3e 69 73 41 72 72 61 79 28 29 20 3d 3d 3d 20 24 74 68 69 73 2d 3e 69 73 41 72 72 61 | ion->isArray().===.$this->isArra |
4a040 | 79 28 29 0a 20 20 20 20 20 20 20 20 20 20 20 20 26 26 20 24 6f 70 74 69 6f 6e 2d 3e 69 73 56 61 | y().............&&.$option->isVa |
4a060 | 6c 75 65 52 65 71 75 69 72 65 64 28 29 20 3d 3d 3d 20 24 74 68 69 73 2d 3e 69 73 56 61 6c 75 65 | lueRequired().===.$this->isValue |
4a080 | 52 65 71 75 69 72 65 64 28 29 0a 20 20 20 20 20 20 20 20 20 20 20 20 26 26 20 24 6f 70 74 69 6f | Required().............&&.$optio |
4a0a0 | 6e 2d 3e 69 73 56 61 6c 75 65 4f 70 74 69 6f 6e 61 6c 28 29 20 3d 3d 3d 20 24 74 68 69 73 2d 3e | n->isValueOptional().===.$this-> |
4a0c0 | 69 73 56 61 6c 75 65 4f 70 74 69 6f 6e 61 6c 28 29 0a 20 20 20 20 20 20 20 20 3b 0a 20 20 20 20 | isValueOptional().........;..... |
4a0e0 | 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 | }.}.<?php../*..*.This.file.is.pa |
4a100 | 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a | rt.of.the.Symfony.package...*..* |
4a120 | 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 | .(c).Fabien.Potencier.<fabien@sy |
4a140 | 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f | mfony.com>..*..*.For.the.full.co |
4a160 | 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c | pyright.and.license.information, |
4a180 | 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 | .please.view.the.LICENSE..*.file |
4a1a0 | 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 | .that.was.distributed.with.this. |
4a1c0 | 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 | source.code...*/..namespace.Symf |
4a1e0 | 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 3b 0a 0a 75 73 | ony\Component\Console\Input;..us |
4a200 | 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 78 63 65 | e.Symfony\Component\Console\Exce |
4a220 | 70 74 69 6f 6e 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 3b 0a | ption\InvalidArgumentException;. |
4a240 | 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 78 | use.Symfony\Component\Console\Ex |
4a260 | 63 65 70 74 69 6f 6e 5c 52 75 6e 74 69 6d 65 45 78 63 65 70 74 69 6f 6e 3b 0a 0a 2f 2a 2a 0a 20 | ception\RuntimeException;../**.. |
4a280 | 2a 20 49 6e 70 75 74 20 69 73 20 74 68 65 20 62 61 73 65 20 63 6c 61 73 73 20 66 6f 72 20 61 6c | *.Input.is.the.base.class.for.al |
4a2a0 | 6c 20 63 6f 6e 63 72 65 74 65 20 49 6e 70 75 74 20 63 6c 61 73 73 65 73 2e 0a 20 2a 0a 20 2a 20 | l.concrete.Input.classes...*..*. |
4a2c0 | 54 68 72 65 65 20 63 6f 6e 63 72 65 74 65 20 63 6c 61 73 73 65 73 20 61 72 65 20 70 72 6f 76 69 | Three.concrete.classes.are.provi |
4a2e0 | 64 65 64 20 62 79 20 64 65 66 61 75 6c 74 3a 0a 20 2a 0a 20 2a 20 20 2a 20 60 41 72 67 76 49 6e | ded.by.default:..*..*..*.`ArgvIn |
4a300 | 70 75 74 60 3a 20 54 68 65 20 69 6e 70 75 74 20 63 6f 6d 65 73 20 66 72 6f 6d 20 74 68 65 20 43 | put`:.The.input.comes.from.the.C |
4a320 | 4c 49 20 61 72 67 75 6d 65 6e 74 73 20 28 61 72 67 76 29 0a 20 2a 20 20 2a 20 60 53 74 72 69 6e | LI.arguments.(argv)..*..*.`Strin |
4a340 | 67 49 6e 70 75 74 60 3a 20 54 68 65 20 69 6e 70 75 74 20 69 73 20 70 72 6f 76 69 64 65 64 20 61 | gInput`:.The.input.is.provided.a |
4a360 | 73 20 61 20 73 74 72 69 6e 67 0a 20 2a 20 20 2a 20 60 41 72 72 61 79 49 6e 70 75 74 60 3a 20 54 | s.a.string..*..*.`ArrayInput`:.T |
4a380 | 68 65 20 69 6e 70 75 74 20 69 73 20 70 72 6f 76 69 64 65 64 20 61 73 20 61 6e 20 61 72 72 61 79 | he.input.is.provided.as.an.array |
4a3a0 | 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 | ..*..*.@author.Fabien.Potencier. |
4a3c0 | 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 2f 0a 61 62 73 74 72 61 63 | <fabien@symfony.com>..*/.abstrac |
4a3e0 | 74 20 63 6c 61 73 73 20 49 6e 70 75 74 20 69 6d 70 6c 65 6d 65 6e 74 73 20 49 6e 70 75 74 49 6e | t.class.Input.implements.InputIn |
4a400 | 74 65 72 66 61 63 65 0a 7b 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 76 61 72 20 49 6e | terface.{...../**......*.@var.In |
4a420 | 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 6f 74 65 63 | putDefinition......*/.....protec |
4a440 | 74 65 64 20 24 64 65 66 69 6e 69 74 69 6f 6e 3b 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 24 | ted.$definition;.....protected.$ |
4a460 | 6f 70 74 69 6f 6e 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 | options.=.array();.....protected |
4a480 | 20 24 61 72 67 75 6d 65 6e 74 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 70 72 6f 74 65 | .$arguments.=.array();.....prote |
4a4a0 | 63 74 65 64 20 24 69 6e 74 65 72 61 63 74 69 76 65 20 3d 20 74 72 75 65 3b 0a 0a 20 20 20 20 2f | cted.$interactive.=.true;....../ |
4a4c0 | 2a 2a 0a 20 20 20 20 20 2a 20 43 6f 6e 73 74 72 75 63 74 6f 72 2e 0a 20 20 20 20 20 2a 0a 20 20 | **......*.Constructor.......*... |
4a4e0 | 20 20 20 2a 20 40 70 61 72 61 6d 20 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 7c 6e 75 6c 6c | ...*.@param.InputDefinition|null |
4a500 | 20 24 64 65 66 69 6e 69 74 69 6f 6e 20 41 20 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 20 69 | .$definition.A.InputDefinition.i |
4a520 | 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 | nstance......*/.....public.funct |
4a540 | 69 6f 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 74 28 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 20 | ion.__construct(InputDefinition. |
4a560 | 24 64 65 66 69 6e 69 74 69 6f 6e 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 | $definition.=.null).....{....... |
4a580 | 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 64 65 66 69 6e 69 74 69 6f 6e 29 20 7b 0a 20 20 | ..if.(null.===.$definition).{... |
4a5a0 | 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 64 65 66 69 6e 69 74 69 6f 6e 20 3d 20 6e 65 | ..........$this->definition.=.ne |
4a5c0 | 77 20 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 28 29 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 | w.InputDefinition();.........}.e |
4a5e0 | 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 62 69 6e 64 28 24 64 | lse.{.............$this->bind($d |
4a600 | 65 66 69 6e 69 74 69 6f 6e 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 76 | efinition);.............$this->v |
4a620 | 61 6c 69 64 61 74 65 28 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 | alidate();.........}.....}...... |
4a640 | 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f | /**......*.{@inheritdoc}......*/ |
4a660 | 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 62 69 6e 64 28 49 6e 70 75 74 44 | .....public.function.bind(InputD |
4a680 | 65 66 69 6e 69 74 69 6f 6e 20 24 64 65 66 69 6e 69 74 69 6f 6e 29 0a 20 20 20 20 7b 0a 20 20 20 | efinition.$definition).....{.... |
4a6a0 | 20 20 20 20 20 24 74 68 69 73 2d 3e 61 72 67 75 6d 65 6e 74 73 20 3d 20 61 72 72 61 79 28 29 3b | .....$this->arguments.=.array(); |
4a6c0 | 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6f 70 74 69 6f 6e 73 20 3d 20 61 72 72 61 79 28 | .........$this->options.=.array( |
4a6e0 | 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 64 65 66 69 6e 69 74 69 6f 6e 20 3d 20 24 | );.........$this->definition.=.$ |
4a700 | 64 65 66 69 6e 69 74 69 6f 6e 3b 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 70 61 72 73 | definition;..........$this->pars |
4a720 | 65 28 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 50 72 6f 63 65 | e();.....}....../**......*.Proce |
4a740 | 73 73 65 73 20 63 6f 6d 6d 61 6e 64 20 6c 69 6e 65 20 61 72 67 75 6d 65 6e 74 73 2e 0a 20 20 20 | sses.command.line.arguments..... |
4a760 | 20 20 2a 2f 0a 20 20 20 20 61 62 73 74 72 61 63 74 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 | ..*/.....abstract.protected.func |
4a780 | 74 69 6f 6e 20 70 61 72 73 65 28 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 | tion.parse();....../**......*.{@ |
4a7a0 | 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 | inheritdoc}......*/.....public.f |
4a7c0 | 75 6e 63 74 69 6f 6e 20 76 61 6c 69 64 61 74 65 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 | unction.validate().....{........ |
4a7e0 | 20 24 64 65 66 69 6e 69 74 69 6f 6e 20 3d 20 24 74 68 69 73 2d 3e 64 65 66 69 6e 69 74 69 6f 6e | .$definition.=.$this->definition |
4a800 | 3b 0a 20 20 20 20 20 20 20 20 24 67 69 76 65 6e 41 72 67 75 6d 65 6e 74 73 20 3d 20 24 74 68 69 | ;.........$givenArguments.=.$thi |
4a820 | 73 2d 3e 61 72 67 75 6d 65 6e 74 73 3b 0a 0a 20 20 20 20 20 20 20 20 24 6d 69 73 73 69 6e 67 41 | s->arguments;..........$missingA |
4a840 | 72 67 75 6d 65 6e 74 73 20 3d 20 61 72 72 61 79 5f 66 69 6c 74 65 72 28 61 72 72 61 79 5f 6b 65 | rguments.=.array_filter(array_ke |
4a860 | 79 73 28 24 64 65 66 69 6e 69 74 69 6f 6e 2d 3e 67 65 74 41 72 67 75 6d 65 6e 74 73 28 29 29 2c | ys($definition->getArguments()), |
4a880 | 20 66 75 6e 63 74 69 6f 6e 20 28 24 61 72 67 75 6d 65 6e 74 29 20 75 73 65 20 28 24 64 65 66 69 | .function.($argument).use.($defi |
4a8a0 | 6e 69 74 69 6f 6e 2c 20 24 67 69 76 65 6e 41 72 67 75 6d 65 6e 74 73 29 20 7b 0a 20 20 20 20 20 | nition,.$givenArguments).{...... |
4a8c0 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 21 61 72 72 61 79 5f 6b 65 79 5f 65 78 69 73 74 73 28 | .......return.!array_key_exists( |
4a8e0 | 24 61 72 67 75 6d 65 6e 74 2c 20 24 67 69 76 65 6e 41 72 67 75 6d 65 6e 74 73 29 20 26 26 20 24 | $argument,.$givenArguments).&&.$ |
4a900 | 64 65 66 69 6e 69 74 69 6f 6e 2d 3e 67 65 74 41 72 67 75 6d 65 6e 74 28 24 61 72 67 75 6d 65 6e | definition->getArgument($argumen |
4a920 | 74 29 2d 3e 69 73 52 65 71 75 69 72 65 64 28 29 3b 0a 20 20 20 20 20 20 20 20 7d 29 3b 0a 0a 20 | t)->isRequired();.........});... |
4a940 | 20 20 20 20 20 20 20 69 66 20 28 63 6f 75 6e 74 28 24 6d 69 73 73 69 6e 67 41 72 67 75 6d 65 6e | .......if.(count($missingArgumen |
4a960 | 74 73 29 20 3e 20 30 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 | ts).>.0).{.............throw.new |
4a980 | 20 52 75 6e 74 69 6d 65 45 78 63 65 70 74 69 6f 6e 28 73 70 72 69 6e 74 66 28 27 4e 6f 74 20 65 | .RuntimeException(sprintf('Not.e |
4a9a0 | 6e 6f 75 67 68 20 61 72 67 75 6d 65 6e 74 73 20 28 6d 69 73 73 69 6e 67 3a 20 22 25 73 22 29 2e | nough.arguments.(missing:."%s"). |
4a9c0 | 27 2c 20 69 6d 70 6c 6f 64 65 28 27 2c 20 27 2c 20 24 6d 69 73 73 69 6e 67 41 72 67 75 6d 65 6e | ',.implode(',.',.$missingArgumen |
4a9e0 | 74 73 29 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a | ts)));.........}.....}....../**. |
4aa00 | 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 | .....*.{@inheritdoc}......*/.... |
4aa20 | 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 69 73 49 6e 74 65 72 61 63 74 69 76 65 28 29 | .public.function.isInteractive() |
4aa40 | 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 69 6e 74 | .....{.........return.$this->int |
4aa60 | 65 72 61 63 74 69 76 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 | eractive;.....}....../**......*. |
4aa80 | 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 | {@inheritdoc}......*/.....public |
4aaa0 | 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 49 6e 74 65 72 61 63 74 69 76 65 28 24 69 6e 74 65 72 61 | .function.setInteractive($intera |
4aac0 | 63 74 69 76 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 69 6e 74 65 | ctive).....{.........$this->inte |
4aae0 | 72 61 63 74 69 76 65 20 3d 20 28 62 6f 6f 6c 29 20 24 69 6e 74 65 72 61 63 74 69 76 65 3b 0a 20 | ractive.=.(bool).$interactive;.. |
4ab00 | 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f | ...}....../**......*.{@inheritdo |
4ab20 | 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 | c}......*/.....public.function.g |
4ab40 | 65 74 41 72 67 75 6d 65 6e 74 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 | etArguments().....{.........retu |
4ab60 | 72 6e 20 61 72 72 61 79 5f 6d 65 72 67 65 28 24 74 68 69 73 2d 3e 64 65 66 69 6e 69 74 69 6f 6e | rn.array_merge($this->definition |
4ab80 | 2d 3e 67 65 74 41 72 67 75 6d 65 6e 74 44 65 66 61 75 6c 74 73 28 29 2c 20 24 74 68 69 73 2d 3e | ->getArgumentDefaults(),.$this-> |
4aba0 | 61 72 67 75 6d 65 6e 74 73 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 | arguments);.....}....../**...... |
4abc0 | 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c | *.{@inheritdoc}......*/.....publ |
4abe0 | 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 41 72 67 75 6d 65 6e 74 28 24 6e 61 6d 65 29 0a 20 | ic.function.getArgument($name).. |
4ac00 | 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 24 74 68 69 73 2d 3e 64 65 66 69 6e 69 74 | ...{.........if.(!$this->definit |
4ac20 | 69 6f 6e 2d 3e 68 61 73 41 72 67 75 6d 65 6e 74 28 24 6e 61 6d 65 29 29 20 7b 0a 20 20 20 20 20 | ion->hasArgument($name)).{...... |
4ac40 | 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 | .......throw.new.InvalidArgument |
4ac60 | 45 78 63 65 70 74 69 6f 6e 28 73 70 72 69 6e 74 66 28 27 54 68 65 20 22 25 73 22 20 61 72 67 75 | Exception(sprintf('The."%s".argu |
4ac80 | 6d 65 6e 74 20 64 6f 65 73 20 6e 6f 74 20 65 78 69 73 74 2e 27 2c 20 24 6e 61 6d 65 29 29 3b 0a | ment.does.not.exist.',.$name));. |
4aca0 | 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 69 73 73 65 74 28 | ........}..........return.isset( |
4acc0 | 24 74 68 69 73 2d 3e 61 72 67 75 6d 65 6e 74 73 5b 24 6e 61 6d 65 5d 29 20 3f 20 24 74 68 69 73 | $this->arguments[$name]).?.$this |
4ace0 | 2d 3e 61 72 67 75 6d 65 6e 74 73 5b 24 6e 61 6d 65 5d 20 3a 20 24 74 68 69 73 2d 3e 64 65 66 69 | ->arguments[$name].:.$this->defi |
4ad00 | 6e 69 74 69 6f 6e 2d 3e 67 65 74 41 72 67 75 6d 65 6e 74 28 24 6e 61 6d 65 29 2d 3e 67 65 74 44 | nition->getArgument($name)->getD |
4ad20 | 65 66 61 75 6c 74 28 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 | efault();.....}....../**......*. |
4ad40 | 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 | {@inheritdoc}......*/.....public |
4ad60 | 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 41 72 67 75 6d 65 6e 74 28 24 6e 61 6d 65 2c 20 24 76 61 | .function.setArgument($name,.$va |
4ad80 | 6c 75 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 24 74 68 69 73 2d 3e 64 | lue).....{.........if.(!$this->d |
4ada0 | 65 66 69 6e 69 74 69 6f 6e 2d 3e 68 61 73 41 72 67 75 6d 65 6e 74 28 24 6e 61 6d 65 29 29 20 7b | efinition->hasArgument($name)).{ |
4adc0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 61 6c 69 64 41 72 | .............throw.new.InvalidAr |
4ade0 | 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 73 70 72 69 6e 74 66 28 27 54 68 65 20 22 25 73 | gumentException(sprintf('The."%s |
4ae00 | 22 20 61 72 67 75 6d 65 6e 74 20 64 6f 65 73 20 6e 6f 74 20 65 78 69 73 74 2e 27 2c 20 24 6e 61 | ".argument.does.not.exist.',.$na |
4ae20 | 6d 65 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e | me));.........}..........$this-> |
4ae40 | 61 72 67 75 6d 65 6e 74 73 5b 24 6e 61 6d 65 5d 20 3d 20 24 76 61 6c 75 65 3b 0a 20 20 20 20 7d | arguments[$name].=.$value;.....} |
4ae60 | 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 | ....../**......*.{@inheritdoc}.. |
4ae80 | 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 68 61 73 41 72 | ....*/.....public.function.hasAr |
4aea0 | 67 75 6d 65 6e 74 28 24 6e 61 6d 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 | gument($name).....{.........retu |
4aec0 | 72 6e 20 24 74 68 69 73 2d 3e 64 65 66 69 6e 69 74 69 6f 6e 2d 3e 68 61 73 41 72 67 75 6d 65 6e | rn.$this->definition->hasArgumen |
4aee0 | 74 28 24 6e 61 6d 65 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 | t($name);.....}....../**......*. |
4af00 | 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 | {@inheritdoc}......*/.....public |
4af20 | 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 4f 70 74 69 6f 6e 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 | .function.getOptions().....{.... |
4af40 | 20 20 20 20 20 72 65 74 75 72 6e 20 61 72 72 61 79 5f 6d 65 72 67 65 28 24 74 68 69 73 2d 3e 64 | .....return.array_merge($this->d |
4af60 | 65 66 69 6e 69 74 69 6f 6e 2d 3e 67 65 74 4f 70 74 69 6f 6e 44 65 66 61 75 6c 74 73 28 29 2c 20 | efinition->getOptionDefaults(),. |
4af80 | 24 74 68 69 73 2d 3e 6f 70 74 69 6f 6e 73 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a | $this->options);.....}....../**. |
4afa0 | 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 | .....*.{@inheritdoc}......*/.... |
4afc0 | 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 4f 70 74 69 6f 6e 28 24 6e 61 6d 65 | .public.function.getOption($name |
4afe0 | 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 24 74 68 69 73 2d 3e 64 65 66 69 | ).....{.........if.(!$this->defi |
4b000 | 6e 69 74 69 6f 6e 2d 3e 68 61 73 4f 70 74 69 6f 6e 28 24 6e 61 6d 65 29 29 20 7b 0a 20 20 20 20 | nition->hasOption($name)).{..... |
4b020 | 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e | ........throw.new.InvalidArgumen |
4b040 | 74 45 78 63 65 70 74 69 6f 6e 28 73 70 72 69 6e 74 66 28 27 54 68 65 20 22 25 73 22 20 6f 70 74 | tException(sprintf('The."%s".opt |
4b060 | 69 6f 6e 20 64 6f 65 73 20 6e 6f 74 20 65 78 69 73 74 2e 27 2c 20 24 6e 61 6d 65 29 29 3b 0a 20 | ion.does.not.exist.',.$name));.. |
4b080 | 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 69 73 73 65 74 28 24 | .......}..........return.isset($ |
4b0a0 | 74 68 69 73 2d 3e 6f 70 74 69 6f 6e 73 5b 24 6e 61 6d 65 5d 29 20 3f 20 24 74 68 69 73 2d 3e 6f | this->options[$name]).?.$this->o |
4b0c0 | 70 74 69 6f 6e 73 5b 24 6e 61 6d 65 5d 20 3a 20 24 74 68 69 73 2d 3e 64 65 66 69 6e 69 74 69 6f | ptions[$name].:.$this->definitio |
4b0e0 | 6e 2d 3e 67 65 74 4f 70 74 69 6f 6e 28 24 6e 61 6d 65 29 2d 3e 67 65 74 44 65 66 61 75 6c 74 28 | n->getOption($name)->getDefault( |
4b100 | 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 | );.....}....../**......*.{@inher |
4b120 | 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 | itdoc}......*/.....public.functi |
4b140 | 6f 6e 20 73 65 74 4f 70 74 69 6f 6e 28 24 6e 61 6d 65 2c 20 24 76 61 6c 75 65 29 0a 20 20 20 20 | on.setOption($name,.$value)..... |
4b160 | 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 24 74 68 69 73 2d 3e 64 65 66 69 6e 69 74 69 6f 6e | {.........if.(!$this->definition |
4b180 | 2d 3e 68 61 73 4f 70 74 69 6f 6e 28 24 6e 61 6d 65 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | ->hasOption($name)).{........... |
4b1a0 | 20 20 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 | ..throw.new.InvalidArgumentExcep |
4b1c0 | 74 69 6f 6e 28 73 70 72 69 6e 74 66 28 27 54 68 65 20 22 25 73 22 20 6f 70 74 69 6f 6e 20 64 6f | tion(sprintf('The."%s".option.do |
4b1e0 | 65 73 20 6e 6f 74 20 65 78 69 73 74 2e 27 2c 20 24 6e 61 6d 65 29 29 3b 0a 20 20 20 20 20 20 20 | es.not.exist.',.$name));........ |
4b200 | 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6f 70 74 69 6f 6e 73 5b 24 6e 61 6d 65 | .}..........$this->options[$name |
4b220 | 5d 20 3d 20 24 76 61 6c 75 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 | ].=.$value;.....}....../**...... |
4b240 | 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c | *.{@inheritdoc}......*/.....publ |
4b260 | 69 63 20 66 75 6e 63 74 69 6f 6e 20 68 61 73 4f 70 74 69 6f 6e 28 24 6e 61 6d 65 29 0a 20 20 20 | ic.function.hasOption($name).... |
4b280 | 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 64 65 66 69 6e 69 74 | .{.........return.$this->definit |
4b2a0 | 69 6f 6e 2d 3e 68 61 73 4f 70 74 69 6f 6e 28 24 6e 61 6d 65 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 | ion->hasOption($name);.....}.... |
4b2c0 | 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 45 73 63 61 70 65 73 20 61 20 74 6f 6b 65 6e 20 74 68 72 | ../**......*.Escapes.a.token.thr |
4b2e0 | 6f 75 67 68 20 65 73 63 61 70 65 73 68 65 6c 6c 61 72 67 20 69 66 20 69 74 20 63 6f 6e 74 61 69 | ough.escapeshellarg.if.it.contai |
4b300 | 6e 73 20 75 6e 73 61 66 65 20 63 68 61 72 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 | ns.unsafe.chars.......*......*.@ |
4b320 | 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 74 6f 6b 65 6e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 | param.string.$token......*...... |
4b340 | 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 | *.@return.string......*/.....pub |
4b360 | 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 65 73 63 61 70 65 54 6f 6b 65 6e 28 24 74 6f 6b 65 6e 29 | lic.function.escapeToken($token) |
4b380 | 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 70 72 65 67 5f 6d 61 74 63 68 | .....{.........return.preg_match |
4b3a0 | 28 27 7b 5e 5b 5c 77 2d 5d 2b 24 7d 27 2c 20 24 74 6f 6b 65 6e 29 20 3f 20 24 74 6f 6b 65 6e 20 | ('{^[\w-]+$}',.$token).?.$token. |
4b3c0 | 3a 20 65 73 63 61 70 65 73 68 65 6c 6c 61 72 67 28 24 74 6f 6b 65 6e 29 3b 0a 20 20 20 20 7d 0a | :.escapeshellarg($token);.....}. |
4b3e0 | 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 | }.<?php../*..*.This.file.is.part |
4b400 | 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 | .of.the.Symfony.package...*..*.( |
4b420 | 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 | c).Fabien.Potencier.<fabien@symf |
4b440 | 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 | ony.com>..*..*.For.the.full.copy |
4b460 | 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 | right.and.license.information,.p |
4b480 | 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 | lease.view.the.LICENSE..*.file.t |
4b4a0 | 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f | hat.was.distributed.with.this.so |
4b4c0 | 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e | urce.code...*/..namespace.Symfon |
4b4e0 | 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 3b 0a 0a 75 73 65 20 | y\Component\Console\Input;..use. |
4b500 | 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 78 63 65 70 74 | Symfony\Component\Console\Except |
4b520 | 69 6f 6e 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 3b 0a 75 73 | ion\InvalidArgumentException;.us |
4b540 | 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 78 63 65 | e.Symfony\Component\Console\Exce |
4b560 | 70 74 69 6f 6e 5c 52 75 6e 74 69 6d 65 45 78 63 65 70 74 69 6f 6e 3b 0a 0a 2f 2a 2a 0a 20 2a 20 | ption\RuntimeException;../**..*. |
4b580 | 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 20 69 73 20 74 68 65 20 69 6e 74 65 72 66 61 63 65 20 | InputInterface.is.the.interface. |
4b5a0 | 69 6d 70 6c 65 6d 65 6e 74 65 64 20 62 79 20 61 6c 6c 20 69 6e 70 75 74 20 63 6c 61 73 73 65 73 | implemented.by.all.input.classes |
4b5c0 | 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 | ...*..*.@author.Fabien.Potencier |
4b5e0 | 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 2f 0a 69 6e 74 65 72 66 | .<fabien@symfony.com>..*/.interf |
4b600 | 61 63 65 20 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 0a 7b 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 | ace.InputInterface.{...../**.... |
4b620 | 20 20 2a 20 52 65 74 75 72 6e 73 20 74 68 65 20 66 69 72 73 74 20 61 72 67 75 6d 65 6e 74 20 66 | ..*.Returns.the.first.argument.f |
4b640 | 72 6f 6d 20 74 68 65 20 72 61 77 20 70 61 72 61 6d 65 74 65 72 73 20 28 6e 6f 74 20 70 61 72 73 | rom.the.raw.parameters.(not.pars |
4b660 | 65 64 29 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e | ed).......*......*.@return.strin |
4b680 | 67 20 54 68 65 20 76 61 6c 75 65 20 6f 66 20 74 68 65 20 66 69 72 73 74 20 61 72 67 75 6d 65 6e | g.The.value.of.the.first.argumen |
4b6a0 | 74 20 6f 72 20 6e 75 6c 6c 20 6f 74 68 65 72 77 69 73 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 | t.or.null.otherwise......*/..... |
4b6c0 | 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 46 69 72 73 74 41 72 67 75 6d 65 6e 74 | public.function.getFirstArgument |
4b6e0 | 28 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 74 72 75 65 | ();....../**......*.Returns.true |
4b700 | 20 69 66 20 74 68 65 20 72 61 77 20 70 61 72 61 6d 65 74 65 72 73 20 28 6e 6f 74 20 70 61 72 73 | .if.the.raw.parameters.(not.pars |
4b720 | 65 64 29 20 63 6f 6e 74 61 69 6e 20 61 20 76 61 6c 75 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 | ed).contain.a.value.......*..... |
4b740 | 20 2a 20 54 68 69 73 20 6d 65 74 68 6f 64 20 69 73 20 74 6f 20 62 65 20 75 73 65 64 20 74 6f 20 | .*.This.method.is.to.be.used.to. |
4b760 | 69 6e 74 72 6f 73 70 65 63 74 20 74 68 65 20 69 6e 70 75 74 20 70 61 72 61 6d 65 74 65 72 73 0a | introspect.the.input.parameters. |
4b780 | 20 20 20 20 20 2a 20 62 65 66 6f 72 65 20 74 68 65 79 20 68 61 76 65 20 62 65 65 6e 20 76 61 6c | .....*.before.they.have.been.val |
4b7a0 | 69 64 61 74 65 64 2e 20 49 74 20 6d 75 73 74 20 62 65 20 75 73 65 64 20 63 61 72 65 66 75 6c 6c | idated..It.must.be.used.carefull |
4b7c0 | 79 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 7c 61 | y.......*......*.@param.string|a |
4b7e0 | 72 72 61 79 20 24 76 61 6c 75 65 73 20 20 20 20 20 54 68 65 20 76 61 6c 75 65 73 20 74 6f 20 6c | rray.$values.....The.values.to.l |
4b800 | 6f 6f 6b 20 66 6f 72 20 69 6e 20 74 68 65 20 72 61 77 20 70 61 72 61 6d 65 74 65 72 73 20 28 63 | ook.for.in.the.raw.parameters.(c |
4b820 | 61 6e 20 62 65 20 61 6e 20 61 72 72 61 79 29 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 62 6f | an.be.an.array)......*.@param.bo |
4b840 | 6f 6c 20 20 20 20 20 20 20 20 20 24 6f 6e 6c 79 50 61 72 61 6d 73 20 4f 6e 6c 79 20 63 68 65 63 | ol.........$onlyParams.Only.chec |
4b860 | 6b 20 72 65 61 6c 20 70 61 72 61 6d 65 74 65 72 73 2c 20 73 6b 69 70 20 74 68 6f 73 65 20 66 6f | k.real.parameters,.skip.those.fo |
4b880 | 6c 6c 6f 77 69 6e 67 20 61 6e 20 65 6e 64 20 6f 66 20 6f 70 74 69 6f 6e 73 20 28 2d 2d 29 20 73 | llowing.an.end.of.options.(--).s |
4b8a0 | 69 67 6e 61 6c 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 62 6f 6f 6c | ignal......*......*.@return.bool |
4b8c0 | 20 74 72 75 65 20 69 66 20 74 68 65 20 76 61 6c 75 65 20 69 73 20 63 6f 6e 74 61 69 6e 65 64 20 | .true.if.the.value.is.contained. |
4b8e0 | 69 6e 20 74 68 65 20 72 61 77 20 70 61 72 61 6d 65 74 65 72 73 0a 20 20 20 20 20 2a 2f 0a 20 20 | in.the.raw.parameters......*/... |
4b900 | 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 68 61 73 50 61 72 61 6d 65 74 65 72 4f 70 | ..public.function.hasParameterOp |
4b920 | 74 69 6f 6e 28 24 76 61 6c 75 65 73 2c 20 24 6f 6e 6c 79 50 61 72 61 6d 73 20 3d 20 66 61 6c 73 | tion($values,.$onlyParams.=.fals |
4b940 | 65 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 74 68 65 20 | e);....../**......*.Returns.the. |
4b960 | 76 61 6c 75 65 20 6f 66 20 61 20 72 61 77 20 6f 70 74 69 6f 6e 20 28 6e 6f 74 20 70 61 72 73 65 | value.of.a.raw.option.(not.parse |
4b980 | 64 29 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 54 68 69 73 20 6d 65 74 68 6f 64 20 69 73 | d).......*......*.This.method.is |
4b9a0 | 20 74 6f 20 62 65 20 75 73 65 64 20 74 6f 20 69 6e 74 72 6f 73 70 65 63 74 20 74 68 65 20 69 6e | .to.be.used.to.introspect.the.in |
4b9c0 | 70 75 74 20 70 61 72 61 6d 65 74 65 72 73 0a 20 20 20 20 20 2a 20 62 65 66 6f 72 65 20 74 68 65 | put.parameters......*.before.the |
4b9e0 | 79 20 68 61 76 65 20 62 65 65 6e 20 76 61 6c 69 64 61 74 65 64 2e 20 49 74 20 6d 75 73 74 20 62 | y.have.been.validated..It.must.b |
4ba00 | 65 20 75 73 65 64 20 63 61 72 65 66 75 6c 6c 79 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 | e.used.carefully.......*......*. |
4ba20 | 40 70 61 72 61 6d 20 73 74 72 69 6e 67 7c 61 72 72 61 79 20 24 76 61 6c 75 65 73 20 20 20 20 20 | @param.string|array.$values..... |
4ba40 | 54 68 65 20 76 61 6c 75 65 28 73 29 20 74 6f 20 6c 6f 6f 6b 20 66 6f 72 20 69 6e 20 74 68 65 20 | The.value(s).to.look.for.in.the. |
4ba60 | 72 61 77 20 70 61 72 61 6d 65 74 65 72 73 20 28 63 61 6e 20 62 65 20 61 6e 20 61 72 72 61 79 29 | raw.parameters.(can.be.an.array) |
4ba80 | 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 6d 69 78 65 64 20 20 20 20 20 20 20 20 24 64 65 66 | ......*.@param.mixed........$def |
4baa0 | 61 75 6c 74 20 20 20 20 54 68 65 20 64 65 66 61 75 6c 74 20 76 61 6c 75 65 20 74 6f 20 72 65 74 | ault....The.default.value.to.ret |
4bac0 | 75 72 6e 20 69 66 20 6e 6f 20 72 65 73 75 6c 74 20 69 73 20 66 6f 75 6e 64 0a 20 20 20 20 20 2a | urn.if.no.result.is.found......* |
4bae0 | 20 40 70 61 72 61 6d 20 62 6f 6f 6c 20 20 20 20 20 20 20 20 20 24 6f 6e 6c 79 50 61 72 61 6d 73 | .@param.bool.........$onlyParams |
4bb00 | 20 4f 6e 6c 79 20 63 68 65 63 6b 20 72 65 61 6c 20 70 61 72 61 6d 65 74 65 72 73 2c 20 73 6b 69 | .Only.check.real.parameters,.ski |
4bb20 | 70 20 74 68 6f 73 65 20 66 6f 6c 6c 6f 77 69 6e 67 20 61 6e 20 65 6e 64 20 6f 66 20 6f 70 74 69 | p.those.following.an.end.of.opti |
4bb40 | 6f 6e 73 20 28 2d 2d 29 20 73 69 67 6e 61 6c 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 | ons.(--).signal......*......*.@r |
4bb60 | 65 74 75 72 6e 20 6d 69 78 65 64 20 54 68 65 20 6f 70 74 69 6f 6e 20 76 61 6c 75 65 0a 20 20 20 | eturn.mixed.The.option.value.... |
4bb80 | 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 50 61 72 61 | ..*/.....public.function.getPara |
4bba0 | 6d 65 74 65 72 4f 70 74 69 6f 6e 28 24 76 61 6c 75 65 73 2c 20 24 64 65 66 61 75 6c 74 20 3d 20 | meterOption($values,.$default.=. |
4bbc0 | 66 61 6c 73 65 2c 20 24 6f 6e 6c 79 50 61 72 61 6d 73 20 3d 20 66 61 6c 73 65 29 3b 0a 0a 20 20 | false,.$onlyParams.=.false);.... |
4bbe0 | 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 42 69 6e 64 73 20 74 68 65 20 63 75 72 72 65 6e 74 20 49 | ../**......*.Binds.the.current.I |
4bc00 | 6e 70 75 74 20 69 6e 73 74 61 6e 63 65 20 77 69 74 68 20 74 68 65 20 67 69 76 65 6e 20 61 72 67 | nput.instance.with.the.given.arg |
4bc20 | 75 6d 65 6e 74 73 20 61 6e 64 20 6f 70 74 69 6f 6e 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 | uments.and.options.......*...... |
4bc40 | 2a 20 40 70 61 72 61 6d 20 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 20 24 64 65 66 69 6e 69 | *.@param.InputDefinition.$defini |
4bc60 | 74 69 6f 6e 20 41 20 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 20 69 6e 73 74 61 6e 63 65 0a | tion.A.InputDefinition.instance. |
4bc80 | 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 62 69 6e 64 | .....*/.....public.function.bind |
4bca0 | 28 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 20 24 64 65 66 69 6e 69 74 69 6f 6e 29 3b 0a 0a | (InputDefinition.$definition);.. |
4bcc0 | 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 56 61 6c 69 64 61 74 65 73 20 74 68 65 20 69 6e 70 | ..../**......*.Validates.the.inp |
4bce0 | 75 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 52 75 6e 74 69 6d | ut.......*......*.@throws.Runtim |
4bd00 | 65 45 78 63 65 70 74 69 6f 6e 20 57 68 65 6e 20 6e 6f 74 20 65 6e 6f 75 67 68 20 61 72 67 75 6d | eException.When.not.enough.argum |
4bd20 | 65 6e 74 73 20 61 72 65 20 67 69 76 65 6e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 | ents.are.given......*/.....publi |
4bd40 | 63 20 66 75 6e 63 74 69 6f 6e 20 76 61 6c 69 64 61 74 65 28 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a | c.function.validate();....../**. |
4bd60 | 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 61 6c 6c 20 74 68 65 20 67 69 76 65 6e 20 61 72 67 | .....*.Returns.all.the.given.arg |
4bd80 | 75 6d 65 6e 74 73 20 6d 65 72 67 65 64 20 77 69 74 68 20 74 68 65 20 64 65 66 61 75 6c 74 20 76 | uments.merged.with.the.default.v |
4bda0 | 61 6c 75 65 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 61 72 72 | alues.......*......*.@return.arr |
4bdc0 | 61 79 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 | ay......*/.....public.function.g |
4bde0 | 65 74 41 72 67 75 6d 65 6e 74 73 28 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 | etArguments();....../**......*.R |
4be00 | 65 74 75 72 6e 73 20 74 68 65 20 61 72 67 75 6d 65 6e 74 20 76 61 6c 75 65 20 66 6f 72 20 61 20 | eturns.the.argument.value.for.a. |
4be20 | 67 69 76 65 6e 20 61 72 67 75 6d 65 6e 74 20 6e 61 6d 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 | given.argument.name.......*..... |
4be40 | 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6e 61 6d 65 20 54 68 65 20 61 72 67 75 6d | .*.@param.string.$name.The.argum |
4be60 | 65 6e 74 20 6e 61 6d 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 6d | ent.name......*......*.@return.m |
4be80 | 69 78 65 64 20 54 68 65 20 61 72 67 75 6d 65 6e 74 20 76 61 6c 75 65 0a 20 20 20 20 20 2a 0a 20 | ixed.The.argument.value......*.. |
4bea0 | 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 | ....*.@throws.InvalidArgumentExc |
4bec0 | 65 70 74 69 6f 6e 20 57 68 65 6e 20 61 72 67 75 6d 65 6e 74 20 67 69 76 65 6e 20 64 6f 65 73 6e | eption.When.argument.given.doesn |
4bee0 | 27 74 20 65 78 69 73 74 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 | 't.exist......*/.....public.func |
4bf00 | 74 69 6f 6e 20 67 65 74 41 72 67 75 6d 65 6e 74 28 24 6e 61 6d 65 29 3b 0a 0a 20 20 20 20 2f 2a | tion.getArgument($name);....../* |
4bf20 | 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 61 6e 20 61 72 67 75 6d 65 6e 74 20 76 61 6c 75 65 20 | *......*.Sets.an.argument.value. |
4bf40 | 62 79 20 6e 61 6d 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 | by.name.......*......*.@param.st |
4bf60 | 72 69 6e 67 20 24 6e 61 6d 65 20 20 54 68 65 20 61 72 67 75 6d 65 6e 74 20 6e 61 6d 65 0a 20 20 | ring.$name..The.argument.name... |
4bf80 | 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 76 61 6c 75 65 20 54 68 65 20 61 72 | ...*.@param.string.$value.The.ar |
4bfa0 | 67 75 6d 65 6e 74 20 76 61 6c 75 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f | gument.value......*......*.@thro |
4bfc0 | 77 73 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 20 57 68 65 6e | ws.InvalidArgumentException.When |
4bfe0 | 20 61 72 67 75 6d 65 6e 74 20 67 69 76 65 6e 20 64 6f 65 73 6e 27 74 20 65 78 69 73 74 0a 20 20 | .argument.given.doesn't.exist... |
4c000 | 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 41 72 67 | ...*/.....public.function.setArg |
4c020 | 75 6d 65 6e 74 28 24 6e 61 6d 65 2c 20 24 76 61 6c 75 65 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 | ument($name,.$value);....../**.. |
4c040 | 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 74 72 75 65 20 69 66 20 61 6e 20 49 6e 70 75 74 41 72 | ....*.Returns.true.if.an.InputAr |
4c060 | 67 75 6d 65 6e 74 20 6f 62 6a 65 63 74 20 65 78 69 73 74 73 20 62 79 20 6e 61 6d 65 20 6f 72 20 | gument.object.exists.by.name.or. |
4c080 | 70 6f 73 69 74 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 | position.......*......*.@param.s |
4c0a0 | 74 72 69 6e 67 7c 69 6e 74 20 24 6e 61 6d 65 20 54 68 65 20 49 6e 70 75 74 41 72 67 75 6d 65 6e | tring|int.$name.The.InputArgumen |
4c0c0 | 74 20 6e 61 6d 65 20 6f 72 20 70 6f 73 69 74 69 6f 6e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a | t.name.or.position......*......* |
4c0e0 | 20 40 72 65 74 75 72 6e 20 62 6f 6f 6c 20 74 72 75 65 20 69 66 20 74 68 65 20 49 6e 70 75 74 41 | .@return.bool.true.if.the.InputA |
4c100 | 72 67 75 6d 65 6e 74 20 6f 62 6a 65 63 74 20 65 78 69 73 74 73 2c 20 66 61 6c 73 65 20 6f 74 68 | rgument.object.exists,.false.oth |
4c120 | 65 72 77 69 73 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 | erwise......*/.....public.functi |
4c140 | 6f 6e 20 68 61 73 41 72 67 75 6d 65 6e 74 28 24 6e 61 6d 65 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a | on.hasArgument($name);....../**. |
4c160 | 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 61 6c 6c 20 74 68 65 20 67 69 76 65 6e 20 6f 70 74 | .....*.Returns.all.the.given.opt |
4c180 | 69 6f 6e 73 20 6d 65 72 67 65 64 20 77 69 74 68 20 74 68 65 20 64 65 66 61 75 6c 74 20 76 61 6c | ions.merged.with.the.default.val |
4c1a0 | 75 65 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 61 72 72 61 79 | ues.......*......*.@return.array |
4c1c0 | 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 | ......*/.....public.function.get |
4c1e0 | 4f 70 74 69 6f 6e 73 28 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 | Options();....../**......*.Retur |
4c200 | 6e 73 20 74 68 65 20 6f 70 74 69 6f 6e 20 76 61 6c 75 65 20 66 6f 72 20 61 20 67 69 76 65 6e 20 | ns.the.option.value.for.a.given. |
4c220 | 6f 70 74 69 6f 6e 20 6e 61 6d 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 | option.name.......*......*.@para |
4c240 | 6d 20 73 74 72 69 6e 67 20 24 6e 61 6d 65 20 54 68 65 20 6f 70 74 69 6f 6e 20 6e 61 6d 65 0a 20 | m.string.$name.The.option.name.. |
4c260 | 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 6d 69 78 65 64 20 54 68 65 20 6f | ....*......*.@return.mixed.The.o |
4c280 | 70 74 69 6f 6e 20 76 61 6c 75 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 | ption.value......*......*.@throw |
4c2a0 | 73 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 20 57 68 65 6e 20 | s.InvalidArgumentException.When. |
4c2c0 | 6f 70 74 69 6f 6e 20 67 69 76 65 6e 20 64 6f 65 73 6e 27 74 20 65 78 69 73 74 0a 20 20 20 20 20 | option.given.doesn't.exist...... |
4c2e0 | 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 4f 70 74 69 6f 6e | */.....public.function.getOption |
4c300 | 28 24 6e 61 6d 65 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 61 6e | ($name);....../**......*.Sets.an |
4c320 | 20 6f 70 74 69 6f 6e 20 76 61 6c 75 65 20 62 79 20 6e 61 6d 65 2e 0a 20 20 20 20 20 2a 0a 20 20 | .option.value.by.name.......*... |
4c340 | 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 20 20 20 20 20 24 6e 61 6d 65 20 20 54 | ...*.@param.string......$name..T |
4c360 | 68 65 20 6f 70 74 69 6f 6e 20 6e 61 6d 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 | he.option.name......*.@param.str |
4c380 | 69 6e 67 7c 62 6f 6f 6c 20 24 76 61 6c 75 65 20 54 68 65 20 6f 70 74 69 6f 6e 20 76 61 6c 75 65 | ing|bool.$value.The.option.value |
4c3a0 | 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 49 6e 76 61 6c 69 64 41 72 | ......*......*.@throws.InvalidAr |
4c3c0 | 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 20 57 68 65 6e 20 6f 70 74 69 6f 6e 20 67 69 76 65 | gumentException.When.option.give |
4c3e0 | 6e 20 64 6f 65 73 6e 27 74 20 65 78 69 73 74 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c | n.doesn't.exist......*/.....publ |
4c400 | 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 4f 70 74 69 6f 6e 28 24 6e 61 6d 65 2c 20 24 76 61 | ic.function.setOption($name,.$va |
4c420 | 6c 75 65 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 74 72 | lue);....../**......*.Returns.tr |
4c440 | 75 65 20 69 66 20 61 6e 20 49 6e 70 75 74 4f 70 74 69 6f 6e 20 6f 62 6a 65 63 74 20 65 78 69 73 | ue.if.an.InputOption.object.exis |
4c460 | 74 73 20 62 79 20 6e 61 6d 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d | ts.by.name.......*......*.@param |
4c480 | 20 73 74 72 69 6e 67 20 24 6e 61 6d 65 20 54 68 65 20 49 6e 70 75 74 4f 70 74 69 6f 6e 20 6e 61 | .string.$name.The.InputOption.na |
4c4a0 | 6d 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 62 6f 6f 6c 20 74 72 | me......*......*.@return.bool.tr |
4c4c0 | 75 65 20 69 66 20 74 68 65 20 49 6e 70 75 74 4f 70 74 69 6f 6e 20 6f 62 6a 65 63 74 20 65 78 69 | ue.if.the.InputOption.object.exi |
4c4e0 | 73 74 73 2c 20 66 61 6c 73 65 20 6f 74 68 65 72 77 69 73 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 | sts,.false.otherwise......*/.... |
4c500 | 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 68 61 73 4f 70 74 69 6f 6e 28 24 6e 61 6d 65 | .public.function.hasOption($name |
4c520 | 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 49 73 20 74 68 69 73 20 69 6e 70 75 74 | );....../**......*.Is.this.input |
4c540 | 20 6d 65 61 6e 73 20 69 6e 74 65 72 61 63 74 69 76 65 3f 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 | .means.interactive?......*...... |
4c560 | 2a 20 40 72 65 74 75 72 6e 20 62 6f 6f 6c 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 | *.@return.bool......*/.....publi |
4c580 | 63 20 66 75 6e 63 74 69 6f 6e 20 69 73 49 6e 74 65 72 61 63 74 69 76 65 28 29 3b 0a 0a 20 20 20 | c.function.isInteractive();..... |
4c5a0 | 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 74 68 65 20 69 6e 70 75 74 20 69 6e 74 65 72 | ./**......*.Sets.the.input.inter |
4c5c0 | 61 63 74 69 76 69 74 79 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 62 | activity.......*......*.@param.b |
4c5e0 | 6f 6f 6c 20 24 69 6e 74 65 72 61 63 74 69 76 65 20 49 66 20 74 68 65 20 69 6e 70 75 74 20 73 68 | ool.$interactive.If.the.input.sh |
4c600 | 6f 75 6c 64 20 62 65 20 69 6e 74 65 72 61 63 74 69 76 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 | ould.be.interactive......*/..... |
4c620 | 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 49 6e 74 65 72 61 63 74 69 76 65 28 24 | public.function.setInteractive($ |
4c640 | 69 6e 74 65 72 61 63 74 69 76 65 29 3b 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 | interactive);.}.<?php../*..*.Thi |
4c660 | 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 | s.file.is.part.of.the.Symfony.pa |
4c680 | 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 | ckage...*..*.(c).Fabien.Potencie |
4c6a0 | 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 | r.<fabien@symfony.com>..*..*.For |
4c6c0 | 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 | .the.full.copyright.and.license. |
4c6e0 | 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 | information,.please.view.the.LIC |
4c700 | 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 | ENSE..*.file.that.was.distribute |
4c720 | 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 | d.with.this.source.code...*/..na |
4c740 | 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c | mespace.Symfony\Component\Consol |
4c760 | 65 3b 0a 0a 2f 2a 2a 0a 20 2a 20 43 6f 6e 74 61 69 6e 73 20 61 6c 6c 20 65 76 65 6e 74 73 20 64 | e;../**..*.Contains.all.events.d |
4c780 | 69 73 70 61 74 63 68 65 64 20 62 79 20 61 6e 20 41 70 70 6c 69 63 61 74 69 6f 6e 2e 0a 20 2a 0a | ispatched.by.an.Application...*. |
4c7a0 | 20 2a 20 40 61 75 74 68 6f 72 20 46 72 61 6e 63 65 73 63 6f 20 4c 65 76 6f 72 61 74 6f 20 3c 67 | .*.@author.Francesco.Levorato.<g |
4c7c0 | 69 74 40 66 6c 65 76 6f 75 72 2e 6e 65 74 3e 0a 20 2a 2f 0a 66 69 6e 61 6c 20 63 6c 61 73 73 20 | it@flevour.net>..*/.final.class. |
4c7e0 | 43 6f 6e 73 6f 6c 65 45 76 65 6e 74 73 0a 7b 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 54 | ConsoleEvents.{...../**......*.T |
4c800 | 68 65 20 43 4f 4d 4d 41 4e 44 20 65 76 65 6e 74 20 61 6c 6c 6f 77 73 20 79 6f 75 20 74 6f 20 61 | he.COMMAND.event.allows.you.to.a |
4c820 | 74 74 61 63 68 20 6c 69 73 74 65 6e 65 72 73 20 62 65 66 6f 72 65 20 61 6e 79 20 63 6f 6d 6d 61 | ttach.listeners.before.any.comma |
4c840 | 6e 64 20 69 73 0a 20 20 20 20 20 2a 20 65 78 65 63 75 74 65 64 20 62 79 20 74 68 65 20 63 6f 6e | nd.is......*.executed.by.the.con |
4c860 | 73 6f 6c 65 2e 20 49 74 20 61 6c 73 6f 20 61 6c 6c 6f 77 73 20 79 6f 75 20 74 6f 20 6d 6f 64 69 | sole..It.also.allows.you.to.modi |
4c880 | 66 79 20 74 68 65 20 63 6f 6d 6d 61 6e 64 2c 20 69 6e 70 75 74 20 61 6e 64 20 6f 75 74 70 75 74 | fy.the.command,.input.and.output |
4c8a0 | 0a 20 20 20 20 20 2a 20 62 65 66 6f 72 65 20 74 68 65 79 20 61 72 65 20 68 61 6e 64 6c 65 64 20 | ......*.before.they.are.handled. |
4c8c0 | 74 6f 20 74 68 65 20 63 6f 6d 6d 61 6e 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 45 | to.the.command.......*......*.@E |
4c8e0 | 76 65 6e 74 28 22 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c | vent("Symfony\Component\Console\ |
4c900 | 45 76 65 6e 74 5c 43 6f 6e 73 6f 6c 65 43 6f 6d 6d 61 6e 64 45 76 65 6e 74 22 29 0a 20 20 20 20 | Event\ConsoleCommandEvent")..... |
4c920 | 20 2a 0a 20 20 20 20 20 2a 20 40 76 61 72 20 73 74 72 69 6e 67 0a 20 20 20 20 20 2a 2f 0a 20 20 | .*......*.@var.string......*/... |
4c940 | 20 20 63 6f 6e 73 74 20 43 4f 4d 4d 41 4e 44 20 3d 20 27 63 6f 6e 73 6f 6c 65 2e 63 6f 6d 6d 61 | ..const.COMMAND.=.'console.comma |
4c960 | 6e 64 27 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 54 68 65 20 54 45 52 4d 49 4e 41 | nd';....../**......*.The.TERMINA |
4c980 | 54 45 20 65 76 65 6e 74 20 61 6c 6c 6f 77 73 20 79 6f 75 20 74 6f 20 61 74 74 61 63 68 20 6c 69 | TE.event.allows.you.to.attach.li |
4c9a0 | 73 74 65 6e 65 72 73 20 61 66 74 65 72 20 61 20 63 6f 6d 6d 61 6e 64 20 69 73 0a 20 20 20 20 20 | steners.after.a.command.is...... |
4c9c0 | 2a 20 65 78 65 63 75 74 65 64 20 62 79 20 74 68 65 20 63 6f 6e 73 6f 6c 65 2e 0a 20 20 20 20 20 | *.executed.by.the.console....... |
4c9e0 | 2a 0a 20 20 20 20 20 2a 20 40 45 76 65 6e 74 28 22 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 | *......*.@Event("Symfony\Compone |
4ca00 | 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 76 65 6e 74 5c 43 6f 6e 73 6f 6c 65 54 65 72 6d 69 6e 61 74 | nt\Console\Event\ConsoleTerminat |
4ca20 | 65 45 76 65 6e 74 22 29 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 76 61 72 20 73 74 72 69 | eEvent")......*......*.@var.stri |
4ca40 | 6e 67 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 63 6f 6e 73 74 20 54 45 52 4d 49 4e 41 54 45 20 3d | ng......*/.....const.TERMINATE.= |
4ca60 | 20 27 63 6f 6e 73 6f 6c 65 2e 74 65 72 6d 69 6e 61 74 65 27 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 | .'console.terminate';....../**.. |
4ca80 | 20 20 20 20 2a 20 54 68 65 20 45 58 43 45 50 54 49 4f 4e 20 65 76 65 6e 74 20 6f 63 63 75 72 73 | ....*.The.EXCEPTION.event.occurs |
4caa0 | 20 77 68 65 6e 20 61 6e 20 75 6e 63 61 75 67 68 74 20 65 78 63 65 70 74 69 6f 6e 20 61 70 70 65 | .when.an.uncaught.exception.appe |
4cac0 | 61 72 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 54 68 69 73 20 65 76 65 6e 74 20 61 6c | ars.......*......*.This.event.al |
4cae0 | 6c 6f 77 73 20 79 6f 75 20 74 6f 20 64 65 61 6c 20 77 69 74 68 20 74 68 65 20 65 78 63 65 70 74 | lows.you.to.deal.with.the.except |
4cb00 | 69 6f 6e 20 6f 72 0a 20 20 20 20 20 2a 20 74 6f 20 6d 6f 64 69 66 79 20 74 68 65 20 74 68 72 6f | ion.or......*.to.modify.the.thro |
4cb20 | 77 6e 20 65 78 63 65 70 74 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 45 76 65 | wn.exception.......*......*.@Eve |
4cb40 | 6e 74 28 22 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 76 | nt("Symfony\Component\Console\Ev |
4cb60 | 65 6e 74 5c 43 6f 6e 73 6f 6c 65 45 78 63 65 70 74 69 6f 6e 45 76 65 6e 74 22 29 0a 20 20 20 20 | ent\ConsoleExceptionEvent")..... |
4cb80 | 20 2a 0a 20 20 20 20 20 2a 20 40 76 61 72 20 73 74 72 69 6e 67 0a 20 20 20 20 20 2a 2f 0a 20 20 | .*......*.@var.string......*/... |
4cba0 | 20 20 63 6f 6e 73 74 20 45 58 43 45 50 54 49 4f 4e 20 3d 20 27 63 6f 6e 73 6f 6c 65 2e 65 78 63 | ..const.EXCEPTION.=.'console.exc |
4cbc0 | 65 70 74 69 6f 6e 27 3b 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c | eption';.}.<?php../*..*.This.fil |
4cbe0 | 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 | e.is.part.of.the.Symfony.package |
4cc00 | 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 | ...*..*.(c).Fabien.Potencier.<fa |
4cc20 | 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 | bien@symfony.com>..*..*.For.the. |
4cc40 | 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 | full.copyright.and.license.infor |
4cc60 | 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a | mation,.please.view.the.LICENSE. |
4cc80 | 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 | .*.file.that.was.distributed.wit |
4cca0 | 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 | h.this.source.code...*/..namespa |
4ccc0 | 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 3b 0a 0a 75 | ce.Symfony\Component\Console;..u |
4cce0 | 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 78 63 | se.Symfony\Component\Console\Exc |
4cd00 | 65 70 74 69 6f 6e 5c 45 78 63 65 70 74 69 6f 6e 49 6e 74 65 72 66 61 63 65 3b 0a 75 73 65 20 53 | eption\ExceptionInterface;.use.S |
4cd20 | 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 48 65 6c 70 65 72 5c | ymfony\Component\Console\Helper\ |
4cd40 | 44 65 62 75 67 46 6f 72 6d 61 74 74 65 72 48 65 6c 70 65 72 3b 0a 75 73 65 20 53 79 6d 66 6f 6e | DebugFormatterHelper;.use.Symfon |
4cd60 | 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 48 65 6c 70 65 72 5c 50 72 6f 63 65 | y\Component\Console\Helper\Proce |
4cd80 | 73 73 48 65 6c 70 65 72 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c | ssHelper;.use.Symfony\Component\ |
4cda0 | 43 6f 6e 73 6f 6c 65 5c 48 65 6c 70 65 72 5c 51 75 65 73 74 69 6f 6e 48 65 6c 70 65 72 3b 0a 75 | Console\Helper\QuestionHelper;.u |
4cdc0 | 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 | se.Symfony\Component\Console\Inp |
4cde0 | 75 74 5c 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 | ut\InputInterface;.use.Symfony\C |
4ce00 | 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 5c 41 72 67 76 49 6e 70 75 74 | omponent\Console\Input\ArgvInput |
4ce20 | 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c | ;.use.Symfony\Component\Console\ |
4ce40 | 49 6e 70 75 74 5c 41 72 72 61 79 49 6e 70 75 74 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f | Input\ArrayInput;.use.Symfony\Co |
4ce60 | 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 5c 49 6e 70 75 74 44 65 66 69 6e | mponent\Console\Input\InputDefin |
4ce80 | 69 74 69 6f 6e 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e | ition;.use.Symfony\Component\Con |
4cea0 | 73 6f 6c 65 5c 49 6e 70 75 74 5c 49 6e 70 75 74 4f 70 74 69 6f 6e 3b 0a 75 73 65 20 53 79 6d 66 | sole\Input\InputOption;.use.Symf |
4cec0 | 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 5c 49 6e 70 75 | ony\Component\Console\Input\Inpu |
4cee0 | 74 41 72 67 75 6d 65 6e 74 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 | tArgument;.use.Symfony\Component |
4cf00 | 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 5c 49 6e 70 75 74 41 77 61 72 65 49 6e 74 65 72 66 61 | \Console\Input\InputAwareInterfa |
4cf20 | 63 65 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c | ce;.use.Symfony\Component\Consol |
4cf40 | 65 5c 4f 75 74 70 75 74 5c 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 3b 0a 75 73 65 20 53 79 | e\Output\OutputInterface;.use.Sy |
4cf60 | 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 4f 75 74 70 75 74 5c 43 | mfony\Component\Console\Output\C |
4cf80 | 6f 6e 73 6f 6c 65 4f 75 74 70 75 74 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e | onsoleOutput;.use.Symfony\Compon |
4cfa0 | 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 4f 75 74 70 75 74 5c 43 6f 6e 73 6f 6c 65 4f 75 74 70 75 74 | ent\Console\Output\ConsoleOutput |
4cfc0 | 49 6e 74 65 72 66 61 63 65 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 | Interface;.use.Symfony\Component |
4cfe0 | 5c 43 6f 6e 73 6f 6c 65 5c 43 6f 6d 6d 61 6e 64 5c 43 6f 6d 6d 61 6e 64 3b 0a 75 73 65 20 53 79 | \Console\Command\Command;.use.Sy |
4d000 | 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 43 6f 6d 6d 61 6e 64 5c | mfony\Component\Console\Command\ |
4d020 | 48 65 6c 70 43 6f 6d 6d 61 6e 64 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 | HelpCommand;.use.Symfony\Compone |
4d040 | 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 43 6f 6d 6d 61 6e 64 5c 4c 69 73 74 43 6f 6d 6d 61 6e 64 3b 0a | nt\Console\Command\ListCommand;. |
4d060 | 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 48 65 | use.Symfony\Component\Console\He |
4d080 | 6c 70 65 72 5c 48 65 6c 70 65 72 53 65 74 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 | lper\HelperSet;.use.Symfony\Comp |
4d0a0 | 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 48 65 6c 70 65 72 5c 46 6f 72 6d 61 74 74 65 72 48 65 | onent\Console\Helper\FormatterHe |
4d0c0 | 6c 70 65 72 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 | lper;.use.Symfony\Component\Cons |
4d0e0 | 6f 6c 65 5c 45 76 65 6e 74 5c 43 6f 6e 73 6f 6c 65 43 6f 6d 6d 61 6e 64 45 76 65 6e 74 3b 0a 75 | ole\Event\ConsoleCommandEvent;.u |
4d100 | 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 76 65 | se.Symfony\Component\Console\Eve |
4d120 | 6e 74 5c 43 6f 6e 73 6f 6c 65 45 78 63 65 70 74 69 6f 6e 45 76 65 6e 74 3b 0a 75 73 65 20 53 79 | nt\ConsoleExceptionEvent;.use.Sy |
4d140 | 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 76 65 6e 74 5c 43 6f | mfony\Component\Console\Event\Co |
4d160 | 6e 73 6f 6c 65 54 65 72 6d 69 6e 61 74 65 45 76 65 6e 74 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 | nsoleTerminateEvent;.use.Symfony |
4d180 | 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 78 63 65 70 74 69 6f 6e 5c 43 6f 6d | \Component\Console\Exception\Com |
4d1a0 | 6d 61 6e 64 4e 6f 74 46 6f 75 6e 64 45 78 63 65 70 74 69 6f 6e 3b 0a 75 73 65 20 53 79 6d 66 6f | mandNotFoundException;.use.Symfo |
4d1c0 | 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 78 63 65 70 74 69 6f 6e 5c 4c | ny\Component\Console\Exception\L |
4d1e0 | 6f 67 69 63 45 78 63 65 70 74 69 6f 6e 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f | ogicException;.use.Symfony\Compo |
4d200 | 6e 65 6e 74 5c 44 65 62 75 67 5c 45 78 63 65 70 74 69 6f 6e 5c 46 61 74 61 6c 54 68 72 6f 77 61 | nent\Debug\Exception\FatalThrowa |
4d220 | 62 6c 65 45 72 72 6f 72 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c | bleError;.use.Symfony\Component\ |
4d240 | 45 76 65 6e 74 44 69 73 70 61 74 63 68 65 72 5c 45 76 65 6e 74 44 69 73 70 61 74 63 68 65 72 49 | EventDispatcher\EventDispatcherI |
4d260 | 6e 74 65 72 66 61 63 65 3b 0a 0a 2f 2a 2a 0a 20 2a 20 41 6e 20 41 70 70 6c 69 63 61 74 69 6f 6e | nterface;../**..*.An.Application |
4d280 | 20 69 73 20 74 68 65 20 63 6f 6e 74 61 69 6e 65 72 20 66 6f 72 20 61 20 63 6f 6c 6c 65 63 74 69 | .is.the.container.for.a.collecti |
4d2a0 | 6f 6e 20 6f 66 20 63 6f 6d 6d 61 6e 64 73 2e 0a 20 2a 0a 20 2a 20 49 74 20 69 73 20 74 68 65 20 | on.of.commands...*..*.It.is.the. |
4d2c0 | 6d 61 69 6e 20 65 6e 74 72 79 20 70 6f 69 6e 74 20 6f 66 20 61 20 43 6f 6e 73 6f 6c 65 20 61 70 | main.entry.point.of.a.Console.ap |
4d2e0 | 70 6c 69 63 61 74 69 6f 6e 2e 0a 20 2a 0a 20 2a 20 54 68 69 73 20 63 6c 61 73 73 20 69 73 20 6f | plication...*..*.This.class.is.o |
4d300 | 70 74 69 6d 69 7a 65 64 20 66 6f 72 20 61 20 73 74 61 6e 64 61 72 64 20 43 4c 49 20 65 6e 76 69 | ptimized.for.a.standard.CLI.envi |
4d320 | 72 6f 6e 6d 65 6e 74 2e 0a 20 2a 0a 20 2a 20 55 73 61 67 65 3a 0a 20 2a 0a 20 2a 20 20 20 20 20 | ronment...*..*.Usage:..*..*..... |
4d340 | 24 61 70 70 20 3d 20 6e 65 77 20 41 70 70 6c 69 63 61 74 69 6f 6e 28 27 6d 79 61 70 70 27 2c 20 | $app.=.new.Application('myapp',. |
4d360 | 27 31 2e 30 20 28 73 74 61 62 6c 65 29 27 29 3b 0a 20 2a 20 20 20 20 20 24 61 70 70 2d 3e 61 64 | '1.0.(stable)');..*.....$app->ad |
4d380 | 64 28 6e 65 77 20 53 69 6d 70 6c 65 43 6f 6d 6d 61 6e 64 28 29 29 3b 0a 20 2a 20 20 20 20 20 24 | d(new.SimpleCommand());..*.....$ |
4d3a0 | 61 70 70 2d 3e 72 75 6e 28 29 3b 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 46 61 62 69 65 6e | app->run();..*..*.@author.Fabien |
4d3c0 | 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a | .Potencier.<fabien@symfony.com>. |
4d3e0 | 20 2a 2f 0a 63 6c 61 73 73 20 41 70 70 6c 69 63 61 74 69 6f 6e 0a 7b 0a 20 20 20 20 70 72 69 76 | .*/.class.Application.{.....priv |
4d400 | 61 74 65 20 24 63 6f 6d 6d 61 6e 64 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 70 72 69 | ate.$commands.=.array();.....pri |
4d420 | 76 61 74 65 20 24 77 61 6e 74 48 65 6c 70 73 20 3d 20 66 61 6c 73 65 3b 0a 20 20 20 20 70 72 69 | vate.$wantHelps.=.false;.....pri |
4d440 | 76 61 74 65 20 24 72 75 6e 6e 69 6e 67 43 6f 6d 6d 61 6e 64 3b 0a 20 20 20 20 70 72 69 76 61 74 | vate.$runningCommand;.....privat |
4d460 | 65 20 24 6e 61 6d 65 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 76 65 72 73 69 6f 6e 3b 0a 20 | e.$name;.....private.$version;.. |
4d480 | 20 20 20 70 72 69 76 61 74 65 20 24 63 61 74 63 68 45 78 63 65 70 74 69 6f 6e 73 20 3d 20 74 72 | ...private.$catchExceptions.=.tr |
4d4a0 | 75 65 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 61 75 74 6f 45 78 69 74 20 3d 20 74 72 75 65 | ue;.....private.$autoExit.=.true |
4d4c0 | 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 64 65 66 69 6e 69 74 69 6f 6e 3b 0a 20 20 20 20 70 | ;.....private.$definition;.....p |
4d4e0 | 72 69 76 61 74 65 20 24 68 65 6c 70 65 72 53 65 74 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 | rivate.$helperSet;.....private.$ |
4d500 | 64 69 73 70 61 74 63 68 65 72 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 74 65 72 6d 69 6e 61 | dispatcher;.....private.$termina |
4d520 | 6c 44 69 6d 65 6e 73 69 6f 6e 73 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 64 65 66 61 75 6c | lDimensions;.....private.$defaul |
4d540 | 74 43 6f 6d 6d 61 6e 64 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 43 6f 6e 73 74 72 | tCommand;....../**......*.Constr |
4d560 | 75 63 74 6f 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 | uctor.......*......*.@param.stri |
4d580 | 6e 67 20 24 6e 61 6d 65 20 20 20 20 54 68 65 20 6e 61 6d 65 20 6f 66 20 74 68 65 20 61 70 70 6c | ng.$name....The.name.of.the.appl |
4d5a0 | 69 63 61 74 69 6f 6e 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 76 65 | ication......*.@param.string.$ve |
4d5c0 | 72 73 69 6f 6e 20 54 68 65 20 76 65 72 73 69 6f 6e 20 6f 66 20 74 68 65 20 61 70 70 6c 69 63 61 | rsion.The.version.of.the.applica |
4d5e0 | 74 69 6f 6e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e | tion......*/.....public.function |
4d600 | 20 5f 5f 63 6f 6e 73 74 72 75 63 74 28 24 6e 61 6d 65 20 3d 20 27 55 4e 4b 4e 4f 57 4e 27 2c 20 | .__construct($name.=.'UNKNOWN',. |
4d620 | 24 76 65 72 73 69 6f 6e 20 3d 20 27 55 4e 4b 4e 4f 57 4e 27 29 0a 20 20 20 20 7b 0a 20 20 20 20 | $version.=.'UNKNOWN').....{..... |
4d640 | 20 20 20 20 24 74 68 69 73 2d 3e 6e 61 6d 65 20 3d 20 24 6e 61 6d 65 3b 0a 20 20 20 20 20 20 20 | ....$this->name.=.$name;........ |
4d660 | 20 24 74 68 69 73 2d 3e 76 65 72 73 69 6f 6e 20 3d 20 24 76 65 72 73 69 6f 6e 3b 0a 20 20 20 20 | .$this->version.=.$version;..... |
4d680 | 20 20 20 20 24 74 68 69 73 2d 3e 64 65 66 61 75 6c 74 43 6f 6d 6d 61 6e 64 20 3d 20 27 6c 69 73 | ....$this->defaultCommand.=.'lis |
4d6a0 | 74 27 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 68 65 6c 70 65 72 53 65 74 20 3d 20 24 | t';.........$this->helperSet.=.$ |
4d6c0 | 74 68 69 73 2d 3e 67 65 74 44 65 66 61 75 6c 74 48 65 6c 70 65 72 53 65 74 28 29 3b 0a 20 20 20 | this->getDefaultHelperSet();.... |
4d6e0 | 20 20 20 20 20 24 74 68 69 73 2d 3e 64 65 66 69 6e 69 74 69 6f 6e 20 3d 20 24 74 68 69 73 2d 3e | .....$this->definition.=.$this-> |
4d700 | 67 65 74 44 65 66 61 75 6c 74 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 28 29 3b 0a 0a 20 20 | getDefaultInputDefinition();.... |
4d720 | 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 74 68 69 73 2d 3e 67 65 74 44 65 66 61 75 6c 74 | ......foreach.($this->getDefault |
4d740 | 43 6f 6d 6d 61 6e 64 73 28 29 20 61 73 20 24 63 6f 6d 6d 61 6e 64 29 20 7b 0a 20 20 20 20 20 20 | Commands().as.$command).{....... |
4d760 | 20 20 20 20 20 20 24 74 68 69 73 2d 3e 61 64 64 28 24 63 6f 6d 6d 61 6e 64 29 3b 0a 20 20 20 20 | ......$this->add($command);..... |
4d780 | 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e | ....}.....}......public.function |
4d7a0 | 20 73 65 74 44 69 73 70 61 74 63 68 65 72 28 45 76 65 6e 74 44 69 73 70 61 74 63 68 65 72 49 6e | .setDispatcher(EventDispatcherIn |
4d7c0 | 74 65 72 66 61 63 65 20 24 64 69 73 70 61 74 63 68 65 72 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 | terface.$dispatcher).....{...... |
4d7e0 | 20 20 20 24 74 68 69 73 2d 3e 64 69 73 70 61 74 63 68 65 72 20 3d 20 24 64 69 73 70 61 74 63 68 | ...$this->dispatcher.=.$dispatch |
4d800 | 65 72 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 75 6e 73 20 74 | er;.....}....../**......*.Runs.t |
4d820 | 68 65 20 63 75 72 72 65 6e 74 20 61 70 70 6c 69 63 61 74 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 | he.current.application.......*.. |
4d840 | 20 20 20 20 2a 20 40 70 61 72 61 6d 20 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 20 20 24 69 6e | ....*.@param.InputInterface..$in |
4d860 | 70 75 74 20 20 41 6e 20 49 6e 70 75 74 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 20 40 70 | put..An.Input.instance......*.@p |
4d880 | 61 72 61 6d 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 20 41 6e 20 | aram.OutputInterface.$output.An. |
4d8a0 | 4f 75 74 70 75 74 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 | Output.instance......*......*.@r |
4d8c0 | 65 74 75 72 6e 20 69 6e 74 20 30 20 69 66 20 65 76 65 72 79 74 68 69 6e 67 20 77 65 6e 74 20 66 | eturn.int.0.if.everything.went.f |
4d8e0 | 69 6e 65 2c 20 6f 72 20 61 6e 20 65 72 72 6f 72 20 63 6f 64 65 0a 20 20 20 20 20 2a 0a 20 20 20 | ine,.or.an.error.code......*.... |
4d900 | 20 20 2a 20 40 74 68 72 6f 77 73 20 5c 45 78 63 65 70 74 69 6f 6e 20 57 68 65 6e 20 64 6f 52 75 | ..*.@throws.\Exception.When.doRu |
4d920 | 6e 20 72 65 74 75 72 6e 73 20 45 78 63 65 70 74 69 6f 6e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 | n.returns.Exception......*/..... |
4d940 | 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 72 75 6e 28 49 6e 70 75 74 49 6e 74 65 72 66 61 | public.function.run(InputInterfa |
4d960 | 63 65 20 24 69 6e 70 75 74 20 3d 20 6e 75 6c 6c 2c 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 | ce.$input.=.null,.OutputInterfac |
4d980 | 65 20 24 6f 75 74 70 75 74 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | e.$output.=.null).....{......... |
4d9a0 | 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 69 6e 70 75 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | if.(null.===.$input).{.......... |
4d9c0 | 20 20 20 24 69 6e 70 75 74 20 3d 20 6e 65 77 20 41 72 67 76 49 6e 70 75 74 28 29 3b 0a 20 20 20 | ...$input.=.new.ArgvInput();.... |
4d9e0 | 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 6f 75 | .....}..........if.(null.===.$ou |
4da00 | 74 70 75 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 75 74 70 75 74 20 3d 20 6e 65 | tput).{.............$output.=.ne |
4da20 | 77 20 43 6f 6e 73 6f 6c 65 4f 75 74 70 75 74 28 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 | w.ConsoleOutput();.........}.... |
4da40 | 20 20 20 20 20 20 24 74 68 69 73 2d 3e 63 6f 6e 66 69 67 75 72 65 49 4f 28 24 69 6e 70 75 74 2c | ......$this->configureIO($input, |
4da60 | 20 24 6f 75 74 70 75 74 29 3b 0a 0a 20 20 20 20 20 20 20 20 74 72 79 20 7b 0a 20 20 20 20 20 20 | .$output);..........try.{....... |
4da80 | 20 20 20 20 20 20 24 65 78 69 74 43 6f 64 65 20 3d 20 24 74 68 69 73 2d 3e 64 6f 52 75 6e 28 24 | ......$exitCode.=.$this->doRun($ |
4daa0 | 69 6e 70 75 74 2c 20 24 6f 75 74 70 75 74 29 3b 0a 20 20 20 20 20 20 20 20 7d 20 63 61 74 63 68 | input,.$output);.........}.catch |
4dac0 | 20 28 5c 45 78 63 65 70 74 69 6f 6e 20 24 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 | .(\Exception.$e).{.............i |
4dae0 | 66 20 28 21 24 74 68 69 73 2d 3e 63 61 74 63 68 45 78 63 65 70 74 69 6f 6e 73 29 20 7b 0a 20 20 | f.(!$this->catchExceptions).{... |
4db00 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 24 65 3b 0a 20 20 20 20 20 20 20 20 | ..............throw.$e;......... |
4db20 | 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 6f 75 74 70 75 74 20 69 | ....}..............if.($output.i |
4db40 | 6e 73 74 61 6e 63 65 6f 66 20 43 6f 6e 73 6f 6c 65 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 | nstanceof.ConsoleOutputInterface |
4db60 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 72 65 6e 64 65 | ).{.................$this->rende |
4db80 | 72 45 78 63 65 70 74 69 6f 6e 28 24 65 2c 20 24 6f 75 74 70 75 74 2d 3e 67 65 74 45 72 72 6f 72 | rException($e,.$output->getError |
4dba0 | 4f 75 74 70 75 74 28 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a | Output());.............}.else.{. |
4dbc0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 72 65 6e 64 65 72 45 78 63 | ................$this->renderExc |
4dbe0 | 65 70 74 69 6f 6e 28 24 65 2c 20 24 6f 75 74 70 75 74 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 | eption($e,.$output);............ |
4dc00 | 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 65 78 69 74 43 6f 64 65 20 3d 20 24 65 2d 3e | .}..............$exitCode.=.$e-> |
4dc20 | 67 65 74 43 6f 64 65 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 69 73 5f 6e 75 | getCode();.............if.(is_nu |
4dc40 | 6d 65 72 69 63 28 24 65 78 69 74 43 6f 64 65 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | meric($exitCode)).{............. |
4dc60 | 20 20 20 20 24 65 78 69 74 43 6f 64 65 20 3d 20 28 69 6e 74 29 20 24 65 78 69 74 43 6f 64 65 3b | ....$exitCode.=.(int).$exitCode; |
4dc80 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 30 20 3d 3d 3d 20 24 65 78 69 74 | .................if.(0.===.$exit |
4dca0 | 43 6f 64 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 65 78 69 | Code).{.....................$exi |
4dcc0 | 74 43 6f 64 65 20 3d 20 31 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 | tCode.=.1;.................}.... |
4dce0 | 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | .........}.else.{............... |
4dd00 | 20 20 24 65 78 69 74 43 6f 64 65 20 3d 20 31 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 | ..$exitCode.=.1;.............}.. |
4dd20 | 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 74 68 69 73 2d 3e 61 75 74 | .......}..........if.($this->aut |
4dd40 | 6f 45 78 69 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 65 78 69 74 43 6f | oExit).{.............if.($exitCo |
4dd60 | 64 65 20 3e 20 32 35 35 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 65 78 69 | de.>.255).{.................$exi |
4dd80 | 74 43 6f 64 65 20 3d 20 32 35 35 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 | tCode.=.255;.............}...... |
4dda0 | 20 20 20 20 20 20 20 20 65 78 69 74 28 24 65 78 69 74 43 6f 64 65 29 3b 0a 20 20 20 20 20 20 20 | ........exit($exitCode);........ |
4ddc0 | 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 65 78 69 74 43 6f 64 65 3b 0a 20 20 | .}..........return.$exitCode;... |
4dde0 | 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 75 6e 73 20 74 68 65 20 63 75 72 | ..}....../**......*.Runs.the.cur |
4de00 | 72 65 6e 74 20 61 70 70 6c 69 63 61 74 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 | rent.application.......*......*. |
4de20 | 40 70 61 72 61 6d 20 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 20 20 24 69 6e 70 75 74 20 20 41 | @param.InputInterface..$input..A |
4de40 | 6e 20 49 6e 70 75 74 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 4f | n.Input.instance......*.@param.O |
4de60 | 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 20 41 6e 20 4f 75 74 70 75 74 | utputInterface.$output.An.Output |
4de80 | 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 | .instance......*......*.@return. |
4dea0 | 69 6e 74 20 30 20 69 66 20 65 76 65 72 79 74 68 69 6e 67 20 77 65 6e 74 20 66 69 6e 65 2c 20 6f | int.0.if.everything.went.fine,.o |
4dec0 | 72 20 61 6e 20 65 72 72 6f 72 20 63 6f 64 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c | r.an.error.code......*/.....publ |
4dee0 | 69 63 20 66 75 6e 63 74 69 6f 6e 20 64 6f 52 75 6e 28 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 | ic.function.doRun(InputInterface |
4df00 | 20 24 69 6e 70 75 74 2c 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 | .$input,.OutputInterface.$output |
4df20 | 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 74 72 75 65 20 3d 3d 3d 20 24 69 6e | ).....{.........if.(true.===.$in |
4df40 | 70 75 74 2d 3e 68 61 73 50 61 72 61 6d 65 74 65 72 4f 70 74 69 6f 6e 28 61 72 72 61 79 28 27 2d | put->hasParameterOption(array('- |
4df60 | 2d 76 65 72 73 69 6f 6e 27 2c 20 27 2d 56 27 29 2c 20 74 72 75 65 29 29 20 7b 0a 20 20 20 20 20 | -version',.'-V'),.true)).{...... |
4df80 | 20 20 20 20 20 20 20 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 24 74 68 69 73 2d 3e 67 | .......$output->writeln($this->g |
4dfa0 | 65 74 4c 6f 6e 67 56 65 72 73 69 6f 6e 28 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 | etLongVersion());..............r |
4dfc0 | 65 74 75 72 6e 20 30 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 6e 61 6d | eturn.0;.........}..........$nam |
4dfe0 | 65 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 43 6f 6d 6d 61 6e 64 4e 61 6d 65 28 24 69 6e 70 75 74 | e.=.$this->getCommandName($input |
4e000 | 29 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 74 72 75 65 20 3d 3d 3d 20 24 69 6e 70 75 74 2d 3e | );.........if.(true.===.$input-> |
4e020 | 68 61 73 50 61 72 61 6d 65 74 65 72 4f 70 74 69 6f 6e 28 61 72 72 61 79 28 27 2d 2d 68 65 6c 70 | hasParameterOption(array('--help |
4e040 | 27 2c 20 27 2d 68 27 29 2c 20 74 72 75 65 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 | ',.'-h'),.true)).{.............i |
4e060 | 66 20 28 21 24 6e 61 6d 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6e 61 | f.(!$name).{.................$na |
4e080 | 6d 65 20 3d 20 27 68 65 6c 70 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 69 6e | me.=.'help';.................$in |
4e0a0 | 70 75 74 20 3d 20 6e 65 77 20 41 72 72 61 79 49 6e 70 75 74 28 61 72 72 61 79 28 27 63 6f 6d 6d | put.=.new.ArrayInput(array('comm |
4e0c0 | 61 6e 64 27 20 3d 3e 20 27 68 65 6c 70 27 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 | and'.=>.'help'));.............}. |
4e0e0 | 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 61 | else.{.................$this->wa |
4e100 | 6e 74 48 65 6c 70 73 20 3d 20 74 72 75 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 | ntHelps.=.true;.............}... |
4e120 | 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 24 6e 61 6d 65 29 20 7b 0a 20 | ......}..........if.(!$name).{.. |
4e140 | 20 20 20 20 20 20 20 20 20 20 20 24 6e 61 6d 65 20 3d 20 24 74 68 69 73 2d 3e 64 65 66 61 75 6c | ...........$name.=.$this->defaul |
4e160 | 74 43 6f 6d 6d 61 6e 64 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 69 6e 70 75 74 20 3d 20 6e | tCommand;.............$input.=.n |
4e180 | 65 77 20 41 72 72 61 79 49 6e 70 75 74 28 61 72 72 61 79 28 27 63 6f 6d 6d 61 6e 64 27 20 3d 3e | ew.ArrayInput(array('command'.=> |
4e1a0 | 20 24 74 68 69 73 2d 3e 64 65 66 61 75 6c 74 43 6f 6d 6d 61 6e 64 29 29 3b 0a 20 20 20 20 20 20 | .$this->defaultCommand));....... |
4e1c0 | 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 2f 2f 20 74 68 65 20 63 6f 6d 6d 61 6e 64 20 6e 61 6d 65 | ..}..........//.the.command.name |
4e1e0 | 20 4d 55 53 54 20 62 65 20 74 68 65 20 66 69 72 73 74 20 65 6c 65 6d 65 6e 74 20 6f 66 20 74 68 | .MUST.be.the.first.element.of.th |
4e200 | 65 20 69 6e 70 75 74 0a 20 20 20 20 20 20 20 20 24 63 6f 6d 6d 61 6e 64 20 3d 20 24 74 68 69 73 | e.input.........$command.=.$this |
4e220 | 2d 3e 66 69 6e 64 28 24 6e 61 6d 65 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 72 | ->find($name);..........$this->r |
4e240 | 75 6e 6e 69 6e 67 43 6f 6d 6d 61 6e 64 20 3d 20 24 63 6f 6d 6d 61 6e 64 3b 0a 20 20 20 20 20 20 | unningCommand.=.$command;....... |
4e260 | 20 20 24 65 78 69 74 43 6f 64 65 20 3d 20 24 74 68 69 73 2d 3e 64 6f 52 75 6e 43 6f 6d 6d 61 6e | ..$exitCode.=.$this->doRunComman |
4e280 | 64 28 24 63 6f 6d 6d 61 6e 64 2c 20 24 69 6e 70 75 74 2c 20 24 6f 75 74 70 75 74 29 3b 0a 20 20 | d($command,.$input,.$output);... |
4e2a0 | 20 20 20 20 20 20 24 74 68 69 73 2d 3e 72 75 6e 6e 69 6e 67 43 6f 6d 6d 61 6e 64 20 3d 20 6e 75 | ......$this->runningCommand.=.nu |
4e2c0 | 6c 6c 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 65 78 69 74 43 6f 64 65 3b 0a 20 | ll;..........return.$exitCode;.. |
4e2e0 | 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 20 61 20 68 65 6c 70 65 | ...}....../**......*.Set.a.helpe |
4e300 | 72 20 73 65 74 20 74 6f 20 62 65 20 75 73 65 64 20 77 69 74 68 20 74 68 65 20 63 6f 6d 6d 61 6e | r.set.to.be.used.with.the.comman |
4e320 | 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 48 65 6c 70 65 72 53 65 | d.......*......*.@param.HelperSe |
4e340 | 74 20 24 68 65 6c 70 65 72 53 65 74 20 54 68 65 20 68 65 6c 70 65 72 20 73 65 74 0a 20 20 20 20 | t.$helperSet.The.helper.set..... |
4e360 | 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 48 65 6c 70 65 | .*/.....public.function.setHelpe |
4e380 | 72 53 65 74 28 48 65 6c 70 65 72 53 65 74 20 24 68 65 6c 70 65 72 53 65 74 29 0a 20 20 20 20 7b | rSet(HelperSet.$helperSet).....{ |
4e3a0 | 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 68 65 6c 70 65 72 53 65 74 20 3d 20 24 68 65 6c | .........$this->helperSet.=.$hel |
4e3c0 | 70 65 72 53 65 74 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 | perSet;.....}....../**......*.Ge |
4e3e0 | 74 20 74 68 65 20 68 65 6c 70 65 72 20 73 65 74 20 61 73 73 6f 63 69 61 74 65 64 20 77 69 74 68 | t.the.helper.set.associated.with |
4e400 | 20 74 68 65 20 63 6f 6d 6d 61 6e 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 | .the.command.......*......*.@ret |
4e420 | 75 72 6e 20 48 65 6c 70 65 72 53 65 74 20 54 68 65 20 48 65 6c 70 65 72 53 65 74 20 69 6e 73 74 | urn.HelperSet.The.HelperSet.inst |
4e440 | 61 6e 63 65 20 61 73 73 6f 63 69 61 74 65 64 20 77 69 74 68 20 74 68 69 73 20 63 6f 6d 6d 61 6e | ance.associated.with.this.comman |
4e460 | 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 | d......*/.....public.function.ge |
4e480 | 74 48 65 6c 70 65 72 53 65 74 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 | tHelperSet().....{.........retur |
4e4a0 | 6e 20 24 74 68 69 73 2d 3e 68 65 6c 70 65 72 53 65 74 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f | n.$this->helperSet;.....}....../ |
4e4c0 | 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 20 61 6e 20 69 6e 70 75 74 20 64 65 66 69 6e 69 74 69 6f | **......*.Set.an.input.definitio |
4e4e0 | 6e 20 74 6f 20 62 65 20 75 73 65 64 20 77 69 74 68 20 74 68 69 73 20 61 70 70 6c 69 63 61 74 69 | n.to.be.used.with.this.applicati |
4e500 | 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 49 6e 70 75 74 44 65 | on.......*......*.@param.InputDe |
4e520 | 66 69 6e 69 74 69 6f 6e 20 24 64 65 66 69 6e 69 74 69 6f 6e 20 54 68 65 20 69 6e 70 75 74 20 64 | finition.$definition.The.input.d |
4e540 | 65 66 69 6e 69 74 69 6f 6e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e | efinition......*/.....public.fun |
4e560 | 63 74 69 6f 6e 20 73 65 74 44 65 66 69 6e 69 74 69 6f 6e 28 49 6e 70 75 74 44 65 66 69 6e 69 74 | ction.setDefinition(InputDefinit |
4e580 | 69 6f 6e 20 24 64 65 66 69 6e 69 74 69 6f 6e 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 | ion.$definition).....{.........$ |
4e5a0 | 74 68 69 73 2d 3e 64 65 66 69 6e 69 74 69 6f 6e 20 3d 20 24 64 65 66 69 6e 69 74 69 6f 6e 3b 0a | this->definition.=.$definition;. |
4e5c0 | 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 49 | ....}....../**......*.Gets.the.I |
4e5e0 | 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 20 72 65 6c 61 74 65 64 20 74 6f 20 74 68 69 73 20 41 | nputDefinition.related.to.this.A |
4e600 | 70 70 6c 69 63 61 74 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 | pplication.......*......*.@retur |
4e620 | 6e 20 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 20 54 68 65 20 49 6e 70 75 74 44 65 66 69 6e | n.InputDefinition.The.InputDefin |
4e640 | 69 74 69 6f 6e 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 | ition.instance......*/.....publi |
4e660 | 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 44 65 66 69 6e 69 74 69 6f 6e 28 29 0a 20 20 20 20 7b | c.function.getDefinition().....{ |
4e680 | 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 64 65 66 69 6e 69 74 69 6f | .........return.$this->definitio |
4e6a0 | 6e 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 | n;.....}....../**......*.Gets.th |
4e6c0 | 65 20 68 65 6c 70 20 6d 65 73 73 61 67 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 | e.help.message.......*......*.@r |
4e6e0 | 65 74 75 72 6e 20 73 74 72 69 6e 67 20 41 20 68 65 6c 70 20 6d 65 73 73 61 67 65 0a 20 20 20 20 | eturn.string.A.help.message..... |
4e700 | 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 48 65 6c 70 28 | .*/.....public.function.getHelp( |
4e720 | 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 67 65 | ).....{.........return.$this->ge |
4e740 | 74 4c 6f 6e 67 56 65 72 73 69 6f 6e 28 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 | tLongVersion();.....}....../**.. |
4e760 | 20 20 20 20 2a 20 47 65 74 73 20 77 68 65 74 68 65 72 20 74 6f 20 63 61 74 63 68 20 65 78 63 65 | ....*.Gets.whether.to.catch.exce |
4e780 | 70 74 69 6f 6e 73 20 6f 72 20 6e 6f 74 20 64 75 72 69 6e 67 20 63 6f 6d 6d 61 6e 64 73 20 65 78 | ptions.or.not.during.commands.ex |
4e7a0 | 65 63 75 74 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 62 | ecution.......*......*.@return.b |
4e7c0 | 6f 6f 6c 20 57 68 65 74 68 65 72 20 74 6f 20 63 61 74 63 68 20 65 78 63 65 70 74 69 6f 6e 73 20 | ool.Whether.to.catch.exceptions. |
4e7e0 | 6f 72 20 6e 6f 74 20 64 75 72 69 6e 67 20 63 6f 6d 6d 61 6e 64 73 20 65 78 65 63 75 74 69 6f 6e | or.not.during.commands.execution |
4e800 | 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 61 72 65 | ......*/.....public.function.are |
4e820 | 45 78 63 65 70 74 69 6f 6e 73 43 61 75 67 68 74 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 | ExceptionsCaught().....{........ |
4e840 | 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 63 61 74 63 68 45 78 63 65 70 74 69 6f 6e 73 3b 0a | .return.$this->catchExceptions;. |
4e860 | 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 77 68 65 74 68 | ....}....../**......*.Sets.wheth |
4e880 | 65 72 20 74 6f 20 63 61 74 63 68 20 65 78 63 65 70 74 69 6f 6e 73 20 6f 72 20 6e 6f 74 20 64 75 | er.to.catch.exceptions.or.not.du |
4e8a0 | 72 69 6e 67 20 63 6f 6d 6d 61 6e 64 73 20 65 78 65 63 75 74 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a | ring.commands.execution.......*. |
4e8c0 | 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 62 6f 6f 6c 20 24 62 6f 6f 6c 65 61 6e 20 57 68 65 74 | .....*.@param.bool.$boolean.Whet |
4e8e0 | 68 65 72 20 74 6f 20 63 61 74 63 68 20 65 78 63 65 70 74 69 6f 6e 73 20 6f 72 20 6e 6f 74 20 64 | her.to.catch.exceptions.or.not.d |
4e900 | 75 72 69 6e 67 20 63 6f 6d 6d 61 6e 64 73 20 65 78 65 63 75 74 69 6f 6e 0a 20 20 20 20 20 2a 2f | uring.commands.execution......*/ |
4e920 | 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 43 61 74 63 68 45 78 63 | .....public.function.setCatchExc |
4e940 | 65 70 74 69 6f 6e 73 28 24 62 6f 6f 6c 65 61 6e 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | eptions($boolean).....{......... |
4e960 | 24 74 68 69 73 2d 3e 63 61 74 63 68 45 78 63 65 70 74 69 6f 6e 73 20 3d 20 28 62 6f 6f 6c 29 20 | $this->catchExceptions.=.(bool). |
4e980 | 24 62 6f 6f 6c 65 61 6e 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 | $boolean;.....}....../**......*. |
4e9a0 | 47 65 74 73 20 77 68 65 74 68 65 72 20 74 6f 20 61 75 74 6f 6d 61 74 69 63 61 6c 6c 79 20 65 78 | Gets.whether.to.automatically.ex |
4e9c0 | 69 74 20 61 66 74 65 72 20 61 20 63 6f 6d 6d 61 6e 64 20 65 78 65 63 75 74 69 6f 6e 20 6f 72 20 | it.after.a.command.execution.or. |
4e9e0 | 6e 6f 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 62 6f 6f 6c 20 | not.......*......*.@return.bool. |
4ea00 | 57 68 65 74 68 65 72 20 74 6f 20 61 75 74 6f 6d 61 74 69 63 61 6c 6c 79 20 65 78 69 74 20 61 66 | Whether.to.automatically.exit.af |
4ea20 | 74 65 72 20 61 20 63 6f 6d 6d 61 6e 64 20 65 78 65 63 75 74 69 6f 6e 20 6f 72 20 6e 6f 74 0a 20 | ter.a.command.execution.or.not.. |
4ea40 | 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 69 73 41 75 74 | ....*/.....public.function.isAut |
4ea60 | 6f 45 78 69 74 45 6e 61 62 6c 65 64 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 | oExitEnabled().....{.........ret |
4ea80 | 75 72 6e 20 24 74 68 69 73 2d 3e 61 75 74 6f 45 78 69 74 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 | urn.$this->autoExit;.....}...... |
4eaa0 | 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 77 68 65 74 68 65 72 20 74 6f 20 61 75 74 6f 6d | /**......*.Sets.whether.to.autom |
4eac0 | 61 74 69 63 61 6c 6c 79 20 65 78 69 74 20 61 66 74 65 72 20 61 20 63 6f 6d 6d 61 6e 64 20 65 78 | atically.exit.after.a.command.ex |
4eae0 | 65 63 75 74 69 6f 6e 20 6f 72 20 6e 6f 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 | ecution.or.not.......*......*.@p |
4eb00 | 61 72 61 6d 20 62 6f 6f 6c 20 24 62 6f 6f 6c 65 61 6e 20 57 68 65 74 68 65 72 20 74 6f 20 61 75 | aram.bool.$boolean.Whether.to.au |
4eb20 | 74 6f 6d 61 74 69 63 61 6c 6c 79 20 65 78 69 74 20 61 66 74 65 72 20 61 20 63 6f 6d 6d 61 6e 64 | tomatically.exit.after.a.command |
4eb40 | 20 65 78 65 63 75 74 69 6f 6e 20 6f 72 20 6e 6f 74 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 | .execution.or.not......*/.....pu |
4eb60 | 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 41 75 74 6f 45 78 69 74 28 24 62 6f 6f 6c 65 | blic.function.setAutoExit($boole |
4eb80 | 61 6e 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 61 75 74 6f 45 78 69 | an).....{.........$this->autoExi |
4eba0 | 74 20 3d 20 28 62 6f 6f 6c 29 20 24 62 6f 6f 6c 65 61 6e 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 | t.=.(bool).$boolean;.....}...... |
4ebc0 | 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 6e 61 6d 65 20 6f 66 20 74 68 65 20 | /**......*.Gets.the.name.of.the. |
4ebe0 | 61 70 70 6c 69 63 61 74 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 | application.......*......*.@retu |
4ec00 | 72 6e 20 73 74 72 69 6e 67 20 54 68 65 20 61 70 70 6c 69 63 61 74 69 6f 6e 20 6e 61 6d 65 0a 20 | rn.string.The.application.name.. |
4ec20 | 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 4e 61 | ....*/.....public.function.getNa |
4ec40 | 6d 65 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d | me().....{.........return.$this- |
4ec60 | 3e 6e 61 6d 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 | >name;.....}....../**......*.Set |
4ec80 | 73 20 74 68 65 20 61 70 70 6c 69 63 61 74 69 6f 6e 20 6e 61 6d 65 2e 0a 20 20 20 20 20 2a 0a 20 | s.the.application.name.......*.. |
4eca0 | 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6e 61 6d 65 20 54 68 65 20 61 70 | ....*.@param.string.$name.The.ap |
4ecc0 | 70 6c 69 63 61 74 69 6f 6e 20 6e 61 6d 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 | plication.name......*/.....publi |
4ece0 | 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 4e 61 6d 65 28 24 6e 61 6d 65 29 0a 20 20 20 20 7b 0a | c.function.setName($name).....{. |
4ed00 | 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6e 61 6d 65 20 3d 20 24 6e 61 6d 65 3b 0a 20 20 20 | ........$this->name.=.$name;.... |
4ed20 | 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 61 70 70 6c | .}....../**......*.Gets.the.appl |
4ed40 | 69 63 61 74 69 6f 6e 20 76 65 72 73 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 | ication.version.......*......*.@ |
4ed60 | 72 65 74 75 72 6e 20 73 74 72 69 6e 67 20 54 68 65 20 61 70 70 6c 69 63 61 74 69 6f 6e 20 76 65 | return.string.The.application.ve |
4ed80 | 72 73 69 6f 6e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f | rsion......*/.....public.functio |
4eda0 | 6e 20 67 65 74 56 65 72 73 69 6f 6e 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 | n.getVersion().....{.........ret |
4edc0 | 75 72 6e 20 24 74 68 69 73 2d 3e 76 65 72 73 69 6f 6e 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f | urn.$this->version;.....}....../ |
4ede0 | 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 74 68 65 20 61 70 70 6c 69 63 61 74 69 6f 6e 20 76 | **......*.Sets.the.application.v |
4ee00 | 65 72 73 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 | ersion.......*......*.@param.str |
4ee20 | 69 6e 67 20 24 76 65 72 73 69 6f 6e 20 54 68 65 20 61 70 70 6c 69 63 61 74 69 6f 6e 20 76 65 72 | ing.$version.The.application.ver |
4ee40 | 73 69 6f 6e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e | sion......*/.....public.function |
4ee60 | 20 73 65 74 56 65 72 73 69 6f 6e 28 24 76 65 72 73 69 6f 6e 29 0a 20 20 20 20 7b 0a 20 20 20 20 | .setVersion($version).....{..... |
4ee80 | 20 20 20 20 24 74 68 69 73 2d 3e 76 65 72 73 69 6f 6e 20 3d 20 24 76 65 72 73 69 6f 6e 3b 0a 20 | ....$this->version.=.$version;.. |
4eea0 | 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 74 68 65 | ...}....../**......*.Returns.the |
4eec0 | 20 6c 6f 6e 67 20 76 65 72 73 69 6f 6e 20 6f 66 20 74 68 65 20 61 70 70 6c 69 63 61 74 69 6f 6e | .long.version.of.the.application |
4eee0 | 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 20 54 | .......*......*.@return.string.T |
4ef00 | 68 65 20 6c 6f 6e 67 20 61 70 70 6c 69 63 61 74 69 6f 6e 20 76 65 72 73 69 6f 6e 0a 20 20 20 20 | he.long.application.version..... |
4ef20 | 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 4c 6f 6e 67 56 | .*/.....public.function.getLongV |
4ef40 | 65 72 73 69 6f 6e 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 27 55 4e 4b 4e | ersion().....{.........if.('UNKN |
4ef60 | 4f 57 4e 27 20 21 3d 3d 20 24 74 68 69 73 2d 3e 67 65 74 4e 61 6d 65 28 29 29 20 7b 0a 20 20 20 | OWN'.!==.$this->getName()).{.... |
4ef80 | 20 20 20 20 20 20 20 20 20 69 66 20 28 27 55 4e 4b 4e 4f 57 4e 27 20 21 3d 3d 20 24 74 68 69 73 | .........if.('UNKNOWN'.!==.$this |
4efa0 | 2d 3e 67 65 74 56 65 72 73 69 6f 6e 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ->getVersion()).{............... |
4efc0 | 20 20 72 65 74 75 72 6e 20 73 70 72 69 6e 74 66 28 27 3c 69 6e 66 6f 3e 25 73 3c 2f 69 6e 66 6f | ..return.sprintf('<info>%s</info |
4efe0 | 3e 20 76 65 72 73 69 6f 6e 20 3c 63 6f 6d 6d 65 6e 74 3e 25 73 3c 2f 63 6f 6d 6d 65 6e 74 3e 27 | >.version.<comment>%s</comment>' |
4f000 | 2c 20 24 74 68 69 73 2d 3e 67 65 74 4e 61 6d 65 28 29 2c 20 24 74 68 69 73 2d 3e 67 65 74 56 65 | ,.$this->getName(),.$this->getVe |
4f020 | 72 73 69 6f 6e 28 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 | rsion());.............}......... |
4f040 | 20 20 20 20 20 72 65 74 75 72 6e 20 73 70 72 69 6e 74 66 28 27 3c 69 6e 66 6f 3e 25 73 3c 2f 69 | .....return.sprintf('<info>%s</i |
4f060 | 6e 66 6f 3e 27 2c 20 24 74 68 69 73 2d 3e 67 65 74 4e 61 6d 65 28 29 29 3b 0a 20 20 20 20 20 20 | nfo>',.$this->getName());....... |
4f080 | 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 27 3c 69 6e 66 6f 3e 43 6f 6e 73 6f | ..}..........return.'<info>Conso |
4f0a0 | 6c 65 20 54 6f 6f 6c 3c 2f 69 6e 66 6f 3e 27 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a | le.Tool</info>';.....}....../**. |
4f0c0 | 20 20 20 20 20 2a 20 52 65 67 69 73 74 65 72 73 20 61 20 6e 65 77 20 63 6f 6d 6d 61 6e 64 2e 0a | .....*.Registers.a.new.command.. |
4f0e0 | 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6e 61 6d | .....*......*.@param.string.$nam |
4f100 | 65 20 54 68 65 20 63 6f 6d 6d 61 6e 64 20 6e 61 6d 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a | e.The.command.name......*......* |
4f120 | 20 40 72 65 74 75 72 6e 20 43 6f 6d 6d 61 6e 64 20 54 68 65 20 6e 65 77 6c 79 20 63 72 65 61 74 | .@return.Command.The.newly.creat |
4f140 | 65 64 20 63 6f 6d 6d 61 6e 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 | ed.command......*/.....public.fu |
4f160 | 6e 63 74 69 6f 6e 20 72 65 67 69 73 74 65 72 28 24 6e 61 6d 65 29 0a 20 20 20 20 7b 0a 20 20 20 | nction.register($name).....{.... |
4f180 | 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 61 64 64 28 6e 65 77 20 43 6f 6d 6d 61 | .....return.$this->add(new.Comma |
4f1a0 | 6e 64 28 24 6e 61 6d 65 29 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 | nd($name));.....}....../**...... |
4f1c0 | 2a 20 41 64 64 73 20 61 6e 20 61 72 72 61 79 20 6f 66 20 63 6f 6d 6d 61 6e 64 20 6f 62 6a 65 63 | *.Adds.an.array.of.command.objec |
4f1e0 | 74 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 49 66 20 61 20 43 6f 6d 6d 61 6e 64 20 69 | ts.......*......*.If.a.Command.i |
4f200 | 73 20 6e 6f 74 20 65 6e 61 62 6c 65 64 20 69 74 20 77 69 6c 6c 20 6e 6f 74 20 62 65 20 61 64 64 | s.not.enabled.it.will.not.be.add |
4f220 | 65 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 43 6f 6d 6d 61 6e 64 | ed.......*......*.@param.Command |
4f240 | 5b 5d 20 24 63 6f 6d 6d 61 6e 64 73 20 41 6e 20 61 72 72 61 79 20 6f 66 20 63 6f 6d 6d 61 6e 64 | [].$commands.An.array.of.command |
4f260 | 73 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 61 64 | s......*/.....public.function.ad |
4f280 | 64 43 6f 6d 6d 61 6e 64 73 28 61 72 72 61 79 20 24 63 6f 6d 6d 61 6e 64 73 29 0a 20 20 20 20 7b | dCommands(array.$commands).....{ |
4f2a0 | 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 63 6f 6d 6d 61 6e 64 73 20 61 73 20 24 | .........foreach.($commands.as.$ |
4f2c0 | 63 6f 6d 6d 61 6e 64 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 61 64 | command).{.............$this->ad |
4f2e0 | 64 28 24 63 6f 6d 6d 61 6e 64 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 | d($command);.........}.....}.... |
4f300 | 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 41 64 64 73 20 61 20 63 6f 6d 6d 61 6e 64 20 6f 62 6a 65 | ../**......*.Adds.a.command.obje |
4f320 | 63 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 49 66 20 61 20 63 6f 6d 6d 61 6e 64 20 77 | ct.......*......*.If.a.command.w |
4f340 | 69 74 68 20 74 68 65 20 73 61 6d 65 20 6e 61 6d 65 20 61 6c 72 65 61 64 79 20 65 78 69 73 74 73 | ith.the.same.name.already.exists |
4f360 | 2c 20 69 74 20 77 69 6c 6c 20 62 65 20 6f 76 65 72 72 69 64 64 65 6e 2e 0a 20 20 20 20 20 2a 20 | ,.it.will.be.overridden.......*. |
4f380 | 49 66 20 74 68 65 20 63 6f 6d 6d 61 6e 64 20 69 73 20 6e 6f 74 20 65 6e 61 62 6c 65 64 20 69 74 | If.the.command.is.not.enabled.it |
4f3a0 | 20 77 69 6c 6c 20 6e 6f 74 20 62 65 20 61 64 64 65 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 | .will.not.be.added.......*...... |
4f3c0 | 2a 20 40 70 61 72 61 6d 20 43 6f 6d 6d 61 6e 64 20 24 63 6f 6d 6d 61 6e 64 20 41 20 43 6f 6d 6d | *.@param.Command.$command.A.Comm |
4f3e0 | 61 6e 64 20 6f 62 6a 65 63 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e | and.object......*......*.@return |
4f400 | 20 43 6f 6d 6d 61 6e 64 7c 6e 75 6c 6c 20 54 68 65 20 72 65 67 69 73 74 65 72 65 64 20 63 6f 6d | .Command|null.The.registered.com |
4f420 | 6d 61 6e 64 20 69 66 20 65 6e 61 62 6c 65 64 20 6f 72 20 6e 75 6c 6c 0a 20 20 20 20 20 2a 2f 0a | mand.if.enabled.or.null......*/. |
4f440 | 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 61 64 64 28 43 6f 6d 6d 61 6e 64 20 | ....public.function.add(Command. |
4f460 | 24 63 6f 6d 6d 61 6e 64 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 63 6f 6d 6d 61 6e 64 | $command).....{.........$command |
4f480 | 2d 3e 73 65 74 41 70 70 6c 69 63 61 74 69 6f 6e 28 24 74 68 69 73 29 3b 0a 0a 20 20 20 20 20 20 | ->setApplication($this);........ |
4f4a0 | 20 20 69 66 20 28 21 24 63 6f 6d 6d 61 6e 64 2d 3e 69 73 45 6e 61 62 6c 65 64 28 29 29 20 7b 0a | ..if.(!$command->isEnabled()).{. |
4f4c0 | 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6f 6d 6d 61 6e 64 2d 3e 73 65 74 41 70 70 6c 69 63 61 | ............$command->setApplica |
4f4e0 | 74 69 6f 6e 28 6e 75 6c 6c 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 3b | tion(null);..............return; |
4f500 | 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d | .........}..........if.(null.=== |
4f520 | 20 24 63 6f 6d 6d 61 6e 64 2d 3e 67 65 74 44 65 66 69 6e 69 74 69 6f 6e 28 29 29 20 7b 0a 20 20 | .$command->getDefinition()).{... |
4f540 | 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 4c 6f 67 69 63 45 78 63 65 70 74 69 | ..........throw.new.LogicExcepti |
4f560 | 6f 6e 28 73 70 72 69 6e 74 66 28 27 43 6f 6d 6d 61 6e 64 20 63 6c 61 73 73 20 22 25 73 22 20 69 | on(sprintf('Command.class."%s".i |
4f580 | 73 20 6e 6f 74 20 63 6f 72 72 65 63 74 6c 79 20 69 6e 69 74 69 61 6c 69 7a 65 64 2e 20 59 6f 75 | s.not.correctly.initialized..You |
4f5a0 | 20 70 72 6f 62 61 62 6c 79 20 66 6f 72 67 6f 74 20 74 6f 20 63 61 6c 6c 20 74 68 65 20 70 61 72 | .probably.forgot.to.call.the.par |
4f5c0 | 65 6e 74 20 63 6f 6e 73 74 72 75 63 74 6f 72 2e 27 2c 20 67 65 74 5f 63 6c 61 73 73 28 24 63 6f | ent.constructor.',.get_class($co |
4f5e0 | 6d 6d 61 6e 64 29 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 | mmand)));.........}..........$th |
4f600 | 69 73 2d 3e 63 6f 6d 6d 61 6e 64 73 5b 24 63 6f 6d 6d 61 6e 64 2d 3e 67 65 74 4e 61 6d 65 28 29 | is->commands[$command->getName() |
4f620 | 5d 20 3d 20 24 63 6f 6d 6d 61 6e 64 3b 0a 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 | ].=.$command;..........foreach.( |
4f640 | 24 63 6f 6d 6d 61 6e 64 2d 3e 67 65 74 41 6c 69 61 73 65 73 28 29 20 61 73 20 24 61 6c 69 61 73 | $command->getAliases().as.$alias |
4f660 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 63 6f 6d 6d 61 6e 64 73 5b | ).{.............$this->commands[ |
4f680 | 24 61 6c 69 61 73 5d 20 3d 20 24 63 6f 6d 6d 61 6e 64 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 | $alias].=.$command;.........}... |
4f6a0 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 63 6f 6d 6d 61 6e 64 3b 0a 20 20 20 20 7d 0a 0a 20 | .......return.$command;.....}... |
4f6c0 | 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 61 20 72 65 67 69 73 74 65 72 | .../**......*.Returns.a.register |
4f6e0 | 65 64 20 63 6f 6d 6d 61 6e 64 20 62 79 20 6e 61 6d 65 20 6f 72 20 61 6c 69 61 73 2e 0a 20 20 20 | ed.command.by.name.or.alias..... |
4f700 | 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6e 61 6d 65 20 54 | ..*......*.@param.string.$name.T |
4f720 | 68 65 20 63 6f 6d 6d 61 6e 64 20 6e 61 6d 65 20 6f 72 20 61 6c 69 61 73 0a 20 20 20 20 20 2a 0a | he.command.name.or.alias......*. |
4f740 | 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 43 6f 6d 6d 61 6e 64 20 41 20 43 6f 6d 6d 61 6e 64 | .....*.@return.Command.A.Command |
4f760 | 20 6f 62 6a 65 63 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 43 6f | .object......*......*.@throws.Co |
4f780 | 6d 6d 61 6e 64 4e 6f 74 46 6f 75 6e 64 45 78 63 65 70 74 69 6f 6e 20 57 68 65 6e 20 63 6f 6d 6d | mmandNotFoundException.When.comm |
4f7a0 | 61 6e 64 20 6e 61 6d 65 20 67 69 76 65 6e 20 64 6f 65 73 20 6e 6f 74 20 65 78 69 73 74 0a 20 20 | and.name.given.does.not.exist... |
4f7c0 | 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 28 24 6e | ...*/.....public.function.get($n |
4f7e0 | 61 6d 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 69 73 73 65 74 28 24 74 | ame).....{.........if.(!isset($t |
4f800 | 68 69 73 2d 3e 63 6f 6d 6d 61 6e 64 73 5b 24 6e 61 6d 65 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 | his->commands[$name])).{........ |
4f820 | 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 43 6f 6d 6d 61 6e 64 4e 6f 74 46 6f 75 6e 64 45 78 | .....throw.new.CommandNotFoundEx |
4f840 | 63 65 70 74 69 6f 6e 28 73 70 72 69 6e 74 66 28 27 54 68 65 20 63 6f 6d 6d 61 6e 64 20 22 25 73 | ception(sprintf('The.command."%s |
4f860 | 22 20 64 6f 65 73 20 6e 6f 74 20 65 78 69 73 74 2e 27 2c 20 24 6e 61 6d 65 29 29 3b 0a 20 20 20 | ".does.not.exist.',.$name));.... |
4f880 | 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 63 6f 6d 6d 61 6e 64 20 3d 20 24 74 68 69 73 | .....}..........$command.=.$this |
4f8a0 | 2d 3e 63 6f 6d 6d 61 6e 64 73 5b 24 6e 61 6d 65 5d 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 | ->commands[$name];..........if.( |
4f8c0 | 24 74 68 69 73 2d 3e 77 61 6e 74 48 65 6c 70 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | $this->wantHelps).{............. |
4f8e0 | 24 74 68 69 73 2d 3e 77 61 6e 74 48 65 6c 70 73 20 3d 20 66 61 6c 73 65 3b 0a 0a 20 20 20 20 20 | $this->wantHelps.=.false;....... |
4f900 | 20 20 20 20 20 20 20 24 68 65 6c 70 43 6f 6d 6d 61 6e 64 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 | .......$helpCommand.=.$this->get |
4f920 | 28 27 68 65 6c 70 27 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 68 65 6c 70 43 6f 6d 6d 61 | ('help');.............$helpComma |
4f940 | 6e 64 2d 3e 73 65 74 43 6f 6d 6d 61 6e 64 28 24 63 6f 6d 6d 61 6e 64 29 3b 0a 0a 20 20 20 20 20 | nd->setCommand($command);....... |
4f960 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 68 65 6c 70 43 6f 6d 6d 61 6e 64 3b 0a 20 20 20 20 | .......return.$helpCommand;..... |
4f980 | 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 63 6f 6d 6d 61 6e 64 3b 0a | ....}..........return.$command;. |
4f9a0 | 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 74 72 | ....}....../**......*.Returns.tr |
4f9c0 | 75 65 20 69 66 20 74 68 65 20 63 6f 6d 6d 61 6e 64 20 65 78 69 73 74 73 2c 20 66 61 6c 73 65 20 | ue.if.the.command.exists,.false. |
4f9e0 | 6f 74 68 65 72 77 69 73 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 | otherwise.......*......*.@param. |
4fa00 | 73 74 72 69 6e 67 20 24 6e 61 6d 65 20 54 68 65 20 63 6f 6d 6d 61 6e 64 20 6e 61 6d 65 20 6f 72 | string.$name.The.command.name.or |
4fa20 | 20 61 6c 69 61 73 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 62 6f 6f | .alias......*......*.@return.boo |
4fa40 | 6c 20 74 72 75 65 20 69 66 20 74 68 65 20 63 6f 6d 6d 61 6e 64 20 65 78 69 73 74 73 2c 20 66 61 | l.true.if.the.command.exists,.fa |
4fa60 | 6c 73 65 20 6f 74 68 65 72 77 69 73 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 | lse.otherwise......*/.....public |
4fa80 | 20 66 75 6e 63 74 69 6f 6e 20 68 61 73 28 24 6e 61 6d 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 | .function.has($name).....{...... |
4faa0 | 20 20 20 72 65 74 75 72 6e 20 69 73 73 65 74 28 24 74 68 69 73 2d 3e 63 6f 6d 6d 61 6e 64 73 5b | ...return.isset($this->commands[ |
4fac0 | 24 6e 61 6d 65 5d 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 | $name]);.....}....../**......*.R |
4fae0 | 65 74 75 72 6e 73 20 61 6e 20 61 72 72 61 79 20 6f 66 20 61 6c 6c 20 75 6e 69 71 75 65 20 6e 61 | eturns.an.array.of.all.unique.na |
4fb00 | 6d 65 73 70 61 63 65 73 20 75 73 65 64 20 62 79 20 63 75 72 72 65 6e 74 6c 79 20 72 65 67 69 73 | mespaces.used.by.currently.regis |
4fb20 | 74 65 72 65 64 20 63 6f 6d 6d 61 6e 64 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 49 74 | tered.commands.......*......*.It |
4fb40 | 20 64 6f 65 73 20 6e 6f 74 20 72 65 74 75 72 6e 20 74 68 65 20 67 6c 6f 62 61 6c 20 6e 61 6d 65 | .does.not.return.the.global.name |
4fb60 | 73 70 61 63 65 20 77 68 69 63 68 20 61 6c 77 61 79 73 20 65 78 69 73 74 73 2e 0a 20 20 20 20 20 | space.which.always.exists....... |
4fb80 | 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 5b 5d 20 41 6e 20 61 72 72 | *......*.@return.string[].An.arr |
4fba0 | 61 79 20 6f 66 20 6e 61 6d 65 73 70 61 63 65 73 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 | ay.of.namespaces......*/.....pub |
4fbc0 | 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 4e 61 6d 65 73 70 61 63 65 73 28 29 0a 20 20 20 | lic.function.getNamespaces().... |
4fbe0 | 20 7b 0a 20 20 20 20 20 20 20 20 24 6e 61 6d 65 73 70 61 63 65 73 20 3d 20 61 72 72 61 79 28 29 | .{.........$namespaces.=.array() |
4fc00 | 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 74 68 69 73 2d 3e 61 6c 6c 28 29 20 | ;.........foreach.($this->all(). |
4fc20 | 61 73 20 24 63 6f 6d 6d 61 6e 64 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6e 61 6d 65 | as.$command).{.............$name |
4fc40 | 73 70 61 63 65 73 20 3d 20 61 72 72 61 79 5f 6d 65 72 67 65 28 24 6e 61 6d 65 73 70 61 63 65 73 | spaces.=.array_merge($namespaces |
4fc60 | 2c 20 24 74 68 69 73 2d 3e 65 78 74 72 61 63 74 41 6c 6c 4e 61 6d 65 73 70 61 63 65 73 28 24 63 | ,.$this->extractAllNamespaces($c |
4fc80 | 6f 6d 6d 61 6e 64 2d 3e 67 65 74 4e 61 6d 65 28 29 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 | ommand->getName()));............ |
4fca0 | 20 20 66 6f 72 65 61 63 68 20 28 24 63 6f 6d 6d 61 6e 64 2d 3e 67 65 74 41 6c 69 61 73 65 73 28 | ..foreach.($command->getAliases( |
4fcc0 | 29 20 61 73 20 24 61 6c 69 61 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 | ).as.$alias).{.................$ |
4fce0 | 6e 61 6d 65 73 70 61 63 65 73 20 3d 20 61 72 72 61 79 5f 6d 65 72 67 65 28 24 6e 61 6d 65 73 70 | namespaces.=.array_merge($namesp |
4fd00 | 61 63 65 73 2c 20 24 74 68 69 73 2d 3e 65 78 74 72 61 63 74 41 6c 6c 4e 61 6d 65 73 70 61 63 65 | aces,.$this->extractAllNamespace |
4fd20 | 73 28 24 61 6c 69 61 73 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 | s($alias));.............}....... |
4fd40 | 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 61 72 72 61 79 5f 76 61 6c 75 65 73 | ..}..........return.array_values |
4fd60 | 28 61 72 72 61 79 5f 75 6e 69 71 75 65 28 61 72 72 61 79 5f 66 69 6c 74 65 72 28 24 6e 61 6d 65 | (array_unique(array_filter($name |
4fd80 | 73 70 61 63 65 73 29 29 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a | spaces)));.....}....../**......* |
4fda0 | 20 46 69 6e 64 73 20 61 20 72 65 67 69 73 74 65 72 65 64 20 6e 61 6d 65 73 70 61 63 65 20 62 79 | .Finds.a.registered.namespace.by |
4fdc0 | 20 61 20 6e 61 6d 65 20 6f 72 20 61 6e 20 61 62 62 72 65 76 69 61 74 69 6f 6e 2e 0a 20 20 20 20 | .a.name.or.an.abbreviation...... |
4fde0 | 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6e 61 6d 65 73 70 61 | .*......*.@param.string.$namespa |
4fe00 | 63 65 20 41 20 6e 61 6d 65 73 70 61 63 65 20 6f 72 20 61 62 62 72 65 76 69 61 74 69 6f 6e 20 74 | ce.A.namespace.or.abbreviation.t |
4fe20 | 6f 20 73 65 61 72 63 68 20 66 6f 72 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 | o.search.for......*......*.@retu |
4fe40 | 72 6e 20 73 74 72 69 6e 67 20 41 20 72 65 67 69 73 74 65 72 65 64 20 6e 61 6d 65 73 70 61 63 65 | rn.string.A.registered.namespace |
4fe60 | 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 43 6f 6d 6d 61 6e 64 4e 6f | ......*......*.@throws.CommandNo |
4fe80 | 74 46 6f 75 6e 64 45 78 63 65 70 74 69 6f 6e 20 57 68 65 6e 20 6e 61 6d 65 73 70 61 63 65 20 69 | tFoundException.When.namespace.i |
4fea0 | 73 20 69 6e 63 6f 72 72 65 63 74 20 6f 72 20 61 6d 62 69 67 75 6f 75 73 0a 20 20 20 20 20 2a 2f | s.incorrect.or.ambiguous......*/ |
4fec0 | 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 66 69 6e 64 4e 61 6d 65 73 70 61 | .....public.function.findNamespa |
4fee0 | 63 65 28 24 6e 61 6d 65 73 70 61 63 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 61 6c | ce($namespace).....{.........$al |
4ff00 | 6c 4e 61 6d 65 73 70 61 63 65 73 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 4e 61 6d 65 73 70 61 63 | lNamespaces.=.$this->getNamespac |
4ff20 | 65 73 28 29 3b 0a 20 20 20 20 20 20 20 20 24 65 78 70 72 20 3d 20 70 72 65 67 5f 72 65 70 6c 61 | es();.........$expr.=.preg_repla |
4ff40 | 63 65 5f 63 61 6c 6c 62 61 63 6b 28 27 7b 28 5b 5e 3a 5d 2b 7c 29 7d 27 2c 20 66 75 6e 63 74 69 | ce_callback('{([^:]+|)}',.functi |
4ff60 | 6f 6e 20 28 24 6d 61 74 63 68 65 73 29 20 7b 20 72 65 74 75 72 6e 20 70 72 65 67 5f 71 75 6f 74 | on.($matches).{.return.preg_quot |
4ff80 | 65 28 24 6d 61 74 63 68 65 73 5b 31 5d 29 2e 27 5b 5e 3a 5d 2a 27 3b 20 7d 2c 20 24 6e 61 6d 65 | e($matches[1]).'[^:]*';.},.$name |
4ffa0 | 73 70 61 63 65 29 3b 0a 20 20 20 20 20 20 20 20 24 6e 61 6d 65 73 70 61 63 65 73 20 3d 20 70 72 | space);.........$namespaces.=.pr |
4ffc0 | 65 67 5f 67 72 65 70 28 27 7b 5e 27 2e 24 65 78 70 72 2e 27 7d 27 2c 20 24 61 6c 6c 4e 61 6d 65 | eg_grep('{^'.$expr.'}',.$allName |
4ffe0 | 73 70 61 63 65 73 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 65 6d 70 74 79 28 24 6e 61 6d | spaces);..........if.(empty($nam |
50000 | 65 73 70 61 63 65 73 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 | espaces)).{.............$message |
50020 | 20 3d 20 73 70 72 69 6e 74 66 28 27 54 68 65 72 65 20 61 72 65 20 6e 6f 20 63 6f 6d 6d 61 6e 64 | .=.sprintf('There.are.no.command |
50040 | 73 20 64 65 66 69 6e 65 64 20 69 6e 20 74 68 65 20 22 25 73 22 20 6e 61 6d 65 73 70 61 63 65 2e | s.defined.in.the."%s".namespace. |
50060 | 27 2c 20 24 6e 61 6d 65 73 70 61 63 65 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 | ',.$namespace);..............if. |
50080 | 28 24 61 6c 74 65 72 6e 61 74 69 76 65 73 20 3d 20 24 74 68 69 73 2d 3e 66 69 6e 64 41 6c 74 65 | ($alternatives.=.$this->findAlte |
500a0 | 72 6e 61 74 69 76 65 73 28 24 6e 61 6d 65 73 70 61 63 65 2c 20 24 61 6c 6c 4e 61 6d 65 73 70 61 | rnatives($namespace,.$allNamespa |
500c0 | 63 65 73 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 31 20 3d 3d | ces)).{.................if.(1.== |
500e0 | 20 63 6f 75 6e 74 28 24 61 6c 74 65 72 6e 61 74 69 76 65 73 29 29 20 7b 0a 20 20 20 20 20 20 20 | .count($alternatives)).{........ |
50100 | 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 20 2e 3d 20 22 5c 6e 5c 6e 44 69 | .............$message..=."\n\nDi |
50120 | 64 20 79 6f 75 20 6d 65 61 6e 20 74 68 69 73 3f 5c 6e 20 20 20 20 22 3b 0a 20 20 20 20 20 20 20 | d.you.mean.this?\n....";........ |
50140 | 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | .........}.else.{............... |
50160 | 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 20 2e 3d 20 22 5c 6e 5c 6e 44 69 64 20 79 6f 75 20 6d | ......$message..=."\n\nDid.you.m |
50180 | 65 61 6e 20 6f 6e 65 20 6f 66 20 74 68 65 73 65 3f 5c 6e 20 20 20 20 22 3b 0a 20 20 20 20 20 20 | ean.one.of.these?\n....";....... |
501a0 | 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 65 | ..........}..................$me |
501c0 | 73 73 61 67 65 20 2e 3d 20 69 6d 70 6c 6f 64 65 28 22 5c 6e 20 20 20 20 22 2c 20 24 61 6c 74 65 | ssage..=.implode("\n....",.$alte |
501e0 | 72 6e 61 74 69 76 65 73 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 | rnatives);.............}........ |
50200 | 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 43 6f 6d 6d 61 6e 64 4e 6f 74 46 6f 75 6e 64 45 | ......throw.new.CommandNotFoundE |
50220 | 78 63 65 70 74 69 6f 6e 28 24 6d 65 73 73 61 67 65 2c 20 24 61 6c 74 65 72 6e 61 74 69 76 65 73 | xception($message,.$alternatives |
50240 | 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 65 78 61 63 74 20 3d 20 69 | );.........}..........$exact.=.i |
50260 | 6e 5f 61 72 72 61 79 28 24 6e 61 6d 65 73 70 61 63 65 2c 20 24 6e 61 6d 65 73 70 61 63 65 73 2c | n_array($namespace,.$namespaces, |
50280 | 20 74 72 75 65 29 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 63 6f 75 6e 74 28 24 6e 61 6d 65 73 | .true);.........if.(count($names |
502a0 | 70 61 63 65 73 29 20 3e 20 31 20 26 26 20 21 24 65 78 61 63 74 29 20 7b 0a 20 20 20 20 20 20 20 | paces).>.1.&&.!$exact).{........ |
502c0 | 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 43 6f 6d 6d 61 6e 64 4e 6f 74 46 6f 75 6e 64 45 78 | .....throw.new.CommandNotFoundEx |
502e0 | 63 65 70 74 69 6f 6e 28 73 70 72 69 6e 74 66 28 27 54 68 65 20 6e 61 6d 65 73 70 61 63 65 20 22 | ception(sprintf('The.namespace." |
50300 | 25 73 22 20 69 73 20 61 6d 62 69 67 75 6f 75 73 20 28 25 73 29 2e 27 2c 20 24 6e 61 6d 65 73 70 | %s".is.ambiguous.(%s).',.$namesp |
50320 | 61 63 65 2c 20 24 74 68 69 73 2d 3e 67 65 74 41 62 62 72 65 76 69 61 74 69 6f 6e 53 75 67 67 65 | ace,.$this->getAbbreviationSugge |
50340 | 73 74 69 6f 6e 73 28 61 72 72 61 79 5f 76 61 6c 75 65 73 28 24 6e 61 6d 65 73 70 61 63 65 73 29 | stions(array_values($namespaces) |
50360 | 29 29 2c 20 61 72 72 61 79 5f 76 61 6c 75 65 73 28 24 6e 61 6d 65 73 70 61 63 65 73 29 29 3b 0a | )),.array_values($namespaces));. |
50380 | 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 65 78 61 63 74 | ........}..........return.$exact |
503a0 | 20 3f 20 24 6e 61 6d 65 73 70 61 63 65 20 3a 20 72 65 73 65 74 28 24 6e 61 6d 65 73 70 61 63 65 | .?.$namespace.:.reset($namespace |
503c0 | 73 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 46 69 6e 64 73 20 | s);.....}....../**......*.Finds. |
503e0 | 61 20 63 6f 6d 6d 61 6e 64 20 62 79 20 6e 61 6d 65 20 6f 72 20 61 6c 69 61 73 2e 0a 20 20 20 20 | a.command.by.name.or.alias...... |
50400 | 20 2a 0a 20 20 20 20 20 2a 20 43 6f 6e 74 72 61 72 79 20 74 6f 20 67 65 74 2c 20 74 68 69 73 20 | .*......*.Contrary.to.get,.this. |
50420 | 63 6f 6d 6d 61 6e 64 20 74 72 69 65 73 20 74 6f 20 66 69 6e 64 20 74 68 65 20 62 65 73 74 0a 20 | command.tries.to.find.the.best.. |
50440 | 20 20 20 20 2a 20 6d 61 74 63 68 20 69 66 20 79 6f 75 20 67 69 76 65 20 69 74 20 61 6e 20 61 62 | ....*.match.if.you.give.it.an.ab |
50460 | 62 72 65 76 69 61 74 69 6f 6e 20 6f 66 20 61 20 6e 61 6d 65 20 6f 72 20 61 6c 69 61 73 2e 0a 20 | breviation.of.a.name.or.alias... |
50480 | 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6e 61 6d 65 | ....*......*.@param.string.$name |
504a0 | 20 41 20 63 6f 6d 6d 61 6e 64 20 6e 61 6d 65 20 6f 72 20 61 20 63 6f 6d 6d 61 6e 64 20 61 6c 69 | .A.command.name.or.a.command.ali |
504c0 | 61 73 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 43 6f 6d 6d 61 6e 64 | as......*......*.@return.Command |
504e0 | 20 41 20 43 6f 6d 6d 61 6e 64 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 | .A.Command.instance......*...... |
50500 | 2a 20 40 74 68 72 6f 77 73 20 43 6f 6d 6d 61 6e 64 4e 6f 74 46 6f 75 6e 64 45 78 63 65 70 74 69 | *.@throws.CommandNotFoundExcepti |
50520 | 6f 6e 20 57 68 65 6e 20 63 6f 6d 6d 61 6e 64 20 6e 61 6d 65 20 69 73 20 69 6e 63 6f 72 72 65 63 | on.When.command.name.is.incorrec |
50540 | 74 20 6f 72 20 61 6d 62 69 67 75 6f 75 73 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 | t.or.ambiguous......*/.....publi |
50560 | 63 20 66 75 6e 63 74 69 6f 6e 20 66 69 6e 64 28 24 6e 61 6d 65 29 0a 20 20 20 20 7b 0a 20 20 20 | c.function.find($name).....{.... |
50580 | 20 20 20 20 20 24 61 6c 6c 43 6f 6d 6d 61 6e 64 73 20 3d 20 61 72 72 61 79 5f 6b 65 79 73 28 24 | .....$allCommands.=.array_keys($ |
505a0 | 74 68 69 73 2d 3e 63 6f 6d 6d 61 6e 64 73 29 3b 0a 20 20 20 20 20 20 20 20 24 65 78 70 72 20 3d | this->commands);.........$expr.= |
505c0 | 20 70 72 65 67 5f 72 65 70 6c 61 63 65 5f 63 61 6c 6c 62 61 63 6b 28 27 7b 28 5b 5e 3a 5d 2b 7c | .preg_replace_callback('{([^:]+| |
505e0 | 29 7d 27 2c 20 66 75 6e 63 74 69 6f 6e 20 28 24 6d 61 74 63 68 65 73 29 20 7b 20 72 65 74 75 72 | )}',.function.($matches).{.retur |
50600 | 6e 20 70 72 65 67 5f 71 75 6f 74 65 28 24 6d 61 74 63 68 65 73 5b 31 5d 29 2e 27 5b 5e 3a 5d 2a | n.preg_quote($matches[1]).'[^:]* |
50620 | 27 3b 20 7d 2c 20 24 6e 61 6d 65 29 3b 0a 20 20 20 20 20 20 20 20 24 63 6f 6d 6d 61 6e 64 73 20 | ';.},.$name);.........$commands. |
50640 | 3d 20 70 72 65 67 5f 67 72 65 70 28 27 7b 5e 27 2e 24 65 78 70 72 2e 27 7d 27 2c 20 24 61 6c 6c | =.preg_grep('{^'.$expr.'}',.$all |
50660 | 43 6f 6d 6d 61 6e 64 73 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 65 6d 70 74 79 28 24 63 | Commands);..........if.(empty($c |
50680 | 6f 6d 6d 61 6e 64 73 29 20 7c 7c 20 63 6f 75 6e 74 28 70 72 65 67 5f 67 72 65 70 28 27 7b 5e 27 | ommands).||.count(preg_grep('{^' |
506a0 | 2e 24 65 78 70 72 2e 27 24 7d 27 2c 20 24 63 6f 6d 6d 61 6e 64 73 29 29 20 3c 20 31 29 20 7b 0a | .$expr.'$}',.$commands)).<.1).{. |
506c0 | 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 66 61 6c 73 65 20 21 3d 3d 20 24 70 6f 73 20 3d | ............if.(false.!==.$pos.= |
506e0 | 20 73 74 72 72 70 6f 73 28 24 6e 61 6d 65 2c 20 27 3a 27 29 29 20 7b 0a 20 20 20 20 20 20 20 20 | .strrpos($name,.':')).{......... |
50700 | 20 20 20 20 20 20 20 20 2f 2f 20 63 68 65 63 6b 20 69 66 20 61 20 6e 61 6d 65 73 70 61 63 65 20 | ........//.check.if.a.namespace. |
50720 | 65 78 69 73 74 73 20 61 6e 64 20 63 6f 6e 74 61 69 6e 73 20 63 6f 6d 6d 61 6e 64 73 0a 20 20 20 | exists.and.contains.commands.... |
50740 | 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 66 69 6e 64 4e 61 6d 65 73 70 61 63 | .............$this->findNamespac |
50760 | 65 28 73 75 62 73 74 72 28 24 6e 61 6d 65 2c 20 30 2c 20 24 70 6f 73 29 29 3b 0a 20 20 20 20 20 | e(substr($name,.0,.$pos));...... |
50780 | 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 20 3d | .......}..............$message.= |
507a0 | 20 73 70 72 69 6e 74 66 28 27 43 6f 6d 6d 61 6e 64 20 22 25 73 22 20 69 73 20 6e 6f 74 20 64 65 | .sprintf('Command."%s".is.not.de |
507c0 | 66 69 6e 65 64 2e 27 2c 20 24 6e 61 6d 65 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 | fined.',.$name);..............if |
507e0 | 20 28 24 61 6c 74 65 72 6e 61 74 69 76 65 73 20 3d 20 24 74 68 69 73 2d 3e 66 69 6e 64 41 6c 74 | .($alternatives.=.$this->findAlt |
50800 | 65 72 6e 61 74 69 76 65 73 28 24 6e 61 6d 65 2c 20 24 61 6c 6c 43 6f 6d 6d 61 6e 64 73 29 29 20 | ernatives($name,.$allCommands)). |
50820 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 31 20 3d 3d 20 63 6f 75 6e 74 | {.................if.(1.==.count |
50840 | 28 24 61 6c 74 65 72 6e 61 74 69 76 65 73 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | ($alternatives)).{.............. |
50860 | 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 20 2e 3d 20 22 5c 6e 5c 6e 44 69 64 20 79 6f 75 20 | .......$message..=."\n\nDid.you. |
50880 | 6d 65 61 6e 20 74 68 69 73 3f 5c 6e 20 20 20 20 22 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | mean.this?\n....";.............. |
508a0 | 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ...}.else.{..................... |
508c0 | 24 6d 65 73 73 61 67 65 20 2e 3d 20 22 5c 6e 5c 6e 44 69 64 20 79 6f 75 20 6d 65 61 6e 20 6f 6e | $message..=."\n\nDid.you.mean.on |
508e0 | 65 20 6f 66 20 74 68 65 73 65 3f 5c 6e 20 20 20 20 22 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | e.of.these?\n....";............. |
50900 | 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 20 2e | ....}.................$message.. |
50920 | 3d 20 69 6d 70 6c 6f 64 65 28 22 5c 6e 20 20 20 20 22 2c 20 24 61 6c 74 65 72 6e 61 74 69 76 65 | =.implode("\n....",.$alternative |
50940 | 73 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 | s);.............}..............t |
50960 | 68 72 6f 77 20 6e 65 77 20 43 6f 6d 6d 61 6e 64 4e 6f 74 46 6f 75 6e 64 45 78 63 65 70 74 69 6f | hrow.new.CommandNotFoundExceptio |
50980 | 6e 28 24 6d 65 73 73 61 67 65 2c 20 24 61 6c 74 65 72 6e 61 74 69 76 65 73 29 3b 0a 20 20 20 20 | n($message,.$alternatives);..... |
509a0 | 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 2f 2f 20 66 69 6c 74 65 72 20 6f 75 74 20 61 6c 69 | ....}..........//.filter.out.ali |
509c0 | 61 73 65 73 20 66 6f 72 20 63 6f 6d 6d 61 6e 64 73 20 77 68 69 63 68 20 61 72 65 20 61 6c 72 65 | ases.for.commands.which.are.alre |
509e0 | 61 64 79 20 6f 6e 20 74 68 65 20 6c 69 73 74 0a 20 20 20 20 20 20 20 20 69 66 20 28 63 6f 75 6e | ady.on.the.list.........if.(coun |
50a00 | 74 28 24 63 6f 6d 6d 61 6e 64 73 29 20 3e 20 31 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | t($commands).>.1).{............. |
50a20 | 24 63 6f 6d 6d 61 6e 64 4c 69 73 74 20 3d 20 24 74 68 69 73 2d 3e 63 6f 6d 6d 61 6e 64 73 3b 0a | $commandList.=.$this->commands;. |
50a40 | 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6f 6d 6d 61 6e 64 73 20 3d 20 61 72 72 61 79 5f 66 69 | ............$commands.=.array_fi |
50a60 | 6c 74 65 72 28 24 63 6f 6d 6d 61 6e 64 73 2c 20 66 75 6e 63 74 69 6f 6e 20 28 24 6e 61 6d 65 4f | lter($commands,.function.($nameO |
50a80 | 72 41 6c 69 61 73 29 20 75 73 65 20 28 24 63 6f 6d 6d 61 6e 64 4c 69 73 74 2c 20 24 63 6f 6d 6d | rAlias).use.($commandList,.$comm |
50aa0 | 61 6e 64 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6f 6d 6d 61 6e 64 | ands).{.................$command |
50ac0 | 4e 61 6d 65 20 3d 20 24 63 6f 6d 6d 61 6e 64 4c 69 73 74 5b 24 6e 61 6d 65 4f 72 41 6c 69 61 73 | Name.=.$commandList[$nameOrAlias |
50ae0 | 5d 2d 3e 67 65 74 4e 61 6d 65 28 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 | ]->getName();..................r |
50b00 | 65 74 75 72 6e 20 24 63 6f 6d 6d 61 6e 64 4e 61 6d 65 20 3d 3d 3d 20 24 6e 61 6d 65 4f 72 41 6c | eturn.$commandName.===.$nameOrAl |
50b20 | 69 61 73 20 7c 7c 20 21 69 6e 5f 61 72 72 61 79 28 24 63 6f 6d 6d 61 6e 64 4e 61 6d 65 2c 20 24 | ias.||.!in_array($commandName,.$ |
50b40 | 63 6f 6d 6d 61 6e 64 73 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 29 3b 0a 20 20 20 20 20 | commands);.............});...... |
50b60 | 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 65 78 61 63 74 20 3d 20 69 6e 5f 61 72 72 61 79 28 | ...}..........$exact.=.in_array( |
50b80 | 24 6e 61 6d 65 2c 20 24 63 6f 6d 6d 61 6e 64 73 2c 20 74 72 75 65 29 3b 0a 20 20 20 20 20 20 20 | $name,.$commands,.true);........ |
50ba0 | 20 69 66 20 28 63 6f 75 6e 74 28 24 63 6f 6d 6d 61 6e 64 73 29 20 3e 20 31 20 26 26 20 21 24 65 | .if.(count($commands).>.1.&&.!$e |
50bc0 | 78 61 63 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 73 75 67 67 65 73 74 69 6f 6e 73 | xact).{.............$suggestions |
50be0 | 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 41 62 62 72 65 76 69 61 74 69 6f 6e 53 75 67 67 65 73 74 | .=.$this->getAbbreviationSuggest |
50c00 | 69 6f 6e 73 28 61 72 72 61 79 5f 76 61 6c 75 65 73 28 24 63 6f 6d 6d 61 6e 64 73 29 29 3b 0a 0a | ions(array_values($commands));.. |
50c20 | 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 43 6f 6d 6d 61 6e 64 4e 6f 74 | ............throw.new.CommandNot |
50c40 | 46 6f 75 6e 64 45 78 63 65 70 74 69 6f 6e 28 73 70 72 69 6e 74 66 28 27 43 6f 6d 6d 61 6e 64 20 | FoundException(sprintf('Command. |
50c60 | 22 25 73 22 20 69 73 20 61 6d 62 69 67 75 6f 75 73 20 28 25 73 29 2e 27 2c 20 24 6e 61 6d 65 2c | "%s".is.ambiguous.(%s).',.$name, |
50c80 | 20 24 73 75 67 67 65 73 74 69 6f 6e 73 29 2c 20 61 72 72 61 79 5f 76 61 6c 75 65 73 28 24 63 6f | .$suggestions),.array_values($co |
50ca0 | 6d 6d 61 6e 64 73 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 | mmands));.........}..........ret |
50cc0 | 75 72 6e 20 24 74 68 69 73 2d 3e 67 65 74 28 24 65 78 61 63 74 20 3f 20 24 6e 61 6d 65 20 3a 20 | urn.$this->get($exact.?.$name.:. |
50ce0 | 72 65 73 65 74 28 24 63 6f 6d 6d 61 6e 64 73 29 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a | reset($commands));.....}....../* |
50d00 | 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 63 6f 6d 6d 61 6e 64 73 20 28 72 65 67 69 | *......*.Gets.the.commands.(regi |
50d20 | 73 74 65 72 65 64 20 69 6e 20 74 68 65 20 67 69 76 65 6e 20 6e 61 6d 65 73 70 61 63 65 20 69 66 | stered.in.the.given.namespace.if |
50d40 | 20 70 72 6f 76 69 64 65 64 29 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 54 68 65 20 61 72 | .provided).......*......*.The.ar |
50d60 | 72 61 79 20 6b 65 79 73 20 61 72 65 20 74 68 65 20 66 75 6c 6c 20 6e 61 6d 65 73 20 61 6e 64 20 | ray.keys.are.the.full.names.and. |
50d80 | 74 68 65 20 76 61 6c 75 65 73 20 74 68 65 20 63 6f 6d 6d 61 6e 64 20 69 6e 73 74 61 6e 63 65 73 | the.values.the.command.instances |
50da0 | 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6e | .......*......*.@param.string.$n |
50dc0 | 61 6d 65 73 70 61 63 65 20 41 20 6e 61 6d 65 73 70 61 63 65 20 6e 61 6d 65 0a 20 20 20 20 20 2a | amespace.A.namespace.name......* |
50de0 | 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 43 6f 6d 6d 61 6e 64 5b 5d 20 41 6e 20 61 72 72 | ......*.@return.Command[].An.arr |
50e00 | 61 79 20 6f 66 20 43 6f 6d 6d 61 6e 64 20 69 6e 73 74 61 6e 63 65 73 0a 20 20 20 20 20 2a 2f 0a | ay.of.Command.instances......*/. |
50e20 | 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 61 6c 6c 28 24 6e 61 6d 65 73 70 61 | ....public.function.all($namespa |
50e40 | 63 65 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c | ce.=.null).....{.........if.(nul |
50e60 | 6c 20 3d 3d 3d 20 24 6e 61 6d 65 73 70 61 63 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | l.===.$namespace).{............. |
50e80 | 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 63 6f 6d 6d 61 6e 64 73 3b 0a 20 20 20 20 20 20 20 20 | return.$this->commands;......... |
50ea0 | 7d 0a 0a 20 20 20 20 20 20 20 20 24 63 6f 6d 6d 61 6e 64 73 20 3d 20 61 72 72 61 79 28 29 3b 0a | }..........$commands.=.array();. |
50ec0 | 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 74 68 69 73 2d 3e 63 6f 6d 6d 61 6e 64 73 | ........foreach.($this->commands |
50ee0 | 20 61 73 20 24 6e 61 6d 65 20 3d 3e 20 24 63 6f 6d 6d 61 6e 64 29 20 7b 0a 20 20 20 20 20 20 20 | .as.$name.=>.$command).{........ |
50f00 | 20 20 20 20 20 69 66 20 28 24 6e 61 6d 65 73 70 61 63 65 20 3d 3d 3d 20 24 74 68 69 73 2d 3e 65 | .....if.($namespace.===.$this->e |
50f20 | 78 74 72 61 63 74 4e 61 6d 65 73 70 61 63 65 28 24 6e 61 6d 65 2c 20 73 75 62 73 74 72 5f 63 6f | xtractNamespace($name,.substr_co |
50f40 | 75 6e 74 28 24 6e 61 6d 65 73 70 61 63 65 2c 20 27 3a 27 29 20 2b 20 31 29 29 20 7b 0a 20 20 20 | unt($namespace,.':').+.1)).{.... |
50f60 | 20 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6f 6d 6d 61 6e 64 73 5b 24 6e 61 6d 65 5d 20 3d 20 | .............$commands[$name].=. |
50f80 | 24 63 6f 6d 6d 61 6e 64 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 | $command;.............}......... |
50fa0 | 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 63 6f 6d 6d 61 6e 64 73 3b 0a 20 20 20 | }..........return.$commands;.... |
50fc0 | 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 61 6e 20 61 72 | .}....../**......*.Returns.an.ar |
50fe0 | 72 61 79 20 6f 66 20 70 6f 73 73 69 62 6c 65 20 61 62 62 72 65 76 69 61 74 69 6f 6e 73 20 67 69 | ray.of.possible.abbreviations.gi |
51000 | 76 65 6e 20 61 20 73 65 74 20 6f 66 20 6e 61 6d 65 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 | ven.a.set.of.names.......*...... |
51020 | 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 24 6e 61 6d 65 73 20 41 6e 20 61 72 72 61 79 20 6f | *.@param.array.$names.An.array.o |
51040 | 66 20 6e 61 6d 65 73 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 61 72 | f.names......*......*.@return.ar |
51060 | 72 61 79 20 41 6e 20 61 72 72 61 79 20 6f 66 20 61 62 62 72 65 76 69 61 74 69 6f 6e 73 0a 20 20 | ray.An.array.of.abbreviations... |
51080 | 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e | ...*/.....public.static.function |
510a0 | 20 67 65 74 41 62 62 72 65 76 69 61 74 69 6f 6e 73 28 24 6e 61 6d 65 73 29 0a 20 20 20 20 7b 0a | .getAbbreviations($names).....{. |
510c0 | 20 20 20 20 20 20 20 20 24 61 62 62 72 65 76 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 | ........$abbrevs.=.array();..... |
510e0 | 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 6e 61 6d 65 73 20 61 73 20 24 6e 61 6d 65 29 20 7b 0a | ....foreach.($names.as.$name).{. |
51100 | 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 20 28 24 6c 65 6e 20 3d 20 73 74 72 6c 65 6e 28 24 | ............for.($len.=.strlen($ |
51120 | 6e 61 6d 65 29 3b 20 24 6c 65 6e 20 3e 20 30 3b 20 2d 2d 24 6c 65 6e 29 20 7b 0a 20 20 20 20 20 | name);.$len.>.0;.--$len).{...... |
51140 | 20 20 20 20 20 20 20 20 20 20 20 24 61 62 62 72 65 76 20 3d 20 73 75 62 73 74 72 28 24 6e 61 6d | ...........$abbrev.=.substr($nam |
51160 | 65 2c 20 30 2c 20 24 6c 65 6e 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 61 62 | e,.0,.$len);.................$ab |
51180 | 62 72 65 76 73 5b 24 61 62 62 72 65 76 5d 5b 5d 20 3d 20 24 6e 61 6d 65 3b 0a 20 20 20 20 20 20 | brevs[$abbrev][].=.$name;....... |
511a0 | 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 | ......}.........}..........retur |
511c0 | 6e 20 24 61 62 62 72 65 76 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 | n.$abbrevs;.....}....../**...... |
511e0 | 2a 20 52 65 6e 64 65 72 73 20 61 20 63 61 75 67 68 74 20 65 78 63 65 70 74 69 6f 6e 2e 0a 20 20 | *.Renders.a.caught.exception.... |
51200 | 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 5c 45 78 63 65 70 74 69 6f 6e 20 20 20 | ...*......*.@param.\Exception... |
51220 | 20 20 20 24 65 20 20 20 20 20 20 41 6e 20 65 78 63 65 70 74 69 6f 6e 20 69 6e 73 74 61 6e 63 65 | ...$e......An.exception.instance |
51240 | 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 | ......*.@param.OutputInterface.$ |
51260 | 6f 75 74 70 75 74 20 41 6e 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 69 6e 73 74 61 6e | output.An.OutputInterface.instan |
51280 | 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 72 | ce......*/.....public.function.r |
512a0 | 65 6e 64 65 72 45 78 63 65 70 74 69 6f 6e 28 5c 45 78 63 65 70 74 69 6f 6e 20 24 65 2c 20 4f 75 | enderException(\Exception.$e,.Ou |
512c0 | 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 29 0a 20 20 20 20 7b 0a 20 20 20 | tputInterface.$output).....{.... |
512e0 | 20 20 20 20 20 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 27 27 2c 20 4f 75 74 70 75 74 | .....$output->writeln('',.Output |
51300 | 49 6e 74 65 72 66 61 63 65 3a 3a 56 45 52 42 4f 53 49 54 59 5f 51 55 49 45 54 29 3b 0a 0a 20 20 | Interface::VERBOSITY_QUIET);.... |
51320 | 20 20 20 20 20 20 64 6f 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 69 74 6c 65 20 3d 20 | ......do.{.............$title.=. |
51340 | 73 70 72 69 6e 74 66 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 27 20 20 5b 25 73 25 | sprintf(.................'..[%s% |
51360 | 73 5d 20 20 27 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 67 65 74 5f 63 6c 61 73 73 | s]..',.................get_class |
51380 | 28 24 65 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 75 74 70 75 74 2d 3e 69 | ($e),.................$output->i |
513a0 | 73 56 65 72 62 6f 73 65 28 29 20 26 26 20 30 20 21 3d 3d 20 28 24 63 6f 64 65 20 3d 20 24 65 2d | sVerbose().&&.0.!==.($code.=.$e- |
513c0 | 3e 67 65 74 43 6f 64 65 28 29 29 20 3f 20 27 20 28 27 2e 24 63 6f 64 65 2e 27 29 27 20 3a 20 27 | >getCode()).?.'.('.$code.')'.:.' |
513e0 | 27 0a 20 20 20 20 20 20 20 20 20 20 20 20 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6c | '.............);..............$l |
51400 | 65 6e 20 3d 20 24 74 68 69 73 2d 3e 73 74 72 69 6e 67 57 69 64 74 68 28 24 74 69 74 6c 65 29 3b | en.=.$this->stringWidth($title); |
51420 | 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 77 69 64 74 68 20 3d 20 24 74 68 69 73 2d 3e 67 65 | ..............$width.=.$this->ge |
51440 | 74 54 65 72 6d 69 6e 61 6c 57 69 64 74 68 28 29 20 3f 20 24 74 68 69 73 2d 3e 67 65 74 54 65 72 | tTerminalWidth().?.$this->getTer |
51460 | 6d 69 6e 61 6c 57 69 64 74 68 28 29 20 2d 20 31 20 3a 20 50 48 50 5f 49 4e 54 5f 4d 41 58 3b 0a | minalWidth().-.1.:.PHP_INT_MAX;. |
51480 | 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 48 48 56 4d 20 6f 6e 6c 79 20 61 63 63 65 70 74 73 | ............//.HHVM.only.accepts |
514a0 | 20 33 32 20 62 69 74 73 20 69 6e 74 65 67 65 72 20 69 6e 20 73 74 72 5f 73 70 6c 69 74 2c 20 65 | .32.bits.integer.in.str_split,.e |
514c0 | 76 65 6e 20 77 68 65 6e 20 50 48 50 5f 49 4e 54 5f 4d 41 58 20 69 73 20 61 20 36 34 20 62 69 74 | ven.when.PHP_INT_MAX.is.a.64.bit |
514e0 | 20 69 6e 74 65 67 65 72 3a 20 68 74 74 70 73 3a 2f 2f 67 69 74 68 75 62 2e 63 6f 6d 2f 66 61 63 | .integer:.https://github.com/fac |
51500 | 65 62 6f 6f 6b 2f 68 68 76 6d 2f 69 73 73 75 65 73 2f 31 33 32 37 0a 20 20 20 20 20 20 20 20 20 | ebook/hhvm/issues/1327.......... |
51520 | 20 20 20 69 66 20 28 64 65 66 69 6e 65 64 28 27 48 48 56 4d 5f 56 45 52 53 49 4f 4e 27 29 20 26 | ...if.(defined('HHVM_VERSION').& |
51540 | 26 20 24 77 69 64 74 68 20 3e 20 31 20 3c 3c 20 33 31 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | &.$width.>.1.<<.31).{........... |
51560 | 20 20 20 20 20 20 24 77 69 64 74 68 20 3d 20 31 20 3c 3c 20 33 31 3b 0a 20 20 20 20 20 20 20 20 | ......$width.=.1.<<.31;......... |
51580 | 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 66 6f 72 6d 61 74 74 65 72 20 3d 20 24 | ....}.............$formatter.=.$ |
515a0 | 6f 75 74 70 75 74 2d 3e 67 65 74 46 6f 72 6d 61 74 74 65 72 28 29 3b 0a 20 20 20 20 20 20 20 20 | output->getFormatter();......... |
515c0 | 20 20 20 20 24 6c 69 6e 65 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 | ....$lines.=.array();........... |
515e0 | 20 20 66 6f 72 65 61 63 68 20 28 70 72 65 67 5f 73 70 6c 69 74 28 27 2f 5c 72 3f 5c 6e 2f 27 2c | ..foreach.(preg_split('/\r?\n/', |
51600 | 20 24 65 2d 3e 67 65 74 4d 65 73 73 61 67 65 28 29 29 20 61 73 20 24 6c 69 6e 65 29 20 7b 0a 20 | .$e->getMessage()).as.$line).{.. |
51620 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 74 68 69 73 2d 3e 73 | ...............foreach.($this->s |
51640 | 70 6c 69 74 53 74 72 69 6e 67 42 79 57 69 64 74 68 28 24 6c 69 6e 65 2c 20 24 77 69 64 74 68 20 | plitStringByWidth($line,.$width. |
51660 | 2d 20 34 29 20 61 73 20 24 6c 69 6e 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | -.4).as.$line).{................ |
51680 | 20 20 20 20 20 2f 2f 20 70 72 65 2d 66 6f 72 6d 61 74 20 6c 69 6e 65 73 20 74 6f 20 67 65 74 20 | .....//.pre-format.lines.to.get. |
516a0 | 74 68 65 20 72 69 67 68 74 20 73 74 72 69 6e 67 20 6c 65 6e 67 74 68 0a 20 20 20 20 20 20 20 20 | the.right.string.length......... |
516c0 | 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 69 6e 65 4c 65 6e 67 74 68 20 3d 20 24 74 68 69 73 2d | ............$lineLength.=.$this- |
516e0 | 3e 73 74 72 69 6e 67 57 69 64 74 68 28 70 72 65 67 5f 72 65 70 6c 61 63 65 28 27 2f 1b 5c 5b 5b | >stringWidth(preg_replace('/.\[[ |
51700 | 5e 6d 5d 2a 6d 2f 27 2c 20 27 27 2c 20 24 66 6f 72 6d 61 74 74 65 72 2d 3e 66 6f 72 6d 61 74 28 | ^m]*m/',.'',.$formatter->format( |
51720 | 24 6c 69 6e 65 29 29 29 20 2b 20 34 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | $line))).+.4;................... |
51740 | 20 20 24 6c 69 6e 65 73 5b 5d 20 3d 20 61 72 72 61 79 28 24 6c 69 6e 65 2c 20 24 6c 69 6e 65 4c | ..$lines[].=.array($line,.$lineL |
51760 | 65 6e 67 74 68 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 65 | ength);......................$le |
51780 | 6e 20 3d 20 6d 61 78 28 24 6c 69 6e 65 4c 65 6e 67 74 68 2c 20 24 6c 65 6e 29 3b 0a 20 20 20 20 | n.=.max($lineLength,.$len);..... |
517a0 | 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 | ............}.............}..... |
517c0 | 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 | .........$messages.=.array();... |
517e0 | 20 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 73 5b 5d 20 3d 20 24 65 6d 70 74 79 4c 69 | ..........$messages[].=.$emptyLi |
51800 | 6e 65 20 3d 20 24 66 6f 72 6d 61 74 74 65 72 2d 3e 66 6f 72 6d 61 74 28 73 70 72 69 6e 74 66 28 | ne.=.$formatter->format(sprintf( |
51820 | 27 3c 65 72 72 6f 72 3e 25 73 3c 2f 65 72 72 6f 72 3e 27 2c 20 73 74 72 5f 72 65 70 65 61 74 28 | '<error>%s</error>',.str_repeat( |
51840 | 27 20 27 2c 20 24 6c 65 6e 29 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 | '.',.$len)));.............$messa |
51860 | 67 65 73 5b 5d 20 3d 20 24 66 6f 72 6d 61 74 74 65 72 2d 3e 66 6f 72 6d 61 74 28 73 70 72 69 6e | ges[].=.$formatter->format(sprin |
51880 | 74 66 28 27 3c 65 72 72 6f 72 3e 25 73 25 73 3c 2f 65 72 72 6f 72 3e 27 2c 20 24 74 69 74 6c 65 | tf('<error>%s%s</error>',.$title |
518a0 | 2c 20 73 74 72 5f 72 65 70 65 61 74 28 27 20 27 2c 20 6d 61 78 28 30 2c 20 24 6c 65 6e 20 2d 20 | ,.str_repeat('.',.max(0,.$len.-. |
518c0 | 24 74 68 69 73 2d 3e 73 74 72 69 6e 67 57 69 64 74 68 28 24 74 69 74 6c 65 29 29 29 29 29 3b 0a | $this->stringWidth($title)))));. |
518e0 | 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 6c 69 6e 65 73 20 61 73 20 24 | ............foreach.($lines.as.$ |
51900 | 6c 69 6e 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 | line).{.................$message |
51920 | 73 5b 5d 20 3d 20 24 66 6f 72 6d 61 74 74 65 72 2d 3e 66 6f 72 6d 61 74 28 73 70 72 69 6e 74 66 | s[].=.$formatter->format(sprintf |
51940 | 28 27 3c 65 72 72 6f 72 3e 20 20 25 73 20 20 25 73 3c 2f 65 72 72 6f 72 3e 27 2c 20 24 6c 69 6e | ('<error>..%s..%s</error>',.$lin |
51960 | 65 5b 30 5d 2c 20 73 74 72 5f 72 65 70 65 61 74 28 27 20 27 2c 20 24 6c 65 6e 20 2d 20 24 6c 69 | e[0],.str_repeat('.',.$len.-.$li |
51980 | 6e 65 5b 31 5d 29 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 | ne[1])));.............}......... |
519a0 | 20 20 20 20 24 6d 65 73 73 61 67 65 73 5b 5d 20 3d 20 24 65 6d 70 74 79 4c 69 6e 65 3b 0a 20 20 | ....$messages[].=.$emptyLine;... |
519c0 | 20 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 73 5b 5d 20 3d 20 27 27 3b 0a 0a 20 20 20 | ..........$messages[].=.'';..... |
519e0 | 20 20 20 20 20 20 20 20 20 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 24 6d 65 73 73 61 | .........$output->writeln($messa |
51a00 | 67 65 73 2c 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 3a 3a 4f 55 54 50 55 54 5f 52 41 57 | ges,.OutputInterface::OUTPUT_RAW |
51a20 | 20 7c 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 3a 3a 56 45 52 42 4f 53 49 54 59 5f 51 55 | .|.OutputInterface::VERBOSITY_QU |
51a40 | 49 45 54 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 4f 75 74 70 75 74 49 6e 74 | IET);..............if.(OutputInt |
51a60 | 65 72 66 61 63 65 3a 3a 56 45 52 42 4f 53 49 54 59 5f 56 45 52 42 4f 53 45 20 3c 3d 20 24 6f 75 | erface::VERBOSITY_VERBOSE.<=.$ou |
51a80 | 74 70 75 74 2d 3e 67 65 74 56 65 72 62 6f 73 69 74 79 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 | tput->getVerbosity()).{......... |
51aa0 | 20 20 20 20 20 20 20 20 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 27 3c 63 6f 6d 6d 65 | ........$output->writeln('<comme |
51ac0 | 6e 74 3e 45 78 63 65 70 74 69 6f 6e 20 74 72 61 63 65 3a 3c 2f 63 6f 6d 6d 65 6e 74 3e 27 2c 20 | nt>Exception.trace:</comment>',. |
51ae0 | 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 3a 3a 56 45 52 42 4f 53 49 54 59 5f 51 55 49 45 54 | OutputInterface::VERBOSITY_QUIET |
51b00 | 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 65 78 63 65 70 74 69 6f 6e | );..................//.exception |
51b20 | 20 72 65 6c 61 74 65 64 20 70 72 6f 70 65 72 74 69 65 73 0a 20 20 20 20 20 20 20 20 20 20 20 20 | .related.properties............. |
51b40 | 20 20 20 20 24 74 72 61 63 65 20 3d 20 24 65 2d 3e 67 65 74 54 72 61 63 65 28 29 3b 0a 20 20 20 | ....$trace.=.$e->getTrace();.... |
51b60 | 20 20 20 20 20 20 20 20 20 20 20 20 20 61 72 72 61 79 5f 75 6e 73 68 69 66 74 28 24 74 72 61 63 | .............array_unshift($trac |
51b80 | 65 2c 20 61 72 72 61 79 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 27 66 | e,.array(.....................'f |
51ba0 | 75 6e 63 74 69 6f 6e 27 20 3d 3e 20 27 27 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | unction'.=>.'',................. |
51bc0 | 20 20 20 20 27 66 69 6c 65 27 20 3d 3e 20 24 65 2d 3e 67 65 74 46 69 6c 65 28 29 20 21 3d 3d 20 | ....'file'.=>.$e->getFile().!==. |
51be0 | 6e 75 6c 6c 20 3f 20 24 65 2d 3e 67 65 74 46 69 6c 65 28 29 20 3a 20 27 6e 2f 61 27 2c 0a 20 20 | null.?.$e->getFile().:.'n/a',... |
51c00 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 27 6c 69 6e 65 27 20 3d 3e 20 24 65 2d 3e | ..................'line'.=>.$e-> |
51c20 | 67 65 74 4c 69 6e 65 28 29 20 21 3d 3d 20 6e 75 6c 6c 20 3f 20 24 65 2d 3e 67 65 74 4c 69 6e 65 | getLine().!==.null.?.$e->getLine |
51c40 | 28 29 20 3a 20 27 6e 2f 61 27 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ().:.'n/a',..................... |
51c60 | 27 61 72 67 73 27 20 3d 3e 20 61 72 72 61 79 28 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | 'args'.=>.array(),.............. |
51c80 | 20 20 20 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 20 28 24 69 20 | ...));..................for.($i. |
51ca0 | 3d 20 30 2c 20 24 63 6f 75 6e 74 20 3d 20 63 6f 75 6e 74 28 24 74 72 61 63 65 29 3b 20 24 69 20 | =.0,.$count.=.count($trace);.$i. |
51cc0 | 3c 20 24 63 6f 75 6e 74 3b 20 2b 2b 24 69 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | <.$count;.++$i).{............... |
51ce0 | 20 20 20 20 20 20 24 63 6c 61 73 73 20 3d 20 69 73 73 65 74 28 24 74 72 61 63 65 5b 24 69 5d 5b | ......$class.=.isset($trace[$i][ |
51d00 | 27 63 6c 61 73 73 27 5d 29 20 3f 20 24 74 72 61 63 65 5b 24 69 5d 5b 27 63 6c 61 73 73 27 5d 20 | 'class']).?.$trace[$i]['class']. |
51d20 | 3a 20 27 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 79 70 65 20 | :.'';.....................$type. |
51d40 | 3d 20 69 73 73 65 74 28 24 74 72 61 63 65 5b 24 69 5d 5b 27 74 79 70 65 27 5d 29 20 3f 20 24 74 | =.isset($trace[$i]['type']).?.$t |
51d60 | 72 61 63 65 5b 24 69 5d 5b 27 74 79 70 65 27 5d 20 3a 20 27 27 3b 0a 20 20 20 20 20 20 20 20 20 | race[$i]['type'].:.'';.......... |
51d80 | 20 20 20 20 20 20 20 20 20 20 20 24 66 75 6e 63 74 69 6f 6e 20 3d 20 24 74 72 61 63 65 5b 24 69 | ...........$function.=.$trace[$i |
51da0 | 5d 5b 27 66 75 6e 63 74 69 6f 6e 27 5d 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ]['function'];.................. |
51dc0 | 20 20 20 24 66 69 6c 65 20 3d 20 69 73 73 65 74 28 24 74 72 61 63 65 5b 24 69 5d 5b 27 66 69 6c | ...$file.=.isset($trace[$i]['fil |
51de0 | 65 27 5d 29 20 3f 20 24 74 72 61 63 65 5b 24 69 5d 5b 27 66 69 6c 65 27 5d 20 3a 20 27 6e 2f 61 | e']).?.$trace[$i]['file'].:.'n/a |
51e00 | 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 69 6e 65 20 3d 20 69 | ';.....................$line.=.i |
51e20 | 73 73 65 74 28 24 74 72 61 63 65 5b 24 69 5d 5b 27 6c 69 6e 65 27 5d 29 20 3f 20 24 74 72 61 63 | sset($trace[$i]['line']).?.$trac |
51e40 | 65 5b 24 69 5d 5b 27 6c 69 6e 65 27 5d 20 3a 20 27 6e 2f 61 27 3b 0a 0a 20 20 20 20 20 20 20 20 | e[$i]['line'].:.'n/a';.......... |
51e60 | 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 73 70 72 | ............$output->writeln(spr |
51e80 | 69 6e 74 66 28 27 20 25 73 25 73 25 73 28 29 20 61 74 20 3c 69 6e 66 6f 3e 25 73 3a 25 73 3c 2f | intf('.%s%s%s().at.<info>%s:%s</ |
51ea0 | 69 6e 66 6f 3e 27 2c 20 24 63 6c 61 73 73 2c 20 24 74 79 70 65 2c 20 24 66 75 6e 63 74 69 6f 6e | info>',.$class,.$type,.$function |
51ec0 | 2c 20 24 66 69 6c 65 2c 20 24 6c 69 6e 65 29 2c 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 | ,.$file,.$line),.OutputInterface |
51ee0 | 3a 3a 56 45 52 42 4f 53 49 54 59 5f 51 55 49 45 54 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ::VERBOSITY_QUIET);............. |
51f00 | 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 75 74 70 75 74 2d 3e | ....}..................$output-> |
51f20 | 77 72 69 74 65 6c 6e 28 27 27 2c 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 3a 3a 56 45 52 | writeln('',.OutputInterface::VER |
51f40 | 42 4f 53 49 54 59 5f 51 55 49 45 54 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 | BOSITY_QUIET);.............}.... |
51f60 | 20 20 20 20 20 7d 20 77 68 69 6c 65 20 28 24 65 20 3d 20 24 65 2d 3e 67 65 74 50 72 65 76 69 6f | .....}.while.($e.=.$e->getPrevio |
51f80 | 75 73 28 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 21 3d 3d 20 24 74 68 | us());..........if.(null.!==.$th |
51fa0 | 69 73 2d 3e 72 75 6e 6e 69 6e 67 43 6f 6d 6d 61 6e 64 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | is->runningCommand).{........... |
51fc0 | 20 20 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 73 70 72 69 6e 74 66 28 27 3c 69 6e 66 | ..$output->writeln(sprintf('<inf |
51fe0 | 6f 3e 25 73 3c 2f 69 6e 66 6f 3e 27 2c 20 73 70 72 69 6e 74 66 28 24 74 68 69 73 2d 3e 72 75 6e | o>%s</info>',.sprintf($this->run |
52000 | 6e 69 6e 67 43 6f 6d 6d 61 6e 64 2d 3e 67 65 74 53 79 6e 6f 70 73 69 73 28 29 2c 20 24 74 68 69 | ningCommand->getSynopsis(),.$thi |
52020 | 73 2d 3e 67 65 74 4e 61 6d 65 28 29 29 29 2c 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 3a | s->getName())),.OutputInterface: |
52040 | 3a 56 45 52 42 4f 53 49 54 59 5f 51 55 49 45 54 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 | :VERBOSITY_QUIET);.............$ |
52060 | 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 27 27 2c 20 4f 75 74 70 75 74 49 6e 74 65 72 66 | output->writeln('',.OutputInterf |
52080 | 61 63 65 3a 3a 56 45 52 42 4f 53 49 54 59 5f 51 55 49 45 54 29 3b 0a 20 20 20 20 20 20 20 20 7d | ace::VERBOSITY_QUIET);.........} |
520a0 | 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 54 72 69 65 73 20 74 6f 20 | .....}....../**......*.Tries.to. |
520c0 | 66 69 67 75 72 65 20 6f 75 74 20 74 68 65 20 74 65 72 6d 69 6e 61 6c 20 77 69 64 74 68 20 69 6e | figure.out.the.terminal.width.in |
520e0 | 20 77 68 69 63 68 20 74 68 69 73 20 61 70 70 6c 69 63 61 74 69 6f 6e 20 72 75 6e 73 2e 0a 20 20 | .which.this.application.runs.... |
52100 | 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 69 6e 74 7c 6e 75 6c 6c 0a 20 20 20 | ...*......*.@return.int|null.... |
52120 | 20 20 2a 2f 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 54 | ..*/.....protected.function.getT |
52140 | 65 72 6d 69 6e 61 6c 57 69 64 74 68 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 64 69 | erminalWidth().....{.........$di |
52160 | 6d 65 6e 73 69 6f 6e 73 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 54 65 72 6d 69 6e 61 6c 44 69 6d | mensions.=.$this->getTerminalDim |
52180 | 65 6e 73 69 6f 6e 73 28 29 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 64 69 6d 65 | ensions();..........return.$dime |
521a0 | 6e 73 69 6f 6e 73 5b 30 5d 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a | nsions[0];.....}....../**......* |
521c0 | 20 54 72 69 65 73 20 74 6f 20 66 69 67 75 72 65 20 6f 75 74 20 74 68 65 20 74 65 72 6d 69 6e 61 | .Tries.to.figure.out.the.termina |
521e0 | 6c 20 68 65 69 67 68 74 20 69 6e 20 77 68 69 63 68 20 74 68 69 73 20 61 70 70 6c 69 63 61 74 69 | l.height.in.which.this.applicati |
52200 | 6f 6e 20 72 75 6e 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 69 | on.runs.......*......*.@return.i |
52220 | 6e 74 7c 6e 75 6c 6c 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 | nt|null......*/.....protected.fu |
52240 | 6e 63 74 69 6f 6e 20 67 65 74 54 65 72 6d 69 6e 61 6c 48 65 69 67 68 74 28 29 0a 20 20 20 20 7b | nction.getTerminalHeight().....{ |
52260 | 0a 20 20 20 20 20 20 20 20 24 64 69 6d 65 6e 73 69 6f 6e 73 20 3d 20 24 74 68 69 73 2d 3e 67 65 | .........$dimensions.=.$this->ge |
52280 | 74 54 65 72 6d 69 6e 61 6c 44 69 6d 65 6e 73 69 6f 6e 73 28 29 3b 0a 0a 20 20 20 20 20 20 20 20 | tTerminalDimensions();.......... |
522a0 | 72 65 74 75 72 6e 20 24 64 69 6d 65 6e 73 69 6f 6e 73 5b 31 5d 3b 0a 20 20 20 20 7d 0a 0a 20 20 | return.$dimensions[1];.....}.... |
522c0 | 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 54 72 69 65 73 20 74 6f 20 66 69 67 75 72 65 20 6f 75 74 | ../**......*.Tries.to.figure.out |
522e0 | 20 74 68 65 20 74 65 72 6d 69 6e 61 6c 20 64 69 6d 65 6e 73 69 6f 6e 73 20 62 61 73 65 64 20 6f | .the.terminal.dimensions.based.o |
52300 | 6e 20 74 68 65 20 63 75 72 72 65 6e 74 20 65 6e 76 69 72 6f 6e 6d 65 6e 74 2e 0a 20 20 20 20 20 | n.the.current.environment....... |
52320 | 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 61 72 72 61 79 20 41 72 72 61 79 20 63 6f 6e | *......*.@return.array.Array.con |
52340 | 74 61 69 6e 69 6e 67 20 77 69 64 74 68 20 61 6e 64 20 68 65 69 67 68 74 0a 20 20 20 20 20 2a 2f | taining.width.and.height......*/ |
52360 | 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 54 65 72 6d 69 6e 61 6c | .....public.function.getTerminal |
52380 | 44 69 6d 65 6e 73 69 6f 6e 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 | Dimensions().....{.........if.($ |
523a0 | 74 68 69 73 2d 3e 74 65 72 6d 69 6e 61 6c 44 69 6d 65 6e 73 69 6f 6e 73 29 20 7b 0a 20 20 20 20 | this->terminalDimensions).{..... |
523c0 | 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 74 65 72 6d 69 6e 61 6c 44 69 | ........return.$this->terminalDi |
523e0 | 6d 65 6e 73 69 6f 6e 73 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 | mensions;.........}..........if. |
52400 | 28 27 5c 5c 27 20 3d 3d 3d 20 44 49 52 45 43 54 4f 52 59 5f 53 45 50 41 52 41 54 4f 52 29 20 7b | ('\\'.===.DIRECTORY_SEPARATOR).{ |
52420 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 65 78 74 72 61 63 74 20 5b 77 2c 20 48 5d 20 66 | .............//.extract.[w,.H].f |
52440 | 72 6f 6d 20 22 77 78 68 20 28 57 78 48 29 22 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 | rom."wxh.(WxH)".............if.( |
52460 | 70 72 65 67 5f 6d 61 74 63 68 28 27 2f 5e 28 5c 64 2b 29 78 5c 64 2b 20 5c 28 5c 64 2b 78 28 5c | preg_match('/^(\d+)x\d+.\(\d+x(\ |
52480 | 64 2b 29 5c 29 24 2f 27 2c 20 74 72 69 6d 28 67 65 74 65 6e 76 28 27 41 4e 53 49 43 4f 4e 27 29 | d+)\)$/',.trim(getenv('ANSICON') |
524a0 | 29 2c 20 24 6d 61 74 63 68 65 73 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ),.$matches)).{................. |
524c0 | 72 65 74 75 72 6e 20 61 72 72 61 79 28 28 69 6e 74 29 20 24 6d 61 74 63 68 65 73 5b 31 5d 2c 20 | return.array((int).$matches[1],. |
524e0 | 28 69 6e 74 29 20 24 6d 61 74 63 68 65 73 5b 32 5d 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | (int).$matches[2]);............. |
52500 | 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 65 78 74 72 61 63 74 20 5b 77 2c 20 68 5d 20 | }.............//.extract.[w,.h]. |
52520 | 66 72 6f 6d 20 22 77 78 68 22 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 70 72 65 67 5f | from."wxh".............if.(preg_ |
52540 | 6d 61 74 63 68 28 27 2f 5e 28 5c 64 2b 29 78 28 5c 64 2b 29 24 2f 27 2c 20 24 74 68 69 73 2d 3e | match('/^(\d+)x(\d+)$/',.$this-> |
52560 | 67 65 74 43 6f 6e 73 6f 6c 65 4d 6f 64 65 28 29 2c 20 24 6d 61 74 63 68 65 73 29 29 20 7b 0a 20 | getConsoleMode(),.$matches)).{.. |
52580 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 61 72 72 61 79 28 28 69 6e 74 | ...............return.array((int |
525a0 | 29 20 24 6d 61 74 63 68 65 73 5b 31 5d 2c 20 28 69 6e 74 29 20 24 6d 61 74 63 68 65 73 5b 32 5d | ).$matches[1],.(int).$matches[2] |
525c0 | 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 | );.............}.........}...... |
525e0 | 20 20 20 20 69 66 20 28 24 73 74 74 79 53 74 72 69 6e 67 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 | ....if.($sttyString.=.$this->get |
52600 | 53 74 74 79 43 6f 6c 75 6d 6e 73 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 | SttyColumns()).{.............//. |
52620 | 65 78 74 72 61 63 74 20 5b 77 2c 20 68 5d 20 66 72 6f 6d 20 22 72 6f 77 73 20 68 3b 20 63 6f 6c | extract.[w,.h].from."rows.h;.col |
52640 | 75 6d 6e 73 20 77 3b 22 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 70 72 65 67 5f 6d 61 | umns.w;".............if.(preg_ma |
52660 | 74 63 68 28 27 2f 72 6f 77 73 2e 28 5c 64 2b 29 3b 2e 63 6f 6c 75 6d 6e 73 2e 28 5c 64 2b 29 3b | tch('/rows.(\d+);.columns.(\d+); |
52680 | 2f 69 27 2c 20 24 73 74 74 79 53 74 72 69 6e 67 2c 20 24 6d 61 74 63 68 65 73 29 29 20 7b 0a 20 | /i',.$sttyString,.$matches)).{.. |
526a0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 61 72 72 61 79 28 28 69 6e 74 | ...............return.array((int |
526c0 | 29 20 24 6d 61 74 63 68 65 73 5b 32 5d 2c 20 28 69 6e 74 29 20 24 6d 61 74 63 68 65 73 5b 31 5d | ).$matches[2],.(int).$matches[1] |
526e0 | 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 | );.............}.............//. |
52700 | 65 78 74 72 61 63 74 20 5b 77 2c 20 68 5d 20 66 72 6f 6d 20 22 3b 20 68 20 72 6f 77 73 3b 20 77 | extract.[w,.h].from.";.h.rows;.w |
52720 | 20 63 6f 6c 75 6d 6e 73 22 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 70 72 65 67 5f 6d | .columns".............if.(preg_m |
52740 | 61 74 63 68 28 27 2f 3b 2e 28 5c 64 2b 29 2e 72 6f 77 73 3b 2e 28 5c 64 2b 29 2e 63 6f 6c 75 6d | atch('/;.(\d+).rows;.(\d+).colum |
52760 | 6e 73 2f 69 27 2c 20 24 73 74 74 79 53 74 72 69 6e 67 2c 20 24 6d 61 74 63 68 65 73 29 29 20 7b | ns/i',.$sttyString,.$matches)).{ |
52780 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 61 72 72 61 79 28 28 69 | .................return.array((i |
527a0 | 6e 74 29 20 24 6d 61 74 63 68 65 73 5b 32 5d 2c 20 28 69 6e 74 29 20 24 6d 61 74 63 68 65 73 5b | nt).$matches[2],.(int).$matches[ |
527c0 | 31 5d 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 | 1]);.............}.........}.... |
527e0 | 20 20 20 20 20 20 72 65 74 75 72 6e 20 61 72 72 61 79 28 6e 75 6c 6c 2c 20 6e 75 6c 6c 29 3b 0a | ......return.array(null,.null);. |
52800 | 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 74 65 72 6d 69 | ....}....../**......*.Sets.termi |
52820 | 6e 61 6c 20 64 69 6d 65 6e 73 69 6f 6e 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 43 61 | nal.dimensions.......*......*.Ca |
52840 | 6e 20 62 65 20 75 73 65 66 75 6c 20 74 6f 20 66 6f 72 63 65 20 74 65 72 6d 69 6e 61 6c 20 64 69 | n.be.useful.to.force.terminal.di |
52860 | 6d 65 6e 73 69 6f 6e 73 20 66 6f 72 20 66 75 6e 63 74 69 6f 6e 61 6c 20 74 65 73 74 73 2e 0a 20 | mensions.for.functional.tests... |
52880 | 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 69 6e 74 20 24 77 69 64 74 68 20 20 | ....*......*.@param.int.$width.. |
528a0 | 54 68 65 20 77 69 64 74 68 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 69 6e 74 20 24 68 65 69 | The.width......*.@param.int.$hei |
528c0 | 67 68 74 20 54 68 65 20 68 65 69 67 68 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 | ght.The.height......*......*.@re |
528e0 | 74 75 72 6e 20 41 70 70 6c 69 63 61 74 69 6f 6e 20 54 68 65 20 63 75 72 72 65 6e 74 20 61 70 70 | turn.Application.The.current.app |
52900 | 6c 69 63 61 74 69 6f 6e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 | lication......*/.....public.func |
52920 | 74 69 6f 6e 20 73 65 74 54 65 72 6d 69 6e 61 6c 44 69 6d 65 6e 73 69 6f 6e 73 28 24 77 69 64 74 | tion.setTerminalDimensions($widt |
52940 | 68 2c 20 24 68 65 69 67 68 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d | h,.$height).....{.........$this- |
52960 | 3e 74 65 72 6d 69 6e 61 6c 44 69 6d 65 6e 73 69 6f 6e 73 20 3d 20 61 72 72 61 79 28 24 77 69 64 | >terminalDimensions.=.array($wid |
52980 | 74 68 2c 20 24 68 65 69 67 68 74 29 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 | th,.$height);..........return.$t |
529a0 | 68 69 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 43 6f 6e 66 69 | his;.....}....../**......*.Confi |
529c0 | 67 75 72 65 73 20 74 68 65 20 69 6e 70 75 74 20 61 6e 64 20 6f 75 74 70 75 74 20 69 6e 73 74 61 | gures.the.input.and.output.insta |
529e0 | 6e 63 65 73 20 62 61 73 65 64 20 6f 6e 20 74 68 65 20 75 73 65 72 20 61 72 67 75 6d 65 6e 74 73 | nces.based.on.the.user.arguments |
52a00 | 20 61 6e 64 20 6f 70 74 69 6f 6e 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 | .and.options.......*......*.@par |
52a20 | 61 6d 20 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 20 20 24 69 6e 70 75 74 20 20 41 6e 20 49 6e | am.InputInterface..$input..An.In |
52a40 | 70 75 74 49 6e 74 65 72 66 61 63 65 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 20 40 70 61 | putInterface.instance......*.@pa |
52a60 | 72 61 6d 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 20 41 6e 20 4f | ram.OutputInterface.$output.An.O |
52a80 | 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 2f 0a | utputInterface.instance......*/. |
52aa0 | 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 63 6f 6e 66 69 67 75 72 65 | ....protected.function.configure |
52ac0 | 49 4f 28 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 69 6e 70 75 74 2c 20 4f 75 74 70 75 74 | IO(InputInterface.$input,.Output |
52ae0 | 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 | Interface.$output).....{........ |
52b00 | 20 69 66 20 28 74 72 75 65 20 3d 3d 3d 20 24 69 6e 70 75 74 2d 3e 68 61 73 50 61 72 61 6d 65 74 | .if.(true.===.$input->hasParamet |
52b20 | 65 72 4f 70 74 69 6f 6e 28 61 72 72 61 79 28 27 2d 2d 61 6e 73 69 27 29 2c 20 74 72 75 65 29 29 | erOption(array('--ansi'),.true)) |
52b40 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 75 74 70 75 74 2d 3e 73 65 74 44 65 63 6f 72 | .{.............$output->setDecor |
52b60 | 61 74 65 64 28 74 72 75 65 29 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 74 72 | ated(true);.........}.elseif.(tr |
52b80 | 75 65 20 3d 3d 3d 20 24 69 6e 70 75 74 2d 3e 68 61 73 50 61 72 61 6d 65 74 65 72 4f 70 74 69 6f | ue.===.$input->hasParameterOptio |
52ba0 | 6e 28 61 72 72 61 79 28 27 2d 2d 6e 6f 2d 61 6e 73 69 27 29 2c 20 74 72 75 65 29 29 20 7b 0a 20 | n(array('--no-ansi'),.true)).{.. |
52bc0 | 20 20 20 20 20 20 20 20 20 20 20 24 6f 75 74 70 75 74 2d 3e 73 65 74 44 65 63 6f 72 61 74 65 64 | ...........$output->setDecorated |
52be0 | 28 66 61 6c 73 65 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 | (false);.........}..........if.( |
52c00 | 74 72 75 65 20 3d 3d 3d 20 24 69 6e 70 75 74 2d 3e 68 61 73 50 61 72 61 6d 65 74 65 72 4f 70 74 | true.===.$input->hasParameterOpt |
52c20 | 69 6f 6e 28 61 72 72 61 79 28 27 2d 2d 6e 6f 2d 69 6e 74 65 72 61 63 74 69 6f 6e 27 2c 20 27 2d | ion(array('--no-interaction',.'- |
52c40 | 6e 27 29 2c 20 74 72 75 65 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 69 6e 70 75 74 | n'),.true)).{.............$input |
52c60 | 2d 3e 73 65 74 49 6e 74 65 72 61 63 74 69 76 65 28 66 61 6c 73 65 29 3b 0a 20 20 20 20 20 20 20 | ->setInteractive(false);........ |
52c80 | 20 7d 20 65 6c 73 65 69 66 20 28 66 75 6e 63 74 69 6f 6e 5f 65 78 69 73 74 73 28 27 70 6f 73 69 | .}.elseif.(function_exists('posi |
52ca0 | 78 5f 69 73 61 74 74 79 27 29 20 26 26 20 24 74 68 69 73 2d 3e 67 65 74 48 65 6c 70 65 72 53 65 | x_isatty').&&.$this->getHelperSe |
52cc0 | 74 28 29 2d 3e 68 61 73 28 27 71 75 65 73 74 69 6f 6e 27 29 29 20 7b 0a 20 20 20 20 20 20 20 20 | t()->has('question')).{......... |
52ce0 | 20 20 20 20 24 69 6e 70 75 74 53 74 72 65 61 6d 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 48 65 6c | ....$inputStream.=.$this->getHel |
52d00 | 70 65 72 53 65 74 28 29 2d 3e 67 65 74 28 27 71 75 65 73 74 69 6f 6e 27 29 2d 3e 67 65 74 49 6e | perSet()->get('question')->getIn |
52d20 | 70 75 74 53 74 72 65 61 6d 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 21 40 70 | putStream();.............if.(!@p |
52d40 | 6f 73 69 78 5f 69 73 61 74 74 79 28 24 69 6e 70 75 74 53 74 72 65 61 6d 29 20 26 26 20 66 61 6c | osix_isatty($inputStream).&&.fal |
52d60 | 73 65 20 3d 3d 3d 20 67 65 74 65 6e 76 28 27 53 48 45 4c 4c 5f 49 4e 54 45 52 41 43 54 49 56 45 | se.===.getenv('SHELL_INTERACTIVE |
52d80 | 27 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 69 6e 70 75 74 2d 3e 73 65 | ')).{.................$input->se |
52da0 | 74 49 6e 74 65 72 61 63 74 69 76 65 28 66 61 6c 73 65 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 | tInteractive(false);............ |
52dc0 | 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 74 72 75 65 20 3d | .}.........}..........if.(true.= |
52de0 | 3d 3d 20 24 69 6e 70 75 74 2d 3e 68 61 73 50 61 72 61 6d 65 74 65 72 4f 70 74 69 6f 6e 28 61 72 | ==.$input->hasParameterOption(ar |
52e00 | 72 61 79 28 27 2d 2d 71 75 69 65 74 27 2c 20 27 2d 71 27 29 2c 20 74 72 75 65 29 29 20 7b 0a 20 | ray('--quiet',.'-q'),.true)).{.. |
52e20 | 20 20 20 20 20 20 20 20 20 20 20 24 6f 75 74 70 75 74 2d 3e 73 65 74 56 65 72 62 6f 73 69 74 79 | ...........$output->setVerbosity |
52e40 | 28 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 3a 3a 56 45 52 42 4f 53 49 54 59 5f 51 55 49 45 | (OutputInterface::VERBOSITY_QUIE |
52e60 | 54 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 69 6e 70 75 74 2d 3e 73 65 74 49 6e 74 65 72 | T);.............$input->setInter |
52e80 | 61 63 74 69 76 65 28 66 61 6c 73 65 29 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a | active(false);.........}.else.{. |
52ea0 | 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 69 6e 70 75 74 2d 3e 68 61 73 50 61 72 61 6d | ............if.($input->hasParam |
52ec0 | 65 74 65 72 4f 70 74 69 6f 6e 28 27 2d 76 76 76 27 2c 20 74 72 75 65 29 20 7c 7c 20 24 69 6e 70 | eterOption('-vvv',.true).||.$inp |
52ee0 | 75 74 2d 3e 68 61 73 50 61 72 61 6d 65 74 65 72 4f 70 74 69 6f 6e 28 27 2d 2d 76 65 72 62 6f 73 | ut->hasParameterOption('--verbos |
52f00 | 65 3d 33 27 2c 20 74 72 75 65 29 20 7c 7c 20 24 69 6e 70 75 74 2d 3e 67 65 74 50 61 72 61 6d 65 | e=3',.true).||.$input->getParame |
52f20 | 74 65 72 4f 70 74 69 6f 6e 28 27 2d 2d 76 65 72 62 6f 73 65 27 2c 20 66 61 6c 73 65 2c 20 74 72 | terOption('--verbose',.false,.tr |
52f40 | 75 65 29 20 3d 3d 3d 20 33 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 75 | ue).===.3).{.................$ou |
52f60 | 74 70 75 74 2d 3e 73 65 74 56 65 72 62 6f 73 69 74 79 28 4f 75 74 70 75 74 49 6e 74 65 72 66 61 | tput->setVerbosity(OutputInterfa |
52f80 | 63 65 3a 3a 56 45 52 42 4f 53 49 54 59 5f 44 45 42 55 47 29 3b 0a 20 20 20 20 20 20 20 20 20 20 | ce::VERBOSITY_DEBUG);........... |
52fa0 | 20 20 7d 20 65 6c 73 65 69 66 20 28 24 69 6e 70 75 74 2d 3e 68 61 73 50 61 72 61 6d 65 74 65 72 | ..}.elseif.($input->hasParameter |
52fc0 | 4f 70 74 69 6f 6e 28 27 2d 76 76 27 2c 20 74 72 75 65 29 20 7c 7c 20 24 69 6e 70 75 74 2d 3e 68 | Option('-vv',.true).||.$input->h |
52fe0 | 61 73 50 61 72 61 6d 65 74 65 72 4f 70 74 69 6f 6e 28 27 2d 2d 76 65 72 62 6f 73 65 3d 32 27 2c | asParameterOption('--verbose=2', |
53000 | 20 74 72 75 65 29 20 7c 7c 20 24 69 6e 70 75 74 2d 3e 67 65 74 50 61 72 61 6d 65 74 65 72 4f 70 | .true).||.$input->getParameterOp |
53020 | 74 69 6f 6e 28 27 2d 2d 76 65 72 62 6f 73 65 27 2c 20 66 61 6c 73 65 2c 20 74 72 75 65 29 20 3d | tion('--verbose',.false,.true).= |
53040 | 3d 3d 20 32 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 75 74 70 75 74 2d | ==.2).{.................$output- |
53060 | 3e 73 65 74 56 65 72 62 6f 73 69 74 79 28 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 3a 3a 56 | >setVerbosity(OutputInterface::V |
53080 | 45 52 42 4f 53 49 54 59 5f 56 45 52 59 5f 56 45 52 42 4f 53 45 29 3b 0a 20 20 20 20 20 20 20 20 | ERBOSITY_VERY_VERBOSE);......... |
530a0 | 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 24 69 6e 70 75 74 2d 3e 68 61 73 50 61 72 61 6d 65 74 | ....}.elseif.($input->hasParamet |
530c0 | 65 72 4f 70 74 69 6f 6e 28 27 2d 76 27 2c 20 74 72 75 65 29 20 7c 7c 20 24 69 6e 70 75 74 2d 3e | erOption('-v',.true).||.$input-> |
530e0 | 68 61 73 50 61 72 61 6d 65 74 65 72 4f 70 74 69 6f 6e 28 27 2d 2d 76 65 72 62 6f 73 65 3d 31 27 | hasParameterOption('--verbose=1' |
53100 | 2c 20 74 72 75 65 29 20 7c 7c 20 24 69 6e 70 75 74 2d 3e 68 61 73 50 61 72 61 6d 65 74 65 72 4f | ,.true).||.$input->hasParameterO |
53120 | 70 74 69 6f 6e 28 27 2d 2d 76 65 72 62 6f 73 65 27 2c 20 74 72 75 65 29 20 7c 7c 20 24 69 6e 70 | ption('--verbose',.true).||.$inp |
53140 | 75 74 2d 3e 67 65 74 50 61 72 61 6d 65 74 65 72 4f 70 74 69 6f 6e 28 27 2d 2d 76 65 72 62 6f 73 | ut->getParameterOption('--verbos |
53160 | 65 27 2c 20 66 61 6c 73 65 2c 20 74 72 75 65 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | e',.false,.true)).{............. |
53180 | 20 20 20 20 24 6f 75 74 70 75 74 2d 3e 73 65 74 56 65 72 62 6f 73 69 74 79 28 4f 75 74 70 75 74 | ....$output->setVerbosity(Output |
531a0 | 49 6e 74 65 72 66 61 63 65 3a 3a 56 45 52 42 4f 53 49 54 59 5f 56 45 52 42 4f 53 45 29 3b 0a 20 | Interface::VERBOSITY_VERBOSE);.. |
531c0 | 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 | ...........}.........}.....}.... |
531e0 | 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 75 6e 73 20 74 68 65 20 63 75 72 72 65 6e 74 20 63 6f | ../**......*.Runs.the.current.co |
53200 | 6d 6d 61 6e 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 49 66 20 61 6e 20 65 76 65 6e 74 | mmand.......*......*.If.an.event |
53220 | 20 64 69 73 70 61 74 63 68 65 72 20 68 61 73 20 62 65 65 6e 20 61 74 74 61 63 68 65 64 20 74 6f | .dispatcher.has.been.attached.to |
53240 | 20 74 68 65 20 61 70 70 6c 69 63 61 74 69 6f 6e 2c 0a 20 20 20 20 20 2a 20 65 76 65 6e 74 73 20 | .the.application,......*.events. |
53260 | 61 72 65 20 61 6c 73 6f 20 64 69 73 70 61 74 63 68 65 64 20 64 75 72 69 6e 67 20 74 68 65 20 6c | are.also.dispatched.during.the.l |
53280 | 69 66 65 2d 63 79 63 6c 65 20 6f 66 20 74 68 65 20 63 6f 6d 6d 61 6e 64 2e 0a 20 20 20 20 20 2a | ife-cycle.of.the.command.......* |
532a0 | 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 43 6f 6d 6d 61 6e 64 20 20 20 20 20 20 20 20 20 24 | ......*.@param.Command.........$ |
532c0 | 63 6f 6d 6d 61 6e 64 20 41 20 43 6f 6d 6d 61 6e 64 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 | command.A.Command.instance...... |
532e0 | 2a 20 40 70 61 72 61 6d 20 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 20 20 24 69 6e 70 75 74 20 | *.@param.InputInterface..$input. |
53300 | 20 20 41 6e 20 49 6e 70 75 74 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 | ..An.Input.instance......*.@para |
53320 | 6d 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 20 20 41 6e 20 4f 75 | m.OutputInterface.$output..An.Ou |
53340 | 74 70 75 74 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 | tput.instance......*......*.@ret |
53360 | 75 72 6e 20 69 6e 74 20 30 20 69 66 20 65 76 65 72 79 74 68 69 6e 67 20 77 65 6e 74 20 66 69 6e | urn.int.0.if.everything.went.fin |
53380 | 65 2c 20 6f 72 20 61 6e 20 65 72 72 6f 72 20 63 6f 64 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 | e,.or.an.error.code......*...... |
533a0 | 2a 20 40 74 68 72 6f 77 73 20 5c 45 78 63 65 70 74 69 6f 6e 20 77 68 65 6e 20 74 68 65 20 63 6f | *.@throws.\Exception.when.the.co |
533c0 | 6d 6d 61 6e 64 20 62 65 69 6e 67 20 72 75 6e 20 74 68 72 65 77 20 61 6e 20 65 78 63 65 70 74 69 | mmand.being.run.threw.an.excepti |
533e0 | 6f 6e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f | on......*/.....protected.functio |
53400 | 6e 20 64 6f 52 75 6e 43 6f 6d 6d 61 6e 64 28 43 6f 6d 6d 61 6e 64 20 24 63 6f 6d 6d 61 6e 64 2c | n.doRunCommand(Command.$command, |
53420 | 20 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 69 6e 70 75 74 2c 20 4f 75 74 70 75 74 49 6e | .InputInterface.$input,.OutputIn |
53440 | 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 66 | terface.$output).....{.........f |
53460 | 6f 72 65 61 63 68 20 28 24 63 6f 6d 6d 61 6e 64 2d 3e 67 65 74 48 65 6c 70 65 72 53 65 74 28 29 | oreach.($command->getHelperSet() |
53480 | 20 61 73 20 24 68 65 6c 70 65 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 | .as.$helper).{.............if.($ |
534a0 | 68 65 6c 70 65 72 20 69 6e 73 74 61 6e 63 65 6f 66 20 49 6e 70 75 74 41 77 61 72 65 49 6e 74 65 | helper.instanceof.InputAwareInte |
534c0 | 72 66 61 63 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 68 65 6c 70 65 72 | rface).{.................$helper |
534e0 | 2d 3e 73 65 74 49 6e 70 75 74 28 24 69 6e 70 75 74 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ->setInput($input);............. |
53500 | 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d | }.........}..........if.(null.== |
53520 | 3d 20 24 74 68 69 73 2d 3e 64 69 73 70 61 74 63 68 65 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | =.$this->dispatcher).{.......... |
53540 | 20 20 20 72 65 74 75 72 6e 20 24 63 6f 6d 6d 61 6e 64 2d 3e 72 75 6e 28 24 69 6e 70 75 74 2c 20 | ...return.$command->run($input,. |
53560 | 24 6f 75 74 70 75 74 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 2f 2f 20 | $output);.........}..........//. |
53580 | 62 69 6e 64 20 62 65 66 6f 72 65 20 74 68 65 20 63 6f 6e 73 6f 6c 65 2e 63 6f 6d 6d 61 6e 64 20 | bind.before.the.console.command. |
535a0 | 65 76 65 6e 74 2c 20 73 6f 20 74 68 65 20 6c 69 73 74 65 6e 65 72 73 20 68 61 76 65 20 61 63 63 | event,.so.the.listeners.have.acc |
535c0 | 65 73 73 20 74 6f 20 69 6e 70 75 74 20 6f 70 74 69 6f 6e 73 2f 61 72 67 75 6d 65 6e 74 73 0a 20 | ess.to.input.options/arguments.. |
535e0 | 20 20 20 20 20 20 20 74 72 79 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6f 6d 6d 61 6e | .......try.{.............$comman |
53600 | 64 2d 3e 6d 65 72 67 65 41 70 70 6c 69 63 61 74 69 6f 6e 44 65 66 69 6e 69 74 69 6f 6e 28 29 3b | d->mergeApplicationDefinition(); |
53620 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 69 6e 70 75 74 2d 3e 62 69 6e 64 28 24 63 6f 6d 6d 61 | .............$input->bind($comma |
53640 | 6e 64 2d 3e 67 65 74 44 65 66 69 6e 69 74 69 6f 6e 28 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 20 | nd->getDefinition());.........}. |
53660 | 63 61 74 63 68 20 28 45 78 63 65 70 74 69 6f 6e 49 6e 74 65 72 66 61 63 65 20 24 65 29 20 7b 0a | catch.(ExceptionInterface.$e).{. |
53680 | 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 69 67 6e 6f 72 65 20 69 6e 76 61 6c 69 64 20 6f 70 | ............//.ignore.invalid.op |
536a0 | 74 69 6f 6e 73 2f 61 72 67 75 6d 65 6e 74 73 20 66 6f 72 20 6e 6f 77 2c 20 74 6f 20 61 6c 6c 6f | tions/arguments.for.now,.to.allo |
536c0 | 77 20 74 68 65 20 65 76 65 6e 74 20 6c 69 73 74 65 6e 65 72 73 20 74 6f 20 63 75 73 74 6f 6d 69 | w.the.event.listeners.to.customi |
536e0 | 7a 65 20 74 68 65 20 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 0a 20 20 20 20 20 20 20 20 7d | ze.the.InputDefinition.........} |
53700 | 0a 0a 20 20 20 20 20 20 20 20 24 65 76 65 6e 74 20 3d 20 6e 65 77 20 43 6f 6e 73 6f 6c 65 43 6f | ..........$event.=.new.ConsoleCo |
53720 | 6d 6d 61 6e 64 45 76 65 6e 74 28 24 63 6f 6d 6d 61 6e 64 2c 20 24 69 6e 70 75 74 2c 20 24 6f 75 | mmandEvent($command,.$input,.$ou |
53740 | 74 70 75 74 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 64 69 73 70 61 74 63 68 65 72 | tput);.........$this->dispatcher |
53760 | 2d 3e 64 69 73 70 61 74 63 68 28 43 6f 6e 73 6f 6c 65 45 76 65 6e 74 73 3a 3a 43 4f 4d 4d 41 4e | ->dispatch(ConsoleEvents::COMMAN |
53780 | 44 2c 20 24 65 76 65 6e 74 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 65 76 65 6e 74 2d | D,.$event);..........if.($event- |
537a0 | 3e 63 6f 6d 6d 61 6e 64 53 68 6f 75 6c 64 52 75 6e 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | >commandShouldRun()).{.......... |
537c0 | 20 20 20 74 72 79 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 65 20 3d 20 6e 75 | ...try.{.................$e.=.nu |
537e0 | 6c 6c 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 65 78 69 74 43 6f 64 65 20 3d 20 | ll;.................$exitCode.=. |
53800 | 24 63 6f 6d 6d 61 6e 64 2d 3e 72 75 6e 28 24 69 6e 70 75 74 2c 20 24 6f 75 74 70 75 74 29 3b 0a | $command->run($input,.$output);. |
53820 | 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 63 61 74 63 68 20 28 5c 45 78 63 65 70 74 69 6f 6e 20 | ............}.catch.(\Exception. |
53840 | 24 78 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 65 20 3d 20 24 78 3b 0a 20 | $x).{.................$e.=.$x;.. |
53860 | 20 20 20 20 20 20 20 20 20 20 20 7d 20 63 61 74 63 68 20 28 5c 54 68 72 6f 77 61 62 6c 65 20 24 | ...........}.catch.(\Throwable.$ |
53880 | 78 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 65 20 3d 20 6e 65 77 20 46 61 | x).{.................$e.=.new.Fa |
538a0 | 74 61 6c 54 68 72 6f 77 61 62 6c 65 45 72 72 6f 72 28 24 78 29 3b 0a 20 20 20 20 20 20 20 20 20 | talThrowableError($x);.......... |
538c0 | 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 21 3d 3d 20 24 65 | ...}.............if.(null.!==.$e |
538e0 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 65 76 65 6e 74 20 3d 20 6e 65 77 | ).{.................$event.=.new |
53900 | 20 43 6f 6e 73 6f 6c 65 45 78 63 65 70 74 69 6f 6e 45 76 65 6e 74 28 24 63 6f 6d 6d 61 6e 64 2c | .ConsoleExceptionEvent($command, |
53920 | 20 24 69 6e 70 75 74 2c 20 24 6f 75 74 70 75 74 2c 20 24 65 2c 20 24 65 2d 3e 67 65 74 43 6f 64 | .$input,.$output,.$e,.$e->getCod |
53940 | 65 28 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 64 69 73 | e());.................$this->dis |
53960 | 70 61 74 63 68 65 72 2d 3e 64 69 73 70 61 74 63 68 28 43 6f 6e 73 6f 6c 65 45 76 65 6e 74 73 3a | patcher->dispatch(ConsoleEvents: |
53980 | 3a 45 58 43 45 50 54 49 4f 4e 2c 20 24 65 76 65 6e 74 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 | :EXCEPTION,.$event);............ |
539a0 | 20 20 20 20 20 20 69 66 20 28 24 65 20 21 3d 3d 20 24 65 76 65 6e 74 2d 3e 67 65 74 45 78 63 65 | ......if.($e.!==.$event->getExce |
539c0 | 70 74 69 6f 6e 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 | ption()).{.....................$ |
539e0 | 78 20 3d 20 24 65 20 3d 20 24 65 76 65 6e 74 2d 3e 67 65 74 45 78 63 65 70 74 69 6f 6e 28 29 3b | x.=.$e.=.$event->getException(); |
53a00 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 | .................}.............. |
53a20 | 20 20 20 20 24 65 76 65 6e 74 20 3d 20 6e 65 77 20 43 6f 6e 73 6f 6c 65 54 65 72 6d 69 6e 61 74 | ....$event.=.new.ConsoleTerminat |
53a40 | 65 45 76 65 6e 74 28 24 63 6f 6d 6d 61 6e 64 2c 20 24 69 6e 70 75 74 2c 20 24 6f 75 74 70 75 74 | eEvent($command,.$input,.$output |
53a60 | 2c 20 24 65 2d 3e 67 65 74 43 6f 64 65 28 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ,.$e->getCode());............... |
53a80 | 20 20 24 74 68 69 73 2d 3e 64 69 73 70 61 74 63 68 65 72 2d 3e 64 69 73 70 61 74 63 68 28 43 6f | ..$this->dispatcher->dispatch(Co |
53aa0 | 6e 73 6f 6c 65 45 76 65 6e 74 73 3a 3a 54 45 52 4d 49 4e 41 54 45 2c 20 24 65 76 65 6e 74 29 3b | nsoleEvents::TERMINATE,.$event); |
53ac0 | 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 24 78 3b 0a 20 20 20 20 | ..................throw.$x;..... |
53ae0 | 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 | ........}.........}.else.{...... |
53b00 | 20 20 20 20 20 20 20 24 65 78 69 74 43 6f 64 65 20 3d 20 43 6f 6e 73 6f 6c 65 43 6f 6d 6d 61 6e | .......$exitCode.=.ConsoleComman |
53b20 | 64 45 76 65 6e 74 3a 3a 52 45 54 55 52 4e 5f 43 4f 44 45 5f 44 49 53 41 42 4c 45 44 3b 0a 20 20 | dEvent::RETURN_CODE_DISABLED;... |
53b40 | 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 65 76 65 6e 74 20 3d 20 6e 65 77 20 43 6f | ......}..........$event.=.new.Co |
53b60 | 6e 73 6f 6c 65 54 65 72 6d 69 6e 61 74 65 45 76 65 6e 74 28 24 63 6f 6d 6d 61 6e 64 2c 20 24 69 | nsoleTerminateEvent($command,.$i |
53b80 | 6e 70 75 74 2c 20 24 6f 75 74 70 75 74 2c 20 24 65 78 69 74 43 6f 64 65 29 3b 0a 20 20 20 20 20 | nput,.$output,.$exitCode);...... |
53ba0 | 20 20 20 24 74 68 69 73 2d 3e 64 69 73 70 61 74 63 68 65 72 2d 3e 64 69 73 70 61 74 63 68 28 43 | ...$this->dispatcher->dispatch(C |
53bc0 | 6f 6e 73 6f 6c 65 45 76 65 6e 74 73 3a 3a 54 45 52 4d 49 4e 41 54 45 2c 20 24 65 76 65 6e 74 29 | onsoleEvents::TERMINATE,.$event) |
53be0 | 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 65 76 65 6e 74 2d 3e 67 65 74 45 78 69 | ;..........return.$event->getExi |
53c00 | 74 43 6f 64 65 28 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 | tCode();.....}....../**......*.G |
53c20 | 65 74 73 20 74 68 65 20 6e 61 6d 65 20 6f 66 20 74 68 65 20 63 6f 6d 6d 61 6e 64 20 62 61 73 65 | ets.the.name.of.the.command.base |
53c40 | 64 20 6f 6e 20 69 6e 70 75 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d | d.on.input.......*......*.@param |
53c60 | 20 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 69 6e 70 75 74 20 54 68 65 20 69 6e 70 75 74 | .InputInterface.$input.The.input |
53c80 | 20 69 6e 74 65 72 66 61 63 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e | .interface......*......*.@return |
53ca0 | 20 73 74 72 69 6e 67 20 54 68 65 20 63 6f 6d 6d 61 6e 64 20 6e 61 6d 65 0a 20 20 20 20 20 2a 2f | .string.The.command.name......*/ |
53cc0 | 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 43 6f 6d 6d 61 | .....protected.function.getComma |
53ce0 | 6e 64 4e 61 6d 65 28 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 69 6e 70 75 74 29 0a 20 20 | ndName(InputInterface.$input)... |
53d00 | 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 69 6e 70 75 74 2d 3e 67 65 74 46 69 | ..{.........return.$input->getFi |
53d20 | 72 73 74 41 72 67 75 6d 65 6e 74 28 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 | rstArgument();.....}....../**... |
53d40 | 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 64 65 66 61 75 6c 74 20 69 6e 70 75 74 20 64 65 66 69 | ...*.Gets.the.default.input.defi |
53d60 | 6e 69 74 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 49 6e | nition.......*......*.@return.In |
53d80 | 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 20 41 6e 20 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e | putDefinition.An.InputDefinition |
53da0 | 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 | .instance......*/.....protected. |
53dc0 | 66 75 6e 63 74 69 6f 6e 20 67 65 74 44 65 66 61 75 6c 74 49 6e 70 75 74 44 65 66 69 6e 69 74 69 | function.getDefaultInputDefiniti |
53de0 | 6f 6e 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6e 65 77 20 49 6e | on().....{.........return.new.In |
53e00 | 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 28 61 72 72 61 79 28 0a 20 20 20 20 20 20 20 20 20 20 20 | putDefinition(array(............ |
53e20 | 20 6e 65 77 20 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 28 27 63 6f 6d 6d 61 6e 64 27 2c 20 49 6e | .new.InputArgument('command',.In |
53e40 | 70 75 74 41 72 67 75 6d 65 6e 74 3a 3a 52 45 51 55 49 52 45 44 2c 20 27 54 68 65 20 63 6f 6d 6d | putArgument::REQUIRED,.'The.comm |
53e60 | 61 6e 64 20 74 6f 20 65 78 65 63 75 74 65 27 29 2c 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 6e | and.to.execute'),..............n |
53e80 | 65 77 20 49 6e 70 75 74 4f 70 74 69 6f 6e 28 27 2d 2d 68 65 6c 70 27 2c 20 27 2d 68 27 2c 20 49 | ew.InputOption('--help',.'-h',.I |
53ea0 | 6e 70 75 74 4f 70 74 69 6f 6e 3a 3a 56 41 4c 55 45 5f 4e 4f 4e 45 2c 20 27 44 69 73 70 6c 61 79 | nputOption::VALUE_NONE,.'Display |
53ec0 | 20 74 68 69 73 20 68 65 6c 70 20 6d 65 73 73 61 67 65 27 29 2c 0a 20 20 20 20 20 20 20 20 20 20 | .this.help.message'),........... |
53ee0 | 20 20 6e 65 77 20 49 6e 70 75 74 4f 70 74 69 6f 6e 28 27 2d 2d 71 75 69 65 74 27 2c 20 27 2d 71 | ..new.InputOption('--quiet',.'-q |
53f00 | 27 2c 20 49 6e 70 75 74 4f 70 74 69 6f 6e 3a 3a 56 41 4c 55 45 5f 4e 4f 4e 45 2c 20 27 44 6f 20 | ',.InputOption::VALUE_NONE,.'Do. |
53f20 | 6e 6f 74 20 6f 75 74 70 75 74 20 61 6e 79 20 6d 65 73 73 61 67 65 27 29 2c 0a 20 20 20 20 20 20 | not.output.any.message'),....... |
53f40 | 20 20 20 20 20 20 6e 65 77 20 49 6e 70 75 74 4f 70 74 69 6f 6e 28 27 2d 2d 76 65 72 62 6f 73 65 | ......new.InputOption('--verbose |
53f60 | 27 2c 20 27 2d 76 7c 76 76 7c 76 76 76 27 2c 20 49 6e 70 75 74 4f 70 74 69 6f 6e 3a 3a 56 41 4c | ',.'-v|vv|vvv',.InputOption::VAL |
53f80 | 55 45 5f 4e 4f 4e 45 2c 20 27 49 6e 63 72 65 61 73 65 20 74 68 65 20 76 65 72 62 6f 73 69 74 79 | UE_NONE,.'Increase.the.verbosity |
53fa0 | 20 6f 66 20 6d 65 73 73 61 67 65 73 3a 20 31 20 66 6f 72 20 6e 6f 72 6d 61 6c 20 6f 75 74 70 75 | .of.messages:.1.for.normal.outpu |
53fc0 | 74 2c 20 32 20 66 6f 72 20 6d 6f 72 65 20 76 65 72 62 6f 73 65 20 6f 75 74 70 75 74 20 61 6e 64 | t,.2.for.more.verbose.output.and |
53fe0 | 20 33 20 66 6f 72 20 64 65 62 75 67 27 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 6e 65 77 20 | .3.for.debug'),.............new. |
54000 | 49 6e 70 75 74 4f 70 74 69 6f 6e 28 27 2d 2d 76 65 72 73 69 6f 6e 27 2c 20 27 2d 56 27 2c 20 49 | InputOption('--version',.'-V',.I |
54020 | 6e 70 75 74 4f 70 74 69 6f 6e 3a 3a 56 41 4c 55 45 5f 4e 4f 4e 45 2c 20 27 44 69 73 70 6c 61 79 | nputOption::VALUE_NONE,.'Display |
54040 | 20 74 68 69 73 20 61 70 70 6c 69 63 61 74 69 6f 6e 20 76 65 72 73 69 6f 6e 27 29 2c 0a 20 20 20 | .this.application.version'),.... |
54060 | 20 20 20 20 20 20 20 20 20 6e 65 77 20 49 6e 70 75 74 4f 70 74 69 6f 6e 28 27 2d 2d 61 6e 73 69 | .........new.InputOption('--ansi |
54080 | 27 2c 20 27 27 2c 20 49 6e 70 75 74 4f 70 74 69 6f 6e 3a 3a 56 41 4c 55 45 5f 4e 4f 4e 45 2c 20 | ',.'',.InputOption::VALUE_NONE,. |
540a0 | 27 46 6f 72 63 65 20 41 4e 53 49 20 6f 75 74 70 75 74 27 29 2c 0a 20 20 20 20 20 20 20 20 20 20 | 'Force.ANSI.output'),........... |
540c0 | 20 20 6e 65 77 20 49 6e 70 75 74 4f 70 74 69 6f 6e 28 27 2d 2d 6e 6f 2d 61 6e 73 69 27 2c 20 27 | ..new.InputOption('--no-ansi',.' |
540e0 | 27 2c 20 49 6e 70 75 74 4f 70 74 69 6f 6e 3a 3a 56 41 4c 55 45 5f 4e 4f 4e 45 2c 20 27 44 69 73 | ',.InputOption::VALUE_NONE,.'Dis |
54100 | 61 62 6c 65 20 41 4e 53 49 20 6f 75 74 70 75 74 27 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 | able.ANSI.output'),............. |
54120 | 6e 65 77 20 49 6e 70 75 74 4f 70 74 69 6f 6e 28 27 2d 2d 6e 6f 2d 69 6e 74 65 72 61 63 74 69 6f | new.InputOption('--no-interactio |
54140 | 6e 27 2c 20 27 2d 6e 27 2c 20 49 6e 70 75 74 4f 70 74 69 6f 6e 3a 3a 56 41 4c 55 45 5f 4e 4f 4e | n',.'-n',.InputOption::VALUE_NON |
54160 | 45 2c 20 27 44 6f 20 6e 6f 74 20 61 73 6b 20 61 6e 79 20 69 6e 74 65 72 61 63 74 69 76 65 20 71 | E,.'Do.not.ask.any.interactive.q |
54180 | 75 65 73 74 69 6f 6e 27 29 2c 0a 20 20 20 20 20 20 20 20 29 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 | uestion'),.........));.....}.... |
541a0 | 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 64 65 66 61 75 6c 74 20 63 6f | ../**......*.Gets.the.default.co |
541c0 | 6d 6d 61 6e 64 73 20 74 68 61 74 20 73 68 6f 75 6c 64 20 61 6c 77 61 79 73 20 62 65 20 61 76 61 | mmands.that.should.always.be.ava |
541e0 | 69 6c 61 62 6c 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 43 6f | ilable.......*......*.@return.Co |
54200 | 6d 6d 61 6e 64 5b 5d 20 41 6e 20 61 72 72 61 79 20 6f 66 20 64 65 66 61 75 6c 74 20 43 6f 6d 6d | mmand[].An.array.of.default.Comm |
54220 | 61 6e 64 20 69 6e 73 74 61 6e 63 65 73 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 6f 74 65 63 | and.instances......*/.....protec |
54240 | 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 44 65 66 61 75 6c 74 43 6f 6d 6d 61 6e 64 73 28 | ted.function.getDefaultCommands( |
54260 | 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 61 72 72 61 79 28 6e 65 77 | ).....{.........return.array(new |
54280 | 20 48 65 6c 70 43 6f 6d 6d 61 6e 64 28 29 2c 20 6e 65 77 20 4c 69 73 74 43 6f 6d 6d 61 6e 64 28 | .HelpCommand(),.new.ListCommand( |
542a0 | 29 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 | ));.....}....../**......*.Gets.t |
542c0 | 68 65 20 64 65 66 61 75 6c 74 20 68 65 6c 70 65 72 20 73 65 74 20 77 69 74 68 20 74 68 65 20 68 | he.default.helper.set.with.the.h |
542e0 | 65 6c 70 65 72 73 20 74 68 61 74 20 73 68 6f 75 6c 64 20 61 6c 77 61 79 73 20 62 65 20 61 76 61 | elpers.that.should.always.be.ava |
54300 | 69 6c 61 62 6c 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 48 65 | ilable.......*......*.@return.He |
54320 | 6c 70 65 72 53 65 74 20 41 20 48 65 6c 70 65 72 53 65 74 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 | lperSet.A.HelperSet.instance.... |
54340 | 20 20 2a 2f 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 44 | ..*/.....protected.function.getD |
54360 | 65 66 61 75 6c 74 48 65 6c 70 65 72 53 65 74 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | efaultHelperSet().....{......... |
54380 | 72 65 74 75 72 6e 20 6e 65 77 20 48 65 6c 70 65 72 53 65 74 28 61 72 72 61 79 28 0a 20 20 20 20 | return.new.HelperSet(array(..... |
543a0 | 20 20 20 20 20 20 20 20 6e 65 77 20 46 6f 72 6d 61 74 74 65 72 48 65 6c 70 65 72 28 29 2c 0a 20 | ........new.FormatterHelper(),.. |
543c0 | 20 20 20 20 20 20 20 20 20 20 20 6e 65 77 20 44 65 62 75 67 46 6f 72 6d 61 74 74 65 72 48 65 6c | ...........new.DebugFormatterHel |
543e0 | 70 65 72 28 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 6e 65 77 20 50 72 6f 63 65 73 73 48 65 | per(),.............new.ProcessHe |
54400 | 6c 70 65 72 28 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 6e 65 77 20 51 75 65 73 74 69 6f 6e | lper(),.............new.Question |
54420 | 48 65 6c 70 65 72 28 29 2c 0a 20 20 20 20 20 20 20 20 29 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 | Helper(),.........));.....}..... |
54440 | 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 75 6e 73 20 61 6e 64 20 70 61 72 73 65 73 20 73 74 74 79 | ./**......*.Runs.and.parses.stty |
54460 | 20 2d 61 20 69 66 20 69 74 27 73 20 61 76 61 69 6c 61 62 6c 65 2c 20 73 75 70 70 72 65 73 73 69 | .-a.if.it's.available,.suppressi |
54480 | 6e 67 20 61 6e 79 20 65 72 72 6f 72 20 6f 75 74 70 75 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 | ng.any.error.output.......*..... |
544a0 | 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 | .*.@return.string......*/.....pr |
544c0 | 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 53 74 74 79 43 6f 6c 75 6d 6e 73 28 29 0a | ivate.function.getSttyColumns(). |
544e0 | 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 66 75 6e 63 74 69 6f 6e 5f 65 78 69 73 | ....{.........if.(!function_exis |
54500 | 74 73 28 27 70 72 6f 63 5f 6f 70 65 6e 27 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 | ts('proc_open')).{.............r |
54520 | 65 74 75 72 6e 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 64 65 73 63 72 | eturn;.........}..........$descr |
54540 | 69 70 74 6f 72 73 70 65 63 20 3d 20 61 72 72 61 79 28 31 20 3d 3e 20 61 72 72 61 79 28 27 70 69 | iptorspec.=.array(1.=>.array('pi |
54560 | 70 65 27 2c 20 27 77 27 29 2c 20 32 20 3d 3e 20 61 72 72 61 79 28 27 70 69 70 65 27 2c 20 27 77 | pe',.'w'),.2.=>.array('pipe',.'w |
54580 | 27 29 29 3b 0a 20 20 20 20 20 20 20 20 24 70 72 6f 63 65 73 73 20 3d 20 70 72 6f 63 5f 6f 70 65 | '));.........$process.=.proc_ope |
545a0 | 6e 28 27 73 74 74 79 20 2d 61 20 7c 20 67 72 65 70 20 63 6f 6c 75 6d 6e 73 27 2c 20 24 64 65 73 | n('stty.-a.|.grep.columns',.$des |
545c0 | 63 72 69 70 74 6f 72 73 70 65 63 2c 20 24 70 69 70 65 73 2c 20 6e 75 6c 6c 2c 20 6e 75 6c 6c 2c | criptorspec,.$pipes,.null,.null, |
545e0 | 20 61 72 72 61 79 28 27 73 75 70 70 72 65 73 73 5f 65 72 72 6f 72 73 27 20 3d 3e 20 74 72 75 65 | .array('suppress_errors'.=>.true |
54600 | 29 29 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 69 73 5f 72 65 73 6f 75 72 63 65 28 24 70 72 6f | ));.........if.(is_resource($pro |
54620 | 63 65 73 73 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 69 6e 66 6f 20 3d 20 73 74 72 | cess)).{.............$info.=.str |
54640 | 65 61 6d 5f 67 65 74 5f 63 6f 6e 74 65 6e 74 73 28 24 70 69 70 65 73 5b 31 5d 29 3b 0a 20 20 20 | eam_get_contents($pipes[1]);.... |
54660 | 20 20 20 20 20 20 20 20 20 66 63 6c 6f 73 65 28 24 70 69 70 65 73 5b 31 5d 29 3b 0a 20 20 20 20 | .........fclose($pipes[1]);..... |
54680 | 20 20 20 20 20 20 20 20 66 63 6c 6f 73 65 28 24 70 69 70 65 73 5b 32 5d 29 3b 0a 20 20 20 20 20 | ........fclose($pipes[2]);...... |
546a0 | 20 20 20 20 20 20 20 70 72 6f 63 5f 63 6c 6f 73 65 28 24 70 72 6f 63 65 73 73 29 3b 0a 0a 20 20 | .......proc_close($process);.... |
546c0 | 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 69 6e 66 6f 3b 0a 20 20 20 20 20 20 20 20 | ..........return.$info;......... |
546e0 | 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 75 6e 73 20 61 6e 64 | }.....}....../**......*.Runs.and |
54700 | 20 70 61 72 73 65 73 20 6d 6f 64 65 20 43 4f 4e 20 69 66 20 69 74 27 73 20 61 76 61 69 6c 61 62 | .parses.mode.CON.if.it's.availab |
54720 | 6c 65 2c 20 73 75 70 70 72 65 73 73 69 6e 67 20 61 6e 79 20 65 72 72 6f 72 20 6f 75 74 70 75 74 | le,.suppressing.any.error.output |
54740 | 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 7c 6e | .......*......*.@return.string|n |
54760 | 75 6c 6c 20 3c 77 69 64 74 68 3e 78 3c 68 65 69 67 68 74 3e 20 6f 72 20 6e 75 6c 6c 20 69 66 20 | ull.<width>x<height>.or.null.if. |
54780 | 69 74 20 63 6f 75 6c 64 20 6e 6f 74 20 62 65 20 70 61 72 73 65 64 0a 20 20 20 20 20 2a 2f 0a 20 | it.could.not.be.parsed......*/.. |
547a0 | 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 43 6f 6e 73 6f 6c 65 4d 6f | ...private.function.getConsoleMo |
547c0 | 64 65 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 66 75 6e 63 74 69 6f 6e | de().....{.........if.(!function |
547e0 | 5f 65 78 69 73 74 73 28 27 70 72 6f 63 5f 6f 70 65 6e 27 29 29 20 7b 0a 20 20 20 20 20 20 20 20 | _exists('proc_open')).{......... |
54800 | 20 20 20 20 72 65 74 75 72 6e 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 | ....return;.........}..........$ |
54820 | 64 65 73 63 72 69 70 74 6f 72 73 70 65 63 20 3d 20 61 72 72 61 79 28 31 20 3d 3e 20 61 72 72 61 | descriptorspec.=.array(1.=>.arra |
54840 | 79 28 27 70 69 70 65 27 2c 20 27 77 27 29 2c 20 32 20 3d 3e 20 61 72 72 61 79 28 27 70 69 70 65 | y('pipe',.'w'),.2.=>.array('pipe |
54860 | 27 2c 20 27 77 27 29 29 3b 0a 20 20 20 20 20 20 20 20 24 70 72 6f 63 65 73 73 20 3d 20 70 72 6f | ',.'w'));.........$process.=.pro |
54880 | 63 5f 6f 70 65 6e 28 27 6d 6f 64 65 20 43 4f 4e 27 2c 20 24 64 65 73 63 72 69 70 74 6f 72 73 70 | c_open('mode.CON',.$descriptorsp |
548a0 | 65 63 2c 20 24 70 69 70 65 73 2c 20 6e 75 6c 6c 2c 20 6e 75 6c 6c 2c 20 61 72 72 61 79 28 27 73 | ec,.$pipes,.null,.null,.array('s |
548c0 | 75 70 70 72 65 73 73 5f 65 72 72 6f 72 73 27 20 3d 3e 20 74 72 75 65 29 29 3b 0a 20 20 20 20 20 | uppress_errors'.=>.true));...... |
548e0 | 20 20 20 69 66 20 28 69 73 5f 72 65 73 6f 75 72 63 65 28 24 70 72 6f 63 65 73 73 29 29 20 7b 0a | ...if.(is_resource($process)).{. |
54900 | 20 20 20 20 20 20 20 20 20 20 20 20 24 69 6e 66 6f 20 3d 20 73 74 72 65 61 6d 5f 67 65 74 5f 63 | ............$info.=.stream_get_c |
54920 | 6f 6e 74 65 6e 74 73 28 24 70 69 70 65 73 5b 31 5d 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ontents($pipes[1]);............. |
54940 | 66 63 6c 6f 73 65 28 24 70 69 70 65 73 5b 31 5d 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 66 | fclose($pipes[1]);.............f |
54960 | 63 6c 6f 73 65 28 24 70 69 70 65 73 5b 32 5d 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 70 72 | close($pipes[2]);.............pr |
54980 | 6f 63 5f 63 6c 6f 73 65 28 24 70 72 6f 63 65 73 73 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 | oc_close($process);............. |
549a0 | 20 69 66 20 28 70 72 65 67 5f 6d 61 74 63 68 28 27 2f 2d 2d 2d 2d 2d 2d 2d 2d 2b 5c 72 3f 5c 6e | .if.(preg_match('/--------+\r?\n |
549c0 | 2e 2b 3f 28 5c 64 2b 29 5c 72 3f 5c 6e 2e 2b 3f 28 5c 64 2b 29 5c 72 3f 5c 6e 2f 27 2c 20 24 69 | .+?(\d+)\r?\n.+?(\d+)\r?\n/',.$i |
549e0 | 6e 66 6f 2c 20 24 6d 61 74 63 68 65 73 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | nfo,.$matches)).{............... |
54a00 | 20 20 72 65 74 75 72 6e 20 24 6d 61 74 63 68 65 73 5b 32 5d 2e 27 78 27 2e 24 6d 61 74 63 68 65 | ..return.$matches[2].'x'.$matche |
54a20 | 73 5b 31 5d 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 | s[1];.............}.........}... |
54a40 | 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 61 62 62 72 | ..}....../**......*.Returns.abbr |
54a60 | 65 76 69 61 74 65 64 20 73 75 67 67 65 73 74 69 6f 6e 73 20 69 6e 20 73 74 72 69 6e 67 20 66 6f | eviated.suggestions.in.string.fo |
54a80 | 72 6d 61 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 | rmat.......*......*.@param.array |
54aa0 | 20 24 61 62 62 72 65 76 73 20 41 62 62 72 65 76 69 61 74 65 64 20 73 75 67 67 65 73 74 69 6f 6e | .$abbrevs.Abbreviated.suggestion |
54ac0 | 73 20 74 6f 20 63 6f 6e 76 65 72 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 | s.to.convert......*......*.@retu |
54ae0 | 72 6e 20 73 74 72 69 6e 67 20 41 20 66 6f 72 6d 61 74 74 65 64 20 73 74 72 69 6e 67 20 6f 66 20 | rn.string.A.formatted.string.of. |
54b00 | 61 62 62 72 65 76 69 61 74 65 64 20 73 75 67 67 65 73 74 69 6f 6e 73 0a 20 20 20 20 20 2a 2f 0a | abbreviated.suggestions......*/. |
54b20 | 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 41 62 62 72 65 76 69 61 | ....private.function.getAbbrevia |
54b40 | 74 69 6f 6e 53 75 67 67 65 73 74 69 6f 6e 73 28 24 61 62 62 72 65 76 73 29 0a 20 20 20 20 7b 0a | tionSuggestions($abbrevs).....{. |
54b60 | 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 70 72 69 6e 74 66 28 27 25 73 2c 20 25 73 25 73 | ........return.sprintf('%s,.%s%s |
54b80 | 27 2c 20 24 61 62 62 72 65 76 73 5b 30 5d 2c 20 24 61 62 62 72 65 76 73 5b 31 5d 2c 20 63 6f 75 | ',.$abbrevs[0],.$abbrevs[1],.cou |
54ba0 | 6e 74 28 24 61 62 62 72 65 76 73 29 20 3e 20 32 20 3f 20 73 70 72 69 6e 74 66 28 27 20 61 6e 64 | nt($abbrevs).>.2.?.sprintf('.and |
54bc0 | 20 25 64 20 6d 6f 72 65 27 2c 20 63 6f 75 6e 74 28 24 61 62 62 72 65 76 73 29 20 2d 20 32 29 20 | .%d.more',.count($abbrevs).-.2). |
54be0 | 3a 20 27 27 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 | :.'');.....}....../**......*.Ret |
54c00 | 75 72 6e 73 20 74 68 65 20 6e 61 6d 65 73 70 61 63 65 20 70 61 72 74 20 6f 66 20 74 68 65 20 63 | urns.the.namespace.part.of.the.c |
54c20 | 6f 6d 6d 61 6e 64 20 6e 61 6d 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 54 68 69 73 20 | ommand.name.......*......*.This. |
54c40 | 6d 65 74 68 6f 64 20 69 73 20 6e 6f 74 20 70 61 72 74 20 6f 66 20 70 75 62 6c 69 63 20 41 50 49 | method.is.not.part.of.public.API |
54c60 | 20 61 6e 64 20 73 68 6f 75 6c 64 20 6e 6f 74 20 62 65 20 75 73 65 64 20 64 69 72 65 63 74 6c 79 | .and.should.not.be.used.directly |
54c80 | 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6e | .......*......*.@param.string.$n |
54ca0 | 61 6d 65 20 20 54 68 65 20 66 75 6c 6c 20 6e 61 6d 65 20 6f 66 20 74 68 65 20 63 6f 6d 6d 61 6e | ame..The.full.name.of.the.comman |
54cc0 | 64 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6c 69 6d 69 74 20 54 68 | d......*.@param.string.$limit.Th |
54ce0 | 65 20 6d 61 78 69 6d 75 6d 20 6e 75 6d 62 65 72 20 6f 66 20 70 61 72 74 73 20 6f 66 20 74 68 65 | e.maximum.number.of.parts.of.the |
54d00 | 20 6e 61 6d 65 73 70 61 63 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e | .namespace......*......*.@return |
54d20 | 20 73 74 72 69 6e 67 20 54 68 65 20 6e 61 6d 65 73 70 61 63 65 20 6f 66 20 74 68 65 20 63 6f 6d | .string.The.namespace.of.the.com |
54d40 | 6d 61 6e 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e | mand......*/.....public.function |
54d60 | 20 65 78 74 72 61 63 74 4e 61 6d 65 73 70 61 63 65 28 24 6e 61 6d 65 2c 20 24 6c 69 6d 69 74 20 | .extractNamespace($name,.$limit. |
54d80 | 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 70 61 72 74 73 20 3d 20 65 | =.null).....{.........$parts.=.e |
54da0 | 78 70 6c 6f 64 65 28 27 3a 27 2c 20 24 6e 61 6d 65 29 3b 0a 20 20 20 20 20 20 20 20 61 72 72 61 | xplode(':',.$name);.........arra |
54dc0 | 79 5f 70 6f 70 28 24 70 61 72 74 73 29 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 69 | y_pop($parts);..........return.i |
54de0 | 6d 70 6c 6f 64 65 28 27 3a 27 2c 20 6e 75 6c 6c 20 3d 3d 3d 20 24 6c 69 6d 69 74 20 3f 20 24 70 | mplode(':',.null.===.$limit.?.$p |
54e00 | 61 72 74 73 20 3a 20 61 72 72 61 79 5f 73 6c 69 63 65 28 24 70 61 72 74 73 2c 20 30 2c 20 24 6c | arts.:.array_slice($parts,.0,.$l |
54e20 | 69 6d 69 74 29 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 46 69 | imit));.....}....../**......*.Fi |
54e40 | 6e 64 73 20 61 6c 74 65 72 6e 61 74 69 76 65 20 6f 66 20 24 6e 61 6d 65 20 61 6d 6f 6e 67 20 24 | nds.alternative.of.$name.among.$ |
54e60 | 63 6f 6c 6c 65 63 74 69 6f 6e 2c 0a 20 20 20 20 20 2a 20 69 66 20 6e 6f 74 68 69 6e 67 20 69 73 | collection,......*.if.nothing.is |
54e80 | 20 66 6f 75 6e 64 20 69 6e 20 24 63 6f 6c 6c 65 63 74 69 6f 6e 2c 20 74 72 79 20 69 6e 20 24 61 | .found.in.$collection,.try.in.$a |
54ea0 | 62 62 72 65 76 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 | bbrevs.......*......*.@param.str |
54ec0 | 69 6e 67 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6e 61 6d 65 20 20 20 20 20 20 20 54 68 65 20 | ing.............$name.......The. |
54ee0 | 73 74 72 69 6e 67 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 7c 5c 54 72 61 76 | string......*.@param.array|\Trav |
54f00 | 65 72 73 61 62 6c 65 20 24 63 6f 6c 6c 65 63 74 69 6f 6e 20 54 68 65 20 63 6f 6c 6c 65 63 74 69 | ersable.$collection.The.collecti |
54f20 | 6f 6e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 5b | on......*......*.@return.string[ |
54f40 | 5d 20 41 20 73 6f 72 74 65 64 20 61 72 72 61 79 20 6f 66 20 73 69 6d 69 6c 61 72 20 73 74 72 69 | ].A.sorted.array.of.similar.stri |
54f60 | 6e 67 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 | ng......*/.....private.function. |
54f80 | 66 69 6e 64 41 6c 74 65 72 6e 61 74 69 76 65 73 28 24 6e 61 6d 65 2c 20 24 63 6f 6c 6c 65 63 74 | findAlternatives($name,.$collect |
54fa0 | 69 6f 6e 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 72 65 73 68 6f 6c 64 20 3d 20 | ion).....{.........$threshold.=. |
54fc0 | 31 65 33 3b 0a 20 20 20 20 20 20 20 20 24 61 6c 74 65 72 6e 61 74 69 76 65 73 20 3d 20 61 72 72 | 1e3;.........$alternatives.=.arr |
54fe0 | 61 79 28 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 63 6f 6c 6c 65 63 74 69 6f 6e 50 61 72 74 73 20 | ay();..........$collectionParts. |
55000 | 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 63 6f 6c | =.array();.........foreach.($col |
55020 | 6c 65 63 74 69 6f 6e 20 61 73 20 24 69 74 65 6d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | lection.as.$item).{............. |
55040 | 24 63 6f 6c 6c 65 63 74 69 6f 6e 50 61 72 74 73 5b 24 69 74 65 6d 5d 20 3d 20 65 78 70 6c 6f 64 | $collectionParts[$item].=.explod |
55060 | 65 28 27 3a 27 2c 20 24 69 74 65 6d 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 | e(':',.$item);.........}........ |
55080 | 20 20 66 6f 72 65 61 63 68 20 28 65 78 70 6c 6f 64 65 28 27 3a 27 2c 20 24 6e 61 6d 65 29 20 61 | ..foreach.(explode(':',.$name).a |
550a0 | 73 20 24 69 20 3d 3e 20 24 73 75 62 6e 61 6d 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | s.$i.=>.$subname).{............. |
550c0 | 66 6f 72 65 61 63 68 20 28 24 63 6f 6c 6c 65 63 74 69 6f 6e 50 61 72 74 73 20 61 73 20 24 63 6f | foreach.($collectionParts.as.$co |
550e0 | 6c 6c 65 63 74 69 6f 6e 4e 61 6d 65 20 3d 3e 20 24 70 61 72 74 73 29 20 7b 0a 20 20 20 20 20 20 | llectionName.=>.$parts).{....... |
55100 | 20 20 20 20 20 20 20 20 20 20 24 65 78 69 73 74 73 20 3d 20 69 73 73 65 74 28 24 61 6c 74 65 72 | ..........$exists.=.isset($alter |
55120 | 6e 61 74 69 76 65 73 5b 24 63 6f 6c 6c 65 63 74 69 6f 6e 4e 61 6d 65 5d 29 3b 0a 20 20 20 20 20 | natives[$collectionName]);...... |
55140 | 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 21 69 73 73 65 74 28 24 70 61 72 74 73 5b 24 69 5d | ...........if.(!isset($parts[$i] |
55160 | 29 20 26 26 20 24 65 78 69 73 74 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ).&&.$exists).{................. |
55180 | 20 20 20 20 24 61 6c 74 65 72 6e 61 74 69 76 65 73 5b 24 63 6f 6c 6c 65 63 74 69 6f 6e 4e 61 6d | ....$alternatives[$collectionNam |
551a0 | 65 5d 20 2b 3d 20 24 74 68 72 65 73 68 6f 6c 64 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | e].+=.$threshold;............... |
551c0 | 20 20 20 20 20 20 63 6f 6e 74 69 6e 75 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ......continue;................. |
551e0 | 7d 20 65 6c 73 65 69 66 20 28 21 69 73 73 65 74 28 24 70 61 72 74 73 5b 24 69 5d 29 29 20 7b 0a | }.elseif.(!isset($parts[$i])).{. |
55200 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 63 6f 6e 74 69 6e 75 65 3b 0a 20 20 | ....................continue;... |
55220 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ..............}................. |
55240 | 20 24 6c 65 76 20 3d 20 6c 65 76 65 6e 73 68 74 65 69 6e 28 24 73 75 62 6e 61 6d 65 2c 20 24 70 | .$lev.=.levenshtein($subname,.$p |
55260 | 61 72 74 73 5b 24 69 5d 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 | arts[$i]);.................if.($ |
55280 | 6c 65 76 20 3c 3d 20 73 74 72 6c 65 6e 28 24 73 75 62 6e 61 6d 65 29 20 2f 20 33 20 7c 7c 20 27 | lev.<=.strlen($subname)./.3.||.' |
552a0 | 27 20 21 3d 3d 20 24 73 75 62 6e 61 6d 65 20 26 26 20 66 61 6c 73 65 20 21 3d 3d 20 73 74 72 70 | '.!==.$subname.&&.false.!==.strp |
552c0 | 6f 73 28 24 70 61 72 74 73 5b 24 69 5d 2c 20 24 73 75 62 6e 61 6d 65 29 29 20 7b 0a 20 20 20 20 | os($parts[$i],.$subname)).{..... |
552e0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 61 6c 74 65 72 6e 61 74 69 76 65 73 5b 24 63 | ................$alternatives[$c |
55300 | 6f 6c 6c 65 63 74 69 6f 6e 4e 61 6d 65 5d 20 3d 20 24 65 78 69 73 74 73 20 3f 20 24 61 6c 74 65 | ollectionName].=.$exists.?.$alte |
55320 | 72 6e 61 74 69 76 65 73 5b 24 63 6f 6c 6c 65 63 74 69 6f 6e 4e 61 6d 65 5d 20 2b 20 24 6c 65 76 | rnatives[$collectionName].+.$lev |
55340 | 20 3a 20 24 6c 65 76 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 | .:.$lev;.................}.elsei |
55360 | 66 20 28 24 65 78 69 73 74 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | f.($exists).{................... |
55380 | 20 20 24 61 6c 74 65 72 6e 61 74 69 76 65 73 5b 24 63 6f 6c 6c 65 63 74 69 6f 6e 4e 61 6d 65 5d | ..$alternatives[$collectionName] |
553a0 | 20 2b 3d 20 24 74 68 72 65 73 68 6f 6c 64 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | .+=.$threshold;................. |
553c0 | 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 | }.............}.........}....... |
553e0 | 20 20 20 66 6f 72 65 61 63 68 20 28 24 63 6f 6c 6c 65 63 74 69 6f 6e 20 61 73 20 24 69 74 65 6d | ...foreach.($collection.as.$item |
55400 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 65 76 20 3d 20 6c 65 76 65 6e 73 68 74 65 | ).{.............$lev.=.levenshte |
55420 | 69 6e 28 24 6e 61 6d 65 2c 20 24 69 74 65 6d 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 | in($name,.$item);.............if |
55440 | 20 28 24 6c 65 76 20 3c 3d 20 73 74 72 6c 65 6e 28 24 6e 61 6d 65 29 20 2f 20 33 20 7c 7c 20 66 | .($lev.<=.strlen($name)./.3.||.f |
55460 | 61 6c 73 65 20 21 3d 3d 20 73 74 72 70 6f 73 28 24 69 74 65 6d 2c 20 24 6e 61 6d 65 29 29 20 7b | alse.!==.strpos($item,.$name)).{ |
55480 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 61 6c 74 65 72 6e 61 74 69 76 65 73 5b 24 | .................$alternatives[$ |
554a0 | 69 74 65 6d 5d 20 3d 20 69 73 73 65 74 28 24 61 6c 74 65 72 6e 61 74 69 76 65 73 5b 24 69 74 65 | item].=.isset($alternatives[$ite |
554c0 | 6d 5d 29 20 3f 20 24 61 6c 74 65 72 6e 61 74 69 76 65 73 5b 24 69 74 65 6d 5d 20 2d 20 24 6c 65 | m]).?.$alternatives[$item].-.$le |
554e0 | 76 20 3a 20 24 6c 65 76 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 | v.:.$lev;.............}......... |
55500 | 7d 0a 0a 20 20 20 20 20 20 20 20 24 61 6c 74 65 72 6e 61 74 69 76 65 73 20 3d 20 61 72 72 61 79 | }..........$alternatives.=.array |
55520 | 5f 66 69 6c 74 65 72 28 24 61 6c 74 65 72 6e 61 74 69 76 65 73 2c 20 66 75 6e 63 74 69 6f 6e 20 | _filter($alternatives,.function. |
55540 | 28 24 6c 65 76 29 20 75 73 65 20 28 24 74 68 72 65 73 68 6f 6c 64 29 20 7b 20 72 65 74 75 72 6e | ($lev).use.($threshold).{.return |
55560 | 20 24 6c 65 76 20 3c 20 32 20 2a 20 24 74 68 72 65 73 68 6f 6c 64 3b 20 7d 29 3b 0a 20 20 20 20 | .$lev.<.2.*.$threshold;.});..... |
55580 | 20 20 20 20 61 73 6f 72 74 28 24 61 6c 74 65 72 6e 61 74 69 76 65 73 29 3b 0a 0a 20 20 20 20 20 | ....asort($alternatives);....... |
555a0 | 20 20 20 72 65 74 75 72 6e 20 61 72 72 61 79 5f 6b 65 79 73 28 24 61 6c 74 65 72 6e 61 74 69 76 | ...return.array_keys($alternativ |
555c0 | 65 73 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 | es);.....}....../**......*.Sets. |
555e0 | 74 68 65 20 64 65 66 61 75 6c 74 20 43 6f 6d 6d 61 6e 64 20 6e 61 6d 65 2e 0a 20 20 20 20 20 2a | the.default.Command.name.......* |
55600 | 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 63 6f 6d 6d 61 6e 64 4e 61 | ......*.@param.string.$commandNa |
55620 | 6d 65 20 54 68 65 20 43 6f 6d 6d 61 6e 64 20 6e 61 6d 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 | me.The.Command.name......*/..... |
55640 | 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 44 65 66 61 75 6c 74 43 6f 6d 6d 61 6e | public.function.setDefaultComman |
55660 | 64 28 24 63 6f 6d 6d 61 6e 64 4e 61 6d 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 | d($commandName).....{.........$t |
55680 | 68 69 73 2d 3e 64 65 66 61 75 6c 74 43 6f 6d 6d 61 6e 64 20 3d 20 24 63 6f 6d 6d 61 6e 64 4e 61 | his->defaultCommand.=.$commandNa |
556a0 | 6d 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 | me;.....}......private.function. |
556c0 | 73 74 72 69 6e 67 57 69 64 74 68 28 24 73 74 72 69 6e 67 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 | stringWidth($string).....{...... |
556e0 | 20 20 20 69 66 20 28 66 61 6c 73 65 20 3d 3d 3d 20 24 65 6e 63 6f 64 69 6e 67 20 3d 20 6d 62 5f | ...if.(false.===.$encoding.=.mb_ |
55700 | 64 65 74 65 63 74 5f 65 6e 63 6f 64 69 6e 67 28 24 73 74 72 69 6e 67 2c 20 6e 75 6c 6c 2c 20 74 | detect_encoding($string,.null,.t |
55720 | 72 75 65 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 74 72 6c 65 | rue)).{.............return.strle |
55740 | 6e 28 24 73 74 72 69 6e 67 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 | n($string);.........}..........r |
55760 | 65 74 75 72 6e 20 6d 62 5f 73 74 72 77 69 64 74 68 28 24 73 74 72 69 6e 67 2c 20 24 65 6e 63 6f | eturn.mb_strwidth($string,.$enco |
55780 | 64 69 6e 67 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 | ding);.....}......private.functi |
557a0 | 6f 6e 20 73 70 6c 69 74 53 74 72 69 6e 67 42 79 57 69 64 74 68 28 24 73 74 72 69 6e 67 2c 20 24 | on.splitStringByWidth($string,.$ |
557c0 | 77 69 64 74 68 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 2f 2f 20 73 74 72 5f 73 70 6c 69 | width).....{.........//.str_spli |
557e0 | 74 20 69 73 20 6e 6f 74 20 73 75 69 74 61 62 6c 65 20 66 6f 72 20 6d 75 6c 74 69 2d 62 79 74 65 | t.is.not.suitable.for.multi-byte |
55800 | 20 63 68 61 72 61 63 74 65 72 73 2c 20 77 65 20 73 68 6f 75 6c 64 20 75 73 65 20 70 72 65 67 5f | .characters,.we.should.use.preg_ |
55820 | 73 70 6c 69 74 20 74 6f 20 67 65 74 20 63 68 61 72 20 61 72 72 61 79 20 70 72 6f 70 65 72 6c 79 | split.to.get.char.array.properly |
55840 | 2e 0a 20 20 20 20 20 20 20 20 2f 2f 20 61 64 64 69 74 69 6f 6e 61 6c 6c 79 2c 20 61 72 72 61 79 | ..........//.additionally,.array |
55860 | 5f 73 6c 69 63 65 28 29 20 69 73 20 6e 6f 74 20 65 6e 6f 75 67 68 20 61 73 20 73 6f 6d 65 20 63 | _slice().is.not.enough.as.some.c |
55880 | 68 61 72 61 63 74 65 72 20 68 61 73 20 64 6f 75 62 6c 65 64 20 77 69 64 74 68 2e 0a 20 20 20 20 | haracter.has.doubled.width...... |
558a0 | 20 20 20 20 2f 2f 20 77 65 20 6e 65 65 64 20 61 20 66 75 6e 63 74 69 6f 6e 20 74 6f 20 73 70 6c | ....//.we.need.a.function.to.spl |
558c0 | 69 74 20 73 74 72 69 6e 67 20 6e 6f 74 20 62 79 20 63 68 61 72 61 63 74 65 72 20 63 6f 75 6e 74 | it.string.not.by.character.count |
558e0 | 20 62 75 74 20 62 79 20 73 74 72 69 6e 67 20 77 69 64 74 68 0a 20 20 20 20 20 20 20 20 69 66 20 | .but.by.string.width.........if. |
55900 | 28 66 61 6c 73 65 20 3d 3d 3d 20 24 65 6e 63 6f 64 69 6e 67 20 3d 20 6d 62 5f 64 65 74 65 63 74 | (false.===.$encoding.=.mb_detect |
55920 | 5f 65 6e 63 6f 64 69 6e 67 28 24 73 74 72 69 6e 67 2c 20 6e 75 6c 6c 2c 20 74 72 75 65 29 29 20 | _encoding($string,.null,.true)). |
55940 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 74 72 5f 73 70 6c 69 74 28 24 | {.............return.str_split($ |
55960 | 73 74 72 69 6e 67 2c 20 24 77 69 64 74 68 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 | string,.$width);.........}...... |
55980 | 20 20 20 20 24 75 74 66 38 53 74 72 69 6e 67 20 3d 20 6d 62 5f 63 6f 6e 76 65 72 74 5f 65 6e 63 | ....$utf8String.=.mb_convert_enc |
559a0 | 6f 64 69 6e 67 28 24 73 74 72 69 6e 67 2c 20 27 75 74 66 38 27 2c 20 24 65 6e 63 6f 64 69 6e 67 | oding($string,.'utf8',.$encoding |
559c0 | 29 3b 0a 20 20 20 20 20 20 20 20 24 6c 69 6e 65 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 | );.........$lines.=.array();.... |
559e0 | 20 20 20 20 20 24 6c 69 6e 65 20 3d 20 27 27 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 | .....$line.=.'';.........foreach |
55a00 | 20 28 70 72 65 67 5f 73 70 6c 69 74 28 27 2f 2f 75 27 2c 20 24 75 74 66 38 53 74 72 69 6e 67 29 | .(preg_split('//u',.$utf8String) |
55a20 | 20 61 73 20 24 63 68 61 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 74 65 73 74 | .as.$char).{.............//.test |
55a40 | 20 69 66 20 24 63 68 61 72 20 63 6f 75 6c 64 20 62 65 20 61 70 70 65 6e 64 65 64 20 74 6f 20 63 | .if.$char.could.be.appended.to.c |
55a60 | 75 72 72 65 6e 74 20 6c 69 6e 65 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 6d 62 5f 73 | urrent.line.............if.(mb_s |
55a80 | 74 72 77 69 64 74 68 28 24 6c 69 6e 65 2e 24 63 68 61 72 2c 20 27 75 74 66 38 27 29 20 3c 3d 20 | trwidth($line.$char,.'utf8').<=. |
55aa0 | 24 77 69 64 74 68 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 69 6e 65 20 | $width).{.................$line. |
55ac0 | 2e 3d 20 24 63 68 61 72 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 63 6f 6e 74 69 6e | .=.$char;.................contin |
55ae0 | 75 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f | ue;.............}.............// |
55b00 | 20 69 66 20 6e 6f 74 2c 20 70 75 73 68 20 63 75 72 72 65 6e 74 20 6c 69 6e 65 20 74 6f 20 61 72 | .if.not,.push.current.line.to.ar |
55b20 | 72 61 79 20 61 6e 64 20 6d 61 6b 65 20 6e 65 77 20 6c 69 6e 65 0a 20 20 20 20 20 20 20 20 20 20 | ray.and.make.new.line........... |
55b40 | 20 20 24 6c 69 6e 65 73 5b 5d 20 3d 20 73 74 72 5f 70 61 64 28 24 6c 69 6e 65 2c 20 24 77 69 64 | ..$lines[].=.str_pad($line,.$wid |
55b60 | 74 68 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 69 6e 65 20 3d 20 24 63 68 61 72 3b 0a | th);.............$line.=.$char;. |
55b80 | 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 27 27 20 21 3d 3d 20 24 6c 69 | ........}.........if.(''.!==.$li |
55ba0 | 6e 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 69 6e 65 73 5b 5d 20 3d 20 63 6f 75 | ne).{.............$lines[].=.cou |
55bc0 | 6e 74 28 24 6c 69 6e 65 73 29 20 3f 20 73 74 72 5f 70 61 64 28 24 6c 69 6e 65 2c 20 24 77 69 64 | nt($lines).?.str_pad($line,.$wid |
55be0 | 74 68 29 20 3a 20 24 6c 69 6e 65 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 | th).:.$line;.........}.......... |
55c00 | 6d 62 5f 63 6f 6e 76 65 72 74 5f 76 61 72 69 61 62 6c 65 73 28 24 65 6e 63 6f 64 69 6e 67 2c 20 | mb_convert_variables($encoding,. |
55c20 | 27 75 74 66 38 27 2c 20 24 6c 69 6e 65 73 29 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e | 'utf8',.$lines);..........return |
55c40 | 20 24 6c 69 6e 65 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 | .$lines;.....}....../**......*.R |
55c60 | 65 74 75 72 6e 73 20 61 6c 6c 20 6e 61 6d 65 73 70 61 63 65 73 20 6f 66 20 74 68 65 20 63 6f 6d | eturns.all.namespaces.of.the.com |
55c80 | 6d 61 6e 64 20 6e 61 6d 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 | mand.name.......*......*.@param. |
55ca0 | 73 74 72 69 6e 67 20 24 6e 61 6d 65 20 54 68 65 20 66 75 6c 6c 20 6e 61 6d 65 20 6f 66 20 74 68 | string.$name.The.full.name.of.th |
55cc0 | 65 20 63 6f 6d 6d 61 6e 64 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 | e.command......*......*.@return. |
55ce0 | 73 74 72 69 6e 67 5b 5d 20 54 68 65 20 6e 61 6d 65 73 70 61 63 65 73 20 6f 66 20 74 68 65 20 63 | string[].The.namespaces.of.the.c |
55d00 | 6f 6d 6d 61 6e 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 | ommand......*/.....private.funct |
55d20 | 69 6f 6e 20 65 78 74 72 61 63 74 41 6c 6c 4e 61 6d 65 73 70 61 63 65 73 28 24 6e 61 6d 65 29 0a | ion.extractAllNamespaces($name). |
55d40 | 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 2f 2f 20 2d 31 20 61 73 20 74 68 69 72 64 20 61 72 67 | ....{.........//.-1.as.third.arg |
55d60 | 75 6d 65 6e 74 20 69 73 20 6e 65 65 64 65 64 20 74 6f 20 73 6b 69 70 20 74 68 65 20 63 6f 6d 6d | ument.is.needed.to.skip.the.comm |
55d80 | 61 6e 64 20 73 68 6f 72 74 20 6e 61 6d 65 20 77 68 65 6e 20 65 78 70 6c 6f 64 69 6e 67 0a 20 20 | and.short.name.when.exploding... |
55da0 | 20 20 20 20 20 20 24 70 61 72 74 73 20 3d 20 65 78 70 6c 6f 64 65 28 27 3a 27 2c 20 24 6e 61 6d | ......$parts.=.explode(':',.$nam |
55dc0 | 65 2c 20 2d 31 29 3b 0a 20 20 20 20 20 20 20 20 24 6e 61 6d 65 73 70 61 63 65 73 20 3d 20 61 72 | e,.-1);.........$namespaces.=.ar |
55de0 | 72 61 79 28 29 3b 0a 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 70 61 72 74 73 20 | ray();..........foreach.($parts. |
55e00 | 61 73 20 24 70 61 72 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 63 6f 75 6e | as.$part).{.............if.(coun |
55e20 | 74 28 24 6e 61 6d 65 73 70 61 63 65 73 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | t($namespaces)).{............... |
55e40 | 20 20 24 6e 61 6d 65 73 70 61 63 65 73 5b 5d 20 3d 20 65 6e 64 28 24 6e 61 6d 65 73 70 61 63 65 | ..$namespaces[].=.end($namespace |
55e60 | 73 29 2e 27 3a 27 2e 24 70 61 72 74 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 | s).':'.$part;.............}.else |
55e80 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6e 61 6d 65 73 70 61 63 65 73 5b 5d | .{.................$namespaces[] |
55ea0 | 20 3d 20 24 70 61 72 74 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 | .=.$part;.............}......... |
55ec0 | 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 6e 61 6d 65 73 70 61 63 65 73 3b 0a 20 | }..........return.$namespaces;.. |
55ee0 | 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 | ...}.}.<?php../*..*.This.file.is |
55f00 | 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a | .part.of.the.Symfony.package...* |
55f20 | 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e | ..*.(c).Fabien.Potencier.<fabien |
55f40 | 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c | @symfony.com>..*..*.For.the.full |
55f60 | 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 | .copyright.and.license.informati |
55f80 | 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 | on,.please.view.the.LICENSE..*.f |
55fa0 | 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 | ile.that.was.distributed.with.th |
55fc0 | 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 | is.source.code...*/..namespace.S |
55fe0 | 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 48 65 6c 70 65 72 3b | ymfony\Component\Console\Helper; |
56000 | 0a 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c | ..use.Symfony\Component\Console\ |
56020 | 45 78 63 65 70 74 69 6f 6e 5c 4c 6f 67 69 63 45 78 63 65 70 74 69 6f 6e 3b 0a 75 73 65 20 53 79 | Exception\LogicException;.use.Sy |
56040 | 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 5c 49 6e | mfony\Component\Console\Input\In |
56060 | 70 75 74 49 6e 74 65 72 66 61 63 65 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e | putInterface;.use.Symfony\Compon |
56080 | 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 4f 75 74 70 75 74 5c 4f 75 74 70 75 74 49 6e 74 65 72 66 61 | ent\Console\Output\OutputInterfa |
560a0 | 63 65 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c | ce;.use.Symfony\Component\Consol |
560c0 | 65 5c 51 75 65 73 74 69 6f 6e 5c 43 68 6f 69 63 65 51 75 65 73 74 69 6f 6e 3b 0a 75 73 65 20 53 | e\Question\ChoiceQuestion;.use.S |
560e0 | 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 51 75 65 73 74 69 6f | ymfony\Component\Console\Questio |
56100 | 6e 5c 43 6f 6e 66 69 72 6d 61 74 69 6f 6e 51 75 65 73 74 69 6f 6e 3b 0a 75 73 65 20 53 79 6d 66 | n\ConfirmationQuestion;.use.Symf |
56120 | 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 51 75 65 73 74 69 6f 6e 5c 51 | ony\Component\Console\Question\Q |
56140 | 75 65 73 74 69 6f 6e 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 | uestion;.use.Symfony\Component\C |
56160 | 6f 6e 73 6f 6c 65 5c 53 74 79 6c 65 5c 53 79 6d 66 6f 6e 79 53 74 79 6c 65 3b 0a 75 73 65 20 53 | onsole\Style\SymfonyStyle;.use.S |
56180 | 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 46 6f 72 6d 61 74 74 | ymfony\Component\Console\Formatt |
561a0 | 65 72 5c 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 3b 0a 0a 2f 2a 2a 0a 20 2a 20 53 79 6d 66 | er\OutputFormatter;../**..*.Symf |
561c0 | 6f 6e 79 20 53 74 79 6c 65 20 47 75 69 64 65 20 63 6f 6d 70 6c 69 61 6e 74 20 71 75 65 73 74 69 | ony.Style.Guide.compliant.questi |
561e0 | 6f 6e 20 68 65 6c 70 65 72 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 4b 65 76 69 6e 20 42 | on.helper...*..*.@author.Kevin.B |
56200 | 6f 6e 64 20 3c 6b 65 76 69 6e 62 6f 6e 64 40 67 6d 61 69 6c 2e 63 6f 6d 3e 0a 20 2a 2f 0a 63 6c | ond.<kevinbond@gmail.com>..*/.cl |
56220 | 61 73 73 20 53 79 6d 66 6f 6e 79 51 75 65 73 74 69 6f 6e 48 65 6c 70 65 72 20 65 78 74 65 6e 64 | ass.SymfonyQuestionHelper.extend |
56240 | 73 20 51 75 65 73 74 69 6f 6e 48 65 6c 70 65 72 0a 7b 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 | s.QuestionHelper.{...../**...... |
56260 | 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c | *.{@inheritdoc}......*/.....publ |
56280 | 69 63 20 66 75 6e 63 74 69 6f 6e 20 61 73 6b 28 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 | ic.function.ask(InputInterface.$ |
562a0 | 69 6e 70 75 74 2c 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 2c 20 | input,.OutputInterface.$output,. |
562c0 | 51 75 65 73 74 69 6f 6e 20 24 71 75 65 73 74 69 6f 6e 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 | Question.$question).....{....... |
562e0 | 20 20 24 76 61 6c 69 64 61 74 6f 72 20 3d 20 24 71 75 65 73 74 69 6f 6e 2d 3e 67 65 74 56 61 6c | ..$validator.=.$question->getVal |
56300 | 69 64 61 74 6f 72 28 29 3b 0a 20 20 20 20 20 20 20 20 24 71 75 65 73 74 69 6f 6e 2d 3e 73 65 74 | idator();.........$question->set |
56320 | 56 61 6c 69 64 61 74 6f 72 28 66 75 6e 63 74 69 6f 6e 20 28 24 76 61 6c 75 65 29 20 75 73 65 20 | Validator(function.($value).use. |
56340 | 28 24 76 61 6c 69 64 61 74 6f 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 6e | ($validator).{.............if.(n |
56360 | 75 6c 6c 20 21 3d 3d 20 24 76 61 6c 69 64 61 74 6f 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | ull.!==.$validator).{........... |
56380 | 20 20 20 20 20 20 24 76 61 6c 75 65 20 3d 20 24 76 61 6c 69 64 61 74 6f 72 28 24 76 61 6c 75 65 | ......$value.=.$validator($value |
563a0 | 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 | );.............}.else.{......... |
563c0 | 20 20 20 20 20 20 20 20 2f 2f 20 6d 61 6b 65 20 72 65 71 75 69 72 65 64 0a 20 20 20 20 20 20 20 | ........//.make.required........ |
563e0 | 20 20 20 20 20 20 20 20 20 69 66 20 28 21 69 73 5f 61 72 72 61 79 28 24 76 61 6c 75 65 29 20 26 | .........if.(!is_array($value).& |
56400 | 26 20 21 69 73 5f 62 6f 6f 6c 28 24 76 61 6c 75 65 29 20 26 26 20 30 20 3d 3d 3d 20 73 74 72 6c | &.!is_bool($value).&&.0.===.strl |
56420 | 65 6e 28 24 76 61 6c 75 65 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | en($value)).{................... |
56440 | 20 20 74 68 72 6f 77 20 6e 65 77 20 4c 6f 67 69 63 45 78 63 65 70 74 69 6f 6e 28 27 41 20 76 61 | ..throw.new.LogicException('A.va |
56460 | 6c 75 65 20 69 73 20 72 65 71 75 69 72 65 64 2e 27 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | lue.is.required.');............. |
56480 | 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 | ....}.............}............. |
564a0 | 20 72 65 74 75 72 6e 20 24 76 61 6c 75 65 3b 0a 20 20 20 20 20 20 20 20 7d 29 3b 0a 0a 20 20 20 | .return.$value;.........});..... |
564c0 | 20 20 20 20 20 72 65 74 75 72 6e 20 70 61 72 65 6e 74 3a 3a 61 73 6b 28 24 69 6e 70 75 74 2c 20 | .....return.parent::ask($input,. |
564e0 | 24 6f 75 74 70 75 74 2c 20 24 71 75 65 73 74 69 6f 6e 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 | $output,.$question);.....}...... |
56500 | 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f | /**......*.{@inheritdoc}......*/ |
56520 | 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 77 72 69 74 65 50 72 6f | .....protected.function.writePro |
56540 | 6d 70 74 28 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 2c 20 51 75 65 | mpt(OutputInterface.$output,.Que |
56560 | 73 74 69 6f 6e 20 24 71 75 65 73 74 69 6f 6e 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 | stion.$question).....{.........$ |
56580 | 74 65 78 74 20 3d 20 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 3a 3a 65 73 63 61 70 65 28 24 | text.=.OutputFormatter::escape($ |
565a0 | 71 75 65 73 74 69 6f 6e 2d 3e 67 65 74 51 75 65 73 74 69 6f 6e 28 29 29 3b 0a 20 20 20 20 20 20 | question->getQuestion());....... |
565c0 | 20 20 24 64 65 66 61 75 6c 74 20 3d 20 24 71 75 65 73 74 69 6f 6e 2d 3e 67 65 74 44 65 66 61 75 | ..$default.=.$question->getDefau |
565e0 | 6c 74 28 29 3b 0a 0a 20 20 20 20 20 20 20 20 73 77 69 74 63 68 20 28 74 72 75 65 29 20 7b 0a 20 | lt();..........switch.(true).{.. |
56600 | 20 20 20 20 20 20 20 20 20 20 20 63 61 73 65 20 6e 75 6c 6c 20 3d 3d 3d 20 24 64 65 66 61 75 6c | ...........case.null.===.$defaul |
56620 | 74 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 65 78 74 20 3d 20 73 70 72 69 6e | t:.................$text.=.sprin |
56640 | 74 66 28 27 20 3c 69 6e 66 6f 3e 25 73 3c 2f 69 6e 66 6f 3e 3a 27 2c 20 24 74 65 78 74 29 3b 0a | tf('.<info>%s</info>:',.$text);. |
56660 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 62 72 65 61 6b 3b 0a 0a 20 20 20 20 20 20 20 | .................break;......... |
56680 | 20 20 20 20 20 63 61 73 65 20 24 71 75 65 73 74 69 6f 6e 20 69 6e 73 74 61 6e 63 65 6f 66 20 43 | .....case.$question.instanceof.C |
566a0 | 6f 6e 66 69 72 6d 61 74 69 6f 6e 51 75 65 73 74 69 6f 6e 3a 0a 20 20 20 20 20 20 20 20 20 20 20 | onfirmationQuestion:............ |
566c0 | 20 20 20 20 20 24 74 65 78 74 20 3d 20 73 70 72 69 6e 74 66 28 27 20 3c 69 6e 66 6f 3e 25 73 20 | .....$text.=.sprintf('.<info>%s. |
566e0 | 28 79 65 73 2f 6e 6f 29 3c 2f 69 6e 66 6f 3e 20 5b 3c 63 6f 6d 6d 65 6e 74 3e 25 73 3c 2f 63 6f | (yes/no)</info>.[<comment>%s</co |
56700 | 6d 6d 65 6e 74 3e 5d 3a 27 2c 20 24 74 65 78 74 2c 20 24 64 65 66 61 75 6c 74 20 3f 20 27 79 65 | mment>]:',.$text,.$default.?.'ye |
56720 | 73 27 20 3a 20 27 6e 6f 27 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 62 72 65 | s'.:.'no');..................bre |
56740 | 61 6b 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 63 61 73 65 20 24 71 75 65 73 74 69 6f 6e 20 | ak;..............case.$question. |
56760 | 69 6e 73 74 61 6e 63 65 6f 66 20 43 68 6f 69 63 65 51 75 65 73 74 69 6f 6e 20 26 26 20 24 71 75 | instanceof.ChoiceQuestion.&&.$qu |
56780 | 65 73 74 69 6f 6e 2d 3e 69 73 4d 75 6c 74 69 73 65 6c 65 63 74 28 29 3a 0a 20 20 20 20 20 20 20 | estion->isMultiselect():........ |
567a0 | 20 20 20 20 20 20 20 20 20 24 63 68 6f 69 63 65 73 20 3d 20 24 71 75 65 73 74 69 6f 6e 2d 3e 67 | .........$choices.=.$question->g |
567c0 | 65 74 43 68 6f 69 63 65 73 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 64 65 | etChoices();.................$de |
567e0 | 66 61 75 6c 74 20 3d 20 65 78 70 6c 6f 64 65 28 27 2c 27 2c 20 24 64 65 66 61 75 6c 74 29 3b 0a | fault.=.explode(',',.$default);. |
56800 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 64 65 66 61 75 | .................foreach.($defau |
56820 | 6c 74 20 61 73 20 24 6b 65 79 20 3d 3e 20 24 76 61 6c 75 65 29 20 7b 0a 20 20 20 20 20 20 20 20 | lt.as.$key.=>.$value).{......... |
56840 | 20 20 20 20 20 20 20 20 20 20 20 20 24 64 65 66 61 75 6c 74 5b 24 6b 65 79 5d 20 3d 20 24 63 68 | ............$default[$key].=.$ch |
56860 | 6f 69 63 65 73 5b 74 72 69 6d 28 24 76 61 6c 75 65 29 5d 3b 0a 20 20 20 20 20 20 20 20 20 20 20 | oices[trim($value)];............ |
56880 | 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 65 78 74 20 3d 20 | .....}..................$text.=. |
568a0 | 73 70 72 69 6e 74 66 28 27 20 3c 69 6e 66 6f 3e 25 73 3c 2f 69 6e 66 6f 3e 20 5b 3c 63 6f 6d 6d | sprintf('.<info>%s</info>.[<comm |
568c0 | 65 6e 74 3e 25 73 3c 2f 63 6f 6d 6d 65 6e 74 3e 5d 3a 27 2c 20 24 74 65 78 74 2c 20 4f 75 74 70 | ent>%s</comment>]:',.$text,.Outp |
568e0 | 75 74 46 6f 72 6d 61 74 74 65 72 3a 3a 65 73 63 61 70 65 28 69 6d 70 6c 6f 64 65 28 27 2c 20 27 | utFormatter::escape(implode(',.' |
56900 | 2c 20 24 64 65 66 61 75 6c 74 29 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ,.$default)));.................. |
56920 | 62 72 65 61 6b 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 63 61 73 65 20 24 71 75 65 73 74 69 | break;..............case.$questi |
56940 | 6f 6e 20 69 6e 73 74 61 6e 63 65 6f 66 20 43 68 6f 69 63 65 51 75 65 73 74 69 6f 6e 3a 0a 20 20 | on.instanceof.ChoiceQuestion:... |
56960 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 63 68 6f 69 63 65 73 20 3d 20 24 71 75 65 73 74 69 | ..............$choices.=.$questi |
56980 | 6f 6e 2d 3e 67 65 74 43 68 6f 69 63 65 73 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | on->getChoices();............... |
569a0 | 20 20 24 74 65 78 74 20 3d 20 73 70 72 69 6e 74 66 28 27 20 3c 69 6e 66 6f 3e 25 73 3c 2f 69 6e | ..$text.=.sprintf('.<info>%s</in |
569c0 | 66 6f 3e 20 5b 3c 63 6f 6d 6d 65 6e 74 3e 25 73 3c 2f 63 6f 6d 6d 65 6e 74 3e 5d 3a 27 2c 20 24 | fo>.[<comment>%s</comment>]:',.$ |
569e0 | 74 65 78 74 2c 20 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 3a 3a 65 73 63 61 70 65 28 24 63 | text,.OutputFormatter::escape($c |
56a00 | 68 6f 69 63 65 73 5b 24 64 65 66 61 75 6c 74 5d 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 | hoices[$default]));............. |
56a20 | 20 20 20 20 20 62 72 65 61 6b 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 64 65 66 61 75 6c 74 | .....break;..............default |
56a40 | 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 65 78 74 20 3d 20 73 70 72 69 6e 74 | :.................$text.=.sprint |
56a60 | 66 28 27 20 3c 69 6e 66 6f 3e 25 73 3c 2f 69 6e 66 6f 3e 20 5b 3c 63 6f 6d 6d 65 6e 74 3e 25 73 | f('.<info>%s</info>.[<comment>%s |
56a80 | 3c 2f 63 6f 6d 6d 65 6e 74 3e 5d 3a 27 2c 20 24 74 65 78 74 2c 20 4f 75 74 70 75 74 46 6f 72 6d | </comment>]:',.$text,.OutputForm |
56aa0 | 61 74 74 65 72 3a 3a 65 73 63 61 70 65 28 24 64 65 66 61 75 6c 74 29 29 3b 0a 20 20 20 20 20 20 | atter::escape($default));....... |
56ac0 | 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 24 74 | ..}..........$output->writeln($t |
56ae0 | 65 78 74 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 71 75 65 73 74 69 6f 6e 20 69 6e 73 | ext);..........if.($question.ins |
56b00 | 74 61 6e 63 65 6f 66 20 43 68 6f 69 63 65 51 75 65 73 74 69 6f 6e 29 20 7b 0a 20 20 20 20 20 20 | tanceof.ChoiceQuestion).{....... |
56b20 | 20 20 20 20 20 20 24 77 69 64 74 68 20 3d 20 6d 61 78 28 61 72 72 61 79 5f 6d 61 70 28 27 73 74 | ......$width.=.max(array_map('st |
56b40 | 72 6c 65 6e 27 2c 20 61 72 72 61 79 5f 6b 65 79 73 28 24 71 75 65 73 74 69 6f 6e 2d 3e 67 65 74 | rlen',.array_keys($question->get |
56b60 | 43 68 6f 69 63 65 73 28 29 29 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 | Choices())));..............forea |
56b80 | 63 68 20 28 24 71 75 65 73 74 69 6f 6e 2d 3e 67 65 74 43 68 6f 69 63 65 73 28 29 20 61 73 20 24 | ch.($question->getChoices().as.$ |
56ba0 | 6b 65 79 20 3d 3e 20 24 76 61 6c 75 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | key.=>.$value).{................ |
56bc0 | 20 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 73 70 72 69 6e 74 66 28 22 20 20 5b 3c 63 | .$output->writeln(sprintf("..[<c |
56be0 | 6f 6d 6d 65 6e 74 3e 25 2d 24 7b 77 69 64 74 68 7d 73 3c 2f 63 6f 6d 6d 65 6e 74 3e 5d 20 25 73 | omment>%-${width}s</comment>].%s |
56c00 | 22 2c 20 24 6b 65 79 2c 20 24 76 61 6c 75 65 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d | ",.$key,.$value));.............} |
56c20 | 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 6f 75 74 70 75 74 2d 3e 77 72 69 | .........}..........$output->wri |
56c40 | 74 65 28 27 20 3e 20 27 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a | te('.>.');.....}....../**......* |
56c60 | 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 6f 74 65 | .{@inheritdoc}......*/.....prote |
56c80 | 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 77 72 69 74 65 45 72 72 6f 72 28 4f 75 74 70 75 74 49 | cted.function.writeError(OutputI |
56ca0 | 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 2c 20 5c 45 78 63 65 70 74 69 6f 6e 20 24 65 72 | nterface.$output,.\Exception.$er |
56cc0 | 72 6f 72 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 6f 75 74 70 75 74 20 69 | ror).....{.........if.($output.i |
56ce0 | 6e 73 74 61 6e 63 65 6f 66 20 53 79 6d 66 6f 6e 79 53 74 79 6c 65 29 20 7b 0a 20 20 20 20 20 20 | nstanceof.SymfonyStyle).{....... |
56d00 | 20 20 20 20 20 20 24 6f 75 74 70 75 74 2d 3e 6e 65 77 4c 69 6e 65 28 29 3b 0a 20 20 20 20 20 20 | ......$output->newLine();....... |
56d20 | 20 20 20 20 20 20 24 6f 75 74 70 75 74 2d 3e 65 72 72 6f 72 28 24 65 72 72 6f 72 2d 3e 67 65 74 | ......$output->error($error->get |
56d40 | 4d 65 73 73 61 67 65 28 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 3b | Message());..............return; |
56d60 | 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 70 61 72 65 6e 74 3a 3a 77 72 69 74 | .........}..........parent::writ |
56d80 | 65 45 72 72 6f 72 28 24 6f 75 74 70 75 74 2c 20 24 65 72 72 6f 72 29 3b 0a 20 20 20 20 7d 0a 7d | eError($output,.$error);.....}.} |
56da0 | 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 | .<?php../*..*.This.file.is.part. |
56dc0 | 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 | of.the.Symfony.package...*..*.(c |
56de0 | 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f | ).Fabien.Potencier.<fabien@symfo |
56e00 | 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 | ny.com>..*..*.For.the.full.copyr |
56e20 | 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c | ight.and.license.information,.pl |
56e40 | 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 | ease.view.the.LICENSE..*.file.th |
56e60 | 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 | at.was.distributed.with.this.sou |
56e80 | 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 | rce.code...*/..namespace.Symfony |
56ea0 | 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 48 65 6c 70 65 72 3b 0a 0a 75 73 65 20 | \Component\Console\Helper;..use. |
56ec0 | 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 78 63 65 70 74 | Symfony\Component\Console\Except |
56ee0 | 69 6f 6e 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 3b 0a 75 73 | ion\InvalidArgumentException;.us |
56f00 | 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 78 63 65 | e.Symfony\Component\Console\Exce |
56f20 | 70 74 69 6f 6e 5c 4c 6f 67 69 63 45 78 63 65 70 74 69 6f 6e 3b 0a 75 73 65 20 53 79 6d 66 6f 6e | ption\LogicException;.use.Symfon |
56f40 | 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 4f 75 74 70 75 74 5c 4f 75 74 70 75 | y\Component\Console\Output\Outpu |
56f60 | 74 49 6e 74 65 72 66 61 63 65 3b 0a 0a 2f 2a 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 4b 65 76 69 | tInterface;../**..*.@author.Kevi |
56f80 | 6e 20 42 6f 6e 64 20 3c 6b 65 76 69 6e 62 6f 6e 64 40 67 6d 61 69 6c 2e 63 6f 6d 3e 0a 20 2a 2f | n.Bond.<kevinbond@gmail.com>..*/ |
56fa0 | 0a 63 6c 61 73 73 20 50 72 6f 67 72 65 73 73 49 6e 64 69 63 61 74 6f 72 0a 7b 0a 20 20 20 20 70 | .class.ProgressIndicator.{.....p |
56fc0 | 72 69 76 61 74 65 20 24 6f 75 74 70 75 74 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 73 74 61 | rivate.$output;.....private.$sta |
56fe0 | 72 74 54 69 6d 65 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 66 6f 72 6d 61 74 3b 0a 20 20 20 | rtTime;.....private.$format;.... |
57000 | 20 70 72 69 76 61 74 65 20 24 6d 65 73 73 61 67 65 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 | .private.$message;.....private.$ |
57020 | 69 6e 64 69 63 61 74 6f 72 56 61 6c 75 65 73 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 69 6e | indicatorValues;.....private.$in |
57040 | 64 69 63 61 74 6f 72 43 75 72 72 65 6e 74 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 69 6e 64 | dicatorCurrent;.....private.$ind |
57060 | 69 63 61 74 6f 72 43 68 61 6e 67 65 49 6e 74 65 72 76 61 6c 3b 0a 20 20 20 20 70 72 69 76 61 74 | icatorChangeInterval;.....privat |
57080 | 65 20 24 69 6e 64 69 63 61 74 6f 72 55 70 64 61 74 65 54 69 6d 65 3b 0a 20 20 20 20 70 72 69 76 | e.$indicatorUpdateTime;.....priv |
570a0 | 61 74 65 20 24 6c 61 73 74 4d 65 73 73 61 67 65 73 4c 65 6e 67 74 68 3b 0a 20 20 20 20 70 72 69 | ate.$lastMessagesLength;.....pri |
570c0 | 76 61 74 65 20 24 73 74 61 72 74 65 64 20 3d 20 66 61 6c 73 65 3b 0a 0a 20 20 20 20 70 72 69 76 | vate.$started.=.false;......priv |
570e0 | 61 74 65 20 73 74 61 74 69 63 20 24 66 6f 72 6d 61 74 74 65 72 73 3b 0a 20 20 20 20 70 72 69 76 | ate.static.$formatters;.....priv |
57100 | 61 74 65 20 73 74 61 74 69 63 20 24 66 6f 72 6d 61 74 73 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 | ate.static.$formats;....../**... |
57120 | 20 20 20 2a 20 40 70 61 72 61 6d 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 | ...*.@param.OutputInterface.$out |
57140 | 70 75 74 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 7c 6e 75 6c 6c 20 20 20 | put......*.@param.string|null... |
57160 | 20 20 24 66 6f 72 6d 61 74 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 49 6e 64 69 63 | ..$format..................Indic |
57180 | 61 74 6f 72 20 66 6f 72 6d 61 74 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 69 6e 74 20 20 20 | ator.format......*.@param.int... |
571a0 | 20 20 20 20 20 20 20 20 20 20 24 69 6e 64 69 63 61 74 6f 72 43 68 61 6e 67 65 49 6e 74 65 72 76 | ..........$indicatorChangeInterv |
571c0 | 61 6c 20 43 68 61 6e 67 65 20 69 6e 74 65 72 76 61 6c 20 69 6e 20 6d 69 6c 6c 69 73 65 63 6f 6e | al.Change.interval.in.millisecon |
571e0 | 64 73 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 7c 6e 75 6c 6c 20 20 20 20 20 | ds......*.@param.array|null..... |
57200 | 20 24 69 6e 64 69 63 61 74 6f 72 56 61 6c 75 65 73 20 20 20 20 20 20 20 20 20 41 6e 69 6d 61 74 | .$indicatorValues.........Animat |
57220 | 65 64 20 69 6e 64 69 63 61 74 6f 72 20 63 68 61 72 61 63 74 65 72 73 0a 20 20 20 20 20 2a 2f 0a | ed.indicator.characters......*/. |
57240 | 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 74 28 | ....public.function.__construct( |
57260 | 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 2c 20 24 66 6f 72 6d 61 74 | OutputInterface.$output,.$format |
57280 | 20 3d 20 6e 75 6c 6c 2c 20 24 69 6e 64 69 63 61 74 6f 72 43 68 61 6e 67 65 49 6e 74 65 72 76 61 | .=.null,.$indicatorChangeInterva |
572a0 | 6c 20 3d 20 31 30 30 2c 20 24 69 6e 64 69 63 61 74 6f 72 56 61 6c 75 65 73 20 3d 20 6e 75 6c 6c | l.=.100,.$indicatorValues.=.null |
572c0 | 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 20 3d 20 | ).....{.........$this->output.=. |
572e0 | 24 6f 75 74 70 75 74 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 | $output;..........if.(null.===.$ |
57300 | 66 6f 72 6d 61 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 66 6f 72 6d 61 74 20 3d 20 | format).{.............$format.=. |
57320 | 24 74 68 69 73 2d 3e 64 65 74 65 72 6d 69 6e 65 42 65 73 74 46 6f 72 6d 61 74 28 29 3b 0a 20 20 | $this->determineBestFormat();... |
57340 | 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 69 | ......}..........if.(null.===.$i |
57360 | 6e 64 69 63 61 74 6f 72 56 61 6c 75 65 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 69 | ndicatorValues).{.............$i |
57380 | 6e 64 69 63 61 74 6f 72 56 61 6c 75 65 73 20 3d 20 61 72 72 61 79 28 27 2d 27 2c 20 27 5c 5c 27 | ndicatorValues.=.array('-',.'\\' |
573a0 | 2c 20 27 7c 27 2c 20 27 2f 27 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 | ,.'|',.'/');.........}.......... |
573c0 | 24 69 6e 64 69 63 61 74 6f 72 56 61 6c 75 65 73 20 3d 20 61 72 72 61 79 5f 76 61 6c 75 65 73 28 | $indicatorValues.=.array_values( |
573e0 | 24 69 6e 64 69 63 61 74 6f 72 56 61 6c 75 65 73 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 | $indicatorValues);..........if.( |
57400 | 32 20 3e 20 63 6f 75 6e 74 28 24 69 6e 64 69 63 61 74 6f 72 56 61 6c 75 65 73 29 29 20 7b 0a 20 | 2.>.count($indicatorValues)).{.. |
57420 | 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 61 6c 69 64 41 72 67 75 | ...........throw.new.InvalidArgu |
57440 | 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 27 4d 75 73 74 20 68 61 76 65 20 61 74 20 6c 65 61 73 | mentException('Must.have.at.leas |
57460 | 74 20 32 20 69 6e 64 69 63 61 74 6f 72 20 76 61 6c 75 65 20 63 68 61 72 61 63 74 65 72 73 2e 27 | t.2.indicator.value.characters.' |
57480 | 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 66 6f 72 | );.........}..........$this->for |
574a0 | 6d 61 74 20 3d 20 73 65 6c 66 3a 3a 67 65 74 46 6f 72 6d 61 74 44 65 66 69 6e 69 74 69 6f 6e 28 | mat.=.self::getFormatDefinition( |
574c0 | 24 66 6f 72 6d 61 74 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 69 6e 64 69 63 61 74 | $format);.........$this->indicat |
574e0 | 6f 72 43 68 61 6e 67 65 49 6e 74 65 72 76 61 6c 20 3d 20 24 69 6e 64 69 63 61 74 6f 72 43 68 61 | orChangeInterval.=.$indicatorCha |
57500 | 6e 67 65 49 6e 74 65 72 76 61 6c 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 69 6e 64 69 | ngeInterval;.........$this->indi |
57520 | 63 61 74 6f 72 56 61 6c 75 65 73 20 3d 20 24 69 6e 64 69 63 61 74 6f 72 56 61 6c 75 65 73 3b 0a | catorValues.=.$indicatorValues;. |
57540 | 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 74 61 72 74 54 69 6d 65 20 3d 20 74 69 6d 65 28 | ........$this->startTime.=.time( |
57560 | 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 74 68 | );.....}....../**......*.Sets.th |
57580 | 65 20 63 75 72 72 65 6e 74 20 69 6e 64 69 63 61 74 6f 72 20 6d 65 73 73 61 67 65 2e 0a 20 20 20 | e.current.indicator.message..... |
575a0 | 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 7c 6e 75 6c 6c 20 24 6d | ..*......*.@param.string|null.$m |
575c0 | 65 73 73 61 67 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 | essage......*/.....public.functi |
575e0 | 6f 6e 20 73 65 74 4d 65 73 73 61 67 65 28 24 6d 65 73 73 61 67 65 29 0a 20 20 20 20 7b 0a 20 20 | on.setMessage($message).....{... |
57600 | 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6d 65 73 73 61 67 65 20 3d 20 24 6d 65 73 73 61 67 65 3b | ......$this->message.=.$message; |
57620 | 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 64 69 73 70 6c 61 79 28 29 3b 0a 20 20 20 20 | ..........$this->display();..... |
57640 | 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 74 61 72 74 73 20 74 68 65 20 69 6e 64 | }....../**......*.Starts.the.ind |
57660 | 69 63 61 74 6f 72 20 6f 75 74 70 75 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 | icator.output.......*......*.@pa |
57680 | 72 61 6d 20 24 6d 65 73 73 61 67 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 | ram.$message......*/.....public. |
576a0 | 66 75 6e 63 74 69 6f 6e 20 73 74 61 72 74 28 24 6d 65 73 73 61 67 65 29 0a 20 20 20 20 7b 0a 20 | function.start($message).....{.. |
576c0 | 20 20 20 20 20 20 20 69 66 20 28 24 74 68 69 73 2d 3e 73 74 61 72 74 65 64 29 20 7b 0a 20 20 20 | .......if.($this->started).{.... |
576e0 | 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 4c 6f 67 69 63 45 78 63 65 70 74 69 6f | .........throw.new.LogicExceptio |
57700 | 6e 28 27 50 72 6f 67 72 65 73 73 20 69 6e 64 69 63 61 74 6f 72 20 61 6c 72 65 61 64 79 20 73 74 | n('Progress.indicator.already.st |
57720 | 61 72 74 65 64 2e 27 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 | arted.');.........}..........$th |
57740 | 69 73 2d 3e 6d 65 73 73 61 67 65 20 3d 20 24 6d 65 73 73 61 67 65 3b 0a 20 20 20 20 20 20 20 20 | is->message.=.$message;......... |
57760 | 24 74 68 69 73 2d 3e 73 74 61 72 74 65 64 20 3d 20 74 72 75 65 3b 0a 20 20 20 20 20 20 20 20 24 | $this->started.=.true;.........$ |
57780 | 74 68 69 73 2d 3e 6c 61 73 74 4d 65 73 73 61 67 65 73 4c 65 6e 67 74 68 20 3d 20 30 3b 0a 20 20 | this->lastMessagesLength.=.0;... |
577a0 | 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 74 61 72 74 54 69 6d 65 20 3d 20 74 69 6d 65 28 29 3b | ......$this->startTime.=.time(); |
577c0 | 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 69 6e 64 69 63 61 74 6f 72 55 70 64 61 74 65 54 | .........$this->indicatorUpdateT |
577e0 | 69 6d 65 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 43 75 72 72 65 6e 74 54 69 6d 65 49 6e 4d 69 6c | ime.=.$this->getCurrentTimeInMil |
57800 | 6c 69 73 65 63 6f 6e 64 73 28 29 20 2b 20 24 74 68 69 73 2d 3e 69 6e 64 69 63 61 74 6f 72 43 68 | liseconds().+.$this->indicatorCh |
57820 | 61 6e 67 65 49 6e 74 65 72 76 61 6c 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 69 6e 64 | angeInterval;.........$this->ind |
57840 | 69 63 61 74 6f 72 43 75 72 72 65 6e 74 20 3d 20 30 3b 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 | icatorCurrent.=.0;..........$thi |
57860 | 73 2d 3e 64 69 73 70 6c 61 79 28 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 | s->display();.....}....../**.... |
57880 | 20 20 2a 20 41 64 76 61 6e 63 65 73 20 74 68 65 20 69 6e 64 69 63 61 74 6f 72 2e 0a 20 20 20 20 | ..*.Advances.the.indicator...... |
578a0 | 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 61 64 76 61 6e 63 65 28 | .*/.....public.function.advance( |
578c0 | 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 24 74 68 69 73 2d 3e 73 74 61 72 | ).....{.........if.(!$this->star |
578e0 | 74 65 64 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 4c 6f 67 | ted).{.............throw.new.Log |
57900 | 69 63 45 78 63 65 70 74 69 6f 6e 28 27 50 72 6f 67 72 65 73 73 20 69 6e 64 69 63 61 74 6f 72 20 | icException('Progress.indicator. |
57920 | 68 61 73 20 6e 6f 74 20 79 65 74 20 62 65 65 6e 20 73 74 61 72 74 65 64 2e 27 29 3b 0a 20 20 20 | has.not.yet.been.started.');.... |
57940 | 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 24 74 68 69 73 2d 3e 6f 75 74 70 | .....}..........if.(!$this->outp |
57960 | 75 74 2d 3e 69 73 44 65 63 6f 72 61 74 65 64 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | ut->isDecorated()).{............ |
57980 | 20 72 65 74 75 72 6e 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 63 75 72 | .return;.........}..........$cur |
579a0 | 72 65 6e 74 54 69 6d 65 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 43 75 72 72 65 6e 74 54 69 6d 65 | rentTime.=.$this->getCurrentTime |
579c0 | 49 6e 4d 69 6c 6c 69 73 65 63 6f 6e 64 73 28 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 | InMilliseconds();..........if.($ |
579e0 | 63 75 72 72 65 6e 74 54 69 6d 65 20 3c 20 24 74 68 69 73 2d 3e 69 6e 64 69 63 61 74 6f 72 55 70 | currentTime.<.$this->indicatorUp |
57a00 | 64 61 74 65 54 69 6d 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 3b 0a | dateTime).{.............return;. |
57a20 | 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 69 6e 64 69 63 61 | ........}..........$this->indica |
57a40 | 74 6f 72 55 70 64 61 74 65 54 69 6d 65 20 3d 20 24 63 75 72 72 65 6e 74 54 69 6d 65 20 2b 20 24 | torUpdateTime.=.$currentTime.+.$ |
57a60 | 74 68 69 73 2d 3e 69 6e 64 69 63 61 74 6f 72 43 68 61 6e 67 65 49 6e 74 65 72 76 61 6c 3b 0a 20 | this->indicatorChangeInterval;.. |
57a80 | 20 20 20 20 20 20 20 2b 2b 24 74 68 69 73 2d 3e 69 6e 64 69 63 61 74 6f 72 43 75 72 72 65 6e 74 | .......++$this->indicatorCurrent |
57aa0 | 3b 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 64 69 73 70 6c 61 79 28 29 3b 0a 20 20 20 | ;..........$this->display();.... |
57ac0 | 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 46 69 6e 69 73 68 20 74 68 65 20 69 6e | .}....../**......*.Finish.the.in |
57ae0 | 64 69 63 61 74 6f 72 20 77 69 74 68 20 6d 65 73 73 61 67 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 | dicator.with.message.......*.... |
57b00 | 20 20 2a 20 40 70 61 72 61 6d 20 24 6d 65 73 73 61 67 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 | ..*.@param.$message......*/..... |
57b20 | 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 66 69 6e 69 73 68 28 24 6d 65 73 73 61 67 65 29 | public.function.finish($message) |
57b40 | 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 24 74 68 69 73 2d 3e 73 74 61 72 74 | .....{.........if.(!$this->start |
57b60 | 65 64 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 4c 6f 67 69 | ed).{.............throw.new.Logi |
57b80 | 63 45 78 63 65 70 74 69 6f 6e 28 27 50 72 6f 67 72 65 73 73 20 69 6e 64 69 63 61 74 6f 72 20 68 | cException('Progress.indicator.h |
57ba0 | 61 73 20 6e 6f 74 20 79 65 74 20 62 65 65 6e 20 73 74 61 72 74 65 64 2e 27 29 3b 0a 20 20 20 20 | as.not.yet.been.started.');..... |
57bc0 | 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6d 65 73 73 61 67 65 20 3d 20 | ....}..........$this->message.=. |
57be0 | 24 6d 65 73 73 61 67 65 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 64 69 73 70 6c 61 79 | $message;.........$this->display |
57c00 | 28 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 | ();.........$this->output->write |
57c20 | 6c 6e 28 27 27 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 74 61 72 74 65 64 20 3d | ln('');.........$this->started.= |
57c40 | 20 66 61 6c 73 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 | .false;.....}....../**......*.Ge |
57c60 | 74 73 20 74 68 65 20 66 6f 72 6d 61 74 20 66 6f 72 20 61 20 67 69 76 65 6e 20 6e 61 6d 65 2e 0a | ts.the.format.for.a.given.name.. |
57c80 | 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6e 61 6d | .....*......*.@param.string.$nam |
57ca0 | 65 20 54 68 65 20 66 6f 72 6d 61 74 20 6e 61 6d 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 | e.The.format.name......*......*. |
57cc0 | 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 7c 6e 75 6c 6c 20 41 20 66 6f 72 6d 61 74 20 73 74 72 | @return.string|null.A.format.str |
57ce0 | 69 6e 67 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 | ing......*/.....public.static.fu |
57d00 | 6e 63 74 69 6f 6e 20 67 65 74 46 6f 72 6d 61 74 44 65 66 69 6e 69 74 69 6f 6e 28 24 6e 61 6d 65 | nction.getFormatDefinition($name |
57d20 | 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 73 65 6c 66 3a 3a 24 66 6f 72 6d | ).....{.........if.(!self::$form |
57d40 | 61 74 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 73 65 6c 66 3a 3a 24 66 6f 72 6d 61 74 | ats).{.............self::$format |
57d60 | 73 20 3d 20 73 65 6c 66 3a 3a 69 6e 69 74 46 6f 72 6d 61 74 73 28 29 3b 0a 20 20 20 20 20 20 20 | s.=.self::initFormats();........ |
57d80 | 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 69 73 73 65 74 28 73 65 6c 66 3a 3a 24 | .}..........return.isset(self::$ |
57da0 | 66 6f 72 6d 61 74 73 5b 24 6e 61 6d 65 5d 29 20 3f 20 73 65 6c 66 3a 3a 24 66 6f 72 6d 61 74 73 | formats[$name]).?.self::$formats |
57dc0 | 5b 24 6e 61 6d 65 5d 20 3a 20 6e 75 6c 6c 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 | [$name].:.null;.....}....../**.. |
57de0 | 20 20 20 20 2a 20 53 65 74 73 20 61 20 70 6c 61 63 65 68 6f 6c 64 65 72 20 66 6f 72 6d 61 74 74 | ....*.Sets.a.placeholder.formatt |
57e00 | 65 72 20 66 6f 72 20 61 20 67 69 76 65 6e 20 6e 61 6d 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 | er.for.a.given.name.......*..... |
57e20 | 20 2a 20 54 68 69 73 20 6d 65 74 68 6f 64 20 61 6c 73 6f 20 61 6c 6c 6f 77 20 79 6f 75 20 74 6f | .*.This.method.also.allow.you.to |
57e40 | 20 6f 76 65 72 72 69 64 65 20 61 6e 20 65 78 69 73 74 69 6e 67 20 70 6c 61 63 65 68 6f 6c 64 65 | .override.an.existing.placeholde |
57e60 | 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 20 | r.......*......*.@param.string.. |
57e80 | 20 24 6e 61 6d 65 20 20 20 20 20 54 68 65 20 70 6c 61 63 65 68 6f 6c 64 65 72 20 6e 61 6d 65 20 | .$name.....The.placeholder.name. |
57ea0 | 28 69 6e 63 6c 75 64 69 6e 67 20 74 68 65 20 64 65 6c 69 6d 69 74 65 72 20 63 68 61 72 20 6c 69 | (including.the.delimiter.char.li |
57ec0 | 6b 65 20 25 29 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 63 61 6c 6c 61 62 6c 65 20 24 63 61 | ke.%)......*.@param.callable.$ca |
57ee0 | 6c 6c 61 62 6c 65 20 41 20 50 48 50 20 63 61 6c 6c 61 62 6c 65 0a 20 20 20 20 20 2a 2f 0a 20 20 | llable.A.PHP.callable......*/... |
57f00 | 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 50 6c 61 63 | ..public.static.function.setPlac |
57f20 | 65 68 6f 6c 64 65 72 46 6f 72 6d 61 74 74 65 72 44 65 66 69 6e 69 74 69 6f 6e 28 24 6e 61 6d 65 | eholderFormatterDefinition($name |
57f40 | 2c 20 24 63 61 6c 6c 61 62 6c 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 | ,.$callable).....{.........if.(! |
57f60 | 73 65 6c 66 3a 3a 24 66 6f 72 6d 61 74 74 65 72 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | self::$formatters).{............ |
57f80 | 20 73 65 6c 66 3a 3a 24 66 6f 72 6d 61 74 74 65 72 73 20 3d 20 73 65 6c 66 3a 3a 69 6e 69 74 50 | .self::$formatters.=.self::initP |
57fa0 | 6c 61 63 65 68 6f 6c 64 65 72 46 6f 72 6d 61 74 74 65 72 73 28 29 3b 0a 20 20 20 20 20 20 20 20 | laceholderFormatters();......... |
57fc0 | 7d 0a 0a 20 20 20 20 20 20 20 20 73 65 6c 66 3a 3a 24 66 6f 72 6d 61 74 74 65 72 73 5b 24 6e 61 | }..........self::$formatters[$na |
57fe0 | 6d 65 5d 20 3d 20 24 63 61 6c 6c 61 62 6c 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a | me].=.$callable;.....}....../**. |
58000 | 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 70 6c 61 63 65 68 6f 6c 64 65 72 20 66 6f 72 6d | .....*.Gets.the.placeholder.form |
58020 | 61 74 74 65 72 20 66 6f 72 20 61 20 67 69 76 65 6e 20 6e 61 6d 65 2e 0a 20 20 20 20 20 2a 0a 20 | atter.for.a.given.name.......*.. |
58040 | 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6e 61 6d 65 20 54 68 65 20 70 6c | ....*.@param.string.$name.The.pl |
58060 | 61 63 65 68 6f 6c 64 65 72 20 6e 61 6d 65 20 28 69 6e 63 6c 75 64 69 6e 67 20 74 68 65 20 64 65 | aceholder.name.(including.the.de |
58080 | 6c 69 6d 69 74 65 72 20 63 68 61 72 20 6c 69 6b 65 20 25 29 0a 20 20 20 20 20 2a 0a 20 20 20 20 | limiter.char.like.%)......*..... |
580a0 | 20 2a 20 40 72 65 74 75 72 6e 20 63 61 6c 6c 61 62 6c 65 7c 6e 75 6c 6c 20 41 20 50 48 50 20 63 | .*.@return.callable|null.A.PHP.c |
580c0 | 61 6c 6c 61 62 6c 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 | allable......*/.....public.stati |
580e0 | 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 50 6c 61 63 65 68 6f 6c 64 65 72 46 6f 72 6d 61 74 74 | c.function.getPlaceholderFormatt |
58100 | 65 72 44 65 66 69 6e 69 74 69 6f 6e 28 24 6e 61 6d 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 | erDefinition($name).....{....... |
58120 | 20 20 69 66 20 28 21 73 65 6c 66 3a 3a 24 66 6f 72 6d 61 74 74 65 72 73 29 20 7b 0a 20 20 20 20 | ..if.(!self::$formatters).{..... |
58140 | 20 20 20 20 20 20 20 20 73 65 6c 66 3a 3a 24 66 6f 72 6d 61 74 74 65 72 73 20 3d 20 73 65 6c 66 | ........self::$formatters.=.self |
58160 | 3a 3a 69 6e 69 74 50 6c 61 63 65 68 6f 6c 64 65 72 46 6f 72 6d 61 74 74 65 72 73 28 29 3b 0a 20 | ::initPlaceholderFormatters();.. |
58180 | 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 69 73 73 65 74 28 73 | .......}..........return.isset(s |
581a0 | 65 6c 66 3a 3a 24 66 6f 72 6d 61 74 74 65 72 73 5b 24 6e 61 6d 65 5d 29 20 3f 20 73 65 6c 66 3a | elf::$formatters[$name]).?.self: |
581c0 | 3a 24 66 6f 72 6d 61 74 74 65 72 73 5b 24 6e 61 6d 65 5d 20 3a 20 6e 75 6c 6c 3b 0a 20 20 20 20 | :$formatters[$name].:.null;..... |
581e0 | 7d 0a 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 64 69 73 70 6c 61 79 28 | }......private.function.display( |
58200 | 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 4f 75 74 70 75 74 49 6e 74 65 72 66 | ).....{.........if.(OutputInterf |
58220 | 61 63 65 3a 3a 56 45 52 42 4f 53 49 54 59 5f 51 55 49 45 54 20 3d 3d 3d 20 24 74 68 69 73 2d 3e | ace::VERBOSITY_QUIET.===.$this-> |
58240 | 6f 75 74 70 75 74 2d 3e 67 65 74 56 65 72 62 6f 73 69 74 79 28 29 29 20 7b 0a 20 20 20 20 20 20 | output->getVerbosity()).{....... |
58260 | 20 20 20 20 20 20 72 65 74 75 72 6e 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 | ......return;.........}......... |
58280 | 20 24 73 65 6c 66 20 3d 20 24 74 68 69 73 3b 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e | .$self.=.$this;..........$this-> |
582a0 | 6f 76 65 72 77 72 69 74 65 28 70 72 65 67 5f 72 65 70 6c 61 63 65 5f 63 61 6c 6c 62 61 63 6b 28 | overwrite(preg_replace_callback( |
582c0 | 22 7b 25 28 5b 61 2d 7a 5c 2d 5f 5d 2b 29 28 3f 3a 5c 3a 28 5b 5e 25 5d 2b 29 29 3f 25 7d 69 22 | "{%([a-z\-_]+)(?:\:([^%]+))?%}i" |
582e0 | 2c 20 66 75 6e 63 74 69 6f 6e 20 28 24 6d 61 74 63 68 65 73 29 20 75 73 65 20 28 24 73 65 6c 66 | ,.function.($matches).use.($self |
58300 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 66 6f 72 6d 61 74 74 65 72 20 3d | ).{.............if.($formatter.= |
58320 | 20 24 73 65 6c 66 3a 3a 67 65 74 50 6c 61 63 65 68 6f 6c 64 65 72 46 6f 72 6d 61 74 74 65 72 44 | .$self::getPlaceholderFormatterD |
58340 | 65 66 69 6e 69 74 69 6f 6e 28 24 6d 61 74 63 68 65 73 5b 31 5d 29 29 20 7b 0a 20 20 20 20 20 20 | efinition($matches[1])).{....... |
58360 | 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 63 61 6c 6c 5f 75 73 65 72 5f 66 75 6e 63 28 | ..........return.call_user_func( |
58380 | 24 66 6f 72 6d 61 74 74 65 72 2c 20 24 73 65 6c 66 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | $formatter,.$self);............. |
583a0 | 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 6d 61 74 63 68 65 73 5b 30 | }..............return.$matches[0 |
583c0 | 5d 3b 0a 20 20 20 20 20 20 20 20 7d 2c 20 24 74 68 69 73 2d 3e 66 6f 72 6d 61 74 29 29 3b 0a 20 | ];.........},.$this->format));.. |
583e0 | 20 20 20 7d 0a 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 64 65 74 65 72 | ...}......private.function.deter |
58400 | 6d 69 6e 65 42 65 73 74 46 6f 72 6d 61 74 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 73 | mineBestFormat().....{.........s |
58420 | 77 69 74 63 68 20 28 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 2d 3e 67 65 74 56 65 72 62 6f 73 69 | witch.($this->output->getVerbosi |
58440 | 74 79 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 4f 75 74 70 75 74 49 6e 74 | ty()).{.............//.OutputInt |
58460 | 65 72 66 61 63 65 3a 3a 56 45 52 42 4f 53 49 54 59 5f 51 55 49 45 54 3a 20 64 69 73 70 6c 61 79 | erface::VERBOSITY_QUIET:.display |
58480 | 20 69 73 20 64 69 73 61 62 6c 65 64 20 61 6e 79 77 61 79 0a 20 20 20 20 20 20 20 20 20 20 20 20 | .is.disabled.anyway............. |
584a0 | 63 61 73 65 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 3a 3a 56 45 52 42 4f 53 49 54 59 5f | case.OutputInterface::VERBOSITY_ |
584c0 | 56 45 52 42 4f 53 45 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 | VERBOSE:.................return. |
584e0 | 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 2d 3e 69 73 44 65 63 6f 72 61 74 65 64 28 29 20 3f 20 27 | $this->output->isDecorated().?.' |
58500 | 76 65 72 62 6f 73 65 27 20 3a 20 27 76 65 72 62 6f 73 65 5f 6e 6f 5f 61 6e 73 69 27 3b 0a 20 20 | verbose'.:.'verbose_no_ansi';... |
58520 | 20 20 20 20 20 20 20 20 20 20 63 61 73 65 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 3a 3a | ..........case.OutputInterface:: |
58540 | 56 45 52 42 4f 53 49 54 59 5f 56 45 52 59 5f 56 45 52 42 4f 53 45 3a 0a 20 20 20 20 20 20 20 20 | VERBOSITY_VERY_VERBOSE:......... |
58560 | 20 20 20 20 63 61 73 65 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 3a 3a 56 45 52 42 4f 53 | ....case.OutputInterface::VERBOS |
58580 | 49 54 59 5f 44 45 42 55 47 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 | ITY_DEBUG:.................retur |
585a0 | 6e 20 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 2d 3e 69 73 44 65 63 6f 72 61 74 65 64 28 29 20 3f | n.$this->output->isDecorated().? |
585c0 | 20 27 76 65 72 79 5f 76 65 72 62 6f 73 65 27 20 3a 20 27 76 65 72 79 5f 76 65 72 62 6f 73 65 5f | .'very_verbose'.:.'very_verbose_ |
585e0 | 6e 6f 5f 61 6e 73 69 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 64 65 66 61 75 6c 74 3a 0a 20 | no_ansi';.............default:.. |
58600 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 6f 75 74 | ...............return.$this->out |
58620 | 70 75 74 2d 3e 69 73 44 65 63 6f 72 61 74 65 64 28 29 20 3f 20 27 6e 6f 72 6d 61 6c 27 20 3a 20 | put->isDecorated().?.'normal'.:. |
58640 | 27 6e 6f 72 6d 61 6c 5f 6e 6f 5f 61 6e 73 69 27 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 | 'normal_no_ansi';.........}..... |
58660 | 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 4f 76 65 72 77 72 69 74 65 73 20 61 20 70 | }....../**......*.Overwrites.a.p |
58680 | 72 65 76 69 6f 75 73 20 6d 65 73 73 61 67 65 20 74 6f 20 74 68 65 20 6f 75 74 70 75 74 2e 0a 20 | revious.message.to.the.output... |
586a0 | 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6d 65 73 73 | ....*......*.@param.string.$mess |
586c0 | 61 67 65 20 54 68 65 20 6d 65 73 73 61 67 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 | age.The.message......*/.....priv |
586e0 | 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 6f 76 65 72 77 72 69 74 65 28 24 6d 65 73 73 61 67 65 29 | ate.function.overwrite($message) |
58700 | 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 2f 2f 20 61 70 70 65 6e 64 20 77 68 69 74 65 73 70 | .....{.........//.append.whitesp |
58720 | 61 63 65 20 74 6f 20 6d 61 74 63 68 20 74 68 65 20 6c 69 6e 65 27 73 20 6c 65 6e 67 74 68 0a 20 | ace.to.match.the.line's.length.. |
58740 | 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 21 3d 3d 20 24 74 68 69 73 2d 3e 6c 61 73 74 4d | .......if.(null.!==.$this->lastM |
58760 | 65 73 73 61 67 65 73 4c 65 6e 67 74 68 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 | essagesLength).{.............if. |
58780 | 28 24 74 68 69 73 2d 3e 6c 61 73 74 4d 65 73 73 61 67 65 73 4c 65 6e 67 74 68 20 3e 20 48 65 6c | ($this->lastMessagesLength.>.Hel |
587a0 | 70 65 72 3a 3a 73 74 72 6c 65 6e 57 69 74 68 6f 75 74 44 65 63 6f 72 61 74 69 6f 6e 28 24 74 68 | per::strlenWithoutDecoration($th |
587c0 | 69 73 2d 3e 6f 75 74 70 75 74 2d 3e 67 65 74 46 6f 72 6d 61 74 74 65 72 28 29 2c 20 24 6d 65 73 | is->output->getFormatter(),.$mes |
587e0 | 73 61 67 65 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 | sage)).{.................$messag |
58800 | 65 20 3d 20 73 74 72 5f 70 61 64 28 24 6d 65 73 73 61 67 65 2c 20 24 74 68 69 73 2d 3e 6c 61 73 | e.=.str_pad($message,.$this->las |
58820 | 74 4d 65 73 73 61 67 65 73 4c 65 6e 67 74 68 2c 20 22 5c 78 32 30 22 2c 20 53 54 52 5f 50 41 44 | tMessagesLength,."\x20",.STR_PAD |
58840 | 5f 52 49 47 48 54 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d | _RIGHT);.............}.........} |
58860 | 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 2d 3e 69 73 44 | ..........if.($this->output->isD |
58880 | 65 63 6f 72 61 74 65 64 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d | ecorated()).{.............$this- |
588a0 | 3e 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 28 22 5c 78 30 44 22 29 3b 0a 20 20 20 20 20 20 20 20 | >output->write("\x0D");......... |
588c0 | 20 20 20 20 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 28 24 6d 65 73 73 61 67 | ....$this->output->write($messag |
588e0 | 65 29 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | e);.........}.else.{............ |
58900 | 20 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 24 6d 65 73 73 61 67 65 | .$this->output->writeln($message |
58920 | 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6c 61 73 | );.........}..........$this->las |
58940 | 74 4d 65 73 73 61 67 65 73 4c 65 6e 67 74 68 20 3d 20 30 3b 0a 0a 20 20 20 20 20 20 20 20 24 6c | tMessagesLength.=.0;..........$l |
58960 | 65 6e 20 3d 20 48 65 6c 70 65 72 3a 3a 73 74 72 6c 65 6e 57 69 74 68 6f 75 74 44 65 63 6f 72 61 | en.=.Helper::strlenWithoutDecora |
58980 | 74 69 6f 6e 28 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 2d 3e 67 65 74 46 6f 72 6d 61 74 74 65 72 | tion($this->output->getFormatter |
589a0 | 28 29 2c 20 24 6d 65 73 73 61 67 65 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 6c 65 6e | (),.$message);..........if.($len |
589c0 | 20 3e 20 24 74 68 69 73 2d 3e 6c 61 73 74 4d 65 73 73 61 67 65 73 4c 65 6e 67 74 68 29 20 7b 0a | .>.$this->lastMessagesLength).{. |
589e0 | 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6c 61 73 74 4d 65 73 73 61 67 65 73 4c | ............$this->lastMessagesL |
58a00 | 65 6e 67 74 68 20 3d 20 24 6c 65 6e 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 | ength.=.$len;.........}.....}... |
58a20 | 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 43 75 72 72 65 6e 74 54 69 | ...private.function.getCurrentTi |
58a40 | 6d 65 49 6e 4d 69 6c 6c 69 73 65 63 6f 6e 64 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 | meInMilliseconds().....{........ |
58a60 | 20 72 65 74 75 72 6e 20 72 6f 75 6e 64 28 6d 69 63 72 6f 74 69 6d 65 28 74 72 75 65 29 20 2a 20 | .return.round(microtime(true).*. |
58a80 | 31 30 30 30 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 | 1000);.....}......private.static |
58aa0 | 20 66 75 6e 63 74 69 6f 6e 20 69 6e 69 74 50 6c 61 63 65 68 6f 6c 64 65 72 46 6f 72 6d 61 74 74 | .function.initPlaceholderFormatt |
58ac0 | 65 72 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 61 72 72 61 79 | ers().....{.........return.array |
58ae0 | 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 69 6e 64 69 63 61 74 6f 72 27 20 3d 3e 20 66 75 6e | (.............'indicator'.=>.fun |
58b00 | 63 74 69 6f 6e 20 28 50 72 6f 67 72 65 73 73 49 6e 64 69 63 61 74 6f 72 20 24 69 6e 64 69 63 61 | ction.(ProgressIndicator.$indica |
58b20 | 74 6f 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 69 | tor).{.................return.$i |
58b40 | 6e 64 69 63 61 74 6f 72 2d 3e 69 6e 64 69 63 61 74 6f 72 56 61 6c 75 65 73 5b 24 69 6e 64 69 63 | ndicator->indicatorValues[$indic |
58b60 | 61 74 6f 72 2d 3e 69 6e 64 69 63 61 74 6f 72 43 75 72 72 65 6e 74 20 25 20 63 6f 75 6e 74 28 24 | ator->indicatorCurrent.%.count($ |
58b80 | 69 6e 64 69 63 61 74 6f 72 2d 3e 69 6e 64 69 63 61 74 6f 72 56 61 6c 75 65 73 29 5d 3b 0a 20 20 | indicator->indicatorValues)];... |
58ba0 | 20 20 20 20 20 20 20 20 20 20 7d 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 6d 65 73 73 61 67 | ..........},.............'messag |
58bc0 | 65 27 20 3d 3e 20 66 75 6e 63 74 69 6f 6e 20 28 50 72 6f 67 72 65 73 73 49 6e 64 69 63 61 74 6f | e'.=>.function.(ProgressIndicato |
58be0 | 72 20 24 69 6e 64 69 63 61 74 6f 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | r.$indicator).{................. |
58c00 | 72 65 74 75 72 6e 20 24 69 6e 64 69 63 61 74 6f 72 2d 3e 6d 65 73 73 61 67 65 3b 0a 20 20 20 20 | return.$indicator->message;..... |
58c20 | 20 20 20 20 20 20 20 20 7d 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 65 6c 61 70 73 65 64 27 | ........},.............'elapsed' |
58c40 | 20 3d 3e 20 66 75 6e 63 74 69 6f 6e 20 28 50 72 6f 67 72 65 73 73 49 6e 64 69 63 61 74 6f 72 20 | .=>.function.(ProgressIndicator. |
58c60 | 24 69 6e 64 69 63 61 74 6f 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 | $indicator).{.................re |
58c80 | 74 75 72 6e 20 48 65 6c 70 65 72 3a 3a 66 6f 72 6d 61 74 54 69 6d 65 28 74 69 6d 65 28 29 20 2d | turn.Helper::formatTime(time().- |
58ca0 | 20 24 69 6e 64 69 63 61 74 6f 72 2d 3e 73 74 61 72 74 54 69 6d 65 29 3b 0a 20 20 20 20 20 20 20 | .$indicator->startTime);........ |
58cc0 | 20 20 20 20 20 7d 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 6d 65 6d 6f 72 79 27 20 3d 3e 20 | .....},.............'memory'.=>. |
58ce0 | 66 75 6e 63 74 69 6f 6e 20 28 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 | function.().{.................re |
58d00 | 74 75 72 6e 20 48 65 6c 70 65 72 3a 3a 66 6f 72 6d 61 74 4d 65 6d 6f 72 79 28 6d 65 6d 6f 72 79 | turn.Helper::formatMemory(memory |
58d20 | 5f 67 65 74 5f 75 73 61 67 65 28 74 72 75 65 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d | _get_usage(true));.............} |
58d40 | 2c 0a 20 20 20 20 20 20 20 20 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 72 69 76 61 74 65 20 | ,.........);.....}......private. |
58d60 | 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 69 6e 69 74 46 6f 72 6d 61 74 73 28 29 0a 20 20 | static.function.initFormats()... |
58d80 | 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 61 72 72 61 79 28 0a 20 20 20 20 20 20 | ..{.........return.array(....... |
58da0 | 20 20 20 20 20 20 27 6e 6f 72 6d 61 6c 27 20 3d 3e 20 27 20 25 69 6e 64 69 63 61 74 6f 72 25 20 | ......'normal'.=>.'.%indicator%. |
58dc0 | 25 6d 65 73 73 61 67 65 25 27 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 6e 6f 72 6d 61 6c 5f | %message%',.............'normal_ |
58de0 | 6e 6f 5f 61 6e 73 69 27 20 3d 3e 20 27 20 25 6d 65 73 73 61 67 65 25 27 2c 0a 0a 20 20 20 20 20 | no_ansi'.=>.'.%message%',....... |
58e00 | 20 20 20 20 20 20 20 27 76 65 72 62 6f 73 65 27 20 3d 3e 20 27 20 25 69 6e 64 69 63 61 74 6f 72 | .......'verbose'.=>.'.%indicator |
58e20 | 25 20 25 6d 65 73 73 61 67 65 25 20 28 25 65 6c 61 70 73 65 64 3a 36 73 25 29 27 2c 0a 20 20 20 | %.%message%.(%elapsed:6s%)',.... |
58e40 | 20 20 20 20 20 20 20 20 20 27 76 65 72 62 6f 73 65 5f 6e 6f 5f 61 6e 73 69 27 20 3d 3e 20 27 20 | .........'verbose_no_ansi'.=>.'. |
58e60 | 25 6d 65 73 73 61 67 65 25 20 28 25 65 6c 61 70 73 65 64 3a 36 73 25 29 27 2c 0a 0a 20 20 20 20 | %message%.(%elapsed:6s%)',...... |
58e80 | 20 20 20 20 20 20 20 20 27 76 65 72 79 5f 76 65 72 62 6f 73 65 27 20 3d 3e 20 27 20 25 69 6e 64 | ........'very_verbose'.=>.'.%ind |
58ea0 | 69 63 61 74 6f 72 25 20 25 6d 65 73 73 61 67 65 25 20 28 25 65 6c 61 70 73 65 64 3a 36 73 25 2c | icator%.%message%.(%elapsed:6s%, |
58ec0 | 20 25 6d 65 6d 6f 72 79 3a 36 73 25 29 27 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 76 65 72 | .%memory:6s%)',.............'ver |
58ee0 | 79 5f 76 65 72 62 6f 73 65 5f 6e 6f 5f 61 6e 73 69 27 20 3d 3e 20 27 20 25 6d 65 73 73 61 67 65 | y_verbose_no_ansi'.=>.'.%message |
58f00 | 25 20 28 25 65 6c 61 70 73 65 64 3a 36 73 25 2c 20 25 6d 65 6d 6f 72 79 3a 36 73 25 29 27 2c 0a | %.(%elapsed:6s%,.%memory:6s%)',. |
58f20 | 20 20 20 20 20 20 20 20 29 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 | ........);.....}.}.<?php../*..*. |
58f40 | 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 | This.file.is.part.of.the.Symfony |
58f60 | 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e | .package...*..*.(c).Fabien.Poten |
58f80 | 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 | cier.<fabien@symfony.com>..*..*. |
58fa0 | 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e | For.the.full.copyright.and.licen |
58fc0 | 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 | se.information,.please.view.the. |
58fe0 | 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 | LICENSE..*.file.that.was.distrib |
59000 | 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a | uted.with.this.source.code...*/. |
59020 | 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e | .namespace.Symfony\Component\Con |
59040 | 73 6f 6c 65 5c 48 65 6c 70 65 72 3b 0a 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e | sole\Helper;..use.Symfony\Compon |
59060 | 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 4f 75 74 70 75 74 5c 43 6f 6e 73 6f 6c 65 4f 75 74 70 75 74 | ent\Console\Output\ConsoleOutput |
59080 | 49 6e 74 65 72 66 61 63 65 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 | Interface;.use.Symfony\Component |
590a0 | 5c 43 6f 6e 73 6f 6c 65 5c 4f 75 74 70 75 74 5c 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 3b | \Console\Output\OutputInterface; |
590c0 | 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 | .use.Symfony\Component\Console\E |
590e0 | 78 63 65 70 74 69 6f 6e 5c 4c 6f 67 69 63 45 78 63 65 70 74 69 6f 6e 3b 0a 0a 2f 2a 2a 0a 20 2a | xception\LogicException;../**..* |
59100 | 20 54 68 65 20 50 72 6f 67 72 65 73 73 42 61 72 20 70 72 6f 76 69 64 65 73 20 68 65 6c 70 65 72 | .The.ProgressBar.provides.helper |
59120 | 73 20 74 6f 20 64 69 73 70 6c 61 79 20 70 72 6f 67 72 65 73 73 20 6f 75 74 70 75 74 2e 0a 20 2a | s.to.display.progress.output...* |
59140 | 0a 20 2a 20 40 61 75 74 68 6f 72 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 | ..*.@author.Fabien.Potencier.<fa |
59160 | 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 20 40 61 75 74 68 6f 72 20 43 68 72 | bien@symfony.com>..*.@author.Chr |
59180 | 69 73 20 4a 6f 6e 65 73 20 3c 6c 65 65 6b 65 64 40 67 6d 61 69 6c 2e 63 6f 6d 3e 0a 20 2a 2f 0a | is.Jones.<leeked@gmail.com>..*/. |
591a0 | 63 6c 61 73 73 20 50 72 6f 67 72 65 73 73 42 61 72 0a 7b 0a 20 20 20 20 2f 2f 20 6f 70 74 69 6f | class.ProgressBar.{.....//.optio |
591c0 | 6e 73 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 62 61 72 57 69 64 74 68 20 3d 20 32 38 3b 0a 20 | ns.....private.$barWidth.=.28;.. |
591e0 | 20 20 20 70 72 69 76 61 74 65 20 24 62 61 72 43 68 61 72 3b 0a 20 20 20 20 70 72 69 76 61 74 65 | ...private.$barChar;.....private |
59200 | 20 24 65 6d 70 74 79 42 61 72 43 68 61 72 20 3d 20 27 2d 27 3b 0a 20 20 20 20 70 72 69 76 61 74 | .$emptyBarChar.=.'-';.....privat |
59220 | 65 20 24 70 72 6f 67 72 65 73 73 43 68 61 72 20 3d 20 27 3e 27 3b 0a 20 20 20 20 70 72 69 76 61 | e.$progressChar.=.'>';.....priva |
59240 | 74 65 20 24 66 6f 72 6d 61 74 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 69 6e 74 65 72 6e 61 | te.$format;.....private.$interna |
59260 | 6c 46 6f 72 6d 61 74 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 72 65 64 72 61 77 46 72 65 71 | lFormat;.....private.$redrawFreq |
59280 | 20 3d 20 31 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 76 61 72 20 4f 75 74 70 75 | .=.1;....../**......*.@var.Outpu |
592a0 | 74 49 6e 74 65 72 66 61 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 | tInterface......*/.....private.$ |
592c0 | 6f 75 74 70 75 74 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 73 74 65 70 20 3d 20 30 3b 0a 20 | output;.....private.$step.=.0;.. |
592e0 | 20 20 20 70 72 69 76 61 74 65 20 24 6d 61 78 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 73 74 | ...private.$max;.....private.$st |
59300 | 61 72 74 54 69 6d 65 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 73 74 65 70 57 69 64 74 68 3b | artTime;.....private.$stepWidth; |
59320 | 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 70 65 72 63 65 6e 74 20 3d 20 30 2e 30 3b 0a 20 20 20 | .....private.$percent.=.0.0;.... |
59340 | 20 70 72 69 76 61 74 65 20 24 66 6f 72 6d 61 74 4c 69 6e 65 43 6f 75 6e 74 3b 0a 20 20 20 20 70 | .private.$formatLineCount;.....p |
59360 | 72 69 76 61 74 65 20 24 6d 65 73 73 61 67 65 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 | rivate.$messages.=.array();..... |
59380 | 70 72 69 76 61 74 65 20 24 6f 76 65 72 77 72 69 74 65 20 3d 20 74 72 75 65 3b 0a 20 20 20 20 70 | private.$overwrite.=.true;.....p |
593a0 | 72 69 76 61 74 65 20 24 66 69 72 73 74 52 75 6e 20 3d 20 74 72 75 65 3b 0a 0a 20 20 20 20 70 72 | rivate.$firstRun.=.true;......pr |
593c0 | 69 76 61 74 65 20 73 74 61 74 69 63 20 24 66 6f 72 6d 61 74 74 65 72 73 3b 0a 20 20 20 20 70 72 | ivate.static.$formatters;.....pr |
593e0 | 69 76 61 74 65 20 73 74 61 74 69 63 20 24 66 6f 72 6d 61 74 73 3b 0a 0a 20 20 20 20 2f 2a 2a 0a | ivate.static.$formats;....../**. |
59400 | 20 20 20 20 20 2a 20 43 6f 6e 73 74 72 75 63 74 6f 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 | .....*.Constructor.......*...... |
59420 | 2a 20 40 70 61 72 61 6d 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 | *.@param.OutputInterface.$output |
59440 | 20 41 6e 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 | .An.OutputInterface.instance.... |
59460 | 20 20 2a 20 40 70 61 72 61 6d 20 69 6e 74 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 61 78 20 | ..*.@param.int.............$max. |
59480 | 20 20 20 4d 61 78 69 6d 75 6d 20 73 74 65 70 73 20 28 30 20 69 66 20 75 6e 6b 6e 6f 77 6e 29 0a | ...Maximum.steps.(0.if.unknown). |
594a0 | 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 63 6f | .....*/.....public.function.__co |
594c0 | 6e 73 74 72 75 63 74 28 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 2c | nstruct(OutputInterface.$output, |
594e0 | 20 24 6d 61 78 20 3d 20 30 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 6f 75 | .$max.=.0).....{.........if.($ou |
59500 | 74 70 75 74 20 69 6e 73 74 61 6e 63 65 6f 66 20 43 6f 6e 73 6f 6c 65 4f 75 74 70 75 74 49 6e 74 | tput.instanceof.ConsoleOutputInt |
59520 | 65 72 66 61 63 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 75 74 70 75 74 20 3d 20 | erface).{.............$output.=. |
59540 | 24 6f 75 74 70 75 74 2d 3e 67 65 74 45 72 72 6f 72 4f 75 74 70 75 74 28 29 3b 0a 20 20 20 20 20 | $output->getErrorOutput();...... |
59560 | 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 20 3d 20 24 6f | ...}..........$this->output.=.$o |
59580 | 75 74 70 75 74 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 65 74 4d 61 78 53 74 65 70 | utput;.........$this->setMaxStep |
595a0 | 73 28 24 6d 61 78 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 24 74 68 69 73 2d 3e 6f 75 | s($max);..........if.(!$this->ou |
595c0 | 74 70 75 74 2d 3e 69 73 44 65 63 6f 72 61 74 65 64 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | tput->isDecorated()).{.......... |
595e0 | 20 20 20 2f 2f 20 64 69 73 61 62 6c 65 20 6f 76 65 72 77 72 69 74 65 20 77 68 65 6e 20 6f 75 74 | ...//.disable.overwrite.when.out |
59600 | 70 75 74 20 64 6f 65 73 20 6e 6f 74 20 73 75 70 70 6f 72 74 20 41 4e 53 49 20 63 6f 64 65 73 2e | put.does.not.support.ANSI.codes. |
59620 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6f 76 65 72 77 72 69 74 65 20 3d 20 | .............$this->overwrite.=. |
59640 | 66 61 6c 73 65 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 73 65 74 20 61 20 72 65 61 | false;..............//.set.a.rea |
59660 | 73 6f 6e 61 62 6c 65 20 72 65 64 72 61 77 20 66 72 65 71 75 65 6e 63 79 20 73 6f 20 6f 75 74 70 | sonable.redraw.frequency.so.outp |
59680 | 75 74 20 69 73 6e 27 74 20 66 6c 6f 6f 64 65 64 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 | ut.isn't.flooded.............$th |
596a0 | 69 73 2d 3e 73 65 74 52 65 64 72 61 77 46 72 65 71 75 65 6e 63 79 28 24 6d 61 78 20 2f 20 31 30 | is->setRedrawFrequency($max./.10 |
596c0 | 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 74 61 | );.........}..........$this->sta |
596e0 | 72 74 54 69 6d 65 20 3d 20 74 69 6d 65 28 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a | rtTime.=.time();.....}....../**. |
59700 | 20 20 20 20 20 2a 20 53 65 74 73 20 61 20 70 6c 61 63 65 68 6f 6c 64 65 72 20 66 6f 72 6d 61 74 | .....*.Sets.a.placeholder.format |
59720 | 74 65 72 20 66 6f 72 20 61 20 67 69 76 65 6e 20 6e 61 6d 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 | ter.for.a.given.name.......*.... |
59740 | 20 20 2a 20 54 68 69 73 20 6d 65 74 68 6f 64 20 61 6c 73 6f 20 61 6c 6c 6f 77 20 79 6f 75 20 74 | ..*.This.method.also.allow.you.t |
59760 | 6f 20 6f 76 65 72 72 69 64 65 20 61 6e 20 65 78 69 73 74 69 6e 67 20 70 6c 61 63 65 68 6f 6c 64 | o.override.an.existing.placehold |
59780 | 65 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 | er.......*......*.@param.string. |
597a0 | 20 20 24 6e 61 6d 65 20 20 20 20 20 54 68 65 20 70 6c 61 63 65 68 6f 6c 64 65 72 20 6e 61 6d 65 | ..$name.....The.placeholder.name |
597c0 | 20 28 69 6e 63 6c 75 64 69 6e 67 20 74 68 65 20 64 65 6c 69 6d 69 74 65 72 20 63 68 61 72 20 6c | .(including.the.delimiter.char.l |
597e0 | 69 6b 65 20 25 29 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 63 61 6c 6c 61 62 6c 65 20 24 63 | ike.%)......*.@param.callable.$c |
59800 | 61 6c 6c 61 62 6c 65 20 41 20 50 48 50 20 63 61 6c 6c 61 62 6c 65 0a 20 20 20 20 20 2a 2f 0a 20 | allable.A.PHP.callable......*/.. |
59820 | 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 50 6c 61 | ...public.static.function.setPla |
59840 | 63 65 68 6f 6c 64 65 72 46 6f 72 6d 61 74 74 65 72 44 65 66 69 6e 69 74 69 6f 6e 28 24 6e 61 6d | ceholderFormatterDefinition($nam |
59860 | 65 2c 20 63 61 6c 6c 61 62 6c 65 20 24 63 61 6c 6c 61 62 6c 65 29 0a 20 20 20 20 7b 0a 20 20 20 | e,.callable.$callable).....{.... |
59880 | 20 20 20 20 20 69 66 20 28 21 73 65 6c 66 3a 3a 24 66 6f 72 6d 61 74 74 65 72 73 29 20 7b 0a 20 | .....if.(!self::$formatters).{.. |
598a0 | 20 20 20 20 20 20 20 20 20 20 20 73 65 6c 66 3a 3a 24 66 6f 72 6d 61 74 74 65 72 73 20 3d 20 73 | ...........self::$formatters.=.s |
598c0 | 65 6c 66 3a 3a 69 6e 69 74 50 6c 61 63 65 68 6f 6c 64 65 72 46 6f 72 6d 61 74 74 65 72 73 28 29 | elf::initPlaceholderFormatters() |
598e0 | 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 73 65 6c 66 3a 3a 24 66 6f 72 6d | ;.........}..........self::$form |
59900 | 61 74 74 65 72 73 5b 24 6e 61 6d 65 5d 20 3d 20 24 63 61 6c 6c 61 62 6c 65 3b 0a 20 20 20 20 7d | atters[$name].=.$callable;.....} |
59920 | 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 70 6c 61 63 65 68 | ....../**......*.Gets.the.placeh |
59940 | 6f 6c 64 65 72 20 66 6f 72 6d 61 74 74 65 72 20 66 6f 72 20 61 20 67 69 76 65 6e 20 6e 61 6d 65 | older.formatter.for.a.given.name |
59960 | 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6e | .......*......*.@param.string.$n |
59980 | 61 6d 65 20 54 68 65 20 70 6c 61 63 65 68 6f 6c 64 65 72 20 6e 61 6d 65 20 28 69 6e 63 6c 75 64 | ame.The.placeholder.name.(includ |
599a0 | 69 6e 67 20 74 68 65 20 64 65 6c 69 6d 69 74 65 72 20 63 68 61 72 20 6c 69 6b 65 20 25 29 0a 20 | ing.the.delimiter.char.like.%).. |
599c0 | 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 63 61 6c 6c 61 62 6c 65 7c 6e 75 | ....*......*.@return.callable|nu |
599e0 | 6c 6c 20 41 20 50 48 50 20 63 61 6c 6c 61 62 6c 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 | ll.A.PHP.callable......*/.....pu |
59a00 | 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 50 6c 61 63 65 68 6f 6c | blic.static.function.getPlacehol |
59a20 | 64 65 72 46 6f 72 6d 61 74 74 65 72 44 65 66 69 6e 69 74 69 6f 6e 28 24 6e 61 6d 65 29 0a 20 20 | derFormatterDefinition($name)... |
59a40 | 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 73 65 6c 66 3a 3a 24 66 6f 72 6d 61 74 74 65 | ..{.........if.(!self::$formatte |
59a60 | 72 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 73 65 6c 66 3a 3a 24 66 6f 72 6d 61 74 74 | rs).{.............self::$formatt |
59a80 | 65 72 73 20 3d 20 73 65 6c 66 3a 3a 69 6e 69 74 50 6c 61 63 65 68 6f 6c 64 65 72 46 6f 72 6d 61 | ers.=.self::initPlaceholderForma |
59aa0 | 74 74 65 72 73 28 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 | tters();.........}..........retu |
59ac0 | 72 6e 20 69 73 73 65 74 28 73 65 6c 66 3a 3a 24 66 6f 72 6d 61 74 74 65 72 73 5b 24 6e 61 6d 65 | rn.isset(self::$formatters[$name |
59ae0 | 5d 29 20 3f 20 73 65 6c 66 3a 3a 24 66 6f 72 6d 61 74 74 65 72 73 5b 24 6e 61 6d 65 5d 20 3a 20 | ]).?.self::$formatters[$name].:. |
59b00 | 6e 75 6c 6c 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 | null;.....}....../**......*.Sets |
59b20 | 20 61 20 66 6f 72 6d 61 74 20 66 6f 72 20 61 20 67 69 76 65 6e 20 6e 61 6d 65 2e 0a 20 20 20 20 | .a.format.for.a.given.name...... |
59b40 | 20 2a 0a 20 20 20 20 20 2a 20 54 68 69 73 20 6d 65 74 68 6f 64 20 61 6c 73 6f 20 61 6c 6c 6f 77 | .*......*.This.method.also.allow |
59b60 | 20 79 6f 75 20 74 6f 20 6f 76 65 72 72 69 64 65 20 61 6e 20 65 78 69 73 74 69 6e 67 20 66 6f 72 | .you.to.override.an.existing.for |
59b80 | 6d 61 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 | mat.......*......*.@param.string |
59ba0 | 20 24 6e 61 6d 65 20 20 20 54 68 65 20 66 6f 72 6d 61 74 20 6e 61 6d 65 0a 20 20 20 20 20 2a 20 | .$name...The.format.name......*. |
59bc0 | 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 66 6f 72 6d 61 74 20 41 20 66 6f 72 6d 61 74 20 73 | @param.string.$format.A.format.s |
59be0 | 74 72 69 6e 67 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 | tring......*/.....public.static. |
59c00 | 66 75 6e 63 74 69 6f 6e 20 73 65 74 46 6f 72 6d 61 74 44 65 66 69 6e 69 74 69 6f 6e 28 24 6e 61 | function.setFormatDefinition($na |
59c20 | 6d 65 2c 20 24 66 6f 72 6d 61 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 | me,.$format).....{.........if.(! |
59c40 | 73 65 6c 66 3a 3a 24 66 6f 72 6d 61 74 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 73 65 | self::$formats).{.............se |
59c60 | 6c 66 3a 3a 24 66 6f 72 6d 61 74 73 20 3d 20 73 65 6c 66 3a 3a 69 6e 69 74 46 6f 72 6d 61 74 73 | lf::$formats.=.self::initFormats |
59c80 | 28 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 73 65 6c 66 3a 3a 24 66 6f | ();.........}..........self::$fo |
59ca0 | 72 6d 61 74 73 5b 24 6e 61 6d 65 5d 20 3d 20 24 66 6f 72 6d 61 74 3b 0a 20 20 20 20 7d 0a 0a 20 | rmats[$name].=.$format;.....}... |
59cc0 | 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 66 6f 72 6d 61 74 20 66 6f | .../**......*.Gets.the.format.fo |
59ce0 | 72 20 61 20 67 69 76 65 6e 20 6e 61 6d 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 | r.a.given.name.......*......*.@p |
59d00 | 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6e 61 6d 65 20 54 68 65 20 66 6f 72 6d 61 74 20 6e 61 6d | aram.string.$name.The.format.nam |
59d20 | 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 7c 6e | e......*......*.@return.string|n |
59d40 | 75 6c 6c 20 41 20 66 6f 72 6d 61 74 20 73 74 72 69 6e 67 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 | ull.A.format.string......*/..... |
59d60 | 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 46 6f 72 6d 61 74 | public.static.function.getFormat |
59d80 | 44 65 66 69 6e 69 74 69 6f 6e 28 24 6e 61 6d 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | Definition($name).....{......... |
59da0 | 69 66 20 28 21 73 65 6c 66 3a 3a 24 66 6f 72 6d 61 74 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | if.(!self::$formats).{.......... |
59dc0 | 20 20 20 73 65 6c 66 3a 3a 24 66 6f 72 6d 61 74 73 20 3d 20 73 65 6c 66 3a 3a 69 6e 69 74 46 6f | ...self::$formats.=.self::initFo |
59de0 | 72 6d 61 74 73 28 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 | rmats();.........}..........retu |
59e00 | 72 6e 20 69 73 73 65 74 28 73 65 6c 66 3a 3a 24 66 6f 72 6d 61 74 73 5b 24 6e 61 6d 65 5d 29 20 | rn.isset(self::$formats[$name]). |
59e20 | 3f 20 73 65 6c 66 3a 3a 24 66 6f 72 6d 61 74 73 5b 24 6e 61 6d 65 5d 20 3a 20 6e 75 6c 6c 3b 0a | ?.self::$formats[$name].:.null;. |
59e40 | 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 41 73 73 6f 63 69 61 74 65 73 | ....}....../**......*.Associates |
59e60 | 20 61 20 74 65 78 74 20 77 69 74 68 20 61 20 6e 61 6d 65 64 20 70 6c 61 63 65 68 6f 6c 64 65 72 | .a.text.with.a.named.placeholder |
59e80 | 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 54 68 65 20 74 65 78 74 20 69 73 20 64 69 73 70 | .......*......*.The.text.is.disp |
59ea0 | 6c 61 79 65 64 20 77 68 65 6e 20 74 68 65 20 70 72 6f 67 72 65 73 73 20 62 61 72 20 69 73 20 72 | layed.when.the.progress.bar.is.r |
59ec0 | 65 6e 64 65 72 65 64 20 62 75 74 20 6f 6e 6c 79 0a 20 20 20 20 20 2a 20 77 68 65 6e 20 74 68 65 | endered.but.only......*.when.the |
59ee0 | 20 63 6f 72 72 65 73 70 6f 6e 64 69 6e 67 20 70 6c 61 63 65 68 6f 6c 64 65 72 20 69 73 20 70 61 | .corresponding.placeholder.is.pa |
59f00 | 72 74 20 6f 66 20 74 68 65 20 63 75 73 74 6f 6d 20 66 6f 72 6d 61 74 20 6c 69 6e 65 0a 20 20 20 | rt.of.the.custom.format.line.... |
59f20 | 20 20 2a 20 28 62 79 20 77 72 61 70 70 69 6e 67 20 74 68 65 20 6e 61 6d 65 20 77 69 74 68 20 25 | ..*.(by.wrapping.the.name.with.% |
59f40 | 29 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 | ).......*......*.@param.string.$ |
59f60 | 6d 65 73 73 61 67 65 20 54 68 65 20 74 65 78 74 20 74 6f 20 61 73 73 6f 63 69 61 74 65 20 77 69 | message.The.text.to.associate.wi |
59f80 | 74 68 20 74 68 65 20 70 6c 61 63 65 68 6f 6c 64 65 72 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d | th.the.placeholder......*.@param |
59fa0 | 20 73 74 72 69 6e 67 20 24 6e 61 6d 65 20 20 20 20 54 68 65 20 6e 61 6d 65 20 6f 66 20 74 68 65 | .string.$name....The.name.of.the |
59fc0 | 20 70 6c 61 63 65 68 6f 6c 64 65 72 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 | .placeholder......*/.....public. |
59fe0 | 66 75 6e 63 74 69 6f 6e 20 73 65 74 4d 65 73 73 61 67 65 28 24 6d 65 73 73 61 67 65 2c 20 24 6e | function.setMessage($message,.$n |
5a000 | 61 6d 65 20 3d 20 27 6d 65 73 73 61 67 65 27 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 | ame.=.'message').....{.........$ |
5a020 | 74 68 69 73 2d 3e 6d 65 73 73 61 67 65 73 5b 24 6e 61 6d 65 5d 20 3d 20 24 6d 65 73 73 61 67 65 | this->messages[$name].=.$message |
5a040 | 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 | ;.....}......public.function.get |
5a060 | 4d 65 73 73 61 67 65 28 24 6e 61 6d 65 20 3d 20 27 6d 65 73 73 61 67 65 27 29 0a 20 20 20 20 7b | Message($name.=.'message').....{ |
5a080 | 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 6d 65 73 73 61 67 65 73 5b | .........return.$this->messages[ |
5a0a0 | 24 6e 61 6d 65 5d 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 | $name];.....}....../**......*.Ge |
5a0c0 | 74 73 20 74 68 65 20 70 72 6f 67 72 65 73 73 20 62 61 72 20 73 74 61 72 74 20 74 69 6d 65 2e 0a | ts.the.progress.bar.start.time.. |
5a0e0 | 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 69 6e 74 20 54 68 65 20 70 72 | .....*......*.@return.int.The.pr |
5a100 | 6f 67 72 65 73 73 20 62 61 72 20 73 74 61 72 74 20 74 69 6d 65 0a 20 20 20 20 20 2a 2f 0a 20 20 | ogress.bar.start.time......*/... |
5a120 | 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 53 74 61 72 74 54 69 6d 65 28 29 | ..public.function.getStartTime() |
5a140 | 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 73 74 61 | .....{.........return.$this->sta |
5a160 | 72 74 54 69 6d 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 | rtTime;.....}....../**......*.Ge |
5a180 | 74 73 20 74 68 65 20 70 72 6f 67 72 65 73 73 20 62 61 72 20 6d 61 78 69 6d 61 6c 20 73 74 65 70 | ts.the.progress.bar.maximal.step |
5a1a0 | 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 69 6e 74 20 54 68 65 | s.......*......*.@return.int.The |
5a1c0 | 20 70 72 6f 67 72 65 73 73 20 62 61 72 20 6d 61 78 20 73 74 65 70 73 0a 20 20 20 20 20 2a 2f 0a | .progress.bar.max.steps......*/. |
5a1e0 | 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 4d 61 78 53 74 65 70 73 28 | ....public.function.getMaxSteps( |
5a200 | 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 6d 61 | ).....{.........return.$this->ma |
5a220 | 78 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 | x;.....}....../**......*.Gets.th |
5a240 | 65 20 63 75 72 72 65 6e 74 20 73 74 65 70 20 70 6f 73 69 74 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a | e.current.step.position.......*. |
5a260 | 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 69 6e 74 20 54 68 65 20 70 72 6f 67 72 65 73 73 20 | .....*.@return.int.The.progress. |
5a280 | 62 61 72 20 73 74 65 70 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 | bar.step......*/.....public.func |
5a2a0 | 74 69 6f 6e 20 67 65 74 50 72 6f 67 72 65 73 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 | tion.getProgress().....{........ |
5a2c0 | 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 73 74 65 70 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 | .return.$this->step;.....}...... |
5a2e0 | 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 70 72 6f 67 72 65 73 73 20 62 61 72 | /**......*.Gets.the.progress.bar |
5a300 | 20 73 74 65 70 20 77 69 64 74 68 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 | .step.width.......*......*.@retu |
5a320 | 72 6e 20 69 6e 74 20 54 68 65 20 70 72 6f 67 72 65 73 73 20 62 61 72 20 73 74 65 70 20 77 69 64 | rn.int.The.progress.bar.step.wid |
5a340 | 74 68 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 | th......*/.....private.function. |
5a360 | 67 65 74 53 74 65 70 57 69 64 74 68 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 | getStepWidth().....{.........ret |
5a380 | 75 72 6e 20 24 74 68 69 73 2d 3e 73 74 65 70 57 69 64 74 68 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 | urn.$this->stepWidth;.....}..... |
5a3a0 | 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 63 75 72 72 65 6e 74 20 70 72 6f | ./**......*.Gets.the.current.pro |
5a3c0 | 67 72 65 73 73 20 62 61 72 20 70 65 72 63 65 6e 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a | gress.bar.percent.......*......* |
5a3e0 | 20 40 72 65 74 75 72 6e 20 66 6c 6f 61 74 20 54 68 65 20 63 75 72 72 65 6e 74 20 70 72 6f 67 72 | .@return.float.The.current.progr |
5a400 | 65 73 73 20 62 61 72 20 70 65 72 63 65 6e 74 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c | ess.bar.percent......*/.....publ |
5a420 | 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 50 72 6f 67 72 65 73 73 50 65 72 63 65 6e 74 28 29 | ic.function.getProgressPercent() |
5a440 | 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 70 65 72 | .....{.........return.$this->per |
5a460 | 63 65 6e 74 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 | cent;.....}....../**......*.Sets |
5a480 | 20 74 68 65 20 70 72 6f 67 72 65 73 73 20 62 61 72 20 77 69 64 74 68 2e 0a 20 20 20 20 20 2a 0a | .the.progress.bar.width.......*. |
5a4a0 | 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 69 6e 74 20 24 73 69 7a 65 20 54 68 65 20 70 72 6f 67 | .....*.@param.int.$size.The.prog |
5a4c0 | 72 65 73 73 20 62 61 72 20 73 69 7a 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 | ress.bar.size......*/.....public |
5a4e0 | 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 42 61 72 57 69 64 74 68 28 24 73 69 7a 65 29 0a 20 20 20 | .function.setBarWidth($size).... |
5a500 | 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 62 61 72 57 69 64 74 68 20 3d 20 28 69 6e | .{.........$this->barWidth.=.(in |
5a520 | 74 29 20 24 73 69 7a 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 | t).$size;.....}....../**......*. |
5a540 | 47 65 74 73 20 74 68 65 20 70 72 6f 67 72 65 73 73 20 62 61 72 20 77 69 64 74 68 2e 0a 20 20 20 | Gets.the.progress.bar.width..... |
5a560 | 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 69 6e 74 20 54 68 65 20 70 72 6f 67 72 | ..*......*.@return.int.The.progr |
5a580 | 65 73 73 20 62 61 72 20 73 69 7a 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 | ess.bar.size......*/.....public. |
5a5a0 | 66 75 6e 63 74 69 6f 6e 20 67 65 74 42 61 72 57 69 64 74 68 28 29 0a 20 20 20 20 7b 0a 20 20 20 | function.getBarWidth().....{.... |
5a5c0 | 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 62 61 72 57 69 64 74 68 3b 0a 20 20 20 | .....return.$this->barWidth;.... |
5a5e0 | 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 74 68 65 20 62 61 72 20 | .}....../**......*.Sets.the.bar. |
5a600 | 63 68 61 72 61 63 74 65 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 | character.......*......*.@param. |
5a620 | 73 74 72 69 6e 67 20 24 63 68 61 72 20 41 20 63 68 61 72 61 63 74 65 72 0a 20 20 20 20 20 2a 2f | string.$char.A.character......*/ |
5a640 | 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 42 61 72 43 68 61 72 61 | .....public.function.setBarChara |
5a660 | 63 74 65 72 28 24 63 68 61 72 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d | cter($char).....{.........$this- |
5a680 | 3e 62 61 72 43 68 61 72 20 3d 20 24 63 68 61 72 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a | >barChar.=.$char;.....}....../** |
5a6a0 | 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 62 61 72 20 63 68 61 72 61 63 74 65 72 2e 0a | ......*.Gets.the.bar.character.. |
5a6c0 | 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 20 41 20 63 | .....*......*.@return.string.A.c |
5a6e0 | 68 61 72 61 63 74 65 72 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 | haracter......*/.....public.func |
5a700 | 74 69 6f 6e 20 67 65 74 42 61 72 43 68 61 72 61 63 74 65 72 28 29 0a 20 20 20 20 7b 0a 20 20 20 | tion.getBarCharacter().....{.... |
5a720 | 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 74 68 69 73 2d 3e 62 61 72 43 68 61 72 | .....if.(null.===.$this->barChar |
5a740 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 6d 61 | ).{.............return.$this->ma |
5a760 | 78 20 3f 20 27 3d 27 20 3a 20 24 74 68 69 73 2d 3e 65 6d 70 74 79 42 61 72 43 68 61 72 3b 0a 20 | x.?.'='.:.$this->emptyBarChar;.. |
5a780 | 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e | .......}..........return.$this-> |
5a7a0 | 62 61 72 43 68 61 72 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 | barChar;.....}....../**......*.S |
5a7c0 | 65 74 73 20 74 68 65 20 65 6d 70 74 79 20 62 61 72 20 63 68 61 72 61 63 74 65 72 2e 0a 20 20 20 | ets.the.empty.bar.character..... |
5a7e0 | 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 63 68 61 72 20 41 | ..*......*.@param.string.$char.A |
5a800 | 20 63 68 61 72 61 63 74 65 72 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 | .character......*/.....public.fu |
5a820 | 6e 63 74 69 6f 6e 20 73 65 74 45 6d 70 74 79 42 61 72 43 68 61 72 61 63 74 65 72 28 24 63 68 61 | nction.setEmptyBarCharacter($cha |
5a840 | 72 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 65 6d 70 74 79 42 61 72 | r).....{.........$this->emptyBar |
5a860 | 43 68 61 72 20 3d 20 24 63 68 61 72 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 | Char.=.$char;.....}....../**.... |
5a880 | 20 20 2a 20 47 65 74 73 20 74 68 65 20 65 6d 70 74 79 20 62 61 72 20 63 68 61 72 61 63 74 65 72 | ..*.Gets.the.empty.bar.character |
5a8a0 | 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 20 41 | .......*......*.@return.string.A |
5a8c0 | 20 63 68 61 72 61 63 74 65 72 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 | .character......*/.....public.fu |
5a8e0 | 6e 63 74 69 6f 6e 20 67 65 74 45 6d 70 74 79 42 61 72 43 68 61 72 61 63 74 65 72 28 29 0a 20 20 | nction.getEmptyBarCharacter()... |
5a900 | 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 65 6d 70 74 79 42 | ..{.........return.$this->emptyB |
5a920 | 61 72 43 68 61 72 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 | arChar;.....}....../**......*.Se |
5a940 | 74 73 20 74 68 65 20 70 72 6f 67 72 65 73 73 20 62 61 72 20 63 68 61 72 61 63 74 65 72 2e 0a 20 | ts.the.progress.bar.character... |
5a960 | 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 63 68 61 72 | ....*......*.@param.string.$char |
5a980 | 20 41 20 63 68 61 72 61 63 74 65 72 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 | .A.character......*/.....public. |
5a9a0 | 66 75 6e 63 74 69 6f 6e 20 73 65 74 50 72 6f 67 72 65 73 73 43 68 61 72 61 63 74 65 72 28 24 63 | function.setProgressCharacter($c |
5a9c0 | 68 61 72 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 70 72 6f 67 72 65 | har).....{.........$this->progre |
5a9e0 | 73 73 43 68 61 72 20 3d 20 24 63 68 61 72 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 | ssChar.=.$char;.....}....../**.. |
5aa00 | 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 70 72 6f 67 72 65 73 73 20 62 61 72 20 63 68 61 72 | ....*.Gets.the.progress.bar.char |
5aa20 | 61 63 74 65 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 | acter.......*......*.@return.str |
5aa40 | 69 6e 67 20 41 20 63 68 61 72 61 63 74 65 72 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c | ing.A.character......*/.....publ |
5aa60 | 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 50 72 6f 67 72 65 73 73 43 68 61 72 61 63 74 65 72 | ic.function.getProgressCharacter |
5aa80 | 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 70 | ().....{.........return.$this->p |
5aaa0 | 72 6f 67 72 65 73 73 43 68 61 72 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 | rogressChar;.....}....../**..... |
5aac0 | 20 2a 20 53 65 74 73 20 74 68 65 20 70 72 6f 67 72 65 73 73 20 62 61 72 20 66 6f 72 6d 61 74 2e | .*.Sets.the.progress.bar.format. |
5aae0 | 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 66 6f | ......*......*.@param.string.$fo |
5ab00 | 72 6d 61 74 20 54 68 65 20 66 6f 72 6d 61 74 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c | rmat.The.format......*/.....publ |
5ab20 | 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 46 6f 72 6d 61 74 28 24 66 6f 72 6d 61 74 29 0a 20 | ic.function.setFormat($format).. |
5ab40 | 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 66 6f 72 6d 61 74 20 3d 20 6e 75 6c | ...{.........$this->format.=.nul |
5ab60 | 6c 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 69 6e 74 65 72 6e 61 6c 46 6f 72 6d 61 74 | l;.........$this->internalFormat |
5ab80 | 20 3d 20 24 66 6f 72 6d 61 74 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 | .=.$format;.....}....../**...... |
5aba0 | 2a 20 53 65 74 73 20 74 68 65 20 72 65 64 72 61 77 20 66 72 65 71 75 65 6e 63 79 2e 0a 20 20 20 | *.Sets.the.redraw.frequency..... |
5abc0 | 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 69 6e 74 7c 66 6c 6f 61 74 20 24 66 72 65 | ..*......*.@param.int|float.$fre |
5abe0 | 71 20 54 68 65 20 66 72 65 71 75 65 6e 63 79 20 69 6e 20 73 74 65 70 73 0a 20 20 20 20 20 2a 2f | q.The.frequency.in.steps......*/ |
5ac00 | 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 52 65 64 72 61 77 46 72 | .....public.function.setRedrawFr |
5ac20 | 65 71 75 65 6e 63 79 28 24 66 72 65 71 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 | equency($freq).....{.........$th |
5ac40 | 69 73 2d 3e 72 65 64 72 61 77 46 72 65 71 20 3d 20 6d 61 78 28 28 69 6e 74 29 20 24 66 72 65 71 | is->redrawFreq.=.max((int).$freq |
5ac60 | 2c 20 31 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 74 61 72 | ,.1);.....}....../**......*.Star |
5ac80 | 74 73 20 74 68 65 20 70 72 6f 67 72 65 73 73 20 6f 75 74 70 75 74 2e 0a 20 20 20 20 20 2a 0a 20 | ts.the.progress.output.......*.. |
5aca0 | 20 20 20 20 2a 20 40 70 61 72 61 6d 20 69 6e 74 7c 6e 75 6c 6c 20 24 6d 61 78 20 4e 75 6d 62 65 | ....*.@param.int|null.$max.Numbe |
5acc0 | 72 20 6f 66 20 73 74 65 70 73 20 74 6f 20 63 6f 6d 70 6c 65 74 65 20 74 68 65 20 62 61 72 20 28 | r.of.steps.to.complete.the.bar.( |
5ace0 | 30 20 69 66 20 69 6e 64 65 74 65 72 6d 69 6e 61 74 65 29 2c 20 6e 75 6c 6c 20 74 6f 20 6c 65 61 | 0.if.indeterminate),.null.to.lea |
5ad00 | 76 65 20 75 6e 63 68 61 6e 67 65 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 | ve.unchanged......*/.....public. |
5ad20 | 66 75 6e 63 74 69 6f 6e 20 73 74 61 72 74 28 24 6d 61 78 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 | function.start($max.=.null)..... |
5ad40 | 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 74 61 72 74 54 69 6d 65 20 3d 20 74 69 6d | {.........$this->startTime.=.tim |
5ad60 | 65 28 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 74 65 70 20 3d 20 30 3b 0a 20 20 | e();.........$this->step.=.0;... |
5ad80 | 20 20 20 20 20 20 24 74 68 69 73 2d 3e 70 65 72 63 65 6e 74 20 3d 20 30 2e 30 3b 0a 0a 20 20 20 | ......$this->percent.=.0.0;..... |
5ada0 | 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 21 3d 3d 20 24 6d 61 78 29 20 7b 0a 20 20 20 20 20 20 | .....if.(null.!==.$max).{....... |
5adc0 | 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 65 74 4d 61 78 53 74 65 70 73 28 24 6d 61 78 29 3b 0a | ......$this->setMaxSteps($max);. |
5ade0 | 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 64 69 73 70 6c 61 | ........}..........$this->displa |
5ae00 | 79 28 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 41 64 76 61 6e | y();.....}....../**......*.Advan |
5ae20 | 63 65 73 20 74 68 65 20 70 72 6f 67 72 65 73 73 20 6f 75 74 70 75 74 20 58 20 73 74 65 70 73 2e | ces.the.progress.output.X.steps. |
5ae40 | 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 69 6e 74 20 24 73 74 65 70 20 | ......*......*.@param.int.$step. |
5ae60 | 4e 75 6d 62 65 72 20 6f 66 20 73 74 65 70 73 20 74 6f 20 61 64 76 61 6e 63 65 0a 20 20 20 20 20 | Number.of.steps.to.advance...... |
5ae80 | 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 4c 6f 67 69 63 45 78 63 65 70 74 69 6f 6e 0a | *......*.@throws.LogicException. |
5aea0 | 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 61 64 76 61 | .....*/.....public.function.adva |
5aec0 | 6e 63 65 28 24 73 74 65 70 20 3d 20 31 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 | nce($step.=.1).....{.........$th |
5aee0 | 69 73 2d 3e 73 65 74 50 72 6f 67 72 65 73 73 28 24 74 68 69 73 2d 3e 73 74 65 70 20 2b 20 24 73 | is->setProgress($this->step.+.$s |
5af00 | 74 65 70 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 | tep);.....}....../**......*.Sets |
5af20 | 20 77 68 65 74 68 65 72 20 74 6f 20 6f 76 65 72 77 72 69 74 65 20 74 68 65 20 70 72 6f 67 72 65 | .whether.to.overwrite.the.progre |
5af40 | 73 73 62 61 72 2c 20 66 61 6c 73 65 20 66 6f 72 20 6e 65 77 20 6c 69 6e 65 2e 0a 20 20 20 20 20 | ssbar,.false.for.new.line....... |
5af60 | 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 62 6f 6f 6c 20 24 6f 76 65 72 77 72 69 74 65 0a | *......*.@param.bool.$overwrite. |
5af80 | 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 4f | .....*/.....public.function.setO |
5afa0 | 76 65 72 77 72 69 74 65 28 24 6f 76 65 72 77 72 69 74 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 | verwrite($overwrite).....{...... |
5afc0 | 20 20 20 24 74 68 69 73 2d 3e 6f 76 65 72 77 72 69 74 65 20 3d 20 28 62 6f 6f 6c 29 20 24 6f 76 | ...$this->overwrite.=.(bool).$ov |
5afe0 | 65 72 77 72 69 74 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 | erwrite;.....}....../**......*.S |
5b000 | 65 74 73 20 74 68 65 20 63 75 72 72 65 6e 74 20 70 72 6f 67 72 65 73 73 2e 0a 20 20 20 20 20 2a | ets.the.current.progress.......* |
5b020 | 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 69 6e 74 20 24 73 74 65 70 20 54 68 65 20 63 75 72 | ......*.@param.int.$step.The.cur |
5b040 | 72 65 6e 74 20 70 72 6f 67 72 65 73 73 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 | rent.progress......*......*.@thr |
5b060 | 6f 77 73 20 4c 6f 67 69 63 45 78 63 65 70 74 69 6f 6e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 | ows.LogicException......*/.....p |
5b080 | 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 50 72 6f 67 72 65 73 73 28 24 73 74 65 70 | ublic.function.setProgress($step |
5b0a0 | 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 73 74 65 70 20 3d 20 28 69 6e 74 29 20 24 73 | ).....{.........$step.=.(int).$s |
5b0c0 | 74 65 70 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 73 74 65 70 20 3c 20 24 74 68 69 73 2d 3e | tep;.........if.($step.<.$this-> |
5b0e0 | 73 74 65 70 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 4c 6f | step).{.............throw.new.Lo |
5b100 | 67 69 63 45 78 63 65 70 74 69 6f 6e 28 27 59 6f 75 20 63 61 6e 5c 27 74 20 72 65 67 72 65 73 73 | gicException('You.can\'t.regress |
5b120 | 20 74 68 65 20 70 72 6f 67 72 65 73 73 20 62 61 72 2e 27 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a | .the.progress.bar.');.........}. |
5b140 | 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 74 68 69 73 2d 3e 6d 61 78 20 26 26 20 24 73 74 65 70 | .........if.($this->max.&&.$step |
5b160 | 20 3e 20 24 74 68 69 73 2d 3e 6d 61 78 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 | .>.$this->max).{.............$th |
5b180 | 69 73 2d 3e 6d 61 78 20 3d 20 24 73 74 65 70 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 | is->max.=.$step;.........}...... |
5b1a0 | 20 20 20 20 24 70 72 65 76 50 65 72 69 6f 64 20 3d 20 28 69 6e 74 29 20 28 24 74 68 69 73 2d 3e | ....$prevPeriod.=.(int).($this-> |
5b1c0 | 73 74 65 70 20 2f 20 24 74 68 69 73 2d 3e 72 65 64 72 61 77 46 72 65 71 29 3b 0a 20 20 20 20 20 | step./.$this->redrawFreq);...... |
5b1e0 | 20 20 20 24 63 75 72 72 50 65 72 69 6f 64 20 3d 20 28 69 6e 74 29 20 28 24 73 74 65 70 20 2f 20 | ...$currPeriod.=.(int).($step./. |
5b200 | 24 74 68 69 73 2d 3e 72 65 64 72 61 77 46 72 65 71 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 | $this->redrawFreq);.........$thi |
5b220 | 73 2d 3e 73 74 65 70 20 3d 20 24 73 74 65 70 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e | s->step.=.$step;.........$this-> |
5b240 | 70 65 72 63 65 6e 74 20 3d 20 24 74 68 69 73 2d 3e 6d 61 78 20 3f 20 28 66 6c 6f 61 74 29 20 24 | percent.=.$this->max.?.(float).$ |
5b260 | 74 68 69 73 2d 3e 73 74 65 70 20 2f 20 24 74 68 69 73 2d 3e 6d 61 78 20 3a 20 30 3b 0a 20 20 20 | this->step./.$this->max.:.0;.... |
5b280 | 20 20 20 20 20 69 66 20 28 24 70 72 65 76 50 65 72 69 6f 64 20 21 3d 3d 20 24 63 75 72 72 50 65 | .....if.($prevPeriod.!==.$currPe |
5b2a0 | 72 69 6f 64 20 7c 7c 20 24 74 68 69 73 2d 3e 6d 61 78 20 3d 3d 3d 20 24 73 74 65 70 29 20 7b 0a | riod.||.$this->max.===.$step).{. |
5b2c0 | 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 64 69 73 70 6c 61 79 28 29 3b 0a 20 20 | ............$this->display();... |
5b2e0 | 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 46 69 | ......}.....}....../**......*.Fi |
5b300 | 6e 69 73 68 65 73 20 74 68 65 20 70 72 6f 67 72 65 73 73 20 6f 75 74 70 75 74 2e 0a 20 20 20 20 | nishes.the.progress.output...... |
5b320 | 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 66 69 6e 69 73 68 28 29 | .*/.....public.function.finish() |
5b340 | 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 24 74 68 69 73 2d 3e 6d 61 78 29 20 | .....{.........if.(!$this->max). |
5b360 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6d 61 78 20 3d 20 24 74 68 69 73 | {.............$this->max.=.$this |
5b380 | 2d 3e 73 74 65 70 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 | ->step;.........}..........if.($ |
5b3a0 | 74 68 69 73 2d 3e 73 74 65 70 20 3d 3d 3d 20 24 74 68 69 73 2d 3e 6d 61 78 20 26 26 20 21 24 74 | this->step.===.$this->max.&&.!$t |
5b3c0 | 68 69 73 2d 3e 6f 76 65 72 77 72 69 74 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f | his->overwrite).{.............// |
5b3e0 | 20 70 72 65 76 65 6e 74 20 64 6f 75 62 6c 65 20 31 30 30 25 20 6f 75 74 70 75 74 0a 20 20 20 20 | .prevent.double.100%.output..... |
5b400 | 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 | ........return;.........}....... |
5b420 | 20 20 20 24 74 68 69 73 2d 3e 73 65 74 50 72 6f 67 72 65 73 73 28 24 74 68 69 73 2d 3e 6d 61 78 | ...$this->setProgress($this->max |
5b440 | 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 4f 75 74 70 75 74 73 | );.....}....../**......*.Outputs |
5b460 | 20 74 68 65 20 63 75 72 72 65 6e 74 20 70 72 6f 67 72 65 73 73 20 73 74 72 69 6e 67 2e 0a 20 20 | .the.current.progress.string.... |
5b480 | 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 64 69 73 70 6c 61 | ...*/.....public.function.displa |
5b4a0 | 79 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 4f 75 74 70 75 74 49 6e 74 65 | y().....{.........if.(OutputInte |
5b4c0 | 72 66 61 63 65 3a 3a 56 45 52 42 4f 53 49 54 59 5f 51 55 49 45 54 20 3d 3d 3d 20 24 74 68 69 73 | rface::VERBOSITY_QUIET.===.$this |
5b4e0 | 2d 3e 6f 75 74 70 75 74 2d 3e 67 65 74 56 65 72 62 6f 73 69 74 79 28 29 29 20 7b 0a 20 20 20 20 | ->output->getVerbosity()).{..... |
5b500 | 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 | ........return;.........}....... |
5b520 | 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 74 68 69 73 2d 3e 66 6f 72 6d 61 74 29 20 7b | ...if.(null.===.$this->format).{ |
5b540 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 65 74 52 65 61 6c 46 6f 72 6d 61 | .............$this->setRealForma |
5b560 | 74 28 24 74 68 69 73 2d 3e 69 6e 74 65 72 6e 61 6c 46 6f 72 6d 61 74 20 3f 3a 20 24 74 68 69 73 | t($this->internalFormat.?:.$this |
5b580 | 2d 3e 64 65 74 65 72 6d 69 6e 65 42 65 73 74 46 6f 72 6d 61 74 28 29 29 3b 0a 20 20 20 20 20 20 | ->determineBestFormat());....... |
5b5a0 | 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6f 76 65 72 77 72 69 74 65 28 70 72 | ..}..........$this->overwrite(pr |
5b5c0 | 65 67 5f 72 65 70 6c 61 63 65 5f 63 61 6c 6c 62 61 63 6b 28 22 7b 25 28 5b 61 2d 7a 5c 2d 5f 5d | eg_replace_callback("{%([a-z\-_] |
5b5e0 | 2b 29 28 3f 3a 5c 3a 28 5b 5e 25 5d 2b 29 29 3f 25 7d 69 22 2c 20 66 75 6e 63 74 69 6f 6e 20 28 | +)(?:\:([^%]+))?%}i",.function.( |
5b600 | 24 6d 61 74 63 68 65 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 66 6f 72 | $matches).{.............if.($for |
5b620 | 6d 61 74 74 65 72 20 3d 20 24 74 68 69 73 3a 3a 67 65 74 50 6c 61 63 65 68 6f 6c 64 65 72 46 6f | matter.=.$this::getPlaceholderFo |
5b640 | 72 6d 61 74 74 65 72 44 65 66 69 6e 69 74 69 6f 6e 28 24 6d 61 74 63 68 65 73 5b 31 5d 29 29 20 | rmatterDefinition($matches[1])). |
5b660 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 65 78 74 20 3d 20 63 61 6c 6c 5f 75 | {.................$text.=.call_u |
5b680 | 73 65 72 5f 66 75 6e 63 28 24 66 6f 72 6d 61 74 74 65 72 2c 20 24 74 68 69 73 2c 20 24 74 68 69 | ser_func($formatter,.$this,.$thi |
5b6a0 | 73 2d 3e 6f 75 74 70 75 74 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 | s->output);.............}.elseif |
5b6c0 | 20 28 69 73 73 65 74 28 24 74 68 69 73 2d 3e 6d 65 73 73 61 67 65 73 5b 24 6d 61 74 63 68 65 73 | .(isset($this->messages[$matches |
5b6e0 | 5b 31 5d 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 65 78 74 20 3d | [1]])).{.................$text.= |
5b700 | 20 24 74 68 69 73 2d 3e 6d 65 73 73 61 67 65 73 5b 24 6d 61 74 63 68 65 73 5b 31 5d 5d 3b 0a 20 | .$this->messages[$matches[1]];.. |
5b720 | 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ...........}.else.{............. |
5b740 | 20 20 20 20 72 65 74 75 72 6e 20 24 6d 61 74 63 68 65 73 5b 30 5d 3b 0a 20 20 20 20 20 20 20 20 | ....return.$matches[0];......... |
5b760 | 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 69 73 73 65 74 28 24 6d 61 | ....}..............if.(isset($ma |
5b780 | 74 63 68 65 73 5b 32 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 65 | tches[2])).{.................$te |
5b7a0 | 78 74 20 3d 20 73 70 72 69 6e 74 66 28 27 25 27 2e 24 6d 61 74 63 68 65 73 5b 32 5d 2c 20 24 74 | xt.=.sprintf('%'.$matches[2],.$t |
5b7c0 | 65 78 74 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 | ext);.............}............. |
5b7e0 | 20 72 65 74 75 72 6e 20 24 74 65 78 74 3b 0a 20 20 20 20 20 20 20 20 7d 2c 20 24 74 68 69 73 2d | .return.$text;.........},.$this- |
5b800 | 3e 66 6f 72 6d 61 74 29 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a | >format));.....}....../**......* |
5b820 | 20 52 65 6d 6f 76 65 73 20 74 68 65 20 70 72 6f 67 72 65 73 73 20 62 61 72 20 66 72 6f 6d 20 74 | .Removes.the.progress.bar.from.t |
5b840 | 68 65 20 63 75 72 72 65 6e 74 20 6c 69 6e 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 54 | he.current.line.......*......*.T |
5b860 | 68 69 73 20 69 73 20 75 73 65 66 75 6c 20 69 66 20 79 6f 75 20 77 69 73 68 20 74 6f 20 77 72 69 | his.is.useful.if.you.wish.to.wri |
5b880 | 74 65 20 73 6f 6d 65 20 6f 75 74 70 75 74 0a 20 20 20 20 20 2a 20 77 68 69 6c 65 20 61 20 70 72 | te.some.output......*.while.a.pr |
5b8a0 | 6f 67 72 65 73 73 20 62 61 72 20 69 73 20 72 75 6e 6e 69 6e 67 2e 0a 20 20 20 20 20 2a 20 43 61 | ogress.bar.is.running.......*.Ca |
5b8c0 | 6c 6c 20 64 69 73 70 6c 61 79 28 29 20 74 6f 20 73 68 6f 77 20 74 68 65 20 70 72 6f 67 72 65 73 | ll.display().to.show.the.progres |
5b8e0 | 73 20 62 61 72 20 61 67 61 69 6e 2e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 | s.bar.again.......*/.....public. |
5b900 | 66 75 6e 63 74 69 6f 6e 20 63 6c 65 61 72 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 | function.clear().....{.........i |
5b920 | 66 20 28 21 24 74 68 69 73 2d 3e 6f 76 65 72 77 72 69 74 65 29 20 7b 0a 20 20 20 20 20 20 20 20 | f.(!$this->overwrite).{......... |
5b940 | 20 20 20 20 72 65 74 75 72 6e 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 | ....return;.........}..........i |
5b960 | 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 74 68 69 73 2d 3e 66 6f 72 6d 61 74 29 20 7b 0a 20 20 20 | f.(null.===.$this->format).{.... |
5b980 | 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 65 74 52 65 61 6c 46 6f 72 6d 61 74 28 24 74 | .........$this->setRealFormat($t |
5b9a0 | 68 69 73 2d 3e 69 6e 74 65 72 6e 61 6c 46 6f 72 6d 61 74 20 3f 3a 20 24 74 68 69 73 2d 3e 64 65 | his->internalFormat.?:.$this->de |
5b9c0 | 74 65 72 6d 69 6e 65 42 65 73 74 46 6f 72 6d 61 74 28 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a | termineBestFormat());.........}. |
5b9e0 | 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6f 76 65 72 77 72 69 74 65 28 27 27 29 3b 0a 20 | .........$this->overwrite('');.. |
5ba00 | 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 74 68 65 20 70 72 | ...}....../**......*.Sets.the.pr |
5ba20 | 6f 67 72 65 73 73 20 62 61 72 20 66 6f 72 6d 61 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a | ogress.bar.format.......*......* |
5ba40 | 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 66 6f 72 6d 61 74 20 54 68 65 20 66 6f 72 6d 61 | .@param.string.$format.The.forma |
5ba60 | 74 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 73 | t......*/.....private.function.s |
5ba80 | 65 74 52 65 61 6c 46 6f 72 6d 61 74 28 24 66 6f 72 6d 61 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 | etRealFormat($format).....{..... |
5baa0 | 20 20 20 20 2f 2f 20 74 72 79 20 74 6f 20 75 73 65 20 74 68 65 20 5f 6e 6f 6d 61 78 20 76 61 72 | ....//.try.to.use.the._nomax.var |
5bac0 | 69 61 6e 74 20 69 66 20 61 76 61 69 6c 61 62 6c 65 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 24 | iant.if.available.........if.(!$ |
5bae0 | 74 68 69 73 2d 3e 6d 61 78 20 26 26 20 6e 75 6c 6c 20 21 3d 3d 20 73 65 6c 66 3a 3a 67 65 74 46 | this->max.&&.null.!==.self::getF |
5bb00 | 6f 72 6d 61 74 44 65 66 69 6e 69 74 69 6f 6e 28 24 66 6f 72 6d 61 74 2e 27 5f 6e 6f 6d 61 78 27 | ormatDefinition($format.'_nomax' |
5bb20 | 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 66 6f 72 6d 61 74 20 3d | )).{.............$this->format.= |
5bb40 | 20 73 65 6c 66 3a 3a 67 65 74 46 6f 72 6d 61 74 44 65 66 69 6e 69 74 69 6f 6e 28 24 66 6f 72 6d | .self::getFormatDefinition($form |
5bb60 | 61 74 2e 27 5f 6e 6f 6d 61 78 27 29 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 | at.'_nomax');.........}.elseif.( |
5bb80 | 6e 75 6c 6c 20 21 3d 3d 20 73 65 6c 66 3a 3a 67 65 74 46 6f 72 6d 61 74 44 65 66 69 6e 69 74 69 | null.!==.self::getFormatDefiniti |
5bba0 | 6f 6e 28 24 66 6f 72 6d 61 74 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 | on($format)).{.............$this |
5bbc0 | 2d 3e 66 6f 72 6d 61 74 20 3d 20 73 65 6c 66 3a 3a 67 65 74 46 6f 72 6d 61 74 44 65 66 69 6e 69 | ->format.=.self::getFormatDefini |
5bbe0 | 74 69 6f 6e 28 24 66 6f 72 6d 61 74 29 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a | tion($format);.........}.else.{. |
5bc00 | 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 66 6f 72 6d 61 74 20 3d 20 24 66 6f 72 | ............$this->format.=.$for |
5bc20 | 6d 61 74 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 66 | mat;.........}..........$this->f |
5bc40 | 6f 72 6d 61 74 4c 69 6e 65 43 6f 75 6e 74 20 3d 20 73 75 62 73 74 72 5f 63 6f 75 6e 74 28 24 74 | ormatLineCount.=.substr_count($t |
5bc60 | 68 69 73 2d 3e 66 6f 72 6d 61 74 2c 20 22 5c 6e 22 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f | his->format,."\n");.....}....../ |
5bc80 | 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 74 68 65 20 70 72 6f 67 72 65 73 73 20 62 61 72 20 | **......*.Sets.the.progress.bar. |
5bca0 | 6d 61 78 69 6d 61 6c 20 73 74 65 70 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 | maximal.steps.......*......*.@pa |
5bcc0 | 72 61 6d 20 69 6e 74 20 24 6d 61 78 20 54 68 65 20 70 72 6f 67 72 65 73 73 20 62 61 72 20 6d 61 | ram.int.$max.The.progress.bar.ma |
5bce0 | 78 20 73 74 65 70 73 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 | x.steps......*/.....private.func |
5bd00 | 74 69 6f 6e 20 73 65 74 4d 61 78 53 74 65 70 73 28 24 6d 61 78 29 0a 20 20 20 20 7b 0a 20 20 20 | tion.setMaxSteps($max).....{.... |
5bd20 | 20 20 20 20 20 24 74 68 69 73 2d 3e 6d 61 78 20 3d 20 6d 61 78 28 30 2c 20 28 69 6e 74 29 20 24 | .....$this->max.=.max(0,.(int).$ |
5bd40 | 6d 61 78 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 74 65 70 57 69 64 74 68 20 3d | max);.........$this->stepWidth.= |
5bd60 | 20 24 74 68 69 73 2d 3e 6d 61 78 20 3f 20 48 65 6c 70 65 72 3a 3a 73 74 72 6c 65 6e 28 24 74 68 | .$this->max.?.Helper::strlen($th |
5bd80 | 69 73 2d 3e 6d 61 78 29 20 3a 20 34 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 | is->max).:.4;.....}....../**.... |
5bda0 | 20 20 2a 20 4f 76 65 72 77 72 69 74 65 73 20 61 20 70 72 65 76 69 6f 75 73 20 6d 65 73 73 61 67 | ..*.Overwrites.a.previous.messag |
5bdc0 | 65 20 74 6f 20 74 68 65 20 6f 75 74 70 75 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 | e.to.the.output.......*......*.@ |
5bde0 | 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6d 65 73 73 61 67 65 20 54 68 65 20 6d 65 73 73 61 67 | param.string.$message.The.messag |
5be00 | 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 6f | e......*/.....private.function.o |
5be20 | 76 65 72 77 72 69 74 65 28 24 6d 65 73 73 61 67 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 | verwrite($message).....{........ |
5be40 | 20 69 66 20 28 24 74 68 69 73 2d 3e 6f 76 65 72 77 72 69 74 65 29 20 7b 0a 20 20 20 20 20 20 20 | .if.($this->overwrite).{........ |
5be60 | 20 20 20 20 20 69 66 20 28 21 24 74 68 69 73 2d 3e 66 69 72 73 74 52 75 6e 29 20 7b 0a 20 20 20 | .....if.(!$this->firstRun).{.... |
5be80 | 20 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 4d 6f 76 65 20 74 68 65 20 63 75 72 73 6f 72 20 | .............//.Move.the.cursor. |
5bea0 | 74 6f 20 74 68 65 20 62 65 67 69 6e 6e 69 6e 67 20 6f 66 20 74 68 65 20 6c 69 6e 65 0a 20 20 20 | to.the.beginning.of.the.line.... |
5bec0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 2d 3e 77 72 69 74 | .............$this->output->writ |
5bee0 | 65 28 22 5c 78 30 44 22 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 45 | e("\x0D");..................//.E |
5bf00 | 72 61 73 65 20 74 68 65 20 6c 69 6e 65 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 | rase.the.line.................$t |
5bf20 | 68 69 73 2d 3e 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 28 22 5c 78 31 42 5b 32 4b 22 29 3b 0a 0a | his->output->write("\x1B[2K");.. |
5bf40 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 45 72 61 73 65 20 70 72 65 76 69 6f 75 | ................//.Erase.previou |
5bf60 | 73 20 6c 69 6e 65 73 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 74 68 69 | s.lines.................if.($thi |
5bf80 | 73 2d 3e 66 6f 72 6d 61 74 4c 69 6e 65 43 6f 75 6e 74 20 3e 20 30 29 20 7b 0a 20 20 20 20 20 20 | s->formatLineCount.>.0).{....... |
5bfa0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 2d 3e 77 72 69 | ..............$this->output->wri |
5bfc0 | 74 65 28 73 74 72 5f 72 65 70 65 61 74 28 22 5c 78 31 42 5b 31 41 5c 78 31 42 5b 32 4b 22 2c 20 | te(str_repeat("\x1B[1A\x1B[2K",. |
5bfe0 | 24 74 68 69 73 2d 3e 66 6f 72 6d 61 74 4c 69 6e 65 43 6f 75 6e 74 29 29 3b 0a 20 20 20 20 20 20 | $this->formatLineCount));....... |
5c000 | 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 | ..........}.............}....... |
5c020 | 20 20 7d 20 65 6c 73 65 69 66 20 28 24 74 68 69 73 2d 3e 73 74 65 70 20 3e 20 30 29 20 7b 0a 20 | ..}.elseif.($this->step.>.0).{.. |
5c040 | 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c | ...........$this->output->writel |
5c060 | 6e 28 27 27 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d | n('');.........}..........$this- |
5c080 | 3e 66 69 72 73 74 52 75 6e 20 3d 20 66 61 6c 73 65 3b 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 | >firstRun.=.false;..........$thi |
5c0a0 | 73 2d 3e 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 28 24 6d 65 73 73 61 67 65 29 3b 0a 20 20 20 20 | s->output->write($message);..... |
5c0c0 | 7d 0a 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 64 65 74 65 72 6d 69 6e | }......private.function.determin |
5c0e0 | 65 42 65 73 74 46 6f 72 6d 61 74 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 73 77 69 74 | eBestFormat().....{.........swit |
5c100 | 63 68 20 28 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 2d 3e 67 65 74 56 65 72 62 6f 73 69 74 79 28 | ch.($this->output->getVerbosity( |
5c120 | 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 4f 75 74 70 75 74 49 6e 74 65 72 66 | )).{.............//.OutputInterf |
5c140 | 61 63 65 3a 3a 56 45 52 42 4f 53 49 54 59 5f 51 55 49 45 54 3a 20 64 69 73 70 6c 61 79 20 69 73 | ace::VERBOSITY_QUIET:.display.is |
5c160 | 20 64 69 73 61 62 6c 65 64 20 61 6e 79 77 61 79 0a 20 20 20 20 20 20 20 20 20 20 20 20 63 61 73 | .disabled.anyway.............cas |
5c180 | 65 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 3a 3a 56 45 52 42 4f 53 49 54 59 5f 56 45 52 | e.OutputInterface::VERBOSITY_VER |
5c1a0 | 42 4f 53 45 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 | BOSE:.................return.$th |
5c1c0 | 69 73 2d 3e 6d 61 78 20 3f 20 27 76 65 72 62 6f 73 65 27 20 3a 20 27 76 65 72 62 6f 73 65 5f 6e | is->max.?.'verbose'.:.'verbose_n |
5c1e0 | 6f 6d 61 78 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 63 61 73 65 20 4f 75 74 70 75 74 49 6e | omax';.............case.OutputIn |
5c200 | 74 65 72 66 61 63 65 3a 3a 56 45 52 42 4f 53 49 54 59 5f 56 45 52 59 5f 56 45 52 42 4f 53 45 3a | terface::VERBOSITY_VERY_VERBOSE: |
5c220 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 6d | .................return.$this->m |
5c240 | 61 78 20 3f 20 27 76 65 72 79 5f 76 65 72 62 6f 73 65 27 20 3a 20 27 76 65 72 79 5f 76 65 72 62 | ax.?.'very_verbose'.:.'very_verb |
5c260 | 6f 73 65 5f 6e 6f 6d 61 78 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 63 61 73 65 20 4f 75 74 | ose_nomax';.............case.Out |
5c280 | 70 75 74 49 6e 74 65 72 66 61 63 65 3a 3a 56 45 52 42 4f 53 49 54 59 5f 44 45 42 55 47 3a 0a 20 | putInterface::VERBOSITY_DEBUG:.. |
5c2a0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 6d 61 78 | ...............return.$this->max |
5c2c0 | 20 3f 20 27 64 65 62 75 67 27 20 3a 20 27 64 65 62 75 67 5f 6e 6f 6d 61 78 27 3b 0a 20 20 20 20 | .?.'debug'.:.'debug_nomax';..... |
5c2e0 | 20 20 20 20 20 20 20 20 64 65 66 61 75 6c 74 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ........default:................ |
5c300 | 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 6d 61 78 20 3f 20 27 6e 6f 72 6d 61 6c 27 20 3a 20 | .return.$this->max.?.'normal'.:. |
5c320 | 27 6e 6f 72 6d 61 6c 5f 6e 6f 6d 61 78 27 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a | 'normal_nomax';.........}.....}. |
5c340 | 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 69 6e 69 | .....private.static.function.ini |
5c360 | 74 50 6c 61 63 65 68 6f 6c 64 65 72 46 6f 72 6d 61 74 74 65 72 73 28 29 0a 20 20 20 20 7b 0a 20 | tPlaceholderFormatters().....{.. |
5c380 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 61 72 72 61 79 28 0a 20 20 20 20 20 20 20 20 20 20 20 | .......return.array(............ |
5c3a0 | 20 27 62 61 72 27 20 3d 3e 20 66 75 6e 63 74 69 6f 6e 20 28 50 72 6f 67 72 65 73 73 42 61 72 20 | .'bar'.=>.function.(ProgressBar. |
5c3c0 | 24 62 61 72 2c 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 29 20 7b | $bar,.OutputInterface.$output).{ |
5c3e0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6f 6d 70 6c 65 74 65 42 61 72 73 20 3d | .................$completeBars.= |
5c400 | 20 66 6c 6f 6f 72 28 24 62 61 72 2d 3e 67 65 74 4d 61 78 53 74 65 70 73 28 29 20 3e 20 30 20 3f | .floor($bar->getMaxSteps().>.0.? |
5c420 | 20 24 62 61 72 2d 3e 67 65 74 50 72 6f 67 72 65 73 73 50 65 72 63 65 6e 74 28 29 20 2a 20 24 62 | .$bar->getProgressPercent().*.$b |
5c440 | 61 72 2d 3e 67 65 74 42 61 72 57 69 64 74 68 28 29 20 3a 20 24 62 61 72 2d 3e 67 65 74 50 72 6f | ar->getBarWidth().:.$bar->getPro |
5c460 | 67 72 65 73 73 28 29 20 25 20 24 62 61 72 2d 3e 67 65 74 42 61 72 57 69 64 74 68 28 29 29 3b 0a | gress().%.$bar->getBarWidth());. |
5c480 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 64 69 73 70 6c 61 79 20 3d 20 73 74 72 5f 72 | ................$display.=.str_r |
5c4a0 | 65 70 65 61 74 28 24 62 61 72 2d 3e 67 65 74 42 61 72 43 68 61 72 61 63 74 65 72 28 29 2c 20 24 | epeat($bar->getBarCharacter(),.$ |
5c4c0 | 63 6f 6d 70 6c 65 74 65 42 61 72 73 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 | completeBars);.................i |
5c4e0 | 66 20 28 24 63 6f 6d 70 6c 65 74 65 42 61 72 73 20 3c 20 24 62 61 72 2d 3e 67 65 74 42 61 72 57 | f.($completeBars.<.$bar->getBarW |
5c500 | 69 64 74 68 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 65 | idth()).{.....................$e |
5c520 | 6d 70 74 79 42 61 72 73 20 3d 20 24 62 61 72 2d 3e 67 65 74 42 61 72 57 69 64 74 68 28 29 20 2d | mptyBars.=.$bar->getBarWidth().- |
5c540 | 20 24 63 6f 6d 70 6c 65 74 65 42 61 72 73 20 2d 20 48 65 6c 70 65 72 3a 3a 73 74 72 6c 65 6e 57 | .$completeBars.-.Helper::strlenW |
5c560 | 69 74 68 6f 75 74 44 65 63 6f 72 61 74 69 6f 6e 28 24 6f 75 74 70 75 74 2d 3e 67 65 74 46 6f 72 | ithoutDecoration($output->getFor |
5c580 | 6d 61 74 74 65 72 28 29 2c 20 24 62 61 72 2d 3e 67 65 74 50 72 6f 67 72 65 73 73 43 68 61 72 61 | matter(),.$bar->getProgressChara |
5c5a0 | 63 74 65 72 28 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 64 69 | cter());.....................$di |
5c5c0 | 73 70 6c 61 79 20 2e 3d 20 24 62 61 72 2d 3e 67 65 74 50 72 6f 67 72 65 73 73 43 68 61 72 61 63 | splay..=.$bar->getProgressCharac |
5c5e0 | 74 65 72 28 29 2e 73 74 72 5f 72 65 70 65 61 74 28 24 62 61 72 2d 3e 67 65 74 45 6d 70 74 79 42 | ter().str_repeat($bar->getEmptyB |
5c600 | 61 72 43 68 61 72 61 63 74 65 72 28 29 2c 20 24 65 6d 70 74 79 42 61 72 73 29 3b 0a 20 20 20 20 | arCharacter(),.$emptyBars);..... |
5c620 | 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 | ............}..................r |
5c640 | 65 74 75 72 6e 20 24 64 69 73 70 6c 61 79 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 2c 0a 20 | eturn.$display;.............},.. |
5c660 | 20 20 20 20 20 20 20 20 20 20 20 27 65 6c 61 70 73 65 64 27 20 3d 3e 20 66 75 6e 63 74 69 6f 6e | ...........'elapsed'.=>.function |
5c680 | 20 28 50 72 6f 67 72 65 73 73 42 61 72 20 24 62 61 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | .(ProgressBar.$bar).{........... |
5c6a0 | 20 20 20 20 20 20 72 65 74 75 72 6e 20 48 65 6c 70 65 72 3a 3a 66 6f 72 6d 61 74 54 69 6d 65 28 | ......return.Helper::formatTime( |
5c6c0 | 74 69 6d 65 28 29 20 2d 20 24 62 61 72 2d 3e 67 65 74 53 74 61 72 74 54 69 6d 65 28 29 29 3b 0a | time().-.$bar->getStartTime());. |
5c6e0 | 20 20 20 20 20 20 20 20 20 20 20 20 7d 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 72 65 6d 61 | ............},.............'rema |
5c700 | 69 6e 69 6e 67 27 20 3d 3e 20 66 75 6e 63 74 69 6f 6e 20 28 50 72 6f 67 72 65 73 73 42 61 72 20 | ining'.=>.function.(ProgressBar. |
5c720 | 24 62 61 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 21 24 62 61 | $bar).{.................if.(!$ba |
5c740 | 72 2d 3e 67 65 74 4d 61 78 53 74 65 70 73 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | r->getMaxSteps()).{............. |
5c760 | 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 4c 6f 67 69 63 45 78 63 65 70 74 69 6f 6e | ........throw.new.LogicException |
5c780 | 28 27 55 6e 61 62 6c 65 20 74 6f 20 64 69 73 70 6c 61 79 20 74 68 65 20 72 65 6d 61 69 6e 69 6e | ('Unable.to.display.the.remainin |
5c7a0 | 67 20 74 69 6d 65 20 69 66 20 74 68 65 20 6d 61 78 69 6d 75 6d 20 6e 75 6d 62 65 72 20 6f 66 20 | g.time.if.the.maximum.number.of. |
5c7c0 | 73 74 65 70 73 20 69 73 20 6e 6f 74 20 73 65 74 2e 27 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 | steps.is.not.set.');............ |
5c7e0 | 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 21 24 62 61 | .....}..................if.(!$ba |
5c800 | 72 2d 3e 67 65 74 50 72 6f 67 72 65 73 73 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | r->getProgress()).{............. |
5c820 | 20 20 20 20 20 20 20 20 24 72 65 6d 61 69 6e 69 6e 67 20 3d 20 30 3b 0a 20 20 20 20 20 20 20 20 | ........$remaining.=.0;......... |
5c840 | 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ........}.else.{................ |
5c860 | 20 20 20 20 20 24 72 65 6d 61 69 6e 69 6e 67 20 3d 20 72 6f 75 6e 64 28 28 74 69 6d 65 28 29 20 | .....$remaining.=.round((time(). |
5c880 | 2d 20 24 62 61 72 2d 3e 67 65 74 53 74 61 72 74 54 69 6d 65 28 29 29 20 2f 20 24 62 61 72 2d 3e | -.$bar->getStartTime())./.$bar-> |
5c8a0 | 67 65 74 50 72 6f 67 72 65 73 73 28 29 20 2a 20 28 24 62 61 72 2d 3e 67 65 74 4d 61 78 53 74 65 | getProgress().*.($bar->getMaxSte |
5c8c0 | 70 73 28 29 20 2d 20 24 62 61 72 2d 3e 67 65 74 50 72 6f 67 72 65 73 73 28 29 29 29 3b 0a 20 20 | ps().-.$bar->getProgress()));... |
5c8e0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ..............}................. |
5c900 | 20 72 65 74 75 72 6e 20 48 65 6c 70 65 72 3a 3a 66 6f 72 6d 61 74 54 69 6d 65 28 24 72 65 6d 61 | .return.Helper::formatTime($rema |
5c920 | 69 6e 69 6e 67 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 2c 0a 20 20 20 20 20 20 20 20 20 | ining);.............},.......... |
5c940 | 20 20 20 27 65 73 74 69 6d 61 74 65 64 27 20 3d 3e 20 66 75 6e 63 74 69 6f 6e 20 28 50 72 6f 67 | ...'estimated'.=>.function.(Prog |
5c960 | 72 65 73 73 42 61 72 20 24 62 61 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ressBar.$bar).{................. |
5c980 | 69 66 20 28 21 24 62 61 72 2d 3e 67 65 74 4d 61 78 53 74 65 70 73 28 29 29 20 7b 0a 20 20 20 20 | if.(!$bar->getMaxSteps()).{..... |
5c9a0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 4c 6f 67 69 63 45 | ................throw.new.LogicE |
5c9c0 | 78 63 65 70 74 69 6f 6e 28 27 55 6e 61 62 6c 65 20 74 6f 20 64 69 73 70 6c 61 79 20 74 68 65 20 | xception('Unable.to.display.the. |
5c9e0 | 65 73 74 69 6d 61 74 65 64 20 74 69 6d 65 20 69 66 20 74 68 65 20 6d 61 78 69 6d 75 6d 20 6e 75 | estimated.time.if.the.maximum.nu |
5ca00 | 6d 62 65 72 20 6f 66 20 73 74 65 70 73 20 69 73 20 6e 6f 74 20 73 65 74 2e 27 29 3b 0a 20 20 20 | mber.of.steps.is.not.set.');.... |
5ca20 | 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | .............}.................. |
5ca40 | 69 66 20 28 21 24 62 61 72 2d 3e 67 65 74 50 72 6f 67 72 65 73 73 28 29 29 20 7b 0a 20 20 20 20 | if.(!$bar->getProgress()).{..... |
5ca60 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 65 73 74 69 6d 61 74 65 64 20 3d 20 30 3b 0a | ................$estimated.=.0;. |
5ca80 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 | ................}.else.{........ |
5caa0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 24 65 73 74 69 6d 61 74 65 64 20 3d 20 72 6f 75 6e 64 28 | .............$estimated.=.round( |
5cac0 | 28 74 69 6d 65 28 29 20 2d 20 24 62 61 72 2d 3e 67 65 74 53 74 61 72 74 54 69 6d 65 28 29 29 20 | (time().-.$bar->getStartTime()). |
5cae0 | 2f 20 24 62 61 72 2d 3e 67 65 74 50 72 6f 67 72 65 73 73 28 29 20 2a 20 24 62 61 72 2d 3e 67 65 | /.$bar->getProgress().*.$bar->ge |
5cb00 | 74 4d 61 78 53 74 65 70 73 28 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a | tMaxSteps());.................}. |
5cb20 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 48 65 6c 70 65 72 3a 3a | .................return.Helper:: |
5cb40 | 66 6f 72 6d 61 74 54 69 6d 65 28 24 65 73 74 69 6d 61 74 65 64 29 3b 0a 20 20 20 20 20 20 20 20 | formatTime($estimated);......... |
5cb60 | 20 20 20 20 7d 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 6d 65 6d 6f 72 79 27 20 3d 3e 20 66 | ....},.............'memory'.=>.f |
5cb80 | 75 6e 63 74 69 6f 6e 20 28 50 72 6f 67 72 65 73 73 42 61 72 20 24 62 61 72 29 20 7b 0a 20 20 20 | unction.(ProgressBar.$bar).{.... |
5cba0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 48 65 6c 70 65 72 3a 3a 66 6f 72 6d | .............return.Helper::form |
5cbc0 | 61 74 4d 65 6d 6f 72 79 28 6d 65 6d 6f 72 79 5f 67 65 74 5f 75 73 61 67 65 28 74 72 75 65 29 29 | atMemory(memory_get_usage(true)) |
5cbe0 | 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 63 75 | ;.............},.............'cu |
5cc00 | 72 72 65 6e 74 27 20 3d 3e 20 66 75 6e 63 74 69 6f 6e 20 28 50 72 6f 67 72 65 73 73 42 61 72 20 | rrent'.=>.function.(ProgressBar. |
5cc20 | 24 62 61 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 | $bar).{.................return.s |
5cc40 | 74 72 5f 70 61 64 28 24 62 61 72 2d 3e 67 65 74 50 72 6f 67 72 65 73 73 28 29 2c 20 24 62 61 72 | tr_pad($bar->getProgress(),.$bar |
5cc60 | 2d 3e 67 65 74 53 74 65 70 57 69 64 74 68 28 29 2c 20 27 20 27 2c 20 53 54 52 5f 50 41 44 5f 4c | ->getStepWidth(),.'.',.STR_PAD_L |
5cc80 | 45 46 54 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 2c 0a 20 20 20 20 20 20 20 20 20 20 20 | EFT);.............},............ |
5cca0 | 20 27 6d 61 78 27 20 3d 3e 20 66 75 6e 63 74 69 6f 6e 20 28 50 72 6f 67 72 65 73 73 42 61 72 20 | .'max'.=>.function.(ProgressBar. |
5ccc0 | 24 62 61 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 | $bar).{.................return.$ |
5cce0 | 62 61 72 2d 3e 67 65 74 4d 61 78 53 74 65 70 73 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | bar->getMaxSteps();............. |
5cd00 | 7d 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 70 65 72 63 65 6e 74 27 20 3d 3e 20 66 75 6e 63 | },.............'percent'.=>.func |
5cd20 | 74 69 6f 6e 20 28 50 72 6f 67 72 65 73 73 42 61 72 20 24 62 61 72 29 20 7b 0a 20 20 20 20 20 20 | tion.(ProgressBar.$bar).{....... |
5cd40 | 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 66 6c 6f 6f 72 28 24 62 61 72 2d 3e 67 65 74 | ..........return.floor($bar->get |
5cd60 | 50 72 6f 67 72 65 73 73 50 65 72 63 65 6e 74 28 29 20 2a 20 31 30 30 29 3b 0a 20 20 20 20 20 20 | ProgressPercent().*.100);....... |
5cd80 | 20 20 20 20 20 20 7d 2c 0a 20 20 20 20 20 20 20 20 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 | ......},.........);.....}......p |
5cda0 | 72 69 76 61 74 65 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 69 6e 69 74 46 6f 72 6d 61 | rivate.static.function.initForma |
5cdc0 | 74 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 61 72 72 61 79 28 | ts().....{.........return.array( |
5cde0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 6e 6f 72 6d 61 6c 27 20 3d 3e 20 27 20 25 63 75 72 72 | .............'normal'.=>.'.%curr |
5ce00 | 65 6e 74 25 2f 25 6d 61 78 25 20 5b 25 62 61 72 25 5d 20 25 70 65 72 63 65 6e 74 3a 33 73 25 25 | ent%/%max%.[%bar%].%percent:3s%% |
5ce20 | 27 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 6e 6f 72 6d 61 6c 5f 6e 6f 6d 61 78 27 20 3d 3e | ',.............'normal_nomax'.=> |
5ce40 | 20 27 20 25 63 75 72 72 65 6e 74 25 20 5b 25 62 61 72 25 5d 27 2c 0a 0a 20 20 20 20 20 20 20 20 | .'.%current%.[%bar%]',.......... |
5ce60 | 20 20 20 20 27 76 65 72 62 6f 73 65 27 20 3d 3e 20 27 20 25 63 75 72 72 65 6e 74 25 2f 25 6d 61 | ....'verbose'.=>.'.%current%/%ma |
5ce80 | 78 25 20 5b 25 62 61 72 25 5d 20 25 70 65 72 63 65 6e 74 3a 33 73 25 25 20 25 65 6c 61 70 73 65 | x%.[%bar%].%percent:3s%%.%elapse |
5cea0 | 64 3a 36 73 25 27 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 76 65 72 62 6f 73 65 5f 6e 6f 6d | d:6s%',.............'verbose_nom |
5cec0 | 61 78 27 20 3d 3e 20 27 20 25 63 75 72 72 65 6e 74 25 20 5b 25 62 61 72 25 5d 20 25 65 6c 61 70 | ax'.=>.'.%current%.[%bar%].%elap |
5cee0 | 73 65 64 3a 36 73 25 27 2c 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 76 65 72 79 5f 76 65 72 | sed:6s%',..............'very_ver |
5cf00 | 62 6f 73 65 27 20 3d 3e 20 27 20 25 63 75 72 72 65 6e 74 25 2f 25 6d 61 78 25 20 5b 25 62 61 72 | bose'.=>.'.%current%/%max%.[%bar |
5cf20 | 25 5d 20 25 70 65 72 63 65 6e 74 3a 33 73 25 25 20 25 65 6c 61 70 73 65 64 3a 36 73 25 2f 25 65 | %].%percent:3s%%.%elapsed:6s%/%e |
5cf40 | 73 74 69 6d 61 74 65 64 3a 2d 36 73 25 27 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 76 65 72 | stimated:-6s%',.............'ver |
5cf60 | 79 5f 76 65 72 62 6f 73 65 5f 6e 6f 6d 61 78 27 20 3d 3e 20 27 20 25 63 75 72 72 65 6e 74 25 20 | y_verbose_nomax'.=>.'.%current%. |
5cf80 | 5b 25 62 61 72 25 5d 20 25 65 6c 61 70 73 65 64 3a 36 73 25 27 2c 0a 0a 20 20 20 20 20 20 20 20 | [%bar%].%elapsed:6s%',.......... |
5cfa0 | 20 20 20 20 27 64 65 62 75 67 27 20 3d 3e 20 27 20 25 63 75 72 72 65 6e 74 25 2f 25 6d 61 78 25 | ....'debug'.=>.'.%current%/%max% |
5cfc0 | 20 5b 25 62 61 72 25 5d 20 25 70 65 72 63 65 6e 74 3a 33 73 25 25 20 25 65 6c 61 70 73 65 64 3a | .[%bar%].%percent:3s%%.%elapsed: |
5cfe0 | 36 73 25 2f 25 65 73 74 69 6d 61 74 65 64 3a 2d 36 73 25 20 25 6d 65 6d 6f 72 79 3a 36 73 25 27 | 6s%/%estimated:-6s%.%memory:6s%' |
5d000 | 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 64 65 62 75 67 5f 6e 6f 6d 61 78 27 20 3d 3e 20 27 | ,.............'debug_nomax'.=>.' |
5d020 | 20 25 63 75 72 72 65 6e 74 25 20 5b 25 62 61 72 25 5d 20 25 65 6c 61 70 73 65 64 3a 36 73 25 20 | .%current%.[%bar%].%elapsed:6s%. |
5d040 | 25 6d 65 6d 6f 72 79 3a 36 73 25 27 2c 0a 20 20 20 20 20 20 20 20 29 3b 0a 20 20 20 20 7d 0a 7d | %memory:6s%',.........);.....}.} |
5d060 | 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 | .<?php../*..*.This.file.is.part. |
5d080 | 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 | of.the.Symfony.package...*..*.(c |
5d0a0 | 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f | ).Fabien.Potencier.<fabien@symfo |
5d0c0 | 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 | ny.com>..*..*.For.the.full.copyr |
5d0e0 | 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c | ight.and.license.information,.pl |
5d100 | 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 | ease.view.the.LICENSE..*.file.th |
5d120 | 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 | at.was.distributed.with.this.sou |
5d140 | 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 | rce.code...*/..namespace.Symfony |
5d160 | 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 48 65 6c 70 65 72 3b 0a 0a 75 73 65 20 | \Component\Console\Helper;..use. |
5d180 | 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 78 63 65 70 74 | Symfony\Component\Console\Except |
5d1a0 | 69 6f 6e 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 3b 0a 75 73 | ion\InvalidArgumentException;.us |
5d1c0 | 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 78 63 65 | e.Symfony\Component\Console\Exce |
5d1e0 | 70 74 69 6f 6e 5c 52 75 6e 74 69 6d 65 45 78 63 65 70 74 69 6f 6e 3b 0a 75 73 65 20 53 79 6d 66 | ption\RuntimeException;.use.Symf |
5d200 | 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 5c 49 6e 70 75 | ony\Component\Console\Input\Inpu |
5d220 | 74 49 6e 74 65 72 66 61 63 65 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e | tInterface;.use.Symfony\Componen |
5d240 | 74 5c 43 6f 6e 73 6f 6c 65 5c 4f 75 74 70 75 74 5c 43 6f 6e 73 6f 6c 65 4f 75 74 70 75 74 49 6e | t\Console\Output\ConsoleOutputIn |
5d260 | 74 65 72 66 61 63 65 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 | terface;.use.Symfony\Component\C |
5d280 | 6f 6e 73 6f 6c 65 5c 4f 75 74 70 75 74 5c 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 3b 0a 75 | onsole\Output\OutputInterface;.u |
5d2a0 | 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 46 6f 72 | se.Symfony\Component\Console\For |
5d2c0 | 6d 61 74 74 65 72 5c 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c 65 3b 0a 75 73 65 | matter\OutputFormatterStyle;.use |
5d2e0 | 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 51 75 65 73 74 | .Symfony\Component\Console\Quest |
5d300 | 69 6f 6e 5c 51 75 65 73 74 69 6f 6e 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e | ion\Question;.use.Symfony\Compon |
5d320 | 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 51 75 65 73 74 69 6f 6e 5c 43 68 6f 69 63 65 51 75 65 73 74 | ent\Console\Question\ChoiceQuest |
5d340 | 69 6f 6e 3b 0a 0a 2f 2a 2a 0a 20 2a 20 54 68 65 20 51 75 65 73 74 69 6f 6e 48 65 6c 70 65 72 20 | ion;../**..*.The.QuestionHelper. |
5d360 | 63 6c 61 73 73 20 70 72 6f 76 69 64 65 73 20 68 65 6c 70 65 72 73 20 74 6f 20 69 6e 74 65 72 61 | class.provides.helpers.to.intera |
5d380 | 63 74 20 77 69 74 68 20 74 68 65 20 75 73 65 72 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 | ct.with.the.user...*..*.@author. |
5d3a0 | 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 | Fabien.Potencier.<fabien@symfony |
5d3c0 | 2e 63 6f 6d 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 51 75 65 73 74 69 6f 6e 48 65 6c 70 65 72 20 65 | .com>..*/.class.QuestionHelper.e |
5d3e0 | 78 74 65 6e 64 73 20 48 65 6c 70 65 72 0a 7b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 69 6e 70 | xtends.Helper.{.....private.$inp |
5d400 | 75 74 53 74 72 65 61 6d 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 24 73 68 | utStream;.....private.static.$sh |
5d420 | 65 6c 6c 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 24 73 74 74 79 3b 0a 0a | ell;.....private.static.$stty;.. |
5d440 | 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 41 73 6b 73 20 61 20 71 75 65 73 74 69 6f 6e 20 74 | ..../**......*.Asks.a.question.t |
5d460 | 6f 20 74 68 65 20 75 73 65 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d | o.the.user.......*......*.@param |
5d480 | 20 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 20 20 24 69 6e 70 75 74 20 20 20 20 41 6e 20 49 6e | .InputInterface..$input....An.In |
5d4a0 | 70 75 74 49 6e 74 65 72 66 61 63 65 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 20 40 70 61 | putInterface.instance......*.@pa |
5d4c0 | 72 61 6d 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 20 20 20 41 6e | ram.OutputInterface.$output...An |
5d4e0 | 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a | .OutputInterface.instance......* |
5d500 | 20 40 70 61 72 61 6d 20 51 75 65 73 74 69 6f 6e 20 20 20 20 20 20 20 20 24 71 75 65 73 74 69 6f | .@param.Question........$questio |
5d520 | 6e 20 54 68 65 20 71 75 65 73 74 69 6f 6e 20 74 6f 20 61 73 6b 0a 20 20 20 20 20 2a 0a 20 20 20 | n.The.question.to.ask......*.... |
5d540 | 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 20 54 68 65 20 75 73 65 72 20 61 6e 73 77 | ..*.@return.string.The.user.answ |
5d560 | 65 72 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 52 75 6e 74 69 6d 65 | er......*......*.@throws.Runtime |
5d580 | 45 78 63 65 70 74 69 6f 6e 20 49 66 20 74 68 65 72 65 20 69 73 20 6e 6f 20 64 61 74 61 20 74 6f | Exception.If.there.is.no.data.to |
5d5a0 | 20 72 65 61 64 20 69 6e 20 74 68 65 20 69 6e 70 75 74 20 73 74 72 65 61 6d 0a 20 20 20 20 20 2a | .read.in.the.input.stream......* |
5d5c0 | 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 61 73 6b 28 49 6e 70 75 74 49 | /.....public.function.ask(InputI |
5d5e0 | 6e 74 65 72 66 61 63 65 20 24 69 6e 70 75 74 2c 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 | nterface.$input,.OutputInterface |
5d600 | 20 24 6f 75 74 70 75 74 2c 20 51 75 65 73 74 69 6f 6e 20 24 71 75 65 73 74 69 6f 6e 29 0a 20 20 | .$output,.Question.$question)... |
5d620 | 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 6f 75 74 70 75 74 20 69 6e 73 74 61 6e 63 65 | ..{.........if.($output.instance |
5d640 | 6f 66 20 43 6f 6e 73 6f 6c 65 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 29 20 7b 0a 20 20 20 | of.ConsoleOutputInterface).{.... |
5d660 | 20 20 20 20 20 20 20 20 20 24 6f 75 74 70 75 74 20 3d 20 24 6f 75 74 70 75 74 2d 3e 67 65 74 45 | .........$output.=.$output->getE |
5d680 | 72 72 6f 72 4f 75 74 70 75 74 28 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 | rrorOutput();.........}......... |
5d6a0 | 20 69 66 20 28 21 24 69 6e 70 75 74 2d 3e 69 73 49 6e 74 65 72 61 63 74 69 76 65 28 29 29 20 7b | .if.(!$input->isInteractive()).{ |
5d6c0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 71 75 65 73 74 69 6f 6e 2d 3e 67 | .............return.$question->g |
5d6e0 | 65 74 44 65 66 61 75 6c 74 28 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 | etDefault();.........}.......... |
5d700 | 69 66 20 28 21 24 71 75 65 73 74 69 6f 6e 2d 3e 67 65 74 56 61 6c 69 64 61 74 6f 72 28 29 29 20 | if.(!$question->getValidator()). |
5d720 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 64 6f 41 73 | {.............return.$this->doAs |
5d740 | 6b 28 24 6f 75 74 70 75 74 2c 20 24 71 75 65 73 74 69 6f 6e 29 3b 0a 20 20 20 20 20 20 20 20 7d | k($output,.$question);.........} |
5d760 | 0a 0a 20 20 20 20 20 20 20 20 24 69 6e 74 65 72 76 69 65 77 65 72 20 3d 20 66 75 6e 63 74 69 6f | ..........$interviewer.=.functio |
5d780 | 6e 20 28 29 20 75 73 65 20 28 24 6f 75 74 70 75 74 2c 20 24 71 75 65 73 74 69 6f 6e 29 20 7b 0a | n.().use.($output,.$question).{. |
5d7a0 | 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 64 6f 41 73 6b 28 | ............return.$this->doAsk( |
5d7c0 | 24 6f 75 74 70 75 74 2c 20 24 71 75 65 73 74 69 6f 6e 29 3b 0a 20 20 20 20 20 20 20 20 7d 3b 0a | $output,.$question);.........};. |
5d7e0 | 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 76 61 6c 69 64 61 74 65 41 | .........return.$this->validateA |
5d800 | 74 74 65 6d 70 74 73 28 24 69 6e 74 65 72 76 69 65 77 65 72 2c 20 24 6f 75 74 70 75 74 2c 20 24 | ttempts($interviewer,.$output,.$ |
5d820 | 71 75 65 73 74 69 6f 6e 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a | question);.....}....../**......* |
5d840 | 20 53 65 74 73 20 74 68 65 20 69 6e 70 75 74 20 73 74 72 65 61 6d 20 74 6f 20 72 65 61 64 20 66 | .Sets.the.input.stream.to.read.f |
5d860 | 72 6f 6d 20 77 68 65 6e 20 69 6e 74 65 72 61 63 74 69 6e 67 20 77 69 74 68 20 74 68 65 20 75 73 | rom.when.interacting.with.the.us |
5d880 | 65 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 54 68 69 73 20 69 73 20 6d 61 69 6e 6c 79 | er.......*......*.This.is.mainly |
5d8a0 | 20 75 73 65 66 75 6c 20 66 6f 72 20 74 65 73 74 69 6e 67 20 70 75 72 70 6f 73 65 2e 0a 20 20 20 | .useful.for.testing.purpose..... |
5d8c0 | 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 72 65 73 6f 75 72 63 65 20 24 73 74 72 65 | ..*......*.@param.resource.$stre |
5d8e0 | 61 6d 20 54 68 65 20 69 6e 70 75 74 20 73 74 72 65 61 6d 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 | am.The.input.stream......*...... |
5d900 | 2a 20 40 74 68 72 6f 77 73 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 | *.@throws.InvalidArgumentExcepti |
5d920 | 6f 6e 20 49 6e 20 63 61 73 65 20 74 68 65 20 73 74 72 65 61 6d 20 69 73 20 6e 6f 74 20 61 20 72 | on.In.case.the.stream.is.not.a.r |
5d940 | 65 73 6f 75 72 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 | esource......*/.....public.funct |
5d960 | 69 6f 6e 20 73 65 74 49 6e 70 75 74 53 74 72 65 61 6d 28 24 73 74 72 65 61 6d 29 0a 20 20 20 20 | ion.setInputStream($stream)..... |
5d980 | 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 69 73 5f 72 65 73 6f 75 72 63 65 28 24 73 74 72 65 | {.........if.(!is_resource($stre |
5d9a0 | 61 6d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 | am)).{.............throw.new.Inv |
5d9c0 | 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 27 49 6e 70 75 74 20 73 74 72 | alidArgumentException('Input.str |
5d9e0 | 65 61 6d 20 6d 75 73 74 20 62 65 20 61 20 76 61 6c 69 64 20 72 65 73 6f 75 72 63 65 2e 27 29 3b | eam.must.be.a.valid.resource.'); |
5da00 | 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 69 6e 70 75 74 | .........}..........$this->input |
5da20 | 53 74 72 65 61 6d 20 3d 20 24 73 74 72 65 61 6d 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a | Stream.=.$stream;.....}....../** |
5da40 | 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 74 68 65 20 68 65 6c 70 65 72 27 73 20 69 6e 70 | ......*.Returns.the.helper's.inp |
5da60 | 75 74 20 73 74 72 65 61 6d 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e | ut.stream.......*......*.@return |
5da80 | 20 72 65 73 6f 75 72 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e | .resource......*/.....public.fun |
5daa0 | 63 74 69 6f 6e 20 67 65 74 49 6e 70 75 74 53 74 72 65 61 6d 28 29 0a 20 20 20 20 7b 0a 20 20 20 | ction.getInputStream().....{.... |
5dac0 | 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 69 6e 70 75 74 53 74 72 65 61 6d 3b 0a | .....return.$this->inputStream;. |
5dae0 | 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 | ....}....../**......*.{@inheritd |
5db00 | 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 | oc}......*/.....public.function. |
5db20 | 67 65 74 4e 61 6d 65 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 27 | getName().....{.........return.' |
5db40 | 71 75 65 73 74 69 6f 6e 27 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a | question';.....}....../**......* |
5db60 | 20 41 73 6b 73 20 74 68 65 20 71 75 65 73 74 69 6f 6e 20 74 6f 20 74 68 65 20 75 73 65 72 2e 0a | .Asks.the.question.to.the.user.. |
5db80 | 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 4f 75 74 70 75 74 49 6e 74 65 72 | .....*......*.@param.OutputInter |
5dba0 | 66 61 63 65 20 24 6f 75 74 70 75 74 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 51 75 65 73 74 | face.$output......*.@param.Quest |
5dbc0 | 69 6f 6e 20 20 20 20 20 20 20 20 24 71 75 65 73 74 69 6f 6e 0a 20 20 20 20 20 2a 0a 20 20 20 20 | ion........$question......*..... |
5dbe0 | 20 2a 20 40 72 65 74 75 72 6e 20 62 6f 6f 6c 7c 6d 69 78 65 64 7c 6e 75 6c 6c 7c 73 74 72 69 6e | .*.@return.bool|mixed|null|strin |
5dc00 | 67 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 5c 45 78 63 65 70 74 69 | g......*......*.@throws.\Excepti |
5dc20 | 6f 6e 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 5c 52 75 6e 74 69 6d 65 45 78 63 65 70 74 | on......*.@throws.\RuntimeExcept |
5dc40 | 69 6f 6e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e | ion......*/.....private.function |
5dc60 | 20 64 6f 41 73 6b 28 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 2c 20 | .doAsk(OutputInterface.$output,. |
5dc80 | 51 75 65 73 74 69 6f 6e 20 24 71 75 65 73 74 69 6f 6e 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 | Question.$question).....{....... |
5dca0 | 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 50 72 6f 6d 70 74 28 24 6f 75 74 70 75 74 2c 20 24 71 | ..$this->writePrompt($output,.$q |
5dcc0 | 75 65 73 74 69 6f 6e 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 69 6e 70 75 74 53 74 72 65 61 6d 20 | uestion);..........$inputStream. |
5dce0 | 3d 20 24 74 68 69 73 2d 3e 69 6e 70 75 74 53 74 72 65 61 6d 20 3f 3a 20 53 54 44 49 4e 3b 0a 20 | =.$this->inputStream.?:.STDIN;.. |
5dd00 | 20 20 20 20 20 20 20 24 61 75 74 6f 63 6f 6d 70 6c 65 74 65 20 3d 20 24 71 75 65 73 74 69 6f 6e | .......$autocomplete.=.$question |
5dd20 | 2d 3e 67 65 74 41 75 74 6f 63 6f 6d 70 6c 65 74 65 72 56 61 6c 75 65 73 28 29 3b 0a 0a 20 20 20 | ->getAutocompleterValues();..... |
5dd40 | 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 61 75 74 6f 63 6f 6d 70 6c 65 74 65 20 | .....if.(null.===.$autocomplete. |
5dd60 | 7c 7c 20 21 24 74 68 69 73 2d 3e 68 61 73 53 74 74 79 41 76 61 69 6c 61 62 6c 65 28 29 29 20 7b | ||.!$this->hasSttyAvailable()).{ |
5dd80 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 72 65 74 20 3d 20 66 61 6c 73 65 3b 0a 20 20 20 20 20 | .............$ret.=.false;...... |
5dda0 | 20 20 20 20 20 20 20 69 66 20 28 24 71 75 65 73 74 69 6f 6e 2d 3e 69 73 48 69 64 64 65 6e 28 29 | .......if.($question->isHidden() |
5ddc0 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 72 79 20 7b 0a 20 20 20 20 20 20 | ).{.................try.{....... |
5dde0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 72 65 74 20 3d 20 74 72 69 6d 28 24 74 68 69 73 2d | ..............$ret.=.trim($this- |
5de00 | 3e 67 65 74 48 69 64 64 65 6e 52 65 73 70 6f 6e 73 65 28 24 6f 75 74 70 75 74 2c 20 24 69 6e 70 | >getHiddenResponse($output,.$inp |
5de20 | 75 74 53 74 72 65 61 6d 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 63 61 | utStream));.................}.ca |
5de40 | 74 63 68 20 28 5c 52 75 6e 74 69 6d 65 45 78 63 65 70 74 69 6f 6e 20 24 65 29 20 7b 0a 20 20 20 | tch.(\RuntimeException.$e).{.... |
5de60 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 21 24 71 75 65 73 74 69 6f 6e 2d | .................if.(!$question- |
5de80 | 3e 69 73 48 69 64 64 65 6e 46 61 6c 6c 62 61 63 6b 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | >isHiddenFallback()).{.......... |
5dea0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 24 65 3b 0a 20 20 20 20 20 20 20 | ...............throw.$e;........ |
5dec0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d | .............}.................} |
5dee0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 | .............}..............if.( |
5df00 | 66 61 6c 73 65 20 3d 3d 3d 20 24 72 65 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | false.===.$ret).{............... |
5df20 | 20 20 24 72 65 74 20 3d 20 66 67 65 74 73 28 24 69 6e 70 75 74 53 74 72 65 61 6d 2c 20 34 30 39 | ..$ret.=.fgets($inputStream,.409 |
5df40 | 36 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 66 61 6c 73 65 20 3d 3d | 6);.................if.(false.== |
5df60 | 3d 20 24 72 65 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 | =.$ret).{.....................th |
5df80 | 72 6f 77 20 6e 65 77 20 5c 52 75 6e 74 69 6d 65 45 78 63 65 70 74 69 6f 6e 28 27 41 62 6f 72 74 | row.new.\RuntimeException('Abort |
5dfa0 | 65 64 27 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 | ed');.................}......... |
5dfc0 | 20 20 20 20 20 20 20 20 24 72 65 74 20 3d 20 74 72 69 6d 28 24 72 65 74 29 3b 0a 20 20 20 20 20 | ........$ret.=.trim($ret);...... |
5dfe0 | 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 | .......}.........}.else.{....... |
5e000 | 20 20 20 20 20 20 24 72 65 74 20 3d 20 74 72 69 6d 28 24 74 68 69 73 2d 3e 61 75 74 6f 63 6f 6d | ......$ret.=.trim($this->autocom |
5e020 | 70 6c 65 74 65 28 24 6f 75 74 70 75 74 2c 20 24 71 75 65 73 74 69 6f 6e 2c 20 24 69 6e 70 75 74 | plete($output,.$question,.$input |
5e040 | 53 74 72 65 61 6d 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 72 65 | Stream));.........}..........$re |
5e060 | 74 20 3d 20 73 74 72 6c 65 6e 28 24 72 65 74 29 20 3e 20 30 20 3f 20 24 72 65 74 20 3a 20 24 71 | t.=.strlen($ret).>.0.?.$ret.:.$q |
5e080 | 75 65 73 74 69 6f 6e 2d 3e 67 65 74 44 65 66 61 75 6c 74 28 29 3b 0a 0a 20 20 20 20 20 20 20 20 | uestion->getDefault();.......... |
5e0a0 | 69 66 20 28 24 6e 6f 72 6d 61 6c 69 7a 65 72 20 3d 20 24 71 75 65 73 74 69 6f 6e 2d 3e 67 65 74 | if.($normalizer.=.$question->get |
5e0c0 | 4e 6f 72 6d 61 6c 69 7a 65 72 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 | Normalizer()).{.............retu |
5e0e0 | 72 6e 20 24 6e 6f 72 6d 61 6c 69 7a 65 72 28 24 72 65 74 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a | rn.$normalizer($ret);.........}. |
5e100 | 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 72 65 74 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 | .........return.$ret;.....}..... |
5e120 | 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 4f 75 74 70 75 74 73 20 74 68 65 20 71 75 65 73 74 69 6f 6e | ./**......*.Outputs.the.question |
5e140 | 20 70 72 6f 6d 70 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 4f 75 | .prompt.......*......*.@param.Ou |
5e160 | 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 0a 20 20 20 20 20 2a 20 40 70 61 | tputInterface.$output......*.@pa |
5e180 | 72 61 6d 20 51 75 65 73 74 69 6f 6e 20 20 20 20 20 20 20 20 24 71 75 65 73 74 69 6f 6e 0a 20 20 | ram.Question........$question... |
5e1a0 | 20 20 20 2a 2f 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 77 72 69 | ...*/.....protected.function.wri |
5e1c0 | 74 65 50 72 6f 6d 70 74 28 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 | tePrompt(OutputInterface.$output |
5e1e0 | 2c 20 51 75 65 73 74 69 6f 6e 20 24 71 75 65 73 74 69 6f 6e 29 0a 20 20 20 20 7b 0a 20 20 20 20 | ,.Question.$question).....{..... |
5e200 | 20 20 20 20 24 6d 65 73 73 61 67 65 20 3d 20 24 71 75 65 73 74 69 6f 6e 2d 3e 67 65 74 51 75 65 | ....$message.=.$question->getQue |
5e220 | 73 74 69 6f 6e 28 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 71 75 65 73 74 69 6f 6e 20 | stion();..........if.($question. |
5e240 | 69 6e 73 74 61 6e 63 65 6f 66 20 43 68 6f 69 63 65 51 75 65 73 74 69 6f 6e 29 20 7b 0a 20 20 20 | instanceof.ChoiceQuestion).{.... |
5e260 | 20 20 20 20 20 20 20 20 20 24 6d 61 78 57 69 64 74 68 20 3d 20 6d 61 78 28 61 72 72 61 79 5f 6d | .........$maxWidth.=.max(array_m |
5e280 | 61 70 28 61 72 72 61 79 28 24 74 68 69 73 2c 20 27 73 74 72 6c 65 6e 27 29 2c 20 61 72 72 61 79 | ap(array($this,.'strlen'),.array |
5e2a0 | 5f 6b 65 79 73 28 24 71 75 65 73 74 69 6f 6e 2d 3e 67 65 74 43 68 6f 69 63 65 73 28 29 29 29 29 | _keys($question->getChoices()))) |
5e2c0 | 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 73 20 3d 20 28 61 72 72 61 | ;..............$messages.=.(arra |
5e2e0 | 79 29 20 24 71 75 65 73 74 69 6f 6e 2d 3e 67 65 74 51 75 65 73 74 69 6f 6e 28 29 3b 0a 20 20 20 | y).$question->getQuestion();.... |
5e300 | 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 71 75 65 73 74 69 6f 6e 2d 3e 67 65 74 | .........foreach.($question->get |
5e320 | 43 68 6f 69 63 65 73 28 29 20 61 73 20 24 6b 65 79 20 3d 3e 20 24 76 61 6c 75 65 29 20 7b 0a 20 | Choices().as.$key.=>.$value).{.. |
5e340 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 77 69 64 74 68 20 3d 20 24 6d 61 78 57 69 64 74 | ...............$width.=.$maxWidt |
5e360 | 68 20 2d 20 24 74 68 69 73 2d 3e 73 74 72 6c 65 6e 28 24 6b 65 79 29 3b 0a 20 20 20 20 20 20 20 | h.-.$this->strlen($key);........ |
5e380 | 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 73 5b 5d 20 3d 20 27 20 20 5b 3c 69 6e 66 6f | .........$messages[].=.'..[<info |
5e3a0 | 3e 27 2e 24 6b 65 79 2e 73 74 72 5f 72 65 70 65 61 74 28 27 20 27 2c 20 24 77 69 64 74 68 29 2e | >'.$key.str_repeat('.',.$width). |
5e3c0 | 27 3c 2f 69 6e 66 6f 3e 5d 20 27 2e 24 76 61 6c 75 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | '</info>].'.$value;............. |
5e3e0 | 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 | }..............$output->writeln( |
5e400 | 24 6d 65 73 73 61 67 65 73 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 | $messages);..............$messag |
5e420 | 65 20 3d 20 24 71 75 65 73 74 69 6f 6e 2d 3e 67 65 74 50 72 6f 6d 70 74 28 29 3b 0a 20 20 20 20 | e.=.$question->getPrompt();..... |
5e440 | 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 28 24 6d | ....}..........$output->write($m |
5e460 | 65 73 73 61 67 65 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 4f | essage);.....}....../**......*.O |
5e480 | 75 74 70 75 74 73 20 61 6e 20 65 72 72 6f 72 20 6d 65 73 73 61 67 65 2e 0a 20 20 20 20 20 2a 0a | utputs.an.error.message.......*. |
5e4a0 | 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f | .....*.@param.OutputInterface.$o |
5e4c0 | 75 74 70 75 74 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 5c 45 78 63 65 70 74 69 6f 6e 20 20 | utput......*.@param.\Exception.. |
5e4e0 | 20 20 20 20 24 65 72 72 6f 72 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 | ....$error......*/.....protected |
5e500 | 20 66 75 6e 63 74 69 6f 6e 20 77 72 69 74 65 45 72 72 6f 72 28 4f 75 74 70 75 74 49 6e 74 65 72 | .function.writeError(OutputInter |
5e520 | 66 61 63 65 20 24 6f 75 74 70 75 74 2c 20 5c 45 78 63 65 70 74 69 6f 6e 20 24 65 72 72 6f 72 29 | face.$output,.\Exception.$error) |
5e540 | 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 21 3d 3d 20 24 74 68 69 | .....{.........if.(null.!==.$thi |
5e560 | 73 2d 3e 67 65 74 48 65 6c 70 65 72 53 65 74 28 29 20 26 26 20 24 74 68 69 73 2d 3e 67 65 74 48 | s->getHelperSet().&&.$this->getH |
5e580 | 65 6c 70 65 72 53 65 74 28 29 2d 3e 68 61 73 28 27 66 6f 72 6d 61 74 74 65 72 27 29 29 20 7b 0a | elperSet()->has('formatter')).{. |
5e5a0 | 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 20 3d 20 24 74 68 69 73 2d 3e 67 65 | ............$message.=.$this->ge |
5e5c0 | 74 48 65 6c 70 65 72 53 65 74 28 29 2d 3e 67 65 74 28 27 66 6f 72 6d 61 74 74 65 72 27 29 2d 3e | tHelperSet()->get('formatter')-> |
5e5e0 | 66 6f 72 6d 61 74 42 6c 6f 63 6b 28 24 65 72 72 6f 72 2d 3e 67 65 74 4d 65 73 73 61 67 65 28 29 | formatBlock($error->getMessage() |
5e600 | 2c 20 27 65 72 72 6f 72 27 29 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 | ,.'error');.........}.else.{.... |
5e620 | 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 20 3d 20 27 3c 65 72 72 6f 72 3e 27 2e 24 65 | .........$message.=.'<error>'.$e |
5e640 | 72 72 6f 72 2d 3e 67 65 74 4d 65 73 73 61 67 65 28 29 2e 27 3c 2f 65 72 72 6f 72 3e 27 3b 0a 20 | rror->getMessage().'</error>';.. |
5e660 | 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 | .......}..........$output->write |
5e680 | 6c 6e 28 24 6d 65 73 73 61 67 65 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 | ln($message);.....}....../**.... |
5e6a0 | 20 20 2a 20 41 75 74 6f 63 6f 6d 70 6c 65 74 65 73 20 61 20 71 75 65 73 74 69 6f 6e 2e 0a 20 20 | ..*.Autocompletes.a.question.... |
5e6c0 | 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 | ...*......*.@param.OutputInterfa |
5e6e0 | 63 65 20 24 6f 75 74 70 75 74 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 51 75 65 73 74 69 6f | ce.$output......*.@param.Questio |
5e700 | 6e 20 20 20 20 20 20 20 20 24 71 75 65 73 74 69 6f 6e 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d | n........$question......*.@param |
5e720 | 20 72 65 73 6f 75 72 63 65 20 20 20 20 20 20 20 20 24 69 6e 70 75 74 53 74 72 65 61 6d 0a 20 20 | .resource........$inputStream... |
5e740 | 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 0a 20 20 20 20 20 | ...*......*.@return.string...... |
5e760 | 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 61 75 74 6f 63 6f 6d 70 | */.....private.function.autocomp |
5e780 | 6c 65 74 65 28 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 2c 20 51 75 | lete(OutputInterface.$output,.Qu |
5e7a0 | 65 73 74 69 6f 6e 20 24 71 75 65 73 74 69 6f 6e 2c 20 24 69 6e 70 75 74 53 74 72 65 61 6d 29 0a | estion.$question,.$inputStream). |
5e7c0 | 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 61 75 74 6f 63 6f 6d 70 6c 65 74 65 20 3d 20 24 71 | ....{.........$autocomplete.=.$q |
5e7e0 | 75 65 73 74 69 6f 6e 2d 3e 67 65 74 41 75 74 6f 63 6f 6d 70 6c 65 74 65 72 56 61 6c 75 65 73 28 | uestion->getAutocompleterValues( |
5e800 | 29 3b 0a 20 20 20 20 20 20 20 20 24 72 65 74 20 3d 20 27 27 3b 0a 0a 20 20 20 20 20 20 20 20 24 | );.........$ret.=.'';..........$ |
5e820 | 69 20 3d 20 30 3b 0a 20 20 20 20 20 20 20 20 24 6f 66 73 20 3d 20 2d 31 3b 0a 20 20 20 20 20 20 | i.=.0;.........$ofs.=.-1;....... |
5e840 | 20 20 24 6d 61 74 63 68 65 73 20 3d 20 24 61 75 74 6f 63 6f 6d 70 6c 65 74 65 3b 0a 20 20 20 20 | ..$matches.=.$autocomplete;..... |
5e860 | 20 20 20 20 24 6e 75 6d 4d 61 74 63 68 65 73 20 3d 20 63 6f 75 6e 74 28 24 6d 61 74 63 68 65 73 | ....$numMatches.=.count($matches |
5e880 | 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 73 74 74 79 4d 6f 64 65 20 3d 20 73 68 65 6c 6c 5f 65 78 | );..........$sttyMode.=.shell_ex |
5e8a0 | 65 63 28 27 73 74 74 79 20 2d 67 27 29 3b 0a 0a 20 20 20 20 20 20 20 20 2f 2f 20 44 69 73 61 62 | ec('stty.-g');..........//.Disab |
5e8c0 | 6c 65 20 69 63 61 6e 6f 6e 20 28 73 6f 20 77 65 20 63 61 6e 20 66 72 65 61 64 20 65 61 63 68 20 | le.icanon.(so.we.can.fread.each. |
5e8e0 | 6b 65 79 70 72 65 73 73 29 20 61 6e 64 20 65 63 68 6f 20 28 77 65 27 6c 6c 20 64 6f 20 65 63 68 | keypress).and.echo.(we'll.do.ech |
5e900 | 6f 69 6e 67 20 68 65 72 65 20 69 6e 73 74 65 61 64 29 0a 20 20 20 20 20 20 20 20 73 68 65 6c 6c | oing.here.instead).........shell |
5e920 | 5f 65 78 65 63 28 27 73 74 74 79 20 2d 69 63 61 6e 6f 6e 20 2d 65 63 68 6f 27 29 3b 0a 0a 20 20 | _exec('stty.-icanon.-echo');.... |
5e940 | 20 20 20 20 20 20 2f 2f 20 41 64 64 20 68 69 67 68 6c 69 67 68 74 65 64 20 74 65 78 74 20 73 74 | ......//.Add.highlighted.text.st |
5e960 | 79 6c 65 0a 20 20 20 20 20 20 20 20 24 6f 75 74 70 75 74 2d 3e 67 65 74 46 6f 72 6d 61 74 74 65 | yle.........$output->getFormatte |
5e980 | 72 28 29 2d 3e 73 65 74 53 74 79 6c 65 28 27 68 6c 27 2c 20 6e 65 77 20 4f 75 74 70 75 74 46 6f | r()->setStyle('hl',.new.OutputFo |
5e9a0 | 72 6d 61 74 74 65 72 53 74 79 6c 65 28 27 62 6c 61 63 6b 27 2c 20 27 77 68 69 74 65 27 29 29 3b | rmatterStyle('black',.'white')); |
5e9c0 | 0a 0a 20 20 20 20 20 20 20 20 2f 2f 20 52 65 61 64 20 61 20 6b 65 79 70 72 65 73 73 0a 20 20 20 | ..........//.Read.a.keypress.... |
5e9e0 | 20 20 20 20 20 77 68 69 6c 65 20 28 21 66 65 6f 66 28 24 69 6e 70 75 74 53 74 72 65 61 6d 29 29 | .....while.(!feof($inputStream)) |
5ea00 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 63 20 3d 20 66 72 65 61 64 28 24 69 6e 70 75 74 | .{.............$c.=.fread($input |
5ea20 | 53 74 72 65 61 6d 2c 20 31 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 42 61 63 6b | Stream,.1);..............//.Back |
5ea40 | 73 70 61 63 65 20 43 68 61 72 61 63 74 65 72 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 | space.Character.............if.( |
5ea60 | 22 5c 31 37 37 22 20 3d 3d 3d 20 24 63 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | "\177".===.$c).{................ |
5ea80 | 20 69 66 20 28 30 20 3d 3d 3d 20 24 6e 75 6d 4d 61 74 63 68 65 73 20 26 26 20 30 20 21 3d 3d 20 | .if.(0.===.$numMatches.&&.0.!==. |
5eaa0 | 24 69 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2d 2d 24 69 3b 0a | $i).{.....................--$i;. |
5eac0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 4d 6f 76 65 20 63 75 72 73 | ....................//.Move.curs |
5eae0 | 6f 72 20 62 61 63 6b 77 61 72 64 73 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | or.backwards.................... |
5eb00 | 20 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 28 22 5c 30 33 33 5b 31 44 22 29 3b 0a 20 20 20 20 | .$output->write("\033[1D");..... |
5eb20 | 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 | ............}..................i |
5eb40 | 66 20 28 24 69 20 3d 3d 3d 20 30 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | f.($i.===.0).{.................. |
5eb60 | 20 20 20 24 6f 66 73 20 3d 20 2d 31 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ...$ofs.=.-1;................... |
5eb80 | 20 20 24 6d 61 74 63 68 65 73 20 3d 20 24 61 75 74 6f 63 6f 6d 70 6c 65 74 65 3b 0a 20 20 20 20 | ..$matches.=.$autocomplete;..... |
5eba0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6e 75 6d 4d 61 74 63 68 65 73 20 3d 20 63 6f | ................$numMatches.=.co |
5ebc0 | 75 6e 74 28 24 6d 61 74 63 68 65 73 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d | unt($matches);.................} |
5ebe0 | 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6e 75 6d | .else.{.....................$num |
5ec00 | 4d 61 74 63 68 65 73 20 3d 20 30 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a | Matches.=.0;.................}.. |
5ec20 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 50 6f 70 20 74 68 65 20 6c 61 73 74 20 | ................//.Pop.the.last. |
5ec40 | 63 68 61 72 61 63 74 65 72 20 6f 66 66 20 74 68 65 20 65 6e 64 20 6f 66 20 6f 75 72 20 73 74 72 | character.off.the.end.of.our.str |
5ec60 | 69 6e 67 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 72 65 74 20 3d 20 73 75 62 73 74 | ing.................$ret.=.subst |
5ec80 | 72 28 24 72 65 74 2c 20 30 2c 20 24 69 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c | r($ret,.0,.$i);.............}.el |
5eca0 | 73 65 69 66 20 28 22 5c 30 33 33 22 20 3d 3d 3d 20 24 63 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | seif.("\033".===.$c).{.......... |
5ecc0 | 20 20 20 20 20 20 20 2f 2f 20 44 69 64 20 77 65 20 72 65 61 64 20 61 6e 20 65 73 63 61 70 65 20 | .......//.Did.we.read.an.escape. |
5ece0 | 73 65 71 75 65 6e 63 65 3f 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 63 20 2e 3d 20 | sequence?.................$c..=. |
5ed00 | 66 72 65 61 64 28 24 69 6e 70 75 74 53 74 72 65 61 6d 2c 20 32 29 3b 0a 0a 20 20 20 20 20 20 20 | fread($inputStream,.2);......... |
5ed20 | 20 20 20 20 20 20 20 20 20 2f 2f 20 41 20 3d 20 55 70 20 41 72 72 6f 77 2e 20 42 20 3d 20 44 6f | .........//.A.=.Up.Arrow..B.=.Do |
5ed40 | 77 6e 20 41 72 72 6f 77 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 69 73 73 | wn.Arrow.................if.(iss |
5ed60 | 65 74 28 24 63 5b 32 5d 29 20 26 26 20 28 27 41 27 20 3d 3d 3d 20 24 63 5b 32 5d 20 7c 7c 20 27 | et($c[2]).&&.('A'.===.$c[2].||.' |
5ed80 | 42 27 20 3d 3d 3d 20 24 63 5b 32 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | B'.===.$c[2])).{................ |
5eda0 | 20 20 20 20 20 69 66 20 28 27 41 27 20 3d 3d 3d 20 24 63 5b 32 5d 20 26 26 20 2d 31 20 3d 3d 3d | .....if.('A'.===.$c[2].&&.-1.=== |
5edc0 | 20 24 6f 66 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | .$ofs).{........................ |
5ede0 | 20 24 6f 66 73 20 3d 20 30 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d | .$ofs.=.0;.....................} |
5ee00 | 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 30 20 3d 3d 3d 20 | ......................if.(0.===. |
5ee20 | 24 6e 75 6d 4d 61 74 63 68 65 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | $numMatches).{.................. |
5ee40 | 20 20 20 20 20 20 20 63 6f 6e 74 69 6e 75 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | .......continue;................ |
5ee60 | 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 66 73 | .....}......................$ofs |
5ee80 | 20 2b 3d 20 28 27 41 27 20 3d 3d 3d 20 24 63 5b 32 5d 29 20 3f 20 2d 31 20 3a 20 31 3b 0a 20 20 | .+=.('A'.===.$c[2]).?.-1.:.1;... |
5eea0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 66 73 20 3d 20 28 24 6e 75 6d 4d 61 | ..................$ofs.=.($numMa |
5eec0 | 74 63 68 65 73 20 2b 20 24 6f 66 73 29 20 25 20 24 6e 75 6d 4d 61 74 63 68 65 73 3b 0a 20 20 20 | tches.+.$ofs).%.$numMatches;.... |
5eee0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 | .............}.............}.els |
5ef00 | 65 69 66 20 28 6f 72 64 28 24 63 29 20 3c 20 33 32 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | eif.(ord($c).<.32).{............ |
5ef20 | 20 20 20 20 20 69 66 20 28 22 5c 74 22 20 3d 3d 3d 20 24 63 20 7c 7c 20 22 5c 6e 22 20 3d 3d 3d | .....if.("\t".===.$c.||."\n".=== |
5ef40 | 20 24 63 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 | .$c).{.....................if.($ |
5ef60 | 6e 75 6d 4d 61 74 63 68 65 73 20 3e 20 30 20 26 26 20 2d 31 20 21 3d 3d 20 24 6f 66 73 29 20 7b | numMatches.>.0.&&.-1.!==.$ofs).{ |
5ef80 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 72 65 74 20 3d 20 | .........................$ret.=. |
5efa0 | 24 6d 61 74 63 68 65 73 5b 24 6f 66 73 5d 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | $matches[$ofs];................. |
5efc0 | 20 20 20 20 20 20 20 20 2f 2f 20 45 63 68 6f 20 6f 75 74 20 72 65 6d 61 69 6e 69 6e 67 20 63 68 | ........//.Echo.out.remaining.ch |
5efe0 | 61 72 73 20 66 6f 72 20 63 75 72 72 65 6e 74 20 6d 61 74 63 68 0a 20 20 20 20 20 20 20 20 20 20 | ars.for.current.match........... |
5f000 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 28 73 75 62 | ..............$output->write(sub |
5f020 | 73 74 72 28 24 72 65 74 2c 20 24 69 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | str($ret,.$i));................. |
5f040 | 20 20 20 20 20 20 20 20 24 69 20 3d 20 73 74 72 6c 65 6e 28 24 72 65 74 29 3b 0a 20 20 20 20 20 | ........$i.=.strlen($ret);...... |
5f060 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ...............}................ |
5f080 | 20 20 20 20 20 20 69 66 20 28 22 5c 6e 22 20 3d 3d 3d 20 24 63 29 20 7b 0a 20 20 20 20 20 20 20 | ......if.("\n".===.$c).{........ |
5f0a0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 28 | .................$output->write( |
5f0c0 | 24 63 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 62 72 65 | $c);.........................bre |
5f0e0 | 61 6b 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 | ak;.....................}....... |
5f100 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6e 75 6d 4d 61 74 63 68 65 73 20 3d 20 30 3b 0a | ...............$numMatches.=.0;. |
5f120 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | ................}............... |
5f140 | 20 20 20 63 6f 6e 74 69 6e 75 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 | ...continue;.............}.else. |
5f160 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 | {.................$output->write |
5f180 | 28 24 63 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 72 65 74 20 2e 3d 20 24 63 | ($c);.................$ret..=.$c |
5f1a0 | 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2b 2b 24 69 3b 0a 0a 20 20 20 20 20 20 20 | ;.................++$i;......... |
5f1c0 | 20 20 20 20 20 20 20 20 20 24 6e 75 6d 4d 61 74 63 68 65 73 20 3d 20 30 3b 0a 20 20 20 20 20 20 | .........$numMatches.=.0;....... |
5f1e0 | 20 20 20 20 20 20 20 20 20 20 24 6f 66 73 20 3d 20 30 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 | ..........$ofs.=.0;............. |
5f200 | 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 61 75 74 6f 63 6f 6d 70 6c 65 74 65 20 61 73 20 24 | .....foreach.($autocomplete.as.$ |
5f220 | 76 61 6c 75 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 | value).{.....................//. |
5f240 | 49 66 20 74 79 70 65 64 20 63 68 61 72 61 63 74 65 72 73 20 6d 61 74 63 68 20 74 68 65 20 62 65 | If.typed.characters.match.the.be |
5f260 | 67 69 6e 6e 69 6e 67 20 63 68 75 6e 6b 20 6f 66 20 76 61 6c 75 65 20 28 65 2e 67 2e 20 5b 41 63 | ginning.chunk.of.value.(e.g..[Ac |
5f280 | 6d 65 44 65 5d 6d 6f 42 75 6e 64 6c 65 29 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | meDe]moBundle).................. |
5f2a0 | 20 20 20 69 66 20 28 30 20 3d 3d 3d 20 73 74 72 70 6f 73 28 24 76 61 6c 75 65 2c 20 24 72 65 74 | ...if.(0.===.strpos($value,.$ret |
5f2c0 | 29 20 26 26 20 24 69 20 21 3d 3d 20 73 74 72 6c 65 6e 28 24 76 61 6c 75 65 29 29 20 7b 0a 20 20 | ).&&.$i.!==.strlen($value)).{... |
5f2e0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 61 74 63 68 65 73 5b 24 | ......................$matches[$ |
5f300 | 6e 75 6d 4d 61 74 63 68 65 73 2b 2b 5d 20 3d 20 24 76 61 6c 75 65 3b 0a 20 20 20 20 20 20 20 20 | numMatches++].=.$value;......... |
5f320 | 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a | ............}.................}. |
5f340 | 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 45 72 | ............}..............//.Er |
5f360 | 61 73 65 20 63 68 61 72 61 63 74 65 72 73 20 66 72 6f 6d 20 63 75 72 73 6f 72 20 74 6f 20 65 6e | ase.characters.from.cursor.to.en |
5f380 | 64 20 6f 66 20 6c 69 6e 65 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 75 74 70 75 74 2d 3e 77 | d.of.line.............$output->w |
5f3a0 | 72 69 74 65 28 22 5c 30 33 33 5b 4b 22 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 | rite("\033[K");..............if. |
5f3c0 | 28 24 6e 75 6d 4d 61 74 63 68 65 73 20 3e 20 30 20 26 26 20 2d 31 20 21 3d 3d 20 24 6f 66 73 29 | ($numMatches.>.0.&&.-1.!==.$ofs) |
5f3e0 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 53 61 76 65 20 63 75 72 73 6f | .{.................//.Save.curso |
5f400 | 72 20 70 6f 73 69 74 69 6f 6e 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 75 74 70 | r.position.................$outp |
5f420 | 75 74 2d 3e 77 72 69 74 65 28 22 5c 30 33 33 37 22 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ut->write("\0337");............. |
5f440 | 20 20 20 20 2f 2f 20 57 72 69 74 65 20 68 69 67 68 6c 69 67 68 74 65 64 20 74 65 78 74 0a 20 20 | ....//.Write.highlighted.text... |
5f460 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 28 27 3c 68 | ..............$output->write('<h |
5f480 | 6c 3e 27 2e 73 75 62 73 74 72 28 24 6d 61 74 63 68 65 73 5b 24 6f 66 73 5d 2c 20 24 69 29 2e 27 | l>'.substr($matches[$ofs],.$i).' |
5f4a0 | 3c 2f 68 6c 3e 27 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 52 65 73 74 | </hl>');.................//.Rest |
5f4c0 | 6f 72 65 20 63 75 72 73 6f 72 20 70 6f 73 69 74 69 6f 6e 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ore.cursor.position............. |
5f4e0 | 20 20 20 20 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 28 22 5c 30 33 33 38 22 29 3b 0a 20 20 20 | ....$output->write("\0338");.... |
5f500 | 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 2f 2f | .........}.........}..........// |
5f520 | 20 52 65 73 65 74 20 73 74 74 79 20 73 6f 20 69 74 20 62 65 68 61 76 65 73 20 6e 6f 72 6d 61 6c | .Reset.stty.so.it.behaves.normal |
5f540 | 6c 79 20 61 67 61 69 6e 0a 20 20 20 20 20 20 20 20 73 68 65 6c 6c 5f 65 78 65 63 28 73 70 72 69 | ly.again.........shell_exec(spri |
5f560 | 6e 74 66 28 27 73 74 74 79 20 25 73 27 2c 20 24 73 74 74 79 4d 6f 64 65 29 29 3b 0a 0a 20 20 20 | ntf('stty.%s',.$sttyMode));..... |
5f580 | 20 20 20 20 20 72 65 74 75 72 6e 20 24 72 65 74 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a | .....return.$ret;.....}....../** |
5f5a0 | 0a 20 20 20 20 20 2a 20 47 65 74 73 20 61 20 68 69 64 64 65 6e 20 72 65 73 70 6f 6e 73 65 20 66 | ......*.Gets.a.hidden.response.f |
5f5c0 | 72 6f 6d 20 75 73 65 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 4f | rom.user.......*......*.@param.O |
5f5e0 | 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 20 20 20 20 20 20 41 6e 20 4f | utputInterface.$output......An.O |
5f600 | 75 74 70 75 74 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 72 65 73 | utput.instance......*.@param.res |
5f620 | 6f 75 72 63 65 20 20 20 20 20 20 20 20 24 69 6e 70 75 74 53 74 72 65 61 6d 20 54 68 65 20 68 61 | ource........$inputStream.The.ha |
5f640 | 6e 64 6c 65 72 20 72 65 73 6f 75 72 63 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 | ndler.resource......*......*.@re |
5f660 | 74 75 72 6e 20 73 74 72 69 6e 67 20 54 68 65 20 61 6e 73 77 65 72 0a 20 20 20 20 20 2a 0a 20 20 | turn.string.The.answer......*... |
5f680 | 20 20 20 2a 20 40 74 68 72 6f 77 73 20 52 75 6e 74 69 6d 65 45 78 63 65 70 74 69 6f 6e 20 49 6e | ...*.@throws.RuntimeException.In |
5f6a0 | 20 63 61 73 65 20 74 68 65 20 66 61 6c 6c 62 61 63 6b 20 69 73 20 64 65 61 63 74 69 76 61 74 65 | .case.the.fallback.is.deactivate |
5f6c0 | 64 20 61 6e 64 20 74 68 65 20 72 65 73 70 6f 6e 73 65 20 63 61 6e 6e 6f 74 20 62 65 20 68 69 64 | d.and.the.response.cannot.be.hid |
5f6e0 | 64 65 6e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e | den......*/.....private.function |
5f700 | 20 67 65 74 48 69 64 64 65 6e 52 65 73 70 6f 6e 73 65 28 4f 75 74 70 75 74 49 6e 74 65 72 66 61 | .getHiddenResponse(OutputInterfa |
5f720 | 63 65 20 24 6f 75 74 70 75 74 2c 20 24 69 6e 70 75 74 53 74 72 65 61 6d 29 0a 20 20 20 20 7b 0a | ce.$output,.$inputStream).....{. |
5f740 | 20 20 20 20 20 20 20 20 69 66 20 28 27 5c 5c 27 20 3d 3d 3d 20 44 49 52 45 43 54 4f 52 59 5f 53 | ........if.('\\'.===.DIRECTORY_S |
5f760 | 45 50 41 52 41 54 4f 52 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 65 78 65 20 3d 20 5f | EPARATOR).{.............$exe.=._ |
5f780 | 5f 44 49 52 5f 5f 2e 27 2f 2e 2e 2f 52 65 73 6f 75 72 63 65 73 2f 62 69 6e 2f 68 69 64 64 65 6e | _DIR__.'/../Resources/bin/hidden |
5f7a0 | 69 6e 70 75 74 2e 65 78 65 27 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 68 61 6e 64 | input.exe';..............//.hand |
5f7c0 | 6c 65 20 63 6f 64 65 20 72 75 6e 6e 69 6e 67 20 66 72 6f 6d 20 61 20 70 68 61 72 0a 20 20 20 20 | le.code.running.from.a.phar..... |
5f7e0 | 20 20 20 20 20 20 20 20 69 66 20 28 27 70 68 61 72 3a 27 20 3d 3d 3d 20 73 75 62 73 74 72 28 5f | ........if.('phar:'.===.substr(_ |
5f800 | 5f 46 49 4c 45 5f 5f 2c 20 30 2c 20 35 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | _FILE__,.0,.5)).{............... |
5f820 | 20 20 24 74 6d 70 45 78 65 20 3d 20 73 79 73 5f 67 65 74 5f 74 65 6d 70 5f 64 69 72 28 29 2e 27 | ..$tmpExe.=.sys_get_temp_dir().' |
5f840 | 2f 68 69 64 64 65 6e 69 6e 70 75 74 2e 65 78 65 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | /hiddeninput.exe';.............. |
5f860 | 20 20 20 63 6f 70 79 28 24 65 78 65 2c 20 24 74 6d 70 45 78 65 29 3b 0a 20 20 20 20 20 20 20 20 | ...copy($exe,.$tmpExe);......... |
5f880 | 20 20 20 20 20 20 20 20 24 65 78 65 20 3d 20 24 74 6d 70 45 78 65 3b 0a 20 20 20 20 20 20 20 20 | ........$exe.=.$tmpExe;......... |
5f8a0 | 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 76 61 6c 75 65 20 3d 20 72 74 72 69 | ....}..............$value.=.rtri |
5f8c0 | 6d 28 73 68 65 6c 6c 5f 65 78 65 63 28 24 65 78 65 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 | m(shell_exec($exe));............ |
5f8e0 | 20 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 27 27 29 3b 0a 0a 20 20 20 20 20 20 20 20 | .$output->writeln('');.......... |
5f900 | 20 20 20 20 69 66 20 28 69 73 73 65 74 28 24 74 6d 70 45 78 65 29 29 20 7b 0a 20 20 20 20 20 20 | ....if.(isset($tmpExe)).{....... |
5f920 | 20 20 20 20 20 20 20 20 20 20 75 6e 6c 69 6e 6b 28 24 74 6d 70 45 78 65 29 3b 0a 20 20 20 20 20 | ..........unlink($tmpExe);...... |
5f940 | 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 76 61 | .......}..............return.$va |
5f960 | 6c 75 65 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 74 68 69 | lue;.........}..........if.($thi |
5f980 | 73 2d 3e 68 61 73 53 74 74 79 41 76 61 69 6c 61 62 6c 65 28 29 29 20 7b 0a 20 20 20 20 20 20 20 | s->hasSttyAvailable()).{........ |
5f9a0 | 20 20 20 20 20 24 73 74 74 79 4d 6f 64 65 20 3d 20 73 68 65 6c 6c 5f 65 78 65 63 28 27 73 74 74 | .....$sttyMode.=.shell_exec('stt |
5f9c0 | 79 20 2d 67 27 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 73 68 65 6c 6c 5f 65 78 65 63 28 | y.-g');..............shell_exec( |
5f9e0 | 27 73 74 74 79 20 2d 65 63 68 6f 27 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 76 61 6c 75 | 'stty.-echo');.............$valu |
5fa00 | 65 20 3d 20 66 67 65 74 73 28 24 69 6e 70 75 74 53 74 72 65 61 6d 2c 20 34 30 39 36 29 3b 0a 20 | e.=.fgets($inputStream,.4096);.. |
5fa20 | 20 20 20 20 20 20 20 20 20 20 20 73 68 65 6c 6c 5f 65 78 65 63 28 73 70 72 69 6e 74 66 28 27 73 | ...........shell_exec(sprintf('s |
5fa40 | 74 74 79 20 25 73 27 2c 20 24 73 74 74 79 4d 6f 64 65 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 | tty.%s',.$sttyMode));........... |
5fa60 | 20 20 20 69 66 20 28 66 61 6c 73 65 20 3d 3d 3d 20 24 76 61 6c 75 65 29 20 7b 0a 20 20 20 20 20 | ...if.(false.===.$value).{...... |
5fa80 | 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 52 75 6e 74 69 6d 65 45 78 63 65 | ...........throw.new.RuntimeExce |
5faa0 | 70 74 69 6f 6e 28 27 41 62 6f 72 74 65 64 27 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a | ption('Aborted');.............}. |
5fac0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 76 61 6c 75 65 20 3d 20 74 72 69 6d 28 24 76 61 6c 75 | .............$value.=.trim($valu |
5fae0 | 65 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e | e);.............$output->writeln |
5fb00 | 28 27 27 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 76 61 6c 75 65 | ('');..............return.$value |
5fb20 | 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 66 61 6c 73 65 20 21 | ;.........}..........if.(false.! |
5fb40 | 3d 3d 20 24 73 68 65 6c 6c 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 53 68 65 6c 6c 28 29 29 20 7b | ==.$shell.=.$this->getShell()).{ |
5fb60 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 72 65 61 64 43 6d 64 20 3d 20 24 73 68 65 6c 6c 20 3d | .............$readCmd.=.$shell.= |
5fb80 | 3d 3d 20 27 63 73 68 27 20 3f 20 27 73 65 74 20 6d 79 70 61 73 73 77 6f 72 64 20 3d 20 24 3c 27 | ==.'csh'.?.'set.mypassword.=.$<' |
5fba0 | 20 3a 20 27 72 65 61 64 20 2d 72 20 6d 79 70 61 73 73 77 6f 72 64 27 3b 0a 20 20 20 20 20 20 20 | .:.'read.-r.mypassword';........ |
5fbc0 | 20 20 20 20 20 24 63 6f 6d 6d 61 6e 64 20 3d 20 73 70 72 69 6e 74 66 28 22 2f 75 73 72 2f 62 69 | .....$command.=.sprintf("/usr/bi |
5fbe0 | 6e 2f 65 6e 76 20 25 73 20 2d 63 20 27 73 74 74 79 20 2d 65 63 68 6f 3b 20 25 73 3b 20 73 74 74 | n/env.%s.-c.'stty.-echo;.%s;.stt |
5fc00 | 79 20 65 63 68 6f 3b 20 65 63 68 6f 20 5c 24 6d 79 70 61 73 73 77 6f 72 64 27 22 2c 20 24 73 68 | y.echo;.echo.\$mypassword'",.$sh |
5fc20 | 65 6c 6c 2c 20 24 72 65 61 64 43 6d 64 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 76 61 6c | ell,.$readCmd);.............$val |
5fc40 | 75 65 20 3d 20 72 74 72 69 6d 28 73 68 65 6c 6c 5f 65 78 65 63 28 24 63 6f 6d 6d 61 6e 64 29 29 | ue.=.rtrim(shell_exec($command)) |
5fc60 | 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 27 | ;.............$output->writeln(' |
5fc80 | 27 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 76 61 6c 75 65 3b 0a | ');..............return.$value;. |
5fca0 | 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 52 75 6e | ........}..........throw.new.Run |
5fcc0 | 74 69 6d 65 45 78 63 65 70 74 69 6f 6e 28 27 55 6e 61 62 6c 65 20 74 6f 20 68 69 64 65 20 74 68 | timeException('Unable.to.hide.th |
5fce0 | 65 20 72 65 73 70 6f 6e 73 65 2e 27 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 | e.response.');.....}....../**... |
5fd00 | 20 20 20 2a 20 56 61 6c 69 64 61 74 65 73 20 61 6e 20 61 74 74 65 6d 70 74 2e 0a 20 20 20 20 20 | ...*.Validates.an.attempt....... |
5fd20 | 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 63 61 6c 6c 61 62 6c 65 20 20 20 20 20 20 20 20 | *......*.@param.callable........ |
5fd40 | 24 69 6e 74 65 72 76 69 65 77 65 72 20 41 20 63 61 6c 6c 61 62 6c 65 20 74 68 61 74 20 77 69 6c | $interviewer.A.callable.that.wil |
5fd60 | 6c 20 61 73 6b 20 66 6f 72 20 61 20 71 75 65 73 74 69 6f 6e 20 61 6e 64 20 72 65 74 75 72 6e 20 | l.ask.for.a.question.and.return. |
5fd80 | 74 68 65 20 72 65 73 75 6c 74 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 4f 75 74 70 75 74 49 | the.result......*.@param.OutputI |
5fda0 | 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 20 20 20 20 20 20 41 6e 20 4f 75 74 70 75 74 20 | nterface.$output......An.Output. |
5fdc0 | 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 51 75 65 73 74 69 6f 6e 20 | instance......*.@param.Question. |
5fde0 | 20 20 20 20 20 20 20 24 71 75 65 73 74 69 6f 6e 20 20 20 20 41 20 51 75 65 73 74 69 6f 6e 20 69 | .......$question....A.Question.i |
5fe00 | 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 | nstance......*......*.@return.st |
5fe20 | 72 69 6e 67 20 54 68 65 20 76 61 6c 69 64 61 74 65 64 20 72 65 73 70 6f 6e 73 65 0a 20 20 20 20 | ring.The.validated.response..... |
5fe40 | 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 5c 45 78 63 65 70 74 69 6f 6e 20 49 6e 20 | .*......*.@throws.\Exception.In. |
5fe60 | 63 61 73 65 20 74 68 65 20 6d 61 78 20 6e 75 6d 62 65 72 20 6f 66 20 61 74 74 65 6d 70 74 73 20 | case.the.max.number.of.attempts. |
5fe80 | 68 61 73 20 62 65 65 6e 20 72 65 61 63 68 65 64 20 61 6e 64 20 6e 6f 20 76 61 6c 69 64 20 72 65 | has.been.reached.and.no.valid.re |
5fea0 | 73 70 6f 6e 73 65 20 68 61 73 20 62 65 65 6e 20 67 69 76 65 6e 0a 20 20 20 20 20 2a 2f 0a 20 20 | sponse.has.been.given......*/... |
5fec0 | 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 76 61 6c 69 64 61 74 65 41 74 74 65 6d | ..private.function.validateAttem |
5fee0 | 70 74 73 28 63 61 6c 6c 61 62 6c 65 20 24 69 6e 74 65 72 76 69 65 77 65 72 2c 20 4f 75 74 70 75 | pts(callable.$interviewer,.Outpu |
5ff00 | 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 2c 20 51 75 65 73 74 69 6f 6e 20 24 71 75 | tInterface.$output,.Question.$qu |
5ff20 | 65 73 74 69 6f 6e 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 65 72 72 6f 72 20 3d 20 6e | estion).....{.........$error.=.n |
5ff40 | 75 6c 6c 3b 0a 20 20 20 20 20 20 20 20 24 61 74 74 65 6d 70 74 73 20 3d 20 24 71 75 65 73 74 69 | ull;.........$attempts.=.$questi |
5ff60 | 6f 6e 2d 3e 67 65 74 4d 61 78 41 74 74 65 6d 70 74 73 28 29 3b 0a 20 20 20 20 20 20 20 20 77 68 | on->getMaxAttempts();.........wh |
5ff80 | 69 6c 65 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 61 74 74 65 6d 70 74 73 20 7c 7c 20 24 61 74 74 65 | ile.(null.===.$attempts.||.$atte |
5ffa0 | 6d 70 74 73 2d 2d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 21 | mpts--).{.............if.(null.! |
5ffc0 | 3d 3d 20 24 65 72 72 6f 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 | ==.$error).{.................$th |
5ffe0 | 69 73 2d 3e 77 72 69 74 65 45 72 72 6f 72 28 24 6f 75 74 70 75 74 2c 20 24 65 72 72 6f 72 29 3b | is->writeError($output,.$error); |
60000 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 72 79 20 | .............}..............try. |
60020 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 63 61 6c 6c 5f 75 73 | {.................return.call_us |
60040 | 65 72 5f 66 75 6e 63 28 24 71 75 65 73 74 69 6f 6e 2d 3e 67 65 74 56 61 6c 69 64 61 74 6f 72 28 | er_func($question->getValidator( |
60060 | 29 2c 20 24 69 6e 74 65 72 76 69 65 77 65 72 28 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ),.$interviewer());............. |
60080 | 7d 20 63 61 74 63 68 20 28 5c 45 78 63 65 70 74 69 6f 6e 20 24 65 72 72 6f 72 29 20 7b 0a 20 20 | }.catch.(\Exception.$error).{... |
600a0 | 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 74 | ..........}.........}..........t |
600c0 | 68 72 6f 77 20 24 65 72 72 6f 72 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 | hrow.$error;.....}....../**..... |
600e0 | 20 2a 20 52 65 74 75 72 6e 73 20 61 20 76 61 6c 69 64 20 75 6e 69 78 20 73 68 65 6c 6c 2e 0a 20 | .*.Returns.a.valid.unix.shell... |
60100 | 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 7c 62 6f 6f 6c | ....*......*.@return.string|bool |
60120 | 20 54 68 65 20 76 61 6c 69 64 20 73 68 65 6c 6c 20 6e 61 6d 65 2c 20 66 61 6c 73 65 20 69 6e 20 | .The.valid.shell.name,.false.in. |
60140 | 63 61 73 65 20 6e 6f 20 76 61 6c 69 64 20 73 68 65 6c 6c 20 69 73 20 66 6f 75 6e 64 0a 20 20 20 | case.no.valid.shell.is.found.... |
60160 | 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 53 68 65 | ..*/.....private.function.getShe |
60180 | 6c 6c 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 21 3d 3d 20 | ll().....{.........if.(null.!==. |
601a0 | 73 65 6c 66 3a 3a 24 73 68 65 6c 6c 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 | self::$shell).{.............retu |
601c0 | 72 6e 20 73 65 6c 66 3a 3a 24 73 68 65 6c 6c 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 | rn.self::$shell;.........}...... |
601e0 | 20 20 20 20 73 65 6c 66 3a 3a 24 73 68 65 6c 6c 20 3d 20 66 61 6c 73 65 3b 0a 0a 20 20 20 20 20 | ....self::$shell.=.false;....... |
60200 | 20 20 20 69 66 20 28 66 69 6c 65 5f 65 78 69 73 74 73 28 27 2f 75 73 72 2f 62 69 6e 2f 65 6e 76 | ...if.(file_exists('/usr/bin/env |
60220 | 27 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 68 61 6e 64 6c 65 20 6f 74 68 65 | ')).{.............//.handle.othe |
60240 | 72 20 4f 53 73 20 77 69 74 68 20 62 61 73 68 2f 7a 73 68 2f 6b 73 68 2f 63 73 68 20 69 66 20 61 | r.OSs.with.bash/zsh/ksh/csh.if.a |
60260 | 76 61 69 6c 61 62 6c 65 20 74 6f 20 68 69 64 65 20 74 68 65 20 61 6e 73 77 65 72 0a 20 20 20 20 | vailable.to.hide.the.answer..... |
60280 | 20 20 20 20 20 20 20 20 24 74 65 73 74 20 3d 20 22 2f 75 73 72 2f 62 69 6e 2f 65 6e 76 20 25 73 | ........$test.=."/usr/bin/env.%s |
602a0 | 20 2d 63 20 27 65 63 68 6f 20 4f 4b 27 20 32 3e 20 2f 64 65 76 2f 6e 75 6c 6c 22 3b 0a 20 20 20 | .-c.'echo.OK'.2>./dev/null";.... |
602c0 | 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 61 72 72 61 79 28 27 62 61 73 68 27 2c 20 | .........foreach.(array('bash',. |
602e0 | 27 7a 73 68 27 2c 20 27 6b 73 68 27 2c 20 27 63 73 68 27 29 20 61 73 20 24 73 68 29 20 7b 0a 20 | 'zsh',.'ksh',.'csh').as.$sh).{.. |
60300 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 27 4f 4b 27 20 3d 3d 3d 20 72 74 72 69 | ...............if.('OK'.===.rtri |
60320 | 6d 28 73 68 65 6c 6c 5f 65 78 65 63 28 73 70 72 69 6e 74 66 28 24 74 65 73 74 2c 20 24 73 68 29 | m(shell_exec(sprintf($test,.$sh) |
60340 | 29 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 73 65 6c 66 3a 3a | ))).{.....................self:: |
60360 | 24 73 68 65 6c 6c 20 3d 20 24 73 68 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | $shell.=.$sh;................... |
60380 | 20 20 62 72 65 61 6b 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 | ..break;.................}...... |
603a0 | 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 | .......}.........}..........retu |
603c0 | 72 6e 20 73 65 6c 66 3a 3a 24 73 68 65 6c 6c 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a | rn.self::$shell;.....}....../**. |
603e0 | 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 77 68 65 74 68 65 72 20 53 74 74 79 20 69 73 20 61 | .....*.Returns.whether.Stty.is.a |
60400 | 76 61 69 6c 61 62 6c 65 20 6f 72 20 6e 6f 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 | vailable.or.not.......*......*.@ |
60420 | 72 65 74 75 72 6e 20 62 6f 6f 6c 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 | return.bool......*/.....private. |
60440 | 66 75 6e 63 74 69 6f 6e 20 68 61 73 53 74 74 79 41 76 61 69 6c 61 62 6c 65 28 29 0a 20 20 20 20 | function.hasSttyAvailable()..... |
60460 | 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 21 3d 3d 20 73 65 6c 66 3a 3a 24 73 74 | {.........if.(null.!==.self::$st |
60480 | 74 79 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 3a 3a 24 | ty).{.............return.self::$ |
604a0 | 73 74 74 79 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 65 78 65 63 28 27 73 | stty;.........}..........exec('s |
604c0 | 74 74 79 20 32 3e 26 31 27 2c 20 24 6f 75 74 70 75 74 2c 20 24 65 78 69 74 63 6f 64 65 29 3b 0a | tty.2>&1',.$output,.$exitcode);. |
604e0 | 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 3a 3a 24 73 74 74 79 20 3d 20 24 65 | .........return.self::$stty.=.$e |
60500 | 78 69 74 63 6f 64 65 20 3d 3d 3d 20 30 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a | xitcode.===.0;.....}.}.<?php../* |
60520 | 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d | ..*.This.file.is.part.of.the.Sym |
60540 | 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 | fony.package...*..*.(c).Fabien.P |
60560 | 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a | otencier.<fabien@symfony.com>..* |
60580 | 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c | ..*.For.the.full.copyright.and.l |
605a0 | 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 | icense.information,.please.view. |
605c0 | 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 | the.LICENSE..*.file.that.was.dis |
605e0 | 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a | tributed.with.this.source.code.. |
60600 | 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 | .*/..namespace.Symfony\Component |
60620 | 5c 43 6f 6e 73 6f 6c 65 5c 48 65 6c 70 65 72 3b 0a 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f | \Console\Helper;..use.Symfony\Co |
60640 | 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 43 6f 6d 6d 61 6e 64 5c 43 6f 6d 6d 61 6e 64 3b | mponent\Console\Command\Command; |
60660 | 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 | .use.Symfony\Component\Console\E |
60680 | 78 63 65 70 74 69 6f 6e 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f | xception\InvalidArgumentExceptio |
606a0 | 6e 3b 0a 0a 2f 2a 2a 0a 20 2a 20 48 65 6c 70 65 72 53 65 74 20 72 65 70 72 65 73 65 6e 74 73 20 | n;../**..*.HelperSet.represents. |
606c0 | 61 20 73 65 74 20 6f 66 20 68 65 6c 70 65 72 73 20 74 6f 20 62 65 20 75 73 65 64 20 77 69 74 68 | a.set.of.helpers.to.be.used.with |
606e0 | 20 61 20 63 6f 6d 6d 61 6e 64 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 46 61 62 69 65 6e | .a.command...*..*.@author.Fabien |
60700 | 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a | .Potencier.<fabien@symfony.com>. |
60720 | 20 2a 2f 0a 63 6c 61 73 73 20 48 65 6c 70 65 72 53 65 74 20 69 6d 70 6c 65 6d 65 6e 74 73 20 5c | .*/.class.HelperSet.implements.\ |
60740 | 49 74 65 72 61 74 6f 72 41 67 67 72 65 67 61 74 65 0a 7b 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 | IteratorAggregate.{...../**..... |
60760 | 20 2a 20 40 76 61 72 20 48 65 6c 70 65 72 5b 5d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 | .*.@var.Helper[]......*/.....pri |
60780 | 76 61 74 65 20 24 68 65 6c 70 65 72 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 70 72 69 | vate.$helpers.=.array();.....pri |
607a0 | 76 61 74 65 20 24 63 6f 6d 6d 61 6e 64 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 43 | vate.$command;....../**......*.C |
607c0 | 6f 6e 73 74 72 75 63 74 6f 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d | onstructor.......*......*.@param |
607e0 | 20 48 65 6c 70 65 72 5b 5d 20 24 68 65 6c 70 65 72 73 20 41 6e 20 61 72 72 61 79 20 6f 66 20 68 | .Helper[].$helpers.An.array.of.h |
60800 | 65 6c 70 65 72 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f | elper......*/.....public.functio |
60820 | 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 74 28 61 72 72 61 79 20 24 68 65 6c 70 65 72 73 20 3d 20 61 | n.__construct(array.$helpers.=.a |
60840 | 72 72 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 | rray()).....{.........foreach.($ |
60860 | 68 65 6c 70 65 72 73 20 61 73 20 24 61 6c 69 61 73 20 3d 3e 20 24 68 65 6c 70 65 72 29 20 7b 0a | helpers.as.$alias.=>.$helper).{. |
60880 | 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 65 74 28 24 68 65 6c 70 65 72 2c 20 | ............$this->set($helper,. |
608a0 | 69 73 5f 69 6e 74 28 24 61 6c 69 61 73 29 20 3f 20 6e 75 6c 6c 20 3a 20 24 61 6c 69 61 73 29 3b | is_int($alias).?.null.:.$alias); |
608c0 | 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a | .........}.....}....../**......* |
608e0 | 20 53 65 74 73 20 61 20 68 65 6c 70 65 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 | .Sets.a.helper.......*......*.@p |
60900 | 61 72 61 6d 20 48 65 6c 70 65 72 49 6e 74 65 72 66 61 63 65 20 24 68 65 6c 70 65 72 20 54 68 65 | aram.HelperInterface.$helper.The |
60920 | 20 68 65 6c 70 65 72 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 | .helper.instance......*.@param.s |
60940 | 74 72 69 6e 67 20 20 20 20 20 20 20 20 20 20 24 61 6c 69 61 73 20 20 41 6e 20 61 6c 69 61 73 0a | tring..........$alias..An.alias. |
60960 | 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 28 | .....*/.....public.function.set( |
60980 | 48 65 6c 70 65 72 49 6e 74 65 72 66 61 63 65 20 24 68 65 6c 70 65 72 2c 20 24 61 6c 69 61 73 20 | HelperInterface.$helper,.$alias. |
609a0 | 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 68 65 6c | =.null).....{.........$this->hel |
609c0 | 70 65 72 73 5b 24 68 65 6c 70 65 72 2d 3e 67 65 74 4e 61 6d 65 28 29 5d 20 3d 20 24 68 65 6c 70 | pers[$helper->getName()].=.$help |
609e0 | 65 72 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 21 3d 3d 20 24 61 6c 69 61 73 29 | er;.........if.(null.!==.$alias) |
60a00 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 68 65 6c 70 65 72 73 5b 24 61 | .{.............$this->helpers[$a |
60a20 | 6c 69 61 73 5d 20 3d 20 24 68 65 6c 70 65 72 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 | lias].=.$helper;.........}...... |
60a40 | 20 20 20 20 24 68 65 6c 70 65 72 2d 3e 73 65 74 48 65 6c 70 65 72 53 65 74 28 24 74 68 69 73 29 | ....$helper->setHelperSet($this) |
60a60 | 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 | ;.....}....../**......*.Returns. |
60a80 | 74 72 75 65 20 69 66 20 74 68 65 20 68 65 6c 70 65 72 20 69 66 20 64 65 66 69 6e 65 64 2e 0a 20 | true.if.the.helper.if.defined... |
60aa0 | 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6e 61 6d 65 | ....*......*.@param.string.$name |
60ac0 | 20 54 68 65 20 68 65 6c 70 65 72 20 6e 61 6d 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 | .The.helper.name......*......*.@ |
60ae0 | 72 65 74 75 72 6e 20 62 6f 6f 6c 20 74 72 75 65 20 69 66 20 74 68 65 20 68 65 6c 70 65 72 20 69 | return.bool.true.if.the.helper.i |
60b00 | 73 20 64 65 66 69 6e 65 64 2c 20 66 61 6c 73 65 20 6f 74 68 65 72 77 69 73 65 0a 20 20 20 20 20 | s.defined,.false.otherwise...... |
60b20 | 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 68 61 73 28 24 6e 61 6d 65 | */.....public.function.has($name |
60b40 | 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 69 73 73 65 74 28 24 74 68 | ).....{.........return.isset($th |
60b60 | 69 73 2d 3e 68 65 6c 70 65 72 73 5b 24 6e 61 6d 65 5d 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 | is->helpers[$name]);.....}...... |
60b80 | 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 61 20 68 65 6c 70 65 72 20 76 61 6c 75 65 2e 0a | /**......*.Gets.a.helper.value.. |
60ba0 | 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6e 61 6d | .....*......*.@param.string.$nam |
60bc0 | 65 20 54 68 65 20 68 65 6c 70 65 72 20 6e 61 6d 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 | e.The.helper.name......*......*. |
60be0 | 40 72 65 74 75 72 6e 20 48 65 6c 70 65 72 49 6e 74 65 72 66 61 63 65 20 54 68 65 20 68 65 6c 70 | @return.HelperInterface.The.help |
60c00 | 65 72 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 | er.instance......*......*.@throw |
60c20 | 73 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 20 69 66 20 74 68 | s.InvalidArgumentException.if.th |
60c40 | 65 20 68 65 6c 70 65 72 20 69 73 20 6e 6f 74 20 64 65 66 69 6e 65 64 0a 20 20 20 20 20 2a 2f 0a | e.helper.is.not.defined......*/. |
60c60 | 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 28 24 6e 61 6d 65 29 0a 20 | ....public.function.get($name).. |
60c80 | 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 24 74 68 69 73 2d 3e 68 61 73 28 24 6e 61 | ...{.........if.(!$this->has($na |
60ca0 | 6d 65 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 | me)).{.............throw.new.Inv |
60cc0 | 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 73 70 72 69 6e 74 66 28 27 54 | alidArgumentException(sprintf('T |
60ce0 | 68 65 20 68 65 6c 70 65 72 20 22 25 73 22 20 69 73 20 6e 6f 74 20 64 65 66 69 6e 65 64 2e 27 2c | he.helper."%s".is.not.defined.', |
60d00 | 20 24 6e 61 6d 65 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 | .$name));.........}..........ret |
60d20 | 75 72 6e 20 24 74 68 69 73 2d 3e 68 65 6c 70 65 72 73 5b 24 6e 61 6d 65 5d 3b 0a 20 20 20 20 7d | urn.$this->helpers[$name];.....} |
60d40 | 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 74 68 65 20 63 6f 6d 6d 61 6e | ....../**......*.Sets.the.comman |
60d60 | 64 20 61 73 73 6f 63 69 61 74 65 64 20 77 69 74 68 20 74 68 69 73 20 68 65 6c 70 65 72 20 73 65 | d.associated.with.this.helper.se |
60d80 | 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 43 6f 6d 6d 61 6e 64 20 | t.......*......*.@param.Command. |
60da0 | 24 63 6f 6d 6d 61 6e 64 20 41 20 43 6f 6d 6d 61 6e 64 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 | $command.A.Command.instance..... |
60dc0 | 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 43 6f 6d 6d 61 | .*/.....public.function.setComma |
60de0 | 6e 64 28 43 6f 6d 6d 61 6e 64 20 24 63 6f 6d 6d 61 6e 64 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 | nd(Command.$command.=.null)..... |
60e00 | 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 63 6f 6d 6d 61 6e 64 20 3d 20 24 63 6f 6d 6d | {.........$this->command.=.$comm |
60e20 | 61 6e 64 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 | and;.....}....../**......*.Gets. |
60e40 | 74 68 65 20 63 6f 6d 6d 61 6e 64 20 61 73 73 6f 63 69 61 74 65 64 20 77 69 74 68 20 74 68 69 73 | the.command.associated.with.this |
60e60 | 20 68 65 6c 70 65 72 20 73 65 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 | .helper.set.......*......*.@retu |
60e80 | 72 6e 20 43 6f 6d 6d 61 6e 64 20 41 20 43 6f 6d 6d 61 6e 64 20 69 6e 73 74 61 6e 63 65 0a 20 20 | rn.Command.A.Command.instance... |
60ea0 | 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 43 6f 6d | ...*/.....public.function.getCom |
60ec0 | 6d 61 6e 64 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 | mand().....{.........return.$thi |
60ee0 | 73 2d 3e 63 6f 6d 6d 61 6e 64 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 | s->command;.....}....../**...... |
60f00 | 2a 20 40 72 65 74 75 72 6e 20 48 65 6c 70 65 72 5b 5d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 | *.@return.Helper[]......*/.....p |
60f20 | 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 49 74 65 72 61 74 6f 72 28 29 0a 20 20 20 | ublic.function.getIterator().... |
60f40 | 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6e 65 77 20 5c 41 72 72 61 79 49 74 65 72 | .{.........return.new.\ArrayIter |
60f60 | 61 74 6f 72 28 24 74 68 69 73 2d 3e 68 65 6c 70 65 72 73 29 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f | ator($this->helpers);.....}.}.<? |
60f80 | 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 | php../*..*.This.file.is.part.of. |
60fa0 | 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 | the.Symfony.package...*..*.(c).F |
60fc0 | 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e | abien.Potencier.<fabien@symfony. |
60fe0 | 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 | com>..*..*.For.the.full.copyrigh |
61000 | 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 | t.and.license.information,.pleas |
61020 | 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 | e.view.the.LICENSE..*.file.that. |
61040 | 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 | was.distributed.with.this.source |
61060 | 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f | .code...*/..namespace.Symfony\Co |
61080 | 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 48 65 6c 70 65 72 3b 0a 0a 75 73 65 20 53 79 6d | mponent\Console\Helper;..use.Sym |
610a0 | 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 78 63 65 70 74 69 6f 6e | fony\Component\Console\Exception |
610c0 | 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 3b 0a 75 73 65 20 53 | \InvalidArgumentException;.use.S |
610e0 | 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 78 63 65 70 74 69 | ymfony\Component\Console\Excepti |
61100 | 6f 6e 5c 4c 6f 67 69 63 45 78 63 65 70 74 69 6f 6e 3b 0a 0a 2f 2a 2a 0a 20 2a 20 44 65 66 69 6e | on\LogicException;../**..*.Defin |
61120 | 65 73 20 74 68 65 20 73 74 79 6c 65 73 20 66 6f 72 20 61 20 54 61 62 6c 65 2e 0a 20 2a 0a 20 2a | es.the.styles.for.a.Table...*..* |
61140 | 20 40 61 75 74 68 6f 72 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 | .@author.Fabien.Potencier.<fabie |
61160 | 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 20 40 61 75 74 68 6f 72 20 d0 a1 d0 b0 d1 88 | n@symfony.com>..*.@author....... |
61180 | d0 b0 20 d0 a1 d1 82 d0 b0 d0 bc d0 b5 d0 bd d0 ba d0 be d0 b2 d0 b8 d1 9b 20 3c 75 6d 70 69 72 | ..........................<umpir |
611a0 | 73 6b 79 40 67 6d 61 69 6c 2e 63 6f 6d 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 54 61 62 6c 65 53 74 | sky@gmail.com>..*/.class.TableSt |
611c0 | 79 6c 65 0a 7b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 70 61 64 64 69 6e 67 43 68 61 72 20 3d | yle.{.....private.$paddingChar.= |
611e0 | 20 27 20 27 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 68 6f 72 69 7a 6f 6e 74 61 6c 42 6f 72 | .'.';.....private.$horizontalBor |
61200 | 64 65 72 43 68 61 72 20 3d 20 27 2d 27 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 76 65 72 74 | derChar.=.'-';.....private.$vert |
61220 | 69 63 61 6c 42 6f 72 64 65 72 43 68 61 72 20 3d 20 27 7c 27 3b 0a 20 20 20 20 70 72 69 76 61 74 | icalBorderChar.=.'|';.....privat |
61240 | 65 20 24 63 72 6f 73 73 69 6e 67 43 68 61 72 20 3d 20 27 2b 27 3b 0a 20 20 20 20 70 72 69 76 61 | e.$crossingChar.=.'+';.....priva |
61260 | 74 65 20 24 63 65 6c 6c 48 65 61 64 65 72 46 6f 72 6d 61 74 20 3d 20 27 3c 69 6e 66 6f 3e 25 73 | te.$cellHeaderFormat.=.'<info>%s |
61280 | 3c 2f 69 6e 66 6f 3e 27 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 63 65 6c 6c 52 6f 77 46 6f | </info>';.....private.$cellRowFo |
612a0 | 72 6d 61 74 20 3d 20 27 25 73 27 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 63 65 6c 6c 52 6f | rmat.=.'%s';.....private.$cellRo |
612c0 | 77 43 6f 6e 74 65 6e 74 46 6f 72 6d 61 74 20 3d 20 27 20 25 73 20 27 3b 0a 20 20 20 20 70 72 69 | wContentFormat.=.'.%s.';.....pri |
612e0 | 76 61 74 65 20 24 62 6f 72 64 65 72 46 6f 72 6d 61 74 20 3d 20 27 25 73 27 3b 0a 20 20 20 20 70 | vate.$borderFormat.=.'%s';.....p |
61300 | 72 69 76 61 74 65 20 24 70 61 64 54 79 70 65 20 3d 20 53 54 52 5f 50 41 44 5f 52 49 47 48 54 3b | rivate.$padType.=.STR_PAD_RIGHT; |
61320 | 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 70 61 64 64 69 6e 67 20 63 68 | ....../**......*.Sets.padding.ch |
61340 | 61 72 61 63 74 65 72 2c 20 75 73 65 64 20 66 6f 72 20 63 65 6c 6c 20 70 61 64 64 69 6e 67 2e 0a | aracter,.used.for.cell.padding.. |
61360 | 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 70 61 64 | .....*......*.@param.string.$pad |
61380 | 64 69 6e 67 43 68 61 72 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 54 | dingChar......*......*.@return.T |
613a0 | 61 62 6c 65 53 74 79 6c 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e | ableStyle......*/.....public.fun |
613c0 | 63 74 69 6f 6e 20 73 65 74 50 61 64 64 69 6e 67 43 68 61 72 28 24 70 61 64 64 69 6e 67 43 68 61 | ction.setPaddingChar($paddingCha |
613e0 | 72 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 24 70 61 64 64 69 6e 67 43 68 | r).....{.........if.(!$paddingCh |
61400 | 61 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 4c 6f 67 69 | ar).{.............throw.new.Logi |
61420 | 63 45 78 63 65 70 74 69 6f 6e 28 27 54 68 65 20 70 61 64 64 69 6e 67 20 63 68 61 72 20 6d 75 73 | cException('The.padding.char.mus |
61440 | 74 20 6e 6f 74 20 62 65 20 65 6d 70 74 79 27 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 | t.not.be.empty');.........}..... |
61460 | 20 20 20 20 20 24 74 68 69 73 2d 3e 70 61 64 64 69 6e 67 43 68 61 72 20 3d 20 24 70 61 64 64 69 | .....$this->paddingChar.=.$paddi |
61480 | 6e 67 43 68 61 72 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 3b 0a 20 | ngChar;..........return.$this;.. |
614a0 | 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 70 61 64 64 69 6e | ...}....../**......*.Gets.paddin |
614c0 | 67 20 63 68 61 72 61 63 74 65 72 2c 20 75 73 65 64 20 66 6f 72 20 63 65 6c 6c 20 70 61 64 64 69 | g.character,.used.for.cell.paddi |
614e0 | 6e 67 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 | ng.......*......*.@return.string |
61500 | 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 | ......*/.....public.function.get |
61520 | 50 61 64 64 69 6e 67 43 68 61 72 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 | PaddingChar().....{.........retu |
61540 | 72 6e 20 24 74 68 69 73 2d 3e 70 61 64 64 69 6e 67 43 68 61 72 3b 0a 20 20 20 20 7d 0a 0a 20 20 | rn.$this->paddingChar;.....}.... |
61560 | 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 68 6f 72 69 7a 6f 6e 74 61 6c 20 62 6f 72 | ../**......*.Sets.horizontal.bor |
61580 | 64 65 72 20 63 68 61 72 61 63 74 65 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 | der.character.......*......*.@pa |
615a0 | 72 61 6d 20 73 74 72 69 6e 67 20 24 68 6f 72 69 7a 6f 6e 74 61 6c 42 6f 72 64 65 72 43 68 61 72 | ram.string.$horizontalBorderChar |
615c0 | 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 54 61 62 6c 65 53 74 79 6c | ......*......*.@return.TableStyl |
615e0 | 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 | e......*/.....public.function.se |
61600 | 74 48 6f 72 69 7a 6f 6e 74 61 6c 42 6f 72 64 65 72 43 68 61 72 28 24 68 6f 72 69 7a 6f 6e 74 61 | tHorizontalBorderChar($horizonta |
61620 | 6c 42 6f 72 64 65 72 43 68 61 72 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 | lBorderChar).....{.........$this |
61640 | 2d 3e 68 6f 72 69 7a 6f 6e 74 61 6c 42 6f 72 64 65 72 43 68 61 72 20 3d 20 24 68 6f 72 69 7a 6f | ->horizontalBorderChar.=.$horizo |
61660 | 6e 74 61 6c 42 6f 72 64 65 72 43 68 61 72 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 | ntalBorderChar;..........return. |
61680 | 24 74 68 69 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 | $this;.....}....../**......*.Get |
616a0 | 73 20 68 6f 72 69 7a 6f 6e 74 61 6c 20 62 6f 72 64 65 72 20 63 68 61 72 61 63 74 65 72 2e 0a 20 | s.horizontal.border.character... |
616c0 | 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 0a 20 20 20 20 | ....*......*.@return.string..... |
616e0 | 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 48 6f 72 69 7a | .*/.....public.function.getHoriz |
61700 | 6f 6e 74 61 6c 42 6f 72 64 65 72 43 68 61 72 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | ontalBorderChar().....{......... |
61720 | 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 68 6f 72 69 7a 6f 6e 74 61 6c 42 6f 72 64 65 72 43 68 | return.$this->horizontalBorderCh |
61740 | 61 72 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 76 | ar;.....}....../**......*.Sets.v |
61760 | 65 72 74 69 63 61 6c 20 62 6f 72 64 65 72 20 63 68 61 72 61 63 74 65 72 2e 0a 20 20 20 20 20 2a | ertical.border.character.......* |
61780 | 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 76 65 72 74 69 63 61 6c 42 | ......*.@param.string.$verticalB |
617a0 | 6f 72 64 65 72 43 68 61 72 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 | orderChar......*......*.@return. |
617c0 | 54 61 62 6c 65 53 74 79 6c 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 | TableStyle......*/.....public.fu |
617e0 | 6e 63 74 69 6f 6e 20 73 65 74 56 65 72 74 69 63 61 6c 42 6f 72 64 65 72 43 68 61 72 28 24 76 65 | nction.setVerticalBorderChar($ve |
61800 | 72 74 69 63 61 6c 42 6f 72 64 65 72 43 68 61 72 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | rticalBorderChar).....{......... |
61820 | 24 74 68 69 73 2d 3e 76 65 72 74 69 63 61 6c 42 6f 72 64 65 72 43 68 61 72 20 3d 20 24 76 65 72 | $this->verticalBorderChar.=.$ver |
61840 | 74 69 63 61 6c 42 6f 72 64 65 72 43 68 61 72 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e | ticalBorderChar;..........return |
61860 | 20 24 74 68 69 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 | .$this;.....}....../**......*.Ge |
61880 | 74 73 20 76 65 72 74 69 63 61 6c 20 62 6f 72 64 65 72 20 63 68 61 72 61 63 74 65 72 2e 0a 20 20 | ts.vertical.border.character.... |
618a0 | 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 0a 20 20 20 20 20 | ...*......*.@return.string...... |
618c0 | 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 56 65 72 74 69 63 | */.....public.function.getVertic |
618e0 | 61 6c 42 6f 72 64 65 72 43 68 61 72 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 | alBorderChar().....{.........ret |
61900 | 75 72 6e 20 24 74 68 69 73 2d 3e 76 65 72 74 69 63 61 6c 42 6f 72 64 65 72 43 68 61 72 3b 0a 20 | urn.$this->verticalBorderChar;.. |
61920 | 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 63 72 6f 73 73 69 | ...}....../**......*.Sets.crossi |
61940 | 6e 67 20 63 68 61 72 61 63 74 65 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 | ng.character.......*......*.@par |
61960 | 61 6d 20 73 74 72 69 6e 67 20 24 63 72 6f 73 73 69 6e 67 43 68 61 72 0a 20 20 20 20 20 2a 0a 20 | am.string.$crossingChar......*.. |
61980 | 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 54 61 62 6c 65 53 74 79 6c 65 0a 20 20 20 20 20 2a 2f | ....*.@return.TableStyle......*/ |
619a0 | 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 43 72 6f 73 73 69 6e 67 | .....public.function.setCrossing |
619c0 | 43 68 61 72 28 24 63 72 6f 73 73 69 6e 67 43 68 61 72 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 | Char($crossingChar).....{....... |
619e0 | 20 20 24 74 68 69 73 2d 3e 63 72 6f 73 73 69 6e 67 43 68 61 72 20 3d 20 24 63 72 6f 73 73 69 6e | ..$this->crossingChar.=.$crossin |
61a00 | 67 43 68 61 72 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 3b 0a 20 20 | gChar;..........return.$this;... |
61a20 | 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 63 72 6f 73 73 69 6e | ..}....../**......*.Gets.crossin |
61a40 | 67 20 63 68 61 72 61 63 74 65 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 | g.character.......*......*.@retu |
61a60 | 72 6e 20 73 74 72 69 6e 67 20 24 63 72 6f 73 73 69 6e 67 43 68 61 72 0a 20 20 20 20 20 2a 2f 0a | rn.string.$crossingChar......*/. |
61a80 | 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 43 72 6f 73 73 69 6e 67 43 | ....public.function.getCrossingC |
61aa0 | 68 61 72 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 | har().....{.........return.$this |
61ac0 | 2d 3e 63 72 6f 73 73 69 6e 67 43 68 61 72 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 | ->crossingChar;.....}....../**.. |
61ae0 | 20 20 20 20 2a 20 53 65 74 73 20 68 65 61 64 65 72 20 63 65 6c 6c 20 66 6f 72 6d 61 74 2e 0a 20 | ....*.Sets.header.cell.format... |
61b00 | 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 63 65 6c 6c | ....*......*.@param.string.$cell |
61b20 | 48 65 61 64 65 72 46 6f 72 6d 61 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 | HeaderFormat......*......*.@retu |
61b40 | 72 6e 20 54 61 62 6c 65 53 74 79 6c 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 | rn.TableStyle......*/.....public |
61b60 | 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 43 65 6c 6c 48 65 61 64 65 72 46 6f 72 6d 61 74 28 24 63 | .function.setCellHeaderFormat($c |
61b80 | 65 6c 6c 48 65 61 64 65 72 46 6f 72 6d 61 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 | ellHeaderFormat).....{.........$ |
61ba0 | 74 68 69 73 2d 3e 63 65 6c 6c 48 65 61 64 65 72 46 6f 72 6d 61 74 20 3d 20 24 63 65 6c 6c 48 65 | this->cellHeaderFormat.=.$cellHe |
61bc0 | 61 64 65 72 46 6f 72 6d 61 74 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 | aderFormat;..........return.$thi |
61be0 | 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 68 65 | s;.....}....../**......*.Gets.he |
61c00 | 61 64 65 72 20 63 65 6c 6c 20 66 6f 72 6d 61 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 | ader.cell.format.......*......*. |
61c20 | 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 | @return.string......*/.....publi |
61c40 | 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 43 65 6c 6c 48 65 61 64 65 72 46 6f 72 6d 61 74 28 29 | c.function.getCellHeaderFormat() |
61c60 | 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 63 65 6c | .....{.........return.$this->cel |
61c80 | 6c 48 65 61 64 65 72 46 6f 72 6d 61 74 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 | lHeaderFormat;.....}....../**... |
61ca0 | 20 20 20 2a 20 53 65 74 73 20 72 6f 77 20 63 65 6c 6c 20 66 6f 72 6d 61 74 2e 0a 20 20 20 20 20 | ...*.Sets.row.cell.format....... |
61cc0 | 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 63 65 6c 6c 52 6f 77 46 | *......*.@param.string.$cellRowF |
61ce0 | 6f 72 6d 61 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 54 61 62 6c | ormat......*......*.@return.Tabl |
61d00 | 65 53 74 79 6c 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 | eStyle......*/.....public.functi |
61d20 | 6f 6e 20 73 65 74 43 65 6c 6c 52 6f 77 46 6f 72 6d 61 74 28 24 63 65 6c 6c 52 6f 77 46 6f 72 6d | on.setCellRowFormat($cellRowForm |
61d40 | 61 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 63 65 6c 6c 52 6f 77 | at).....{.........$this->cellRow |
61d60 | 46 6f 72 6d 61 74 20 3d 20 24 63 65 6c 6c 52 6f 77 46 6f 72 6d 61 74 3b 0a 0a 20 20 20 20 20 20 | Format.=.$cellRowFormat;........ |
61d80 | 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 | ..return.$this;.....}....../**.. |
61da0 | 20 20 20 20 2a 20 47 65 74 73 20 72 6f 77 20 63 65 6c 6c 20 66 6f 72 6d 61 74 2e 0a 20 20 20 20 | ....*.Gets.row.cell.format...... |
61dc0 | 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 0a 20 20 20 20 20 2a 2f | .*......*.@return.string......*/ |
61de0 | 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 43 65 6c 6c 52 6f 77 46 | .....public.function.getCellRowF |
61e00 | 6f 72 6d 61 74 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 | ormat().....{.........return.$th |
61e20 | 69 73 2d 3e 63 65 6c 6c 52 6f 77 46 6f 72 6d 61 74 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a | is->cellRowFormat;.....}....../* |
61e40 | 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 72 6f 77 20 63 65 6c 6c 20 63 6f 6e 74 65 6e 74 20 66 | *......*.Sets.row.cell.content.f |
61e60 | 6f 72 6d 61 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 | ormat.......*......*.@param.stri |
61e80 | 6e 67 20 24 63 65 6c 6c 52 6f 77 43 6f 6e 74 65 6e 74 46 6f 72 6d 61 74 0a 20 20 20 20 20 2a 0a | ng.$cellRowContentFormat......*. |
61ea0 | 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 54 61 62 6c 65 53 74 79 6c 65 0a 20 20 20 20 20 2a | .....*.@return.TableStyle......* |
61ec0 | 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 43 65 6c 6c 52 6f 77 | /.....public.function.setCellRow |
61ee0 | 43 6f 6e 74 65 6e 74 46 6f 72 6d 61 74 28 24 63 65 6c 6c 52 6f 77 43 6f 6e 74 65 6e 74 46 6f 72 | ContentFormat($cellRowContentFor |
61f00 | 6d 61 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 63 65 6c 6c 52 6f | mat).....{.........$this->cellRo |
61f20 | 77 43 6f 6e 74 65 6e 74 46 6f 72 6d 61 74 20 3d 20 24 63 65 6c 6c 52 6f 77 43 6f 6e 74 65 6e 74 | wContentFormat.=.$cellRowContent |
61f40 | 46 6f 72 6d 61 74 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 3b 0a 20 | Format;..........return.$this;.. |
61f60 | 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 72 6f 77 20 63 65 | ...}....../**......*.Gets.row.ce |
61f80 | 6c 6c 20 63 6f 6e 74 65 6e 74 20 66 6f 72 6d 61 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a | ll.content.format.......*......* |
61fa0 | 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c | .@return.string......*/.....publ |
61fc0 | 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 43 65 6c 6c 52 6f 77 43 6f 6e 74 65 6e 74 46 6f 72 | ic.function.getCellRowContentFor |
61fe0 | 6d 61 74 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 | mat().....{.........return.$this |
62000 | 2d 3e 63 65 6c 6c 52 6f 77 43 6f 6e 74 65 6e 74 46 6f 72 6d 61 74 3b 0a 20 20 20 20 7d 0a 0a 20 | ->cellRowContentFormat;.....}... |
62020 | 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 74 61 62 6c 65 20 62 6f 72 64 65 72 20 | .../**......*.Sets.table.border. |
62040 | 66 6f 72 6d 61 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 | format.......*......*.@param.str |
62060 | 69 6e 67 20 24 62 6f 72 64 65 72 46 6f 72 6d 61 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 | ing.$borderFormat......*......*. |
62080 | 40 72 65 74 75 72 6e 20 54 61 62 6c 65 53 74 79 6c 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 | @return.TableStyle......*/.....p |
620a0 | 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 42 6f 72 64 65 72 46 6f 72 6d 61 74 28 24 | ublic.function.setBorderFormat($ |
620c0 | 62 6f 72 64 65 72 46 6f 72 6d 61 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 | borderFormat).....{.........$thi |
620e0 | 73 2d 3e 62 6f 72 64 65 72 46 6f 72 6d 61 74 20 3d 20 24 62 6f 72 64 65 72 46 6f 72 6d 61 74 3b | s->borderFormat.=.$borderFormat; |
62100 | 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 3b 0a 20 20 20 20 7d 0a 0a 20 | ..........return.$this;.....}... |
62120 | 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 61 62 6c 65 20 62 6f 72 64 65 72 20 | .../**......*.Gets.table.border. |
62140 | 66 6f 72 6d 61 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 | format.......*......*.@return.st |
62160 | 72 69 6e 67 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e | ring......*/.....public.function |
62180 | 20 67 65 74 42 6f 72 64 65 72 46 6f 72 6d 61 74 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 | .getBorderFormat().....{........ |
621a0 | 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 62 6f 72 64 65 72 46 6f 72 6d 61 74 3b 0a 20 20 20 | .return.$this->borderFormat;.... |
621c0 | 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 63 65 6c 6c 20 70 61 64 | .}....../**......*.Sets.cell.pad |
621e0 | 64 69 6e 67 20 74 79 70 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 | ding.type.......*......*.@param. |
62200 | 69 6e 74 20 24 70 61 64 54 79 70 65 20 53 54 52 5f 50 41 44 5f 2a 0a 20 20 20 20 20 2a 0a 20 20 | int.$padType.STR_PAD_*......*... |
62220 | 20 20 20 2a 20 40 72 65 74 75 72 6e 20 54 61 62 6c 65 53 74 79 6c 65 0a 20 20 20 20 20 2a 2f 0a | ...*.@return.TableStyle......*/. |
62240 | 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 50 61 64 54 79 70 65 28 24 | ....public.function.setPadType($ |
62260 | 70 61 64 54 79 70 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 69 6e 5f 61 | padType).....{.........if.(!in_a |
62280 | 72 72 61 79 28 24 70 61 64 54 79 70 65 2c 20 61 72 72 61 79 28 53 54 52 5f 50 41 44 5f 4c 45 46 | rray($padType,.array(STR_PAD_LEF |
622a0 | 54 2c 20 53 54 52 5f 50 41 44 5f 52 49 47 48 54 2c 20 53 54 52 5f 50 41 44 5f 42 4f 54 48 29 2c | T,.STR_PAD_RIGHT,.STR_PAD_BOTH), |
622c0 | 20 74 72 75 65 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 | .true)).{.............throw.new. |
622e0 | 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 27 49 6e 76 61 6c 69 | InvalidArgumentException('Invali |
62300 | 64 20 70 61 64 64 69 6e 67 20 74 79 70 65 2e 20 45 78 70 65 63 74 65 64 20 6f 6e 65 20 6f 66 20 | d.padding.type..Expected.one.of. |
62320 | 28 53 54 52 5f 50 41 44 5f 4c 45 46 54 2c 20 53 54 52 5f 50 41 44 5f 52 49 47 48 54 2c 20 53 54 | (STR_PAD_LEFT,.STR_PAD_RIGHT,.ST |
62340 | 52 5f 50 41 44 5f 42 4f 54 48 29 2e 27 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 | R_PAD_BOTH).');.........}....... |
62360 | 20 20 20 24 74 68 69 73 2d 3e 70 61 64 54 79 70 65 20 3d 20 24 70 61 64 54 79 70 65 3b 0a 0a 20 | ...$this->padType.=.$padType;... |
62380 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 | .......return.$this;.....}...... |
623a0 | 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 63 65 6c 6c 20 70 61 64 64 69 6e 67 20 74 79 70 | /**......*.Gets.cell.padding.typ |
623c0 | 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 69 6e 74 0a 20 20 20 | e.......*......*.@return.int.... |
623e0 | 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 50 61 64 54 | ..*/.....public.function.getPadT |
62400 | 79 70 65 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 | ype().....{.........return.$this |
62420 | 2d 3e 70 61 64 54 79 70 65 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 | ->padType;.....}.}.<?php../*..*. |
62440 | 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 | This.file.is.part.of.the.Symfony |
62460 | 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e | .package...*..*.(c).Fabien.Poten |
62480 | 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 | cier.<fabien@symfony.com>..*..*. |
624a0 | 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e | For.the.full.copyright.and.licen |
624c0 | 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 | se.information,.please.view.the. |
624e0 | 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 | LICENSE..*.file.that.was.distrib |
62500 | 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a | uted.with.this.source.code...*/. |
62520 | 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e | .namespace.Symfony\Component\Con |
62540 | 73 6f 6c 65 5c 48 65 6c 70 65 72 3b 0a 0a 2f 2a 2a 0a 20 2a 20 48 65 6c 70 73 20 6f 75 74 70 75 | sole\Helper;../**..*.Helps.outpu |
62560 | 74 74 69 6e 67 20 64 65 62 75 67 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 20 77 68 65 6e 20 72 75 6e | tting.debug.information.when.run |
62580 | 6e 69 6e 67 20 61 6e 20 65 78 74 65 72 6e 61 6c 20 70 72 6f 67 72 61 6d 20 66 72 6f 6d 20 61 20 | ning.an.external.program.from.a. |
625a0 | 63 6f 6d 6d 61 6e 64 2e 0a 20 2a 0a 20 2a 20 41 6e 20 65 78 74 65 72 6e 61 6c 20 70 72 6f 67 72 | command...*..*.An.external.progr |
625c0 | 61 6d 20 63 61 6e 20 62 65 20 61 20 50 72 6f 63 65 73 73 2c 20 61 6e 20 48 54 54 50 20 72 65 71 | am.can.be.a.Process,.an.HTTP.req |
625e0 | 75 65 73 74 2c 20 6f 72 20 61 6e 79 74 68 69 6e 67 20 65 6c 73 65 2e 0a 20 2a 0a 20 2a 20 40 61 | uest,.or.anything.else...*..*.@a |
62600 | 75 74 68 6f 72 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 | uthor.Fabien.Potencier.<fabien@s |
62620 | 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 44 65 62 75 67 46 6f 72 6d 61 | ymfony.com>..*/.class.DebugForma |
62640 | 74 74 65 72 48 65 6c 70 65 72 20 65 78 74 65 6e 64 73 20 48 65 6c 70 65 72 0a 7b 0a 20 20 20 20 | tterHelper.extends.Helper.{..... |
62660 | 70 72 69 76 61 74 65 20 24 63 6f 6c 6f 72 73 20 3d 20 61 72 72 61 79 28 27 62 6c 61 63 6b 27 2c | private.$colors.=.array('black', |
62680 | 20 27 72 65 64 27 2c 20 27 67 72 65 65 6e 27 2c 20 27 79 65 6c 6c 6f 77 27 2c 20 27 62 6c 75 65 | .'red',.'green',.'yellow',.'blue |
626a0 | 27 2c 20 27 6d 61 67 65 6e 74 61 27 2c 20 27 63 79 61 6e 27 2c 20 27 77 68 69 74 65 27 2c 20 27 | ',.'magenta',.'cyan',.'white',.' |
626c0 | 64 65 66 61 75 6c 74 27 29 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 73 74 61 72 74 65 64 20 | default');.....private.$started. |
626e0 | 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 63 6f 75 6e 74 20 3d 20 | =.array();.....private.$count.=. |
62700 | 2d 31 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 74 61 72 74 73 20 61 20 64 65 62 | -1;....../**......*.Starts.a.deb |
62720 | 75 67 20 66 6f 72 6d 61 74 74 69 6e 67 20 73 65 73 73 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 | ug.formatting.session.......*... |
62740 | 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 69 64 20 20 20 20 20 20 54 68 65 20 | ...*.@param.string.$id......The. |
62760 | 69 64 20 6f 66 20 74 68 65 20 66 6f 72 6d 61 74 74 69 6e 67 20 73 65 73 73 69 6f 6e 0a 20 20 20 | id.of.the.formatting.session.... |
62780 | 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6d 65 73 73 61 67 65 20 54 68 65 20 6d | ..*.@param.string.$message.The.m |
627a0 | 65 73 73 61 67 65 20 74 6f 20 64 69 73 70 6c 61 79 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 | essage.to.display......*.@param. |
627c0 | 73 74 72 69 6e 67 20 24 70 72 65 66 69 78 20 20 54 68 65 20 70 72 65 66 69 78 20 74 6f 20 75 73 | string.$prefix..The.prefix.to.us |
627e0 | 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 0a 20 | e......*......*.@return.string.. |
62800 | 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 74 61 72 74 | ....*/.....public.function.start |
62820 | 28 24 69 64 2c 20 24 6d 65 73 73 61 67 65 2c 20 24 70 72 65 66 69 78 20 3d 20 27 52 55 4e 27 29 | ($id,.$message,.$prefix.=.'RUN') |
62840 | 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 74 61 72 74 65 64 5b 24 69 | .....{.........$this->started[$i |
62860 | 64 5d 20 3d 20 61 72 72 61 79 28 27 62 6f 72 64 65 72 27 20 3d 3e 20 2b 2b 24 74 68 69 73 2d 3e | d].=.array('border'.=>.++$this-> |
62880 | 63 6f 75 6e 74 20 25 20 63 6f 75 6e 74 28 24 74 68 69 73 2d 3e 63 6f 6c 6f 72 73 29 29 3b 0a 0a | count.%.count($this->colors));.. |
628a0 | 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 70 72 69 6e 74 66 28 22 25 73 3c 62 67 3d 62 6c | ........return.sprintf("%s<bg=bl |
628c0 | 75 65 3b 66 67 3d 77 68 69 74 65 3e 20 25 73 20 3c 2f 3e 20 3c 66 67 3d 62 6c 75 65 3e 25 73 3c | ue;fg=white>.%s.</>.<fg=blue>%s< |
628e0 | 2f 3e 5c 6e 22 2c 20 24 74 68 69 73 2d 3e 67 65 74 42 6f 72 64 65 72 28 24 69 64 29 2c 20 24 70 | />\n",.$this->getBorder($id),.$p |
62900 | 72 65 66 69 78 2c 20 24 6d 65 73 73 61 67 65 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a | refix,.$message);.....}....../** |
62920 | 0a 20 20 20 20 20 2a 20 41 64 64 73 20 70 72 6f 67 72 65 73 73 20 74 6f 20 61 20 66 6f 72 6d 61 | ......*.Adds.progress.to.a.forma |
62940 | 74 74 69 6e 67 20 73 65 73 73 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 | tting.session.......*......*.@pa |
62960 | 72 61 6d 20 73 74 72 69 6e 67 20 24 69 64 20 20 20 20 20 20 20 20 20 20 54 68 65 20 69 64 20 6f | ram.string.$id..........The.id.o |
62980 | 66 20 74 68 65 20 66 6f 72 6d 61 74 74 69 6e 67 20 73 65 73 73 69 6f 6e 0a 20 20 20 20 20 2a 20 | f.the.formatting.session......*. |
629a0 | 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 62 75 66 66 65 72 20 20 20 20 20 20 54 68 65 20 6d | @param.string.$buffer......The.m |
629c0 | 65 73 73 61 67 65 20 74 6f 20 64 69 73 70 6c 61 79 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 | essage.to.display......*.@param. |
629e0 | 62 6f 6f 6c 20 20 20 24 65 72 72 6f 72 20 20 20 20 20 20 20 57 68 65 74 68 65 72 20 74 6f 20 63 | bool...$error.......Whether.to.c |
62a00 | 6f 6e 73 69 64 65 72 20 74 68 65 20 62 75 66 66 65 72 20 61 73 20 65 72 72 6f 72 0a 20 20 20 20 | onsider.the.buffer.as.error..... |
62a20 | 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 70 72 65 66 69 78 20 20 20 20 20 20 54 68 | .*.@param.string.$prefix......Th |
62a40 | 65 20 70 72 65 66 69 78 20 66 6f 72 20 6f 75 74 70 75 74 0a 20 20 20 20 20 2a 20 40 70 61 72 61 | e.prefix.for.output......*.@para |
62a60 | 6d 20 73 74 72 69 6e 67 20 24 65 72 72 6f 72 50 72 65 66 69 78 20 54 68 65 20 70 72 65 66 69 78 | m.string.$errorPrefix.The.prefix |
62a80 | 20 66 6f 72 20 65 72 72 6f 72 20 6f 75 74 70 75 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 | .for.error.output......*......*. |
62aa0 | 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 | @return.string......*/.....publi |
62ac0 | 63 20 66 75 6e 63 74 69 6f 6e 20 70 72 6f 67 72 65 73 73 28 24 69 64 2c 20 24 62 75 66 66 65 72 | c.function.progress($id,.$buffer |
62ae0 | 2c 20 24 65 72 72 6f 72 20 3d 20 66 61 6c 73 65 2c 20 24 70 72 65 66 69 78 20 3d 20 27 4f 55 54 | ,.$error.=.false,.$prefix.=.'OUT |
62b00 | 27 2c 20 24 65 72 72 6f 72 50 72 65 66 69 78 20 3d 20 27 45 52 52 27 29 0a 20 20 20 20 7b 0a 20 | ',.$errorPrefix.=.'ERR').....{.. |
62b20 | 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 20 3d 20 27 27 3b 0a 0a 20 20 20 20 20 20 20 20 69 | .......$message.=.'';..........i |
62b40 | 66 20 28 24 65 72 72 6f 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 69 73 73 | f.($error).{.............if.(iss |
62b60 | 65 74 28 24 74 68 69 73 2d 3e 73 74 61 72 74 65 64 5b 24 69 64 5d 5b 27 6f 75 74 27 5d 29 29 20 | et($this->started[$id]['out'])). |
62b80 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 20 2e 3d 20 22 5c | {.................$message..=."\ |
62ba0 | 6e 22 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 75 6e 73 65 74 28 24 74 68 69 73 2d | n";.................unset($this- |
62bc0 | 3e 73 74 61 72 74 65 64 5b 24 69 64 5d 5b 27 6f 75 74 27 5d 29 3b 0a 20 20 20 20 20 20 20 20 20 | >started[$id]['out']);.......... |
62be0 | 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 21 69 73 73 65 74 28 24 74 68 69 | ...}.............if.(!isset($thi |
62c00 | 73 2d 3e 73 74 61 72 74 65 64 5b 24 69 64 5d 5b 27 65 72 72 27 5d 29 29 20 7b 0a 20 20 20 20 20 | s->started[$id]['err'])).{...... |
62c20 | 20 20 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 20 2e 3d 20 73 70 72 69 6e 74 66 28 27 | ...........$message..=.sprintf(' |
62c40 | 25 73 3c 62 67 3d 72 65 64 3b 66 67 3d 77 68 69 74 65 3e 20 25 73 20 3c 2f 3e 20 27 2c 20 24 74 | %s<bg=red;fg=white>.%s.</>.',.$t |
62c60 | 68 69 73 2d 3e 67 65 74 42 6f 72 64 65 72 28 24 69 64 29 2c 20 24 65 72 72 6f 72 50 72 65 66 69 | his->getBorder($id),.$errorPrefi |
62c80 | 78 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 74 61 72 74 | x);.................$this->start |
62ca0 | 65 64 5b 24 69 64 5d 5b 27 65 72 72 27 5d 20 3d 20 74 72 75 65 3b 0a 20 20 20 20 20 20 20 20 20 | ed[$id]['err'].=.true;.......... |
62cc0 | 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 20 2e 3d 20 73 74 | ...}..............$message..=.st |
62ce0 | 72 5f 72 65 70 6c 61 63 65 28 22 5c 6e 22 2c 20 73 70 72 69 6e 74 66 28 22 5c 6e 25 73 3c 62 67 | r_replace("\n",.sprintf("\n%s<bg |
62d00 | 3d 72 65 64 3b 66 67 3d 77 68 69 74 65 3e 20 25 73 20 3c 2f 3e 20 22 2c 20 24 74 68 69 73 2d 3e | =red;fg=white>.%s.</>.",.$this-> |
62d20 | 67 65 74 42 6f 72 64 65 72 28 24 69 64 29 2c 20 24 65 72 72 6f 72 50 72 65 66 69 78 29 2c 20 24 | getBorder($id),.$errorPrefix),.$ |
62d40 | 62 75 66 66 65 72 29 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 | buffer);.........}.else.{....... |
62d60 | 20 20 20 20 20 20 69 66 20 28 69 73 73 65 74 28 24 74 68 69 73 2d 3e 73 74 61 72 74 65 64 5b 24 | ......if.(isset($this->started[$ |
62d80 | 69 64 5d 5b 27 65 72 72 27 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 | id]['err'])).{.................$ |
62da0 | 6d 65 73 73 61 67 65 20 2e 3d 20 22 5c 6e 22 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | message..=."\n";................ |
62dc0 | 20 75 6e 73 65 74 28 24 74 68 69 73 2d 3e 73 74 61 72 74 65 64 5b 24 69 64 5d 5b 27 65 72 72 27 | .unset($this->started[$id]['err' |
62de0 | 5d 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 | ]);.............}.............if |
62e00 | 20 28 21 69 73 73 65 74 28 24 74 68 69 73 2d 3e 73 74 61 72 74 65 64 5b 24 69 64 5d 5b 27 6f 75 | .(!isset($this->started[$id]['ou |
62e20 | 74 27 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 | t'])).{.................$message |
62e40 | 20 2e 3d 20 73 70 72 69 6e 74 66 28 27 25 73 3c 62 67 3d 67 72 65 65 6e 3b 66 67 3d 77 68 69 74 | ..=.sprintf('%s<bg=green;fg=whit |
62e60 | 65 3e 20 25 73 20 3c 2f 3e 20 27 2c 20 24 74 68 69 73 2d 3e 67 65 74 42 6f 72 64 65 72 28 24 69 | e>.%s.</>.',.$this->getBorder($i |
62e80 | 64 29 2c 20 24 70 72 65 66 69 78 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 | d),.$prefix);.................$t |
62ea0 | 68 69 73 2d 3e 73 74 61 72 74 65 64 5b 24 69 64 5d 5b 27 6f 75 74 27 5d 20 3d 20 74 72 75 65 3b | his->started[$id]['out'].=.true; |
62ec0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 65 73 | .............}..............$mes |
62ee0 | 73 61 67 65 20 2e 3d 20 73 74 72 5f 72 65 70 6c 61 63 65 28 22 5c 6e 22 2c 20 73 70 72 69 6e 74 | sage..=.str_replace("\n",.sprint |
62f00 | 66 28 22 5c 6e 25 73 3c 62 67 3d 67 72 65 65 6e 3b 66 67 3d 77 68 69 74 65 3e 20 25 73 20 3c 2f | f("\n%s<bg=green;fg=white>.%s.</ |
62f20 | 3e 20 22 2c 20 24 74 68 69 73 2d 3e 67 65 74 42 6f 72 64 65 72 28 24 69 64 29 2c 20 24 70 72 65 | >.",.$this->getBorder($id),.$pre |
62f40 | 66 69 78 29 2c 20 24 62 75 66 66 65 72 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 | fix),.$buffer);.........}....... |
62f60 | 20 20 20 72 65 74 75 72 6e 20 24 6d 65 73 73 61 67 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f | ...return.$message;.....}....../ |
62f80 | 2a 2a 0a 20 20 20 20 20 2a 20 53 74 6f 70 73 20 61 20 66 6f 72 6d 61 74 74 69 6e 67 20 73 65 73 | **......*.Stops.a.formatting.ses |
62fa0 | 73 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e | sion.......*......*.@param.strin |
62fc0 | 67 20 24 69 64 20 20 20 20 20 20 20 20 20 54 68 65 20 69 64 20 6f 66 20 74 68 65 20 66 6f 72 6d | g.$id.........The.id.of.the.form |
62fe0 | 61 74 74 69 6e 67 20 73 65 73 73 69 6f 6e 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 | atting.session......*.@param.str |
63000 | 69 6e 67 20 24 6d 65 73 73 61 67 65 20 20 20 20 54 68 65 20 6d 65 73 73 61 67 65 20 74 6f 20 64 | ing.$message....The.message.to.d |
63020 | 69 73 70 6c 61 79 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 62 6f 6f 6c 20 20 20 24 73 75 63 | isplay......*.@param.bool...$suc |
63040 | 63 65 73 73 66 75 6c 20 57 68 65 74 68 65 72 20 74 6f 20 63 6f 6e 73 69 64 65 72 20 74 68 65 20 | cessful.Whether.to.consider.the. |
63060 | 72 65 73 75 6c 74 20 61 73 20 73 75 63 63 65 73 73 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 | result.as.success......*.@param. |
63080 | 73 74 72 69 6e 67 20 24 70 72 65 66 69 78 20 20 20 20 20 54 68 65 20 70 72 65 66 69 78 20 66 6f | string.$prefix.....The.prefix.fo |
630a0 | 72 20 74 68 65 20 65 6e 64 20 6f 75 74 70 75 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 | r.the.end.output......*......*.@ |
630c0 | 72 65 74 75 72 6e 20 73 74 72 69 6e 67 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 | return.string......*/.....public |
630e0 | 20 66 75 6e 63 74 69 6f 6e 20 73 74 6f 70 28 24 69 64 2c 20 24 6d 65 73 73 61 67 65 2c 20 24 73 | .function.stop($id,.$message,.$s |
63100 | 75 63 63 65 73 73 66 75 6c 2c 20 24 70 72 65 66 69 78 20 3d 20 27 52 45 53 27 29 0a 20 20 20 20 | uccessful,.$prefix.=.'RES')..... |
63120 | 7b 0a 20 20 20 20 20 20 20 20 24 74 72 61 69 6c 69 6e 67 45 4f 4c 20 3d 20 69 73 73 65 74 28 24 | {.........$trailingEOL.=.isset($ |
63140 | 74 68 69 73 2d 3e 73 74 61 72 74 65 64 5b 24 69 64 5d 5b 27 6f 75 74 27 5d 29 20 7c 7c 20 69 73 | this->started[$id]['out']).||.is |
63160 | 73 65 74 28 24 74 68 69 73 2d 3e 73 74 61 72 74 65 64 5b 24 69 64 5d 5b 27 65 72 72 27 5d 29 20 | set($this->started[$id]['err']). |
63180 | 3f 20 22 5c 6e 22 20 3a 20 27 27 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 73 75 63 63 65 | ?."\n".:.'';..........if.($succe |
631a0 | 73 73 66 75 6c 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 70 72 69 | ssful).{.............return.spri |
631c0 | 6e 74 66 28 22 25 73 25 73 3c 62 67 3d 67 72 65 65 6e 3b 66 67 3d 77 68 69 74 65 3e 20 25 73 20 | ntf("%s%s<bg=green;fg=white>.%s. |
631e0 | 3c 2f 3e 20 3c 66 67 3d 67 72 65 65 6e 3e 25 73 3c 2f 3e 5c 6e 22 2c 20 24 74 72 61 69 6c 69 6e | </>.<fg=green>%s</>\n",.$trailin |
63200 | 67 45 4f 4c 2c 20 24 74 68 69 73 2d 3e 67 65 74 42 6f 72 64 65 72 28 24 69 64 29 2c 20 24 70 72 | gEOL,.$this->getBorder($id),.$pr |
63220 | 65 66 69 78 2c 20 24 6d 65 73 73 61 67 65 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 | efix,.$message);.........}...... |
63240 | 20 20 20 20 24 6d 65 73 73 61 67 65 20 3d 20 73 70 72 69 6e 74 66 28 22 25 73 25 73 3c 62 67 3d | ....$message.=.sprintf("%s%s<bg= |
63260 | 72 65 64 3b 66 67 3d 77 68 69 74 65 3e 20 25 73 20 3c 2f 3e 20 3c 66 67 3d 72 65 64 3e 25 73 3c | red;fg=white>.%s.</>.<fg=red>%s< |
63280 | 2f 3e 5c 6e 22 2c 20 24 74 72 61 69 6c 69 6e 67 45 4f 4c 2c 20 24 74 68 69 73 2d 3e 67 65 74 42 | />\n",.$trailingEOL,.$this->getB |
632a0 | 6f 72 64 65 72 28 24 69 64 29 2c 20 24 70 72 65 66 69 78 2c 20 24 6d 65 73 73 61 67 65 29 3b 0a | order($id),.$prefix,.$message);. |
632c0 | 0a 20 20 20 20 20 20 20 20 75 6e 73 65 74 28 24 74 68 69 73 2d 3e 73 74 61 72 74 65 64 5b 24 69 | .........unset($this->started[$i |
632e0 | 64 5d 5b 27 6f 75 74 27 5d 2c 20 24 74 68 69 73 2d 3e 73 74 61 72 74 65 64 5b 24 69 64 5d 5b 27 | d]['out'],.$this->started[$id][' |
63300 | 65 72 72 27 5d 29 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 6d 65 73 73 61 67 65 | err']);..........return.$message |
63320 | 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 | ;.....}....../**......*.@param.s |
63340 | 74 72 69 6e 67 20 24 69 64 20 54 68 65 20 69 64 20 6f 66 20 74 68 65 20 66 6f 72 6d 61 74 74 69 | tring.$id.The.id.of.the.formatti |
63360 | 6e 67 20 73 65 73 73 69 6f 6e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e | ng.session......*......*.@return |
63380 | 20 73 74 72 69 6e 67 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 | .string......*/.....private.func |
633a0 | 74 69 6f 6e 20 67 65 74 42 6f 72 64 65 72 28 24 69 64 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 | tion.getBorder($id).....{....... |
633c0 | 20 20 72 65 74 75 72 6e 20 73 70 72 69 6e 74 66 28 27 3c 62 67 3d 25 73 3e 20 3c 2f 3e 27 2c 20 | ..return.sprintf('<bg=%s>.</>',. |
633e0 | 24 74 68 69 73 2d 3e 63 6f 6c 6f 72 73 5b 24 74 68 69 73 2d 3e 73 74 61 72 74 65 64 5b 24 69 64 | $this->colors[$this->started[$id |
63400 | 5d 5b 27 62 6f 72 64 65 72 27 5d 5d 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 | ]['border']]);.....}....../**... |
63420 | 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 | ...*.{@inheritdoc}......*/.....p |
63440 | 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 4e 61 6d 65 28 29 0a 20 20 20 20 7b 0a 20 | ublic.function.getName().....{.. |
63460 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 27 64 65 62 75 67 5f 66 6f 72 6d 61 74 74 65 72 27 3b | .......return.'debug_formatter'; |
63480 | 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 | .....}.}.<?php../*..*.This.file. |
634a0 | 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a | is.part.of.the.Symfony.package.. |
634c0 | 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 | .*..*.(c).Fabien.Potencier.<fabi |
634e0 | 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 | en@symfony.com>..*..*.For.the.fu |
63500 | 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 | ll.copyright.and.license.informa |
63520 | 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a | tion,.please.view.the.LICENSE..* |
63540 | 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 | .file.that.was.distributed.with. |
63560 | 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 | this.source.code...*/..namespace |
63580 | 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 48 65 6c 70 65 | .Symfony\Component\Console\Helpe |
635a0 | 72 3b 0a 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c | r;..use.Symfony\Component\Consol |
635c0 | 65 5c 4f 75 74 70 75 74 5c 43 6f 6e 73 6f 6c 65 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 3b | e\Output\ConsoleOutputInterface; |
635e0 | 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 4f | .use.Symfony\Component\Console\O |
63600 | 75 74 70 75 74 5c 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 3b 0a 75 73 65 20 53 79 6d 66 6f | utput\OutputInterface;.use.Symfo |
63620 | 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 50 72 6f 63 65 73 73 5c 45 78 63 65 70 74 69 6f 6e 5c 50 | ny\Component\Process\Exception\P |
63640 | 72 6f 63 65 73 73 46 61 69 6c 65 64 45 78 63 65 70 74 69 6f 6e 3b 0a 75 73 65 20 53 79 6d 66 6f | rocessFailedException;.use.Symfo |
63660 | 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 50 72 6f 63 65 73 73 5c 50 72 6f 63 65 73 73 3b 0a 75 73 | ny\Component\Process\Process;.us |
63680 | 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 50 72 6f 63 65 73 73 5c 50 72 6f 63 | e.Symfony\Component\Process\Proc |
636a0 | 65 73 73 42 75 69 6c 64 65 72 3b 0a 0a 2f 2a 2a 0a 20 2a 20 54 68 65 20 50 72 6f 63 65 73 73 48 | essBuilder;../**..*.The.ProcessH |
636c0 | 65 6c 70 65 72 20 63 6c 61 73 73 20 70 72 6f 76 69 64 65 73 20 68 65 6c 70 65 72 73 20 74 6f 20 | elper.class.provides.helpers.to. |
636e0 | 72 75 6e 20 65 78 74 65 72 6e 61 6c 20 70 72 6f 63 65 73 73 65 73 2e 0a 20 2a 0a 20 2a 20 40 61 | run.external.processes...*..*.@a |
63700 | 75 74 68 6f 72 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 | uthor.Fabien.Potencier.<fabien@s |
63720 | 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 50 72 6f 63 65 73 73 48 65 6c | ymfony.com>..*/.class.ProcessHel |
63740 | 70 65 72 20 65 78 74 65 6e 64 73 20 48 65 6c 70 65 72 0a 7b 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 | per.extends.Helper.{...../**.... |
63760 | 20 20 2a 20 52 75 6e 73 20 61 6e 20 65 78 74 65 72 6e 61 6c 20 70 72 6f 63 65 73 73 2e 0a 20 20 | ..*.Runs.an.external.process.... |
63780 | 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 | ...*......*.@param.OutputInterfa |
637a0 | 63 65 20 20 20 20 20 20 24 6f 75 74 70 75 74 20 20 20 20 41 6e 20 4f 75 74 70 75 74 49 6e 74 65 | ce......$output....An.OutputInte |
637c0 | 72 66 61 63 65 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 | rface.instance......*.@param.str |
637e0 | 69 6e 67 7c 61 72 72 61 79 7c 50 72 6f 63 65 73 73 20 24 63 6d 64 20 20 20 20 20 20 20 41 6e 20 | ing|array|Process.$cmd.......An. |
63800 | 69 6e 73 74 61 6e 63 65 20 6f 66 20 50 72 6f 63 65 73 73 20 6f 72 20 61 6e 20 61 72 72 61 79 20 | instance.of.Process.or.an.array. |
63820 | 6f 66 20 61 72 67 75 6d 65 6e 74 73 20 74 6f 20 65 73 63 61 70 65 20 61 6e 64 20 72 75 6e 20 6f | of.arguments.to.escape.and.run.o |
63840 | 72 20 61 20 63 6f 6d 6d 61 6e 64 20 74 6f 20 72 75 6e 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d | r.a.command.to.run......*.@param |
63860 | 20 73 74 72 69 6e 67 7c 6e 75 6c 6c 20 20 20 20 20 20 20 20 20 20 24 65 72 72 6f 72 20 20 20 20 | .string|null..........$error.... |
63880 | 20 41 6e 20 65 72 72 6f 72 20 6d 65 73 73 61 67 65 20 74 68 61 74 20 6d 75 73 74 20 62 65 20 64 | .An.error.message.that.must.be.d |
638a0 | 69 73 70 6c 61 79 65 64 20 69 66 20 73 6f 6d 65 74 68 69 6e 67 20 77 65 6e 74 20 77 72 6f 6e 67 | isplayed.if.something.went.wrong |
638c0 | 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 63 61 6c 6c 61 62 6c 65 7c 6e 75 6c 6c 20 20 20 20 | ......*.@param.callable|null.... |
638e0 | 20 20 20 20 24 63 61 6c 6c 62 61 63 6b 20 20 41 20 50 48 50 20 63 61 6c 6c 62 61 63 6b 20 74 6f | ....$callback..A.PHP.callback.to |
63900 | 20 72 75 6e 20 77 68 65 6e 65 76 65 72 20 74 68 65 72 65 20 69 73 20 73 6f 6d 65 0a 20 20 20 20 | .run.whenever.there.is.some..... |
63920 | 20 2a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | .*.............................. |
63940 | 20 20 20 20 20 20 20 20 20 20 6f 75 74 70 75 74 20 61 76 61 69 6c 61 62 6c 65 20 6f 6e 20 53 54 | ..........output.available.on.ST |
63960 | 44 4f 55 54 20 6f 72 20 53 54 44 45 52 52 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 69 6e 74 | DOUT.or.STDERR......*.@param.int |
63980 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 76 65 72 62 6f 73 69 74 79 20 54 68 65 | ..................$verbosity.The |
639a0 | 20 74 68 72 65 73 68 6f 6c 64 20 66 6f 72 20 76 65 72 62 6f 73 69 74 79 0a 20 20 20 20 20 2a 0a | .threshold.for.verbosity......*. |
639c0 | 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 50 72 6f 63 65 73 73 20 54 68 65 20 70 72 6f 63 65 | .....*.@return.Process.The.proce |
639e0 | 73 73 20 74 68 61 74 20 72 61 6e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 | ss.that.ran......*/.....public.f |
63a00 | 75 6e 63 74 69 6f 6e 20 72 75 6e 28 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 | unction.run(OutputInterface.$out |
63a20 | 70 75 74 2c 20 24 63 6d 64 2c 20 24 65 72 72 6f 72 20 3d 20 6e 75 6c 6c 2c 20 63 61 6c 6c 61 62 | put,.$cmd,.$error.=.null,.callab |
63a40 | 6c 65 20 24 63 61 6c 6c 62 61 63 6b 20 3d 20 6e 75 6c 6c 2c 20 24 76 65 72 62 6f 73 69 74 79 20 | le.$callback.=.null,.$verbosity. |
63a60 | 3d 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 3a 3a 56 45 52 42 4f 53 49 54 59 5f 56 45 52 | =.OutputInterface::VERBOSITY_VER |
63a80 | 59 5f 56 45 52 42 4f 53 45 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 6f 75 | Y_VERBOSE).....{.........if.($ou |
63aa0 | 74 70 75 74 20 69 6e 73 74 61 6e 63 65 6f 66 20 43 6f 6e 73 6f 6c 65 4f 75 74 70 75 74 49 6e 74 | tput.instanceof.ConsoleOutputInt |
63ac0 | 65 72 66 61 63 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 75 74 70 75 74 20 3d 20 | erface).{.............$output.=. |
63ae0 | 24 6f 75 74 70 75 74 2d 3e 67 65 74 45 72 72 6f 72 4f 75 74 70 75 74 28 29 3b 0a 20 20 20 20 20 | $output->getErrorOutput();...... |
63b00 | 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 66 6f 72 6d 61 74 74 65 72 20 3d 20 24 74 68 69 73 | ...}..........$formatter.=.$this |
63b20 | 2d 3e 67 65 74 48 65 6c 70 65 72 53 65 74 28 29 2d 3e 67 65 74 28 27 64 65 62 75 67 5f 66 6f 72 | ->getHelperSet()->get('debug_for |
63b40 | 6d 61 74 74 65 72 27 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 69 73 5f 61 72 72 61 79 28 | matter');..........if.(is_array( |
63b60 | 24 63 6d 64 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 70 72 6f 63 65 73 73 20 3d 20 | $cmd)).{.............$process.=. |
63b80 | 50 72 6f 63 65 73 73 42 75 69 6c 64 65 72 3a 3a 63 72 65 61 74 65 28 24 63 6d 64 29 2d 3e 67 65 | ProcessBuilder::create($cmd)->ge |
63ba0 | 74 50 72 6f 63 65 73 73 28 29 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 24 63 | tProcess();.........}.elseif.($c |
63bc0 | 6d 64 20 69 6e 73 74 61 6e 63 65 6f 66 20 50 72 6f 63 65 73 73 29 20 7b 0a 20 20 20 20 20 20 20 | md.instanceof.Process).{........ |
63be0 | 20 20 20 20 20 24 70 72 6f 63 65 73 73 20 3d 20 24 63 6d 64 3b 0a 20 20 20 20 20 20 20 20 7d 20 | .....$process.=.$cmd;.........}. |
63c00 | 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 70 72 6f 63 65 73 73 20 3d 20 6e 65 | else.{.............$process.=.ne |
63c20 | 77 20 50 72 6f 63 65 73 73 28 24 63 6d 64 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 | w.Process($cmd);.........}...... |
63c40 | 20 20 20 20 69 66 20 28 24 76 65 72 62 6f 73 69 74 79 20 3c 3d 20 24 6f 75 74 70 75 74 2d 3e 67 | ....if.($verbosity.<=.$output->g |
63c60 | 65 74 56 65 72 62 6f 73 69 74 79 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 75 | etVerbosity()).{.............$ou |
63c80 | 74 70 75 74 2d 3e 77 72 69 74 65 28 24 66 6f 72 6d 61 74 74 65 72 2d 3e 73 74 61 72 74 28 73 70 | tput->write($formatter->start(sp |
63ca0 | 6c 5f 6f 62 6a 65 63 74 5f 68 61 73 68 28 24 70 72 6f 63 65 73 73 29 2c 20 24 74 68 69 73 2d 3e | l_object_hash($process),.$this-> |
63cc0 | 65 73 63 61 70 65 53 74 72 69 6e 67 28 24 70 72 6f 63 65 73 73 2d 3e 67 65 74 43 6f 6d 6d 61 6e | escapeString($process->getComman |
63ce0 | 64 4c 69 6e 65 28 29 29 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 | dLine())));.........}..........i |
63d00 | 66 20 28 24 6f 75 74 70 75 74 2d 3e 69 73 44 65 62 75 67 28 29 29 20 7b 0a 20 20 20 20 20 20 20 | f.($output->isDebug()).{........ |
63d20 | 20 20 20 20 20 24 63 61 6c 6c 62 61 63 6b 20 3d 20 24 74 68 69 73 2d 3e 77 72 61 70 43 61 6c 6c | .....$callback.=.$this->wrapCall |
63d40 | 62 61 63 6b 28 24 6f 75 74 70 75 74 2c 20 24 70 72 6f 63 65 73 73 2c 20 24 63 61 6c 6c 62 61 63 | back($output,.$process,.$callbac |
63d60 | 6b 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 70 72 6f 63 65 73 73 2d | k);.........}..........$process- |
63d80 | 3e 72 75 6e 28 24 63 61 6c 6c 62 61 63 6b 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 76 | >run($callback);..........if.($v |
63da0 | 65 72 62 6f 73 69 74 79 20 3c 3d 20 24 6f 75 74 70 75 74 2d 3e 67 65 74 56 65 72 62 6f 73 69 74 | erbosity.<=.$output->getVerbosit |
63dc0 | 79 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 20 3d 20 24 70 | y()).{.............$message.=.$p |
63de0 | 72 6f 63 65 73 73 2d 3e 69 73 53 75 63 63 65 73 73 66 75 6c 28 29 20 3f 20 27 43 6f 6d 6d 61 6e | rocess->isSuccessful().?.'Comman |
63e00 | 64 20 72 61 6e 20 73 75 63 63 65 73 73 66 75 6c 6c 79 27 20 3a 20 73 70 72 69 6e 74 66 28 27 25 | d.ran.successfully'.:.sprintf('% |
63e20 | 73 20 43 6f 6d 6d 61 6e 64 20 64 69 64 20 6e 6f 74 20 72 75 6e 20 73 75 63 63 65 73 73 66 75 6c | s.Command.did.not.run.successful |
63e40 | 6c 79 27 2c 20 24 70 72 6f 63 65 73 73 2d 3e 67 65 74 45 78 69 74 43 6f 64 65 28 29 29 3b 0a 20 | ly',.$process->getExitCode());.. |
63e60 | 20 20 20 20 20 20 20 20 20 20 20 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 28 24 66 6f 72 6d 61 | ...........$output->write($forma |
63e80 | 74 74 65 72 2d 3e 73 74 6f 70 28 73 70 6c 5f 6f 62 6a 65 63 74 5f 68 61 73 68 28 24 70 72 6f 63 | tter->stop(spl_object_hash($proc |
63ea0 | 65 73 73 29 2c 20 24 6d 65 73 73 61 67 65 2c 20 24 70 72 6f 63 65 73 73 2d 3e 69 73 53 75 63 63 | ess),.$message,.$process->isSucc |
63ec0 | 65 73 73 66 75 6c 28 29 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 | essful()));.........}..........i |
63ee0 | 66 20 28 21 24 70 72 6f 63 65 73 73 2d 3e 69 73 53 75 63 63 65 73 73 66 75 6c 28 29 20 26 26 20 | f.(!$process->isSuccessful().&&. |
63f00 | 6e 75 6c 6c 20 21 3d 3d 20 24 65 72 72 6f 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 | null.!==.$error).{.............$ |
63f20 | 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 73 70 72 69 6e 74 66 28 27 3c 65 72 72 6f 72 3e | output->writeln(sprintf('<error> |
63f40 | 25 73 3c 2f 65 72 72 6f 72 3e 27 2c 20 24 74 68 69 73 2d 3e 65 73 63 61 70 65 53 74 72 69 6e 67 | %s</error>',.$this->escapeString |
63f60 | 28 24 65 72 72 6f 72 29 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 | ($error)));.........}..........r |
63f80 | 65 74 75 72 6e 20 24 70 72 6f 63 65 73 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 | eturn.$process;.....}....../**.. |
63fa0 | 20 20 20 20 2a 20 52 75 6e 73 20 74 68 65 20 70 72 6f 63 65 73 73 2e 0a 20 20 20 20 20 2a 0a 20 | ....*.Runs.the.process.......*.. |
63fc0 | 20 20 20 20 2a 20 54 68 69 73 20 69 73 20 69 64 65 6e 74 69 63 61 6c 20 74 6f 20 72 75 6e 28 29 | ....*.This.is.identical.to.run() |
63fe0 | 20 65 78 63 65 70 74 20 74 68 61 74 20 61 6e 20 65 78 63 65 70 74 69 6f 6e 20 69 73 20 74 68 72 | .except.that.an.exception.is.thr |
64000 | 6f 77 6e 20 69 66 20 74 68 65 20 70 72 6f 63 65 73 73 0a 20 20 20 20 20 2a 20 65 78 69 74 73 20 | own.if.the.process......*.exits. |
64020 | 77 69 74 68 20 61 20 6e 6f 6e 2d 7a 65 72 6f 20 65 78 69 74 20 63 6f 64 65 2e 0a 20 20 20 20 20 | with.a.non-zero.exit.code....... |
64040 | 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 | *......*.@param.OutputInterface. |
64060 | 24 6f 75 74 70 75 74 20 20 20 41 6e 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 69 6e 73 | $output...An.OutputInterface.ins |
64080 | 74 61 6e 63 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 7c 50 72 6f 63 65 | tance......*.@param.string|Proce |
640a0 | 73 73 20 20 24 63 6d 64 20 20 20 20 20 20 41 6e 20 69 6e 73 74 61 6e 63 65 20 6f 66 20 50 72 6f | ss..$cmd......An.instance.of.Pro |
640c0 | 63 65 73 73 20 6f 72 20 61 20 63 6f 6d 6d 61 6e 64 20 74 6f 20 72 75 6e 0a 20 20 20 20 20 2a 20 | cess.or.a.command.to.run......*. |
640e0 | 40 70 61 72 61 6d 20 73 74 72 69 6e 67 7c 6e 75 6c 6c 20 20 20 20 20 24 65 72 72 6f 72 20 20 20 | @param.string|null.....$error... |
64100 | 20 41 6e 20 65 72 72 6f 72 20 6d 65 73 73 61 67 65 20 74 68 61 74 20 6d 75 73 74 20 62 65 20 64 | .An.error.message.that.must.be.d |
64120 | 69 73 70 6c 61 79 65 64 20 69 66 20 73 6f 6d 65 74 68 69 6e 67 20 77 65 6e 74 20 77 72 6f 6e 67 | isplayed.if.something.went.wrong |
64140 | 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 63 61 6c 6c 61 62 6c 65 7c 6e 75 6c 6c 20 20 20 24 | ......*.@param.callable|null...$ |
64160 | 63 61 6c 6c 62 61 63 6b 20 41 20 50 48 50 20 63 61 6c 6c 62 61 63 6b 20 74 6f 20 72 75 6e 20 77 | callback.A.PHP.callback.to.run.w |
64180 | 68 65 6e 65 76 65 72 20 74 68 65 72 65 20 69 73 20 73 6f 6d 65 0a 20 20 20 20 20 2a 20 20 20 20 | henever.there.is.some......*.... |
641a0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6f 75 | ..............................ou |
641c0 | 74 70 75 74 20 61 76 61 69 6c 61 62 6c 65 20 6f 6e 20 53 54 44 4f 55 54 20 6f 72 20 53 54 44 45 | tput.available.on.STDOUT.or.STDE |
641e0 | 52 52 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 50 72 6f 63 65 73 73 | RR......*......*.@return.Process |
64200 | 20 54 68 65 20 70 72 6f 63 65 73 73 20 74 68 61 74 20 72 61 6e 0a 20 20 20 20 20 2a 0a 20 20 20 | .The.process.that.ran......*.... |
64220 | 20 20 2a 20 40 74 68 72 6f 77 73 20 50 72 6f 63 65 73 73 46 61 69 6c 65 64 45 78 63 65 70 74 69 | ..*.@throws.ProcessFailedExcepti |
64240 | 6f 6e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 73 65 65 20 72 75 6e 28 29 0a 20 20 20 20 | on......*......*.@see.run()..... |
64260 | 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 6d 75 73 74 52 75 6e 28 | .*/.....public.function.mustRun( |
64280 | 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 2c 20 24 63 6d 64 2c 20 24 | OutputInterface.$output,.$cmd,.$ |
642a0 | 65 72 72 6f 72 20 3d 20 6e 75 6c 6c 2c 20 63 61 6c 6c 61 62 6c 65 20 24 63 61 6c 6c 62 61 63 6b | error.=.null,.callable.$callback |
642c0 | 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 70 72 6f 63 65 73 73 20 | .=.null).....{.........$process. |
642e0 | 3d 20 24 74 68 69 73 2d 3e 72 75 6e 28 24 6f 75 74 70 75 74 2c 20 24 63 6d 64 2c 20 24 65 72 72 | =.$this->run($output,.$cmd,.$err |
64300 | 6f 72 2c 20 24 63 61 6c 6c 62 61 63 6b 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 24 70 | or,.$callback);..........if.(!$p |
64320 | 72 6f 63 65 73 73 2d 3e 69 73 53 75 63 63 65 73 73 66 75 6c 28 29 29 20 7b 0a 20 20 20 20 20 20 | rocess->isSuccessful()).{....... |
64340 | 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 50 72 6f 63 65 73 73 46 61 69 6c 65 64 45 78 63 | ......throw.new.ProcessFailedExc |
64360 | 65 70 74 69 6f 6e 28 24 70 72 6f 63 65 73 73 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 | eption($process);.........}..... |
64380 | 20 20 20 20 20 72 65 74 75 72 6e 20 24 70 72 6f 63 65 73 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 | .....return.$process;.....}..... |
643a0 | 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 57 72 61 70 73 20 61 20 50 72 6f 63 65 73 73 20 63 61 6c 6c | ./**......*.Wraps.a.Process.call |
643c0 | 62 61 63 6b 20 74 6f 20 61 64 64 20 64 65 62 75 67 67 69 6e 67 20 6f 75 74 70 75 74 2e 0a 20 20 | back.to.add.debugging.output.... |
643e0 | 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 | ...*......*.@param.OutputInterfa |
64400 | 63 65 20 24 6f 75 74 70 75 74 20 20 20 41 6e 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 | ce.$output...An.OutputInterface. |
64420 | 69 6e 74 65 72 66 61 63 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 50 72 6f 63 65 73 73 20 | interface......*.@param.Process. |
64440 | 20 20 20 20 20 20 20 20 24 70 72 6f 63 65 73 73 20 20 54 68 65 20 50 72 6f 63 65 73 73 0a 20 20 | ........$process..The.Process... |
64460 | 20 20 20 2a 20 40 70 61 72 61 6d 20 63 61 6c 6c 61 62 6c 65 7c 6e 75 6c 6c 20 20 20 24 63 61 6c | ...*.@param.callable|null...$cal |
64480 | 6c 62 61 63 6b 20 41 20 50 48 50 20 63 61 6c 6c 61 62 6c 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 | lback.A.PHP.callable......*..... |
644a0 | 20 2a 20 40 72 65 74 75 72 6e 20 63 61 6c 6c 61 62 6c 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 | .*.@return.callable......*/..... |
644c0 | 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 77 72 61 70 43 61 6c 6c 62 61 63 6b 28 4f 75 74 | public.function.wrapCallback(Out |
644e0 | 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 2c 20 50 72 6f 63 65 73 73 20 24 70 | putInterface.$output,.Process.$p |
64500 | 72 6f 63 65 73 73 2c 20 63 61 6c 6c 61 62 6c 65 20 24 63 61 6c 6c 62 61 63 6b 20 3d 20 6e 75 6c | rocess,.callable.$callback.=.nul |
64520 | 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 6f 75 74 70 75 74 20 69 6e 73 | l).....{.........if.($output.ins |
64540 | 74 61 6e 63 65 6f 66 20 43 6f 6e 73 6f 6c 65 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 29 20 | tanceof.ConsoleOutputInterface). |
64560 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 75 74 70 75 74 20 3d 20 24 6f 75 74 70 75 74 2d | {.............$output.=.$output- |
64580 | 3e 67 65 74 45 72 72 6f 72 4f 75 74 70 75 74 28 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 | >getErrorOutput();.........}.... |
645a0 | 20 20 20 20 20 20 24 66 6f 72 6d 61 74 74 65 72 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 48 65 6c | ......$formatter.=.$this->getHel |
645c0 | 70 65 72 53 65 74 28 29 2d 3e 67 65 74 28 27 64 65 62 75 67 5f 66 6f 72 6d 61 74 74 65 72 27 29 | perSet()->get('debug_formatter') |
645e0 | 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 66 75 6e 63 74 69 6f 6e 20 28 24 74 79 70 | ;..........return.function.($typ |
64600 | 65 2c 20 24 62 75 66 66 65 72 29 20 75 73 65 20 28 24 6f 75 74 70 75 74 2c 20 24 70 72 6f 63 65 | e,.$buffer).use.($output,.$proce |
64620 | 73 73 2c 20 24 63 61 6c 6c 62 61 63 6b 2c 20 24 66 6f 72 6d 61 74 74 65 72 29 20 7b 0a 20 20 20 | ss,.$callback,.$formatter).{.... |
64640 | 20 20 20 20 20 20 20 20 20 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 28 24 66 6f 72 6d 61 74 74 | .........$output->write($formatt |
64660 | 65 72 2d 3e 70 72 6f 67 72 65 73 73 28 73 70 6c 5f 6f 62 6a 65 63 74 5f 68 61 73 68 28 24 70 72 | er->progress(spl_object_hash($pr |
64680 | 6f 63 65 73 73 29 2c 20 24 74 68 69 73 2d 3e 65 73 63 61 70 65 53 74 72 69 6e 67 28 24 62 75 66 | ocess),.$this->escapeString($buf |
646a0 | 66 65 72 29 2c 20 50 72 6f 63 65 73 73 3a 3a 45 52 52 20 3d 3d 3d 20 24 74 79 70 65 29 29 3b 0a | fer),.Process::ERR.===.$type));. |
646c0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 21 3d 3d 20 24 63 61 6c 6c 62 | .............if.(null.!==.$callb |
646e0 | 61 63 6b 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 63 61 6c 6c 5f 75 73 65 72 | ack).{.................call_user |
64700 | 5f 66 75 6e 63 28 24 63 61 6c 6c 62 61 63 6b 2c 20 24 74 79 70 65 2c 20 24 62 75 66 66 65 72 29 | _func($callback,.$type,.$buffer) |
64720 | 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 3b 0a 20 20 20 20 7d | ;.............}.........};.....} |
64740 | 0a 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 65 73 63 61 70 65 53 74 72 | ......private.function.escapeStr |
64760 | 69 6e 67 28 24 73 74 72 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 | ing($str).....{.........return.s |
64780 | 74 72 5f 72 65 70 6c 61 63 65 28 27 3c 27 2c 20 27 5c 5c 3c 27 2c 20 24 73 74 72 29 3b 0a 20 20 | tr_replace('<',.'\\<',.$str);... |
647a0 | 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 | ..}....../**......*.{@inheritdoc |
647c0 | 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 | }......*/.....public.function.ge |
647e0 | 74 4e 61 6d 65 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 27 70 72 | tName().....{.........return.'pr |
64800 | 6f 63 65 73 73 27 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 | ocess';.....}.}.<?php../*..*.Thi |
64820 | 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 | s.file.is.part.of.the.Symfony.pa |
64840 | 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 | ckage...*..*.(c).Fabien.Potencie |
64860 | 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 | r.<fabien@symfony.com>..*..*.For |
64880 | 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 | .the.full.copyright.and.license. |
648a0 | 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 | information,.please.view.the.LIC |
648c0 | 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 | ENSE..*.file.that.was.distribute |
648e0 | 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 | d.with.this.source.code...*/..na |
64900 | 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c | mespace.Symfony\Component\Consol |
64920 | 65 5c 48 65 6c 70 65 72 3b 0a 0a 2f 2a 2a 0a 20 2a 20 4d 61 72 6b 73 20 61 20 72 6f 77 20 61 73 | e\Helper;../**..*.Marks.a.row.as |
64940 | 20 62 65 69 6e 67 20 61 20 73 65 70 61 72 61 74 6f 72 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f | .being.a.separator...*..*.@autho |
64960 | 72 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f | r.Fabien.Potencier.<fabien@symfo |
64980 | 6e 79 2e 63 6f 6d 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 54 61 62 6c 65 53 65 70 61 72 61 74 6f 72 | ny.com>..*/.class.TableSeparator |
649a0 | 20 65 78 74 65 6e 64 73 20 54 61 62 6c 65 43 65 6c 6c 0a 7b 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 | .extends.TableCell.{...../**.... |
649c0 | 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 24 6f 70 74 69 6f 6e 73 0a 20 20 20 20 20 2a | ..*.@param.array.$options......* |
649e0 | 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 | /.....public.function.__construc |
64a00 | 74 28 61 72 72 61 79 20 24 6f 70 74 69 6f 6e 73 20 3d 20 61 72 72 61 79 28 29 29 0a 20 20 20 20 | t(array.$options.=.array())..... |
64a20 | 7b 0a 20 20 20 20 20 20 20 20 70 61 72 65 6e 74 3a 3a 5f 5f 63 6f 6e 73 74 72 75 63 74 28 27 27 | {.........parent::__construct('' |
64a40 | 2c 20 24 6f 70 74 69 6f 6e 73 29 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 | ,.$options);.....}.}.<?php../*.. |
64a60 | 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f | *.This.file.is.part.of.the.Symfo |
64a80 | 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 | ny.package...*..*.(c).Fabien.Pot |
64aa0 | 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 | encier.<fabien@symfony.com>..*.. |
64ac0 | 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 | *.For.the.full.copyright.and.lic |
64ae0 | 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 | ense.information,.please.view.th |
64b00 | 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 | e.LICENSE..*.file.that.was.distr |
64b20 | 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a | ibuted.with.this.source.code...* |
64b40 | 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 | /..namespace.Symfony\Component\C |
64b60 | 6f 6e 73 6f 6c 65 5c 48 65 6c 70 65 72 3b 0a 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 | onsole\Helper;..use.Symfony\Comp |
64b80 | 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 5c 49 6e 70 75 74 49 6e 74 65 72 66 61 | onent\Console\Input\InputInterfa |
64ba0 | 63 65 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c | ce;.use.Symfony\Component\Consol |
64bc0 | 65 5c 49 6e 70 75 74 5c 49 6e 70 75 74 41 77 61 72 65 49 6e 74 65 72 66 61 63 65 3b 0a 0a 2f 2a | e\Input\InputAwareInterface;../* |
64be0 | 2a 0a 20 2a 20 41 6e 20 69 6d 70 6c 65 6d 65 6e 74 61 74 69 6f 6e 20 6f 66 20 49 6e 70 75 74 41 | *..*.An.implementation.of.InputA |
64c00 | 77 61 72 65 49 6e 74 65 72 66 61 63 65 20 66 6f 72 20 48 65 6c 70 65 72 73 2e 0a 20 2a 0a 20 2a | wareInterface.for.Helpers...*..* |
64c20 | 20 40 61 75 74 68 6f 72 20 57 6f 75 74 65 72 20 4a 20 3c 77 61 6c 64 69 6f 2e 77 65 62 64 65 73 | .@author.Wouter.J.<waldio.webdes |
64c40 | 69 67 6e 40 67 6d 61 69 6c 2e 63 6f 6d 3e 0a 20 2a 2f 0a 61 62 73 74 72 61 63 74 20 63 6c 61 73 | ign@gmail.com>..*/.abstract.clas |
64c60 | 73 20 49 6e 70 75 74 41 77 61 72 65 48 65 6c 70 65 72 20 65 78 74 65 6e 64 73 20 48 65 6c 70 65 | s.InputAwareHelper.extends.Helpe |
64c80 | 72 20 69 6d 70 6c 65 6d 65 6e 74 73 20 49 6e 70 75 74 41 77 61 72 65 49 6e 74 65 72 66 61 63 65 | r.implements.InputAwareInterface |
64ca0 | 0a 7b 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 24 69 6e 70 75 74 3b 0a 0a 20 20 20 20 2f 2a | .{.....protected.$input;....../* |
64cc0 | 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 | *......*.{@inheritdoc}......*/.. |
64ce0 | 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 49 6e 70 75 74 28 49 6e 70 75 | ...public.function.setInput(Inpu |
64d00 | 74 49 6e 74 65 72 66 61 63 65 20 24 69 6e 70 75 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 | tInterface.$input).....{........ |
64d20 | 20 24 74 68 69 73 2d 3e 69 6e 70 75 74 20 3d 20 24 69 6e 70 75 74 3b 0a 20 20 20 20 7d 0a 7d 0a | .$this->input.=.$input;.....}.}. |
64d40 | 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f | <?php../*..*.This.file.is.part.o |
64d60 | 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 | f.the.Symfony.package...*..*.(c) |
64d80 | 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e | .Fabien.Potencier.<fabien@symfon |
64da0 | 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 | y.com>..*..*.For.the.full.copyri |
64dc0 | 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 | ght.and.license.information,.ple |
64de0 | 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 | ase.view.the.LICENSE..*.file.tha |
64e00 | 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 | t.was.distributed.with.this.sour |
64e20 | 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c | ce.code...*/..namespace.Symfony\ |
64e40 | 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 48 65 6c 70 65 72 3b 0a 0a 75 73 65 20 53 | Component\Console\Helper;..use.S |
64e60 | 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 46 6f 72 6d 61 74 74 | ymfony\Component\Console\Formatt |
64e80 | 65 72 5c 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 49 6e 74 65 72 66 61 63 65 3b 0a 0a 2f 2a | er\OutputFormatterInterface;../* |
64ea0 | 2a 0a 20 2a 20 48 65 6c 70 65 72 20 69 73 20 74 68 65 20 62 61 73 65 20 63 6c 61 73 73 20 66 6f | *..*.Helper.is.the.base.class.fo |
64ec0 | 72 20 61 6c 6c 20 68 65 6c 70 65 72 20 63 6c 61 73 73 65 73 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 | r.all.helper.classes...*..*.@aut |
64ee0 | 68 6f 72 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d | hor.Fabien.Potencier.<fabien@sym |
64f00 | 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 2f 0a 61 62 73 74 72 61 63 74 20 63 6c 61 73 73 20 48 65 6c | fony.com>..*/.abstract.class.Hel |
64f20 | 70 65 72 20 69 6d 70 6c 65 6d 65 6e 74 73 20 48 65 6c 70 65 72 49 6e 74 65 72 66 61 63 65 0a 7b | per.implements.HelperInterface.{ |
64f40 | 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 24 68 65 6c 70 65 72 53 65 74 20 3d 20 6e 75 6c 6c | .....protected.$helperSet.=.null |
64f60 | 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 74 68 65 20 68 65 6c 70 65 | ;....../**......*.Sets.the.helpe |
64f80 | 72 20 73 65 74 20 61 73 73 6f 63 69 61 74 65 64 20 77 69 74 68 20 74 68 69 73 20 68 65 6c 70 65 | r.set.associated.with.this.helpe |
64fa0 | 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 48 65 6c 70 65 72 53 65 | r.......*......*.@param.HelperSe |
64fc0 | 74 20 24 68 65 6c 70 65 72 53 65 74 20 41 20 48 65 6c 70 65 72 53 65 74 20 69 6e 73 74 61 6e 63 | t.$helperSet.A.HelperSet.instanc |
64fe0 | 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 | e......*/.....public.function.se |
65000 | 74 48 65 6c 70 65 72 53 65 74 28 48 65 6c 70 65 72 53 65 74 20 24 68 65 6c 70 65 72 53 65 74 20 | tHelperSet(HelperSet.$helperSet. |
65020 | 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 68 65 6c | =.null).....{.........$this->hel |
65040 | 70 65 72 53 65 74 20 3d 20 24 68 65 6c 70 65 72 53 65 74 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 | perSet.=.$helperSet;.....}...... |
65060 | 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 68 65 6c 70 65 72 20 73 65 74 20 61 | /**......*.Gets.the.helper.set.a |
65080 | 73 73 6f 63 69 61 74 65 64 20 77 69 74 68 20 74 68 69 73 20 68 65 6c 70 65 72 2e 0a 20 20 20 20 | ssociated.with.this.helper...... |
650a0 | 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 48 65 6c 70 65 72 53 65 74 20 41 20 48 65 | .*......*.@return.HelperSet.A.He |
650c0 | 6c 70 65 72 53 65 74 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 | lperSet.instance......*/.....pub |
650e0 | 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 48 65 6c 70 65 72 53 65 74 28 29 0a 20 20 20 20 | lic.function.getHelperSet()..... |
65100 | 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 68 65 6c 70 65 72 53 65 | {.........return.$this->helperSe |
65120 | 74 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 | t;.....}....../**......*.Returns |
65140 | 20 74 68 65 20 6c 65 6e 67 74 68 20 6f 66 20 61 20 73 74 72 69 6e 67 2c 20 75 73 69 6e 67 20 6d | .the.length.of.a.string,.using.m |
65160 | 62 5f 73 74 72 77 69 64 74 68 20 69 66 20 69 74 20 69 73 20 61 76 61 69 6c 61 62 6c 65 2e 0a 20 | b_strwidth.if.it.is.available... |
65180 | 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 73 74 72 69 | ....*......*.@param.string.$stri |
651a0 | 6e 67 20 54 68 65 20 73 74 72 69 6e 67 20 74 6f 20 63 68 65 63 6b 20 69 74 73 20 6c 65 6e 67 74 | ng.The.string.to.check.its.lengt |
651c0 | 68 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 69 6e 74 20 54 68 65 20 | h......*......*.@return.int.The. |
651e0 | 6c 65 6e 67 74 68 20 6f 66 20 74 68 65 20 73 74 72 69 6e 67 0a 20 20 20 20 20 2a 2f 0a 20 20 20 | length.of.the.string......*/.... |
65200 | 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 74 72 6c 65 6e 28 24 | .public.static.function.strlen($ |
65220 | 73 74 72 69 6e 67 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 66 61 6c 73 65 20 | string).....{.........if.(false. |
65240 | 3d 3d 3d 20 24 65 6e 63 6f 64 69 6e 67 20 3d 20 6d 62 5f 64 65 74 65 63 74 5f 65 6e 63 6f 64 69 | ===.$encoding.=.mb_detect_encodi |
65260 | 6e 67 28 24 73 74 72 69 6e 67 2c 20 6e 75 6c 6c 2c 20 74 72 75 65 29 29 20 7b 0a 20 20 20 20 20 | ng($string,.null,.true)).{...... |
65280 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 74 72 6c 65 6e 28 24 73 74 72 69 6e 67 29 3b 0a 20 | .......return.strlen($string);.. |
652a0 | 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6d 62 5f 73 74 72 77 | .......}..........return.mb_strw |
652c0 | 69 64 74 68 28 24 73 74 72 69 6e 67 2c 20 24 65 6e 63 6f 64 69 6e 67 29 3b 0a 20 20 20 20 7d 0a | idth($string,.$encoding);.....}. |
652e0 | 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 66 6f 72 6d | .....public.static.function.form |
65300 | 61 74 54 69 6d 65 28 24 73 65 63 73 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 73 74 61 74 | atTime($secs).....{.........stat |
65320 | 69 63 20 24 74 69 6d 65 46 6f 72 6d 61 74 73 20 3d 20 61 72 72 61 79 28 0a 20 20 20 20 20 20 20 | ic.$timeFormats.=.array(........ |
65340 | 20 20 20 20 20 61 72 72 61 79 28 30 2c 20 27 3c 20 31 20 73 65 63 27 29 2c 0a 20 20 20 20 20 20 | .....array(0,.'<.1.sec'),....... |
65360 | 20 20 20 20 20 20 61 72 72 61 79 28 31 2c 20 27 31 20 73 65 63 27 29 2c 0a 20 20 20 20 20 20 20 | ......array(1,.'1.sec'),........ |
65380 | 20 20 20 20 20 61 72 72 61 79 28 32 2c 20 27 73 65 63 73 27 2c 20 31 29 2c 0a 20 20 20 20 20 20 | .....array(2,.'secs',.1),....... |
653a0 | 20 20 20 20 20 20 61 72 72 61 79 28 36 30 2c 20 27 31 20 6d 69 6e 27 29 2c 0a 20 20 20 20 20 20 | ......array(60,.'1.min'),....... |
653c0 | 20 20 20 20 20 20 61 72 72 61 79 28 31 32 30 2c 20 27 6d 69 6e 73 27 2c 20 36 30 29 2c 0a 20 20 | ......array(120,.'mins',.60),... |
653e0 | 20 20 20 20 20 20 20 20 20 20 61 72 72 61 79 28 33 36 30 30 2c 20 27 31 20 68 72 27 29 2c 0a 20 | ..........array(3600,.'1.hr'),.. |
65400 | 20 20 20 20 20 20 20 20 20 20 20 61 72 72 61 79 28 37 32 30 30 2c 20 27 68 72 73 27 2c 20 33 36 | ...........array(7200,.'hrs',.36 |
65420 | 30 30 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 61 72 72 61 79 28 38 36 34 30 30 2c 20 27 31 | 00),.............array(86400,.'1 |
65440 | 20 64 61 79 27 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 61 72 72 61 79 28 31 37 32 38 30 30 | .day'),.............array(172800 |
65460 | 2c 20 27 64 61 79 73 27 2c 20 38 36 34 30 30 29 2c 0a 20 20 20 20 20 20 20 20 29 3b 0a 0a 20 20 | ,.'days',.86400),.........);.... |
65480 | 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 74 69 6d 65 46 6f 72 6d 61 74 73 20 61 73 20 24 | ......foreach.($timeFormats.as.$ |
654a0 | 69 6e 64 65 78 20 3d 3e 20 24 66 6f 72 6d 61 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | index.=>.$format).{............. |
654c0 | 69 66 20 28 24 73 65 63 73 20 3e 3d 20 24 66 6f 72 6d 61 74 5b 30 5d 29 20 7b 0a 20 20 20 20 20 | if.($secs.>=.$format[0]).{...... |
654e0 | 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 28 69 73 73 65 74 28 24 74 69 6d 65 46 6f 72 6d 61 | ...........if.((isset($timeForma |
65500 | 74 73 5b 24 69 6e 64 65 78 20 2b 20 31 5d 29 20 26 26 20 24 73 65 63 73 20 3c 20 24 74 69 6d 65 | ts[$index.+.1]).&&.$secs.<.$time |
65520 | 46 6f 72 6d 61 74 73 5b 24 69 6e 64 65 78 20 2b 20 31 5d 5b 30 5d 29 0a 20 20 20 20 20 20 20 20 | Formats[$index.+.1][0])......... |
65540 | 20 20 20 20 20 20 20 20 20 20 20 20 7c 7c 20 24 69 6e 64 65 78 20 3d 3d 20 63 6f 75 6e 74 28 24 | ............||.$index.==.count($ |
65560 | 74 69 6d 65 46 6f 72 6d 61 74 73 29 20 2d 20 31 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | timeFormats).-.1................ |
65580 | 20 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 32 20 3d | .).{.....................if.(2.= |
655a0 | 3d 20 63 6f 75 6e 74 28 24 66 6f 72 6d 61 74 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | =.count($format)).{............. |
655c0 | 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 66 6f 72 6d 61 74 5b 31 5d 3b 0a 20 | ............return.$format[1];.. |
655e0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 | ...................}............ |
65600 | 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 66 6c 6f 6f 72 28 24 73 65 63 73 20 2f 20 24 | ..........return.floor($secs./.$ |
65620 | 66 6f 72 6d 61 74 5b 32 5d 29 2e 27 20 27 2e 24 66 6f 72 6d 61 74 5b 31 5d 3b 0a 20 20 20 20 20 | format[2]).'.'.$format[1];...... |
65640 | 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 | ...........}.............}...... |
65660 | 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 | ...}.....}......public.static.fu |
65680 | 6e 63 74 69 6f 6e 20 66 6f 72 6d 61 74 4d 65 6d 6f 72 79 28 24 6d 65 6d 6f 72 79 29 0a 20 20 20 | nction.formatMemory($memory).... |
656a0 | 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 6d 65 6d 6f 72 79 20 3e 3d 20 31 30 32 34 20 2a | .{.........if.($memory.>=.1024.* |
656c0 | 20 31 30 32 34 20 2a 20 31 30 32 34 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 | .1024.*.1024).{.............retu |
656e0 | 72 6e 20 73 70 72 69 6e 74 66 28 27 25 2e 31 66 20 47 69 42 27 2c 20 24 6d 65 6d 6f 72 79 20 2f | rn.sprintf('%.1f.GiB',.$memory./ |
65700 | 20 31 30 32 34 20 2f 20 31 30 32 34 20 2f 20 31 30 32 34 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a | .1024./.1024./.1024);.........}. |
65720 | 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 6d 65 6d 6f 72 79 20 3e 3d 20 31 30 32 34 20 2a 20 31 | .........if.($memory.>=.1024.*.1 |
65740 | 30 32 34 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 70 72 69 6e 74 | 024).{.............return.sprint |
65760 | 66 28 27 25 2e 31 66 20 4d 69 42 27 2c 20 24 6d 65 6d 6f 72 79 20 2f 20 31 30 32 34 20 2f 20 31 | f('%.1f.MiB',.$memory./.1024./.1 |
65780 | 30 32 34 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 6d 65 | 024);.........}..........if.($me |
657a0 | 6d 6f 72 79 20 3e 3d 20 31 30 32 34 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 | mory.>=.1024).{.............retu |
657c0 | 72 6e 20 73 70 72 69 6e 74 66 28 27 25 64 20 4b 69 42 27 2c 20 24 6d 65 6d 6f 72 79 20 2f 20 31 | rn.sprintf('%d.KiB',.$memory./.1 |
657e0 | 30 32 34 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 | 024);.........}..........return. |
65800 | 73 70 72 69 6e 74 66 28 27 25 64 20 42 27 2c 20 24 6d 65 6d 6f 72 79 29 3b 0a 20 20 20 20 7d 0a | sprintf('%d.B',.$memory);.....}. |
65820 | 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 74 72 6c | .....public.static.function.strl |
65840 | 65 6e 57 69 74 68 6f 75 74 44 65 63 6f 72 61 74 69 6f 6e 28 4f 75 74 70 75 74 46 6f 72 6d 61 74 | enWithoutDecoration(OutputFormat |
65860 | 74 65 72 49 6e 74 65 72 66 61 63 65 20 24 66 6f 72 6d 61 74 74 65 72 2c 20 24 73 74 72 69 6e 67 | terInterface.$formatter,.$string |
65880 | 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 69 73 44 65 63 6f 72 61 74 65 64 20 3d 20 24 | ).....{.........$isDecorated.=.$ |
658a0 | 66 6f 72 6d 61 74 74 65 72 2d 3e 69 73 44 65 63 6f 72 61 74 65 64 28 29 3b 0a 20 20 20 20 20 20 | formatter->isDecorated();....... |
658c0 | 20 20 24 66 6f 72 6d 61 74 74 65 72 2d 3e 73 65 74 44 65 63 6f 72 61 74 65 64 28 66 61 6c 73 65 | ..$formatter->setDecorated(false |
658e0 | 29 3b 0a 20 20 20 20 20 20 20 20 2f 2f 20 72 65 6d 6f 76 65 20 3c 2e 2e 2e 3e 20 66 6f 72 6d 61 | );.........//.remove.<...>.forma |
65900 | 74 74 69 6e 67 0a 20 20 20 20 20 20 20 20 24 73 74 72 69 6e 67 20 3d 20 24 66 6f 72 6d 61 74 74 | tting.........$string.=.$formatt |
65920 | 65 72 2d 3e 66 6f 72 6d 61 74 28 24 73 74 72 69 6e 67 29 3b 0a 20 20 20 20 20 20 20 20 2f 2f 20 | er->format($string);.........//. |
65940 | 72 65 6d 6f 76 65 20 61 6c 72 65 61 64 79 20 66 6f 72 6d 61 74 74 65 64 20 63 68 61 72 61 63 74 | remove.already.formatted.charact |
65960 | 65 72 73 0a 20 20 20 20 20 20 20 20 24 73 74 72 69 6e 67 20 3d 20 70 72 65 67 5f 72 65 70 6c 61 | ers.........$string.=.preg_repla |
65980 | 63 65 28 22 2f 5c 30 33 33 5c 5b 5b 5e 6d 5d 2a 6d 2f 22 2c 20 27 27 2c 20 24 73 74 72 69 6e 67 | ce("/\033\[[^m]*m/",.'',.$string |
659a0 | 29 3b 0a 20 20 20 20 20 20 20 20 24 66 6f 72 6d 61 74 74 65 72 2d 3e 73 65 74 44 65 63 6f 72 61 | );.........$formatter->setDecora |
659c0 | 74 65 64 28 24 69 73 44 65 63 6f 72 61 74 65 64 29 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 | ted($isDecorated);..........retu |
659e0 | 72 6e 20 73 65 6c 66 3a 3a 73 74 72 6c 65 6e 28 24 73 74 72 69 6e 67 29 3b 0a 20 20 20 20 7d 0a | rn.self::strlen($string);.....}. |
65a00 | 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 | }.<?php../*..*.This.file.is.part |
65a20 | 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 | .of.the.Symfony.package...*..*.( |
65a40 | 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 | c).Fabien.Potencier.<fabien@symf |
65a60 | 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 | ony.com>..*..*.For.the.full.copy |
65a80 | 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 | right.and.license.information,.p |
65aa0 | 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 | lease.view.the.LICENSE..*.file.t |
65ac0 | 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f | hat.was.distributed.with.this.so |
65ae0 | 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e | urce.code...*/..namespace.Symfon |
65b00 | 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 48 65 6c 70 65 72 3b 0a 0a 75 73 65 | y\Component\Console\Helper;..use |
65b20 | 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 46 6f 72 6d 61 | .Symfony\Component\Console\Forma |
65b40 | 74 74 65 72 5c 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 3b 0a 0a 2f 2a 2a 0a 20 2a 20 54 68 | tter\OutputFormatter;../**..*.Th |
65b60 | 65 20 46 6f 72 6d 61 74 74 65 72 20 63 6c 61 73 73 20 70 72 6f 76 69 64 65 73 20 68 65 6c 70 65 | e.Formatter.class.provides.helpe |
65b80 | 72 73 20 74 6f 20 66 6f 72 6d 61 74 20 6d 65 73 73 61 67 65 73 2e 0a 20 2a 0a 20 2a 20 40 61 75 | rs.to.format.messages...*..*.@au |
65ba0 | 74 68 6f 72 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 | thor.Fabien.Potencier.<fabien@sy |
65bc0 | 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 46 6f 72 6d 61 74 74 65 72 48 65 | mfony.com>..*/.class.FormatterHe |
65be0 | 6c 70 65 72 20 65 78 74 65 6e 64 73 20 48 65 6c 70 65 72 0a 7b 0a 20 20 20 20 2f 2a 2a 0a 20 20 | lper.extends.Helper.{...../**... |
65c00 | 20 20 20 2a 20 46 6f 72 6d 61 74 73 20 61 20 6d 65 73 73 61 67 65 20 77 69 74 68 69 6e 20 61 20 | ...*.Formats.a.message.within.a. |
65c20 | 73 65 63 74 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 | section.......*......*.@param.st |
65c40 | 72 69 6e 67 20 24 73 65 63 74 69 6f 6e 20 54 68 65 20 73 65 63 74 69 6f 6e 20 6e 61 6d 65 0a 20 | ring.$section.The.section.name.. |
65c60 | 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6d 65 73 73 61 67 65 20 54 68 65 | ....*.@param.string.$message.The |
65c80 | 20 6d 65 73 73 61 67 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 73 | .message......*.@param.string.$s |
65ca0 | 74 79 6c 65 20 20 20 54 68 65 20 73 74 79 6c 65 20 74 6f 20 61 70 70 6c 79 20 74 6f 20 74 68 65 | tyle...The.style.to.apply.to.the |
65cc0 | 20 73 65 63 74 69 6f 6e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 | .section......*......*.@return.s |
65ce0 | 74 72 69 6e 67 20 54 68 65 20 66 6f 72 6d 61 74 20 73 65 63 74 69 6f 6e 0a 20 20 20 20 20 2a 2f | tring.The.format.section......*/ |
65d00 | 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 66 6f 72 6d 61 74 53 65 63 74 69 | .....public.function.formatSecti |
65d20 | 6f 6e 28 24 73 65 63 74 69 6f 6e 2c 20 24 6d 65 73 73 61 67 65 2c 20 24 73 74 79 6c 65 20 3d 20 | on($section,.$message,.$style.=. |
65d40 | 27 69 6e 66 6f 27 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 70 72 | 'info').....{.........return.spr |
65d60 | 69 6e 74 66 28 27 3c 25 73 3e 5b 25 73 5d 3c 2f 25 73 3e 20 25 73 27 2c 20 24 73 74 79 6c 65 2c | intf('<%s>[%s]</%s>.%s',.$style, |
65d80 | 20 24 73 65 63 74 69 6f 6e 2c 20 24 73 74 79 6c 65 2c 20 24 6d 65 73 73 61 67 65 29 3b 0a 20 20 | .$section,.$style,.$message);... |
65da0 | 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 46 6f 72 6d 61 74 73 20 61 20 6d 65 | ..}....../**......*.Formats.a.me |
65dc0 | 73 73 61 67 65 20 61 73 20 61 20 62 6c 6f 63 6b 20 6f 66 20 74 65 78 74 2e 0a 20 20 20 20 20 2a | ssage.as.a.block.of.text.......* |
65de0 | 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 7c 61 72 72 61 79 20 24 6d 65 73 | ......*.@param.string|array.$mes |
65e00 | 73 61 67 65 73 20 54 68 65 20 6d 65 73 73 61 67 65 20 74 6f 20 77 72 69 74 65 20 69 6e 20 74 68 | sages.The.message.to.write.in.th |
65e20 | 65 20 62 6c 6f 63 6b 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 20 20 20 | e.block......*.@param.string.... |
65e40 | 20 20 20 24 73 74 79 6c 65 20 20 20 20 54 68 65 20 73 74 79 6c 65 20 74 6f 20 61 70 70 6c 79 20 | ...$style....The.style.to.apply. |
65e60 | 74 6f 20 74 68 65 20 77 68 6f 6c 65 20 62 6c 6f 63 6b 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d | to.the.whole.block......*.@param |
65e80 | 20 62 6f 6f 6c 20 20 20 20 20 20 20 20 20 24 6c 61 72 67 65 20 20 20 20 57 68 65 74 68 65 72 20 | .bool.........$large....Whether. |
65ea0 | 74 6f 20 72 65 74 75 72 6e 20 61 20 6c 61 72 67 65 20 62 6c 6f 63 6b 0a 20 20 20 20 20 2a 0a 20 | to.return.a.large.block......*.. |
65ec0 | 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 20 54 68 65 20 66 6f 72 6d 61 74 74 | ....*.@return.string.The.formatt |
65ee0 | 65 72 20 6d 65 73 73 61 67 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 | er.message......*/.....public.fu |
65f00 | 6e 63 74 69 6f 6e 20 66 6f 72 6d 61 74 42 6c 6f 63 6b 28 24 6d 65 73 73 61 67 65 73 2c 20 24 73 | nction.formatBlock($messages,.$s |
65f20 | 74 79 6c 65 2c 20 24 6c 61 72 67 65 20 3d 20 66 61 6c 73 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 | tyle,.$large.=.false).....{..... |
65f40 | 20 20 20 20 69 66 20 28 21 69 73 5f 61 72 72 61 79 28 24 6d 65 73 73 61 67 65 73 29 29 20 7b 0a | ....if.(!is_array($messages)).{. |
65f60 | 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 73 20 3d 20 61 72 72 61 79 28 24 6d | ............$messages.=.array($m |
65f80 | 65 73 73 61 67 65 73 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 6c 65 | essages);.........}..........$le |
65fa0 | 6e 20 3d 20 30 3b 0a 20 20 20 20 20 20 20 20 24 6c 69 6e 65 73 20 3d 20 61 72 72 61 79 28 29 3b | n.=.0;.........$lines.=.array(); |
65fc0 | 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 6d 65 73 73 61 67 65 73 20 61 73 20 24 | .........foreach.($messages.as.$ |
65fe0 | 6d 65 73 73 61 67 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 20 | message).{.............$message. |
66000 | 3d 20 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 3a 3a 65 73 63 61 70 65 28 24 6d 65 73 73 61 | =.OutputFormatter::escape($messa |
66020 | 67 65 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 69 6e 65 73 5b 5d 20 3d 20 73 70 72 69 | ge);.............$lines[].=.spri |
66040 | 6e 74 66 28 24 6c 61 72 67 65 20 3f 20 27 20 20 25 73 20 20 27 20 3a 20 27 20 25 73 20 27 2c 20 | ntf($large.?.'..%s..'.:.'.%s.',. |
66060 | 24 6d 65 73 73 61 67 65 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 65 6e 20 3d 20 6d 61 | $message);.............$len.=.ma |
66080 | 78 28 24 74 68 69 73 2d 3e 73 74 72 6c 65 6e 28 24 6d 65 73 73 61 67 65 29 20 2b 20 28 24 6c 61 | x($this->strlen($message).+.($la |
660a0 | 72 67 65 20 3f 20 34 20 3a 20 32 29 2c 20 24 6c 65 6e 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a | rge.?.4.:.2),.$len);.........}.. |
660c0 | 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 73 20 3d 20 24 6c 61 72 67 65 20 3f 20 61 72 72 | ........$messages.=.$large.?.arr |
660e0 | 61 79 28 73 74 72 5f 72 65 70 65 61 74 28 27 20 27 2c 20 24 6c 65 6e 29 29 20 3a 20 61 72 72 61 | ay(str_repeat('.',.$len)).:.arra |
66100 | 79 28 29 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 20 28 24 69 20 3d 20 30 3b 20 69 73 73 65 74 28 | y();.........for.($i.=.0;.isset( |
66120 | 24 6c 69 6e 65 73 5b 24 69 5d 29 3b 20 2b 2b 24 69 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | $lines[$i]);.++$i).{............ |
66140 | 20 24 6d 65 73 73 61 67 65 73 5b 5d 20 3d 20 24 6c 69 6e 65 73 5b 24 69 5d 2e 73 74 72 5f 72 65 | .$messages[].=.$lines[$i].str_re |
66160 | 70 65 61 74 28 27 20 27 2c 20 24 6c 65 6e 20 2d 20 24 74 68 69 73 2d 3e 73 74 72 6c 65 6e 28 24 | peat('.',.$len.-.$this->strlen($ |
66180 | 6c 69 6e 65 73 5b 24 69 5d 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 | lines[$i]));.........}.........i |
661a0 | 66 20 28 24 6c 61 72 67 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 | f.($large).{.............$messag |
661c0 | 65 73 5b 5d 20 3d 20 73 74 72 5f 72 65 70 65 61 74 28 27 20 27 2c 20 24 6c 65 6e 29 3b 0a 20 20 | es[].=.str_repeat('.',.$len);... |
661e0 | 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 66 6f 72 20 28 24 69 20 3d 20 30 3b 20 69 73 | ......}..........for.($i.=.0;.is |
66200 | 73 65 74 28 24 6d 65 73 73 61 67 65 73 5b 24 69 5d 29 3b 20 2b 2b 24 69 29 20 7b 0a 20 20 20 20 | set($messages[$i]);.++$i).{..... |
66220 | 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 73 5b 24 69 5d 20 3d 20 73 70 72 69 6e 74 66 28 | ........$messages[$i].=.sprintf( |
66240 | 27 3c 25 73 3e 25 73 3c 2f 25 73 3e 27 2c 20 24 73 74 79 6c 65 2c 20 24 6d 65 73 73 61 67 65 73 | '<%s>%s</%s>',.$style,.$messages |
66260 | 5b 24 69 5d 2c 20 24 73 74 79 6c 65 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 | [$i],.$style);.........}........ |
66280 | 20 20 72 65 74 75 72 6e 20 69 6d 70 6c 6f 64 65 28 22 5c 6e 22 2c 20 24 6d 65 73 73 61 67 65 73 | ..return.implode("\n",.$messages |
662a0 | 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 54 72 75 6e 63 61 74 | );.....}....../**......*.Truncat |
662c0 | 65 73 20 61 20 6d 65 73 73 61 67 65 20 74 6f 20 74 68 65 20 67 69 76 65 6e 20 6c 65 6e 67 74 68 | es.a.message.to.the.given.length |
662e0 | 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6d | .......*......*.@param.string.$m |
66300 | 65 73 73 61 67 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 69 6e 74 20 20 20 20 24 6c 65 6e | essage......*.@param.int....$len |
66320 | 67 74 68 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 73 75 66 66 69 78 | gth......*.@param.string.$suffix |
66340 | 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 0a 20 20 | ......*......*.@return.string... |
66360 | 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 74 72 75 6e 63 61 | ...*/.....public.function.trunca |
66380 | 74 65 28 24 6d 65 73 73 61 67 65 2c 20 24 6c 65 6e 67 74 68 2c 20 24 73 75 66 66 69 78 20 3d 20 | te($message,.$length,.$suffix.=. |
663a0 | 27 2e 2e 2e 27 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 63 6f 6d 70 75 74 65 64 4c 65 | '...').....{.........$computedLe |
663c0 | 6e 67 74 68 20 3d 20 24 6c 65 6e 67 74 68 20 2d 20 24 74 68 69 73 2d 3e 73 74 72 6c 65 6e 28 24 | ngth.=.$length.-.$this->strlen($ |
663e0 | 73 75 66 66 69 78 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 63 6f 6d 70 75 74 65 64 4c | suffix);..........if.($computedL |
66400 | 65 6e 67 74 68 20 3e 20 24 74 68 69 73 2d 3e 73 74 72 6c 65 6e 28 24 6d 65 73 73 61 67 65 29 29 | ength.>.$this->strlen($message)) |
66420 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 6d 65 73 73 61 67 65 3b 0a | .{.............return.$message;. |
66440 | 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 66 61 6c 73 65 20 3d 3d 3d | ........}..........if.(false.=== |
66460 | 20 24 65 6e 63 6f 64 69 6e 67 20 3d 20 6d 62 5f 64 65 74 65 63 74 5f 65 6e 63 6f 64 69 6e 67 28 | .$encoding.=.mb_detect_encoding( |
66480 | 24 6d 65 73 73 61 67 65 2c 20 6e 75 6c 6c 2c 20 74 72 75 65 29 29 20 7b 0a 20 20 20 20 20 20 20 | $message,.null,.true)).{........ |
664a0 | 20 20 20 20 20 72 65 74 75 72 6e 20 73 75 62 73 74 72 28 24 6d 65 73 73 61 67 65 2c 20 30 2c 20 | .....return.substr($message,.0,. |
664c0 | 24 6c 65 6e 67 74 68 29 2e 24 73 75 66 66 69 78 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 | $length).$suffix;.........}..... |
664e0 | 20 20 20 20 20 72 65 74 75 72 6e 20 6d 62 5f 73 75 62 73 74 72 28 24 6d 65 73 73 61 67 65 2c 20 | .....return.mb_substr($message,. |
66500 | 30 2c 20 24 6c 65 6e 67 74 68 2c 20 24 65 6e 63 6f 64 69 6e 67 29 2e 24 73 75 66 66 69 78 3b 0a | 0,.$length,.$encoding).$suffix;. |
66520 | 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 | ....}....../**......*.{@inheritd |
66540 | 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 | oc}......*/.....public.function. |
66560 | 67 65 74 4e 61 6d 65 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 27 | getName().....{.........return.' |
66580 | 66 6f 72 6d 61 74 74 65 72 27 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a | formatter';.....}.}.<?php../*..* |
665a0 | 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e | .This.file.is.part.of.the.Symfon |
665c0 | 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 | y.package...*..*.(c).Fabien.Pote |
665e0 | 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a | ncier.<fabien@symfony.com>..*..* |
66600 | 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 | .For.the.full.copyright.and.lice |
66620 | 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 | nse.information,.please.view.the |
66640 | 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 | .LICENSE..*.file.that.was.distri |
66660 | 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f | buted.with.this.source.code...*/ |
66680 | 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f | ..namespace.Symfony\Component\Co |
666a0 | 6e 73 6f 6c 65 5c 48 65 6c 70 65 72 3b 0a 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f | nsole\Helper;..use.Symfony\Compo |
666c0 | 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 4f 75 74 70 75 74 5c 4f 75 74 70 75 74 49 6e 74 65 72 66 | nent\Console\Output\OutputInterf |
666e0 | 61 63 65 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f | ace;.use.Symfony\Component\Conso |
66700 | 6c 65 5c 45 78 63 65 70 74 69 6f 6e 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 | le\Exception\InvalidArgumentExce |
66720 | 70 74 69 6f 6e 3b 0a 0a 2f 2a 2a 0a 20 2a 20 50 72 6f 76 69 64 65 73 20 68 65 6c 70 65 72 73 20 | ption;../**..*.Provides.helpers. |
66740 | 74 6f 20 64 69 73 70 6c 61 79 20 61 20 74 61 62 6c 65 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f | to.display.a.table...*..*.@autho |
66760 | 72 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f | r.Fabien.Potencier.<fabien@symfo |
66780 | 6e 79 2e 63 6f 6d 3e 0a 20 2a 20 40 61 75 74 68 6f 72 20 d0 a1 d0 b0 d1 88 d0 b0 20 d0 a1 d1 82 | ny.com>..*.@author.............. |
667a0 | d0 b0 d0 bc d0 b5 d0 bd d0 ba d0 be d0 b2 d0 b8 d1 9b 20 3c 75 6d 70 69 72 73 6b 79 40 67 6d 61 | ...................<umpirsky@gma |
667c0 | 69 6c 2e 63 6f 6d 3e 0a 20 2a 20 40 61 75 74 68 6f 72 20 41 62 64 65 6c 6c 61 74 69 66 20 41 69 | il.com>..*.@author.Abdellatif.Ai |
667e0 | 74 20 62 6f 75 64 61 64 20 3c 61 2e 61 69 74 62 6f 75 64 61 64 40 67 6d 61 69 6c 2e 63 6f 6d 3e | t.boudad.<a.aitboudad@gmail.com> |
66800 | 0a 20 2a 20 40 61 75 74 68 6f 72 20 4d 61 78 20 47 72 69 67 6f 72 69 61 6e 20 3c 6d 61 78 61 6b | ..*.@author.Max.Grigorian.<maxak |
66820 | 61 77 69 7a 61 72 64 40 67 6d 61 69 6c 2e 63 6f 6d 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 54 61 62 | awizard@gmail.com>..*/.class.Tab |
66840 | 6c 65 0a 7b 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 54 61 62 6c 65 20 68 65 61 64 65 72 | le.{...../**......*.Table.header |
66860 | 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 76 61 72 20 61 72 72 61 79 0a 20 20 20 20 | s.......*......*.@var.array..... |
66880 | 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 68 65 61 64 65 72 73 20 3d 20 61 72 72 61 79 | .*/.....private.$headers.=.array |
668a0 | 28 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 54 61 62 6c 65 20 72 6f 77 73 2e 0a | ();....../**......*.Table.rows.. |
668c0 | 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 76 61 72 20 61 72 72 61 79 0a 20 20 20 20 20 2a 2f | .....*......*.@var.array......*/ |
668e0 | 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 72 6f 77 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 0a 20 | .....private.$rows.=.array();... |
66900 | 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 43 6f 6c 75 6d 6e 20 77 69 64 74 68 73 20 63 61 63 68 | .../**......*.Column.widths.cach |
66920 | 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 76 61 72 20 61 72 72 61 79 0a 20 20 20 20 | e.......*......*.@var.array..... |
66940 | 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 65 66 66 65 63 74 69 76 65 43 6f 6c 75 6d 6e | .*/.....private.$effectiveColumn |
66960 | 57 69 64 74 68 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 | Widths.=.array();....../**...... |
66980 | 2a 20 4e 75 6d 62 65 72 20 6f 66 20 63 6f 6c 75 6d 6e 73 20 63 61 63 68 65 2e 0a 20 20 20 20 20 | *.Number.of.columns.cache....... |
669a0 | 2a 0a 20 20 20 20 20 2a 20 40 76 61 72 20 61 72 72 61 79 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 | *......*.@var.array......*/..... |
669c0 | 70 72 69 76 61 74 65 20 24 6e 75 6d 62 65 72 4f 66 43 6f 6c 75 6d 6e 73 3b 0a 0a 20 20 20 20 2f | private.$numberOfColumns;....../ |
669e0 | 2a 2a 0a 20 20 20 20 20 2a 20 40 76 61 72 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 0a 20 | **......*.@var.OutputInterface.. |
66a00 | 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 6f 75 74 70 75 74 3b 0a 0a 20 20 20 | ....*/.....private.$output;..... |
66a20 | 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 76 61 72 20 54 61 62 6c 65 53 74 79 6c 65 0a 20 20 20 20 | ./**......*.@var.TableStyle..... |
66a40 | 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 73 74 79 6c 65 3b 0a 0a 20 20 20 20 2f 2a 2a | .*/.....private.$style;....../** |
66a60 | 0a 20 20 20 20 20 2a 20 40 76 61 72 20 61 72 72 61 79 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 | ......*.@var.array......*/.....p |
66a80 | 72 69 76 61 74 65 20 24 63 6f 6c 75 6d 6e 53 74 79 6c 65 73 20 3d 20 61 72 72 61 79 28 29 3b 0a | rivate.$columnStyles.=.array();. |
66aa0 | 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 55 73 65 72 20 73 65 74 20 63 6f 6c 75 6d 6e 20 | ...../**......*.User.set.column. |
66ac0 | 77 69 64 74 68 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 76 61 72 20 61 72 72 61 79 | widths.......*......*.@var.array |
66ae0 | 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 63 6f 6c 75 6d 6e 57 69 64 74 | ......*/.....private.$columnWidt |
66b00 | 68 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 | hs.=.array();......private.stati |
66b20 | 63 20 24 73 74 79 6c 65 73 3b 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 | c.$styles;......public.function. |
66b40 | 5f 5f 63 6f 6e 73 74 72 75 63 74 28 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 | __construct(OutputInterface.$out |
66b60 | 70 75 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 | put).....{.........$this->output |
66b80 | 20 3d 20 24 6f 75 74 70 75 74 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 73 65 6c 66 3a 3a | .=.$output;..........if.(!self:: |
66ba0 | 24 73 74 79 6c 65 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 73 65 6c 66 3a 3a 24 73 74 | $styles).{.............self::$st |
66bc0 | 79 6c 65 73 20 3d 20 73 65 6c 66 3a 3a 69 6e 69 74 53 74 79 6c 65 73 28 29 3b 0a 20 20 20 20 20 | yles.=.self::initStyles();...... |
66be0 | 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 65 74 53 74 79 6c 65 28 27 64 | ...}..........$this->setStyle('d |
66c00 | 65 66 61 75 6c 74 27 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 | efault');.....}....../**......*. |
66c20 | 53 65 74 73 20 61 20 73 74 79 6c 65 20 64 65 66 69 6e 69 74 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a | Sets.a.style.definition.......*. |
66c40 | 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 20 20 20 20 24 6e 61 6d 65 20 20 | .....*.@param.string.....$name.. |
66c60 | 54 68 65 20 73 74 79 6c 65 20 6e 61 6d 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 54 61 62 | The.style.name......*.@param.Tab |
66c80 | 6c 65 53 74 79 6c 65 20 24 73 74 79 6c 65 20 41 20 54 61 62 6c 65 53 74 79 6c 65 20 69 6e 73 74 | leStyle.$style.A.TableStyle.inst |
66ca0 | 61 6e 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 | ance......*/.....public.static.f |
66cc0 | 75 6e 63 74 69 6f 6e 20 73 65 74 53 74 79 6c 65 44 65 66 69 6e 69 74 69 6f 6e 28 24 6e 61 6d 65 | unction.setStyleDefinition($name |
66ce0 | 2c 20 54 61 62 6c 65 53 74 79 6c 65 20 24 73 74 79 6c 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 | ,.TableStyle.$style).....{...... |
66d00 | 20 20 20 69 66 20 28 21 73 65 6c 66 3a 3a 24 73 74 79 6c 65 73 29 20 7b 0a 20 20 20 20 20 20 20 | ...if.(!self::$styles).{........ |
66d20 | 20 20 20 20 20 73 65 6c 66 3a 3a 24 73 74 79 6c 65 73 20 3d 20 73 65 6c 66 3a 3a 69 6e 69 74 53 | .....self::$styles.=.self::initS |
66d40 | 74 79 6c 65 73 28 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 73 65 6c 66 | tyles();.........}..........self |
66d60 | 3a 3a 24 73 74 79 6c 65 73 5b 24 6e 61 6d 65 5d 20 3d 20 24 73 74 79 6c 65 3b 0a 20 20 20 20 7d | ::$styles[$name].=.$style;.....} |
66d80 | 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 61 20 73 74 79 6c 65 20 64 65 | ....../**......*.Gets.a.style.de |
66da0 | 66 69 6e 69 74 69 6f 6e 20 62 79 20 6e 61 6d 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 | finition.by.name.......*......*. |
66dc0 | 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6e 61 6d 65 20 54 68 65 20 73 74 79 6c 65 20 6e 61 | @param.string.$name.The.style.na |
66de0 | 6d 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 54 61 62 6c 65 53 74 | me......*......*.@return.TableSt |
66e00 | 79 6c 65 20 41 20 54 61 62 6c 65 53 74 79 6c 65 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a | yle.A.TableStyle.instance......* |
66e20 | 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 | /.....public.static.function.get |
66e40 | 53 74 79 6c 65 44 65 66 69 6e 69 74 69 6f 6e 28 24 6e 61 6d 65 29 0a 20 20 20 20 7b 0a 20 20 20 | StyleDefinition($name).....{.... |
66e60 | 20 20 20 20 20 69 66 20 28 21 73 65 6c 66 3a 3a 24 73 74 79 6c 65 73 29 20 7b 0a 20 20 20 20 20 | .....if.(!self::$styles).{...... |
66e80 | 20 20 20 20 20 20 20 73 65 6c 66 3a 3a 24 73 74 79 6c 65 73 20 3d 20 73 65 6c 66 3a 3a 69 6e 69 | .......self::$styles.=.self::ini |
66ea0 | 74 53 74 79 6c 65 73 28 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 | tStyles();.........}..........if |
66ec0 | 20 28 69 73 73 65 74 28 73 65 6c 66 3a 3a 24 73 74 79 6c 65 73 5b 24 6e 61 6d 65 5d 29 29 20 7b | .(isset(self::$styles[$name])).{ |
66ee0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 3a 3a 24 73 74 79 6c 65 | .............return.self::$style |
66f00 | 73 5b 24 6e 61 6d 65 5d 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 74 68 72 | s[$name];.........}..........thr |
66f20 | 6f 77 20 6e 65 77 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 | ow.new.InvalidArgumentException( |
66f40 | 73 70 72 69 6e 74 66 28 27 53 74 79 6c 65 20 22 25 73 22 20 69 73 20 6e 6f 74 20 64 65 66 69 6e | sprintf('Style."%s".is.not.defin |
66f60 | 65 64 2e 27 2c 20 24 6e 61 6d 65 29 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 | ed.',.$name));.....}....../**... |
66f80 | 20 20 20 2a 20 53 65 74 73 20 74 61 62 6c 65 20 73 74 79 6c 65 2e 0a 20 20 20 20 20 2a 0a 20 20 | ...*.Sets.table.style.......*... |
66fa0 | 20 20 20 2a 20 40 70 61 72 61 6d 20 54 61 62 6c 65 53 74 79 6c 65 7c 73 74 72 69 6e 67 20 24 6e | ...*.@param.TableStyle|string.$n |
66fc0 | 61 6d 65 20 54 68 65 20 73 74 79 6c 65 20 6e 61 6d 65 20 6f 72 20 61 20 54 61 62 6c 65 53 74 79 | ame.The.style.name.or.a.TableSty |
66fe0 | 6c 65 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 | le.instance......*......*.@retur |
67000 | 6e 20 54 61 62 6c 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 | n.Table......*/.....public.funct |
67020 | 69 6f 6e 20 73 65 74 53 74 79 6c 65 28 24 6e 61 6d 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 | ion.setStyle($name).....{....... |
67040 | 20 20 24 74 68 69 73 2d 3e 73 74 79 6c 65 20 3d 20 24 74 68 69 73 2d 3e 72 65 73 6f 6c 76 65 53 | ..$this->style.=.$this->resolveS |
67060 | 74 79 6c 65 28 24 6e 61 6d 65 29 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 | tyle($name);..........return.$th |
67080 | 69 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 | is;.....}....../**......*.Gets.t |
670a0 | 68 65 20 63 75 72 72 65 6e 74 20 74 61 62 6c 65 20 73 74 79 6c 65 2e 0a 20 20 20 20 20 2a 0a 20 | he.current.table.style.......*.. |
670c0 | 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 54 61 62 6c 65 53 74 79 6c 65 0a 20 20 20 20 20 2a 2f | ....*.@return.TableStyle......*/ |
670e0 | 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 53 74 79 6c 65 28 29 0a | .....public.function.getStyle(). |
67100 | 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 73 74 79 6c | ....{.........return.$this->styl |
67120 | 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 74 61 | e;.....}....../**......*.Sets.ta |
67140 | 62 6c 65 20 63 6f 6c 75 6d 6e 20 73 74 79 6c 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 | ble.column.style.......*......*. |
67160 | 40 70 61 72 61 6d 20 69 6e 74 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6f 6c 75 6d 6e | @param.int...............$column |
67180 | 49 6e 64 65 78 20 43 6f 6c 75 6d 6e 20 69 6e 64 65 78 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d | Index.Column.index......*.@param |
671a0 | 20 54 61 62 6c 65 53 74 79 6c 65 7c 73 74 72 69 6e 67 20 24 6e 61 6d 65 20 20 20 20 20 20 20 20 | .TableStyle|string.$name........ |
671c0 | 54 68 65 20 73 74 79 6c 65 20 6e 61 6d 65 20 6f 72 20 61 20 54 61 62 6c 65 53 74 79 6c 65 20 69 | The.style.name.or.a.TableStyle.i |
671e0 | 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 54 61 | nstance......*......*.@return.Ta |
67200 | 62 6c 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 | ble......*/.....public.function. |
67220 | 73 65 74 43 6f 6c 75 6d 6e 53 74 79 6c 65 28 24 63 6f 6c 75 6d 6e 49 6e 64 65 78 2c 20 24 6e 61 | setColumnStyle($columnIndex,.$na |
67240 | 6d 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 63 6f 6c 75 6d 6e 49 6e 64 65 78 20 3d | me).....{.........$columnIndex.= |
67260 | 20 69 6e 74 76 61 6c 28 24 63 6f 6c 75 6d 6e 49 6e 64 65 78 29 3b 0a 0a 20 20 20 20 20 20 20 20 | .intval($columnIndex);.......... |
67280 | 24 74 68 69 73 2d 3e 63 6f 6c 75 6d 6e 53 74 79 6c 65 73 5b 24 63 6f 6c 75 6d 6e 49 6e 64 65 78 | $this->columnStyles[$columnIndex |
672a0 | 5d 20 3d 20 24 74 68 69 73 2d 3e 72 65 73 6f 6c 76 65 53 74 79 6c 65 28 24 6e 61 6d 65 29 3b 0a | ].=.$this->resolveStyle($name);. |
672c0 | 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 | .........return.$this;.....}.... |
672e0 | 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 63 75 72 72 65 6e 74 20 73 74 | ../**......*.Gets.the.current.st |
67300 | 79 6c 65 20 66 6f 72 20 61 20 63 6f 6c 75 6d 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 | yle.for.a.column.......*......*. |
67320 | 49 66 20 73 74 79 6c 65 20 77 61 73 20 6e 6f 74 20 73 65 74 2c 20 69 74 20 72 65 74 75 72 6e 73 | If.style.was.not.set,.it.returns |
67340 | 20 74 68 65 20 67 6c 6f 62 61 6c 20 74 61 62 6c 65 20 73 74 79 6c 65 2e 0a 20 20 20 20 20 2a 0a | .the.global.table.style.......*. |
67360 | 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 69 6e 74 20 24 63 6f 6c 75 6d 6e 49 6e 64 65 78 20 43 | .....*.@param.int.$columnIndex.C |
67380 | 6f 6c 75 6d 6e 20 69 6e 64 65 78 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 | olumn.index......*......*.@retur |
673a0 | 6e 20 54 61 62 6c 65 53 74 79 6c 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 | n.TableStyle......*/.....public. |
673c0 | 66 75 6e 63 74 69 6f 6e 20 67 65 74 43 6f 6c 75 6d 6e 53 74 79 6c 65 28 24 63 6f 6c 75 6d 6e 49 | function.getColumnStyle($columnI |
673e0 | 6e 64 65 78 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 69 73 73 65 74 28 24 74 | ndex).....{.........if.(isset($t |
67400 | 68 69 73 2d 3e 63 6f 6c 75 6d 6e 53 74 79 6c 65 73 5b 24 63 6f 6c 75 6d 6e 49 6e 64 65 78 5d 29 | his->columnStyles[$columnIndex]) |
67420 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 63 6f | ).{.............return.$this->co |
67440 | 6c 75 6d 6e 53 74 79 6c 65 73 5b 24 63 6f 6c 75 6d 6e 49 6e 64 65 78 5d 3b 0a 20 20 20 20 20 20 | lumnStyles[$columnIndex];....... |
67460 | 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 67 65 74 53 74 | ..}..........return.$this->getSt |
67480 | 79 6c 65 28 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 | yle();.....}....../**......*.Set |
674a0 | 73 20 74 68 65 20 6d 69 6e 69 6d 75 6d 20 77 69 64 74 68 20 6f 66 20 61 20 63 6f 6c 75 6d 6e 2e | s.the.minimum.width.of.a.column. |
674c0 | 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 69 6e 74 20 24 63 6f 6c 75 6d | ......*......*.@param.int.$colum |
674e0 | 6e 49 6e 64 65 78 20 43 6f 6c 75 6d 6e 20 69 6e 64 65 78 0a 20 20 20 20 20 2a 20 40 70 61 72 61 | nIndex.Column.index......*.@para |
67500 | 6d 20 69 6e 74 20 24 77 69 64 74 68 20 20 20 20 20 20 20 4d 69 6e 69 6d 75 6d 20 63 6f 6c 75 6d | m.int.$width.......Minimum.colum |
67520 | 6e 20 77 69 64 74 68 20 69 6e 20 63 68 61 72 61 63 74 65 72 73 0a 20 20 20 20 20 2a 0a 20 20 20 | n.width.in.characters......*.... |
67540 | 20 20 2a 20 40 72 65 74 75 72 6e 20 54 61 62 6c 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 | ..*.@return.Table......*/.....pu |
67560 | 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 43 6f 6c 75 6d 6e 57 69 64 74 68 28 24 63 6f | blic.function.setColumnWidth($co |
67580 | 6c 75 6d 6e 49 6e 64 65 78 2c 20 24 77 69 64 74 68 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 | lumnIndex,.$width).....{........ |
675a0 | 20 24 74 68 69 73 2d 3e 63 6f 6c 75 6d 6e 57 69 64 74 68 73 5b 69 6e 74 76 61 6c 28 24 63 6f 6c | .$this->columnWidths[intval($col |
675c0 | 75 6d 6e 49 6e 64 65 78 29 5d 20 3d 20 69 6e 74 76 61 6c 28 24 77 69 64 74 68 29 3b 0a 0a 20 20 | umnIndex)].=.intval($width);.... |
675e0 | 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f | ......return.$this;.....}....../ |
67600 | 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 74 68 65 20 6d 69 6e 69 6d 75 6d 20 77 69 64 74 68 | **......*.Sets.the.minimum.width |
67620 | 20 6f 66 20 61 6c 6c 20 63 6f 6c 75 6d 6e 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 | .of.all.columns.......*......*.@ |
67640 | 70 61 72 61 6d 20 61 72 72 61 79 20 24 77 69 64 74 68 73 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 | param.array.$widths......*...... |
67660 | 2a 20 40 72 65 74 75 72 6e 20 54 61 62 6c 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c | *.@return.Table......*/.....publ |
67680 | 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 43 6f 6c 75 6d 6e 57 69 64 74 68 73 28 61 72 72 61 | ic.function.setColumnWidths(arra |
676a0 | 79 20 24 77 69 64 74 68 73 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e | y.$widths).....{.........$this-> |
676c0 | 63 6f 6c 75 6d 6e 57 69 64 74 68 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 | columnWidths.=.array();......... |
676e0 | 66 6f 72 65 61 63 68 20 28 24 77 69 64 74 68 73 20 61 73 20 24 69 6e 64 65 78 20 3d 3e 20 24 77 | foreach.($widths.as.$index.=>.$w |
67700 | 69 64 74 68 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 65 74 43 6f | idth).{.............$this->setCo |
67720 | 6c 75 6d 6e 57 69 64 74 68 28 24 69 6e 64 65 78 2c 20 24 77 69 64 74 68 29 3b 0a 20 20 20 20 20 | lumnWidth($index,.$width);...... |
67740 | 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 3b 0a 20 20 20 20 | ...}..........return.$this;..... |
67760 | 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 48 65 61 64 65 72 | }......public.function.setHeader |
67780 | 73 28 61 72 72 61 79 20 24 68 65 61 64 65 72 73 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | s(array.$headers).....{......... |
677a0 | 24 68 65 61 64 65 72 73 20 3d 20 61 72 72 61 79 5f 76 61 6c 75 65 73 28 24 68 65 61 64 65 72 73 | $headers.=.array_values($headers |
677c0 | 29 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 65 6d 70 74 79 28 24 68 65 61 64 65 72 73 29 20 | );.........if.(!empty($headers). |
677e0 | 26 26 20 21 69 73 5f 61 72 72 61 79 28 24 68 65 61 64 65 72 73 5b 30 5d 29 29 20 7b 0a 20 20 20 | &&.!is_array($headers[0])).{.... |
67800 | 20 20 20 20 20 20 20 20 20 24 68 65 61 64 65 72 73 20 3d 20 61 72 72 61 79 28 24 68 65 61 64 65 | .........$headers.=.array($heade |
67820 | 72 73 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 68 | rs);.........}..........$this->h |
67840 | 65 61 64 65 72 73 20 3d 20 24 68 65 61 64 65 72 73 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 | eaders.=.$headers;..........retu |
67860 | 72 6e 20 24 74 68 69 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 | rn.$this;.....}......public.func |
67880 | 74 69 6f 6e 20 73 65 74 52 6f 77 73 28 61 72 72 61 79 20 24 72 6f 77 73 29 0a 20 20 20 20 7b 0a | tion.setRows(array.$rows).....{. |
678a0 | 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 72 6f 77 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 0a | ........$this->rows.=.array();.. |
678c0 | 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 61 64 64 52 6f 77 73 28 24 72 | ........return.$this->addRows($r |
678e0 | 6f 77 73 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e | ows);.....}......public.function |
67900 | 20 61 64 64 52 6f 77 73 28 61 72 72 61 79 20 24 72 6f 77 73 29 0a 20 20 20 20 7b 0a 20 20 20 20 | .addRows(array.$rows).....{..... |
67920 | 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 72 6f 77 73 20 61 73 20 24 72 6f 77 29 20 7b 0a 20 20 | ....foreach.($rows.as.$row).{... |
67940 | 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 61 64 64 52 6f 77 28 24 72 6f 77 29 3b 0a 20 | ..........$this->addRow($row);.. |
67960 | 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 3b 0a | .......}..........return.$this;. |
67980 | 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 61 64 64 52 6f | ....}......public.function.addRo |
679a0 | 77 28 24 72 6f 77 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 72 6f 77 20 69 | w($row).....{.........if.($row.i |
679c0 | 6e 73 74 61 6e 63 65 6f 66 20 54 61 62 6c 65 53 65 70 61 72 61 74 6f 72 29 20 7b 0a 20 20 20 20 | nstanceof.TableSeparator).{..... |
679e0 | 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 72 6f 77 73 5b 5d 20 3d 20 24 72 6f 77 3b 0a 0a 20 | ........$this->rows[].=.$row;... |
67a00 | 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 3b 0a 20 20 20 20 20 20 20 | ...........return.$this;........ |
67a20 | 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 69 73 5f 61 72 72 61 79 28 24 72 6f 77 29 29 | .}..........if.(!is_array($row)) |
67a40 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 61 6c 69 64 | .{.............throw.new.Invalid |
67a60 | 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 27 41 20 72 6f 77 20 6d 75 73 74 20 62 65 | ArgumentException('A.row.must.be |
67a80 | 20 61 6e 20 61 72 72 61 79 20 6f 72 20 61 20 54 61 62 6c 65 53 65 70 61 72 61 74 6f 72 20 69 6e | .an.array.or.a.TableSeparator.in |
67aa0 | 73 74 61 6e 63 65 2e 27 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 | stance.');.........}..........$t |
67ac0 | 68 69 73 2d 3e 72 6f 77 73 5b 5d 20 3d 20 61 72 72 61 79 5f 76 61 6c 75 65 73 28 24 72 6f 77 29 | his->rows[].=.array_values($row) |
67ae0 | 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 3b 0a 20 20 20 20 7d 0a 0a | ;..........return.$this;.....}.. |
67b00 | 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 52 6f 77 28 24 63 6f 6c 75 | ....public.function.setRow($colu |
67b20 | 6d 6e 2c 20 61 72 72 61 79 20 24 72 6f 77 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 | mn,.array.$row).....{.........$t |
67b40 | 68 69 73 2d 3e 72 6f 77 73 5b 24 63 6f 6c 75 6d 6e 5d 20 3d 20 24 72 6f 77 3b 0a 0a 20 20 20 20 | his->rows[$column].=.$row;...... |
67b60 | 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a | ....return.$this;.....}....../** |
67b80 | 0a 20 20 20 20 20 2a 20 52 65 6e 64 65 72 73 20 74 61 62 6c 65 20 74 6f 20 6f 75 74 70 75 74 2e | ......*.Renders.table.to.output. |
67ba0 | 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 45 78 61 6d 70 6c 65 3a 0a 20 20 20 20 20 2a 20 2b | ......*......*.Example:......*.+ |
67bc0 | 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2b 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d | ---------------+---------------- |
67be0 | 2d 2d 2d 2d 2d 2d 2d 2b 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2b 0a 20 20 20 20 | -------+------------------+..... |
67c00 | 20 2a 20 7c 20 49 53 42 4e 20 20 20 20 20 20 20 20 20 20 7c 20 54 69 74 6c 65 20 20 20 20 20 20 | .*.|.ISBN..........|.Title...... |
67c20 | 20 20 20 20 20 20 20 20 20 20 20 7c 20 41 75 74 68 6f 72 20 20 20 20 20 20 20 20 20 20 20 7c 0a | ...........|.Author...........|. |
67c40 | 20 20 20 20 20 2a 20 2b 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2b 2d 2d 2d 2d 2d 2d 2d 2d | .....*.+---------------+-------- |
67c60 | 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2b 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d | ---------------+---------------- |
67c80 | 2d 2d 2b 0a 20 20 20 20 20 2a 20 7c 20 39 39 39 32 31 2d 35 38 2d 31 30 2d 37 20 7c 20 44 69 76 | --+......*.|.99921-58-10-7.|.Div |
67ca0 | 69 6e 65 20 43 6f 6d 65 64 79 20 20 20 20 20 20 20 20 20 7c 20 44 61 6e 74 65 20 41 6c 69 67 68 | ine.Comedy.........|.Dante.Aligh |
67cc0 | 69 65 72 69 20 20 7c 0a 20 20 20 20 20 2a 20 7c 20 39 39 37 31 2d 35 2d 30 32 31 30 2d 30 20 7c | ieri..|......*.|.9971-5-0210-0.| |
67ce0 | 20 41 20 54 61 6c 65 20 6f 66 20 54 77 6f 20 43 69 74 69 65 73 20 20 7c 20 43 68 61 72 6c 65 73 | .A.Tale.of.Two.Cities..|.Charles |
67d00 | 20 44 69 63 6b 65 6e 73 20 20 7c 0a 20 20 20 20 20 2a 20 7c 20 39 36 30 2d 34 32 35 2d 30 35 39 | .Dickens..|......*.|.960-425-059 |
67d20 | 2d 30 20 7c 20 54 68 65 20 4c 6f 72 64 20 6f 66 20 74 68 65 20 52 69 6e 67 73 20 7c 20 4a 2e 20 | -0.|.The.Lord.of.the.Rings.|.J.. |
67d40 | 52 2e 20 52 2e 20 54 6f 6c 6b 69 65 6e 20 7c 0a 20 20 20 20 20 2a 20 2b 2d 2d 2d 2d 2d 2d 2d 2d | R..R..Tolkien.|......*.+-------- |
67d60 | 2d 2d 2d 2d 2d 2d 2d 2b 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2b | -------+-----------------------+ |
67d80 | 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2b 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 | ------------------+......*/..... |
67da0 | 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 72 65 6e 64 65 72 28 29 0a 20 20 20 20 7b 0a 20 | public.function.render().....{.. |
67dc0 | 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 63 61 6c 63 75 6c 61 74 65 4e 75 6d 62 65 72 4f 66 43 | .......$this->calculateNumberOfC |
67de0 | 6f 6c 75 6d 6e 73 28 29 3b 0a 20 20 20 20 20 20 20 20 24 72 6f 77 73 20 3d 20 24 74 68 69 73 2d | olumns();.........$rows.=.$this- |
67e00 | 3e 62 75 69 6c 64 54 61 62 6c 65 52 6f 77 73 28 24 74 68 69 73 2d 3e 72 6f 77 73 29 3b 0a 20 20 | >buildTableRows($this->rows);... |
67e20 | 20 20 20 20 20 20 24 68 65 61 64 65 72 73 20 3d 20 24 74 68 69 73 2d 3e 62 75 69 6c 64 54 61 62 | ......$headers.=.$this->buildTab |
67e40 | 6c 65 52 6f 77 73 28 24 74 68 69 73 2d 3e 68 65 61 64 65 72 73 29 3b 0a 0a 20 20 20 20 20 20 20 | leRows($this->headers);......... |
67e60 | 20 24 74 68 69 73 2d 3e 63 61 6c 63 75 6c 61 74 65 43 6f 6c 75 6d 6e 73 57 69 64 74 68 28 61 72 | .$this->calculateColumnsWidth(ar |
67e80 | 72 61 79 5f 6d 65 72 67 65 28 24 68 65 61 64 65 72 73 2c 20 24 72 6f 77 73 29 29 3b 0a 0a 20 20 | ray_merge($headers,.$rows));.... |
67ea0 | 20 20 20 20 20 20 24 74 68 69 73 2d 3e 72 65 6e 64 65 72 52 6f 77 53 65 70 61 72 61 74 6f 72 28 | ......$this->renderRowSeparator( |
67ec0 | 29 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 65 6d 70 74 79 28 24 68 65 61 64 65 72 73 29 29 | );.........if.(!empty($headers)) |
67ee0 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 68 65 61 64 65 72 73 | .{.............foreach.($headers |
67f00 | 20 61 73 20 24 68 65 61 64 65 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 | .as.$header).{.................$ |
67f20 | 74 68 69 73 2d 3e 72 65 6e 64 65 72 52 6f 77 28 24 68 65 61 64 65 72 2c 20 24 74 68 69 73 2d 3e | this->renderRow($header,.$this-> |
67f40 | 73 74 79 6c 65 2d 3e 67 65 74 43 65 6c 6c 48 65 61 64 65 72 46 6f 72 6d 61 74 28 29 29 3b 0a 20 | style->getCellHeaderFormat());.. |
67f60 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 72 65 6e 64 65 72 52 6f 77 53 | ...............$this->renderRowS |
67f80 | 65 70 61 72 61 74 6f 72 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 | eparator();.............}....... |
67fa0 | 20 20 7d 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 72 6f 77 73 20 61 73 20 24 72 | ..}.........foreach.($rows.as.$r |
67fc0 | 6f 77 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 72 6f 77 20 69 6e 73 74 61 | ow).{.............if.($row.insta |
67fe0 | 6e 63 65 6f 66 20 54 61 62 6c 65 53 65 70 61 72 61 74 6f 72 29 20 7b 0a 20 20 20 20 20 20 20 20 | nceof.TableSeparator).{......... |
68000 | 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 72 65 6e 64 65 72 52 6f 77 53 65 70 61 72 61 74 6f | ........$this->renderRowSeparato |
68020 | 72 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 | r();.............}.else.{....... |
68040 | 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 72 65 6e 64 65 72 52 6f 77 28 24 72 6f 77 2c | ..........$this->renderRow($row, |
68060 | 20 24 74 68 69 73 2d 3e 73 74 79 6c 65 2d 3e 67 65 74 43 65 6c 6c 52 6f 77 46 6f 72 6d 61 74 28 | .$this->style->getCellRowFormat( |
68080 | 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 | ));.............}.........}..... |
680a0 | 20 20 20 20 69 66 20 28 21 65 6d 70 74 79 28 24 72 6f 77 73 29 29 20 7b 0a 20 20 20 20 20 20 20 | ....if.(!empty($rows)).{........ |
680c0 | 20 20 20 20 20 24 74 68 69 73 2d 3e 72 65 6e 64 65 72 52 6f 77 53 65 70 61 72 61 74 6f 72 28 29 | .....$this->renderRowSeparator() |
680e0 | 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 63 6c 65 61 | ;.........}..........$this->clea |
68100 | 6e 75 70 28 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 6e | nup();.....}....../**......*.Ren |
68120 | 64 65 72 73 20 68 6f 72 69 7a 6f 6e 74 61 6c 20 68 65 61 64 65 72 20 73 65 70 61 72 61 74 6f 72 | ders.horizontal.header.separator |
68140 | 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 45 78 61 6d 70 6c 65 3a 20 2b 2d 2d 2d 2d 2d 2b | .......*......*.Example:.+-----+ |
68160 | 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2d 2b 2d 2d 2d 2d 2d 2d 2d 2b 0a 20 20 20 20 20 2a 2f 0a 20 20 20 | -----------+-------+......*/.... |
68180 | 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 72 65 6e 64 65 72 52 6f 77 53 65 70 61 72 | .private.function.renderRowSepar |
681a0 | 61 74 6f 72 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 30 20 3d 3d 3d 20 24 | ator().....{.........if.(0.===.$ |
681c0 | 63 6f 75 6e 74 20 3d 20 24 74 68 69 73 2d 3e 6e 75 6d 62 65 72 4f 66 43 6f 6c 75 6d 6e 73 29 20 | count.=.$this->numberOfColumns). |
681e0 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 3b 0a 20 20 20 20 20 20 20 20 7d 0a | {.............return;.........}. |
68200 | 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 24 74 68 69 73 2d 3e 73 74 79 6c 65 2d 3e 67 65 74 48 | .........if.(!$this->style->getH |
68220 | 6f 72 69 7a 6f 6e 74 61 6c 42 6f 72 64 65 72 43 68 61 72 28 29 20 26 26 20 21 24 74 68 69 73 2d | orizontalBorderChar().&&.!$this- |
68240 | 3e 73 74 79 6c 65 2d 3e 67 65 74 43 72 6f 73 73 69 6e 67 43 68 61 72 28 29 29 20 7b 0a 20 20 20 | >style->getCrossingChar()).{.... |
68260 | 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 | .........return;.........}...... |
68280 | 20 20 20 20 24 6d 61 72 6b 75 70 20 3d 20 24 74 68 69 73 2d 3e 73 74 79 6c 65 2d 3e 67 65 74 43 | ....$markup.=.$this->style->getC |
682a0 | 72 6f 73 73 69 6e 67 43 68 61 72 28 29 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 20 28 24 63 6f 6c | rossingChar();.........for.($col |
682c0 | 75 6d 6e 20 3d 20 30 3b 20 24 63 6f 6c 75 6d 6e 20 3c 20 24 63 6f 75 6e 74 3b 20 2b 2b 24 63 6f | umn.=.0;.$column.<.$count;.++$co |
682e0 | 6c 75 6d 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 61 72 6b 75 70 20 2e 3d 20 73 | lumn).{.............$markup..=.s |
68300 | 74 72 5f 72 65 70 65 61 74 28 24 74 68 69 73 2d 3e 73 74 79 6c 65 2d 3e 67 65 74 48 6f 72 69 7a | tr_repeat($this->style->getHoriz |
68320 | 6f 6e 74 61 6c 42 6f 72 64 65 72 43 68 61 72 28 29 2c 20 24 74 68 69 73 2d 3e 65 66 66 65 63 74 | ontalBorderChar(),.$this->effect |
68340 | 69 76 65 43 6f 6c 75 6d 6e 57 69 64 74 68 73 5b 24 63 6f 6c 75 6d 6e 5d 29 2e 24 74 68 69 73 2d | iveColumnWidths[$column]).$this- |
68360 | 3e 73 74 79 6c 65 2d 3e 67 65 74 43 72 6f 73 73 69 6e 67 43 68 61 72 28 29 3b 0a 20 20 20 20 20 | >style->getCrossingChar();...... |
68380 | 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 2d 3e 77 72 69 | ...}..........$this->output->wri |
683a0 | 74 65 6c 6e 28 73 70 72 69 6e 74 66 28 24 74 68 69 73 2d 3e 73 74 79 6c 65 2d 3e 67 65 74 42 6f | teln(sprintf($this->style->getBo |
683c0 | 72 64 65 72 46 6f 72 6d 61 74 28 29 2c 20 24 6d 61 72 6b 75 70 29 29 3b 0a 20 20 20 20 7d 0a 0a | rderFormat(),.$markup));.....}.. |
683e0 | 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 6e 64 65 72 73 20 76 65 72 74 69 63 61 6c 20 | ..../**......*.Renders.vertical. |
68400 | 63 6f 6c 75 6d 6e 20 73 65 70 61 72 61 74 6f 72 2e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 | column.separator.......*/.....pr |
68420 | 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 72 65 6e 64 65 72 43 6f 6c 75 6d 6e 53 65 70 61 72 | ivate.function.renderColumnSepar |
68440 | 61 74 6f 72 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 70 72 69 | ator().....{.........return.spri |
68460 | 6e 74 66 28 24 74 68 69 73 2d 3e 73 74 79 6c 65 2d 3e 67 65 74 42 6f 72 64 65 72 46 6f 72 6d 61 | ntf($this->style->getBorderForma |
68480 | 74 28 29 2c 20 24 74 68 69 73 2d 3e 73 74 79 6c 65 2d 3e 67 65 74 56 65 72 74 69 63 61 6c 42 6f | t(),.$this->style->getVerticalBo |
684a0 | 72 64 65 72 43 68 61 72 28 29 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 | rderChar());.....}....../**..... |
684c0 | 20 2a 20 52 65 6e 64 65 72 73 20 74 61 62 6c 65 20 72 6f 77 2e 0a 20 20 20 20 20 2a 0a 20 20 20 | .*.Renders.table.row.......*.... |
684e0 | 20 20 2a 20 45 78 61 6d 70 6c 65 3a 20 7c 20 39 39 37 31 2d 35 2d 30 32 31 30 2d 30 20 7c 20 41 | ..*.Example:.|.9971-5-0210-0.|.A |
68500 | 20 54 61 6c 65 20 6f 66 20 54 77 6f 20 43 69 74 69 65 73 20 20 7c 20 43 68 61 72 6c 65 73 20 44 | .Tale.of.Two.Cities..|.Charles.D |
68520 | 69 63 6b 65 6e 73 20 20 7c 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 | ickens..|......*......*.@param.a |
68540 | 72 72 61 79 20 20 24 72 6f 77 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 | rray..$row......*.@param.string. |
68560 | 24 63 65 6c 6c 46 6f 72 6d 61 74 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 | $cellFormat......*/.....private. |
68580 | 66 75 6e 63 74 69 6f 6e 20 72 65 6e 64 65 72 52 6f 77 28 61 72 72 61 79 20 24 72 6f 77 2c 20 24 | function.renderRow(array.$row,.$ |
685a0 | 63 65 6c 6c 46 6f 72 6d 61 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 65 6d | cellFormat).....{.........if.(em |
685c0 | 70 74 79 28 24 72 6f 77 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 3b | pty($row)).{.............return; |
685e0 | 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 72 6f 77 43 6f 6e 74 65 6e 74 20 | .........}..........$rowContent. |
68600 | 3d 20 24 74 68 69 73 2d 3e 72 65 6e 64 65 72 43 6f 6c 75 6d 6e 53 65 70 61 72 61 74 6f 72 28 29 | =.$this->renderColumnSeparator() |
68620 | 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 74 68 69 73 2d 3e 67 65 74 52 6f 77 | ;.........foreach.($this->getRow |
68640 | 43 6f 6c 75 6d 6e 73 28 24 72 6f 77 29 20 61 73 20 24 63 6f 6c 75 6d 6e 29 20 7b 0a 20 20 20 20 | Columns($row).as.$column).{..... |
68660 | 20 20 20 20 20 20 20 20 24 72 6f 77 43 6f 6e 74 65 6e 74 20 2e 3d 20 24 74 68 69 73 2d 3e 72 65 | ........$rowContent..=.$this->re |
68680 | 6e 64 65 72 43 65 6c 6c 28 24 72 6f 77 2c 20 24 63 6f 6c 75 6d 6e 2c 20 24 63 65 6c 6c 46 6f 72 | nderCell($row,.$column,.$cellFor |
686a0 | 6d 61 74 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 72 6f 77 43 6f 6e 74 65 6e 74 20 2e 3d | mat);.............$rowContent..= |
686c0 | 20 24 74 68 69 73 2d 3e 72 65 6e 64 65 72 43 6f 6c 75 6d 6e 53 65 70 61 72 61 74 6f 72 28 29 3b | .$this->renderColumnSeparator(); |
686e0 | 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 | .........}.........$this->output |
68700 | 2d 3e 77 72 69 74 65 6c 6e 28 24 72 6f 77 43 6f 6e 74 65 6e 74 29 3b 0a 20 20 20 20 7d 0a 0a 20 | ->writeln($rowContent);.....}... |
68720 | 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 6e 64 65 72 73 20 74 61 62 6c 65 20 63 65 6c 6c | .../**......*.Renders.table.cell |
68740 | 20 77 69 74 68 20 70 61 64 64 69 6e 67 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 | .with.padding.......*......*.@pa |
68760 | 72 61 6d 20 61 72 72 61 79 20 20 24 72 6f 77 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 69 6e | ram.array..$row......*.@param.in |
68780 | 74 20 20 20 20 24 63 6f 6c 75 6d 6e 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e | t....$column......*.@param.strin |
687a0 | 67 20 24 63 65 6c 6c 46 6f 72 6d 61 74 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 | g.$cellFormat......*/.....privat |
687c0 | 65 20 66 75 6e 63 74 69 6f 6e 20 72 65 6e 64 65 72 43 65 6c 6c 28 61 72 72 61 79 20 24 72 6f 77 | e.function.renderCell(array.$row |
687e0 | 2c 20 24 63 6f 6c 75 6d 6e 2c 20 24 63 65 6c 6c 46 6f 72 6d 61 74 29 0a 20 20 20 20 7b 0a 20 20 | ,.$column,.$cellFormat).....{... |
68800 | 20 20 20 20 20 20 24 63 65 6c 6c 20 3d 20 69 73 73 65 74 28 24 72 6f 77 5b 24 63 6f 6c 75 6d 6e | ......$cell.=.isset($row[$column |
68820 | 5d 29 20 3f 20 24 72 6f 77 5b 24 63 6f 6c 75 6d 6e 5d 20 3a 20 27 27 3b 0a 20 20 20 20 20 20 20 | ]).?.$row[$column].:.'';........ |
68840 | 20 24 77 69 64 74 68 20 3d 20 24 74 68 69 73 2d 3e 65 66 66 65 63 74 69 76 65 43 6f 6c 75 6d 6e | .$width.=.$this->effectiveColumn |
68860 | 57 69 64 74 68 73 5b 24 63 6f 6c 75 6d 6e 5d 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 63 65 | Widths[$column];.........if.($ce |
68880 | 6c 6c 20 69 6e 73 74 61 6e 63 65 6f 66 20 54 61 62 6c 65 43 65 6c 6c 20 26 26 20 24 63 65 6c 6c | ll.instanceof.TableCell.&&.$cell |
688a0 | 2d 3e 67 65 74 43 6f 6c 73 70 61 6e 28 29 20 3e 20 31 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | ->getColspan().>.1).{........... |
688c0 | 20 20 2f 2f 20 61 64 64 20 74 68 65 20 77 69 64 74 68 20 6f 66 20 74 68 65 20 66 6f 6c 6c 6f 77 | ..//.add.the.width.of.the.follow |
688e0 | 69 6e 67 20 63 6f 6c 75 6d 6e 73 28 6e 75 6d 62 65 72 73 20 6f 66 20 63 6f 6c 73 70 61 6e 29 2e | ing.columns(numbers.of.colspan). |
68900 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 72 61 6e 67 65 28 24 63 6f 6c | .............foreach.(range($col |
68920 | 75 6d 6e 20 2b 20 31 2c 20 24 63 6f 6c 75 6d 6e 20 2b 20 24 63 65 6c 6c 2d 3e 67 65 74 43 6f 6c | umn.+.1,.$column.+.$cell->getCol |
68940 | 73 70 61 6e 28 29 20 2d 20 31 29 20 61 73 20 24 6e 65 78 74 43 6f 6c 75 6d 6e 29 20 7b 0a 20 20 | span().-.1).as.$nextColumn).{... |
68960 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 77 69 64 74 68 20 2b 3d 20 24 74 68 69 73 2d 3e 67 | ..............$width.+=.$this->g |
68980 | 65 74 43 6f 6c 75 6d 6e 53 65 70 61 72 61 74 6f 72 57 69 64 74 68 28 29 20 2b 20 24 74 68 69 73 | etColumnSeparatorWidth().+.$this |
689a0 | 2d 3e 65 66 66 65 63 74 69 76 65 43 6f 6c 75 6d 6e 57 69 64 74 68 73 5b 24 6e 65 78 74 43 6f 6c | ->effectiveColumnWidths[$nextCol |
689c0 | 75 6d 6e 5d 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 | umn];.............}.........}... |
689e0 | 20 20 20 20 20 20 20 2f 2f 20 73 74 72 5f 70 61 64 20 77 6f 6e 27 74 20 77 6f 72 6b 20 70 72 6f | .......//.str_pad.won't.work.pro |
68a00 | 70 65 72 6c 79 20 77 69 74 68 20 6d 75 6c 74 69 2d 62 79 74 65 20 73 74 72 69 6e 67 73 2c 20 77 | perly.with.multi-byte.strings,.w |
68a20 | 65 20 6e 65 65 64 20 74 6f 20 66 69 78 20 74 68 65 20 70 61 64 64 69 6e 67 0a 20 20 20 20 20 20 | e.need.to.fix.the.padding....... |
68a40 | 20 20 69 66 20 28 66 61 6c 73 65 20 21 3d 3d 20 24 65 6e 63 6f 64 69 6e 67 20 3d 20 6d 62 5f 64 | ..if.(false.!==.$encoding.=.mb_d |
68a60 | 65 74 65 63 74 5f 65 6e 63 6f 64 69 6e 67 28 24 63 65 6c 6c 2c 20 6e 75 6c 6c 2c 20 74 72 75 65 | etect_encoding($cell,.null,.true |
68a80 | 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 77 69 64 74 68 20 2b 3d 20 73 74 72 6c 65 | )).{.............$width.+=.strle |
68aa0 | 6e 28 24 63 65 6c 6c 29 20 2d 20 6d 62 5f 73 74 72 77 69 64 74 68 28 24 63 65 6c 6c 2c 20 24 65 | n($cell).-.mb_strwidth($cell,.$e |
68ac0 | 6e 63 6f 64 69 6e 67 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 73 74 | ncoding);.........}..........$st |
68ae0 | 79 6c 65 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 43 6f 6c 75 6d 6e 53 74 79 6c 65 28 24 63 6f 6c | yle.=.$this->getColumnStyle($col |
68b00 | 75 6d 6e 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 63 65 6c 6c 20 69 6e 73 74 61 6e 63 | umn);..........if.($cell.instanc |
68b20 | 65 6f 66 20 54 61 62 6c 65 53 65 70 61 72 61 74 6f 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | eof.TableSeparator).{........... |
68b40 | 20 20 72 65 74 75 72 6e 20 73 70 72 69 6e 74 66 28 24 73 74 79 6c 65 2d 3e 67 65 74 42 6f 72 64 | ..return.sprintf($style->getBord |
68b60 | 65 72 46 6f 72 6d 61 74 28 29 2c 20 73 74 72 5f 72 65 70 65 61 74 28 24 73 74 79 6c 65 2d 3e 67 | erFormat(),.str_repeat($style->g |
68b80 | 65 74 48 6f 72 69 7a 6f 6e 74 61 6c 42 6f 72 64 65 72 43 68 61 72 28 29 2c 20 24 77 69 64 74 68 | etHorizontalBorderChar(),.$width |
68ba0 | 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 77 69 64 74 68 20 2b 3d | ));.........}..........$width.+= |
68bc0 | 20 48 65 6c 70 65 72 3a 3a 73 74 72 6c 65 6e 28 24 63 65 6c 6c 29 20 2d 20 48 65 6c 70 65 72 3a | .Helper::strlen($cell).-.Helper: |
68be0 | 3a 73 74 72 6c 65 6e 57 69 74 68 6f 75 74 44 65 63 6f 72 61 74 69 6f 6e 28 24 74 68 69 73 2d 3e | :strlenWithoutDecoration($this-> |
68c00 | 6f 75 74 70 75 74 2d 3e 67 65 74 46 6f 72 6d 61 74 74 65 72 28 29 2c 20 24 63 65 6c 6c 29 3b 0a | output->getFormatter(),.$cell);. |
68c20 | 20 20 20 20 20 20 20 20 24 63 6f 6e 74 65 6e 74 20 3d 20 73 70 72 69 6e 74 66 28 24 73 74 79 6c | ........$content.=.sprintf($styl |
68c40 | 65 2d 3e 67 65 74 43 65 6c 6c 52 6f 77 43 6f 6e 74 65 6e 74 46 6f 72 6d 61 74 28 29 2c 20 24 63 | e->getCellRowContentFormat(),.$c |
68c60 | 65 6c 6c 29 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 70 72 69 6e 74 66 28 24 63 | ell);..........return.sprintf($c |
68c80 | 65 6c 6c 46 6f 72 6d 61 74 2c 20 73 74 72 5f 70 61 64 28 24 63 6f 6e 74 65 6e 74 2c 20 24 77 69 | ellFormat,.str_pad($content,.$wi |
68ca0 | 64 74 68 2c 20 24 73 74 79 6c 65 2d 3e 67 65 74 50 61 64 64 69 6e 67 43 68 61 72 28 29 2c 20 24 | dth,.$style->getPaddingChar(),.$ |
68cc0 | 73 74 79 6c 65 2d 3e 67 65 74 50 61 64 54 79 70 65 28 29 29 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 | style->getPadType()));.....}.... |
68ce0 | 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 43 61 6c 63 75 6c 61 74 65 20 6e 75 6d 62 65 72 20 6f 66 | ../**......*.Calculate.number.of |
68d00 | 20 63 6f 6c 75 6d 6e 73 20 66 6f 72 20 74 68 69 73 20 74 61 62 6c 65 2e 0a 20 20 20 20 20 2a 2f | .columns.for.this.table.......*/ |
68d20 | 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 63 61 6c 63 75 6c 61 74 65 4e | .....private.function.calculateN |
68d40 | 75 6d 62 65 72 4f 66 43 6f 6c 75 6d 6e 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 | umberOfColumns().....{.........i |
68d60 | 66 20 28 6e 75 6c 6c 20 21 3d 3d 20 24 74 68 69 73 2d 3e 6e 75 6d 62 65 72 4f 66 43 6f 6c 75 6d | f.(null.!==.$this->numberOfColum |
68d80 | 6e 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 3b 0a 20 20 20 20 20 20 | ns).{.............return;....... |
68da0 | 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 63 6f 6c 75 6d 6e 73 20 3d 20 61 72 72 61 79 28 30 29 | ..}..........$columns.=.array(0) |
68dc0 | 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 61 72 72 61 79 5f 6d 65 72 67 65 28 24 | ;.........foreach.(array_merge($ |
68de0 | 74 68 69 73 2d 3e 68 65 61 64 65 72 73 2c 20 24 74 68 69 73 2d 3e 72 6f 77 73 29 20 61 73 20 24 | this->headers,.$this->rows).as.$ |
68e00 | 72 6f 77 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 72 6f 77 20 69 6e 73 74 | row).{.............if.($row.inst |
68e20 | 61 6e 63 65 6f 66 20 54 61 62 6c 65 53 65 70 61 72 61 74 6f 72 29 20 7b 0a 20 20 20 20 20 20 20 | anceof.TableSeparator).{........ |
68e40 | 20 20 20 20 20 20 20 20 20 63 6f 6e 74 69 6e 75 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d | .........continue;.............} |
68e60 | 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6f 6c 75 6d 6e 73 5b 5d 20 3d 20 24 74 68 69 73 | ..............$columns[].=.$this |
68e80 | 2d 3e 67 65 74 4e 75 6d 62 65 72 4f 66 43 6f 6c 75 6d 6e 73 28 24 72 6f 77 29 3b 0a 20 20 20 20 | ->getNumberOfColumns($row);..... |
68ea0 | 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6e 75 6d 62 65 72 4f 66 43 6f | ....}..........$this->numberOfCo |
68ec0 | 6c 75 6d 6e 73 20 3d 20 6d 61 78 28 24 63 6f 6c 75 6d 6e 73 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 | lumns.=.max($columns);.....}.... |
68ee0 | 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 62 75 69 6c 64 54 61 62 6c 65 52 6f 77 | ..private.function.buildTableRow |
68f00 | 73 28 24 72 6f 77 73 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 75 6e 6d 65 72 67 65 64 | s($rows).....{.........$unmerged |
68f20 | 52 6f 77 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 20 28 24 72 6f | Rows.=.array();.........for.($ro |
68f40 | 77 4b 65 79 20 3d 20 30 3b 20 24 72 6f 77 4b 65 79 20 3c 20 63 6f 75 6e 74 28 24 72 6f 77 73 29 | wKey.=.0;.$rowKey.<.count($rows) |
68f60 | 3b 20 2b 2b 24 72 6f 77 4b 65 79 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 72 6f 77 73 | ;.++$rowKey).{.............$rows |
68f80 | 20 3d 20 24 74 68 69 73 2d 3e 66 69 6c 6c 4e 65 78 74 52 6f 77 73 28 24 72 6f 77 73 2c 20 24 72 | .=.$this->fillNextRows($rows,.$r |
68fa0 | 6f 77 4b 65 79 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 52 65 6d 6f 76 65 20 61 | owKey);..............//.Remove.a |
68fc0 | 6e 79 20 6e 65 77 20 6c 69 6e 65 20 62 72 65 61 6b 73 20 61 6e 64 20 72 65 70 6c 61 63 65 20 69 | ny.new.line.breaks.and.replace.i |
68fe0 | 74 20 77 69 74 68 20 61 20 6e 65 77 20 6c 69 6e 65 0a 20 20 20 20 20 20 20 20 20 20 20 20 66 6f | t.with.a.new.line.............fo |
69000 | 72 65 61 63 68 20 28 24 72 6f 77 73 5b 24 72 6f 77 4b 65 79 5d 20 61 73 20 24 63 6f 6c 75 6d 6e | reach.($rows[$rowKey].as.$column |
69020 | 20 3d 3e 20 24 63 65 6c 6c 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 | .=>.$cell).{.................if. |
69040 | 28 21 73 74 72 73 74 72 28 24 63 65 6c 6c 2c 20 22 5c 6e 22 29 29 20 7b 0a 20 20 20 20 20 20 20 | (!strstr($cell,."\n")).{........ |
69060 | 20 20 20 20 20 20 20 20 20 20 20 20 20 63 6f 6e 74 69 6e 75 65 3b 0a 20 20 20 20 20 20 20 20 20 | .............continue;.......... |
69080 | 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 69 6e 65 73 20 | .......}.................$lines. |
690a0 | 3d 20 65 78 70 6c 6f 64 65 28 22 5c 6e 22 2c 20 24 63 65 6c 6c 29 3b 0a 20 20 20 20 20 20 20 20 | =.explode("\n",.$cell);......... |
690c0 | 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 6c 69 6e 65 73 20 61 73 20 24 6c 69 6e 65 | ........foreach.($lines.as.$line |
690e0 | 4b 65 79 20 3d 3e 20 24 6c 69 6e 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | Key.=>.$line).{................. |
69100 | 20 20 20 20 69 66 20 28 24 63 65 6c 6c 20 69 6e 73 74 61 6e 63 65 6f 66 20 54 61 62 6c 65 43 65 | ....if.($cell.instanceof.TableCe |
69120 | 6c 6c 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6c | ll).{.........................$l |
69140 | 69 6e 65 20 3d 20 6e 65 77 20 54 61 62 6c 65 43 65 6c 6c 28 24 6c 69 6e 65 2c 20 61 72 72 61 79 | ine.=.new.TableCell($line,.array |
69160 | 28 27 63 6f 6c 73 70 61 6e 27 20 3d 3e 20 24 63 65 6c 6c 2d 3e 67 65 74 43 6f 6c 73 70 61 6e 28 | ('colspan'.=>.$cell->getColspan( |
69180 | 29 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 | )));.....................}...... |
691a0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 30 20 3d 3d 3d 20 24 6c 69 6e 65 4b 65 | ...............if.(0.===.$lineKe |
691c0 | 79 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 72 6f | y).{.........................$ro |
691e0 | 77 73 5b 24 72 6f 77 4b 65 79 5d 5b 24 63 6f 6c 75 6d 6e 5d 20 3d 20 24 6c 69 6e 65 3b 0a 20 20 | ws[$rowKey][$column].=.$line;... |
69200 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 | ..................}.else.{...... |
69220 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 75 6e 6d 65 72 67 65 64 52 6f 77 73 | ...................$unmergedRows |
69240 | 5b 24 72 6f 77 4b 65 79 5d 5b 24 6c 69 6e 65 4b 65 79 5d 5b 24 63 6f 6c 75 6d 6e 5d 20 3d 20 24 | [$rowKey][$lineKey][$column].=.$ |
69260 | 6c 69 6e 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 | line;.....................}..... |
69280 | 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 | ............}.............}..... |
692a0 | 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 61 62 6c 65 52 6f 77 73 20 3d 20 61 72 72 61 | ....}..........$tableRows.=.arra |
692c0 | 79 28 29 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 72 6f 77 73 20 61 73 20 24 | y();.........foreach.($rows.as.$ |
692e0 | 72 6f 77 4b 65 79 20 3d 3e 20 24 72 6f 77 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 | rowKey.=>.$row).{.............$t |
69300 | 61 62 6c 65 52 6f 77 73 5b 5d 20 3d 20 24 74 68 69 73 2d 3e 66 69 6c 6c 43 65 6c 6c 73 28 24 72 | ableRows[].=.$this->fillCells($r |
69320 | 6f 77 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 69 73 73 65 74 28 24 75 6e 6d 65 | ow);.............if.(isset($unme |
69340 | 72 67 65 64 52 6f 77 73 5b 24 72 6f 77 4b 65 79 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | rgedRows[$rowKey])).{........... |
69360 | 20 20 20 20 20 20 24 74 61 62 6c 65 52 6f 77 73 20 3d 20 61 72 72 61 79 5f 6d 65 72 67 65 28 24 | ......$tableRows.=.array_merge($ |
69380 | 74 61 62 6c 65 52 6f 77 73 2c 20 24 75 6e 6d 65 72 67 65 64 52 6f 77 73 5b 24 72 6f 77 4b 65 79 | tableRows,.$unmergedRows[$rowKey |
693a0 | 5d 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 | ]);.............}.........}..... |
693c0 | 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 61 62 6c 65 52 6f 77 73 3b 0a 20 20 20 20 7d 0a 0a 20 | .....return.$tableRows;.....}... |
693e0 | 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 66 69 6c 6c 20 72 6f 77 73 20 74 68 61 74 20 63 6f 6e | .../**......*.fill.rows.that.con |
69400 | 74 61 69 6e 73 20 72 6f 77 73 70 61 6e 20 3e 20 31 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a | tains.rowspan.>.1.......*......* |
69420 | 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 24 72 6f 77 73 0a 20 20 20 20 20 2a 20 40 70 61 72 61 | .@param.array.$rows......*.@para |
69440 | 6d 20 69 6e 74 20 20 20 24 6c 69 6e 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 | m.int...$line......*......*.@ret |
69460 | 75 72 6e 20 61 72 72 61 79 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 | urn.array......*/.....private.fu |
69480 | 6e 63 74 69 6f 6e 20 66 69 6c 6c 4e 65 78 74 52 6f 77 73 28 24 72 6f 77 73 2c 20 24 6c 69 6e 65 | nction.fillNextRows($rows,.$line |
694a0 | 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 75 6e 6d 65 72 67 65 64 52 6f 77 73 20 3d 20 | ).....{.........$unmergedRows.=. |
694c0 | 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 72 6f 77 73 5b | array();.........foreach.($rows[ |
694e0 | 24 6c 69 6e 65 5d 20 61 73 20 24 63 6f 6c 75 6d 6e 20 3d 3e 20 24 63 65 6c 6c 29 20 7b 0a 20 20 | $line].as.$column.=>.$cell).{... |
69500 | 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 63 65 6c 6c 20 69 6e 73 74 61 6e 63 65 6f 66 20 54 | ..........if.($cell.instanceof.T |
69520 | 61 62 6c 65 43 65 6c 6c 20 26 26 20 24 63 65 6c 6c 2d 3e 67 65 74 52 6f 77 73 70 61 6e 28 29 20 | ableCell.&&.$cell->getRowspan(). |
69540 | 3e 20 31 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6e 62 4c 69 6e 65 73 20 | >.1).{.................$nbLines. |
69560 | 3d 20 24 63 65 6c 6c 2d 3e 67 65 74 52 6f 77 73 70 61 6e 28 29 20 2d 20 31 3b 0a 20 20 20 20 20 | =.$cell->getRowspan().-.1;...... |
69580 | 20 20 20 20 20 20 20 20 20 20 20 24 6c 69 6e 65 73 20 3d 20 61 72 72 61 79 28 24 63 65 6c 6c 29 | ...........$lines.=.array($cell) |
695a0 | 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 73 74 72 73 74 72 28 24 63 65 | ;.................if.(strstr($ce |
695c0 | 6c 6c 2c 20 22 5c 6e 22 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ll,."\n")).{.................... |
695e0 | 20 24 6c 69 6e 65 73 20 3d 20 65 78 70 6c 6f 64 65 28 22 5c 6e 22 2c 20 24 63 65 6c 6c 29 3b 0a | .$lines.=.explode("\n",.$cell);. |
69600 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6e 62 4c 69 6e 65 73 20 3d 20 63 | ....................$nbLines.=.c |
69620 | 6f 75 6e 74 28 24 6c 69 6e 65 73 29 20 3e 20 24 6e 62 4c 69 6e 65 73 20 3f 20 73 75 62 73 74 72 | ount($lines).>.$nbLines.?.substr |
69640 | 5f 63 6f 75 6e 74 28 24 63 65 6c 6c 2c 20 22 5c 6e 22 29 20 3a 20 24 6e 62 4c 69 6e 65 73 3b 0a | _count($cell,."\n").:.$nbLines;. |
69660 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 72 6f 77 73 5b 24 6c 69 6e 65 | .....................$rows[$line |
69680 | 5d 5b 24 63 6f 6c 75 6d 6e 5d 20 3d 20 6e 65 77 20 54 61 62 6c 65 43 65 6c 6c 28 24 6c 69 6e 65 | ][$column].=.new.TableCell($line |
696a0 | 73 5b 30 5d 2c 20 61 72 72 61 79 28 27 63 6f 6c 73 70 61 6e 27 20 3d 3e 20 24 63 65 6c 6c 2d 3e | s[0],.array('colspan'.=>.$cell-> |
696c0 | 67 65 74 43 6f 6c 73 70 61 6e 28 29 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | getColspan()));................. |
696e0 | 20 20 20 20 75 6e 73 65 74 28 24 6c 69 6e 65 73 5b 30 5d 29 3b 0a 20 20 20 20 20 20 20 20 20 20 | ....unset($lines[0]);........... |
69700 | 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 63 72 65 61 | ......}..................//.crea |
69720 | 74 65 20 61 20 74 77 6f 20 64 69 6d 65 6e 73 69 6f 6e 61 6c 20 61 72 72 61 79 20 28 72 6f 77 73 | te.a.two.dimensional.array.(rows |
69740 | 70 61 6e 20 78 20 63 6f 6c 73 70 61 6e 29 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 | pan.x.colspan).................$ |
69760 | 75 6e 6d 65 72 67 65 64 52 6f 77 73 20 3d 20 61 72 72 61 79 5f 72 65 70 6c 61 63 65 5f 72 65 63 | unmergedRows.=.array_replace_rec |
69780 | 75 72 73 69 76 65 28 61 72 72 61 79 5f 66 69 6c 6c 28 24 6c 69 6e 65 20 2b 20 31 2c 20 24 6e 62 | ursive(array_fill($line.+.1,.$nb |
697a0 | 4c 69 6e 65 73 2c 20 61 72 72 61 79 28 29 29 2c 20 24 75 6e 6d 65 72 67 65 64 52 6f 77 73 29 3b | Lines,.array()),.$unmergedRows); |
697c0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 75 6e 6d 65 72 | .................foreach.($unmer |
697e0 | 67 65 64 52 6f 77 73 20 61 73 20 24 75 6e 6d 65 72 67 65 64 52 6f 77 4b 65 79 20 3d 3e 20 24 75 | gedRows.as.$unmergedRowKey.=>.$u |
69800 | 6e 6d 65 72 67 65 64 52 6f 77 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | nmergedRow).{................... |
69820 | 20 20 24 76 61 6c 75 65 20 3d 20 69 73 73 65 74 28 24 6c 69 6e 65 73 5b 24 75 6e 6d 65 72 67 65 | ..$value.=.isset($lines[$unmerge |
69840 | 64 52 6f 77 4b 65 79 20 2d 20 24 6c 69 6e 65 5d 29 20 3f 20 24 6c 69 6e 65 73 5b 24 75 6e 6d 65 | dRowKey.-.$line]).?.$lines[$unme |
69860 | 72 67 65 64 52 6f 77 4b 65 79 20 2d 20 24 6c 69 6e 65 5d 20 3a 20 27 27 3b 0a 20 20 20 20 20 20 | rgedRowKey.-.$line].:.'';....... |
69880 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 75 6e 6d 65 72 67 65 64 52 6f 77 73 5b 24 75 6e 6d | ..............$unmergedRows[$unm |
698a0 | 65 72 67 65 64 52 6f 77 4b 65 79 5d 5b 24 63 6f 6c 75 6d 6e 5d 20 3d 20 6e 65 77 20 54 61 62 6c | ergedRowKey][$column].=.new.Tabl |
698c0 | 65 43 65 6c 6c 28 24 76 61 6c 75 65 2c 20 61 72 72 61 79 28 27 63 6f 6c 73 70 61 6e 27 20 3d 3e | eCell($value,.array('colspan'.=> |
698e0 | 20 24 63 65 6c 6c 2d 3e 67 65 74 43 6f 6c 73 70 61 6e 28 29 29 29 3b 0a 20 20 20 20 20 20 20 20 | .$cell->getColspan()));......... |
69900 | 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 | ........}.............}......... |
69920 | 7d 0a 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 75 6e 6d 65 72 67 65 64 52 6f 77 | }..........foreach.($unmergedRow |
69940 | 73 20 61 73 20 24 75 6e 6d 65 72 67 65 64 52 6f 77 4b 65 79 20 3d 3e 20 24 75 6e 6d 65 72 67 65 | s.as.$unmergedRowKey.=>.$unmerge |
69960 | 64 52 6f 77 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 77 65 20 6e 65 65 64 20 74 | dRow).{.............//.we.need.t |
69980 | 6f 20 6b 6e 6f 77 20 69 66 20 24 75 6e 6d 65 72 67 65 64 52 6f 77 20 77 69 6c 6c 20 62 65 20 6d | o.know.if.$unmergedRow.will.be.m |
699a0 | 65 72 67 65 64 20 6f 72 20 69 6e 73 65 72 74 65 64 20 69 6e 74 6f 20 24 72 6f 77 73 0a 20 20 20 | erged.or.inserted.into.$rows.... |
699c0 | 20 20 20 20 20 20 20 20 20 69 66 20 28 69 73 73 65 74 28 24 72 6f 77 73 5b 24 75 6e 6d 65 72 67 | .........if.(isset($rows[$unmerg |
699e0 | 65 64 52 6f 77 4b 65 79 5d 29 20 26 26 20 69 73 5f 61 72 72 61 79 28 24 72 6f 77 73 5b 24 75 6e | edRowKey]).&&.is_array($rows[$un |
69a00 | 6d 65 72 67 65 64 52 6f 77 4b 65 79 5d 29 20 26 26 20 28 24 74 68 69 73 2d 3e 67 65 74 4e 75 6d | mergedRowKey]).&&.($this->getNum |
69a20 | 62 65 72 4f 66 43 6f 6c 75 6d 6e 73 28 24 72 6f 77 73 5b 24 75 6e 6d 65 72 67 65 64 52 6f 77 4b | berOfColumns($rows[$unmergedRowK |
69a40 | 65 79 5d 29 20 2b 20 24 74 68 69 73 2d 3e 67 65 74 4e 75 6d 62 65 72 4f 66 43 6f 6c 75 6d 6e 73 | ey]).+.$this->getNumberOfColumns |
69a60 | 28 24 75 6e 6d 65 72 67 65 64 52 6f 77 73 5b 24 75 6e 6d 65 72 67 65 64 52 6f 77 4b 65 79 5d 29 | ($unmergedRows[$unmergedRowKey]) |
69a80 | 20 3c 3d 20 24 74 68 69 73 2d 3e 6e 75 6d 62 65 72 4f 66 43 6f 6c 75 6d 6e 73 29 29 20 7b 0a 20 | .<=.$this->numberOfColumns)).{.. |
69aa0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 75 6e 6d 65 72 67 65 | ...............foreach.($unmerge |
69ac0 | 64 52 6f 77 20 61 73 20 24 63 65 6c 6c 4b 65 79 20 3d 3e 20 24 63 65 6c 6c 29 20 7b 0a 20 20 20 | dRow.as.$cellKey.=>.$cell).{.... |
69ae0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 69 6e 73 65 72 74 20 63 65 6c 6c 20 | .................//.insert.cell. |
69b00 | 69 6e 74 6f 20 72 6f 77 20 61 74 20 63 65 6c 6c 4b 65 79 20 70 6f 73 69 74 69 6f 6e 0a 20 20 20 | into.row.at.cellKey.position.... |
69b20 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 61 72 72 61 79 5f 73 70 6c 69 63 65 28 24 72 | .................array_splice($r |
69b40 | 6f 77 73 5b 24 75 6e 6d 65 72 67 65 64 52 6f 77 4b 65 79 5d 2c 20 24 63 65 6c 6c 4b 65 79 2c 20 | ows[$unmergedRowKey],.$cellKey,. |
69b60 | 30 2c 20 61 72 72 61 79 28 24 63 65 6c 6c 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | 0,.array($cell));............... |
69b80 | 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 | ..}.............}.else.{........ |
69ba0 | 20 20 20 20 20 20 20 20 20 24 72 6f 77 20 3d 20 24 74 68 69 73 2d 3e 63 6f 70 79 52 6f 77 28 24 | .........$row.=.$this->copyRow($ |
69bc0 | 72 6f 77 73 2c 20 24 75 6e 6d 65 72 67 65 64 52 6f 77 4b 65 79 20 2d 20 31 29 3b 0a 20 20 20 20 | rows,.$unmergedRowKey.-.1);..... |
69be0 | 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 75 6e 6d 65 72 67 65 64 52 6f | ............foreach.($unmergedRo |
69c00 | 77 20 61 73 20 24 63 6f 6c 75 6d 6e 20 3d 3e 20 24 63 65 6c 6c 29 20 7b 0a 20 20 20 20 20 20 20 | w.as.$column.=>.$cell).{........ |
69c20 | 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 21 65 6d 70 74 79 28 24 63 65 6c 6c 29 29 20 | .............if.(!empty($cell)). |
69c40 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 72 6f 77 5b 24 | {.........................$row[$ |
69c60 | 63 6f 6c 75 6d 6e 5d 20 3d 20 24 75 6e 6d 65 72 67 65 64 52 6f 77 5b 24 63 6f 6c 75 6d 6e 5d 3b | column].=.$unmergedRow[$column]; |
69c80 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 | .....................}.......... |
69ca0 | 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 61 72 72 61 79 5f 73 | .......}.................array_s |
69cc0 | 70 6c 69 63 65 28 24 72 6f 77 73 2c 20 24 75 6e 6d 65 72 67 65 64 52 6f 77 4b 65 79 2c 20 30 2c | plice($rows,.$unmergedRowKey,.0, |
69ce0 | 20 61 72 72 61 79 28 24 72 6f 77 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 | .array($row));.............}.... |
69d00 | 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 72 6f 77 73 3b 0a 20 20 | .....}..........return.$rows;... |
69d20 | 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 66 69 6c 6c 20 63 65 6c 6c 73 20 66 | ..}....../**......*.fill.cells.f |
69d40 | 6f 72 20 61 20 72 6f 77 20 74 68 61 74 20 63 6f 6e 74 61 69 6e 73 20 63 6f 6c 73 70 61 6e 20 3e | or.a.row.that.contains.colspan.> |
69d60 | 20 31 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 24 | .1.......*......*.@param.array.$ |
69d80 | 72 6f 77 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 61 72 72 61 79 0a | row......*......*.@return.array. |
69da0 | 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 66 69 6c | .....*/.....private.function.fil |
69dc0 | 6c 43 65 6c 6c 73 28 24 72 6f 77 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 6e 65 77 52 | lCells($row).....{.........$newR |
69de0 | 6f 77 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 | ow.=.array();.........foreach.($ |
69e00 | 72 6f 77 20 61 73 20 24 63 6f 6c 75 6d 6e 20 3d 3e 20 24 63 65 6c 6c 29 20 7b 0a 20 20 20 20 20 | row.as.$column.=>.$cell).{...... |
69e20 | 20 20 20 20 20 20 20 24 6e 65 77 52 6f 77 5b 5d 20 3d 20 24 63 65 6c 6c 3b 0a 20 20 20 20 20 20 | .......$newRow[].=.$cell;....... |
69e40 | 20 20 20 20 20 20 69 66 20 28 24 63 65 6c 6c 20 69 6e 73 74 61 6e 63 65 6f 66 20 54 61 62 6c 65 | ......if.($cell.instanceof.Table |
69e60 | 43 65 6c 6c 20 26 26 20 24 63 65 6c 6c 2d 3e 67 65 74 43 6f 6c 73 70 61 6e 28 29 20 3e 20 31 29 | Cell.&&.$cell->getColspan().>.1) |
69e80 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 72 61 6e 67 | .{.................foreach.(rang |
69ea0 | 65 28 24 63 6f 6c 75 6d 6e 20 2b 20 31 2c 20 24 63 6f 6c 75 6d 6e 20 2b 20 24 63 65 6c 6c 2d 3e | e($column.+.1,.$column.+.$cell-> |
69ec0 | 67 65 74 43 6f 6c 73 70 61 6e 28 29 20 2d 20 31 29 20 61 73 20 24 70 6f 73 69 74 69 6f 6e 29 20 | getColspan().-.1).as.$position). |
69ee0 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 69 6e 73 65 72 74 20 | {.....................//.insert. |
69f00 | 65 6d 70 74 79 20 76 61 6c 75 65 20 61 74 20 63 6f 6c 75 6d 6e 20 70 6f 73 69 74 69 6f 6e 0a 20 | empty.value.at.column.position.. |
69f20 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6e 65 77 52 6f 77 5b 5d 20 3d 20 27 | ...................$newRow[].=.' |
69f40 | 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 | ';.................}............ |
69f60 | 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 6e 65 | .}.........}..........return.$ne |
69f80 | 77 52 6f 77 20 3f 3a 20 24 72 6f 77 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 | wRow.?:.$row;.....}....../**.... |
69fa0 | 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 24 72 6f 77 73 0a 20 20 20 20 20 2a 20 40 70 | ..*.@param.array.$rows......*.@p |
69fc0 | 61 72 61 6d 20 69 6e 74 20 20 20 24 6c 69 6e 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 | aram.int...$line......*......*.@ |
69fe0 | 72 65 74 75 72 6e 20 61 72 72 61 79 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 | return.array......*/.....private |
6a000 | 20 66 75 6e 63 74 69 6f 6e 20 63 6f 70 79 52 6f 77 28 24 72 6f 77 73 2c 20 24 6c 69 6e 65 29 0a | .function.copyRow($rows,.$line). |
6a020 | 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 72 6f 77 20 3d 20 24 72 6f 77 73 5b 24 6c 69 6e 65 | ....{.........$row.=.$rows[$line |
6a040 | 5d 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 72 6f 77 20 61 73 20 24 63 65 6c | ];.........foreach.($row.as.$cel |
6a060 | 6c 4b 65 79 20 3d 3e 20 24 63 65 6c 6c 56 61 6c 75 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | lKey.=>.$cellValue).{........... |
6a080 | 20 20 24 72 6f 77 5b 24 63 65 6c 6c 4b 65 79 5d 20 3d 20 27 27 3b 0a 20 20 20 20 20 20 20 20 20 | ..$row[$cellKey].=.'';.......... |
6a0a0 | 20 20 20 69 66 20 28 24 63 65 6c 6c 56 61 6c 75 65 20 69 6e 73 74 61 6e 63 65 6f 66 20 54 61 62 | ...if.($cellValue.instanceof.Tab |
6a0c0 | 6c 65 43 65 6c 6c 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 72 6f 77 5b 24 | leCell).{.................$row[$ |
6a0e0 | 63 65 6c 6c 4b 65 79 5d 20 3d 20 6e 65 77 20 54 61 62 6c 65 43 65 6c 6c 28 27 27 2c 20 61 72 72 | cellKey].=.new.TableCell('',.arr |
6a100 | 61 79 28 27 63 6f 6c 73 70 61 6e 27 20 3d 3e 20 24 63 65 6c 6c 56 61 6c 75 65 2d 3e 67 65 74 43 | ay('colspan'.=>.$cellValue->getC |
6a120 | 6f 6c 73 70 61 6e 28 29 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 | olspan()));.............}....... |
6a140 | 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 72 6f 77 3b 0a 20 20 20 20 7d 0a | ..}..........return.$row;.....}. |
6a160 | 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 6e 75 6d 62 65 72 20 6f 66 20 63 | ...../**......*.Gets.number.of.c |
6a180 | 6f 6c 75 6d 6e 73 20 62 79 20 72 6f 77 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 | olumns.by.row.......*......*.@pa |
6a1a0 | 72 61 6d 20 61 72 72 61 79 20 24 72 6f 77 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 | ram.array.$row......*......*.@re |
6a1c0 | 74 75 72 6e 20 69 6e 74 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e | turn.int......*/.....private.fun |
6a1e0 | 63 74 69 6f 6e 20 67 65 74 4e 75 6d 62 65 72 4f 66 43 6f 6c 75 6d 6e 73 28 61 72 72 61 79 20 24 | ction.getNumberOfColumns(array.$ |
6a200 | 72 6f 77 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 63 6f 6c 75 6d 6e 73 20 3d 20 63 6f | row).....{.........$columns.=.co |
6a220 | 75 6e 74 28 24 72 6f 77 29 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 72 6f 77 | unt($row);.........foreach.($row |
6a240 | 20 61 73 20 24 63 6f 6c 75 6d 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6f 6c 75 | .as.$column).{.............$colu |
6a260 | 6d 6e 73 20 2b 3d 20 24 63 6f 6c 75 6d 6e 20 69 6e 73 74 61 6e 63 65 6f 66 20 54 61 62 6c 65 43 | mns.+=.$column.instanceof.TableC |
6a280 | 65 6c 6c 20 3f 20 28 24 63 6f 6c 75 6d 6e 2d 3e 67 65 74 43 6f 6c 73 70 61 6e 28 29 20 2d 20 31 | ell.?.($column->getColspan().-.1 |
6a2a0 | 29 20 3a 20 30 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e | ).:.0;.........}..........return |
6a2c0 | 20 24 63 6f 6c 75 6d 6e 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a | .$columns;.....}....../**......* |
6a2e0 | 20 47 65 74 73 20 6c 69 73 74 20 6f 66 20 63 6f 6c 75 6d 6e 73 20 66 6f 72 20 74 68 65 20 67 69 | .Gets.list.of.columns.for.the.gi |
6a300 | 76 65 6e 20 72 6f 77 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 | ven.row.......*......*.@param.ar |
6a320 | 72 61 79 20 24 72 6f 77 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 61 | ray.$row......*......*.@return.a |
6a340 | 72 72 61 79 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f | rray......*/.....private.functio |
6a360 | 6e 20 67 65 74 52 6f 77 43 6f 6c 75 6d 6e 73 28 24 72 6f 77 29 0a 20 20 20 20 7b 0a 20 20 20 20 | n.getRowColumns($row).....{..... |
6a380 | 20 20 20 20 24 63 6f 6c 75 6d 6e 73 20 3d 20 72 61 6e 67 65 28 30 2c 20 24 74 68 69 73 2d 3e 6e | ....$columns.=.range(0,.$this->n |
6a3a0 | 75 6d 62 65 72 4f 66 43 6f 6c 75 6d 6e 73 20 2d 20 31 29 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 | umberOfColumns.-.1);.........for |
6a3c0 | 65 61 63 68 20 28 24 72 6f 77 20 61 73 20 24 63 65 6c 6c 4b 65 79 20 3d 3e 20 24 63 65 6c 6c 29 | each.($row.as.$cellKey.=>.$cell) |
6a3e0 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 63 65 6c 6c 20 69 6e 73 74 61 6e 63 | .{.............if.($cell.instanc |
6a400 | 65 6f 66 20 54 61 62 6c 65 43 65 6c 6c 20 26 26 20 24 63 65 6c 6c 2d 3e 67 65 74 43 6f 6c 73 70 | eof.TableCell.&&.$cell->getColsp |
6a420 | 61 6e 28 29 20 3e 20 31 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 65 | an().>.1).{.................//.e |
6a440 | 78 63 6c 75 64 65 20 67 72 6f 75 70 65 64 20 63 6f 6c 75 6d 6e 73 2e 0a 20 20 20 20 20 20 20 20 | xclude.grouped.columns.......... |
6a460 | 20 20 20 20 20 20 20 20 24 63 6f 6c 75 6d 6e 73 20 3d 20 61 72 72 61 79 5f 64 69 66 66 28 24 63 | ........$columns.=.array_diff($c |
6a480 | 6f 6c 75 6d 6e 73 2c 20 72 61 6e 67 65 28 24 63 65 6c 6c 4b 65 79 20 2b 20 31 2c 20 24 63 65 6c | olumns,.range($cellKey.+.1,.$cel |
6a4a0 | 6c 4b 65 79 20 2b 20 24 63 65 6c 6c 2d 3e 67 65 74 43 6f 6c 73 70 61 6e 28 29 20 2d 20 31 29 29 | lKey.+.$cell->getColspan().-.1)) |
6a4c0 | 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 | ;.............}.........}....... |
6a4e0 | 20 20 20 72 65 74 75 72 6e 20 24 63 6f 6c 75 6d 6e 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f | ...return.$columns;.....}....../ |
6a500 | 2a 2a 0a 20 20 20 20 20 2a 20 43 61 6c 63 75 6c 61 74 65 73 20 63 6f 6c 75 6d 6e 73 20 77 69 64 | **......*.Calculates.columns.wid |
6a520 | 74 68 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 | ths.......*......*.@param.array. |
6a540 | 24 72 6f 77 73 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 | $rows......*/.....private.functi |
6a560 | 6f 6e 20 63 61 6c 63 75 6c 61 74 65 43 6f 6c 75 6d 6e 73 57 69 64 74 68 28 24 72 6f 77 73 29 0a | on.calculateColumnsWidth($rows). |
6a580 | 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 66 6f 72 20 28 24 63 6f 6c 75 6d 6e 20 3d 20 30 3b 20 | ....{.........for.($column.=.0;. |
6a5a0 | 24 63 6f 6c 75 6d 6e 20 3c 20 24 74 68 69 73 2d 3e 6e 75 6d 62 65 72 4f 66 43 6f 6c 75 6d 6e 73 | $column.<.$this->numberOfColumns |
6a5c0 | 3b 20 2b 2b 24 63 6f 6c 75 6d 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 65 6e 67 | ;.++$column).{.............$leng |
6a5e0 | 74 68 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 | ths.=.array();.............forea |
6a600 | 63 68 20 28 24 72 6f 77 73 20 61 73 20 24 72 6f 77 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | ch.($rows.as.$row).{............ |
6a620 | 20 20 20 20 20 69 66 20 28 24 72 6f 77 20 69 6e 73 74 61 6e 63 65 6f 66 20 54 61 62 6c 65 53 65 | .....if.($row.instanceof.TableSe |
6a640 | 70 61 72 61 74 6f 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 63 | parator).{.....................c |
6a660 | 6f 6e 74 69 6e 75 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 | ontinue;.................}...... |
6a680 | 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 72 6f 77 20 61 73 20 24 69 20 | ............foreach.($row.as.$i. |
6a6a0 | 3d 3e 20 24 63 65 6c 6c 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | =>.$cell).{..................... |
6a6c0 | 69 66 20 28 24 63 65 6c 6c 20 69 6e 73 74 61 6e 63 65 6f 66 20 54 61 62 6c 65 43 65 6c 6c 29 20 | if.($cell.instanceof.TableCell). |
6a6e0 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 65 78 74 4c | {.........................$textL |
6a700 | 65 6e 67 74 68 20 3d 20 73 74 72 6c 65 6e 28 24 63 65 6c 6c 29 3b 0a 20 20 20 20 20 20 20 20 20 | ength.=.strlen($cell);.......... |
6a720 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 74 65 78 74 4c 65 6e 67 74 68 20 3e | ...............if.($textLength.> |
6a740 | 20 30 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | .0).{........................... |
6a760 | 20 20 24 63 6f 6e 74 65 6e 74 43 6f 6c 75 6d 6e 73 20 3d 20 73 74 72 5f 73 70 6c 69 74 28 24 63 | ..$contentColumns.=.str_split($c |
6a780 | 65 6c 6c 2c 20 63 65 69 6c 28 24 74 65 78 74 4c 65 6e 67 74 68 20 2f 20 24 63 65 6c 6c 2d 3e 67 | ell,.ceil($textLength./.$cell->g |
6a7a0 | 65 74 43 6f 6c 73 70 61 6e 28 29 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | etColspan()));.................. |
6a7c0 | 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 63 6f 6e 74 65 6e 74 43 6f 6c 75 | ...........foreach.($contentColu |
6a7e0 | 6d 6e 73 20 61 73 20 24 70 6f 73 69 74 69 6f 6e 20 3d 3e 20 24 63 6f 6e 74 65 6e 74 29 20 7b 0a | mns.as.$position.=>.$content).{. |
6a800 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ................................ |
6a820 | 24 72 6f 77 5b 24 69 20 2b 20 24 70 6f 73 69 74 69 6f 6e 5d 20 3d 20 24 63 6f 6e 74 65 6e 74 3b | $row[$i.+.$position].=.$content; |
6a840 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 | .............................}.. |
6a860 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 | .......................}........ |
6a880 | 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d | .............}.................} |
6a8a0 | 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 65 6e 67 74 68 73 5b 5d 20 3d 20 24 | ..................$lengths[].=.$ |
6a8c0 | 74 68 69 73 2d 3e 67 65 74 43 65 6c 6c 57 69 64 74 68 28 24 72 6f 77 2c 20 24 63 6f 6c 75 6d 6e | this->getCellWidth($row,.$column |
6a8e0 | 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 | );.............}..............$t |
6a900 | 68 69 73 2d 3e 65 66 66 65 63 74 69 76 65 43 6f 6c 75 6d 6e 57 69 64 74 68 73 5b 24 63 6f 6c 75 | his->effectiveColumnWidths[$colu |
6a920 | 6d 6e 5d 20 3d 20 6d 61 78 28 24 6c 65 6e 67 74 68 73 29 20 2b 20 73 74 72 6c 65 6e 28 24 74 68 | mn].=.max($lengths).+.strlen($th |
6a940 | 69 73 2d 3e 73 74 79 6c 65 2d 3e 67 65 74 43 65 6c 6c 52 6f 77 43 6f 6e 74 65 6e 74 46 6f 72 6d | is->style->getCellRowContentForm |
6a960 | 61 74 28 29 29 20 2d 20 32 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 | at()).-.2;.........}.....}...... |
6a980 | 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 63 6f 6c 75 6d 6e 20 77 69 64 74 68 2e 0a 20 20 | /**......*.Gets.column.width.... |
6a9a0 | 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 69 6e 74 0a 20 20 20 20 20 2a 2f 0a | ...*......*.@return.int......*/. |
6a9c0 | 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 43 6f 6c 75 6d 6e 53 65 | ....private.function.getColumnSe |
6a9e0 | 70 61 72 61 74 6f 72 57 69 64 74 68 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 | paratorWidth().....{.........ret |
6aa00 | 75 72 6e 20 73 74 72 6c 65 6e 28 73 70 72 69 6e 74 66 28 24 74 68 69 73 2d 3e 73 74 79 6c 65 2d | urn.strlen(sprintf($this->style- |
6aa20 | 3e 67 65 74 42 6f 72 64 65 72 46 6f 72 6d 61 74 28 29 2c 20 24 74 68 69 73 2d 3e 73 74 79 6c 65 | >getBorderFormat(),.$this->style |
6aa40 | 2d 3e 67 65 74 56 65 72 74 69 63 61 6c 42 6f 72 64 65 72 43 68 61 72 28 29 29 29 3b 0a 20 20 20 | ->getVerticalBorderChar()));.... |
6aa60 | 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 63 65 6c 6c 20 77 69 64 | .}....../**......*.Gets.cell.wid |
6aa80 | 74 68 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 24 | th.......*......*.@param.array.$ |
6aaa0 | 72 6f 77 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 69 6e 74 20 20 20 24 63 6f 6c 75 6d 6e 0a | row......*.@param.int...$column. |
6aac0 | 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 69 6e 74 0a 20 20 20 20 20 2a | .....*......*.@return.int......* |
6aae0 | 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 43 65 6c 6c 57 69 | /.....private.function.getCellWi |
6ab00 | 64 74 68 28 61 72 72 61 79 20 24 72 6f 77 2c 20 24 63 6f 6c 75 6d 6e 29 0a 20 20 20 20 7b 0a 20 | dth(array.$row,.$column).....{.. |
6ab20 | 20 20 20 20 20 20 20 24 63 65 6c 6c 57 69 64 74 68 20 3d 20 30 3b 0a 0a 20 20 20 20 20 20 20 20 | .......$cellWidth.=.0;.......... |
6ab40 | 69 66 20 28 69 73 73 65 74 28 24 72 6f 77 5b 24 63 6f 6c 75 6d 6e 5d 29 29 20 7b 0a 20 20 20 20 | if.(isset($row[$column])).{..... |
6ab60 | 20 20 20 20 20 20 20 20 24 63 65 6c 6c 20 3d 20 24 72 6f 77 5b 24 63 6f 6c 75 6d 6e 5d 3b 0a 20 | ........$cell.=.$row[$column];.. |
6ab80 | 20 20 20 20 20 20 20 20 20 20 20 24 63 65 6c 6c 57 69 64 74 68 20 3d 20 48 65 6c 70 65 72 3a 3a | ...........$cellWidth.=.Helper:: |
6aba0 | 73 74 72 6c 65 6e 57 69 74 68 6f 75 74 44 65 63 6f 72 61 74 69 6f 6e 28 24 74 68 69 73 2d 3e 6f | strlenWithoutDecoration($this->o |
6abc0 | 75 74 70 75 74 2d 3e 67 65 74 46 6f 72 6d 61 74 74 65 72 28 29 2c 20 24 63 65 6c 6c 29 3b 0a 20 | utput->getFormatter(),.$cell);.. |
6abe0 | 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 63 6f 6c 75 6d 6e 57 69 64 74 68 20 3d | .......}..........$columnWidth.= |
6ac00 | 20 69 73 73 65 74 28 24 74 68 69 73 2d 3e 63 6f 6c 75 6d 6e 57 69 64 74 68 73 5b 24 63 6f 6c 75 | .isset($this->columnWidths[$colu |
6ac20 | 6d 6e 5d 29 20 3f 20 24 74 68 69 73 2d 3e 63 6f 6c 75 6d 6e 57 69 64 74 68 73 5b 24 63 6f 6c 75 | mn]).?.$this->columnWidths[$colu |
6ac40 | 6d 6e 5d 20 3a 20 30 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6d 61 78 28 24 63 65 | mn].:.0;..........return.max($ce |
6ac60 | 6c 6c 57 69 64 74 68 2c 20 24 63 6f 6c 75 6d 6e 57 69 64 74 68 29 3b 0a 20 20 20 20 7d 0a 0a 20 | llWidth,.$columnWidth);.....}... |
6ac80 | 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 43 61 6c 6c 65 64 20 61 66 74 65 72 20 72 65 6e 64 65 | .../**......*.Called.after.rende |
6aca0 | 72 69 6e 67 20 74 6f 20 63 6c 65 61 6e 75 70 20 63 61 63 68 65 20 64 61 74 61 2e 0a 20 20 20 20 | ring.to.cleanup.cache.data...... |
6acc0 | 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 63 6c 65 61 6e 75 70 | .*/.....private.function.cleanup |
6ace0 | 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 65 66 66 65 63 74 69 76 | ().....{.........$this->effectiv |
6ad00 | 65 43 6f 6c 75 6d 6e 57 69 64 74 68 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 | eColumnWidths.=.array();........ |
6ad20 | 20 24 74 68 69 73 2d 3e 6e 75 6d 62 65 72 4f 66 43 6f 6c 75 6d 6e 73 20 3d 20 6e 75 6c 6c 3b 0a | .$this->numberOfColumns.=.null;. |
6ad40 | 20 20 20 20 7d 0a 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 | ....}......private.static.functi |
6ad60 | 6f 6e 20 69 6e 69 74 53 74 79 6c 65 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 62 | on.initStyles().....{.........$b |
6ad80 | 6f 72 64 65 72 6c 65 73 73 20 3d 20 6e 65 77 20 54 61 62 6c 65 53 74 79 6c 65 28 29 3b 0a 20 20 | orderless.=.new.TableStyle();... |
6ada0 | 20 20 20 20 20 20 24 62 6f 72 64 65 72 6c 65 73 73 0a 20 20 20 20 20 20 20 20 20 20 20 20 2d 3e | ......$borderless.............-> |
6adc0 | 73 65 74 48 6f 72 69 7a 6f 6e 74 61 6c 42 6f 72 64 65 72 43 68 61 72 28 27 3d 27 29 0a 20 20 20 | setHorizontalBorderChar('=').... |
6ade0 | 20 20 20 20 20 20 20 20 20 2d 3e 73 65 74 56 65 72 74 69 63 61 6c 42 6f 72 64 65 72 43 68 61 72 | .........->setVerticalBorderChar |
6ae00 | 28 27 20 27 29 0a 20 20 20 20 20 20 20 20 20 20 20 20 2d 3e 73 65 74 43 72 6f 73 73 69 6e 67 43 | ('.').............->setCrossingC |
6ae20 | 68 61 72 28 27 20 27 29 0a 20 20 20 20 20 20 20 20 3b 0a 0a 20 20 20 20 20 20 20 20 24 63 6f 6d | har('.').........;..........$com |
6ae40 | 70 61 63 74 20 3d 20 6e 65 77 20 54 61 62 6c 65 53 74 79 6c 65 28 29 3b 0a 20 20 20 20 20 20 20 | pact.=.new.TableStyle();........ |
6ae60 | 20 24 63 6f 6d 70 61 63 74 0a 20 20 20 20 20 20 20 20 20 20 20 20 2d 3e 73 65 74 48 6f 72 69 7a | .$compact.............->setHoriz |
6ae80 | 6f 6e 74 61 6c 42 6f 72 64 65 72 43 68 61 72 28 27 27 29 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ontalBorderChar('')............. |
6aea0 | 2d 3e 73 65 74 56 65 72 74 69 63 61 6c 42 6f 72 64 65 72 43 68 61 72 28 27 20 27 29 0a 20 20 20 | ->setVerticalBorderChar('.').... |
6aec0 | 20 20 20 20 20 20 20 20 20 2d 3e 73 65 74 43 72 6f 73 73 69 6e 67 43 68 61 72 28 27 27 29 0a 20 | .........->setCrossingChar('').. |
6aee0 | 20 20 20 20 20 20 20 20 20 20 20 2d 3e 73 65 74 43 65 6c 6c 52 6f 77 43 6f 6e 74 65 6e 74 46 6f | ...........->setCellRowContentFo |
6af00 | 72 6d 61 74 28 27 25 73 27 29 0a 20 20 20 20 20 20 20 20 3b 0a 0a 20 20 20 20 20 20 20 20 24 73 | rmat('%s').........;..........$s |
6af20 | 74 79 6c 65 47 75 69 64 65 20 3d 20 6e 65 77 20 54 61 62 6c 65 53 74 79 6c 65 28 29 3b 0a 20 20 | tyleGuide.=.new.TableStyle();... |
6af40 | 20 20 20 20 20 20 24 73 74 79 6c 65 47 75 69 64 65 0a 20 20 20 20 20 20 20 20 20 20 20 20 2d 3e | ......$styleGuide.............-> |
6af60 | 73 65 74 48 6f 72 69 7a 6f 6e 74 61 6c 42 6f 72 64 65 72 43 68 61 72 28 27 2d 27 29 0a 20 20 20 | setHorizontalBorderChar('-').... |
6af80 | 20 20 20 20 20 20 20 20 20 2d 3e 73 65 74 56 65 72 74 69 63 61 6c 42 6f 72 64 65 72 43 68 61 72 | .........->setVerticalBorderChar |
6afa0 | 28 27 20 27 29 0a 20 20 20 20 20 20 20 20 20 20 20 20 2d 3e 73 65 74 43 72 6f 73 73 69 6e 67 43 | ('.').............->setCrossingC |
6afc0 | 68 61 72 28 27 20 27 29 0a 20 20 20 20 20 20 20 20 20 20 20 20 2d 3e 73 65 74 43 65 6c 6c 48 65 | har('.').............->setCellHe |
6afe0 | 61 64 65 72 46 6f 72 6d 61 74 28 27 25 73 27 29 0a 20 20 20 20 20 20 20 20 3b 0a 0a 20 20 20 20 | aderFormat('%s').........;...... |
6b000 | 20 20 20 20 72 65 74 75 72 6e 20 61 72 72 61 79 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 64 | ....return.array(.............'d |
6b020 | 65 66 61 75 6c 74 27 20 3d 3e 20 6e 65 77 20 54 61 62 6c 65 53 74 79 6c 65 28 29 2c 0a 20 20 20 | efault'.=>.new.TableStyle(),.... |
6b040 | 20 20 20 20 20 20 20 20 20 27 62 6f 72 64 65 72 6c 65 73 73 27 20 3d 3e 20 24 62 6f 72 64 65 72 | .........'borderless'.=>.$border |
6b060 | 6c 65 73 73 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 63 6f 6d 70 61 63 74 27 20 3d 3e 20 24 | less,.............'compact'.=>.$ |
6b080 | 63 6f 6d 70 61 63 74 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 73 79 6d 66 6f 6e 79 2d 73 74 | compact,.............'symfony-st |
6b0a0 | 79 6c 65 2d 67 75 69 64 65 27 20 3d 3e 20 24 73 74 79 6c 65 47 75 69 64 65 2c 0a 20 20 20 20 20 | yle-guide'.=>.$styleGuide,...... |
6b0c0 | 20 20 20 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f | ...);.....}......private.functio |
6b0e0 | 6e 20 72 65 73 6f 6c 76 65 53 74 79 6c 65 28 24 6e 61 6d 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 | n.resolveStyle($name).....{..... |
6b100 | 20 20 20 20 69 66 20 28 24 6e 61 6d 65 20 69 6e 73 74 61 6e 63 65 6f 66 20 54 61 62 6c 65 53 74 | ....if.($name.instanceof.TableSt |
6b120 | 79 6c 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 6e 61 6d 65 3b | yle).{.............return.$name; |
6b140 | 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 69 73 73 65 74 28 73 65 | .........}..........if.(isset(se |
6b160 | 6c 66 3a 3a 24 73 74 79 6c 65 73 5b 24 6e 61 6d 65 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | lf::$styles[$name])).{.......... |
6b180 | 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 3a 3a 24 73 74 79 6c 65 73 5b 24 6e 61 6d 65 5d 3b 0a | ...return.self::$styles[$name];. |
6b1a0 | 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 | ........}..........throw.new.Inv |
6b1c0 | 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 73 70 72 69 6e 74 66 28 27 53 | alidArgumentException(sprintf('S |
6b1e0 | 74 79 6c 65 20 22 25 73 22 20 69 73 20 6e 6f 74 20 64 65 66 69 6e 65 64 2e 27 2c 20 24 6e 61 6d | tyle."%s".is.not.defined.',.$nam |
6b200 | 65 29 29 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 | e));.....}.}.<?php../*..*.This.f |
6b220 | 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 | ile.is.part.of.the.Symfony.packa |
6b240 | 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c | ge...*..*.(c).Fabien.Potencier.< |
6b260 | 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 | fabien@symfony.com>..*..*.For.th |
6b280 | 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 | e.full.copyright.and.license.inf |
6b2a0 | 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 | ormation,.please.view.the.LICENS |
6b2c0 | 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 | E..*.file.that.was.distributed.w |
6b2e0 | 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 | ith.this.source.code...*/..names |
6b300 | 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 48 | pace.Symfony\Component\Console\H |
6b320 | 65 6c 70 65 72 3b 0a 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f | elper;..use.Symfony\Component\Co |
6b340 | 6e 73 6f 6c 65 5c 45 78 63 65 70 74 69 6f 6e 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 | nsole\Exception\InvalidArgumentE |
6b360 | 78 63 65 70 74 69 6f 6e 3b 0a 0a 2f 2a 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 41 62 64 65 6c 6c | xception;../**..*.@author.Abdell |
6b380 | 61 74 69 66 20 41 69 74 20 62 6f 75 64 61 64 20 3c 61 2e 61 69 74 62 6f 75 64 61 64 40 67 6d 61 | atif.Ait.boudad.<a.aitboudad@gma |
6b3a0 | 69 6c 2e 63 6f 6d 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 54 61 62 6c 65 43 65 6c 6c 0a 7b 0a 20 20 | il.com>..*/.class.TableCell.{... |
6b3c0 | 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 76 61 72 20 73 74 72 69 6e 67 0a 20 20 20 20 20 2a 2f | ../**......*.@var.string......*/ |
6b3e0 | 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 76 61 6c 75 65 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 | .....private.$value;....../**... |
6b400 | 20 20 20 2a 20 40 76 61 72 20 61 72 72 61 79 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 | ...*.@var.array......*/.....priv |
6b420 | 61 74 65 20 24 6f 70 74 69 6f 6e 73 20 3d 20 61 72 72 61 79 28 0a 20 20 20 20 20 20 20 20 27 72 | ate.$options.=.array(.........'r |
6b440 | 6f 77 73 70 61 6e 27 20 3d 3e 20 31 2c 0a 20 20 20 20 20 20 20 20 27 63 6f 6c 73 70 61 6e 27 20 | owspan'.=>.1,.........'colspan'. |
6b460 | 3d 3e 20 31 2c 0a 20 20 20 20 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 70 61 | =>.1,.....);....../**......*.@pa |
6b480 | 72 61 6d 20 73 74 72 69 6e 67 20 24 76 61 6c 75 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 | ram.string.$value......*.@param. |
6b4a0 | 61 72 72 61 79 20 20 24 6f 70 74 69 6f 6e 73 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c | array..$options......*/.....publ |
6b4c0 | 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 74 28 24 76 61 6c 75 65 20 3d | ic.function.__construct($value.= |
6b4e0 | 20 27 27 2c 20 61 72 72 61 79 20 24 6f 70 74 69 6f 6e 73 20 3d 20 61 72 72 61 79 28 29 29 0a 20 | .'',.array.$options.=.array()).. |
6b500 | 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 76 61 6c 75 65 20 3d 20 24 76 61 6c | ...{.........$this->value.=.$val |
6b520 | 75 65 3b 0a 0a 20 20 20 20 20 20 20 20 2f 2f 20 63 68 65 63 6b 20 6f 70 74 69 6f 6e 20 6e 61 6d | ue;..........//.check.option.nam |
6b540 | 65 73 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 64 69 66 66 20 3d 20 61 72 72 61 79 5f 64 69 66 | es.........if.($diff.=.array_dif |
6b560 | 66 28 61 72 72 61 79 5f 6b 65 79 73 28 24 6f 70 74 69 6f 6e 73 29 2c 20 61 72 72 61 79 5f 6b 65 | f(array_keys($options),.array_ke |
6b580 | 79 73 28 24 74 68 69 73 2d 3e 6f 70 74 69 6f 6e 73 29 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | ys($this->options))).{.......... |
6b5a0 | 20 20 20 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 | ...throw.new.InvalidArgumentExce |
6b5c0 | 70 74 69 6f 6e 28 73 70 72 69 6e 74 66 28 27 54 68 65 20 54 61 62 6c 65 43 65 6c 6c 20 64 6f 65 | ption(sprintf('The.TableCell.doe |
6b5e0 | 73 20 6e 6f 74 20 73 75 70 70 6f 72 74 20 74 68 65 20 66 6f 6c 6c 6f 77 69 6e 67 20 6f 70 74 69 | s.not.support.the.following.opti |
6b600 | 6f 6e 73 3a 20 5c 27 25 73 5c 27 2e 27 2c 20 69 6d 70 6c 6f 64 65 28 27 5c 27 2c 20 5c 27 27 2c | ons:.\'%s\'.',.implode('\',.\'', |
6b620 | 20 24 64 69 66 66 29 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 | .$diff)));.........}..........$t |
6b640 | 68 69 73 2d 3e 6f 70 74 69 6f 6e 73 20 3d 20 61 72 72 61 79 5f 6d 65 72 67 65 28 24 74 68 69 73 | his->options.=.array_merge($this |
6b660 | 2d 3e 6f 70 74 69 6f 6e 73 2c 20 24 6f 70 74 69 6f 6e 73 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 | ->options,.$options);.....}..... |
6b680 | 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 74 68 65 20 63 65 6c 6c 20 76 61 6c | ./**......*.Returns.the.cell.val |
6b6a0 | 75 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 | ue.......*......*.@return.string |
6b6c0 | 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 74 | ......*/.....public.function.__t |
6b6e0 | 6f 53 74 72 69 6e 67 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 | oString().....{.........return.$ |
6b700 | 74 68 69 73 2d 3e 76 61 6c 75 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 | this->value;.....}....../**..... |
6b720 | 20 2a 20 47 65 74 73 20 6e 75 6d 62 65 72 20 6f 66 20 63 6f 6c 73 70 61 6e 2e 0a 20 20 20 20 20 | .*.Gets.number.of.colspan....... |
6b740 | 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 69 6e 74 0a 20 20 20 20 20 2a 2f 0a 20 20 20 | *......*.@return.int......*/.... |
6b760 | 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 43 6f 6c 73 70 61 6e 28 29 0a 20 20 | .public.function.getColspan()... |
6b780 | 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 28 69 6e 74 29 20 24 74 68 69 73 2d 3e | ..{.........return.(int).$this-> |
6b7a0 | 6f 70 74 69 6f 6e 73 5b 27 63 6f 6c 73 70 61 6e 27 5d 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f | options['colspan'];.....}....../ |
6b7c0 | 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 6e 75 6d 62 65 72 20 6f 66 20 72 6f 77 73 70 61 6e | **......*.Gets.number.of.rowspan |
6b7e0 | 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 69 6e 74 0a 20 20 20 20 | .......*......*.@return.int..... |
6b800 | 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 52 6f 77 73 70 | .*/.....public.function.getRowsp |
6b820 | 61 6e 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 28 69 6e 74 29 20 | an().....{.........return.(int). |
6b840 | 24 74 68 69 73 2d 3e 6f 70 74 69 6f 6e 73 5b 27 72 6f 77 73 70 61 6e 27 5d 3b 0a 20 20 20 20 7d | $this->options['rowspan'];.....} |
6b860 | 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 | .}.<?php../*..*.This.file.is.par |
6b880 | 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 | t.of.the.Symfony.package...*..*. |
6b8a0 | 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d | (c).Fabien.Potencier.<fabien@sym |
6b8c0 | 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 | fony.com>..*..*.For.the.full.cop |
6b8e0 | 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 | yright.and.license.information,. |
6b900 | 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 | please.view.the.LICENSE..*.file. |
6b920 | 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 | that.was.distributed.with.this.s |
6b940 | 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f | ource.code...*/..namespace.Symfo |
6b960 | 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 48 65 6c 70 65 72 3b 0a 0a 75 73 | ny\Component\Console\Helper;..us |
6b980 | 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 44 65 73 63 | e.Symfony\Component\Console\Desc |
6b9a0 | 72 69 70 74 6f 72 5c 44 65 73 63 72 69 70 74 6f 72 49 6e 74 65 72 66 61 63 65 3b 0a 75 73 65 20 | riptor\DescriptorInterface;.use. |
6b9c0 | 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 44 65 73 63 72 69 | Symfony\Component\Console\Descri |
6b9e0 | 70 74 6f 72 5c 4a 73 6f 6e 44 65 73 63 72 69 70 74 6f 72 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 | ptor\JsonDescriptor;.use.Symfony |
6ba00 | 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 44 65 73 63 72 69 70 74 6f 72 5c 4d 61 | \Component\Console\Descriptor\Ma |
6ba20 | 72 6b 64 6f 77 6e 44 65 73 63 72 69 70 74 6f 72 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f | rkdownDescriptor;.use.Symfony\Co |
6ba40 | 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 44 65 73 63 72 69 70 74 6f 72 5c 54 65 78 74 44 | mponent\Console\Descriptor\TextD |
6ba60 | 65 73 63 72 69 70 74 6f 72 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 | escriptor;.use.Symfony\Component |
6ba80 | 5c 43 6f 6e 73 6f 6c 65 5c 44 65 73 63 72 69 70 74 6f 72 5c 58 6d 6c 44 65 73 63 72 69 70 74 6f | \Console\Descriptor\XmlDescripto |
6baa0 | 72 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 | r;.use.Symfony\Component\Console |
6bac0 | 5c 4f 75 74 70 75 74 5c 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 3b 0a 75 73 65 20 53 79 6d | \Output\OutputInterface;.use.Sym |
6bae0 | 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 78 63 65 70 74 69 6f 6e | fony\Component\Console\Exception |
6bb00 | 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 3b 0a 0a 2f 2a 2a 0a | \InvalidArgumentException;../**. |
6bb20 | 20 2a 20 54 68 69 73 20 63 6c 61 73 73 20 61 64 64 73 20 68 65 6c 70 65 72 20 6d 65 74 68 6f 64 | .*.This.class.adds.helper.method |
6bb40 | 20 74 6f 20 64 65 73 63 72 69 62 65 20 6f 62 6a 65 63 74 73 20 69 6e 20 76 61 72 69 6f 75 73 20 | .to.describe.objects.in.various. |
6bb60 | 66 6f 72 6d 61 74 73 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 4a 65 61 6e 2d 46 72 61 6e | formats...*..*.@author.Jean-Fran |
6bb80 | c3 a7 6f 69 73 20 53 69 6d 6f 6e 20 3c 63 6f 6e 74 61 63 74 40 6a 66 73 69 6d 6f 6e 2e 66 72 3e | ..ois.Simon.<contact@jfsimon.fr> |
6bba0 | 0a 20 2a 2f 0a 63 6c 61 73 73 20 44 65 73 63 72 69 70 74 6f 72 48 65 6c 70 65 72 20 65 78 74 65 | ..*/.class.DescriptorHelper.exte |
6bbc0 | 6e 64 73 20 48 65 6c 70 65 72 0a 7b 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 76 61 72 | nds.Helper.{...../**......*.@var |
6bbe0 | 20 44 65 73 63 72 69 70 74 6f 72 49 6e 74 65 72 66 61 63 65 5b 5d 0a 20 20 20 20 20 2a 2f 0a 20 | .DescriptorInterface[]......*/.. |
6bc00 | 20 20 20 70 72 69 76 61 74 65 20 24 64 65 73 63 72 69 70 74 6f 72 73 20 3d 20 61 72 72 61 79 28 | ...private.$descriptors.=.array( |
6bc20 | 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 43 6f 6e 73 74 72 75 63 74 6f 72 2e 0a | );....../**......*.Constructor.. |
6bc40 | 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 63 6f | .....*/.....public.function.__co |
6bc60 | 6e 73 74 72 75 63 74 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 0a 20 20 | nstruct().....{.........$this... |
6bc80 | 20 20 20 20 20 20 20 20 20 20 2d 3e 72 65 67 69 73 74 65 72 28 27 74 78 74 27 2c 20 6e 65 77 20 | ..........->register('txt',.new. |
6bca0 | 54 65 78 74 44 65 73 63 72 69 70 74 6f 72 28 29 29 0a 20 20 20 20 20 20 20 20 20 20 20 20 2d 3e | TextDescriptor()).............-> |
6bcc0 | 72 65 67 69 73 74 65 72 28 27 78 6d 6c 27 2c 20 6e 65 77 20 58 6d 6c 44 65 73 63 72 69 70 74 6f | register('xml',.new.XmlDescripto |
6bce0 | 72 28 29 29 0a 20 20 20 20 20 20 20 20 20 20 20 20 2d 3e 72 65 67 69 73 74 65 72 28 27 6a 73 6f | r()).............->register('jso |
6bd00 | 6e 27 2c 20 6e 65 77 20 4a 73 6f 6e 44 65 73 63 72 69 70 74 6f 72 28 29 29 0a 20 20 20 20 20 20 | n',.new.JsonDescriptor())....... |
6bd20 | 20 20 20 20 20 20 2d 3e 72 65 67 69 73 74 65 72 28 27 6d 64 27 2c 20 6e 65 77 20 4d 61 72 6b 64 | ......->register('md',.new.Markd |
6bd40 | 6f 77 6e 44 65 73 63 72 69 70 74 6f 72 28 29 29 0a 20 20 20 20 20 20 20 20 3b 0a 20 20 20 20 7d | ownDescriptor()).........;.....} |
6bd60 | 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 44 65 73 63 72 69 62 65 73 20 61 6e 20 6f 62 | ....../**......*.Describes.an.ob |
6bd80 | 6a 65 63 74 20 69 66 20 73 75 70 70 6f 72 74 65 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a | ject.if.supported.......*......* |
6bda0 | 20 41 76 61 69 6c 61 62 6c 65 20 6f 70 74 69 6f 6e 73 20 61 72 65 3a 0a 20 20 20 20 20 2a 20 2a | .Available.options.are:......*.* |
6bdc0 | 20 66 6f 72 6d 61 74 3a 20 73 74 72 69 6e 67 2c 20 74 68 65 20 6f 75 74 70 75 74 20 66 6f 72 6d | .format:.string,.the.output.form |
6bde0 | 61 74 20 6e 61 6d 65 0a 20 20 20 20 20 2a 20 2a 20 72 61 77 5f 74 65 78 74 3a 20 62 6f 6f 6c 65 | at.name......*.*.raw_text:.boole |
6be00 | 61 6e 2c 20 73 65 74 73 20 6f 75 74 70 75 74 20 74 79 70 65 20 61 73 20 72 61 77 0a 20 20 20 20 | an,.sets.output.type.as.raw..... |
6be20 | 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 | .*......*.@param.OutputInterface |
6be40 | 20 24 6f 75 74 70 75 74 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 6f 62 6a 65 63 74 20 20 20 | .$output......*.@param.object... |
6be60 | 20 20 20 20 20 20 20 24 6f 62 6a 65 63 74 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 | .......$object......*.@param.arr |
6be80 | 61 79 20 20 20 20 20 20 20 20 20 20 20 24 6f 70 74 69 6f 6e 73 0a 20 20 20 20 20 2a 0a 20 20 20 | ay...........$options......*.... |
6bea0 | 20 20 2a 20 40 74 68 72 6f 77 73 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 | ..*.@throws.InvalidArgumentExcep |
6bec0 | 74 69 6f 6e 20 77 68 65 6e 20 74 68 65 20 67 69 76 65 6e 20 66 6f 72 6d 61 74 20 69 73 20 6e 6f | tion.when.the.given.format.is.no |
6bee0 | 74 20 73 75 70 70 6f 72 74 65 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 | t.supported......*/.....public.f |
6bf00 | 75 6e 63 74 69 6f 6e 20 64 65 73 63 72 69 62 65 28 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 | unction.describe(OutputInterface |
6bf20 | 20 24 6f 75 74 70 75 74 2c 20 24 6f 62 6a 65 63 74 2c 20 61 72 72 61 79 20 24 6f 70 74 69 6f 6e | .$output,.$object,.array.$option |
6bf40 | 73 20 3d 20 61 72 72 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 6f 70 74 69 | s.=.array()).....{.........$opti |
6bf60 | 6f 6e 73 20 3d 20 61 72 72 61 79 5f 6d 65 72 67 65 28 61 72 72 61 79 28 0a 20 20 20 20 20 20 20 | ons.=.array_merge(array(........ |
6bf80 | 20 20 20 20 20 27 72 61 77 5f 74 65 78 74 27 20 3d 3e 20 66 61 6c 73 65 2c 0a 20 20 20 20 20 20 | .....'raw_text'.=>.false,....... |
6bfa0 | 20 20 20 20 20 20 27 66 6f 72 6d 61 74 27 20 3d 3e 20 27 74 78 74 27 2c 0a 20 20 20 20 20 20 20 | ......'format'.=>.'txt',........ |
6bfc0 | 20 29 2c 20 24 6f 70 74 69 6f 6e 73 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 69 73 73 | .),.$options);..........if.(!iss |
6bfe0 | 65 74 28 24 74 68 69 73 2d 3e 64 65 73 63 72 69 70 74 6f 72 73 5b 24 6f 70 74 69 6f 6e 73 5b 27 | et($this->descriptors[$options[' |
6c000 | 66 6f 72 6d 61 74 27 5d 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 | format']])).{.............throw. |
6c020 | 6e 65 77 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 73 70 72 | new.InvalidArgumentException(spr |
6c040 | 69 6e 74 66 28 27 55 6e 73 75 70 70 6f 72 74 65 64 20 66 6f 72 6d 61 74 20 22 25 73 22 2e 27 2c | intf('Unsupported.format."%s".', |
6c060 | 20 24 6f 70 74 69 6f 6e 73 5b 27 66 6f 72 6d 61 74 27 5d 29 29 3b 0a 20 20 20 20 20 20 20 20 7d | .$options['format']));.........} |
6c080 | 0a 0a 20 20 20 20 20 20 20 20 24 64 65 73 63 72 69 70 74 6f 72 20 3d 20 24 74 68 69 73 2d 3e 64 | ..........$descriptor.=.$this->d |
6c0a0 | 65 73 63 72 69 70 74 6f 72 73 5b 24 6f 70 74 69 6f 6e 73 5b 27 66 6f 72 6d 61 74 27 5d 5d 3b 0a | escriptors[$options['format']];. |
6c0c0 | 20 20 20 20 20 20 20 20 24 64 65 73 63 72 69 70 74 6f 72 2d 3e 64 65 73 63 72 69 62 65 28 24 6f | ........$descriptor->describe($o |
6c0e0 | 75 74 70 75 74 2c 20 24 6f 62 6a 65 63 74 2c 20 24 6f 70 74 69 6f 6e 73 29 3b 0a 20 20 20 20 7d | utput,.$object,.$options);.....} |
6c100 | 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 67 69 73 74 65 72 73 20 61 20 64 65 73 | ....../**......*.Registers.a.des |
6c120 | 63 72 69 70 74 6f 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 | criptor.......*......*.@param.st |
6c140 | 72 69 6e 67 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 66 6f 72 6d 61 74 0a 20 20 20 20 20 2a | ring..............$format......* |
6c160 | 20 40 70 61 72 61 6d 20 44 65 73 63 72 69 70 74 6f 72 49 6e 74 65 72 66 61 63 65 20 24 64 65 73 | .@param.DescriptorInterface.$des |
6c180 | 63 72 69 70 74 6f 72 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 44 65 | criptor......*......*.@return.De |
6c1a0 | 73 63 72 69 70 74 6f 72 48 65 6c 70 65 72 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 | scriptorHelper......*/.....publi |
6c1c0 | 63 20 66 75 6e 63 74 69 6f 6e 20 72 65 67 69 73 74 65 72 28 24 66 6f 72 6d 61 74 2c 20 44 65 73 | c.function.register($format,.Des |
6c1e0 | 63 72 69 70 74 6f 72 49 6e 74 65 72 66 61 63 65 20 24 64 65 73 63 72 69 70 74 6f 72 29 0a 20 20 | criptorInterface.$descriptor)... |
6c200 | 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 64 65 73 63 72 69 70 74 6f 72 73 5b 24 | ..{.........$this->descriptors[$ |
6c220 | 66 6f 72 6d 61 74 5d 20 3d 20 24 64 65 73 63 72 69 70 74 6f 72 3b 0a 0a 20 20 20 20 20 20 20 20 | format].=.$descriptor;.......... |
6c240 | 72 65 74 75 72 6e 20 24 74 68 69 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 | return.$this;.....}....../**.... |
6c260 | 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 | ..*.{@inheritdoc}......*/.....pu |
6c280 | 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 4e 61 6d 65 28 29 0a 20 20 20 20 7b 0a 20 20 | blic.function.getName().....{... |
6c2a0 | 20 20 20 20 20 20 72 65 74 75 72 6e 20 27 64 65 73 63 72 69 70 74 6f 72 27 3b 0a 20 20 20 20 7d | ......return.'descriptor';.....} |
6c2c0 | 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 | .}.<?php../*..*.This.file.is.par |
6c2e0 | 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 | t.of.the.Symfony.package...*..*. |
6c300 | 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d | (c).Fabien.Potencier.<fabien@sym |
6c320 | 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 | fony.com>..*..*.For.the.full.cop |
6c340 | 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 | yright.and.license.information,. |
6c360 | 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 | please.view.the.LICENSE..*.file. |
6c380 | 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 | that.was.distributed.with.this.s |
6c3a0 | 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f | ource.code...*/..namespace.Symfo |
6c3c0 | 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 48 65 6c 70 65 72 3b 0a 0a 2f 2a | ny\Component\Console\Helper;../* |
6c3e0 | 2a 0a 20 2a 20 48 65 6c 70 65 72 49 6e 74 65 72 66 61 63 65 20 69 73 20 74 68 65 20 69 6e 74 65 | *..*.HelperInterface.is.the.inte |
6c400 | 72 66 61 63 65 20 61 6c 6c 20 68 65 6c 70 65 72 73 20 6d 75 73 74 20 69 6d 70 6c 65 6d 65 6e 74 | rface.all.helpers.must.implement |
6c420 | 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 | ...*..*.@author.Fabien.Potencier |
6c440 | 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 2f 0a 69 6e 74 65 72 66 | .<fabien@symfony.com>..*/.interf |
6c460 | 61 63 65 20 48 65 6c 70 65 72 49 6e 74 65 72 66 61 63 65 0a 7b 0a 20 20 20 20 2f 2a 2a 0a 20 20 | ace.HelperInterface.{...../**... |
6c480 | 20 20 20 2a 20 53 65 74 73 20 74 68 65 20 68 65 6c 70 65 72 20 73 65 74 20 61 73 73 6f 63 69 61 | ...*.Sets.the.helper.set.associa |
6c4a0 | 74 65 64 20 77 69 74 68 20 74 68 69 73 20 68 65 6c 70 65 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 | ted.with.this.helper.......*.... |
6c4c0 | 20 20 2a 20 40 70 61 72 61 6d 20 48 65 6c 70 65 72 53 65 74 20 24 68 65 6c 70 65 72 53 65 74 20 | ..*.@param.HelperSet.$helperSet. |
6c4e0 | 41 20 48 65 6c 70 65 72 53 65 74 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 | A.HelperSet.instance......*/.... |
6c500 | 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 48 65 6c 70 65 72 53 65 74 28 48 65 | .public.function.setHelperSet(He |
6c520 | 6c 70 65 72 53 65 74 20 24 68 65 6c 70 65 72 53 65 74 20 3d 20 6e 75 6c 6c 29 3b 0a 0a 20 20 20 | lperSet.$helperSet.=.null);..... |
6c540 | 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 68 65 6c 70 65 72 20 73 65 74 20 | ./**......*.Gets.the.helper.set. |
6c560 | 61 73 73 6f 63 69 61 74 65 64 20 77 69 74 68 20 74 68 69 73 20 68 65 6c 70 65 72 2e 0a 20 20 20 | associated.with.this.helper..... |
6c580 | 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 48 65 6c 70 65 72 53 65 74 20 41 20 48 | ..*......*.@return.HelperSet.A.H |
6c5a0 | 65 6c 70 65 72 53 65 74 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 | elperSet.instance......*/.....pu |
6c5c0 | 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 48 65 6c 70 65 72 53 65 74 28 29 3b 0a 0a 20 | blic.function.getHelperSet();... |
6c5e0 | 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 74 68 65 20 63 61 6e 6f 6e 69 | .../**......*.Returns.the.canoni |
6c600 | 63 61 6c 20 6e 61 6d 65 20 6f 66 20 74 68 69 73 20 68 65 6c 70 65 72 2e 0a 20 20 20 20 20 2a 0a | cal.name.of.this.helper.......*. |
6c620 | 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 20 54 68 65 20 63 61 6e 6f 6e 69 | .....*.@return.string.The.canoni |
6c640 | 63 61 6c 20 6e 61 6d 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 | cal.name......*/.....public.func |
6c660 | 74 69 6f 6e 20 67 65 74 4e 61 6d 65 28 29 3b 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 | tion.getName();.}.<?php../*..*.T |
6c680 | 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 | his.file.is.part.of.the.Symfony. |
6c6a0 | 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 | package...*..*.(c).Fabien.Potenc |
6c6c0 | 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 | ier.<fabien@symfony.com>..*..*.F |
6c6e0 | 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 | or.the.full.copyright.and.licens |
6c700 | 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c | e.information,.please.view.the.L |
6c720 | 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 | ICENSE..*.file.that.was.distribu |
6c740 | 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a | ted.with.this.source.code...*/.. |
6c760 | 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 | namespace.Symfony\Component\Cons |
6c780 | 6f 6c 65 5c 46 6f 72 6d 61 74 74 65 72 3b 0a 0a 2f 2a 2a 0a 20 2a 20 46 6f 72 6d 61 74 74 65 72 | ole\Formatter;../**..*.Formatter |
6c7a0 | 20 73 74 79 6c 65 20 69 6e 74 65 72 66 61 63 65 20 66 6f 72 20 64 65 66 69 6e 69 6e 67 20 73 74 | .style.interface.for.defining.st |
6c7c0 | 79 6c 65 73 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 4b 6f 6e 73 74 61 6e 74 69 6e 20 4b | yles...*..*.@author.Konstantin.K |
6c7e0 | 75 64 72 79 61 73 68 6f 76 20 3c 65 76 65 72 2e 7a 65 74 40 67 6d 61 69 6c 2e 63 6f 6d 3e 0a 20 | udryashov.<ever.zet@gmail.com>.. |
6c800 | 2a 2f 0a 69 6e 74 65 72 66 61 63 65 20 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c | */.interface.OutputFormatterStyl |
6c820 | 65 49 6e 74 65 72 66 61 63 65 0a 7b 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 | eInterface.{...../**......*.Sets |
6c840 | 20 73 74 79 6c 65 20 66 6f 72 65 67 72 6f 75 6e 64 20 63 6f 6c 6f 72 2e 0a 20 20 20 20 20 2a 0a | .style.foreground.color.......*. |
6c860 | 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 63 6f 6c 6f 72 20 54 68 65 20 | .....*.@param.string.$color.The. |
6c880 | 63 6f 6c 6f 72 20 6e 61 6d 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 | color.name......*/.....public.fu |
6c8a0 | 6e 63 74 69 6f 6e 20 73 65 74 46 6f 72 65 67 72 6f 75 6e 64 28 24 63 6f 6c 6f 72 20 3d 20 6e 75 | nction.setForeground($color.=.nu |
6c8c0 | 6c 6c 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 73 74 79 6c 65 20 | ll);....../**......*.Sets.style. |
6c8e0 | 62 61 63 6b 67 72 6f 75 6e 64 20 63 6f 6c 6f 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 | background.color.......*......*. |
6c900 | 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 63 6f 6c 6f 72 20 54 68 65 20 63 6f 6c 6f 72 20 6e | @param.string.$color.The.color.n |
6c920 | 61 6d 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 | ame......*/.....public.function. |
6c940 | 73 65 74 42 61 63 6b 67 72 6f 75 6e 64 28 24 63 6f 6c 6f 72 20 3d 20 6e 75 6c 6c 29 3b 0a 0a 20 | setBackground($color.=.null);... |
6c960 | 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 73 6f 6d 65 20 73 70 65 63 69 66 69 63 | .../**......*.Sets.some.specific |
6c980 | 20 73 74 79 6c 65 20 6f 70 74 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 | .style.option.......*......*.@pa |
6c9a0 | 72 61 6d 20 73 74 72 69 6e 67 20 24 6f 70 74 69 6f 6e 20 54 68 65 20 6f 70 74 69 6f 6e 20 6e 61 | ram.string.$option.The.option.na |
6c9c0 | 6d 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 | me......*/.....public.function.s |
6c9e0 | 65 74 4f 70 74 69 6f 6e 28 24 6f 70 74 69 6f 6e 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 | etOption($option);....../**..... |
6ca00 | 20 2a 20 55 6e 73 65 74 73 20 73 6f 6d 65 20 73 70 65 63 69 66 69 63 20 73 74 79 6c 65 20 6f 70 | .*.Unsets.some.specific.style.op |
6ca20 | 74 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e | tion.......*......*.@param.strin |
6ca40 | 67 20 24 6f 70 74 69 6f 6e 20 54 68 65 20 6f 70 74 69 6f 6e 20 6e 61 6d 65 0a 20 20 20 20 20 2a | g.$option.The.option.name......* |
6ca60 | 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 75 6e 73 65 74 4f 70 74 69 6f | /.....public.function.unsetOptio |
6ca80 | 6e 28 24 6f 70 74 69 6f 6e 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 | n($option);....../**......*.Sets |
6caa0 | 20 6d 75 6c 74 69 70 6c 65 20 73 74 79 6c 65 20 6f 70 74 69 6f 6e 73 20 61 74 20 6f 6e 63 65 2e | .multiple.style.options.at.once. |
6cac0 | 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 24 6f 70 74 | ......*......*.@param.array.$opt |
6cae0 | 69 6f 6e 73 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e | ions......*/.....public.function |
6cb00 | 20 73 65 74 4f 70 74 69 6f 6e 73 28 61 72 72 61 79 20 24 6f 70 74 69 6f 6e 73 29 3b 0a 0a 20 20 | .setOptions(array.$options);.... |
6cb20 | 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 41 70 70 6c 69 65 73 20 74 68 65 20 73 74 79 6c 65 20 74 | ../**......*.Applies.the.style.t |
6cb40 | 6f 20 61 20 67 69 76 65 6e 20 74 65 78 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 | o.a.given.text.......*......*.@p |
6cb60 | 61 72 61 6d 20 73 74 72 69 6e 67 20 24 74 65 78 74 20 54 68 65 20 74 65 78 74 20 74 6f 20 73 74 | aram.string.$text.The.text.to.st |
6cb80 | 79 6c 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 | yle......*......*.@return.string |
6cba0 | 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 61 70 70 | ......*/.....public.function.app |
6cbc0 | 6c 79 28 24 74 65 78 74 29 3b 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 | ly($text);.}.<?php../*..*.This.f |
6cbe0 | 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 | ile.is.part.of.the.Symfony.packa |
6cc00 | 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c | ge...*..*.(c).Fabien.Potencier.< |
6cc20 | 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 | fabien@symfony.com>..*..*.For.th |
6cc40 | 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 | e.full.copyright.and.license.inf |
6cc60 | 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 | ormation,.please.view.the.LICENS |
6cc80 | 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 | E..*.file.that.was.distributed.w |
6cca0 | 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 | ith.this.source.code...*/..names |
6ccc0 | 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 46 | pace.Symfony\Component\Console\F |
6cce0 | 6f 72 6d 61 74 74 65 72 3b 0a 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 | ormatter;..use.Symfony\Component |
6cd00 | 5c 43 6f 6e 73 6f 6c 65 5c 45 78 63 65 70 74 69 6f 6e 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 | \Console\Exception\InvalidArgume |
6cd20 | 6e 74 45 78 63 65 70 74 69 6f 6e 3b 0a 0a 2f 2a 2a 0a 20 2a 20 46 6f 72 6d 61 74 74 65 72 20 63 | ntException;../**..*.Formatter.c |
6cd40 | 6c 61 73 73 20 66 6f 72 20 63 6f 6e 73 6f 6c 65 20 6f 75 74 70 75 74 2e 0a 20 2a 0a 20 2a 20 40 | lass.for.console.output...*..*.@ |
6cd60 | 61 75 74 68 6f 72 20 4b 6f 6e 73 74 61 6e 74 69 6e 20 4b 75 64 72 79 61 73 68 6f 76 20 3c 65 76 | author.Konstantin.Kudryashov.<ev |
6cd80 | 65 72 2e 7a 65 74 40 67 6d 61 69 6c 2e 63 6f 6d 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 4f 75 74 70 | er.zet@gmail.com>..*/.class.Outp |
6cda0 | 75 74 46 6f 72 6d 61 74 74 65 72 20 69 6d 70 6c 65 6d 65 6e 74 73 20 4f 75 74 70 75 74 46 6f 72 | utFormatter.implements.OutputFor |
6cdc0 | 6d 61 74 74 65 72 49 6e 74 65 72 66 61 63 65 0a 7b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 64 | matterInterface.{.....private.$d |
6cde0 | 65 63 6f 72 61 74 65 64 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 73 74 79 6c 65 73 20 3d 20 | ecorated;.....private.$styles.=. |
6ce00 | 61 72 72 61 79 28 29 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 73 74 79 6c 65 53 74 61 63 6b | array();.....private.$styleStack |
6ce20 | 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 45 73 63 61 70 65 73 20 22 3c 22 20 73 70 | ;....../**......*.Escapes."<".sp |
6ce40 | 65 63 69 61 6c 20 63 68 61 72 20 69 6e 20 67 69 76 65 6e 20 74 65 78 74 2e 0a 20 20 20 20 20 2a | ecial.char.in.given.text.......* |
6ce60 | 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 74 65 78 74 20 54 65 78 74 | ......*.@param.string.$text.Text |
6ce80 | 20 74 6f 20 65 73 63 61 70 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e | .to.escape......*......*.@return |
6cea0 | 20 73 74 72 69 6e 67 20 45 73 63 61 70 65 64 20 74 65 78 74 0a 20 20 20 20 20 2a 2f 0a 20 20 20 | .string.Escaped.text......*/.... |
6cec0 | 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 65 73 63 61 70 65 28 24 | .public.static.function.escape($ |
6cee0 | 74 65 78 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 65 78 74 20 3d 20 70 72 65 67 | text).....{.........$text.=.preg |
6cf00 | 5f 72 65 70 6c 61 63 65 28 27 2f 28 5b 5e 5c 5c 5c 5c 5d 3f 29 3c 2f 27 2c 20 27 24 31 5c 5c 3c | _replace('/([^\\\\]?)</',.'$1\\< |
6cf20 | 27 2c 20 24 74 65 78 74 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 27 5c 5c 27 20 3d 3d 3d | ',.$text);..........if.('\\'.=== |
6cf40 | 20 73 75 62 73 74 72 28 24 74 65 78 74 2c 20 2d 31 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | .substr($text,.-1)).{........... |
6cf60 | 20 20 24 6c 65 6e 20 3d 20 73 74 72 6c 65 6e 28 24 74 65 78 74 29 3b 0a 20 20 20 20 20 20 20 20 | ..$len.=.strlen($text);......... |
6cf80 | 20 20 20 20 24 74 65 78 74 20 3d 20 72 74 72 69 6d 28 24 74 65 78 74 2c 20 27 5c 5c 27 29 3b 0a | ....$text.=.rtrim($text,.'\\');. |
6cfa0 | 20 20 20 20 20 20 20 20 20 20 20 20 24 74 65 78 74 20 2e 3d 20 73 74 72 5f 72 65 70 65 61 74 28 | ............$text..=.str_repeat( |
6cfc0 | 27 3c 3c 27 2c 20 24 6c 65 6e 20 2d 20 73 74 72 6c 65 6e 28 24 74 65 78 74 29 29 3b 0a 20 20 20 | '<<',.$len.-.strlen($text));.... |
6cfe0 | 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 65 78 74 3b 0a 20 20 | .....}..........return.$text;... |
6d000 | 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 49 6e 69 74 69 61 6c 69 7a 65 73 20 | ..}....../**......*.Initializes. |
6d020 | 63 6f 6e 73 6f 6c 65 20 6f 75 74 70 75 74 20 66 6f 72 6d 61 74 74 65 72 2e 0a 20 20 20 20 20 2a | console.output.formatter.......* |
6d040 | 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 62 6f 6f 6c 20 20 20 20 20 20 20 20 20 20 20 20 20 | ......*.@param.bool............. |
6d060 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 64 65 63 6f 72 61 74 65 64 20 57 68 65 74 68 65 | ...............$decorated.Whethe |
6d080 | 72 20 74 68 69 73 20 66 6f 72 6d 61 74 74 65 72 20 73 68 6f 75 6c 64 20 61 63 74 75 61 6c 6c 79 | r.this.formatter.should.actually |
6d0a0 | 20 64 65 63 6f 72 61 74 65 20 73 74 72 69 6e 67 73 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 | .decorate.strings......*.@param. |
6d0c0 | 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c 65 49 6e 74 65 72 66 61 63 65 5b 5d 20 | OutputFormatterStyleInterface[]. |
6d0e0 | 24 73 74 79 6c 65 73 20 20 20 20 41 72 72 61 79 20 6f 66 20 22 6e 61 6d 65 20 3d 3e 20 46 6f 72 | $styles....Array.of."name.=>.For |
6d100 | 6d 61 74 74 65 72 53 74 79 6c 65 22 20 69 6e 73 74 61 6e 63 65 73 0a 20 20 20 20 20 2a 2f 0a 20 | matterStyle".instances......*/.. |
6d120 | 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 74 28 24 | ...public.function.__construct($ |
6d140 | 64 65 63 6f 72 61 74 65 64 20 3d 20 66 61 6c 73 65 2c 20 61 72 72 61 79 20 24 73 74 79 6c 65 73 | decorated.=.false,.array.$styles |
6d160 | 20 3d 20 61 72 72 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d | .=.array()).....{.........$this- |
6d180 | 3e 64 65 63 6f 72 61 74 65 64 20 3d 20 28 62 6f 6f 6c 29 20 24 64 65 63 6f 72 61 74 65 64 3b 0a | >decorated.=.(bool).$decorated;. |
6d1a0 | 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 65 74 53 74 79 6c 65 28 27 65 72 72 6f 72 27 | .........$this->setStyle('error' |
6d1c0 | 2c 20 6e 65 77 20 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c 65 28 27 77 68 69 74 | ,.new.OutputFormatterStyle('whit |
6d1e0 | 65 27 2c 20 27 72 65 64 27 29 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 65 74 53 | e',.'red'));.........$this->setS |
6d200 | 74 79 6c 65 28 27 69 6e 66 6f 27 2c 20 6e 65 77 20 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 | tyle('info',.new.OutputFormatter |
6d220 | 53 74 79 6c 65 28 27 67 72 65 65 6e 27 29 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e | Style('green'));.........$this-> |
6d240 | 73 65 74 53 74 79 6c 65 28 27 63 6f 6d 6d 65 6e 74 27 2c 20 6e 65 77 20 4f 75 74 70 75 74 46 6f | setStyle('comment',.new.OutputFo |
6d260 | 72 6d 61 74 74 65 72 53 74 79 6c 65 28 27 79 65 6c 6c 6f 77 27 29 29 3b 0a 20 20 20 20 20 20 20 | rmatterStyle('yellow'));........ |
6d280 | 20 24 74 68 69 73 2d 3e 73 65 74 53 74 79 6c 65 28 27 71 75 65 73 74 69 6f 6e 27 2c 20 6e 65 77 | .$this->setStyle('question',.new |
6d2a0 | 20 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c 65 28 27 62 6c 61 63 6b 27 2c 20 27 | .OutputFormatterStyle('black',.' |
6d2c0 | 63 79 61 6e 27 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 73 74 79 6c | cyan'));..........foreach.($styl |
6d2e0 | 65 73 20 61 73 20 24 6e 61 6d 65 20 3d 3e 20 24 73 74 79 6c 65 29 20 7b 0a 20 20 20 20 20 20 20 | es.as.$name.=>.$style).{........ |
6d300 | 20 20 20 20 20 24 74 68 69 73 2d 3e 73 65 74 53 74 79 6c 65 28 24 6e 61 6d 65 2c 20 24 73 74 79 | .....$this->setStyle($name,.$sty |
6d320 | 6c 65 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 | le);.........}..........$this->s |
6d340 | 74 79 6c 65 53 74 61 63 6b 20 3d 20 6e 65 77 20 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 53 | tyleStack.=.new.OutputFormatterS |
6d360 | 74 79 6c 65 53 74 61 63 6b 28 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 | tyleStack();.....}....../**..... |
6d380 | 20 2a 20 53 65 74 73 20 74 68 65 20 64 65 63 6f 72 61 74 65 64 20 66 6c 61 67 2e 0a 20 20 20 20 | .*.Sets.the.decorated.flag...... |
6d3a0 | 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 62 6f 6f 6c 20 24 64 65 63 6f 72 61 74 65 64 | .*......*.@param.bool.$decorated |
6d3c0 | 20 57 68 65 74 68 65 72 20 74 6f 20 64 65 63 6f 72 61 74 65 20 74 68 65 20 6d 65 73 73 61 67 65 | .Whether.to.decorate.the.message |
6d3e0 | 73 20 6f 72 20 6e 6f 74 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 | s.or.not......*/.....public.func |
6d400 | 74 69 6f 6e 20 73 65 74 44 65 63 6f 72 61 74 65 64 28 24 64 65 63 6f 72 61 74 65 64 29 0a 20 20 | tion.setDecorated($decorated)... |
6d420 | 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 64 65 63 6f 72 61 74 65 64 20 3d 20 28 | ..{.........$this->decorated.=.( |
6d440 | 62 6f 6f 6c 29 20 24 64 65 63 6f 72 61 74 65 64 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a | bool).$decorated;.....}....../** |
6d460 | 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 64 65 63 6f 72 61 74 65 64 20 66 6c 61 67 2e | ......*.Gets.the.decorated.flag. |
6d480 | 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 62 6f 6f 6c 20 74 72 75 65 | ......*......*.@return.bool.true |
6d4a0 | 20 69 66 20 74 68 65 20 6f 75 74 70 75 74 20 77 69 6c 6c 20 64 65 63 6f 72 61 74 65 20 6d 65 73 | .if.the.output.will.decorate.mes |
6d4c0 | 73 61 67 65 73 2c 20 66 61 6c 73 65 20 6f 74 68 65 72 77 69 73 65 0a 20 20 20 20 20 2a 2f 0a 20 | sages,.false.otherwise......*/.. |
6d4e0 | 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 69 73 44 65 63 6f 72 61 74 65 64 28 29 | ...public.function.isDecorated() |
6d500 | 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 64 65 63 | .....{.........return.$this->dec |
6d520 | 6f 72 61 74 65 64 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 | orated;.....}....../**......*.Se |
6d540 | 74 73 20 61 20 6e 65 77 20 73 74 79 6c 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 | ts.a.new.style.......*......*.@p |
6d560 | 61 72 61 6d 20 73 74 72 69 6e 67 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | aram.string..................... |
6d580 | 20 20 20 24 6e 61 6d 65 20 20 54 68 65 20 73 74 79 6c 65 20 6e 61 6d 65 0a 20 20 20 20 20 2a 20 | ...$name..The.style.name......*. |
6d5a0 | 40 70 61 72 61 6d 20 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c 65 49 6e 74 65 72 | @param.OutputFormatterStyleInter |
6d5c0 | 66 61 63 65 20 24 73 74 79 6c 65 20 54 68 65 20 73 74 79 6c 65 20 69 6e 73 74 61 6e 63 65 0a 20 | face.$style.The.style.instance.. |
6d5e0 | 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 53 74 | ....*/.....public.function.setSt |
6d600 | 79 6c 65 28 24 6e 61 6d 65 2c 20 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c 65 49 | yle($name,.OutputFormatterStyleI |
6d620 | 6e 74 65 72 66 61 63 65 20 24 73 74 79 6c 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 | nterface.$style).....{.........$ |
6d640 | 74 68 69 73 2d 3e 73 74 79 6c 65 73 5b 73 74 72 74 6f 6c 6f 77 65 72 28 24 6e 61 6d 65 29 5d 20 | this->styles[strtolower($name)]. |
6d660 | 3d 20 24 73 74 79 6c 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 | =.$style;.....}....../**......*. |
6d680 | 43 68 65 63 6b 73 20 69 66 20 6f 75 74 70 75 74 20 66 6f 72 6d 61 74 74 65 72 20 68 61 73 20 73 | Checks.if.output.formatter.has.s |
6d6a0 | 74 79 6c 65 20 77 69 74 68 20 73 70 65 63 69 66 69 65 64 20 6e 61 6d 65 2e 0a 20 20 20 20 20 2a | tyle.with.specified.name.......* |
6d6c0 | 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6e 61 6d 65 0a 20 20 20 20 | ......*.@param.string.$name..... |
6d6e0 | 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 62 6f 6f 6c 0a 20 20 20 20 20 2a 2f 0a 20 | .*......*.@return.bool......*/.. |
6d700 | 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 68 61 73 53 74 79 6c 65 28 24 6e 61 6d | ...public.function.hasStyle($nam |
6d720 | 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 69 73 73 65 74 28 24 74 | e).....{.........return.isset($t |
6d740 | 68 69 73 2d 3e 73 74 79 6c 65 73 5b 73 74 72 74 6f 6c 6f 77 65 72 28 24 6e 61 6d 65 29 5d 29 3b | his->styles[strtolower($name)]); |
6d760 | 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 73 74 79 6c | .....}....../**......*.Gets.styl |
6d780 | 65 20 6f 70 74 69 6f 6e 73 20 66 72 6f 6d 20 73 74 79 6c 65 20 77 69 74 68 20 73 70 65 63 69 66 | e.options.from.style.with.specif |
6d7a0 | 69 65 64 20 6e 61 6d 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 | ied.name.......*......*.@param.s |
6d7c0 | 74 72 69 6e 67 20 24 6e 61 6d 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 | tring.$name......*......*.@retur |
6d7e0 | 6e 20 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c 65 49 6e 74 65 72 66 61 63 65 0a | n.OutputFormatterStyleInterface. |
6d800 | 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 49 6e 76 61 6c 69 64 41 72 67 | .....*......*.@throws.InvalidArg |
6d820 | 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 20 57 68 65 6e 20 73 74 79 6c 65 20 69 73 6e 27 74 20 | umentException.When.style.isn't. |
6d840 | 64 65 66 69 6e 65 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 | defined......*/.....public.funct |
6d860 | 69 6f 6e 20 67 65 74 53 74 79 6c 65 28 24 6e 61 6d 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 | ion.getStyle($name).....{....... |
6d880 | 20 20 69 66 20 28 21 24 74 68 69 73 2d 3e 68 61 73 53 74 79 6c 65 28 24 6e 61 6d 65 29 29 20 7b | ..if.(!$this->hasStyle($name)).{ |
6d8a0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 61 6c 69 64 41 72 | .............throw.new.InvalidAr |
6d8c0 | 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 73 70 72 69 6e 74 66 28 27 55 6e 64 65 66 69 6e | gumentException(sprintf('Undefin |
6d8e0 | 65 64 20 73 74 79 6c 65 3a 20 25 73 27 2c 20 24 6e 61 6d 65 29 29 3b 0a 20 20 20 20 20 20 20 20 | ed.style:.%s',.$name));......... |
6d900 | 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 73 74 79 6c 65 73 5b | }..........return.$this->styles[ |
6d920 | 73 74 72 74 6f 6c 6f 77 65 72 28 24 6e 61 6d 65 29 5d 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f | strtolower($name)];.....}....../ |
6d940 | 2a 2a 0a 20 20 20 20 20 2a 20 46 6f 72 6d 61 74 73 20 61 20 6d 65 73 73 61 67 65 20 61 63 63 6f | **......*.Formats.a.message.acco |
6d960 | 72 64 69 6e 67 20 74 6f 20 74 68 65 20 67 69 76 65 6e 20 73 74 79 6c 65 73 2e 0a 20 20 20 20 20 | rding.to.the.given.styles....... |
6d980 | 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6d 65 73 73 61 67 65 20 | *......*.@param.string.$message. |
6d9a0 | 54 68 65 20 6d 65 73 73 61 67 65 20 74 6f 20 73 74 79 6c 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 | The.message.to.style......*..... |
6d9c0 | 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 20 54 68 65 20 73 74 79 6c 65 64 20 6d 65 73 | .*.@return.string.The.styled.mes |
6d9e0 | 73 61 67 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e | sage......*/.....public.function |
6da00 | 20 66 6f 72 6d 61 74 28 24 6d 65 73 73 61 67 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | .format($message).....{......... |
6da20 | 24 6d 65 73 73 61 67 65 20 3d 20 28 73 74 72 69 6e 67 29 20 24 6d 65 73 73 61 67 65 3b 0a 20 20 | $message.=.(string).$message;... |
6da40 | 20 20 20 20 20 20 24 6f 66 66 73 65 74 20 3d 20 30 3b 0a 20 20 20 20 20 20 20 20 24 6f 75 74 70 | ......$offset.=.0;.........$outp |
6da60 | 75 74 20 3d 20 27 27 3b 0a 20 20 20 20 20 20 20 20 24 74 61 67 52 65 67 65 78 20 3d 20 27 5b 61 | ut.=.'';.........$tagRegex.=.'[a |
6da80 | 2d 7a 5d 5b 61 2d 7a 30 2d 39 5f 3d 3b 2d 5d 2a 2b 27 3b 0a 20 20 20 20 20 20 20 20 70 72 65 67 | -z][a-z0-9_=;-]*+';.........preg |
6daa0 | 5f 6d 61 74 63 68 5f 61 6c 6c 28 22 23 3c 28 28 24 74 61 67 52 65 67 65 78 29 20 7c 20 2f 28 24 | _match_all("#<(($tagRegex).|./($ |
6dac0 | 74 61 67 52 65 67 65 78 29 3f 29 3e 23 69 78 22 2c 20 24 6d 65 73 73 61 67 65 2c 20 24 6d 61 74 | tagRegex)?)>#ix",.$message,.$mat |
6dae0 | 63 68 65 73 2c 20 50 52 45 47 5f 4f 46 46 53 45 54 5f 43 41 50 54 55 52 45 29 3b 0a 20 20 20 20 | ches,.PREG_OFFSET_CAPTURE);..... |
6db00 | 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 6d 61 74 63 68 65 73 5b 30 5d 20 61 73 20 24 69 20 3d | ....foreach.($matches[0].as.$i.= |
6db20 | 3e 20 24 6d 61 74 63 68 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 70 6f 73 20 3d 20 24 | >.$match).{.............$pos.=.$ |
6db40 | 6d 61 74 63 68 5b 31 5d 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 65 78 74 20 3d 20 24 6d | match[1];.............$text.=.$m |
6db60 | 61 74 63 68 5b 30 5d 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 30 20 21 3d 20 24 | atch[0];..............if.(0.!=.$ |
6db80 | 70 6f 73 20 26 26 20 27 5c 5c 27 20 3d 3d 20 24 6d 65 73 73 61 67 65 5b 24 70 6f 73 20 2d 20 31 | pos.&&.'\\'.==.$message[$pos.-.1 |
6dba0 | 5d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 63 6f 6e 74 69 6e 75 65 3b 0a 20 | ]).{.................continue;.. |
6dbc0 | 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 61 64 64 | ...........}..............//.add |
6dbe0 | 20 74 68 65 20 74 65 78 74 20 75 70 20 74 6f 20 74 68 65 20 6e 65 78 74 20 74 61 67 0a 20 20 20 | .the.text.up.to.the.next.tag.... |
6dc00 | 20 20 20 20 20 20 20 20 20 24 6f 75 74 70 75 74 20 2e 3d 20 24 74 68 69 73 2d 3e 61 70 70 6c 79 | .........$output..=.$this->apply |
6dc20 | 43 75 72 72 65 6e 74 53 74 79 6c 65 28 73 75 62 73 74 72 28 24 6d 65 73 73 61 67 65 2c 20 24 6f | CurrentStyle(substr($message,.$o |
6dc40 | 66 66 73 65 74 2c 20 24 70 6f 73 20 2d 20 24 6f 66 66 73 65 74 29 29 3b 0a 20 20 20 20 20 20 20 | ffset,.$pos.-.$offset));........ |
6dc60 | 20 20 20 20 20 24 6f 66 66 73 65 74 20 3d 20 24 70 6f 73 20 2b 20 73 74 72 6c 65 6e 28 24 74 65 | .....$offset.=.$pos.+.strlen($te |
6dc80 | 78 74 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 6f 70 65 6e 69 6e 67 20 74 61 67 | xt);..............//.opening.tag |
6dca0 | 3f 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 6f 70 65 6e 20 3d 20 27 2f 27 20 21 3d | ?.............if.($open.=.'/'.!= |
6dcc0 | 20 24 74 65 78 74 5b 31 5d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 61 | .$text[1]).{.................$ta |
6dce0 | 67 20 3d 20 24 6d 61 74 63 68 65 73 5b 31 5d 5b 24 69 5d 5b 30 5d 3b 0a 20 20 20 20 20 20 20 20 | g.=.$matches[1][$i][0];......... |
6dd00 | 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 61 | ....}.else.{.................$ta |
6dd20 | 67 20 3d 20 69 73 73 65 74 28 24 6d 61 74 63 68 65 73 5b 33 5d 5b 24 69 5d 5b 30 5d 29 20 3f 20 | g.=.isset($matches[3][$i][0]).?. |
6dd40 | 24 6d 61 74 63 68 65 73 5b 33 5d 5b 24 69 5d 5b 30 5d 20 3a 20 27 27 3b 0a 20 20 20 20 20 20 20 | $matches[3][$i][0].:.'';........ |
6dd60 | 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 21 24 6f 70 65 6e 20 26 | .....}..............if.(!$open.& |
6dd80 | 26 20 21 24 74 61 67 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 3c 2f | &.!$tag).{.................//.</ |
6dda0 | 3e 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 74 79 6c 65 53 74 | >.................$this->styleSt |
6ddc0 | 61 63 6b 2d 3e 70 6f 70 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 | ack->pop();.............}.elseif |
6dde0 | 20 28 66 61 6c 73 65 20 3d 3d 3d 20 24 73 74 79 6c 65 20 3d 20 24 74 68 69 73 2d 3e 63 72 65 61 | .(false.===.$style.=.$this->crea |
6de00 | 74 65 53 74 79 6c 65 46 72 6f 6d 53 74 72 69 6e 67 28 73 74 72 74 6f 6c 6f 77 65 72 28 24 74 61 | teStyleFromString(strtolower($ta |
6de20 | 67 29 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 75 74 70 75 74 20 2e | g))).{.................$output.. |
6de40 | 3d 20 24 74 68 69 73 2d 3e 61 70 70 6c 79 43 75 72 72 65 6e 74 53 74 79 6c 65 28 24 74 65 78 74 | =.$this->applyCurrentStyle($text |
6de60 | 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 24 6f 70 65 6e 29 20 | );.............}.elseif.($open). |
6de80 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 74 79 6c 65 53 74 | {.................$this->styleSt |
6dea0 | 61 63 6b 2d 3e 70 75 73 68 28 24 73 74 79 6c 65 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d | ack->push($style);.............} |
6dec0 | 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 | .else.{.................$this->s |
6dee0 | 74 79 6c 65 53 74 61 63 6b 2d 3e 70 6f 70 28 24 73 74 79 6c 65 29 3b 0a 20 20 20 20 20 20 20 20 | tyleStack->pop($style);......... |
6df00 | 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 6f 75 74 70 75 74 | ....}.........}..........$output |
6df20 | 20 2e 3d 20 24 74 68 69 73 2d 3e 61 70 70 6c 79 43 75 72 72 65 6e 74 53 74 79 6c 65 28 73 75 62 | ..=.$this->applyCurrentStyle(sub |
6df40 | 73 74 72 28 24 6d 65 73 73 61 67 65 2c 20 24 6f 66 66 73 65 74 29 29 3b 0a 0a 20 20 20 20 20 20 | str($message,.$offset));........ |
6df60 | 20 20 69 66 20 28 66 61 6c 73 65 20 21 3d 3d 20 73 74 72 70 6f 73 28 24 6f 75 74 70 75 74 2c 20 | ..if.(false.!==.strpos($output,. |
6df80 | 27 3c 3c 27 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 74 72 74 | '<<')).{.............return.strt |
6dfa0 | 72 28 24 6f 75 74 70 75 74 2c 20 61 72 72 61 79 28 27 5c 5c 3c 27 20 3d 3e 20 27 3c 27 2c 20 27 | r($output,.array('\\<'.=>.'<',.' |
6dfc0 | 3c 3c 27 20 3d 3e 20 27 5c 5c 27 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 | <<'.=>.'\\'));.........}........ |
6dfe0 | 20 20 72 65 74 75 72 6e 20 73 74 72 5f 72 65 70 6c 61 63 65 28 27 5c 5c 3c 27 2c 20 27 3c 27 2c | ..return.str_replace('\\<',.'<', |
6e000 | 20 24 6f 75 74 70 75 74 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a | .$output);.....}....../**......* |
6e020 | 20 40 72 65 74 75 72 6e 20 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c 65 53 74 61 | .@return.OutputFormatterStyleSta |
6e040 | 63 6b 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 | ck......*/.....public.function.g |
6e060 | 65 74 53 74 79 6c 65 53 74 61 63 6b 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 | etStyleStack().....{.........ret |
6e080 | 75 72 6e 20 24 74 68 69 73 2d 3e 73 74 79 6c 65 53 74 61 63 6b 3b 0a 20 20 20 20 7d 0a 0a 20 20 | urn.$this->styleStack;.....}.... |
6e0a0 | 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 54 72 69 65 73 20 74 6f 20 63 72 65 61 74 65 20 6e 65 77 | ../**......*.Tries.to.create.new |
6e0c0 | 20 73 74 79 6c 65 20 69 6e 73 74 61 6e 63 65 20 66 72 6f 6d 20 73 74 72 69 6e 67 2e 0a 20 20 20 | .style.instance.from.string..... |
6e0e0 | 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 73 74 72 69 6e 67 | ..*......*.@param.string.$string |
6e100 | 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 4f 75 74 70 75 74 46 6f 72 | ......*......*.@return.OutputFor |
6e120 | 6d 61 74 74 65 72 53 74 79 6c 65 7c 62 6f 6f 6c 20 66 61 6c 73 65 20 69 66 20 73 74 72 69 6e 67 | matterStyle|bool.false.if.string |
6e140 | 20 69 73 20 6e 6f 74 20 66 6f 72 6d 61 74 20 73 74 72 69 6e 67 0a 20 20 20 20 20 2a 2f 0a 20 20 | .is.not.format.string......*/... |
6e160 | 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 63 72 65 61 74 65 53 74 79 6c 65 46 72 | ..private.function.createStyleFr |
6e180 | 6f 6d 53 74 72 69 6e 67 28 24 73 74 72 69 6e 67 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | omString($string).....{......... |
6e1a0 | 69 66 20 28 69 73 73 65 74 28 24 74 68 69 73 2d 3e 73 74 79 6c 65 73 5b 24 73 74 72 69 6e 67 5d | if.(isset($this->styles[$string] |
6e1c0 | 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 73 | )).{.............return.$this->s |
6e1e0 | 74 79 6c 65 73 5b 24 73 74 72 69 6e 67 5d 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 | tyles[$string];.........}....... |
6e200 | 20 20 20 69 66 20 28 21 70 72 65 67 5f 6d 61 74 63 68 5f 61 6c 6c 28 27 2f 28 5b 5e 3d 5d 2b 29 | ...if.(!preg_match_all('/([^=]+) |
6e220 | 3d 28 5b 5e 3b 5d 2b 29 28 3b 7c 24 29 2f 27 2c 20 73 74 72 74 6f 6c 6f 77 65 72 28 24 73 74 72 | =([^;]+)(;|$)/',.strtolower($str |
6e240 | 69 6e 67 29 2c 20 24 6d 61 74 63 68 65 73 2c 20 50 52 45 47 5f 53 45 54 5f 4f 52 44 45 52 29 29 | ing),.$matches,.PREG_SET_ORDER)) |
6e260 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 66 61 6c 73 65 3b 0a 20 20 20 | .{.............return.false;.... |
6e280 | 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 73 74 79 6c 65 20 3d 20 6e 65 77 20 4f 75 74 | .....}..........$style.=.new.Out |
6e2a0 | 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c 65 28 29 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 | putFormatterStyle();.........for |
6e2c0 | 65 61 63 68 20 28 24 6d 61 74 63 68 65 73 20 61 73 20 24 6d 61 74 63 68 29 20 7b 0a 20 20 20 20 | each.($matches.as.$match).{..... |
6e2e0 | 20 20 20 20 20 20 20 20 61 72 72 61 79 5f 73 68 69 66 74 28 24 6d 61 74 63 68 29 3b 0a 0a 20 20 | ........array_shift($match);.... |
6e300 | 20 20 20 20 20 20 20 20 20 20 69 66 20 28 27 66 67 27 20 3d 3d 20 24 6d 61 74 63 68 5b 30 5d 29 | ..........if.('fg'.==.$match[0]) |
6e320 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 73 74 79 6c 65 2d 3e 73 65 74 46 6f | .{.................$style->setFo |
6e340 | 72 65 67 72 6f 75 6e 64 28 24 6d 61 74 63 68 5b 31 5d 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 | reground($match[1]);............ |
6e360 | 20 7d 20 65 6c 73 65 69 66 20 28 27 62 67 27 20 3d 3d 20 24 6d 61 74 63 68 5b 30 5d 29 20 7b 0a | .}.elseif.('bg'.==.$match[0]).{. |
6e380 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 73 74 79 6c 65 2d 3e 73 65 74 42 61 63 6b 67 | ................$style->setBackg |
6e3a0 | 72 6f 75 6e 64 28 24 6d 61 74 63 68 5b 31 5d 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 | round($match[1]);.............}. |
6e3c0 | 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 72 79 20 7b 0a 20 20 20 | else.{.................try.{.... |
6e3e0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 73 74 79 6c 65 2d 3e 73 65 74 4f 70 74 69 | .................$style->setOpti |
6e400 | 6f 6e 28 24 6d 61 74 63 68 5b 31 5d 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d | on($match[1]);.................} |
6e420 | 20 63 61 74 63 68 20 28 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f | .catch.(\InvalidArgumentExceptio |
6e440 | 6e 20 24 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 | n.$e).{.....................retu |
6e460 | 72 6e 20 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 | rn.false;.................}..... |
6e480 | 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 | ........}.........}..........ret |
6e4a0 | 75 72 6e 20 24 73 74 79 6c 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 | urn.$style;.....}....../**...... |
6e4c0 | 2a 20 41 70 70 6c 69 65 73 20 63 75 72 72 65 6e 74 20 73 74 79 6c 65 20 66 72 6f 6d 20 73 74 61 | *.Applies.current.style.from.sta |
6e4e0 | 63 6b 20 74 6f 20 74 65 78 74 2c 20 69 66 20 6d 75 73 74 20 62 65 20 61 70 70 6c 69 65 64 2e 0a | ck.to.text,.if.must.be.applied.. |
6e500 | 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 74 65 78 | .....*......*.@param.string.$tex |
6e520 | 74 20 49 6e 70 75 74 20 74 65 78 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 | t.Input.text......*......*.@retu |
6e540 | 72 6e 20 73 74 72 69 6e 67 20 53 74 79 6c 65 64 20 74 65 78 74 0a 20 20 20 20 20 2a 2f 0a 20 20 | rn.string.Styled.text......*/... |
6e560 | 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 61 70 70 6c 79 43 75 72 72 65 6e 74 53 | ..private.function.applyCurrentS |
6e580 | 74 79 6c 65 28 24 74 65 78 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e | tyle($text).....{.........return |
6e5a0 | 20 24 74 68 69 73 2d 3e 69 73 44 65 63 6f 72 61 74 65 64 28 29 20 26 26 20 73 74 72 6c 65 6e 28 | .$this->isDecorated().&&.strlen( |
6e5c0 | 24 74 65 78 74 29 20 3e 20 30 20 3f 20 24 74 68 69 73 2d 3e 73 74 79 6c 65 53 74 61 63 6b 2d 3e | $text).>.0.?.$this->styleStack-> |
6e5e0 | 67 65 74 43 75 72 72 65 6e 74 28 29 2d 3e 61 70 70 6c 79 28 24 74 65 78 74 29 20 3a 20 24 74 65 | getCurrent()->apply($text).:.$te |
6e600 | 78 74 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 | xt;.....}.}.<?php../*..*.This.fi |
6e620 | 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 | le.is.part.of.the.Symfony.packag |
6e640 | 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 | e...*..*.(c).Fabien.Potencier.<f |
6e660 | 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 | abien@symfony.com>..*..*.For.the |
6e680 | 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f | .full.copyright.and.license.info |
6e6a0 | 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 | rmation,.please.view.the.LICENSE |
6e6c0 | 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 | ..*.file.that.was.distributed.wi |
6e6e0 | 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 | th.this.source.code...*/..namesp |
6e700 | 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 46 6f | ace.Symfony\Component\Console\Fo |
6e720 | 72 6d 61 74 74 65 72 3b 0a 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c | rmatter;..use.Symfony\Component\ |
6e740 | 43 6f 6e 73 6f 6c 65 5c 45 78 63 65 70 74 69 6f 6e 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e | Console\Exception\InvalidArgumen |
6e760 | 74 45 78 63 65 70 74 69 6f 6e 3b 0a 0a 2f 2a 2a 0a 20 2a 20 46 6f 72 6d 61 74 74 65 72 20 73 74 | tException;../**..*.Formatter.st |
6e780 | 79 6c 65 20 63 6c 61 73 73 20 66 6f 72 20 64 65 66 69 6e 69 6e 67 20 73 74 79 6c 65 73 2e 0a 20 | yle.class.for.defining.styles... |
6e7a0 | 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 4b 6f 6e 73 74 61 6e 74 69 6e 20 4b 75 64 72 79 61 73 68 | *..*.@author.Konstantin.Kudryash |
6e7c0 | 6f 76 20 3c 65 76 65 72 2e 7a 65 74 40 67 6d 61 69 6c 2e 63 6f 6d 3e 0a 20 2a 2f 0a 63 6c 61 73 | ov.<ever.zet@gmail.com>..*/.clas |
6e7e0 | 73 20 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c 65 20 69 6d 70 6c 65 6d 65 6e 74 | s.OutputFormatterStyle.implement |
6e800 | 73 20 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c 65 49 6e 74 65 72 66 61 63 65 0a | s.OutputFormatterStyleInterface. |
6e820 | 7b 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 24 61 76 61 69 6c 61 62 6c 65 46 | {.....private.static.$availableF |
6e840 | 6f 72 65 67 72 6f 75 6e 64 43 6f 6c 6f 72 73 20 3d 20 61 72 72 61 79 28 0a 20 20 20 20 20 20 20 | oregroundColors.=.array(........ |
6e860 | 20 27 62 6c 61 63 6b 27 20 3d 3e 20 61 72 72 61 79 28 27 73 65 74 27 20 3d 3e 20 33 30 2c 20 27 | .'black'.=>.array('set'.=>.30,.' |
6e880 | 75 6e 73 65 74 27 20 3d 3e 20 33 39 29 2c 0a 20 20 20 20 20 20 20 20 27 72 65 64 27 20 3d 3e 20 | unset'.=>.39),.........'red'.=>. |
6e8a0 | 61 72 72 61 79 28 27 73 65 74 27 20 3d 3e 20 33 31 2c 20 27 75 6e 73 65 74 27 20 3d 3e 20 33 39 | array('set'.=>.31,.'unset'.=>.39 |
6e8c0 | 29 2c 0a 20 20 20 20 20 20 20 20 27 67 72 65 65 6e 27 20 3d 3e 20 61 72 72 61 79 28 27 73 65 74 | ),.........'green'.=>.array('set |
6e8e0 | 27 20 3d 3e 20 33 32 2c 20 27 75 6e 73 65 74 27 20 3d 3e 20 33 39 29 2c 0a 20 20 20 20 20 20 20 | '.=>.32,.'unset'.=>.39),........ |
6e900 | 20 27 79 65 6c 6c 6f 77 27 20 3d 3e 20 61 72 72 61 79 28 27 73 65 74 27 20 3d 3e 20 33 33 2c 20 | .'yellow'.=>.array('set'.=>.33,. |
6e920 | 27 75 6e 73 65 74 27 20 3d 3e 20 33 39 29 2c 0a 20 20 20 20 20 20 20 20 27 62 6c 75 65 27 20 3d | 'unset'.=>.39),.........'blue'.= |
6e940 | 3e 20 61 72 72 61 79 28 27 73 65 74 27 20 3d 3e 20 33 34 2c 20 27 75 6e 73 65 74 27 20 3d 3e 20 | >.array('set'.=>.34,.'unset'.=>. |
6e960 | 33 39 29 2c 0a 20 20 20 20 20 20 20 20 27 6d 61 67 65 6e 74 61 27 20 3d 3e 20 61 72 72 61 79 28 | 39),.........'magenta'.=>.array( |
6e980 | 27 73 65 74 27 20 3d 3e 20 33 35 2c 20 27 75 6e 73 65 74 27 20 3d 3e 20 33 39 29 2c 0a 20 20 20 | 'set'.=>.35,.'unset'.=>.39),.... |
6e9a0 | 20 20 20 20 20 27 63 79 61 6e 27 20 3d 3e 20 61 72 72 61 79 28 27 73 65 74 27 20 3d 3e 20 33 36 | .....'cyan'.=>.array('set'.=>.36 |
6e9c0 | 2c 20 27 75 6e 73 65 74 27 20 3d 3e 20 33 39 29 2c 0a 20 20 20 20 20 20 20 20 27 77 68 69 74 65 | ,.'unset'.=>.39),.........'white |
6e9e0 | 27 20 3d 3e 20 61 72 72 61 79 28 27 73 65 74 27 20 3d 3e 20 33 37 2c 20 27 75 6e 73 65 74 27 20 | '.=>.array('set'.=>.37,.'unset'. |
6ea00 | 3d 3e 20 33 39 29 2c 0a 20 20 20 20 20 20 20 20 27 64 65 66 61 75 6c 74 27 20 3d 3e 20 61 72 72 | =>.39),.........'default'.=>.arr |
6ea20 | 61 79 28 27 73 65 74 27 20 3d 3e 20 33 39 2c 20 27 75 6e 73 65 74 27 20 3d 3e 20 33 39 29 2c 0a | ay('set'.=>.39,.'unset'.=>.39),. |
6ea40 | 20 20 20 20 29 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 24 61 76 61 69 6c | ....);.....private.static.$avail |
6ea60 | 61 62 6c 65 42 61 63 6b 67 72 6f 75 6e 64 43 6f 6c 6f 72 73 20 3d 20 61 72 72 61 79 28 0a 20 20 | ableBackgroundColors.=.array(... |
6ea80 | 20 20 20 20 20 20 27 62 6c 61 63 6b 27 20 3d 3e 20 61 72 72 61 79 28 27 73 65 74 27 20 3d 3e 20 | ......'black'.=>.array('set'.=>. |
6eaa0 | 34 30 2c 20 27 75 6e 73 65 74 27 20 3d 3e 20 34 39 29 2c 0a 20 20 20 20 20 20 20 20 27 72 65 64 | 40,.'unset'.=>.49),.........'red |
6eac0 | 27 20 3d 3e 20 61 72 72 61 79 28 27 73 65 74 27 20 3d 3e 20 34 31 2c 20 27 75 6e 73 65 74 27 20 | '.=>.array('set'.=>.41,.'unset'. |
6eae0 | 3d 3e 20 34 39 29 2c 0a 20 20 20 20 20 20 20 20 27 67 72 65 65 6e 27 20 3d 3e 20 61 72 72 61 79 | =>.49),.........'green'.=>.array |
6eb00 | 28 27 73 65 74 27 20 3d 3e 20 34 32 2c 20 27 75 6e 73 65 74 27 20 3d 3e 20 34 39 29 2c 0a 20 20 | ('set'.=>.42,.'unset'.=>.49),... |
6eb20 | 20 20 20 20 20 20 27 79 65 6c 6c 6f 77 27 20 3d 3e 20 61 72 72 61 79 28 27 73 65 74 27 20 3d 3e | ......'yellow'.=>.array('set'.=> |
6eb40 | 20 34 33 2c 20 27 75 6e 73 65 74 27 20 3d 3e 20 34 39 29 2c 0a 20 20 20 20 20 20 20 20 27 62 6c | .43,.'unset'.=>.49),.........'bl |
6eb60 | 75 65 27 20 3d 3e 20 61 72 72 61 79 28 27 73 65 74 27 20 3d 3e 20 34 34 2c 20 27 75 6e 73 65 74 | ue'.=>.array('set'.=>.44,.'unset |
6eb80 | 27 20 3d 3e 20 34 39 29 2c 0a 20 20 20 20 20 20 20 20 27 6d 61 67 65 6e 74 61 27 20 3d 3e 20 61 | '.=>.49),.........'magenta'.=>.a |
6eba0 | 72 72 61 79 28 27 73 65 74 27 20 3d 3e 20 34 35 2c 20 27 75 6e 73 65 74 27 20 3d 3e 20 34 39 29 | rray('set'.=>.45,.'unset'.=>.49) |
6ebc0 | 2c 0a 20 20 20 20 20 20 20 20 27 63 79 61 6e 27 20 3d 3e 20 61 72 72 61 79 28 27 73 65 74 27 20 | ,.........'cyan'.=>.array('set'. |
6ebe0 | 3d 3e 20 34 36 2c 20 27 75 6e 73 65 74 27 20 3d 3e 20 34 39 29 2c 0a 20 20 20 20 20 20 20 20 27 | =>.46,.'unset'.=>.49),.........' |
6ec00 | 77 68 69 74 65 27 20 3d 3e 20 61 72 72 61 79 28 27 73 65 74 27 20 3d 3e 20 34 37 2c 20 27 75 6e | white'.=>.array('set'.=>.47,.'un |
6ec20 | 73 65 74 27 20 3d 3e 20 34 39 29 2c 0a 20 20 20 20 20 20 20 20 27 64 65 66 61 75 6c 74 27 20 3d | set'.=>.49),.........'default'.= |
6ec40 | 3e 20 61 72 72 61 79 28 27 73 65 74 27 20 3d 3e 20 34 39 2c 20 27 75 6e 73 65 74 27 20 3d 3e 20 | >.array('set'.=>.49,.'unset'.=>. |
6ec60 | 34 39 29 2c 0a 20 20 20 20 29 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 24 | 49),.....);.....private.static.$ |
6ec80 | 61 76 61 69 6c 61 62 6c 65 4f 70 74 69 6f 6e 73 20 3d 20 61 72 72 61 79 28 0a 20 20 20 20 20 20 | availableOptions.=.array(....... |
6eca0 | 20 20 27 62 6f 6c 64 27 20 3d 3e 20 61 72 72 61 79 28 27 73 65 74 27 20 3d 3e 20 31 2c 20 27 75 | ..'bold'.=>.array('set'.=>.1,.'u |
6ecc0 | 6e 73 65 74 27 20 3d 3e 20 32 32 29 2c 0a 20 20 20 20 20 20 20 20 27 75 6e 64 65 72 73 63 6f 72 | nset'.=>.22),.........'underscor |
6ece0 | 65 27 20 3d 3e 20 61 72 72 61 79 28 27 73 65 74 27 20 3d 3e 20 34 2c 20 27 75 6e 73 65 74 27 20 | e'.=>.array('set'.=>.4,.'unset'. |
6ed00 | 3d 3e 20 32 34 29 2c 0a 20 20 20 20 20 20 20 20 27 62 6c 69 6e 6b 27 20 3d 3e 20 61 72 72 61 79 | =>.24),.........'blink'.=>.array |
6ed20 | 28 27 73 65 74 27 20 3d 3e 20 35 2c 20 27 75 6e 73 65 74 27 20 3d 3e 20 32 35 29 2c 0a 20 20 20 | ('set'.=>.5,.'unset'.=>.25),.... |
6ed40 | 20 20 20 20 20 27 72 65 76 65 72 73 65 27 20 3d 3e 20 61 72 72 61 79 28 27 73 65 74 27 20 3d 3e | .....'reverse'.=>.array('set'.=> |
6ed60 | 20 37 2c 20 27 75 6e 73 65 74 27 20 3d 3e 20 32 37 29 2c 0a 20 20 20 20 20 20 20 20 27 63 6f 6e | .7,.'unset'.=>.27),.........'con |
6ed80 | 63 65 61 6c 27 20 3d 3e 20 61 72 72 61 79 28 27 73 65 74 27 20 3d 3e 20 38 2c 20 27 75 6e 73 65 | ceal'.=>.array('set'.=>.8,.'unse |
6eda0 | 74 27 20 3d 3e 20 32 38 29 2c 0a 20 20 20 20 29 3b 0a 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 | t'.=>.28),.....);......private.$ |
6edc0 | 66 6f 72 65 67 72 6f 75 6e 64 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 62 61 63 6b 67 72 6f | foreground;.....private.$backgro |
6ede0 | 75 6e 64 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 6f 70 74 69 6f 6e 73 20 3d 20 61 72 72 61 | und;.....private.$options.=.arra |
6ee00 | 79 28 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 49 6e 69 74 69 61 6c 69 7a 65 73 | y();....../**......*.Initializes |
6ee20 | 20 6f 75 74 70 75 74 20 66 6f 72 6d 61 74 74 65 72 20 73 74 79 6c 65 2e 0a 20 20 20 20 20 2a 0a | .output.formatter.style.......*. |
6ee40 | 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 7c 6e 75 6c 6c 20 24 66 6f 72 65 67 | .....*.@param.string|null.$foreg |
6ee60 | 72 6f 75 6e 64 20 54 68 65 20 73 74 79 6c 65 20 66 6f 72 65 67 72 6f 75 6e 64 20 63 6f 6c 6f 72 | round.The.style.foreground.color |
6ee80 | 20 6e 61 6d 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 7c 6e 75 6c 6c 20 | .name......*.@param.string|null. |
6eea0 | 24 62 61 63 6b 67 72 6f 75 6e 64 20 54 68 65 20 73 74 79 6c 65 20 62 61 63 6b 67 72 6f 75 6e 64 | $background.The.style.background |
6eec0 | 20 63 6f 6c 6f 72 20 6e 61 6d 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 | .color.name......*.@param.array. |
6eee0 | 20 20 20 20 20 20 24 6f 70 74 69 6f 6e 73 20 20 20 20 54 68 65 20 73 74 79 6c 65 20 6f 70 74 69 | ......$options....The.style.opti |
6ef00 | 6f 6e 73 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 | ons......*/.....public.function. |
6ef20 | 5f 5f 63 6f 6e 73 74 72 75 63 74 28 24 66 6f 72 65 67 72 6f 75 6e 64 20 3d 20 6e 75 6c 6c 2c 20 | __construct($foreground.=.null,. |
6ef40 | 24 62 61 63 6b 67 72 6f 75 6e 64 20 3d 20 6e 75 6c 6c 2c 20 61 72 72 61 79 20 24 6f 70 74 69 6f | $background.=.null,.array.$optio |
6ef60 | 6e 73 20 3d 20 61 72 72 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 | ns.=.array()).....{.........if.( |
6ef80 | 6e 75 6c 6c 20 21 3d 3d 20 24 66 6f 72 65 67 72 6f 75 6e 64 29 20 7b 0a 20 20 20 20 20 20 20 20 | null.!==.$foreground).{......... |
6efa0 | 20 20 20 20 24 74 68 69 73 2d 3e 73 65 74 46 6f 72 65 67 72 6f 75 6e 64 28 24 66 6f 72 65 67 72 | ....$this->setForeground($foregr |
6efc0 | 6f 75 6e 64 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c | ound);.........}.........if.(nul |
6efe0 | 6c 20 21 3d 3d 20 24 62 61 63 6b 67 72 6f 75 6e 64 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | l.!==.$background).{............ |
6f000 | 20 24 74 68 69 73 2d 3e 73 65 74 42 61 63 6b 67 72 6f 75 6e 64 28 24 62 61 63 6b 67 72 6f 75 6e | .$this->setBackground($backgroun |
6f020 | 64 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 63 6f 75 6e 74 28 | d);.........}.........if.(count( |
6f040 | 24 6f 70 74 69 6f 6e 73 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e | $options)).{.............$this-> |
6f060 | 73 65 74 4f 70 74 69 6f 6e 73 28 24 6f 70 74 69 6f 6e 73 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a | setOptions($options);.........}. |
6f080 | 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 73 74 79 6c 65 | ....}....../**......*.Sets.style |
6f0a0 | 20 66 6f 72 65 67 72 6f 75 6e 64 20 63 6f 6c 6f 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a | .foreground.color.......*......* |
6f0c0 | 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 7c 6e 75 6c 6c 20 24 63 6f 6c 6f 72 20 54 68 65 20 63 | .@param.string|null.$color.The.c |
6f0e0 | 6f 6c 6f 72 20 6e 61 6d 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 | olor.name......*......*.@throws. |
6f100 | 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 20 57 68 65 6e 20 74 68 | InvalidArgumentException.When.th |
6f120 | 65 20 63 6f 6c 6f 72 20 6e 61 6d 65 20 69 73 6e 27 74 20 64 65 66 69 6e 65 64 0a 20 20 20 20 20 | e.color.name.isn't.defined...... |
6f140 | 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 46 6f 72 65 67 72 | */.....public.function.setForegr |
6f160 | 6f 75 6e 64 28 24 63 6f 6c 6f 72 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 | ound($color.=.null).....{....... |
6f180 | 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 63 6f 6c 6f 72 29 20 7b 0a 20 20 20 20 20 20 20 | ..if.(null.===.$color).{........ |
6f1a0 | 20 20 20 20 20 24 74 68 69 73 2d 3e 66 6f 72 65 67 72 6f 75 6e 64 20 3d 20 6e 75 6c 6c 3b 0a 0a | .....$this->foreground.=.null;.. |
6f1c0 | 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 | ............return;.........}... |
6f1e0 | 20 20 20 20 20 20 20 69 66 20 28 21 69 73 73 65 74 28 73 74 61 74 69 63 3a 3a 24 61 76 61 69 6c | .......if.(!isset(static::$avail |
6f200 | 61 62 6c 65 46 6f 72 65 67 72 6f 75 6e 64 43 6f 6c 6f 72 73 5b 24 63 6f 6c 6f 72 5d 29 29 20 7b | ableForegroundColors[$color])).{ |
6f220 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 61 6c 69 64 41 72 | .............throw.new.InvalidAr |
6f240 | 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 73 70 72 69 6e 74 66 28 0a 20 20 20 20 20 20 20 | gumentException(sprintf(........ |
6f260 | 20 20 20 20 20 20 20 20 20 27 49 6e 76 61 6c 69 64 20 66 6f 72 65 67 72 6f 75 6e 64 20 63 6f 6c | .........'Invalid.foreground.col |
6f280 | 6f 72 20 73 70 65 63 69 66 69 65 64 3a 20 22 25 73 22 2e 20 45 78 70 65 63 74 65 64 20 6f 6e 65 | or.specified:."%s"..Expected.one |
6f2a0 | 20 6f 66 20 28 25 73 29 27 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6f 6c 6f | .of.(%s)',.................$colo |
6f2c0 | 72 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 6d 70 6c 6f 64 65 28 27 2c 20 27 2c | r,.................implode(',.', |
6f2e0 | 20 61 72 72 61 79 5f 6b 65 79 73 28 73 74 61 74 69 63 3a 3a 24 61 76 61 69 6c 61 62 6c 65 46 6f | .array_keys(static::$availableFo |
6f300 | 72 65 67 72 6f 75 6e 64 43 6f 6c 6f 72 73 29 29 0a 20 20 20 20 20 20 20 20 20 20 20 20 29 29 3b | regroundColors)).............)); |
6f320 | 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 66 6f 72 65 67 | .........}..........$this->foreg |
6f340 | 72 6f 75 6e 64 20 3d 20 73 74 61 74 69 63 3a 3a 24 61 76 61 69 6c 61 62 6c 65 46 6f 72 65 67 72 | round.=.static::$availableForegr |
6f360 | 6f 75 6e 64 43 6f 6c 6f 72 73 5b 24 63 6f 6c 6f 72 5d 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f | oundColors[$color];.....}....../ |
6f380 | 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 73 74 79 6c 65 20 62 61 63 6b 67 72 6f 75 6e 64 20 | **......*.Sets.style.background. |
6f3a0 | 63 6f 6c 6f 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 | color.......*......*.@param.stri |
6f3c0 | 6e 67 7c 6e 75 6c 6c 20 24 63 6f 6c 6f 72 20 54 68 65 20 63 6f 6c 6f 72 20 6e 61 6d 65 0a 20 20 | ng|null.$color.The.color.name... |
6f3e0 | 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 49 6e 76 61 6c 69 64 41 72 67 75 6d | ...*......*.@throws.InvalidArgum |
6f400 | 65 6e 74 45 78 63 65 70 74 69 6f 6e 20 57 68 65 6e 20 74 68 65 20 63 6f 6c 6f 72 20 6e 61 6d 65 | entException.When.the.color.name |
6f420 | 20 69 73 6e 27 74 20 64 65 66 69 6e 65 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 | .isn't.defined......*/.....publi |
6f440 | 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 42 61 63 6b 67 72 6f 75 6e 64 28 24 63 6f 6c 6f 72 20 | c.function.setBackground($color. |
6f460 | 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d | =.null).....{.........if.(null.= |
6f480 | 3d 3d 20 24 63 6f 6c 6f 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e | ==.$color).{.............$this-> |
6f4a0 | 62 61 63 6b 67 72 6f 75 6e 64 20 3d 20 6e 75 6c 6c 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 | background.=.null;.............. |
6f4c0 | 72 65 74 75 72 6e 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 | return;.........}..........if.(! |
6f4e0 | 69 73 73 65 74 28 73 74 61 74 69 63 3a 3a 24 61 76 61 69 6c 61 62 6c 65 42 61 63 6b 67 72 6f 75 | isset(static::$availableBackgrou |
6f500 | 6e 64 43 6f 6c 6f 72 73 5b 24 63 6f 6c 6f 72 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | ndColors[$color])).{............ |
6f520 | 20 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 | .throw.new.InvalidArgumentExcept |
6f540 | 69 6f 6e 28 73 70 72 69 6e 74 66 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 27 49 6e | ion(sprintf(.................'In |
6f560 | 76 61 6c 69 64 20 62 61 63 6b 67 72 6f 75 6e 64 20 63 6f 6c 6f 72 20 73 70 65 63 69 66 69 65 64 | valid.background.color.specified |
6f580 | 3a 20 22 25 73 22 2e 20 45 78 70 65 63 74 65 64 20 6f 6e 65 20 6f 66 20 28 25 73 29 27 2c 0a 20 | :."%s"..Expected.one.of.(%s)',.. |
6f5a0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6f 6c 6f 72 2c 0a 20 20 20 20 20 20 20 20 20 | ...............$color,.......... |
6f5c0 | 20 20 20 20 20 20 20 69 6d 70 6c 6f 64 65 28 27 2c 20 27 2c 20 61 72 72 61 79 5f 6b 65 79 73 28 | .......implode(',.',.array_keys( |
6f5e0 | 73 74 61 74 69 63 3a 3a 24 61 76 61 69 6c 61 62 6c 65 42 61 63 6b 67 72 6f 75 6e 64 43 6f 6c 6f | static::$availableBackgroundColo |
6f600 | 72 73 29 29 0a 20 20 20 20 20 20 20 20 20 20 20 20 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a | rs)).............));.........}.. |
6f620 | 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 62 61 63 6b 67 72 6f 75 6e 64 20 3d 20 73 74 61 74 | ........$this->background.=.stat |
6f640 | 69 63 3a 3a 24 61 76 61 69 6c 61 62 6c 65 42 61 63 6b 67 72 6f 75 6e 64 43 6f 6c 6f 72 73 5b 24 | ic::$availableBackgroundColors[$ |
6f660 | 63 6f 6c 6f 72 5d 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 | color];.....}....../**......*.Se |
6f680 | 74 73 20 73 6f 6d 65 20 73 70 65 63 69 66 69 63 20 73 74 79 6c 65 20 6f 70 74 69 6f 6e 2e 0a 20 | ts.some.specific.style.option... |
6f6a0 | 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6f 70 74 69 | ....*......*.@param.string.$opti |
6f6c0 | 6f 6e 20 54 68 65 20 6f 70 74 69 6f 6e 20 6e 61 6d 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a | on.The.option.name......*......* |
6f6e0 | 20 40 74 68 72 6f 77 73 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f | .@throws.InvalidArgumentExceptio |
6f700 | 6e 20 57 68 65 6e 20 74 68 65 20 6f 70 74 69 6f 6e 20 6e 61 6d 65 20 69 73 6e 27 74 20 64 65 66 | n.When.the.option.name.isn't.def |
6f720 | 69 6e 65 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e | ined......*/.....public.function |
6f740 | 20 73 65 74 4f 70 74 69 6f 6e 28 24 6f 70 74 69 6f 6e 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 | .setOption($option).....{....... |
6f760 | 20 20 69 66 20 28 21 69 73 73 65 74 28 73 74 61 74 69 63 3a 3a 24 61 76 61 69 6c 61 62 6c 65 4f | ..if.(!isset(static::$availableO |
6f780 | 70 74 69 6f 6e 73 5b 24 6f 70 74 69 6f 6e 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ptions[$option])).{............. |
6f7a0 | 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 | throw.new.InvalidArgumentExcepti |
6f7c0 | 6f 6e 28 73 70 72 69 6e 74 66 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 27 49 6e 76 | on(sprintf(.................'Inv |
6f7e0 | 61 6c 69 64 20 6f 70 74 69 6f 6e 20 73 70 65 63 69 66 69 65 64 3a 20 22 25 73 22 2e 20 45 78 70 | alid.option.specified:."%s"..Exp |
6f800 | 65 63 74 65 64 20 6f 6e 65 20 6f 66 20 28 25 73 29 27 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ected.one.of.(%s)',............. |
6f820 | 20 20 20 20 24 6f 70 74 69 6f 6e 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 6d 70 | ....$option,.................imp |
6f840 | 6c 6f 64 65 28 27 2c 20 27 2c 20 61 72 72 61 79 5f 6b 65 79 73 28 73 74 61 74 69 63 3a 3a 24 61 | lode(',.',.array_keys(static::$a |
6f860 | 76 61 69 6c 61 62 6c 65 4f 70 74 69 6f 6e 73 29 29 0a 20 20 20 20 20 20 20 20 20 20 20 20 29 29 | vailableOptions)).............)) |
6f880 | 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 69 6e 5f 61 72 72 | ;.........}..........if.(!in_arr |
6f8a0 | 61 79 28 73 74 61 74 69 63 3a 3a 24 61 76 61 69 6c 61 62 6c 65 4f 70 74 69 6f 6e 73 5b 24 6f 70 | ay(static::$availableOptions[$op |
6f8c0 | 74 69 6f 6e 5d 2c 20 24 74 68 69 73 2d 3e 6f 70 74 69 6f 6e 73 29 29 20 7b 0a 20 20 20 20 20 20 | tion],.$this->options)).{....... |
6f8e0 | 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6f 70 74 69 6f 6e 73 5b 5d 20 3d 20 73 74 61 74 69 63 3a | ......$this->options[].=.static: |
6f900 | 3a 24 61 76 61 69 6c 61 62 6c 65 4f 70 74 69 6f 6e 73 5b 24 6f 70 74 69 6f 6e 5d 3b 0a 20 20 20 | :$availableOptions[$option];.... |
6f920 | 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 55 6e 73 | .....}.....}....../**......*.Uns |
6f940 | 65 74 73 20 73 6f 6d 65 20 73 70 65 63 69 66 69 63 20 73 74 79 6c 65 20 6f 70 74 69 6f 6e 2e 0a | ets.some.specific.style.option.. |
6f960 | 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6f 70 74 | .....*......*.@param.string.$opt |
6f980 | 69 6f 6e 20 54 68 65 20 6f 70 74 69 6f 6e 20 6e 61 6d 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 | ion.The.option.name......*...... |
6f9a0 | 2a 20 40 74 68 72 6f 77 73 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 | *.@throws.InvalidArgumentExcepti |
6f9c0 | 6f 6e 20 57 68 65 6e 20 74 68 65 20 6f 70 74 69 6f 6e 20 6e 61 6d 65 20 69 73 6e 27 74 20 64 65 | on.When.the.option.name.isn't.de |
6f9e0 | 66 69 6e 65 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f | fined......*/.....public.functio |
6fa00 | 6e 20 75 6e 73 65 74 4f 70 74 69 6f 6e 28 24 6f 70 74 69 6f 6e 29 0a 20 20 20 20 7b 0a 20 20 20 | n.unsetOption($option).....{.... |
6fa20 | 20 20 20 20 20 69 66 20 28 21 69 73 73 65 74 28 73 74 61 74 69 63 3a 3a 24 61 76 61 69 6c 61 62 | .....if.(!isset(static::$availab |
6fa40 | 6c 65 4f 70 74 69 6f 6e 73 5b 24 6f 70 74 69 6f 6e 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | leOptions[$option])).{.......... |
6fa60 | 20 20 20 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 | ...throw.new.InvalidArgumentExce |
6fa80 | 70 74 69 6f 6e 28 73 70 72 69 6e 74 66 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 27 | ption(sprintf(.................' |
6faa0 | 49 6e 76 61 6c 69 64 20 6f 70 74 69 6f 6e 20 73 70 65 63 69 66 69 65 64 3a 20 22 25 73 22 2e 20 | Invalid.option.specified:."%s".. |
6fac0 | 45 78 70 65 63 74 65 64 20 6f 6e 65 20 6f 66 20 28 25 73 29 27 2c 0a 20 20 20 20 20 20 20 20 20 | Expected.one.of.(%s)',.......... |
6fae0 | 20 20 20 20 20 20 20 24 6f 70 74 69 6f 6e 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | .......$option,................. |
6fb00 | 69 6d 70 6c 6f 64 65 28 27 2c 20 27 2c 20 61 72 72 61 79 5f 6b 65 79 73 28 73 74 61 74 69 63 3a | implode(',.',.array_keys(static: |
6fb20 | 3a 24 61 76 61 69 6c 61 62 6c 65 4f 70 74 69 6f 6e 73 29 29 0a 20 20 20 20 20 20 20 20 20 20 20 | :$availableOptions))............ |
6fb40 | 20 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 70 6f 73 20 3d 20 61 | .));.........}..........$pos.=.a |
6fb60 | 72 72 61 79 5f 73 65 61 72 63 68 28 73 74 61 74 69 63 3a 3a 24 61 76 61 69 6c 61 62 6c 65 4f 70 | rray_search(static::$availableOp |
6fb80 | 74 69 6f 6e 73 5b 24 6f 70 74 69 6f 6e 5d 2c 20 24 74 68 69 73 2d 3e 6f 70 74 69 6f 6e 73 29 3b | tions[$option],.$this->options); |
6fba0 | 0a 20 20 20 20 20 20 20 20 69 66 20 28 66 61 6c 73 65 20 21 3d 3d 20 24 70 6f 73 29 20 7b 0a 20 | .........if.(false.!==.$pos).{.. |
6fbc0 | 20 20 20 20 20 20 20 20 20 20 20 75 6e 73 65 74 28 24 74 68 69 73 2d 3e 6f 70 74 69 6f 6e 73 5b | ...........unset($this->options[ |
6fbe0 | 24 70 6f 73 5d 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a | $pos]);.........}.....}....../** |
6fc00 | 0a 20 20 20 20 20 2a 20 53 65 74 73 20 6d 75 6c 74 69 70 6c 65 20 73 74 79 6c 65 20 6f 70 74 69 | ......*.Sets.multiple.style.opti |
6fc20 | 6f 6e 73 20 61 74 20 6f 6e 63 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 | ons.at.once.......*......*.@para |
6fc40 | 6d 20 61 72 72 61 79 20 24 6f 70 74 69 6f 6e 73 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 | m.array.$options......*/.....pub |
6fc60 | 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 4f 70 74 69 6f 6e 73 28 61 72 72 61 79 20 24 6f | lic.function.setOptions(array.$o |
6fc80 | 70 74 69 6f 6e 73 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6f 70 74 | ptions).....{.........$this->opt |
6fca0 | 69 6f 6e 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 | ions.=.array();..........foreach |
6fcc0 | 20 28 24 6f 70 74 69 6f 6e 73 20 61 73 20 24 6f 70 74 69 6f 6e 29 20 7b 0a 20 20 20 20 20 20 20 | .($options.as.$option).{........ |
6fce0 | 20 20 20 20 20 24 74 68 69 73 2d 3e 73 65 74 4f 70 74 69 6f 6e 28 24 6f 70 74 69 6f 6e 29 3b 0a | .....$this->setOption($option);. |
6fd00 | 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 | ........}.....}....../**......*. |
6fd20 | 41 70 70 6c 69 65 73 20 74 68 65 20 73 74 79 6c 65 20 74 6f 20 61 20 67 69 76 65 6e 20 74 65 78 | Applies.the.style.to.a.given.tex |
6fd40 | 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 | t.......*......*.@param.string.$ |
6fd60 | 74 65 78 74 20 54 68 65 20 74 65 78 74 20 74 6f 20 73 74 79 6c 65 0a 20 20 20 20 20 2a 0a 20 20 | text.The.text.to.style......*... |
6fd80 | 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 | ...*.@return.string......*/..... |
6fda0 | 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 61 70 70 6c 79 28 24 74 65 78 74 29 0a 20 20 20 | public.function.apply($text).... |
6fdc0 | 20 7b 0a 20 20 20 20 20 20 20 20 24 73 65 74 43 6f 64 65 73 20 3d 20 61 72 72 61 79 28 29 3b 0a | .{.........$setCodes.=.array();. |
6fde0 | 20 20 20 20 20 20 20 20 24 75 6e 73 65 74 43 6f 64 65 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 0a | ........$unsetCodes.=.array();.. |
6fe00 | 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 21 3d 3d 20 24 74 68 69 73 2d 3e 66 6f 72 65 | ........if.(null.!==.$this->fore |
6fe20 | 67 72 6f 75 6e 64 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 73 65 74 43 6f 64 65 73 5b | ground).{.............$setCodes[ |
6fe40 | 5d 20 3d 20 24 74 68 69 73 2d 3e 66 6f 72 65 67 72 6f 75 6e 64 5b 27 73 65 74 27 5d 3b 0a 20 20 | ].=.$this->foreground['set'];... |
6fe60 | 20 20 20 20 20 20 20 20 20 20 24 75 6e 73 65 74 43 6f 64 65 73 5b 5d 20 3d 20 24 74 68 69 73 2d | ..........$unsetCodes[].=.$this- |
6fe80 | 3e 66 6f 72 65 67 72 6f 75 6e 64 5b 27 75 6e 73 65 74 27 5d 3b 0a 20 20 20 20 20 20 20 20 7d 0a | >foreground['unset'];.........}. |
6fea0 | 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 21 3d 3d 20 24 74 68 69 73 2d 3e 62 61 63 6b | ........if.(null.!==.$this->back |
6fec0 | 67 72 6f 75 6e 64 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 73 65 74 43 6f 64 65 73 5b | ground).{.............$setCodes[ |
6fee0 | 5d 20 3d 20 24 74 68 69 73 2d 3e 62 61 63 6b 67 72 6f 75 6e 64 5b 27 73 65 74 27 5d 3b 0a 20 20 | ].=.$this->background['set'];... |
6ff00 | 20 20 20 20 20 20 20 20 20 20 24 75 6e 73 65 74 43 6f 64 65 73 5b 5d 20 3d 20 24 74 68 69 73 2d | ..........$unsetCodes[].=.$this- |
6ff20 | 3e 62 61 63 6b 67 72 6f 75 6e 64 5b 27 75 6e 73 65 74 27 5d 3b 0a 20 20 20 20 20 20 20 20 7d 0a | >background['unset'];.........}. |
6ff40 | 20 20 20 20 20 20 20 20 69 66 20 28 63 6f 75 6e 74 28 24 74 68 69 73 2d 3e 6f 70 74 69 6f 6e 73 | ........if.(count($this->options |
6ff60 | 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 74 68 69 73 2d | )).{.............foreach.($this- |
6ff80 | 3e 6f 70 74 69 6f 6e 73 20 61 73 20 24 6f 70 74 69 6f 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | >options.as.$option).{.......... |
6ffa0 | 20 20 20 20 20 20 20 24 73 65 74 43 6f 64 65 73 5b 5d 20 3d 20 24 6f 70 74 69 6f 6e 5b 27 73 65 | .......$setCodes[].=.$option['se |
6ffc0 | 74 27 5d 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 75 6e 73 65 74 43 6f 64 65 73 | t'];.................$unsetCodes |
6ffe0 | 5b 5d 20 3d 20 24 6f 70 74 69 6f 6e 5b 27 75 6e 73 65 74 27 5d 3b 0a 20 20 20 20 20 20 20 20 20 | [].=.$option['unset'];.......... |
70000 | 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 30 20 3d 3d | ...}.........}..........if.(0.== |
70020 | 3d 20 63 6f 75 6e 74 28 24 73 65 74 43 6f 64 65 73 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | =.count($setCodes)).{........... |
70040 | 20 20 72 65 74 75 72 6e 20 24 74 65 78 74 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 | ..return.$text;.........}....... |
70060 | 20 20 20 72 65 74 75 72 6e 20 73 70 72 69 6e 74 66 28 22 5c 30 33 33 5b 25 73 6d 25 73 5c 30 33 | ...return.sprintf("\033[%sm%s\03 |
70080 | 33 5b 25 73 6d 22 2c 20 69 6d 70 6c 6f 64 65 28 27 3b 27 2c 20 24 73 65 74 43 6f 64 65 73 29 2c | 3[%sm",.implode(';',.$setCodes), |
700a0 | 20 24 74 65 78 74 2c 20 69 6d 70 6c 6f 64 65 28 27 3b 27 2c 20 24 75 6e 73 65 74 43 6f 64 65 73 | .$text,.implode(';',.$unsetCodes |
700c0 | 29 29 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 | ));.....}.}.<?php../*..*.This.fi |
700e0 | 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 | le.is.part.of.the.Symfony.packag |
70100 | 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 | e...*..*.(c).Fabien.Potencier.<f |
70120 | 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 | abien@symfony.com>..*..*.For.the |
70140 | 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f | .full.copyright.and.license.info |
70160 | 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 | rmation,.please.view.the.LICENSE |
70180 | 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 | ..*.file.that.was.distributed.wi |
701a0 | 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 | th.this.source.code...*/..namesp |
701c0 | 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 46 6f | ace.Symfony\Component\Console\Fo |
701e0 | 72 6d 61 74 74 65 72 3b 0a 0a 2f 2a 2a 0a 20 2a 20 46 6f 72 6d 61 74 74 65 72 20 69 6e 74 65 72 | rmatter;../**..*.Formatter.inter |
70200 | 66 61 63 65 20 66 6f 72 20 63 6f 6e 73 6f 6c 65 20 6f 75 74 70 75 74 2e 0a 20 2a 0a 20 2a 20 40 | face.for.console.output...*..*.@ |
70220 | 61 75 74 68 6f 72 20 4b 6f 6e 73 74 61 6e 74 69 6e 20 4b 75 64 72 79 61 73 68 6f 76 20 3c 65 76 | author.Konstantin.Kudryashov.<ev |
70240 | 65 72 2e 7a 65 74 40 67 6d 61 69 6c 2e 63 6f 6d 3e 0a 20 2a 2f 0a 69 6e 74 65 72 66 61 63 65 20 | er.zet@gmail.com>..*/.interface. |
70260 | 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 49 6e 74 65 72 66 61 63 65 0a 7b 0a 20 20 20 20 2f | OutputFormatterInterface.{...../ |
70280 | 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 74 68 65 20 64 65 63 6f 72 61 74 65 64 20 66 6c 61 | **......*.Sets.the.decorated.fla |
702a0 | 67 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 62 6f 6f 6c 20 24 64 65 | g.......*......*.@param.bool.$de |
702c0 | 63 6f 72 61 74 65 64 20 57 68 65 74 68 65 72 20 74 6f 20 64 65 63 6f 72 61 74 65 20 74 68 65 20 | corated.Whether.to.decorate.the. |
702e0 | 6d 65 73 73 61 67 65 73 20 6f 72 20 6e 6f 74 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c | messages.or.not......*/.....publ |
70300 | 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 44 65 63 6f 72 61 74 65 64 28 24 64 65 63 6f 72 61 | ic.function.setDecorated($decora |
70320 | 74 65 64 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 64 | ted);....../**......*.Gets.the.d |
70340 | 65 63 6f 72 61 74 65 64 20 66 6c 61 67 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 | ecorated.flag.......*......*.@re |
70360 | 74 75 72 6e 20 62 6f 6f 6c 20 74 72 75 65 20 69 66 20 74 68 65 20 6f 75 74 70 75 74 20 77 69 6c | turn.bool.true.if.the.output.wil |
70380 | 6c 20 64 65 63 6f 72 61 74 65 20 6d 65 73 73 61 67 65 73 2c 20 66 61 6c 73 65 20 6f 74 68 65 72 | l.decorate.messages,.false.other |
703a0 | 77 69 73 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e | wise......*/.....public.function |
703c0 | 20 69 73 44 65 63 6f 72 61 74 65 64 28 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 | .isDecorated();....../**......*. |
703e0 | 53 65 74 73 20 61 20 6e 65 77 20 73 74 79 6c 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 | Sets.a.new.style.......*......*. |
70400 | 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | @param.string................... |
70420 | 20 20 20 20 20 24 6e 61 6d 65 20 20 54 68 65 20 73 74 79 6c 65 20 6e 61 6d 65 0a 20 20 20 20 20 | .....$name..The.style.name...... |
70440 | 2a 20 40 70 61 72 61 6d 20 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c 65 49 6e 74 | *.@param.OutputFormatterStyleInt |
70460 | 65 72 66 61 63 65 20 24 73 74 79 6c 65 20 54 68 65 20 73 74 79 6c 65 20 69 6e 73 74 61 6e 63 65 | erface.$style.The.style.instance |
70480 | 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 | ......*/.....public.function.set |
704a0 | 53 74 79 6c 65 28 24 6e 61 6d 65 2c 20 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c | Style($name,.OutputFormatterStyl |
704c0 | 65 49 6e 74 65 72 66 61 63 65 20 24 73 74 79 6c 65 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 | eInterface.$style);....../**.... |
704e0 | 20 20 2a 20 43 68 65 63 6b 73 20 69 66 20 6f 75 74 70 75 74 20 66 6f 72 6d 61 74 74 65 72 20 68 | ..*.Checks.if.output.formatter.h |
70500 | 61 73 20 73 74 79 6c 65 20 77 69 74 68 20 73 70 65 63 69 66 69 65 64 20 6e 61 6d 65 2e 0a 20 20 | as.style.with.specified.name.... |
70520 | 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6e 61 6d 65 0a | ...*......*.@param.string.$name. |
70540 | 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 62 6f 6f 6c 0a 20 20 20 20 20 | .....*......*.@return.bool...... |
70560 | 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 68 61 73 53 74 79 6c 65 28 | */.....public.function.hasStyle( |
70580 | 24 6e 61 6d 65 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 73 74 79 | $name);....../**......*.Gets.sty |
705a0 | 6c 65 20 6f 70 74 69 6f 6e 73 20 66 72 6f 6d 20 73 74 79 6c 65 20 77 69 74 68 20 73 70 65 63 69 | le.options.from.style.with.speci |
705c0 | 66 69 65 64 20 6e 61 6d 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 | fied.name.......*......*.@param. |
705e0 | 73 74 72 69 6e 67 20 24 6e 61 6d 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 | string.$name......*......*.@retu |
70600 | 72 6e 20 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c 65 49 6e 74 65 72 66 61 63 65 | rn.OutputFormatterStyleInterface |
70620 | 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 | ......*/.....public.function.get |
70640 | 53 74 79 6c 65 28 24 6e 61 6d 65 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 46 6f | Style($name);....../**......*.Fo |
70660 | 72 6d 61 74 73 20 61 20 6d 65 73 73 61 67 65 20 61 63 63 6f 72 64 69 6e 67 20 74 6f 20 74 68 65 | rmats.a.message.according.to.the |
70680 | 20 67 69 76 65 6e 20 73 74 79 6c 65 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 | .given.styles.......*......*.@pa |
706a0 | 72 61 6d 20 73 74 72 69 6e 67 20 24 6d 65 73 73 61 67 65 20 54 68 65 20 6d 65 73 73 61 67 65 20 | ram.string.$message.The.message. |
706c0 | 74 6f 20 73 74 79 6c 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 | to.style......*......*.@return.s |
706e0 | 74 72 69 6e 67 20 54 68 65 20 73 74 79 6c 65 64 20 6d 65 73 73 61 67 65 0a 20 20 20 20 20 2a 2f | tring.The.styled.message......*/ |
70700 | 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 66 6f 72 6d 61 74 28 24 6d 65 73 | .....public.function.format($mes |
70720 | 73 61 67 65 29 3b 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 | sage);.}.<?php../*..*.This.file. |
70740 | 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a | is.part.of.the.Symfony.package.. |
70760 | 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 | .*..*.(c).Fabien.Potencier.<fabi |
70780 | 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 | en@symfony.com>..*..*.For.the.fu |
707a0 | 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 | ll.copyright.and.license.informa |
707c0 | 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a | tion,.please.view.the.LICENSE..* |
707e0 | 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 | .file.that.was.distributed.with. |
70800 | 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 | this.source.code...*/..namespace |
70820 | 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 46 6f 72 6d 61 | .Symfony\Component\Console\Forma |
70840 | 74 74 65 72 3b 0a 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e | tter;..use.Symfony\Component\Con |
70860 | 73 6f 6c 65 5c 45 78 63 65 70 74 69 6f 6e 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 | sole\Exception\InvalidArgumentEx |
70880 | 63 65 70 74 69 6f 6e 3b 0a 0a 2f 2a 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 4a 65 61 6e 2d 46 72 | ception;../**..*.@author.Jean-Fr |
708a0 | 61 6e c3 a7 6f 69 73 20 53 69 6d 6f 6e 20 3c 63 6f 6e 74 61 63 74 40 6a 66 73 69 6d 6f 6e 2e 66 | an..ois.Simon.<contact@jfsimon.f |
708c0 | 72 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c | r>..*/.class.OutputFormatterStyl |
708e0 | 65 53 74 61 63 6b 0a 7b 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 76 61 72 20 4f 75 74 | eStack.{...../**......*.@var.Out |
70900 | 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c 65 49 6e 74 65 72 66 61 63 65 5b 5d 0a 20 20 20 | putFormatterStyleInterface[].... |
70920 | 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 73 74 79 6c 65 73 3b 0a 0a 20 20 20 20 2f | ..*/.....private.$styles;....../ |
70940 | 2a 2a 0a 20 20 20 20 20 2a 20 40 76 61 72 20 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 | **......*.@var.OutputFormatterSt |
70960 | 79 6c 65 49 6e 74 65 72 66 61 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 | yleInterface......*/.....private |
70980 | 20 24 65 6d 70 74 79 53 74 79 6c 65 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 43 6f | .$emptyStyle;....../**......*.Co |
709a0 | 6e 73 74 72 75 63 74 6f 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 | nstructor.......*......*.@param. |
709c0 | 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c 65 49 6e 74 65 72 66 61 63 65 7c 6e 75 | OutputFormatterStyleInterface|nu |
709e0 | 6c 6c 20 24 65 6d 70 74 79 53 74 79 6c 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 | ll.$emptyStyle......*/.....publi |
70a00 | 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 74 28 4f 75 74 70 75 74 46 6f 72 | c.function.__construct(OutputFor |
70a20 | 6d 61 74 74 65 72 53 74 79 6c 65 49 6e 74 65 72 66 61 63 65 20 24 65 6d 70 74 79 53 74 79 6c 65 | matterStyleInterface.$emptyStyle |
70a40 | 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 65 6d | .=.null).....{.........$this->em |
70a60 | 70 74 79 53 74 79 6c 65 20 3d 20 24 65 6d 70 74 79 53 74 79 6c 65 20 3f 3a 20 6e 65 77 20 4f 75 | ptyStyle.=.$emptyStyle.?:.new.Ou |
70a80 | 74 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c 65 28 29 3b 0a 20 20 20 20 20 20 20 20 24 74 | tputFormatterStyle();.........$t |
70aa0 | 68 69 73 2d 3e 72 65 73 65 74 28 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 | his->reset();.....}....../**.... |
70ac0 | 20 20 2a 20 52 65 73 65 74 73 20 73 74 61 63 6b 20 28 69 65 2e 20 65 6d 70 74 79 20 69 6e 74 65 | ..*.Resets.stack.(ie..empty.inte |
70ae0 | 72 6e 61 6c 20 61 72 72 61 79 73 29 2e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 | rnal.arrays).......*/.....public |
70b00 | 20 66 75 6e 63 74 69 6f 6e 20 72 65 73 65 74 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | .function.reset().....{......... |
70b20 | 24 74 68 69 73 2d 3e 73 74 79 6c 65 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 7d 0a 0a | $this->styles.=.array();.....}.. |
70b40 | 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 50 75 73 68 65 73 20 61 20 73 74 79 6c 65 20 69 6e | ..../**......*.Pushes.a.style.in |
70b60 | 20 74 68 65 20 73 74 61 63 6b 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d | .the.stack.......*......*.@param |
70b80 | 20 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c 65 49 6e 74 65 72 66 61 63 65 20 24 | .OutputFormatterStyleInterface.$ |
70ba0 | 73 74 79 6c 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f | style......*/.....public.functio |
70bc0 | 6e 20 70 75 73 68 28 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c 65 49 6e 74 65 72 | n.push(OutputFormatterStyleInter |
70be0 | 66 61 63 65 20 24 73 74 79 6c 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 | face.$style).....{.........$this |
70c00 | 2d 3e 73 74 79 6c 65 73 5b 5d 20 3d 20 24 73 74 79 6c 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 | ->styles[].=.$style;.....}...... |
70c20 | 2f 2a 2a 0a 20 20 20 20 20 2a 20 50 6f 70 73 20 61 20 73 74 79 6c 65 20 66 72 6f 6d 20 74 68 65 | /**......*.Pops.a.style.from.the |
70c40 | 20 73 74 61 63 6b 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 4f 75 74 | .stack.......*......*.@param.Out |
70c60 | 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c 65 49 6e 74 65 72 66 61 63 65 7c 6e 75 6c 6c 20 | putFormatterStyleInterface|null. |
70c80 | 24 73 74 79 6c 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 4f 75 74 | $style......*......*.@return.Out |
70ca0 | 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c 65 49 6e 74 65 72 66 61 63 65 0a 20 20 20 20 20 | putFormatterStyleInterface...... |
70cc0 | 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 | *......*.@throws.InvalidArgument |
70ce0 | 45 78 63 65 70 74 69 6f 6e 20 57 68 65 6e 20 73 74 79 6c 65 20 74 61 67 73 20 69 6e 63 6f 72 72 | Exception.When.style.tags.incorr |
70d00 | 65 63 74 6c 79 20 6e 65 73 74 65 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 | ectly.nested......*/.....public. |
70d20 | 66 75 6e 63 74 69 6f 6e 20 70 6f 70 28 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c | function.pop(OutputFormatterStyl |
70d40 | 65 49 6e 74 65 72 66 61 63 65 20 24 73 74 79 6c 65 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a | eInterface.$style.=.null).....{. |
70d60 | 20 20 20 20 20 20 20 20 69 66 20 28 65 6d 70 74 79 28 24 74 68 69 73 2d 3e 73 74 79 6c 65 73 29 | ........if.(empty($this->styles) |
70d80 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 65 6d | ).{.............return.$this->em |
70da0 | 70 74 79 53 74 79 6c 65 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 | ptyStyle;.........}..........if. |
70dc0 | 28 6e 75 6c 6c 20 3d 3d 3d 20 24 73 74 79 6c 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | (null.===.$style).{............. |
70de0 | 72 65 74 75 72 6e 20 61 72 72 61 79 5f 70 6f 70 28 24 74 68 69 73 2d 3e 73 74 79 6c 65 73 29 3b | return.array_pop($this->styles); |
70e00 | 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 61 72 72 | .........}..........foreach.(arr |
70e20 | 61 79 5f 72 65 76 65 72 73 65 28 24 74 68 69 73 2d 3e 73 74 79 6c 65 73 2c 20 74 72 75 65 29 20 | ay_reverse($this->styles,.true). |
70e40 | 61 73 20 24 69 6e 64 65 78 20 3d 3e 20 24 73 74 61 63 6b 65 64 53 74 79 6c 65 29 20 7b 0a 20 20 | as.$index.=>.$stackedStyle).{... |
70e60 | 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 73 74 79 6c 65 2d 3e 61 70 70 6c 79 28 27 27 29 20 | ..........if.($style->apply(''). |
70e80 | 3d 3d 3d 20 24 73 74 61 63 6b 65 64 53 74 79 6c 65 2d 3e 61 70 70 6c 79 28 27 27 29 29 20 7b 0a | ===.$stackedStyle->apply('')).{. |
70ea0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 74 79 6c 65 73 20 3d 20 | ................$this->styles.=. |
70ec0 | 61 72 72 61 79 5f 73 6c 69 63 65 28 24 74 68 69 73 2d 3e 73 74 79 6c 65 73 2c 20 30 2c 20 24 69 | array_slice($this->styles,.0,.$i |
70ee0 | 6e 64 65 78 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 | ndex);..................return.$ |
70f00 | 73 74 61 63 6b 65 64 53 74 79 6c 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 | stackedStyle;.............}..... |
70f20 | 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 61 6c 69 64 | ....}..........throw.new.Invalid |
70f40 | 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 27 49 6e 63 6f 72 72 65 63 74 6c 79 20 6e | ArgumentException('Incorrectly.n |
70f60 | 65 73 74 65 64 20 73 74 79 6c 65 20 74 61 67 20 66 6f 75 6e 64 2e 27 29 3b 0a 20 20 20 20 7d 0a | ested.style.tag.found.');.....}. |
70f80 | 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 43 6f 6d 70 75 74 65 73 20 63 75 72 72 65 6e 74 | ...../**......*.Computes.current |
70fa0 | 20 73 74 79 6c 65 20 77 69 74 68 20 73 74 61 63 6b 73 20 74 6f 70 20 63 6f 64 65 73 2e 0a 20 20 | .style.with.stacks.top.codes.... |
70fc0 | 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 4f 75 74 70 75 74 46 6f 72 6d 61 74 | ...*......*.@return.OutputFormat |
70fe0 | 74 65 72 53 74 79 6c 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 | terStyle......*/.....public.func |
71000 | 74 69 6f 6e 20 67 65 74 43 75 72 72 65 6e 74 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | tion.getCurrent().....{......... |
71020 | 69 66 20 28 65 6d 70 74 79 28 24 74 68 69 73 2d 3e 73 74 79 6c 65 73 29 29 20 7b 0a 20 20 20 20 | if.(empty($this->styles)).{..... |
71040 | 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 65 6d 70 74 79 53 74 79 6c 65 | ........return.$this->emptyStyle |
71060 | 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 | ;.........}..........return.$thi |
71080 | 73 2d 3e 73 74 79 6c 65 73 5b 63 6f 75 6e 74 28 24 74 68 69 73 2d 3e 73 74 79 6c 65 73 29 20 2d | s->styles[count($this->styles).- |
710a0 | 20 31 5d 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 | .1];.....}....../**......*.@para |
710c0 | 6d 20 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c 65 49 6e 74 65 72 66 61 63 65 20 | m.OutputFormatterStyleInterface. |
710e0 | 24 65 6d 70 74 79 53 74 79 6c 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 | $emptyStyle......*......*.@retur |
71100 | 6e 20 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c 65 53 74 61 63 6b 0a 20 20 20 20 | n.OutputFormatterStyleStack..... |
71120 | 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 45 6d 70 74 79 | .*/.....public.function.setEmpty |
71140 | 53 74 79 6c 65 28 4f 75 74 70 75 74 46 6f 72 6d 61 74 74 65 72 53 74 79 6c 65 49 6e 74 65 72 66 | Style(OutputFormatterStyleInterf |
71160 | 61 63 65 20 24 65 6d 70 74 79 53 74 79 6c 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 | ace.$emptyStyle).....{.........$ |
71180 | 74 68 69 73 2d 3e 65 6d 70 74 79 53 74 79 6c 65 20 3d 20 24 65 6d 70 74 79 53 74 79 6c 65 3b 0a | this->emptyStyle.=.$emptyStyle;. |
711a0 | 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 | .........return.$this;.....}.... |
711c0 | 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 4f 75 74 70 75 74 46 6f 72 6d 61 | ../**......*.@return.OutputForma |
711e0 | 74 74 65 72 53 74 79 6c 65 49 6e 74 65 72 66 61 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 | tterStyleInterface......*/.....p |
71200 | 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 45 6d 70 74 79 53 74 79 6c 65 28 29 0a 20 | ublic.function.getEmptyStyle().. |
71220 | 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 65 6d 70 74 79 | ...{.........return.$this->empty |
71240 | 53 74 79 6c 65 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 | Style;.....}.}.<?php../*..*.This |
71260 | 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 | .file.is.part.of.the.Symfony.pac |
71280 | 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 | kage...*..*.(c).Fabien.Potencier |
712a0 | 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 | .<fabien@symfony.com>..*..*.For. |
712c0 | 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 | the.full.copyright.and.license.i |
712e0 | 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 | nformation,.please.view.the.LICE |
71300 | 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 | NSE..*.file.that.was.distributed |
71320 | 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d | .with.this.source.code...*/..nam |
71340 | 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 | espace.Symfony\Component\Console |
71360 | 5c 51 75 65 73 74 69 6f 6e 3b 0a 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e | \Question;..use.Symfony\Componen |
71380 | 74 5c 43 6f 6e 73 6f 6c 65 5c 45 78 63 65 70 74 69 6f 6e 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d | t\Console\Exception\InvalidArgum |
713a0 | 65 6e 74 45 78 63 65 70 74 69 6f 6e 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e | entException;.use.Symfony\Compon |
713c0 | 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 78 63 65 70 74 69 6f 6e 5c 4c 6f 67 69 63 45 78 63 65 70 | ent\Console\Exception\LogicExcep |
713e0 | 74 69 6f 6e 3b 0a 0a 2f 2a 2a 0a 20 2a 20 52 65 70 72 65 73 65 6e 74 73 20 61 20 51 75 65 73 74 | tion;../**..*.Represents.a.Quest |
71400 | 69 6f 6e 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 | ion...*..*.@author.Fabien.Potenc |
71420 | 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 2f 0a 63 6c 61 | ier.<fabien@symfony.com>..*/.cla |
71440 | 73 73 20 51 75 65 73 74 69 6f 6e 0a 7b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 71 75 65 73 74 | ss.Question.{.....private.$quest |
71460 | 69 6f 6e 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 61 74 74 65 6d 70 74 73 3b 0a 20 20 20 20 | ion;.....private.$attempts;..... |
71480 | 70 72 69 76 61 74 65 20 24 68 69 64 64 65 6e 20 3d 20 66 61 6c 73 65 3b 0a 20 20 20 20 70 72 69 | private.$hidden.=.false;.....pri |
714a0 | 76 61 74 65 20 24 68 69 64 64 65 6e 46 61 6c 6c 62 61 63 6b 20 3d 20 74 72 75 65 3b 0a 20 20 20 | vate.$hiddenFallback.=.true;.... |
714c0 | 20 70 72 69 76 61 74 65 20 24 61 75 74 6f 63 6f 6d 70 6c 65 74 65 72 56 61 6c 75 65 73 3b 0a 20 | .private.$autocompleterValues;.. |
714e0 | 20 20 20 70 72 69 76 61 74 65 20 24 76 61 6c 69 64 61 74 6f 72 3b 0a 20 20 20 20 70 72 69 76 61 | ...private.$validator;.....priva |
71500 | 74 65 20 24 64 65 66 61 75 6c 74 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 6e 6f 72 6d 61 6c | te.$default;.....private.$normal |
71520 | 69 7a 65 72 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 43 6f 6e 73 74 72 75 63 74 6f | izer;....../**......*.Constructo |
71540 | 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 | r.......*......*.@param.string.$ |
71560 | 71 75 65 73 74 69 6f 6e 20 54 68 65 20 71 75 65 73 74 69 6f 6e 20 74 6f 20 61 73 6b 20 74 6f 20 | question.The.question.to.ask.to. |
71580 | 74 68 65 20 75 73 65 72 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 6d 69 78 65 64 20 20 24 64 | the.user......*.@param.mixed..$d |
715a0 | 65 66 61 75 6c 74 20 20 54 68 65 20 64 65 66 61 75 6c 74 20 61 6e 73 77 65 72 20 74 6f 20 72 65 | efault..The.default.answer.to.re |
715c0 | 74 75 72 6e 20 69 66 20 74 68 65 20 75 73 65 72 20 65 6e 74 65 72 73 20 6e 6f 74 68 69 6e 67 0a | turn.if.the.user.enters.nothing. |
715e0 | 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 63 6f | .....*/.....public.function.__co |
71600 | 6e 73 74 72 75 63 74 28 24 71 75 65 73 74 69 6f 6e 2c 20 24 64 65 66 61 75 6c 74 20 3d 20 6e 75 | nstruct($question,.$default.=.nu |
71620 | 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 71 75 65 73 74 69 6f | ll).....{.........$this->questio |
71640 | 6e 20 3d 20 24 71 75 65 73 74 69 6f 6e 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 64 65 | n.=.$question;.........$this->de |
71660 | 66 61 75 6c 74 20 3d 20 24 64 65 66 61 75 6c 74 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a | fault.=.$default;.....}....../** |
71680 | 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 74 68 65 20 71 75 65 73 74 69 6f 6e 2e 0a 20 20 | ......*.Returns.the.question.... |
716a0 | 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 0a 20 20 20 20 20 | ...*......*.@return.string...... |
716c0 | 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 51 75 65 73 74 69 | */.....public.function.getQuesti |
716e0 | 6f 6e 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d | on().....{.........return.$this- |
71700 | 3e 71 75 65 73 74 69 6f 6e 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a | >question;.....}....../**......* |
71720 | 20 52 65 74 75 72 6e 73 20 74 68 65 20 64 65 66 61 75 6c 74 20 61 6e 73 77 65 72 2e 0a 20 20 20 | .Returns.the.default.answer..... |
71740 | 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 6d 69 78 65 64 0a 20 20 20 20 20 2a 2f | ..*......*.@return.mixed......*/ |
71760 | 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 44 65 66 61 75 6c 74 28 | .....public.function.getDefault( |
71780 | 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 64 65 | ).....{.........return.$this->de |
717a0 | 66 61 75 6c 74 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 | fault;.....}....../**......*.Ret |
717c0 | 75 72 6e 73 20 77 68 65 74 68 65 72 20 74 68 65 20 75 73 65 72 20 72 65 73 70 6f 6e 73 65 20 6d | urns.whether.the.user.response.m |
717e0 | 75 73 74 20 62 65 20 68 69 64 64 65 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 | ust.be.hidden.......*......*.@re |
71800 | 74 75 72 6e 20 62 6f 6f 6c 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e | turn.bool......*/.....public.fun |
71820 | 63 74 69 6f 6e 20 69 73 48 69 64 64 65 6e 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 | ction.isHidden().....{.........r |
71840 | 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 68 69 64 64 65 6e 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 | eturn.$this->hidden;.....}...... |
71860 | 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 77 68 65 74 68 65 72 20 74 68 65 20 75 73 65 72 | /**......*.Sets.whether.the.user |
71880 | 20 72 65 73 70 6f 6e 73 65 20 6d 75 73 74 20 62 65 20 68 69 64 64 65 6e 20 6f 72 20 6e 6f 74 2e | .response.must.be.hidden.or.not. |
718a0 | 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 62 6f 6f 6c 20 24 68 69 64 64 | ......*......*.@param.bool.$hidd |
718c0 | 65 6e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 51 75 65 73 74 69 6f | en......*......*.@return.Questio |
718e0 | 6e 20 54 68 65 20 63 75 72 72 65 6e 74 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 0a 20 20 | n.The.current.instance......*... |
71900 | 20 20 20 2a 20 40 74 68 72 6f 77 73 20 4c 6f 67 69 63 45 78 63 65 70 74 69 6f 6e 20 49 6e 20 63 | ...*.@throws.LogicException.In.c |
71920 | 61 73 65 20 74 68 65 20 61 75 74 6f 63 6f 6d 70 6c 65 74 65 72 20 69 73 20 61 6c 73 6f 20 75 73 | ase.the.autocompleter.is.also.us |
71940 | 65 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 | ed......*/.....public.function.s |
71960 | 65 74 48 69 64 64 65 6e 28 24 68 69 64 64 65 6e 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | etHidden($hidden).....{......... |
71980 | 69 66 20 28 24 74 68 69 73 2d 3e 61 75 74 6f 63 6f 6d 70 6c 65 74 65 72 56 61 6c 75 65 73 29 20 | if.($this->autocompleterValues). |
719a0 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 4c 6f 67 69 63 45 78 63 | {.............throw.new.LogicExc |
719c0 | 65 70 74 69 6f 6e 28 27 41 20 68 69 64 64 65 6e 20 71 75 65 73 74 69 6f 6e 20 63 61 6e 6e 6f 74 | eption('A.hidden.question.cannot |
719e0 | 20 75 73 65 20 74 68 65 20 61 75 74 6f 63 6f 6d 70 6c 65 74 65 72 2e 27 29 3b 0a 20 20 20 20 20 | .use.the.autocompleter.');...... |
71a00 | 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 68 69 64 64 65 6e 20 3d 20 28 62 | ...}..........$this->hidden.=.(b |
71a20 | 6f 6f 6c 29 20 24 68 69 64 64 65 6e 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 | ool).$hidden;..........return.$t |
71a40 | 68 69 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 49 6e 20 63 61 | his;.....}....../**......*.In.ca |
71a60 | 73 65 20 74 68 65 20 72 65 73 70 6f 6e 73 65 20 63 61 6e 20 6e 6f 74 20 62 65 20 68 69 64 64 65 | se.the.response.can.not.be.hidde |
71a80 | 6e 2c 20 77 68 65 74 68 65 72 20 74 6f 20 66 61 6c 6c 62 61 63 6b 20 6f 6e 20 6e 6f 6e 2d 68 69 | n,.whether.to.fallback.on.non-hi |
71aa0 | 64 64 65 6e 20 71 75 65 73 74 69 6f 6e 20 6f 72 20 6e 6f 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 | dden.question.or.not.......*.... |
71ac0 | 20 20 2a 20 40 72 65 74 75 72 6e 20 62 6f 6f 6c 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 | ..*.@return.bool......*/.....pub |
71ae0 | 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 69 73 48 69 64 64 65 6e 46 61 6c 6c 62 61 63 6b 28 29 0a | lic.function.isHiddenFallback(). |
71b00 | 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 68 69 64 64 | ....{.........return.$this->hidd |
71b20 | 65 6e 46 61 6c 6c 62 61 63 6b 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 | enFallback;.....}....../**...... |
71b40 | 2a 20 53 65 74 73 20 77 68 65 74 68 65 72 20 74 6f 20 66 61 6c 6c 62 61 63 6b 20 6f 6e 20 6e 6f | *.Sets.whether.to.fallback.on.no |
71b60 | 6e 2d 68 69 64 64 65 6e 20 71 75 65 73 74 69 6f 6e 20 69 66 20 74 68 65 20 72 65 73 70 6f 6e 73 | n-hidden.question.if.the.respons |
71b80 | 65 20 63 61 6e 20 6e 6f 74 20 62 65 20 68 69 64 64 65 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 | e.can.not.be.hidden.......*..... |
71ba0 | 20 2a 20 40 70 61 72 61 6d 20 62 6f 6f 6c 20 24 66 61 6c 6c 62 61 63 6b 0a 20 20 20 20 20 2a 0a | .*.@param.bool.$fallback......*. |
71bc0 | 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 51 75 65 73 74 69 6f 6e 20 54 68 65 20 63 75 72 72 | .....*.@return.Question.The.curr |
71be0 | 65 6e 74 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 | ent.instance......*/.....public. |
71c00 | 66 75 6e 63 74 69 6f 6e 20 73 65 74 48 69 64 64 65 6e 46 61 6c 6c 62 61 63 6b 28 24 66 61 6c 6c | function.setHiddenFallback($fall |
71c20 | 62 61 63 6b 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 68 69 64 64 65 | back).....{.........$this->hidde |
71c40 | 6e 46 61 6c 6c 62 61 63 6b 20 3d 20 28 62 6f 6f 6c 29 20 24 66 61 6c 6c 62 61 63 6b 3b 0a 0a 20 | nFallback.=.(bool).$fallback;... |
71c60 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 | .......return.$this;.....}...... |
71c80 | 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 76 61 6c 75 65 73 20 66 6f 72 20 74 68 65 20 61 | /**......*.Gets.values.for.the.a |
71ca0 | 75 74 6f 63 6f 6d 70 6c 65 74 65 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 | utocompleter.......*......*.@ret |
71cc0 | 75 72 6e 20 6e 75 6c 6c 7c 61 72 72 61 79 7c 5c 54 72 61 76 65 72 73 61 62 6c 65 0a 20 20 20 20 | urn.null|array|\Traversable..... |
71ce0 | 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 41 75 74 6f 63 | .*/.....public.function.getAutoc |
71d00 | 6f 6d 70 6c 65 74 65 72 56 61 6c 75 65 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 | ompleterValues().....{.........r |
71d20 | 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 61 75 74 6f 63 6f 6d 70 6c 65 74 65 72 56 61 6c 75 65 73 | eturn.$this->autocompleterValues |
71d40 | 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 76 61 6c | ;.....}....../**......*.Sets.val |
71d60 | 75 65 73 20 66 6f 72 20 74 68 65 20 61 75 74 6f 63 6f 6d 70 6c 65 74 65 72 2e 0a 20 20 20 20 20 | ues.for.the.autocompleter....... |
71d80 | 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 6e 75 6c 6c 7c 61 72 72 61 79 7c 5c 54 72 61 76 | *......*.@param.null|array|\Trav |
71da0 | 65 72 73 61 62 6c 65 20 24 76 61 6c 75 65 73 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 | ersable.$values......*......*.@r |
71dc0 | 65 74 75 72 6e 20 51 75 65 73 74 69 6f 6e 20 54 68 65 20 63 75 72 72 65 6e 74 20 69 6e 73 74 61 | eturn.Question.The.current.insta |
71de0 | 6e 63 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 49 6e 76 61 6c 69 | nce......*......*.@throws.Invali |
71e00 | 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 | dArgumentException......*.@throw |
71e20 | 73 20 4c 6f 67 69 63 45 78 63 65 70 74 69 6f 6e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 | s.LogicException......*/.....pub |
71e40 | 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 41 75 74 6f 63 6f 6d 70 6c 65 74 65 72 56 61 6c | lic.function.setAutocompleterVal |
71e60 | 75 65 73 28 24 76 61 6c 75 65 73 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 69 | ues($values).....{.........if.(i |
71e80 | 73 5f 61 72 72 61 79 28 24 76 61 6c 75 65 73 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | s_array($values)).{............. |
71ea0 | 24 76 61 6c 75 65 73 20 3d 20 24 74 68 69 73 2d 3e 69 73 41 73 73 6f 63 28 24 76 61 6c 75 65 73 | $values.=.$this->isAssoc($values |
71ec0 | 29 20 3f 20 61 72 72 61 79 5f 6d 65 72 67 65 28 61 72 72 61 79 5f 6b 65 79 73 28 24 76 61 6c 75 | ).?.array_merge(array_keys($valu |
71ee0 | 65 73 29 2c 20 61 72 72 61 79 5f 76 61 6c 75 65 73 28 24 76 61 6c 75 65 73 29 29 20 3a 20 61 72 | es),.array_values($values)).:.ar |
71f00 | 72 61 79 5f 76 61 6c 75 65 73 28 24 76 61 6c 75 65 73 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a | ray_values($values);.........}.. |
71f20 | 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 21 3d 3d 20 24 76 61 6c 75 65 73 20 26 26 20 | ........if.(null.!==.$values.&&. |
71f40 | 21 69 73 5f 61 72 72 61 79 28 24 76 61 6c 75 65 73 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | !is_array($values)).{........... |
71f60 | 20 20 69 66 20 28 21 24 76 61 6c 75 65 73 20 69 6e 73 74 61 6e 63 65 6f 66 20 5c 54 72 61 76 65 | ..if.(!$values.instanceof.\Trave |
71f80 | 72 73 61 62 6c 65 20 7c 7c 20 21 24 76 61 6c 75 65 73 20 69 6e 73 74 61 6e 63 65 6f 66 20 5c 43 | rsable.||.!$values.instanceof.\C |
71fa0 | 6f 75 6e 74 61 62 6c 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f | ountable).{.................thro |
71fc0 | 77 20 6e 65 77 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 27 | w.new.InvalidArgumentException(' |
71fe0 | 41 75 74 6f 63 6f 6d 70 6c 65 74 65 72 20 76 61 6c 75 65 73 20 63 61 6e 20 62 65 20 65 69 74 68 | Autocompleter.values.can.be.eith |
72000 | 65 72 20 61 6e 20 61 72 72 61 79 2c 20 60 6e 75 6c 6c 60 20 6f 72 20 61 6e 20 6f 62 6a 65 63 74 | er.an.array,.`null`.or.an.object |
72020 | 20 69 6d 70 6c 65 6d 65 6e 74 69 6e 67 20 62 6f 74 68 20 60 43 6f 75 6e 74 61 62 6c 65 60 20 61 | .implementing.both.`Countable`.a |
72040 | 6e 64 20 60 54 72 61 76 65 72 73 61 62 6c 65 60 20 69 6e 74 65 72 66 61 63 65 73 2e 27 29 3b 0a | nd.`Traversable`.interfaces.');. |
72060 | 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 | ............}.........}......... |
72080 | 20 69 66 20 28 24 74 68 69 73 2d 3e 68 69 64 64 65 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | .if.($this->hidden).{........... |
720a0 | 20 20 74 68 72 6f 77 20 6e 65 77 20 4c 6f 67 69 63 45 78 63 65 70 74 69 6f 6e 28 27 41 20 68 69 | ..throw.new.LogicException('A.hi |
720c0 | 64 64 65 6e 20 71 75 65 73 74 69 6f 6e 20 63 61 6e 6e 6f 74 20 75 73 65 20 74 68 65 20 61 75 74 | dden.question.cannot.use.the.aut |
720e0 | 6f 63 6f 6d 70 6c 65 74 65 72 2e 27 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 | ocompleter.');.........}........ |
72100 | 20 20 24 74 68 69 73 2d 3e 61 75 74 6f 63 6f 6d 70 6c 65 74 65 72 56 61 6c 75 65 73 20 3d 20 24 | ..$this->autocompleterValues.=.$ |
72120 | 76 61 6c 75 65 73 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 3b 0a 20 | values;..........return.$this;.. |
72140 | 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 61 20 76 61 6c 69 | ...}....../**......*.Sets.a.vali |
72160 | 64 61 74 6f 72 20 66 6f 72 20 74 68 65 20 71 75 65 73 74 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 | dator.for.the.question.......*.. |
72180 | 20 20 20 20 2a 20 40 70 61 72 61 6d 20 6e 75 6c 6c 7c 63 61 6c 6c 61 62 6c 65 20 24 76 61 6c 69 | ....*.@param.null|callable.$vali |
721a0 | 64 61 74 6f 72 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 51 75 65 73 | dator......*......*.@return.Ques |
721c0 | 74 69 6f 6e 20 54 68 65 20 63 75 72 72 65 6e 74 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a | tion.The.current.instance......* |
721e0 | 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 56 61 6c 69 64 61 74 | /.....public.function.setValidat |
72200 | 6f 72 28 63 61 6c 6c 61 62 6c 65 20 24 76 61 6c 69 64 61 74 6f 72 20 3d 20 6e 75 6c 6c 29 0a 20 | or(callable.$validator.=.null).. |
72220 | 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 76 61 6c 69 64 61 74 6f 72 20 3d 20 | ...{.........$this->validator.=. |
72240 | 24 76 61 6c 69 64 61 74 6f 72 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 | $validator;..........return.$thi |
72260 | 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 | s;.....}....../**......*.Gets.th |
72280 | 65 20 76 61 6c 69 64 61 74 6f 72 20 66 6f 72 20 74 68 65 20 71 75 65 73 74 69 6f 6e 2e 0a 20 20 | e.validator.for.the.question.... |
722a0 | 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 6e 75 6c 6c 7c 63 61 6c 6c 61 62 6c | ...*......*.@return.null|callabl |
722c0 | 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 | e......*/.....public.function.ge |
722e0 | 74 56 61 6c 69 64 61 74 6f 72 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 | tValidator().....{.........retur |
72300 | 6e 20 24 74 68 69 73 2d 3e 76 61 6c 69 64 61 74 6f 72 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f | n.$this->validator;.....}....../ |
72320 | 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 74 68 65 20 6d 61 78 69 6d 75 6d 20 6e 75 6d 62 65 | **......*.Sets.the.maximum.numbe |
72340 | 72 20 6f 66 20 61 74 74 65 6d 70 74 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 4e 75 6c | r.of.attempts.......*......*.Nul |
72360 | 6c 20 6d 65 61 6e 73 20 61 6e 20 75 6e 6c 69 6d 69 74 65 64 20 6e 75 6d 62 65 72 20 6f 66 20 61 | l.means.an.unlimited.number.of.a |
72380 | 74 74 65 6d 70 74 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 6e 75 | ttempts.......*......*.@param.nu |
723a0 | 6c 6c 7c 69 6e 74 20 24 61 74 74 65 6d 70 74 73 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 | ll|int.$attempts......*......*.@ |
723c0 | 72 65 74 75 72 6e 20 51 75 65 73 74 69 6f 6e 20 54 68 65 20 63 75 72 72 65 6e 74 20 69 6e 73 74 | return.Question.The.current.inst |
723e0 | 61 6e 63 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 49 6e 76 61 6c | ance......*......*.@throws.Inval |
72400 | 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 20 49 6e 20 63 61 73 65 20 74 68 65 20 | idArgumentException.In.case.the. |
72420 | 6e 75 6d 62 65 72 20 6f 66 20 61 74 74 65 6d 70 74 73 20 69 73 20 69 6e 76 61 6c 69 64 2e 0a 20 | number.of.attempts.is.invalid... |
72440 | 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 4d 61 | ....*/.....public.function.setMa |
72460 | 78 41 74 74 65 6d 70 74 73 28 24 61 74 74 65 6d 70 74 73 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 | xAttempts($attempts).....{...... |
72480 | 20 20 20 69 66 20 28 6e 75 6c 6c 20 21 3d 3d 20 24 61 74 74 65 6d 70 74 73 20 26 26 20 24 61 74 | ...if.(null.!==.$attempts.&&.$at |
724a0 | 74 65 6d 70 74 73 20 3c 20 31 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 | tempts.<.1).{.............throw. |
724c0 | 6e 65 77 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 27 4d 61 | new.InvalidArgumentException('Ma |
724e0 | 78 69 6d 75 6d 20 6e 75 6d 62 65 72 20 6f 66 20 61 74 74 65 6d 70 74 73 20 6d 75 73 74 20 62 65 | ximum.number.of.attempts.must.be |
72500 | 20 61 20 70 6f 73 69 74 69 76 65 20 76 61 6c 75 65 2e 27 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a | .a.positive.value.');.........}. |
72520 | 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 61 74 74 65 6d 70 74 73 20 3d 20 24 61 74 74 65 | .........$this->attempts.=.$atte |
72540 | 6d 70 74 73 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 3b 0a 20 20 20 | mpts;..........return.$this;.... |
72560 | 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 6d 61 78 69 | .}....../**......*.Gets.the.maxi |
72580 | 6d 75 6d 20 6e 75 6d 62 65 72 20 6f 66 20 61 74 74 65 6d 70 74 73 2e 0a 20 20 20 20 20 2a 0a 20 | mum.number.of.attempts.......*.. |
725a0 | 20 20 20 20 2a 20 4e 75 6c 6c 20 6d 65 61 6e 73 20 61 6e 20 75 6e 6c 69 6d 69 74 65 64 20 6e 75 | ....*.Null.means.an.unlimited.nu |
725c0 | 6d 62 65 72 20 6f 66 20 61 74 74 65 6d 70 74 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 | mber.of.attempts.......*......*. |
725e0 | 40 72 65 74 75 72 6e 20 6e 75 6c 6c 7c 69 6e 74 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 | @return.null|int......*/.....pub |
72600 | 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 4d 61 78 41 74 74 65 6d 70 74 73 28 29 0a 20 20 | lic.function.getMaxAttempts()... |
72620 | 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 61 74 74 65 6d 70 | ..{.........return.$this->attemp |
72640 | 74 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 61 | ts;.....}....../**......*.Sets.a |
72660 | 20 6e 6f 72 6d 61 6c 69 7a 65 72 20 66 6f 72 20 74 68 65 20 72 65 73 70 6f 6e 73 65 2e 0a 20 20 | .normalizer.for.the.response.... |
72680 | 20 20 20 2a 0a 20 20 20 20 20 2a 20 54 68 65 20 6e 6f 72 6d 61 6c 69 7a 65 72 20 63 61 6e 20 62 | ...*......*.The.normalizer.can.b |
726a0 | 65 20 61 20 63 61 6c 6c 61 62 6c 65 20 28 61 20 73 74 72 69 6e 67 29 2c 20 61 20 63 6c 6f 73 75 | e.a.callable.(a.string),.a.closu |
726c0 | 72 65 20 6f 72 20 61 20 63 6c 61 73 73 20 69 6d 70 6c 65 6d 65 6e 74 69 6e 67 20 5f 5f 69 6e 76 | re.or.a.class.implementing.__inv |
726e0 | 6f 6b 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 63 61 6c 6c 61 62 | oke.......*......*.@param.callab |
72700 | 6c 65 20 24 6e 6f 72 6d 61 6c 69 7a 65 72 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 | le.$normalizer......*......*.@re |
72720 | 74 75 72 6e 20 51 75 65 73 74 69 6f 6e 20 54 68 65 20 63 75 72 72 65 6e 74 20 69 6e 73 74 61 6e | turn.Question.The.current.instan |
72740 | 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 | ce......*/.....public.function.s |
72760 | 65 74 4e 6f 72 6d 61 6c 69 7a 65 72 28 63 61 6c 6c 61 62 6c 65 20 24 6e 6f 72 6d 61 6c 69 7a 65 | etNormalizer(callable.$normalize |
72780 | 72 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6e 6f 72 6d 61 6c 69 7a | r).....{.........$this->normaliz |
727a0 | 65 72 20 3d 20 24 6e 6f 72 6d 61 6c 69 7a 65 72 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 | er.=.$normalizer;..........retur |
727c0 | 6e 20 24 74 68 69 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 | n.$this;.....}....../**......*.G |
727e0 | 65 74 73 20 74 68 65 20 6e 6f 72 6d 61 6c 69 7a 65 72 20 66 6f 72 20 74 68 65 20 72 65 73 70 6f | ets.the.normalizer.for.the.respo |
72800 | 6e 73 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 54 68 65 20 6e 6f 72 6d 61 6c 69 7a 65 | nse.......*......*.The.normalize |
72820 | 72 20 63 61 6e 20 62 61 20 61 20 63 61 6c 6c 61 62 6c 65 20 28 61 20 73 74 72 69 6e 67 29 2c 20 | r.can.ba.a.callable.(a.string),. |
72840 | 61 20 63 6c 6f 73 75 72 65 20 6f 72 20 61 20 63 6c 61 73 73 20 69 6d 70 6c 65 6d 65 6e 74 69 6e | a.closure.or.a.class.implementin |
72860 | 67 20 5f 5f 69 6e 76 6f 6b 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 | g.__invoke.......*......*.@retur |
72880 | 6e 20 63 61 6c 6c 61 62 6c 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 | n.callable......*/.....public.fu |
728a0 | 6e 63 74 69 6f 6e 20 67 65 74 4e 6f 72 6d 61 6c 69 7a 65 72 28 29 0a 20 20 20 20 7b 0a 20 20 20 | nction.getNormalizer().....{.... |
728c0 | 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 6e 6f 72 6d 61 6c 69 7a 65 72 3b 0a 20 | .....return.$this->normalizer;.. |
728e0 | 20 20 20 7d 0a 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 69 73 41 | ...}......protected.function.isA |
72900 | 73 73 6f 63 28 24 61 72 72 61 79 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 | ssoc($array).....{.........retur |
72920 | 6e 20 28 62 6f 6f 6c 29 20 63 6f 75 6e 74 28 61 72 72 61 79 5f 66 69 6c 74 65 72 28 61 72 72 61 | n.(bool).count(array_filter(arra |
72940 | 79 5f 6b 65 79 73 28 24 61 72 72 61 79 29 2c 20 27 69 73 5f 73 74 72 69 6e 67 27 29 29 3b 0a 20 | y_keys($array),.'is_string'));.. |
72960 | 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 | ...}.}.<?php../*..*.This.file.is |
72980 | 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a | .part.of.the.Symfony.package...* |
729a0 | 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e | ..*.(c).Fabien.Potencier.<fabien |
729c0 | 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c | @symfony.com>..*..*.For.the.full |
729e0 | 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 | .copyright.and.license.informati |
72a00 | 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 | on,.please.view.the.LICENSE..*.f |
72a20 | 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 | ile.that.was.distributed.with.th |
72a40 | 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 | is.source.code...*/..namespace.S |
72a60 | 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 51 75 65 73 74 69 6f | ymfony\Component\Console\Questio |
72a80 | 6e 3b 0a 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c | n;..use.Symfony\Component\Consol |
72aa0 | 65 5c 45 78 63 65 70 74 69 6f 6e 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 | e\Exception\InvalidArgumentExcep |
72ac0 | 74 69 6f 6e 3b 0a 0a 2f 2a 2a 0a 20 2a 20 52 65 70 72 65 73 65 6e 74 73 20 61 20 63 68 6f 69 63 | tion;../**..*.Represents.a.choic |
72ae0 | 65 20 71 75 65 73 74 69 6f 6e 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 46 61 62 69 65 6e | e.question...*..*.@author.Fabien |
72b00 | 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a | .Potencier.<fabien@symfony.com>. |
72b20 | 20 2a 2f 0a 63 6c 61 73 73 20 43 68 6f 69 63 65 51 75 65 73 74 69 6f 6e 20 65 78 74 65 6e 64 73 | .*/.class.ChoiceQuestion.extends |
72b40 | 20 51 75 65 73 74 69 6f 6e 0a 7b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 63 68 6f 69 63 65 73 | .Question.{.....private.$choices |
72b60 | 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 6d 75 6c 74 69 73 65 6c 65 63 74 20 3d 20 66 61 6c | ;.....private.$multiselect.=.fal |
72b80 | 73 65 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 70 72 6f 6d 70 74 20 3d 20 27 20 3e 20 27 3b | se;.....private.$prompt.=.'.>.'; |
72ba0 | 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 65 72 72 6f 72 4d 65 73 73 61 67 65 20 3d 20 27 56 61 | .....private.$errorMessage.=.'Va |
72bc0 | 6c 75 65 20 22 25 73 22 20 69 73 20 69 6e 76 61 6c 69 64 27 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 | lue."%s".is.invalid';....../**.. |
72be0 | 20 20 20 20 2a 20 43 6f 6e 73 74 72 75 63 74 6f 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a | ....*.Constructor.......*......* |
72c00 | 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 71 75 65 73 74 69 6f 6e 20 54 68 65 20 71 75 65 | .@param.string.$question.The.que |
72c20 | 73 74 69 6f 6e 20 74 6f 20 61 73 6b 20 74 6f 20 74 68 65 20 75 73 65 72 0a 20 20 20 20 20 2a 20 | stion.to.ask.to.the.user......*. |
72c40 | 40 70 61 72 61 6d 20 61 72 72 61 79 20 20 24 63 68 6f 69 63 65 73 20 20 54 68 65 20 6c 69 73 74 | @param.array..$choices..The.list |
72c60 | 20 6f 66 20 61 76 61 69 6c 61 62 6c 65 20 63 68 6f 69 63 65 73 0a 20 20 20 20 20 2a 20 40 70 61 | .of.available.choices......*.@pa |
72c80 | 72 61 6d 20 6d 69 78 65 64 20 20 24 64 65 66 61 75 6c 74 20 20 54 68 65 20 64 65 66 61 75 6c 74 | ram.mixed..$default..The.default |
72ca0 | 20 61 6e 73 77 65 72 20 74 6f 20 72 65 74 75 72 6e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 | .answer.to.return......*/.....pu |
72cc0 | 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 74 28 24 71 75 65 73 74 | blic.function.__construct($quest |
72ce0 | 69 6f 6e 2c 20 61 72 72 61 79 20 24 63 68 6f 69 63 65 73 2c 20 24 64 65 66 61 75 6c 74 20 3d 20 | ion,.array.$choices,.$default.=. |
72d00 | 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 70 61 72 65 6e 74 3a 3a 5f 5f 63 6f | null).....{.........parent::__co |
72d20 | 6e 73 74 72 75 63 74 28 24 71 75 65 73 74 69 6f 6e 2c 20 24 64 65 66 61 75 6c 74 29 3b 0a 0a 20 | nstruct($question,.$default);... |
72d40 | 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 63 68 6f 69 63 65 73 20 3d 20 24 63 68 6f 69 63 65 73 | .......$this->choices.=.$choices |
72d60 | 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 65 74 56 61 6c 69 64 61 74 6f 72 28 24 74 | ;.........$this->setValidator($t |
72d80 | 68 69 73 2d 3e 67 65 74 44 65 66 61 75 6c 74 56 61 6c 69 64 61 74 6f 72 28 29 29 3b 0a 20 20 20 | his->getDefaultValidator());.... |
72da0 | 20 20 20 20 20 24 74 68 69 73 2d 3e 73 65 74 41 75 74 6f 63 6f 6d 70 6c 65 74 65 72 56 61 6c 75 | .....$this->setAutocompleterValu |
72dc0 | 65 73 28 24 63 68 6f 69 63 65 73 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 | es($choices);.....}....../**.... |
72de0 | 20 20 2a 20 52 65 74 75 72 6e 73 20 61 76 61 69 6c 61 62 6c 65 20 63 68 6f 69 63 65 73 2e 0a 20 | ..*.Returns.available.choices... |
72e00 | 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 61 72 72 61 79 0a 20 20 20 20 20 | ....*......*.@return.array...... |
72e20 | 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 43 68 6f 69 63 65 | */.....public.function.getChoice |
72e40 | 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e | s().....{.........return.$this-> |
72e60 | 63 68 6f 69 63 65 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 | choices;.....}....../**......*.S |
72e80 | 65 74 73 20 6d 75 6c 74 69 73 65 6c 65 63 74 20 6f 70 74 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 | ets.multiselect.option.......*.. |
72ea0 | 20 20 20 20 2a 20 57 68 65 6e 20 6d 75 6c 74 69 73 65 6c 65 63 74 20 69 73 20 73 65 74 20 74 6f | ....*.When.multiselect.is.set.to |
72ec0 | 20 74 72 75 65 2c 20 6d 75 6c 74 69 70 6c 65 20 63 68 6f 69 63 65 73 20 63 61 6e 20 62 65 20 61 | .true,.multiple.choices.can.be.a |
72ee0 | 6e 73 77 65 72 65 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 62 6f | nswered.......*......*.@param.bo |
72f00 | 6f 6c 20 24 6d 75 6c 74 69 73 65 6c 65 63 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 | ol.$multiselect......*......*.@r |
72f20 | 65 74 75 72 6e 20 43 68 6f 69 63 65 51 75 65 73 74 69 6f 6e 20 54 68 65 20 63 75 72 72 65 6e 74 | eturn.ChoiceQuestion.The.current |
72f40 | 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e | .instance......*/.....public.fun |
72f60 | 63 74 69 6f 6e 20 73 65 74 4d 75 6c 74 69 73 65 6c 65 63 74 28 24 6d 75 6c 74 69 73 65 6c 65 63 | ction.setMultiselect($multiselec |
72f80 | 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6d 75 6c 74 69 73 65 6c | t).....{.........$this->multisel |
72fa0 | 65 63 74 20 3d 20 24 6d 75 6c 74 69 73 65 6c 65 63 74 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 | ect.=.$multiselect;.........$thi |
72fc0 | 73 2d 3e 73 65 74 56 61 6c 69 64 61 74 6f 72 28 24 74 68 69 73 2d 3e 67 65 74 44 65 66 61 75 6c | s->setValidator($this->getDefaul |
72fe0 | 74 56 61 6c 69 64 61 74 6f 72 28 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 | tValidator());..........return.$ |
73000 | 74 68 69 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 | this;.....}....../**......*.Retu |
73020 | 72 6e 73 20 77 68 65 74 68 65 72 20 74 68 65 20 63 68 6f 69 63 65 73 20 61 72 65 20 6d 75 6c 74 | rns.whether.the.choices.are.mult |
73040 | 69 73 65 6c 65 63 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 62 | iselect.......*......*.@return.b |
73060 | 6f 6f 6c 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 | ool......*/.....public.function. |
73080 | 69 73 4d 75 6c 74 69 73 65 6c 65 63 74 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 | isMultiselect().....{.........re |
730a0 | 74 75 72 6e 20 24 74 68 69 73 2d 3e 6d 75 6c 74 69 73 65 6c 65 63 74 3b 0a 20 20 20 20 7d 0a 0a | turn.$this->multiselect;.....}.. |
730c0 | 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 70 72 6f 6d 70 74 20 66 | ..../**......*.Gets.the.prompt.f |
730e0 | 6f 72 20 63 68 6f 69 63 65 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 | or.choices.......*......*.@retur |
73100 | 6e 20 73 74 72 69 6e 67 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 | n.string......*/.....public.func |
73120 | 74 69 6f 6e 20 67 65 74 50 72 6f 6d 70 74 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 | tion.getPrompt().....{.........r |
73140 | 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 70 72 6f 6d 70 74 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 | eturn.$this->prompt;.....}...... |
73160 | 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 74 68 65 20 70 72 6f 6d 70 74 20 66 6f 72 20 63 | /**......*.Sets.the.prompt.for.c |
73180 | 68 6f 69 63 65 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 | hoices.......*......*.@param.str |
731a0 | 69 6e 67 20 24 70 72 6f 6d 70 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 | ing.$prompt......*......*.@retur |
731c0 | 6e 20 43 68 6f 69 63 65 51 75 65 73 74 69 6f 6e 20 54 68 65 20 63 75 72 72 65 6e 74 20 69 6e 73 | n.ChoiceQuestion.The.current.ins |
731e0 | 74 61 6e 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f | tance......*/.....public.functio |
73200 | 6e 20 73 65 74 50 72 6f 6d 70 74 28 24 70 72 6f 6d 70 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 | n.setPrompt($prompt).....{...... |
73220 | 20 20 20 24 74 68 69 73 2d 3e 70 72 6f 6d 70 74 20 3d 20 24 70 72 6f 6d 70 74 3b 0a 0a 20 20 20 | ...$this->prompt.=.$prompt;..... |
73240 | 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a | .....return.$this;.....}....../* |
73260 | 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 74 68 65 20 65 72 72 6f 72 20 6d 65 73 73 61 67 65 20 | *......*.Sets.the.error.message. |
73280 | 66 6f 72 20 69 6e 76 61 6c 69 64 20 76 61 6c 75 65 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 | for.invalid.values.......*...... |
732a0 | 2a 20 54 68 65 20 65 72 72 6f 72 20 6d 65 73 73 61 67 65 20 68 61 73 20 61 20 73 74 72 69 6e 67 | *.The.error.message.has.a.string |
732c0 | 20 70 6c 61 63 65 68 6f 6c 64 65 72 20 28 25 73 29 20 66 6f 72 20 74 68 65 20 69 6e 76 61 6c 69 | .placeholder.(%s).for.the.invali |
732e0 | 64 20 76 61 6c 75 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 | d.value.......*......*.@param.st |
73300 | 72 69 6e 67 20 24 65 72 72 6f 72 4d 65 73 73 61 67 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a | ring.$errorMessage......*......* |
73320 | 20 40 72 65 74 75 72 6e 20 43 68 6f 69 63 65 51 75 65 73 74 69 6f 6e 20 54 68 65 20 63 75 72 72 | .@return.ChoiceQuestion.The.curr |
73340 | 65 6e 74 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 | ent.instance......*/.....public. |
73360 | 66 75 6e 63 74 69 6f 6e 20 73 65 74 45 72 72 6f 72 4d 65 73 73 61 67 65 28 24 65 72 72 6f 72 4d | function.setErrorMessage($errorM |
73380 | 65 73 73 61 67 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 65 72 72 | essage).....{.........$this->err |
733a0 | 6f 72 4d 65 73 73 61 67 65 20 3d 20 24 65 72 72 6f 72 4d 65 73 73 61 67 65 3b 0a 20 20 20 20 20 | orMessage.=.$errorMessage;...... |
733c0 | 20 20 20 24 74 68 69 73 2d 3e 73 65 74 56 61 6c 69 64 61 74 6f 72 28 24 74 68 69 73 2d 3e 67 65 | ...$this->setValidator($this->ge |
733e0 | 74 44 65 66 61 75 6c 74 56 61 6c 69 64 61 74 6f 72 28 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 72 | tDefaultValidator());..........r |
73400 | 65 74 75 72 6e 20 24 74 68 69 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 | eturn.$this;.....}....../**..... |
73420 | 20 2a 20 52 65 74 75 72 6e 73 20 74 68 65 20 64 65 66 61 75 6c 74 20 61 6e 73 77 65 72 20 76 61 | .*.Returns.the.default.answer.va |
73440 | 6c 69 64 61 74 6f 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 63 | lidator.......*......*.@return.c |
73460 | 61 6c 6c 61 62 6c 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 | allable......*/.....private.func |
73480 | 74 69 6f 6e 20 67 65 74 44 65 66 61 75 6c 74 56 61 6c 69 64 61 74 6f 72 28 29 0a 20 20 20 20 7b | tion.getDefaultValidator().....{ |
734a0 | 0a 20 20 20 20 20 20 20 20 24 63 68 6f 69 63 65 73 20 3d 20 24 74 68 69 73 2d 3e 63 68 6f 69 63 | .........$choices.=.$this->choic |
734c0 | 65 73 3b 0a 20 20 20 20 20 20 20 20 24 65 72 72 6f 72 4d 65 73 73 61 67 65 20 3d 20 24 74 68 69 | es;.........$errorMessage.=.$thi |
734e0 | 73 2d 3e 65 72 72 6f 72 4d 65 73 73 61 67 65 3b 0a 20 20 20 20 20 20 20 20 24 6d 75 6c 74 69 73 | s->errorMessage;.........$multis |
73500 | 65 6c 65 63 74 20 3d 20 24 74 68 69 73 2d 3e 6d 75 6c 74 69 73 65 6c 65 63 74 3b 0a 20 20 20 20 | elect.=.$this->multiselect;..... |
73520 | 20 20 20 20 24 69 73 41 73 73 6f 63 20 3d 20 24 74 68 69 73 2d 3e 69 73 41 73 73 6f 63 28 24 63 | ....$isAssoc.=.$this->isAssoc($c |
73540 | 68 6f 69 63 65 73 29 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 66 75 6e 63 74 69 6f | hoices);..........return.functio |
73560 | 6e 20 28 24 73 65 6c 65 63 74 65 64 29 20 75 73 65 20 28 24 63 68 6f 69 63 65 73 2c 20 24 65 72 | n.($selected).use.($choices,.$er |
73580 | 72 6f 72 4d 65 73 73 61 67 65 2c 20 24 6d 75 6c 74 69 73 65 6c 65 63 74 2c 20 24 69 73 41 73 73 | rorMessage,.$multiselect,.$isAss |
735a0 | 6f 63 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 43 6f 6c 6c 61 70 73 65 20 61 6c | oc).{.............//.Collapse.al |
735c0 | 6c 20 73 70 61 63 65 73 2e 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 73 65 6c 65 63 74 65 64 43 | l.spaces..............$selectedC |
735e0 | 68 6f 69 63 65 73 20 3d 20 73 74 72 5f 72 65 70 6c 61 63 65 28 27 20 27 2c 20 27 27 2c 20 24 73 | hoices.=.str_replace('.',.'',.$s |
73600 | 65 6c 65 63 74 65 64 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 6d 75 6c 74 | elected);..............if.($mult |
73620 | 69 73 65 6c 65 63 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 43 68 | iselect).{.................//.Ch |
73640 | 65 63 6b 20 66 6f 72 20 61 20 73 65 70 61 72 61 74 65 64 20 63 6f 6d 6d 61 20 76 61 6c 75 65 73 | eck.for.a.separated.comma.values |
73660 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 21 70 72 65 67 5f 6d 61 74 63 68 | .................if.(!preg_match |
73680 | 28 27 2f 5e 5b 61 2d 7a 41 2d 5a 30 2d 39 5f 2d 5d 2b 28 3f 3a 2c 5b 61 2d 7a 41 2d 5a 30 2d 39 | ('/^[a-zA-Z0-9_-]+(?:,[a-zA-Z0-9 |
736a0 | 5f 2d 5d 2b 29 2a 24 2f 27 2c 20 24 73 65 6c 65 63 74 65 64 43 68 6f 69 63 65 73 2c 20 24 6d 61 | _-]+)*$/',.$selectedChoices,.$ma |
736c0 | 74 63 68 65 73 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 | tches)).{.....................th |
736e0 | 72 6f 77 20 6e 65 77 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e | row.new.InvalidArgumentException |
73700 | 28 73 70 72 69 6e 74 66 28 24 65 72 72 6f 72 4d 65 73 73 61 67 65 2c 20 24 73 65 6c 65 63 74 65 | (sprintf($errorMessage,.$selecte |
73720 | 64 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 | d));.................}.......... |
73740 | 20 20 20 20 20 20 20 24 73 65 6c 65 63 74 65 64 43 68 6f 69 63 65 73 20 3d 20 65 78 70 6c 6f 64 | .......$selectedChoices.=.explod |
73760 | 65 28 27 2c 27 2c 20 24 73 65 6c 65 63 74 65 64 43 68 6f 69 63 65 73 29 3b 0a 20 20 20 20 20 20 | e(',',.$selectedChoices);....... |
73780 | 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 | ......}.else.{.................$ |
737a0 | 73 65 6c 65 63 74 65 64 43 68 6f 69 63 65 73 20 3d 20 61 72 72 61 79 28 24 73 65 6c 65 63 74 65 | selectedChoices.=.array($selecte |
737c0 | 64 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 | d);.............}..............$ |
737e0 | 6d 75 6c 74 69 73 65 6c 65 63 74 43 68 6f 69 63 65 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 | multiselectChoices.=.array();... |
73800 | 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 73 65 6c 65 63 74 65 64 43 68 6f 69 | ..........foreach.($selectedChoi |
73820 | 63 65 73 20 61 73 20 24 76 61 6c 75 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ces.as.$value).{................ |
73840 | 20 24 72 65 73 75 6c 74 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 | .$results.=.array();............ |
73860 | 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 63 68 6f 69 63 65 73 20 61 73 20 24 6b 65 79 20 3d | .....foreach.($choices.as.$key.= |
73880 | 3e 20 24 63 68 6f 69 63 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | >.$choice).{.................... |
738a0 | 20 69 66 20 28 24 63 68 6f 69 63 65 20 3d 3d 3d 20 24 76 61 6c 75 65 29 20 7b 0a 20 20 20 20 20 | .if.($choice.===.$value).{...... |
738c0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 72 65 73 75 6c 74 73 5b 5d 20 3d 20 | ...................$results[].=. |
738e0 | 24 6b 65 79 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 | $key;.....................}..... |
73900 | 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 | ............}..................i |
73920 | 66 20 28 63 6f 75 6e 74 28 24 72 65 73 75 6c 74 73 29 20 3e 20 31 29 20 7b 0a 20 20 20 20 20 20 | f.(count($results).>.1).{....... |
73940 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 61 6c 69 64 41 | ..............throw.new.InvalidA |
73960 | 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 73 70 72 69 6e 74 66 28 27 54 68 65 20 70 72 | rgumentException(sprintf('The.pr |
73980 | 6f 76 69 64 65 64 20 61 6e 73 77 65 72 20 69 73 20 61 6d 62 69 67 75 6f 75 73 2e 20 56 61 6c 75 | ovided.answer.is.ambiguous..Valu |
739a0 | 65 20 73 68 6f 75 6c 64 20 62 65 20 6f 6e 65 20 6f 66 20 25 73 2e 27 2c 20 69 6d 70 6c 6f 64 65 | e.should.be.one.of.%s.',.implode |
739c0 | 28 27 20 6f 72 20 27 2c 20 24 72 65 73 75 6c 74 73 29 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 | ('.or.',.$results)));........... |
739e0 | 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 72 65 73 75 6c 74 | ......}..................$result |
73a00 | 20 3d 20 61 72 72 61 79 5f 73 65 61 72 63 68 28 24 76 61 6c 75 65 2c 20 24 63 68 6f 69 63 65 73 | .=.array_search($value,.$choices |
73a20 | 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 21 24 69 73 41 73 73 6f | );..................if.(!$isAsso |
73a40 | 63 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 66 61 6c | c).{.....................if.(fal |
73a60 | 73 65 20 21 3d 3d 20 24 72 65 73 75 6c 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | se.!==.$result).{............... |
73a80 | 20 20 20 20 20 20 20 20 20 20 24 72 65 73 75 6c 74 20 3d 20 24 63 68 6f 69 63 65 73 5b 24 72 65 | ..........$result.=.$choices[$re |
73aa0 | 73 75 6c 74 5d 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 | sult];.....................}.els |
73ac0 | 65 69 66 20 28 69 73 73 65 74 28 24 63 68 6f 69 63 65 73 5b 24 76 61 6c 75 65 5d 29 29 20 7b 0a | eif.(isset($choices[$value])).{. |
73ae0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 72 65 73 75 6c 74 20 | ........................$result. |
73b00 | 3d 20 24 63 68 6f 69 63 65 73 5b 24 76 61 6c 75 65 5d 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | =.$choices[$value];............. |
73b20 | 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 | ........}.................}.else |
73b40 | 69 66 20 28 66 61 6c 73 65 20 3d 3d 3d 20 24 72 65 73 75 6c 74 20 26 26 20 69 73 73 65 74 28 24 | if.(false.===.$result.&&.isset($ |
73b60 | 63 68 6f 69 63 65 73 5b 24 76 61 6c 75 65 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | choices[$value])).{............. |
73b80 | 20 20 20 20 20 20 20 20 24 72 65 73 75 6c 74 20 3d 20 24 76 61 6c 75 65 3b 0a 20 20 20 20 20 20 | ........$result.=.$value;....... |
73ba0 | 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 | ..........}..................if. |
73bc0 | 28 66 61 6c 73 65 20 3d 3d 3d 20 24 72 65 73 75 6c 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | (false.===.$result).{........... |
73be0 | 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 61 6c 69 64 41 72 67 75 6d | ..........throw.new.InvalidArgum |
73c00 | 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 73 70 72 69 6e 74 66 28 24 65 72 72 6f 72 4d 65 73 73 61 | entException(sprintf($errorMessa |
73c20 | 67 65 2c 20 24 76 61 6c 75 65 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a | ge,.$value));.................}. |
73c40 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 75 6c 74 69 73 65 6c 65 63 74 43 68 6f | .................$multiselectCho |
73c60 | 69 63 65 73 5b 5d 20 3d 20 28 73 74 72 69 6e 67 29 20 24 72 65 73 75 6c 74 3b 0a 20 20 20 20 20 | ices[].=.(string).$result;...... |
73c80 | 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 6d 75 6c 74 69 | .......}..............if.($multi |
73ca0 | 73 65 6c 65 63 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e | select).{.................return |
73cc0 | 20 24 6d 75 6c 74 69 73 65 6c 65 63 74 43 68 6f 69 63 65 73 3b 0a 20 20 20 20 20 20 20 20 20 20 | .$multiselectChoices;........... |
73ce0 | 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 63 75 72 72 65 6e 74 28 | ..}..............return.current( |
73d00 | 24 6d 75 6c 74 69 73 65 6c 65 63 74 43 68 6f 69 63 65 73 29 3b 0a 20 20 20 20 20 20 20 20 7d 3b | $multiselectChoices);.........}; |
73d20 | 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 | .....}.}.<?php../*..*.This.file. |
73d40 | 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a | is.part.of.the.Symfony.package.. |
73d60 | 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 | .*..*.(c).Fabien.Potencier.<fabi |
73d80 | 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 | en@symfony.com>..*..*.For.the.fu |
73da0 | 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 | ll.copyright.and.license.informa |
73dc0 | 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a | tion,.please.view.the.LICENSE..* |
73de0 | 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 | .file.that.was.distributed.with. |
73e00 | 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 | this.source.code...*/..namespace |
73e20 | 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 51 75 65 73 74 | .Symfony\Component\Console\Quest |
73e40 | 69 6f 6e 3b 0a 0a 2f 2a 2a 0a 20 2a 20 52 65 70 72 65 73 65 6e 74 73 20 61 20 79 65 73 2f 6e 6f | ion;../**..*.Represents.a.yes/no |
73e60 | 20 71 75 65 73 74 69 6f 6e 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 46 61 62 69 65 6e 20 | .question...*..*.@author.Fabien. |
73e80 | 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 | Potencier.<fabien@symfony.com>.. |
73ea0 | 2a 2f 0a 63 6c 61 73 73 20 43 6f 6e 66 69 72 6d 61 74 69 6f 6e 51 75 65 73 74 69 6f 6e 20 65 78 | */.class.ConfirmationQuestion.ex |
73ec0 | 74 65 6e 64 73 20 51 75 65 73 74 69 6f 6e 0a 7b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 74 72 | tends.Question.{.....private.$tr |
73ee0 | 75 65 41 6e 73 77 65 72 52 65 67 65 78 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 43 | ueAnswerRegex;....../**......*.C |
73f00 | 6f 6e 73 74 72 75 63 74 6f 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d | onstructor.......*......*.@param |
73f20 | 20 73 74 72 69 6e 67 20 24 71 75 65 73 74 69 6f 6e 20 20 20 20 20 20 20 20 54 68 65 20 71 75 65 | .string.$question........The.que |
73f40 | 73 74 69 6f 6e 20 74 6f 20 61 73 6b 20 74 6f 20 74 68 65 20 75 73 65 72 0a 20 20 20 20 20 2a 20 | stion.to.ask.to.the.user......*. |
73f60 | 40 70 61 72 61 6d 20 62 6f 6f 6c 20 20 20 24 64 65 66 61 75 6c 74 20 20 20 20 20 20 20 20 20 54 | @param.bool...$default.........T |
73f80 | 68 65 20 64 65 66 61 75 6c 74 20 61 6e 73 77 65 72 20 74 6f 20 72 65 74 75 72 6e 2c 20 74 72 75 | he.default.answer.to.return,.tru |
73fa0 | 65 20 6f 72 20 66 61 6c 73 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 | e.or.false......*.@param.string. |
73fc0 | 24 74 72 75 65 41 6e 73 77 65 72 52 65 67 65 78 20 41 20 72 65 67 65 78 20 74 6f 20 6d 61 74 63 | $trueAnswerRegex.A.regex.to.matc |
73fe0 | 68 20 74 68 65 20 22 79 65 73 22 20 61 6e 73 77 65 72 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 | h.the."yes".answer......*/.....p |
74000 | 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 74 28 24 71 75 65 73 | ublic.function.__construct($ques |
74020 | 74 69 6f 6e 2c 20 24 64 65 66 61 75 6c 74 20 3d 20 74 72 75 65 2c 20 24 74 72 75 65 41 6e 73 77 | tion,.$default.=.true,.$trueAnsw |
74040 | 65 72 52 65 67 65 78 20 3d 20 27 2f 5e 79 2f 69 27 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 | erRegex.=.'/^y/i').....{........ |
74060 | 20 70 61 72 65 6e 74 3a 3a 5f 5f 63 6f 6e 73 74 72 75 63 74 28 24 71 75 65 73 74 69 6f 6e 2c 20 | .parent::__construct($question,. |
74080 | 28 62 6f 6f 6c 29 20 24 64 65 66 61 75 6c 74 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 | (bool).$default);..........$this |
740a0 | 2d 3e 74 72 75 65 41 6e 73 77 65 72 52 65 67 65 78 20 3d 20 24 74 72 75 65 41 6e 73 77 65 72 52 | ->trueAnswerRegex.=.$trueAnswerR |
740c0 | 65 67 65 78 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 65 74 4e 6f 72 6d 61 6c 69 7a | egex;.........$this->setNormaliz |
740e0 | 65 72 28 24 74 68 69 73 2d 3e 67 65 74 44 65 66 61 75 6c 74 4e 6f 72 6d 61 6c 69 7a 65 72 28 29 | er($this->getDefaultNormalizer() |
74100 | 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 | );.....}....../**......*.Returns |
74120 | 20 74 68 65 20 64 65 66 61 75 6c 74 20 61 6e 73 77 65 72 20 6e 6f 72 6d 61 6c 69 7a 65 72 2e 0a | .the.default.answer.normalizer.. |
74140 | 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 63 61 6c 6c 61 62 6c 65 0a 20 | .....*......*.@return.callable.. |
74160 | 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 44 | ....*/.....private.function.getD |
74180 | 65 66 61 75 6c 74 4e 6f 72 6d 61 6c 69 7a 65 72 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 | efaultNormalizer().....{........ |
741a0 | 20 24 64 65 66 61 75 6c 74 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 44 65 66 61 75 6c 74 28 29 3b | .$default.=.$this->getDefault(); |
741c0 | 0a 20 20 20 20 20 20 20 20 24 72 65 67 65 78 20 3d 20 24 74 68 69 73 2d 3e 74 72 75 65 41 6e 73 | .........$regex.=.$this->trueAns |
741e0 | 77 65 72 52 65 67 65 78 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 66 75 6e 63 74 69 | werRegex;..........return.functi |
74200 | 6f 6e 20 28 24 61 6e 73 77 65 72 29 20 75 73 65 20 28 24 64 65 66 61 75 6c 74 2c 20 24 72 65 67 | on.($answer).use.($default,.$reg |
74220 | 65 78 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 69 73 5f 62 6f 6f 6c 28 24 61 | ex).{.............if.(is_bool($a |
74240 | 6e 73 77 65 72 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e | nswer)).{.................return |
74260 | 20 24 61 6e 73 77 65 72 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 | .$answer;.............}......... |
74280 | 20 20 20 20 20 24 61 6e 73 77 65 72 49 73 54 72 75 65 20 3d 20 28 62 6f 6f 6c 29 20 70 72 65 67 | .....$answerIsTrue.=.(bool).preg |
742a0 | 5f 6d 61 74 63 68 28 24 72 65 67 65 78 2c 20 24 61 6e 73 77 65 72 29 3b 0a 20 20 20 20 20 20 20 | _match($regex,.$answer);........ |
742c0 | 20 20 20 20 20 69 66 20 28 66 61 6c 73 65 20 3d 3d 3d 20 24 64 65 66 61 75 6c 74 29 20 7b 0a 20 | .....if.(false.===.$default).{.. |
742e0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 61 6e 73 77 65 72 20 26 26 | ...............return.$answer.&& |
74300 | 20 24 61 6e 73 77 65 72 49 73 54 72 75 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 | .$answerIsTrue;.............}... |
74320 | 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 21 24 61 6e 73 77 65 72 20 7c 7c 20 24 61 | ...........return.!$answer.||.$a |
74340 | 6e 73 77 65 72 49 73 54 72 75 65 3b 0a 20 20 20 20 20 20 20 20 7d 3b 0a 20 20 20 20 7d 0a 7d 0a | nswerIsTrue;.........};.....}.}. |
74360 | 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f | <?php../*..*.This.file.is.part.o |
74380 | 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 | f.the.Symfony.package...*..*.(c) |
743a0 | 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e | .Fabien.Potencier.<fabien@symfon |
743c0 | 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 | y.com>..*..*.For.the.full.copyri |
743e0 | 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 | ght.and.license.information,.ple |
74400 | 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 | ase.view.the.LICENSE..*.file.tha |
74420 | 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 | t.was.distributed.with.this.sour |
74440 | 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c | ce.code...*/..namespace.Symfony\ |
74460 | 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 43 6f 6d 6d 61 6e 64 3b 0a 0a 75 73 65 20 | Component\Console\Command;..use. |
74480 | 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 48 65 6c 70 65 72 | Symfony\Component\Console\Helper |
744a0 | 5c 44 65 73 63 72 69 70 74 6f 72 48 65 6c 70 65 72 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 | \DescriptorHelper;.use.Symfony\C |
744c0 | 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 5c 49 6e 70 75 74 41 72 67 75 | omponent\Console\Input\InputArgu |
744e0 | 6d 65 6e 74 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 | ment;.use.Symfony\Component\Cons |
74500 | 6f 6c 65 5c 49 6e 70 75 74 5c 49 6e 70 75 74 4f 70 74 69 6f 6e 3b 0a 75 73 65 20 53 79 6d 66 6f | ole\Input\InputOption;.use.Symfo |
74520 | 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 5c 49 6e 70 75 74 | ny\Component\Console\Input\Input |
74540 | 49 6e 74 65 72 66 61 63 65 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 | Interface;.use.Symfony\Component |
74560 | 5c 43 6f 6e 73 6f 6c 65 5c 4f 75 74 70 75 74 5c 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 3b | \Console\Output\OutputInterface; |
74580 | 0a 0a 2f 2a 2a 0a 20 2a 20 48 65 6c 70 43 6f 6d 6d 61 6e 64 20 64 69 73 70 6c 61 79 73 20 74 68 | ../**..*.HelpCommand.displays.th |
745a0 | 65 20 68 65 6c 70 20 66 6f 72 20 61 20 67 69 76 65 6e 20 63 6f 6d 6d 61 6e 64 2e 0a 20 2a 0a 20 | e.help.for.a.given.command...*.. |
745c0 | 2a 20 40 61 75 74 68 6f 72 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 | *.@author.Fabien.Potencier.<fabi |
745e0 | 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 48 65 6c 70 43 6f | en@symfony.com>..*/.class.HelpCo |
74600 | 6d 6d 61 6e 64 20 65 78 74 65 6e 64 73 20 43 6f 6d 6d 61 6e 64 0a 7b 0a 20 20 20 20 70 72 69 76 | mmand.extends.Command.{.....priv |
74620 | 61 74 65 20 24 63 6f 6d 6d 61 6e 64 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 | ate.$command;....../**......*.{@ |
74640 | 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 6f 74 65 63 74 65 | inheritdoc}......*/.....protecte |
74660 | 64 20 66 75 6e 63 74 69 6f 6e 20 63 6f 6e 66 69 67 75 72 65 28 29 0a 20 20 20 20 7b 0a 20 20 20 | d.function.configure().....{.... |
74680 | 20 20 20 20 20 24 74 68 69 73 2d 3e 69 67 6e 6f 72 65 56 61 6c 69 64 61 74 69 6f 6e 45 72 72 6f | .....$this->ignoreValidationErro |
746a0 | 72 73 28 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 0a 20 20 20 20 20 20 20 20 20 20 20 | rs();..........$this............ |
746c0 | 20 2d 3e 73 65 74 4e 61 6d 65 28 27 68 65 6c 70 27 29 0a 20 20 20 20 20 20 20 20 20 20 20 20 2d | .->setName('help').............- |
746e0 | 3e 73 65 74 44 65 66 69 6e 69 74 69 6f 6e 28 61 72 72 61 79 28 0a 20 20 20 20 20 20 20 20 20 20 | >setDefinition(array(........... |
74700 | 20 20 20 20 20 20 6e 65 77 20 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 28 27 63 6f 6d 6d 61 6e 64 | ......new.InputArgument('command |
74720 | 5f 6e 61 6d 65 27 2c 20 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 3a 3a 4f 50 54 49 4f 4e 41 4c 2c | _name',.InputArgument::OPTIONAL, |
74740 | 20 27 54 68 65 20 63 6f 6d 6d 61 6e 64 20 6e 61 6d 65 27 2c 20 27 68 65 6c 70 27 29 2c 0a 20 20 | .'The.command.name',.'help'),... |
74760 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6e 65 77 20 49 6e 70 75 74 4f 70 74 69 6f 6e 28 27 66 | ..............new.InputOption('f |
74780 | 6f 72 6d 61 74 27 2c 20 6e 75 6c 6c 2c 20 49 6e 70 75 74 4f 70 74 69 6f 6e 3a 3a 56 41 4c 55 45 | ormat',.null,.InputOption::VALUE |
747a0 | 5f 52 45 51 55 49 52 45 44 2c 20 27 54 68 65 20 6f 75 74 70 75 74 20 66 6f 72 6d 61 74 20 28 74 | _REQUIRED,.'The.output.format.(t |
747c0 | 78 74 2c 20 78 6d 6c 2c 20 6a 73 6f 6e 2c 20 6f 72 20 6d 64 29 27 2c 20 27 74 78 74 27 29 2c 0a | xt,.xml,.json,.or.md)',.'txt'),. |
747e0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6e 65 77 20 49 6e 70 75 74 4f 70 74 69 6f 6e 28 | ................new.InputOption( |
74800 | 27 72 61 77 27 2c 20 6e 75 6c 6c 2c 20 49 6e 70 75 74 4f 70 74 69 6f 6e 3a 3a 56 41 4c 55 45 5f | 'raw',.null,.InputOption::VALUE_ |
74820 | 4e 4f 4e 45 2c 20 27 54 6f 20 6f 75 74 70 75 74 20 72 61 77 20 63 6f 6d 6d 61 6e 64 20 68 65 6c | NONE,.'To.output.raw.command.hel |
74840 | 70 27 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 29 29 0a 20 20 20 20 20 20 20 20 20 20 20 20 | p'),.............))............. |
74860 | 2d 3e 73 65 74 44 65 73 63 72 69 70 74 69 6f 6e 28 27 44 69 73 70 6c 61 79 73 20 68 65 6c 70 20 | ->setDescription('Displays.help. |
74880 | 66 6f 72 20 61 20 63 6f 6d 6d 61 6e 64 27 29 0a 20 20 20 20 20 20 20 20 20 20 20 20 2d 3e 73 65 | for.a.command').............->se |
748a0 | 74 48 65 6c 70 28 3c 3c 3c 27 45 4f 46 27 0a 54 68 65 20 3c 69 6e 66 6f 3e 25 63 6f 6d 6d 61 6e | tHelp(<<<'EOF'.The.<info>%comman |
748c0 | 64 2e 6e 61 6d 65 25 3c 2f 69 6e 66 6f 3e 20 63 6f 6d 6d 61 6e 64 20 64 69 73 70 6c 61 79 73 20 | d.name%</info>.command.displays. |
748e0 | 68 65 6c 70 20 66 6f 72 20 61 20 67 69 76 65 6e 20 63 6f 6d 6d 61 6e 64 3a 0a 0a 20 20 3c 69 6e | help.for.a.given.command:....<in |
74900 | 66 6f 3e 70 68 70 20 25 63 6f 6d 6d 61 6e 64 2e 66 75 6c 6c 5f 6e 61 6d 65 25 20 6c 69 73 74 3c | fo>php.%command.full_name%.list< |
74920 | 2f 69 6e 66 6f 3e 0a 0a 59 6f 75 20 63 61 6e 20 61 6c 73 6f 20 6f 75 74 70 75 74 20 74 68 65 20 | /info>..You.can.also.output.the. |
74940 | 68 65 6c 70 20 69 6e 20 6f 74 68 65 72 20 66 6f 72 6d 61 74 73 20 62 79 20 75 73 69 6e 67 20 74 | help.in.other.formats.by.using.t |
74960 | 68 65 20 3c 63 6f 6d 6d 65 6e 74 3e 2d 2d 66 6f 72 6d 61 74 3c 2f 63 6f 6d 6d 65 6e 74 3e 20 6f | he.<comment>--format</comment>.o |
74980 | 70 74 69 6f 6e 3a 0a 0a 20 20 3c 69 6e 66 6f 3e 70 68 70 20 25 63 6f 6d 6d 61 6e 64 2e 66 75 6c | ption:....<info>php.%command.ful |
749a0 | 6c 5f 6e 61 6d 65 25 20 2d 2d 66 6f 72 6d 61 74 3d 78 6d 6c 20 6c 69 73 74 3c 2f 69 6e 66 6f 3e | l_name%.--format=xml.list</info> |
749c0 | 0a 0a 54 6f 20 64 69 73 70 6c 61 79 20 74 68 65 20 6c 69 73 74 20 6f 66 20 61 76 61 69 6c 61 62 | ..To.display.the.list.of.availab |
749e0 | 6c 65 20 63 6f 6d 6d 61 6e 64 73 2c 20 70 6c 65 61 73 65 20 75 73 65 20 74 68 65 20 3c 69 6e 66 | le.commands,.please.use.the.<inf |
74a00 | 6f 3e 6c 69 73 74 3c 2f 69 6e 66 6f 3e 20 63 6f 6d 6d 61 6e 64 2e 0a 45 4f 46 0a 20 20 20 20 20 | o>list</info>.command..EOF...... |
74a20 | 20 20 20 20 20 20 20 29 0a 20 20 20 20 20 20 20 20 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a | .......).........;.....}....../* |
74a40 | 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 74 68 65 20 63 6f 6d 6d 61 6e 64 2e 0a 20 20 20 20 20 | *......*.Sets.the.command....... |
74a60 | 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 43 6f 6d 6d 61 6e 64 20 24 63 6f 6d 6d 61 6e 64 | *......*.@param.Command.$command |
74a80 | 20 54 68 65 20 63 6f 6d 6d 61 6e 64 20 74 6f 20 73 65 74 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 | .The.command.to.set......*/..... |
74aa0 | 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 43 6f 6d 6d 61 6e 64 28 43 6f 6d 6d 61 | public.function.setCommand(Comma |
74ac0 | 6e 64 20 24 63 6f 6d 6d 61 6e 64 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 | nd.$command).....{.........$this |
74ae0 | 2d 3e 63 6f 6d 6d 61 6e 64 20 3d 20 24 63 6f 6d 6d 61 6e 64 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 | ->command.=.$command;.....}..... |
74b00 | 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a | ./**......*.{@inheritdoc}......* |
74b20 | 2f 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 65 78 65 63 75 74 65 | /.....protected.function.execute |
74b40 | 28 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 69 6e 70 75 74 2c 20 4f 75 74 70 75 74 49 6e | (InputInterface.$input,.OutputIn |
74b60 | 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 | terface.$output).....{.........i |
74b80 | 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 74 68 69 73 2d 3e 63 6f 6d 6d 61 6e 64 29 20 7b 0a 20 20 | f.(null.===.$this->command).{... |
74ba0 | 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 63 6f 6d 6d 61 6e 64 20 3d 20 24 74 68 69 73 | ..........$this->command.=.$this |
74bc0 | 2d 3e 67 65 74 41 70 70 6c 69 63 61 74 69 6f 6e 28 29 2d 3e 66 69 6e 64 28 24 69 6e 70 75 74 2d | ->getApplication()->find($input- |
74be0 | 3e 67 65 74 41 72 67 75 6d 65 6e 74 28 27 63 6f 6d 6d 61 6e 64 5f 6e 61 6d 65 27 29 29 3b 0a 20 | >getArgument('command_name'));.. |
74c00 | 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 68 65 6c 70 65 72 20 3d 20 6e 65 77 20 | .......}..........$helper.=.new. |
74c20 | 44 65 73 63 72 69 70 74 6f 72 48 65 6c 70 65 72 28 29 3b 0a 20 20 20 20 20 20 20 20 24 68 65 6c | DescriptorHelper();.........$hel |
74c40 | 70 65 72 2d 3e 64 65 73 63 72 69 62 65 28 24 6f 75 74 70 75 74 2c 20 24 74 68 69 73 2d 3e 63 6f | per->describe($output,.$this->co |
74c60 | 6d 6d 61 6e 64 2c 20 61 72 72 61 79 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 66 6f 72 6d 61 | mmand,.array(.............'forma |
74c80 | 74 27 20 3d 3e 20 24 69 6e 70 75 74 2d 3e 67 65 74 4f 70 74 69 6f 6e 28 27 66 6f 72 6d 61 74 27 | t'.=>.$input->getOption('format' |
74ca0 | 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 72 61 77 5f 74 65 78 74 27 20 3d 3e 20 24 69 6e | ),.............'raw_text'.=>.$in |
74cc0 | 70 75 74 2d 3e 67 65 74 4f 70 74 69 6f 6e 28 27 72 61 77 27 29 2c 0a 20 20 20 20 20 20 20 20 29 | put->getOption('raw'),.........) |
74ce0 | 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 63 6f 6d 6d 61 6e 64 20 3d 20 6e 75 6c | );..........$this->command.=.nul |
74d00 | 6c 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c | l;.....}.}.<?php../*..*.This.fil |
74d20 | 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 | e.is.part.of.the.Symfony.package |
74d40 | 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 | ...*..*.(c).Fabien.Potencier.<fa |
74d60 | 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 | bien@symfony.com>..*..*.For.the. |
74d80 | 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 | full.copyright.and.license.infor |
74da0 | 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a | mation,.please.view.the.LICENSE. |
74dc0 | 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 | .*.file.that.was.distributed.wit |
74de0 | 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 | h.this.source.code...*/..namespa |
74e00 | 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 43 6f 6d | ce.Symfony\Component\Console\Com |
74e20 | 6d 61 6e 64 3b 0a 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e | mand;..use.Symfony\Component\Con |
74e40 | 73 6f 6c 65 5c 45 78 63 65 70 74 69 6f 6e 5c 45 78 63 65 70 74 69 6f 6e 49 6e 74 65 72 66 61 63 | sole\Exception\ExceptionInterfac |
74e60 | 65 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 | e;.use.Symfony\Component\Console |
74e80 | 5c 49 6e 70 75 74 5c 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 3b 0a 75 73 65 20 53 79 6d 66 | \Input\InputDefinition;.use.Symf |
74ea0 | 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 5c 49 6e 70 75 | ony\Component\Console\Input\Inpu |
74ec0 | 74 4f 70 74 69 6f 6e 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 | tOption;.use.Symfony\Component\C |
74ee0 | 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 5c 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 3b 0a 75 73 65 20 | onsole\Input\InputArgument;.use. |
74f00 | 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 5c | Symfony\Component\Console\Input\ |
74f20 | 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 | InputInterface;.use.Symfony\Comp |
74f40 | 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 4f 75 74 70 75 74 5c 4f 75 74 70 75 74 49 6e 74 65 72 | onent\Console\Output\OutputInter |
74f60 | 66 61 63 65 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 | face;.use.Symfony\Component\Cons |
74f80 | 6f 6c 65 5c 41 70 70 6c 69 63 61 74 69 6f 6e 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d | ole\Application;.use.Symfony\Com |
74fa0 | 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 48 65 6c 70 65 72 5c 48 65 6c 70 65 72 53 65 74 3b | ponent\Console\Helper\HelperSet; |
74fc0 | 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 | .use.Symfony\Component\Console\E |
74fe0 | 78 63 65 70 74 69 6f 6e 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f | xception\InvalidArgumentExceptio |
75000 | 6e 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 | n;.use.Symfony\Component\Console |
75020 | 5c 45 78 63 65 70 74 69 6f 6e 5c 4c 6f 67 69 63 45 78 63 65 70 74 69 6f 6e 3b 0a 0a 2f 2a 2a 0a | \Exception\LogicException;../**. |
75040 | 20 2a 20 42 61 73 65 20 63 6c 61 73 73 20 66 6f 72 20 61 6c 6c 20 63 6f 6d 6d 61 6e 64 73 2e 0a | .*.Base.class.for.all.commands.. |
75060 | 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c | .*..*.@author.Fabien.Potencier.< |
75080 | 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 43 6f | fabien@symfony.com>..*/.class.Co |
750a0 | 6d 6d 61 6e 64 0a 7b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 61 70 70 6c 69 63 61 74 69 6f 6e | mmand.{.....private.$application |
750c0 | 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 6e 61 6d 65 3b 0a 20 20 20 20 70 72 69 76 61 74 65 | ;.....private.$name;.....private |
750e0 | 20 24 70 72 6f 63 65 73 73 54 69 74 6c 65 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 61 6c 69 | .$processTitle;.....private.$ali |
75100 | 61 73 65 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 64 65 66 | ases.=.array();.....private.$def |
75120 | 69 6e 69 74 69 6f 6e 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 68 65 6c 70 3b 0a 20 20 20 20 | inition;.....private.$help;..... |
75140 | 70 72 69 76 61 74 65 20 24 64 65 73 63 72 69 70 74 69 6f 6e 3b 0a 20 20 20 20 70 72 69 76 61 74 | private.$description;.....privat |
75160 | 65 20 24 69 67 6e 6f 72 65 56 61 6c 69 64 61 74 69 6f 6e 45 72 72 6f 72 73 20 3d 20 66 61 6c 73 | e.$ignoreValidationErrors.=.fals |
75180 | 65 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 61 70 70 6c 69 63 61 74 69 6f 6e 44 65 66 69 6e | e;.....private.$applicationDefin |
751a0 | 69 74 69 6f 6e 4d 65 72 67 65 64 20 3d 20 66 61 6c 73 65 3b 0a 20 20 20 20 70 72 69 76 61 74 65 | itionMerged.=.false;.....private |
751c0 | 20 24 61 70 70 6c 69 63 61 74 69 6f 6e 44 65 66 69 6e 69 74 69 6f 6e 4d 65 72 67 65 64 57 69 74 | .$applicationDefinitionMergedWit |
751e0 | 68 41 72 67 73 20 3d 20 66 61 6c 73 65 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 63 6f 64 65 | hArgs.=.false;.....private.$code |
75200 | 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 73 79 6e 6f 70 73 69 73 20 3d 20 61 72 72 61 79 28 | ;.....private.$synopsis.=.array( |
75220 | 29 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 75 73 61 67 65 73 20 3d 20 61 72 72 61 79 28 29 | );.....private.$usages.=.array() |
75240 | 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 68 65 6c 70 65 72 53 65 74 3b 0a 0a 20 20 20 20 2f | ;.....private.$helperSet;....../ |
75260 | 2a 2a 0a 20 20 20 20 20 2a 20 43 6f 6e 73 74 72 75 63 74 6f 72 2e 0a 20 20 20 20 20 2a 0a 20 20 | **......*.Constructor.......*... |
75280 | 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 7c 6e 75 6c 6c 20 24 6e 61 6d 65 20 54 68 | ...*.@param.string|null.$name.Th |
752a0 | 65 20 6e 61 6d 65 20 6f 66 20 74 68 65 20 63 6f 6d 6d 61 6e 64 3b 20 70 61 73 73 69 6e 67 20 6e | e.name.of.the.command;.passing.n |
752c0 | 75 6c 6c 20 6d 65 61 6e 73 20 69 74 20 6d 75 73 74 20 62 65 20 73 65 74 20 69 6e 20 63 6f 6e 66 | ull.means.it.must.be.set.in.conf |
752e0 | 69 67 75 72 65 28 29 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 4c 6f | igure()......*......*.@throws.Lo |
75300 | 67 69 63 45 78 63 65 70 74 69 6f 6e 20 57 68 65 6e 20 74 68 65 20 63 6f 6d 6d 61 6e 64 20 6e 61 | gicException.When.the.command.na |
75320 | 6d 65 20 69 73 20 65 6d 70 74 79 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 | me.is.empty......*/.....public.f |
75340 | 75 6e 63 74 69 6f 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 74 28 24 6e 61 6d 65 20 3d 20 6e 75 6c 6c | unction.__construct($name.=.null |
75360 | 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 64 65 66 69 6e 69 74 69 6f | ).....{.........$this->definitio |
75380 | 6e 20 3d 20 6e 65 77 20 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 28 29 3b 0a 0a 20 20 20 20 | n.=.new.InputDefinition();...... |
753a0 | 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 21 3d 3d 20 24 6e 61 6d 65 29 20 7b 0a 20 20 20 20 20 20 | ....if.(null.!==.$name).{....... |
753c0 | 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 65 74 4e 61 6d 65 28 24 6e 61 6d 65 29 3b 0a 20 20 20 | ......$this->setName($name);.... |
753e0 | 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 63 6f 6e 66 69 67 75 72 65 | .....}..........$this->configure |
75400 | 28 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 24 74 68 69 73 2d 3e 6e 61 6d 65 29 20 7b | ();..........if.(!$this->name).{ |
75420 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 4c 6f 67 69 63 45 78 63 65 | .............throw.new.LogicExce |
75440 | 70 74 69 6f 6e 28 73 70 72 69 6e 74 66 28 27 54 68 65 20 63 6f 6d 6d 61 6e 64 20 64 65 66 69 6e | ption(sprintf('The.command.defin |
75460 | 65 64 20 69 6e 20 22 25 73 22 20 63 61 6e 6e 6f 74 20 68 61 76 65 20 61 6e 20 65 6d 70 74 79 20 | ed.in."%s".cannot.have.an.empty. |
75480 | 6e 61 6d 65 2e 27 2c 20 67 65 74 5f 63 6c 61 73 73 28 24 74 68 69 73 29 29 29 3b 0a 20 20 20 20 | name.',.get_class($this)));..... |
754a0 | 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 49 67 6e 6f | ....}.....}....../**......*.Igno |
754c0 | 72 65 73 20 76 61 6c 69 64 61 74 69 6f 6e 20 65 72 72 6f 72 73 2e 0a 20 20 20 20 20 2a 0a 20 20 | res.validation.errors.......*... |
754e0 | 20 20 20 2a 20 54 68 69 73 20 69 73 20 6d 61 69 6e 6c 79 20 75 73 65 66 75 6c 20 66 6f 72 20 74 | ...*.This.is.mainly.useful.for.t |
75500 | 68 65 20 68 65 6c 70 20 63 6f 6d 6d 61 6e 64 2e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 | he.help.command.......*/.....pub |
75520 | 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 69 67 6e 6f 72 65 56 61 6c 69 64 61 74 69 6f 6e 45 72 72 | lic.function.ignoreValidationErr |
75540 | 6f 72 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 69 67 6e 6f 72 | ors().....{.........$this->ignor |
75560 | 65 56 61 6c 69 64 61 74 69 6f 6e 45 72 72 6f 72 73 20 3d 20 74 72 75 65 3b 0a 20 20 20 20 7d 0a | eValidationErrors.=.true;.....}. |
75580 | 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 74 68 65 20 61 70 70 6c 69 63 61 | ...../**......*.Sets.the.applica |
755a0 | 74 69 6f 6e 20 69 6e 73 74 61 6e 63 65 20 66 6f 72 20 74 68 69 73 20 63 6f 6d 6d 61 6e 64 2e 0a | tion.instance.for.this.command.. |
755c0 | 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 41 70 70 6c 69 63 61 74 69 6f 6e | .....*......*.@param.Application |
755e0 | 20 24 61 70 70 6c 69 63 61 74 69 6f 6e 20 41 6e 20 41 70 70 6c 69 63 61 74 69 6f 6e 20 69 6e 73 | .$application.An.Application.ins |
75600 | 74 61 6e 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f | tance......*/.....public.functio |
75620 | 6e 20 73 65 74 41 70 70 6c 69 63 61 74 69 6f 6e 28 41 70 70 6c 69 63 61 74 69 6f 6e 20 24 61 70 | n.setApplication(Application.$ap |
75640 | 70 6c 69 63 61 74 69 6f 6e 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | plication.=.null).....{......... |
75660 | 24 74 68 69 73 2d 3e 61 70 70 6c 69 63 61 74 69 6f 6e 20 3d 20 24 61 70 70 6c 69 63 61 74 69 6f | $this->application.=.$applicatio |
75680 | 6e 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 61 70 70 6c 69 63 61 74 69 6f 6e 29 20 7b 0a 20 | n;.........if.($application).{.. |
756a0 | 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 65 74 48 65 6c 70 65 72 53 65 74 28 24 | ...........$this->setHelperSet($ |
756c0 | 61 70 70 6c 69 63 61 74 69 6f 6e 2d 3e 67 65 74 48 65 6c 70 65 72 53 65 74 28 29 29 3b 0a 20 20 | application->getHelperSet());... |
756e0 | 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 | ......}.else.{.............$this |
75700 | 2d 3e 68 65 6c 70 65 72 53 65 74 20 3d 20 6e 75 6c 6c 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 | ->helperSet.=.null;.........}... |
75720 | 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 74 68 65 20 68 65 6c | ..}....../**......*.Sets.the.hel |
75740 | 70 65 72 20 73 65 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 48 65 | per.set.......*......*.@param.He |
75760 | 6c 70 65 72 53 65 74 20 24 68 65 6c 70 65 72 53 65 74 20 41 20 48 65 6c 70 65 72 53 65 74 20 69 | lperSet.$helperSet.A.HelperSet.i |
75780 | 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 | nstance......*/.....public.funct |
757a0 | 69 6f 6e 20 73 65 74 48 65 6c 70 65 72 53 65 74 28 48 65 6c 70 65 72 53 65 74 20 24 68 65 6c 70 | ion.setHelperSet(HelperSet.$help |
757c0 | 65 72 53 65 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 68 65 6c 70 | erSet).....{.........$this->help |
757e0 | 65 72 53 65 74 20 3d 20 24 68 65 6c 70 65 72 53 65 74 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f | erSet.=.$helperSet;.....}....../ |
75800 | 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 68 65 6c 70 65 72 20 73 65 74 2e 0a 20 | **......*.Gets.the.helper.set... |
75820 | 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 48 65 6c 70 65 72 53 65 74 20 41 | ....*......*.@return.HelperSet.A |
75840 | 20 48 65 6c 70 65 72 53 65 74 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 | .HelperSet.instance......*/..... |
75860 | 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 48 65 6c 70 65 72 53 65 74 28 29 0a 20 | public.function.getHelperSet().. |
75880 | 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 68 65 6c 70 65 | ...{.........return.$this->helpe |
758a0 | 72 53 65 74 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 | rSet;.....}....../**......*.Gets |
758c0 | 20 74 68 65 20 61 70 70 6c 69 63 61 74 69 6f 6e 20 69 6e 73 74 61 6e 63 65 20 66 6f 72 20 74 68 | .the.application.instance.for.th |
758e0 | 69 73 20 63 6f 6d 6d 61 6e 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 | is.command.......*......*.@retur |
75900 | 6e 20 41 70 70 6c 69 63 61 74 69 6f 6e 20 41 6e 20 41 70 70 6c 69 63 61 74 69 6f 6e 20 69 6e 73 | n.Application.An.Application.ins |
75920 | 74 61 6e 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f | tance......*/.....public.functio |
75940 | 6e 20 67 65 74 41 70 70 6c 69 63 61 74 69 6f 6e 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 | n.getApplication().....{........ |
75960 | 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 61 70 70 6c 69 63 61 74 69 6f 6e 3b 0a 20 20 20 20 | .return.$this->application;..... |
75980 | 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 43 68 65 63 6b 73 20 77 68 65 74 68 65 72 | }....../**......*.Checks.whether |
759a0 | 20 74 68 65 20 63 6f 6d 6d 61 6e 64 20 69 73 20 65 6e 61 62 6c 65 64 20 6f 72 20 6e 6f 74 20 69 | .the.command.is.enabled.or.not.i |
759c0 | 6e 20 74 68 65 20 63 75 72 72 65 6e 74 20 65 6e 76 69 72 6f 6e 6d 65 6e 74 2e 0a 20 20 20 20 20 | n.the.current.environment....... |
759e0 | 2a 0a 20 20 20 20 20 2a 20 4f 76 65 72 72 69 64 65 20 74 68 69 73 20 74 6f 20 63 68 65 63 6b 20 | *......*.Override.this.to.check. |
75a00 | 66 6f 72 20 78 20 6f 72 20 79 20 61 6e 64 20 72 65 74 75 72 6e 20 66 61 6c 73 65 20 69 66 20 74 | for.x.or.y.and.return.false.if.t |
75a20 | 68 65 20 63 6f 6d 6d 61 6e 64 20 63 61 6e 20 6e 6f 74 0a 20 20 20 20 20 2a 20 72 75 6e 20 70 72 | he.command.can.not......*.run.pr |
75a40 | 6f 70 65 72 6c 79 20 75 6e 64 65 72 20 74 68 65 20 63 75 72 72 65 6e 74 20 63 6f 6e 64 69 74 69 | operly.under.the.current.conditi |
75a60 | 6f 6e 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 62 6f 6f 6c 0a | ons.......*......*.@return.bool. |
75a80 | 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 69 73 45 6e | .....*/.....public.function.isEn |
75aa0 | 61 62 6c 65 64 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 74 72 75 | abled().....{.........return.tru |
75ac0 | 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 43 6f 6e 66 69 67 75 | e;.....}....../**......*.Configu |
75ae0 | 72 65 73 20 74 68 65 20 63 75 72 72 65 6e 74 20 63 6f 6d 6d 61 6e 64 2e 0a 20 20 20 20 20 2a 2f | res.the.current.command.......*/ |
75b00 | 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 63 6f 6e 66 69 67 75 72 | .....protected.function.configur |
75b20 | 65 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 | e().....{.....}....../**......*. |
75b40 | 45 78 65 63 75 74 65 73 20 74 68 65 20 63 75 72 72 65 6e 74 20 63 6f 6d 6d 61 6e 64 2e 0a 20 20 | Executes.the.current.command.... |
75b60 | 20 20 20 2a 0a 20 20 20 20 20 2a 20 54 68 69 73 20 6d 65 74 68 6f 64 20 69 73 20 6e 6f 74 20 61 | ...*......*.This.method.is.not.a |
75b80 | 62 73 74 72 61 63 74 20 62 65 63 61 75 73 65 20 79 6f 75 20 63 61 6e 20 75 73 65 20 74 68 69 73 | bstract.because.you.can.use.this |
75ba0 | 20 63 6c 61 73 73 0a 20 20 20 20 20 2a 20 61 73 20 61 20 63 6f 6e 63 72 65 74 65 20 63 6c 61 73 | .class......*.as.a.concrete.clas |
75bc0 | 73 2e 20 49 6e 20 74 68 69 73 20 63 61 73 65 2c 20 69 6e 73 74 65 61 64 20 6f 66 20 64 65 66 69 | s..In.this.case,.instead.of.defi |
75be0 | 6e 69 6e 67 20 74 68 65 0a 20 20 20 20 20 2a 20 65 78 65 63 75 74 65 28 29 20 6d 65 74 68 6f 64 | ning.the......*.execute().method |
75c00 | 2c 20 79 6f 75 20 73 65 74 20 74 68 65 20 63 6f 64 65 20 74 6f 20 65 78 65 63 75 74 65 20 62 79 | ,.you.set.the.code.to.execute.by |
75c20 | 20 70 61 73 73 69 6e 67 0a 20 20 20 20 20 2a 20 61 20 43 6c 6f 73 75 72 65 20 74 6f 20 74 68 65 | .passing......*.a.Closure.to.the |
75c40 | 20 73 65 74 43 6f 64 65 28 29 20 6d 65 74 68 6f 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a | .setCode().method.......*......* |
75c60 | 20 40 70 61 72 61 6d 20 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 20 20 24 69 6e 70 75 74 20 20 | .@param.InputInterface..$input.. |
75c80 | 41 6e 20 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 | An.InputInterface.instance...... |
75ca0 | 2a 20 40 70 61 72 61 6d 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 | *.@param.OutputInterface.$output |
75cc0 | 20 41 6e 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 | .An.OutputInterface.instance.... |
75ce0 | 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 6e 75 6c 6c 7c 69 6e 74 20 6e 75 6c 6c | ..*......*.@return.null|int.null |
75d00 | 20 6f 72 20 30 20 69 66 20 65 76 65 72 79 74 68 69 6e 67 20 77 65 6e 74 20 66 69 6e 65 2c 20 6f | .or.0.if.everything.went.fine,.o |
75d20 | 72 20 61 6e 20 65 72 72 6f 72 20 63 6f 64 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 | r.an.error.code......*......*.@t |
75d40 | 68 72 6f 77 73 20 4c 6f 67 69 63 45 78 63 65 70 74 69 6f 6e 20 57 68 65 6e 20 74 68 69 73 20 61 | hrows.LogicException.When.this.a |
75d60 | 62 73 74 72 61 63 74 20 6d 65 74 68 6f 64 20 69 73 20 6e 6f 74 20 69 6d 70 6c 65 6d 65 6e 74 65 | bstract.method.is.not.implemente |
75d80 | 64 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 73 65 65 20 73 65 74 43 6f 64 65 28 29 0a 20 | d......*......*.@see.setCode().. |
75da0 | 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 65 78 | ....*/.....protected.function.ex |
75dc0 | 65 63 75 74 65 28 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 69 6e 70 75 74 2c 20 4f 75 74 | ecute(InputInterface.$input,.Out |
75de0 | 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 | putInterface.$output).....{..... |
75e00 | 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 4c 6f 67 69 63 45 78 63 65 70 74 69 6f 6e 28 27 59 6f | ....throw.new.LogicException('Yo |
75e20 | 75 20 6d 75 73 74 20 6f 76 65 72 72 69 64 65 20 74 68 65 20 65 78 65 63 75 74 65 28 29 20 6d 65 | u.must.override.the.execute().me |
75e40 | 74 68 6f 64 20 69 6e 20 74 68 65 20 63 6f 6e 63 72 65 74 65 20 63 6f 6d 6d 61 6e 64 20 63 6c 61 | thod.in.the.concrete.command.cla |
75e60 | 73 73 2e 27 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 49 6e 74 | ss.');.....}....../**......*.Int |
75e80 | 65 72 61 63 74 73 20 77 69 74 68 20 74 68 65 20 75 73 65 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 | eracts.with.the.user.......*.... |
75ea0 | 20 20 2a 20 54 68 69 73 20 6d 65 74 68 6f 64 20 69 73 20 65 78 65 63 75 74 65 64 20 62 65 66 6f | ..*.This.method.is.executed.befo |
75ec0 | 72 65 20 74 68 65 20 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 20 69 73 20 76 61 6c 69 64 61 | re.the.InputDefinition.is.valida |
75ee0 | 74 65 64 2e 0a 20 20 20 20 20 2a 20 54 68 69 73 20 6d 65 61 6e 73 20 74 68 61 74 20 74 68 69 73 | ted.......*.This.means.that.this |
75f00 | 20 69 73 20 74 68 65 20 6f 6e 6c 79 20 70 6c 61 63 65 20 77 68 65 72 65 20 74 68 65 20 63 6f 6d | .is.the.only.place.where.the.com |
75f20 | 6d 61 6e 64 20 63 61 6e 0a 20 20 20 20 20 2a 20 69 6e 74 65 72 61 63 74 69 76 65 6c 79 20 61 73 | mand.can......*.interactively.as |
75f40 | 6b 20 66 6f 72 20 76 61 6c 75 65 73 20 6f 66 20 6d 69 73 73 69 6e 67 20 72 65 71 75 69 72 65 64 | k.for.values.of.missing.required |
75f60 | 20 61 72 67 75 6d 65 6e 74 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d | .arguments.......*......*.@param |
75f80 | 20 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 20 20 24 69 6e 70 75 74 20 20 41 6e 20 49 6e 70 75 | .InputInterface..$input..An.Inpu |
75fa0 | 74 49 6e 74 65 72 66 61 63 65 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 | tInterface.instance......*.@para |
75fc0 | 6d 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 20 41 6e 20 4f 75 74 | m.OutputInterface.$output.An.Out |
75fe0 | 70 75 74 49 6e 74 65 72 66 61 63 65 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 | putInterface.instance......*/... |
76000 | 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 69 6e 74 65 72 61 63 74 28 49 6e | ..protected.function.interact(In |
76020 | 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 69 6e 70 75 74 2c 20 4f 75 74 70 75 74 49 6e 74 65 72 | putInterface.$input,.OutputInter |
76040 | 66 61 63 65 20 24 6f 75 74 70 75 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f | face.$output).....{.....}....../ |
76060 | 2a 2a 0a 20 20 20 20 20 2a 20 49 6e 69 74 69 61 6c 69 7a 65 73 20 74 68 65 20 63 6f 6d 6d 61 6e | **......*.Initializes.the.comman |
76080 | 64 20 6a 75 73 74 20 61 66 74 65 72 20 74 68 65 20 69 6e 70 75 74 20 68 61 73 20 62 65 65 6e 20 | d.just.after.the.input.has.been. |
760a0 | 76 61 6c 69 64 61 74 65 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 54 68 69 73 20 69 73 | validated.......*......*.This.is |
760c0 | 20 6d 61 69 6e 6c 79 20 75 73 65 66 75 6c 20 77 68 65 6e 20 61 20 6c 6f 74 20 6f 66 20 63 6f 6d | .mainly.useful.when.a.lot.of.com |
760e0 | 6d 61 6e 64 73 20 65 78 74 65 6e 64 73 20 6f 6e 65 20 6d 61 69 6e 20 63 6f 6d 6d 61 6e 64 0a 20 | mands.extends.one.main.command.. |
76100 | 20 20 20 20 2a 20 77 68 65 72 65 20 73 6f 6d 65 20 74 68 69 6e 67 73 20 6e 65 65 64 20 74 6f 20 | ....*.where.some.things.need.to. |
76120 | 62 65 20 69 6e 69 74 69 61 6c 69 7a 65 64 20 62 61 73 65 64 20 6f 6e 20 74 68 65 20 69 6e 70 75 | be.initialized.based.on.the.inpu |
76140 | 74 20 61 72 67 75 6d 65 6e 74 73 20 61 6e 64 20 6f 70 74 69 6f 6e 73 2e 0a 20 20 20 20 20 2a 0a | t.arguments.and.options.......*. |
76160 | 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 20 20 24 69 | .....*.@param.InputInterface..$i |
76180 | 6e 70 75 74 20 20 41 6e 20 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 20 69 6e 73 74 61 6e 63 65 | nput..An.InputInterface.instance |
761a0 | 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 | ......*.@param.OutputInterface.$ |
761c0 | 6f 75 74 70 75 74 20 41 6e 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 69 6e 73 74 61 6e | output.An.OutputInterface.instan |
761e0 | 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f | ce......*/.....protected.functio |
76200 | 6e 20 69 6e 69 74 69 61 6c 69 7a 65 28 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 69 6e 70 | n.initialize(InputInterface.$inp |
76220 | 75 74 2c 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 29 0a 20 20 20 | ut,.OutputInterface.$output).... |
76240 | 20 7b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 75 6e 73 20 74 68 | .{.....}....../**......*.Runs.th |
76260 | 65 20 63 6f 6d 6d 61 6e 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 54 68 65 20 63 6f 64 | e.command.......*......*.The.cod |
76280 | 65 20 74 6f 20 65 78 65 63 75 74 65 20 69 73 20 65 69 74 68 65 72 20 64 65 66 69 6e 65 64 20 64 | e.to.execute.is.either.defined.d |
762a0 | 69 72 65 63 74 6c 79 20 77 69 74 68 20 74 68 65 0a 20 20 20 20 20 2a 20 73 65 74 43 6f 64 65 28 | irectly.with.the......*.setCode( |
762c0 | 29 20 6d 65 74 68 6f 64 20 6f 72 20 62 79 20 6f 76 65 72 72 69 64 69 6e 67 20 74 68 65 20 65 78 | ).method.or.by.overriding.the.ex |
762e0 | 65 63 75 74 65 28 29 20 6d 65 74 68 6f 64 0a 20 20 20 20 20 2a 20 69 6e 20 61 20 73 75 62 2d 63 | ecute().method......*.in.a.sub-c |
76300 | 6c 61 73 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 49 6e 70 75 74 | lass.......*......*.@param.Input |
76320 | 49 6e 74 65 72 66 61 63 65 20 20 24 69 6e 70 75 74 20 20 41 6e 20 49 6e 70 75 74 49 6e 74 65 72 | Interface..$input..An.InputInter |
76340 | 66 61 63 65 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 4f 75 74 70 | face.instance......*.@param.Outp |
76360 | 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 20 41 6e 20 4f 75 74 70 75 74 49 6e 74 | utInterface.$output.An.OutputInt |
76380 | 65 72 66 61 63 65 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 | erface.instance......*......*.@r |
763a0 | 65 74 75 72 6e 20 69 6e 74 20 54 68 65 20 63 6f 6d 6d 61 6e 64 20 65 78 69 74 20 63 6f 64 65 0a | eturn.int.The.command.exit.code. |
763c0 | 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 5c 45 78 63 65 70 74 69 6f 6e | .....*......*.@throws.\Exception |
763e0 | 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 73 65 65 20 73 65 74 43 6f 64 65 28 29 0a 20 20 | ......*......*.@see.setCode()... |
76400 | 20 20 20 2a 20 40 73 65 65 20 65 78 65 63 75 74 65 28 29 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 | ...*.@see.execute()......*/..... |
76420 | 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 72 75 6e 28 49 6e 70 75 74 49 6e 74 65 72 66 61 | public.function.run(InputInterfa |
76440 | 63 65 20 24 69 6e 70 75 74 2c 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 | ce.$input,.OutputInterface.$outp |
76460 | 75 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 2f 2f 20 66 6f 72 63 65 20 74 68 65 20 63 | ut).....{.........//.force.the.c |
76480 | 72 65 61 74 69 6f 6e 20 6f 66 20 74 68 65 20 73 79 6e 6f 70 73 69 73 20 62 65 66 6f 72 65 20 74 | reation.of.the.synopsis.before.t |
764a0 | 68 65 20 6d 65 72 67 65 20 77 69 74 68 20 74 68 65 20 61 70 70 20 64 65 66 69 6e 69 74 69 6f 6e | he.merge.with.the.app.definition |
764c0 | 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 67 65 74 53 79 6e 6f 70 73 69 73 28 74 72 75 65 | .........$this->getSynopsis(true |
764e0 | 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 67 65 74 53 79 6e 6f 70 73 69 73 28 66 61 | );.........$this->getSynopsis(fa |
76500 | 6c 73 65 29 3b 0a 0a 20 20 20 20 20 20 20 20 2f 2f 20 61 64 64 20 74 68 65 20 61 70 70 6c 69 63 | lse);..........//.add.the.applic |
76520 | 61 74 69 6f 6e 20 61 72 67 75 6d 65 6e 74 73 20 61 6e 64 20 6f 70 74 69 6f 6e 73 0a 20 20 20 20 | ation.arguments.and.options..... |
76540 | 20 20 20 20 24 74 68 69 73 2d 3e 6d 65 72 67 65 41 70 70 6c 69 63 61 74 69 6f 6e 44 65 66 69 6e | ....$this->mergeApplicationDefin |
76560 | 69 74 69 6f 6e 28 29 3b 0a 0a 20 20 20 20 20 20 20 20 2f 2f 20 62 69 6e 64 20 74 68 65 20 69 6e | ition();..........//.bind.the.in |
76580 | 70 75 74 20 61 67 61 69 6e 73 74 20 74 68 65 20 63 6f 6d 6d 61 6e 64 20 73 70 65 63 69 66 69 63 | put.against.the.command.specific |
765a0 | 20 61 72 67 75 6d 65 6e 74 73 2f 6f 70 74 69 6f 6e 73 0a 20 20 20 20 20 20 20 20 74 72 79 20 7b | .arguments/options.........try.{ |
765c0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 69 6e 70 75 74 2d 3e 62 69 6e 64 28 24 74 68 69 73 2d | .............$input->bind($this- |
765e0 | 3e 64 65 66 69 6e 69 74 69 6f 6e 29 3b 0a 20 20 20 20 20 20 20 20 7d 20 63 61 74 63 68 20 28 45 | >definition);.........}.catch.(E |
76600 | 78 63 65 70 74 69 6f 6e 49 6e 74 65 72 66 61 63 65 20 24 65 29 20 7b 0a 20 20 20 20 20 20 20 20 | xceptionInterface.$e).{......... |
76620 | 20 20 20 20 69 66 20 28 21 24 74 68 69 73 2d 3e 69 67 6e 6f 72 65 56 61 6c 69 64 61 74 69 6f 6e | ....if.(!$this->ignoreValidation |
76640 | 45 72 72 6f 72 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 | Errors).{.................throw. |
76660 | 24 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 | $e;.............}.........}..... |
76680 | 20 20 20 20 20 24 74 68 69 73 2d 3e 69 6e 69 74 69 61 6c 69 7a 65 28 24 69 6e 70 75 74 2c 20 24 | .....$this->initialize($input,.$ |
766a0 | 6f 75 74 70 75 74 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 21 3d 3d 20 24 | output);..........if.(null.!==.$ |
766c0 | 74 68 69 73 2d 3e 70 72 6f 63 65 73 73 54 69 74 6c 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | this->processTitle).{........... |
766e0 | 20 20 69 66 20 28 66 75 6e 63 74 69 6f 6e 5f 65 78 69 73 74 73 28 27 63 6c 69 5f 73 65 74 5f 70 | ..if.(function_exists('cli_set_p |
76700 | 72 6f 63 65 73 73 5f 74 69 74 6c 65 27 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | rocess_title')).{............... |
76720 | 20 20 63 6c 69 5f 73 65 74 5f 70 72 6f 63 65 73 73 5f 74 69 74 6c 65 28 24 74 68 69 73 2d 3e 70 | ..cli_set_process_title($this->p |
76740 | 72 6f 63 65 73 73 54 69 74 6c 65 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 | rocessTitle);.............}.else |
76760 | 69 66 20 28 66 75 6e 63 74 69 6f 6e 5f 65 78 69 73 74 73 28 27 73 65 74 70 72 6f 63 74 69 74 6c | if.(function_exists('setproctitl |
76780 | 65 27 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 73 65 74 70 72 6f 63 74 69 | e')).{.................setprocti |
767a0 | 74 6c 65 28 24 74 68 69 73 2d 3e 70 72 6f 63 65 73 73 54 69 74 6c 65 29 3b 0a 20 20 20 20 20 20 | tle($this->processTitle);....... |
767c0 | 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 3a | ......}.elseif.(OutputInterface: |
767e0 | 3a 56 45 52 42 4f 53 49 54 59 5f 56 45 52 59 5f 56 45 52 42 4f 53 45 20 3d 3d 3d 20 24 6f 75 74 | :VERBOSITY_VERY_VERBOSE.===.$out |
76800 | 70 75 74 2d 3e 67 65 74 56 65 72 62 6f 73 69 74 79 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | put->getVerbosity()).{.......... |
76820 | 20 20 20 20 20 20 20 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 27 3c 63 6f 6d 6d 65 6e | .......$output->writeln('<commen |
76840 | 74 3e 49 6e 73 74 61 6c 6c 20 74 68 65 20 70 72 6f 63 74 69 74 6c 65 20 50 45 43 4c 20 74 6f 20 | t>Install.the.proctitle.PECL.to. |
76860 | 62 65 20 61 62 6c 65 20 74 6f 20 63 68 61 6e 67 65 20 74 68 65 20 70 72 6f 63 65 73 73 20 74 69 | be.able.to.change.the.process.ti |
76880 | 74 6c 65 2e 3c 2f 63 6f 6d 6d 65 6e 74 3e 27 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a | tle.</comment>');.............}. |
768a0 | 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 69 6e 70 75 74 2d 3e 69 | ........}..........if.($input->i |
768c0 | 73 49 6e 74 65 72 61 63 74 69 76 65 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 | sInteractive()).{.............$t |
768e0 | 68 69 73 2d 3e 69 6e 74 65 72 61 63 74 28 24 69 6e 70 75 74 2c 20 24 6f 75 74 70 75 74 29 3b 0a | his->interact($input,.$output);. |
76900 | 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 2f 2f 20 54 68 65 20 63 6f 6d 6d 61 6e | ........}..........//.The.comman |
76920 | 64 20 6e 61 6d 65 20 61 72 67 75 6d 65 6e 74 20 69 73 20 6f 66 74 65 6e 20 6f 6d 69 74 74 65 64 | d.name.argument.is.often.omitted |
76940 | 20 77 68 65 6e 20 61 20 63 6f 6d 6d 61 6e 64 20 69 73 20 65 78 65 63 75 74 65 64 20 64 69 72 65 | .when.a.command.is.executed.dire |
76960 | 63 74 6c 79 20 77 69 74 68 20 69 74 73 20 72 75 6e 28 29 20 6d 65 74 68 6f 64 2e 0a 20 20 20 20 | ctly.with.its.run().method...... |
76980 | 20 20 20 20 2f 2f 20 49 74 20 77 6f 75 6c 64 20 66 61 69 6c 20 74 68 65 20 76 61 6c 69 64 61 74 | ....//.It.would.fail.the.validat |
769a0 | 69 6f 6e 20 69 66 20 77 65 20 64 69 64 6e 27 74 20 6d 61 6b 65 20 73 75 72 65 20 74 68 65 20 63 | ion.if.we.didn't.make.sure.the.c |
769c0 | 6f 6d 6d 61 6e 64 20 61 72 67 75 6d 65 6e 74 20 69 73 20 70 72 65 73 65 6e 74 2c 0a 20 20 20 20 | ommand.argument.is.present,..... |
769e0 | 20 20 20 20 2f 2f 20 73 69 6e 63 65 20 69 74 27 73 20 72 65 71 75 69 72 65 64 20 62 79 20 74 68 | ....//.since.it's.required.by.th |
76a00 | 65 20 61 70 70 6c 69 63 61 74 69 6f 6e 2e 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 69 6e 70 75 | e.application..........if.($inpu |
76a20 | 74 2d 3e 68 61 73 41 72 67 75 6d 65 6e 74 28 27 63 6f 6d 6d 61 6e 64 27 29 20 26 26 20 6e 75 6c | t->hasArgument('command').&&.nul |
76a40 | 6c 20 3d 3d 3d 20 24 69 6e 70 75 74 2d 3e 67 65 74 41 72 67 75 6d 65 6e 74 28 27 63 6f 6d 6d 61 | l.===.$input->getArgument('comma |
76a60 | 6e 64 27 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 69 6e 70 75 74 2d 3e 73 65 74 41 | nd')).{.............$input->setA |
76a80 | 72 67 75 6d 65 6e 74 28 27 63 6f 6d 6d 61 6e 64 27 2c 20 24 74 68 69 73 2d 3e 67 65 74 4e 61 6d | rgument('command',.$this->getNam |
76aa0 | 65 28 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 69 6e 70 75 74 2d | e());.........}..........$input- |
76ac0 | 3e 76 61 6c 69 64 61 74 65 28 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 74 68 69 73 2d | >validate();..........if.($this- |
76ae0 | 3e 63 6f 64 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 73 74 61 74 75 73 43 6f 64 65 | >code).{.............$statusCode |
76b00 | 20 3d 20 63 61 6c 6c 5f 75 73 65 72 5f 66 75 6e 63 28 24 74 68 69 73 2d 3e 63 6f 64 65 2c 20 24 | .=.call_user_func($this->code,.$ |
76b20 | 69 6e 70 75 74 2c 20 24 6f 75 74 70 75 74 29 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 | input,.$output);.........}.else. |
76b40 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 73 74 61 74 75 73 43 6f 64 65 20 3d 20 24 74 68 69 | {.............$statusCode.=.$thi |
76b60 | 73 2d 3e 65 78 65 63 75 74 65 28 24 69 6e 70 75 74 2c 20 24 6f 75 74 70 75 74 29 3b 0a 20 20 20 | s->execute($input,.$output);.... |
76b80 | 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 69 73 5f 6e 75 6d 65 72 69 | .....}..........return.is_numeri |
76ba0 | 63 28 24 73 74 61 74 75 73 43 6f 64 65 29 20 3f 20 28 69 6e 74 29 20 24 73 74 61 74 75 73 43 6f | c($statusCode).?.(int).$statusCo |
76bc0 | 64 65 20 3a 20 30 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 | de.:.0;.....}....../**......*.Se |
76be0 | 74 73 20 74 68 65 20 63 6f 64 65 20 74 6f 20 65 78 65 63 75 74 65 20 77 68 65 6e 20 72 75 6e 6e | ts.the.code.to.execute.when.runn |
76c00 | 69 6e 67 20 74 68 69 73 20 63 6f 6d 6d 61 6e 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 | ing.this.command.......*......*. |
76c20 | 49 66 20 74 68 69 73 20 6d 65 74 68 6f 64 20 69 73 20 75 73 65 64 2c 20 69 74 20 6f 76 65 72 72 | If.this.method.is.used,.it.overr |
76c40 | 69 64 65 73 20 74 68 65 20 63 6f 64 65 20 64 65 66 69 6e 65 64 0a 20 20 20 20 20 2a 20 69 6e 20 | ides.the.code.defined......*.in. |
76c60 | 74 68 65 20 65 78 65 63 75 74 65 28 29 20 6d 65 74 68 6f 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 | the.execute().method.......*.... |
76c80 | 20 20 2a 20 40 70 61 72 61 6d 20 63 61 6c 6c 61 62 6c 65 20 24 63 6f 64 65 20 41 20 63 61 6c 6c | ..*.@param.callable.$code.A.call |
76ca0 | 61 62 6c 65 28 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 69 6e 70 75 74 2c 20 4f 75 74 70 | able(InputInterface.$input,.Outp |
76cc0 | 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 29 0a 20 20 20 20 20 2a 0a 20 20 20 20 | utInterface.$output)......*..... |
76ce0 | 20 2a 20 40 72 65 74 75 72 6e 20 43 6f 6d 6d 61 6e 64 20 54 68 65 20 63 75 72 72 65 6e 74 20 69 | .*.@return.Command.The.current.i |
76d00 | 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 49 6e | nstance......*......*.@throws.In |
76d20 | 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 0a 20 20 20 20 20 2a 0a 20 20 | validArgumentException......*... |
76d40 | 20 20 20 2a 20 40 73 65 65 20 65 78 65 63 75 74 65 28 29 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 | ...*.@see.execute()......*/..... |
76d60 | 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 43 6f 64 65 28 63 61 6c 6c 61 62 6c 65 | public.function.setCode(callable |
76d80 | 20 24 63 6f 64 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 63 6f 64 65 20 | .$code).....{.........if.($code. |
76da0 | 69 6e 73 74 61 6e 63 65 6f 66 20 5c 43 6c 6f 73 75 72 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | instanceof.\Closure).{.......... |
76dc0 | 20 20 20 24 72 20 3d 20 6e 65 77 20 5c 52 65 66 6c 65 63 74 69 6f 6e 46 75 6e 63 74 69 6f 6e 28 | ...$r.=.new.\ReflectionFunction( |
76de0 | 24 63 6f 64 65 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d | $code);.............if.(null.=== |
76e00 | 20 24 72 2d 3e 67 65 74 43 6c 6f 73 75 72 65 54 68 69 73 28 29 29 20 7b 0a 20 20 20 20 20 20 20 | .$r->getClosureThis()).{........ |
76e20 | 20 20 20 20 20 20 20 20 20 24 63 6f 64 65 20 3d 20 5c 43 6c 6f 73 75 72 65 3a 3a 62 69 6e 64 28 | .........$code.=.\Closure::bind( |
76e40 | 24 63 6f 64 65 2c 20 24 74 68 69 73 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 | $code,.$this);.............}.... |
76e60 | 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 63 6f 64 65 20 3d 20 24 63 | .....}..........$this->code.=.$c |
76e80 | 6f 64 65 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 3b 0a 20 20 20 20 | ode;..........return.$this;..... |
76ea0 | 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 4d 65 72 67 65 73 20 74 68 65 20 61 70 70 | }....../**......*.Merges.the.app |
76ec0 | 6c 69 63 61 74 69 6f 6e 20 64 65 66 69 6e 69 74 69 6f 6e 20 77 69 74 68 20 74 68 65 20 63 6f 6d | lication.definition.with.the.com |
76ee0 | 6d 61 6e 64 20 64 65 66 69 6e 69 74 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 54 | mand.definition.......*......*.T |
76f00 | 68 69 73 20 6d 65 74 68 6f 64 20 69 73 20 6e 6f 74 20 70 61 72 74 20 6f 66 20 70 75 62 6c 69 63 | his.method.is.not.part.of.public |
76f20 | 20 41 50 49 20 61 6e 64 20 73 68 6f 75 6c 64 20 6e 6f 74 20 62 65 20 75 73 65 64 20 64 69 72 65 | .API.and.should.not.be.used.dire |
76f40 | 63 74 6c 79 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 62 6f 6f 6c 20 | ctly.......*......*.@param.bool. |
76f60 | 24 6d 65 72 67 65 41 72 67 73 20 57 68 65 74 68 65 72 20 74 6f 20 6d 65 72 67 65 20 6f 72 20 6e | $mergeArgs.Whether.to.merge.or.n |
76f80 | 6f 74 20 74 68 65 20 41 70 70 6c 69 63 61 74 69 6f 6e 20 64 65 66 69 6e 69 74 69 6f 6e 20 61 72 | ot.the.Application.definition.ar |
76fa0 | 67 75 6d 65 6e 74 73 20 74 6f 20 43 6f 6d 6d 61 6e 64 20 64 65 66 69 6e 69 74 69 6f 6e 20 61 72 | guments.to.Command.definition.ar |
76fc0 | 67 75 6d 65 6e 74 73 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 | guments......*/.....public.funct |
76fe0 | 69 6f 6e 20 6d 65 72 67 65 41 70 70 6c 69 63 61 74 69 6f 6e 44 65 66 69 6e 69 74 69 6f 6e 28 24 | ion.mergeApplicationDefinition($ |
77000 | 6d 65 72 67 65 41 72 67 73 20 3d 20 74 72 75 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | mergeArgs.=.true).....{......... |
77020 | 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 74 68 69 73 2d 3e 61 70 70 6c 69 63 61 74 69 6f 6e 20 | if.(null.===.$this->application. |
77040 | 7c 7c 20 28 74 72 75 65 20 3d 3d 3d 20 24 74 68 69 73 2d 3e 61 70 70 6c 69 63 61 74 69 6f 6e 44 | ||.(true.===.$this->applicationD |
77060 | 65 66 69 6e 69 74 69 6f 6e 4d 65 72 67 65 64 20 26 26 20 28 24 74 68 69 73 2d 3e 61 70 70 6c 69 | efinitionMerged.&&.($this->appli |
77080 | 63 61 74 69 6f 6e 44 65 66 69 6e 69 74 69 6f 6e 4d 65 72 67 65 64 57 69 74 68 41 72 67 73 20 7c | cationDefinitionMergedWithArgs.| |
770a0 | 7c 20 21 24 6d 65 72 67 65 41 72 67 73 29 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 | |.!$mergeArgs))).{.............r |
770c0 | 65 74 75 72 6e 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d | eturn;.........}..........$this- |
770e0 | 3e 64 65 66 69 6e 69 74 69 6f 6e 2d 3e 61 64 64 4f 70 74 69 6f 6e 73 28 24 74 68 69 73 2d 3e 61 | >definition->addOptions($this->a |
77100 | 70 70 6c 69 63 61 74 69 6f 6e 2d 3e 67 65 74 44 65 66 69 6e 69 74 69 6f 6e 28 29 2d 3e 67 65 74 | pplication->getDefinition()->get |
77120 | 4f 70 74 69 6f 6e 73 28 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 6d 65 72 67 65 41 | Options());..........if.($mergeA |
77140 | 72 67 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 63 75 72 72 65 6e 74 41 72 67 75 6d | rgs).{.............$currentArgum |
77160 | 65 6e 74 73 20 3d 20 24 74 68 69 73 2d 3e 64 65 66 69 6e 69 74 69 6f 6e 2d 3e 67 65 74 41 72 67 | ents.=.$this->definition->getArg |
77180 | 75 6d 65 6e 74 73 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 64 65 66 | uments();.............$this->def |
771a0 | 69 6e 69 74 69 6f 6e 2d 3e 73 65 74 41 72 67 75 6d 65 6e 74 73 28 24 74 68 69 73 2d 3e 61 70 70 | inition->setArguments($this->app |
771c0 | 6c 69 63 61 74 69 6f 6e 2d 3e 67 65 74 44 65 66 69 6e 69 74 69 6f 6e 28 29 2d 3e 67 65 74 41 72 | lication->getDefinition()->getAr |
771e0 | 67 75 6d 65 6e 74 73 28 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 64 | guments());.............$this->d |
77200 | 65 66 69 6e 69 74 69 6f 6e 2d 3e 61 64 64 41 72 67 75 6d 65 6e 74 73 28 24 63 75 72 72 65 6e 74 | efinition->addArguments($current |
77220 | 41 72 67 75 6d 65 6e 74 73 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 | Arguments);.........}..........$ |
77240 | 74 68 69 73 2d 3e 61 70 70 6c 69 63 61 74 69 6f 6e 44 65 66 69 6e 69 74 69 6f 6e 4d 65 72 67 65 | this->applicationDefinitionMerge |
77260 | 64 20 3d 20 74 72 75 65 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 6d 65 72 67 65 41 72 67 73 | d.=.true;.........if.($mergeArgs |
77280 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 61 70 70 6c 69 63 61 74 69 | ).{.............$this->applicati |
772a0 | 6f 6e 44 65 66 69 6e 69 74 69 6f 6e 4d 65 72 67 65 64 57 69 74 68 41 72 67 73 20 3d 20 74 72 75 | onDefinitionMergedWithArgs.=.tru |
772c0 | 65 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 | e;.........}.....}....../**..... |
772e0 | 20 2a 20 53 65 74 73 20 61 6e 20 61 72 72 61 79 20 6f 66 20 61 72 67 75 6d 65 6e 74 20 61 6e 64 | .*.Sets.an.array.of.argument.and |
77300 | 20 6f 70 74 69 6f 6e 20 69 6e 73 74 61 6e 63 65 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a | .option.instances.......*......* |
77320 | 20 40 70 61 72 61 6d 20 61 72 72 61 79 7c 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 20 24 64 | .@param.array|InputDefinition.$d |
77340 | 65 66 69 6e 69 74 69 6f 6e 20 41 6e 20 61 72 72 61 79 20 6f 66 20 61 72 67 75 6d 65 6e 74 20 61 | efinition.An.array.of.argument.a |
77360 | 6e 64 20 6f 70 74 69 6f 6e 20 69 6e 73 74 61 6e 63 65 73 20 6f 72 20 61 20 64 65 66 69 6e 69 74 | nd.option.instances.or.a.definit |
77380 | 69 6f 6e 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 | ion.instance......*......*.@retu |
773a0 | 72 6e 20 43 6f 6d 6d 61 6e 64 20 54 68 65 20 63 75 72 72 65 6e 74 20 69 6e 73 74 61 6e 63 65 0a | rn.Command.The.current.instance. |
773c0 | 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 44 | .....*/.....public.function.setD |
773e0 | 65 66 69 6e 69 74 69 6f 6e 28 24 64 65 66 69 6e 69 74 69 6f 6e 29 0a 20 20 20 20 7b 0a 20 20 20 | efinition($definition).....{.... |
77400 | 20 20 20 20 20 69 66 20 28 24 64 65 66 69 6e 69 74 69 6f 6e 20 69 6e 73 74 61 6e 63 65 6f 66 20 | .....if.($definition.instanceof. |
77420 | 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 | InputDefinition).{.............$ |
77440 | 74 68 69 73 2d 3e 64 65 66 69 6e 69 74 69 6f 6e 20 3d 20 24 64 65 66 69 6e 69 74 69 6f 6e 3b 0a | this->definition.=.$definition;. |
77460 | 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 | ........}.else.{.............$th |
77480 | 69 73 2d 3e 64 65 66 69 6e 69 74 69 6f 6e 2d 3e 73 65 74 44 65 66 69 6e 69 74 69 6f 6e 28 24 64 | is->definition->setDefinition($d |
774a0 | 65 66 69 6e 69 74 69 6f 6e 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 | efinition);.........}..........$ |
774c0 | 74 68 69 73 2d 3e 61 70 70 6c 69 63 61 74 69 6f 6e 44 65 66 69 6e 69 74 69 6f 6e 4d 65 72 67 65 | this->applicationDefinitionMerge |
774e0 | 64 20 3d 20 66 61 6c 73 65 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 | d.=.false;..........return.$this |
77500 | 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 | ;.....}....../**......*.Gets.the |
77520 | 20 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 20 61 74 74 61 63 68 65 64 20 74 6f 20 74 68 69 | .InputDefinition.attached.to.thi |
77540 | 73 20 43 6f 6d 6d 61 6e 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e | s.Command.......*......*.@return |
77560 | 20 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 20 41 6e 20 49 6e 70 75 74 44 65 66 69 6e 69 74 | .InputDefinition.An.InputDefinit |
77580 | 69 6f 6e 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 | ion.instance......*/.....public. |
775a0 | 66 75 6e 63 74 69 6f 6e 20 67 65 74 44 65 66 69 6e 69 74 69 6f 6e 28 29 0a 20 20 20 20 7b 0a 20 | function.getDefinition().....{.. |
775c0 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 64 65 66 69 6e 69 74 69 6f 6e 3b | .......return.$this->definition; |
775e0 | 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 | .....}....../**......*.Gets.the. |
77600 | 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 20 74 6f 20 62 65 20 75 73 65 64 20 74 6f 20 63 72 | InputDefinition.to.be.used.to.cr |
77620 | 65 61 74 65 20 72 65 70 72 65 73 65 6e 74 61 74 69 6f 6e 73 20 6f 66 20 74 68 69 73 20 43 6f 6d | eate.representations.of.this.Com |
77640 | 6d 61 6e 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 43 61 6e 20 62 65 20 6f 76 65 72 72 | mand.......*......*.Can.be.overr |
77660 | 69 64 64 65 6e 20 74 6f 20 70 72 6f 76 69 64 65 20 74 68 65 20 6f 72 69 67 69 6e 61 6c 20 63 6f | idden.to.provide.the.original.co |
77680 | 6d 6d 61 6e 64 20 72 65 70 72 65 73 65 6e 74 61 74 69 6f 6e 20 77 68 65 6e 20 69 74 20 77 6f 75 | mmand.representation.when.it.wou |
776a0 | 6c 64 20 6f 74 68 65 72 77 69 73 65 0a 20 20 20 20 20 2a 20 62 65 20 63 68 61 6e 67 65 64 20 62 | ld.otherwise......*.be.changed.b |
776c0 | 79 20 6d 65 72 67 69 6e 67 20 77 69 74 68 20 74 68 65 20 61 70 70 6c 69 63 61 74 69 6f 6e 20 49 | y.merging.with.the.application.I |
776e0 | 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 54 68 | nputDefinition.......*......*.Th |
77700 | 69 73 20 6d 65 74 68 6f 64 20 69 73 20 6e 6f 74 20 70 61 72 74 20 6f 66 20 70 75 62 6c 69 63 20 | is.method.is.not.part.of.public. |
77720 | 41 50 49 20 61 6e 64 20 73 68 6f 75 6c 64 20 6e 6f 74 20 62 65 20 75 73 65 64 20 64 69 72 65 63 | API.and.should.not.be.used.direc |
77740 | 74 6c 79 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 49 6e 70 75 74 | tly.......*......*.@return.Input |
77760 | 44 65 66 69 6e 69 74 69 6f 6e 20 41 6e 20 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 20 69 6e | Definition.An.InputDefinition.in |
77780 | 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 | stance......*/.....public.functi |
777a0 | 6f 6e 20 67 65 74 4e 61 74 69 76 65 44 65 66 69 6e 69 74 69 6f 6e 28 29 0a 20 20 20 20 7b 0a 20 | on.getNativeDefinition().....{.. |
777c0 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 67 65 74 44 65 66 69 6e 69 74 69 | .......return.$this->getDefiniti |
777e0 | 6f 6e 28 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 41 64 64 73 | on();.....}....../**......*.Adds |
77800 | 20 61 6e 20 61 72 67 75 6d 65 6e 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 | .an.argument.......*......*.@par |
77820 | 61 6d 20 73 74 72 69 6e 67 20 24 6e 61 6d 65 20 20 20 20 20 20 20 20 54 68 65 20 61 72 67 75 6d | am.string.$name........The.argum |
77840 | 65 6e 74 20 6e 61 6d 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 69 6e 74 20 20 20 20 24 6d | ent.name......*.@param.int....$m |
77860 | 6f 64 65 20 20 20 20 20 20 20 20 54 68 65 20 61 72 67 75 6d 65 6e 74 20 6d 6f 64 65 3a 20 49 6e | ode........The.argument.mode:.In |
77880 | 70 75 74 41 72 67 75 6d 65 6e 74 3a 3a 52 45 51 55 49 52 45 44 20 6f 72 20 49 6e 70 75 74 41 72 | putArgument::REQUIRED.or.InputAr |
778a0 | 67 75 6d 65 6e 74 3a 3a 4f 50 54 49 4f 4e 41 4c 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 | gument::OPTIONAL......*.@param.s |
778c0 | 74 72 69 6e 67 20 24 64 65 73 63 72 69 70 74 69 6f 6e 20 41 20 64 65 73 63 72 69 70 74 69 6f 6e | tring.$description.A.description |
778e0 | 20 74 65 78 74 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 6d 69 78 65 64 20 20 24 64 65 66 61 | .text......*.@param.mixed..$defa |
77900 | 75 6c 74 20 20 20 20 20 54 68 65 20 64 65 66 61 75 6c 74 20 76 61 6c 75 65 20 28 66 6f 72 20 49 | ult.....The.default.value.(for.I |
77920 | 6e 70 75 74 41 72 67 75 6d 65 6e 74 3a 3a 4f 50 54 49 4f 4e 41 4c 20 6d 6f 64 65 20 6f 6e 6c 79 | nputArgument::OPTIONAL.mode.only |
77940 | 29 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 43 6f 6d 6d 61 6e 64 20 | )......*......*.@return.Command. |
77960 | 54 68 65 20 63 75 72 72 65 6e 74 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 | The.current.instance......*/.... |
77980 | 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 61 64 64 41 72 67 75 6d 65 6e 74 28 24 6e 61 | .public.function.addArgument($na |
779a0 | 6d 65 2c 20 24 6d 6f 64 65 20 3d 20 6e 75 6c 6c 2c 20 24 64 65 73 63 72 69 70 74 69 6f 6e 20 3d | me,.$mode.=.null,.$description.= |
779c0 | 20 27 27 2c 20 24 64 65 66 61 75 6c 74 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 | .'',.$default.=.null).....{..... |
779e0 | 20 20 20 20 24 74 68 69 73 2d 3e 64 65 66 69 6e 69 74 69 6f 6e 2d 3e 61 64 64 41 72 67 75 6d 65 | ....$this->definition->addArgume |
77a00 | 6e 74 28 6e 65 77 20 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 28 24 6e 61 6d 65 2c 20 24 6d 6f 64 | nt(new.InputArgument($name,.$mod |
77a20 | 65 2c 20 24 64 65 73 63 72 69 70 74 69 6f 6e 2c 20 24 64 65 66 61 75 6c 74 29 29 3b 0a 0a 20 20 | e,.$description,.$default));.... |
77a40 | 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f | ......return.$this;.....}....../ |
77a60 | 2a 2a 0a 20 20 20 20 20 2a 20 41 64 64 73 20 61 6e 20 6f 70 74 69 6f 6e 2e 0a 20 20 20 20 20 2a | **......*.Adds.an.option.......* |
77a80 | 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6e 61 6d 65 20 20 20 20 20 | ......*.@param.string.$name..... |
77aa0 | 20 20 20 54 68 65 20 6f 70 74 69 6f 6e 20 6e 61 6d 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d | ...The.option.name......*.@param |
77ac0 | 20 73 74 72 69 6e 67 20 24 73 68 6f 72 74 63 75 74 20 20 20 20 54 68 65 20 73 68 6f 72 74 63 75 | .string.$shortcut....The.shortcu |
77ae0 | 74 20 28 63 61 6e 20 62 65 20 6e 75 6c 6c 29 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 69 6e | t.(can.be.null)......*.@param.in |
77b00 | 74 20 20 20 20 24 6d 6f 64 65 20 20 20 20 20 20 20 20 54 68 65 20 6f 70 74 69 6f 6e 20 6d 6f 64 | t....$mode........The.option.mod |
77b20 | 65 3a 20 4f 6e 65 20 6f 66 20 74 68 65 20 49 6e 70 75 74 4f 70 74 69 6f 6e 3a 3a 56 41 4c 55 45 | e:.One.of.the.InputOption::VALUE |
77b40 | 5f 2a 20 63 6f 6e 73 74 61 6e 74 73 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e | _*.constants......*.@param.strin |
77b60 | 67 20 24 64 65 73 63 72 69 70 74 69 6f 6e 20 41 20 64 65 73 63 72 69 70 74 69 6f 6e 20 74 65 78 | g.$description.A.description.tex |
77b80 | 74 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 6d 69 78 65 64 20 20 24 64 65 66 61 75 6c 74 20 | t......*.@param.mixed..$default. |
77ba0 | 20 20 20 20 54 68 65 20 64 65 66 61 75 6c 74 20 76 61 6c 75 65 20 28 6d 75 73 74 20 62 65 20 6e | ....The.default.value.(must.be.n |
77bc0 | 75 6c 6c 20 66 6f 72 20 49 6e 70 75 74 4f 70 74 69 6f 6e 3a 3a 56 41 4c 55 45 5f 4e 4f 4e 45 29 | ull.for.InputOption::VALUE_NONE) |
77be0 | 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 43 6f 6d 6d 61 6e 64 20 54 | ......*......*.@return.Command.T |
77c00 | 68 65 20 63 75 72 72 65 6e 74 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 | he.current.instance......*/..... |
77c20 | 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 61 64 64 4f 70 74 69 6f 6e 28 24 6e 61 6d 65 2c | public.function.addOption($name, |
77c40 | 20 24 73 68 6f 72 74 63 75 74 20 3d 20 6e 75 6c 6c 2c 20 24 6d 6f 64 65 20 3d 20 6e 75 6c 6c 2c | .$shortcut.=.null,.$mode.=.null, |
77c60 | 20 24 64 65 73 63 72 69 70 74 69 6f 6e 20 3d 20 27 27 2c 20 24 64 65 66 61 75 6c 74 20 3d 20 6e | .$description.=.'',.$default.=.n |
77c80 | 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 64 65 66 69 6e 69 | ull).....{.........$this->defini |
77ca0 | 74 69 6f 6e 2d 3e 61 64 64 4f 70 74 69 6f 6e 28 6e 65 77 20 49 6e 70 75 74 4f 70 74 69 6f 6e 28 | tion->addOption(new.InputOption( |
77cc0 | 24 6e 61 6d 65 2c 20 24 73 68 6f 72 74 63 75 74 2c 20 24 6d 6f 64 65 2c 20 24 64 65 73 63 72 69 | $name,.$shortcut,.$mode,.$descri |
77ce0 | 70 74 69 6f 6e 2c 20 24 64 65 66 61 75 6c 74 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 | ption,.$default));..........retu |
77d00 | 72 6e 20 24 74 68 69 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 | rn.$this;.....}....../**......*. |
77d20 | 53 65 74 73 20 74 68 65 20 6e 61 6d 65 20 6f 66 20 74 68 65 20 63 6f 6d 6d 61 6e 64 2e 0a 20 20 | Sets.the.name.of.the.command.... |
77d40 | 20 20 20 2a 0a 20 20 20 20 20 2a 20 54 68 69 73 20 6d 65 74 68 6f 64 20 63 61 6e 20 73 65 74 20 | ...*......*.This.method.can.set. |
77d60 | 62 6f 74 68 20 74 68 65 20 6e 61 6d 65 73 70 61 63 65 20 61 6e 64 20 74 68 65 20 6e 61 6d 65 20 | both.the.namespace.and.the.name. |
77d80 | 69 66 0a 20 20 20 20 20 2a 20 79 6f 75 20 73 65 70 61 72 61 74 65 20 74 68 65 6d 20 62 79 20 61 | if......*.you.separate.them.by.a |
77da0 | 20 63 6f 6c 6f 6e 20 28 3a 29 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 20 20 20 20 24 63 6f | .colon.(:)......*......*.....$co |
77dc0 | 6d 6d 61 6e 64 2d 3e 73 65 74 4e 61 6d 65 28 27 66 6f 6f 3a 62 61 72 27 29 3b 0a 20 20 20 20 20 | mmand->setName('foo:bar');...... |
77de0 | 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6e 61 6d 65 20 54 68 65 | *......*.@param.string.$name.The |
77e00 | 20 63 6f 6d 6d 61 6e 64 20 6e 61 6d 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 | .command.name......*......*.@ret |
77e20 | 75 72 6e 20 43 6f 6d 6d 61 6e 64 20 54 68 65 20 63 75 72 72 65 6e 74 20 69 6e 73 74 61 6e 63 65 | urn.Command.The.current.instance |
77e40 | 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 49 6e 76 61 6c 69 64 41 72 | ......*......*.@throws.InvalidAr |
77e60 | 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 20 57 68 65 6e 20 74 68 65 20 6e 61 6d 65 20 69 73 | gumentException.When.the.name.is |
77e80 | 20 69 6e 76 61 6c 69 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 | .invalid......*/.....public.func |
77ea0 | 74 69 6f 6e 20 73 65 74 4e 61 6d 65 28 24 6e 61 6d 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 | tion.setName($name).....{....... |
77ec0 | 20 20 24 74 68 69 73 2d 3e 76 61 6c 69 64 61 74 65 4e 61 6d 65 28 24 6e 61 6d 65 29 3b 0a 0a 20 | ..$this->validateName($name);... |
77ee0 | 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6e 61 6d 65 20 3d 20 24 6e 61 6d 65 3b 0a 0a 20 20 20 | .......$this->name.=.$name;..... |
77f00 | 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a | .....return.$this;.....}....../* |
77f20 | 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 74 68 65 20 70 72 6f 63 65 73 73 20 74 69 74 6c 65 20 | *......*.Sets.the.process.title. |
77f40 | 6f 66 20 74 68 65 20 63 6f 6d 6d 61 6e 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 54 68 | of.the.command.......*......*.Th |
77f60 | 69 73 20 66 65 61 74 75 72 65 20 73 68 6f 75 6c 64 20 62 65 20 75 73 65 64 20 6f 6e 6c 79 20 77 | is.feature.should.be.used.only.w |
77f80 | 68 65 6e 20 63 72 65 61 74 69 6e 67 20 61 20 6c 6f 6e 67 20 70 72 6f 63 65 73 73 20 63 6f 6d 6d | hen.creating.a.long.process.comm |
77fa0 | 61 6e 64 2c 0a 20 20 20 20 20 2a 20 6c 69 6b 65 20 61 20 64 61 65 6d 6f 6e 2e 0a 20 20 20 20 20 | and,......*.like.a.daemon....... |
77fc0 | 2a 0a 20 20 20 20 20 2a 20 50 48 50 20 35 2e 35 2b 20 6f 72 20 74 68 65 20 70 72 6f 63 74 69 74 | *......*.PHP.5.5+.or.the.proctit |
77fe0 | 6c 65 20 50 45 43 4c 20 6c 69 62 72 61 72 79 20 69 73 20 72 65 71 75 69 72 65 64 0a 20 20 20 20 | le.PECL.library.is.required..... |
78000 | 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 74 69 74 6c 65 20 54 | .*......*.@param.string.$title.T |
78020 | 68 65 20 70 72 6f 63 65 73 73 20 74 69 74 6c 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 | he.process.title......*......*.@ |
78040 | 72 65 74 75 72 6e 20 43 6f 6d 6d 61 6e 64 20 54 68 65 20 63 75 72 72 65 6e 74 20 69 6e 73 74 61 | return.Command.The.current.insta |
78060 | 6e 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 | nce......*/.....public.function. |
78080 | 73 65 74 50 72 6f 63 65 73 73 54 69 74 6c 65 28 24 74 69 74 6c 65 29 0a 20 20 20 20 7b 0a 20 20 | setProcessTitle($title).....{... |
780a0 | 20 20 20 20 20 20 24 74 68 69 73 2d 3e 70 72 6f 63 65 73 73 54 69 74 6c 65 20 3d 20 24 74 69 74 | ......$this->processTitle.=.$tit |
780c0 | 6c 65 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 3b 0a 20 20 20 20 7d | le;..........return.$this;.....} |
780e0 | 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 74 68 65 20 63 6f 6d | ....../**......*.Returns.the.com |
78100 | 6d 61 6e 64 20 6e 61 6d 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e | mand.name.......*......*.@return |
78120 | 20 73 74 72 69 6e 67 20 54 68 65 20 63 6f 6d 6d 61 6e 64 20 6e 61 6d 65 0a 20 20 20 20 20 2a 2f | .string.The.command.name......*/ |
78140 | 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 4e 61 6d 65 28 29 0a 20 | .....public.function.getName().. |
78160 | 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 6e 61 6d 65 3b | ...{.........return.$this->name; |
78180 | 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 74 68 65 20 | .....}....../**......*.Sets.the. |
781a0 | 64 65 73 63 72 69 70 74 69 6f 6e 20 66 6f 72 20 74 68 65 20 63 6f 6d 6d 61 6e 64 2e 0a 20 20 20 | description.for.the.command..... |
781c0 | 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 64 65 73 63 72 69 | ..*......*.@param.string.$descri |
781e0 | 70 74 69 6f 6e 20 54 68 65 20 64 65 73 63 72 69 70 74 69 6f 6e 20 66 6f 72 20 74 68 65 20 63 6f | ption.The.description.for.the.co |
78200 | 6d 6d 61 6e 64 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 43 6f 6d 6d | mmand......*......*.@return.Comm |
78220 | 61 6e 64 20 54 68 65 20 63 75 72 72 65 6e 74 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 2f | and.The.current.instance......*/ |
78240 | 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 44 65 73 63 72 69 70 74 | .....public.function.setDescript |
78260 | 69 6f 6e 28 24 64 65 73 63 72 69 70 74 69 6f 6e 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | ion($description).....{......... |
78280 | 24 74 68 69 73 2d 3e 64 65 73 63 72 69 70 74 69 6f 6e 20 3d 20 24 64 65 73 63 72 69 70 74 69 6f | $this->description.=.$descriptio |
782a0 | 6e 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 3b 0a 20 20 20 20 7d 0a | n;..........return.$this;.....}. |
782c0 | 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 74 68 65 20 64 65 73 63 | ...../**......*.Returns.the.desc |
782e0 | 72 69 70 74 69 6f 6e 20 66 6f 72 20 74 68 65 20 63 6f 6d 6d 61 6e 64 2e 0a 20 20 20 20 20 2a 0a | ription.for.the.command.......*. |
78300 | 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 20 54 68 65 20 64 65 73 63 72 69 | .....*.@return.string.The.descri |
78320 | 70 74 69 6f 6e 20 66 6f 72 20 74 68 65 20 63 6f 6d 6d 61 6e 64 0a 20 20 20 20 20 2a 2f 0a 20 20 | ption.for.the.command......*/... |
78340 | 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 44 65 73 63 72 69 70 74 69 6f 6e | ..public.function.getDescription |
78360 | 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 64 | ().....{.........return.$this->d |
78380 | 65 73 63 72 69 70 74 69 6f 6e 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 | escription;.....}....../**...... |
783a0 | 2a 20 53 65 74 73 20 74 68 65 20 68 65 6c 70 20 66 6f 72 20 74 68 65 20 63 6f 6d 6d 61 6e 64 2e | *.Sets.the.help.for.the.command. |
783c0 | 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 68 65 | ......*......*.@param.string.$he |
783e0 | 6c 70 20 54 68 65 20 68 65 6c 70 20 66 6f 72 20 74 68 65 20 63 6f 6d 6d 61 6e 64 0a 20 20 20 20 | lp.The.help.for.the.command..... |
78400 | 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 43 6f 6d 6d 61 6e 64 20 54 68 65 20 63 75 | .*......*.@return.Command.The.cu |
78420 | 72 72 65 6e 74 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 | rrent.instance......*/.....publi |
78440 | 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 48 65 6c 70 28 24 68 65 6c 70 29 0a 20 20 20 20 7b 0a | c.function.setHelp($help).....{. |
78460 | 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 68 65 6c 70 20 3d 20 24 68 65 6c 70 3b 0a 0a 20 20 | ........$this->help.=.$help;.... |
78480 | 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f | ......return.$this;.....}....../ |
784a0 | 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 74 68 65 20 68 65 6c 70 20 66 6f 72 20 74 | **......*.Returns.the.help.for.t |
784c0 | 68 65 20 63 6f 6d 6d 61 6e 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 | he.command.......*......*.@retur |
784e0 | 6e 20 73 74 72 69 6e 67 20 54 68 65 20 68 65 6c 70 20 66 6f 72 20 74 68 65 20 63 6f 6d 6d 61 6e | n.string.The.help.for.the.comman |
78500 | 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 | d......*/.....public.function.ge |
78520 | 74 48 65 6c 70 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 | tHelp().....{.........return.$th |
78540 | 69 73 2d 3e 68 65 6c 70 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 | is->help;.....}....../**......*. |
78560 | 52 65 74 75 72 6e 73 20 74 68 65 20 70 72 6f 63 65 73 73 65 64 20 68 65 6c 70 20 66 6f 72 20 74 | Returns.the.processed.help.for.t |
78580 | 68 65 20 63 6f 6d 6d 61 6e 64 20 72 65 70 6c 61 63 69 6e 67 20 74 68 65 20 25 63 6f 6d 6d 61 6e | he.command.replacing.the.%comman |
785a0 | 64 2e 6e 61 6d 65 25 20 61 6e 64 0a 20 20 20 20 20 2a 20 25 63 6f 6d 6d 61 6e 64 2e 66 75 6c 6c | d.name%.and......*.%command.full |
785c0 | 5f 6e 61 6d 65 25 20 70 61 74 74 65 72 6e 73 20 77 69 74 68 20 74 68 65 20 72 65 61 6c 20 76 61 | _name%.patterns.with.the.real.va |
785e0 | 6c 75 65 73 20 64 79 6e 61 6d 69 63 61 6c 6c 79 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 | lues.dynamically.......*......*. |
78600 | 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 20 54 68 65 20 70 72 6f 63 65 73 73 65 64 20 68 65 6c | @return.string.The.processed.hel |
78620 | 70 20 66 6f 72 20 74 68 65 20 63 6f 6d 6d 61 6e 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 | p.for.the.command......*/.....pu |
78640 | 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 50 72 6f 63 65 73 73 65 64 48 65 6c 70 28 29 | blic.function.getProcessedHelp() |
78660 | 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 6e 61 6d 65 20 3d 20 24 74 68 69 73 2d 3e 6e 61 | .....{.........$name.=.$this->na |
78680 | 6d 65 3b 0a 0a 20 20 20 20 20 20 20 20 24 70 6c 61 63 65 68 6f 6c 64 65 72 73 20 3d 20 61 72 72 | me;..........$placeholders.=.arr |
786a0 | 61 79 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 25 63 6f 6d 6d 61 6e 64 2e 6e 61 6d 65 25 27 | ay(.............'%command.name%' |
786c0 | 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 25 63 6f 6d 6d 61 6e 64 2e 66 75 6c 6c 5f 6e 61 6d | ,.............'%command.full_nam |
786e0 | 65 25 27 2c 0a 20 20 20 20 20 20 20 20 29 3b 0a 20 20 20 20 20 20 20 20 24 72 65 70 6c 61 63 65 | e%',.........);.........$replace |
78700 | 6d 65 6e 74 73 20 3d 20 61 72 72 61 79 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6e 61 6d 65 | ments.=.array(.............$name |
78720 | 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 5f 53 45 52 56 45 52 5b 27 50 48 50 5f 53 45 4c 46 | ,.............$_SERVER['PHP_SELF |
78740 | 27 5d 2e 27 20 27 2e 24 6e 61 6d 65 2c 0a 20 20 20 20 20 20 20 20 29 3b 0a 0a 20 20 20 20 20 20 | '].'.'.$name,.........);........ |
78760 | 20 20 72 65 74 75 72 6e 20 73 74 72 5f 72 65 70 6c 61 63 65 28 24 70 6c 61 63 65 68 6f 6c 64 65 | ..return.str_replace($placeholde |
78780 | 72 73 2c 20 24 72 65 70 6c 61 63 65 6d 65 6e 74 73 2c 20 24 74 68 69 73 2d 3e 67 65 74 48 65 6c | rs,.$replacements,.$this->getHel |
787a0 | 70 28 29 20 3f 3a 20 24 74 68 69 73 2d 3e 67 65 74 44 65 73 63 72 69 70 74 69 6f 6e 28 29 29 3b | p().?:.$this->getDescription()); |
787c0 | 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 65 74 73 20 74 68 65 20 | .....}....../**......*.Sets.the. |
787e0 | 61 6c 69 61 73 65 73 20 66 6f 72 20 74 68 65 20 63 6f 6d 6d 61 6e 64 2e 0a 20 20 20 20 20 2a 0a | aliases.for.the.command.......*. |
78800 | 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 5b 5d 20 24 61 6c 69 61 73 65 73 20 | .....*.@param.string[].$aliases. |
78820 | 41 6e 20 61 72 72 61 79 20 6f 66 20 61 6c 69 61 73 65 73 20 66 6f 72 20 74 68 65 20 63 6f 6d 6d | An.array.of.aliases.for.the.comm |
78840 | 61 6e 64 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 43 6f 6d 6d 61 6e | and......*......*.@return.Comman |
78860 | 64 20 54 68 65 20 63 75 72 72 65 6e 74 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 0a 20 20 | d.The.current.instance......*... |
78880 | 20 20 20 2a 20 40 74 68 72 6f 77 73 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 | ...*.@throws.InvalidArgumentExce |
788a0 | 70 74 69 6f 6e 20 57 68 65 6e 20 61 6e 20 61 6c 69 61 73 20 69 73 20 69 6e 76 61 6c 69 64 0a 20 | ption.When.an.alias.is.invalid.. |
788c0 | 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 41 6c | ....*/.....public.function.setAl |
788e0 | 69 61 73 65 73 28 24 61 6c 69 61 73 65 73 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 | iases($aliases).....{.........if |
78900 | 20 28 21 69 73 5f 61 72 72 61 79 28 24 61 6c 69 61 73 65 73 29 20 26 26 20 21 24 61 6c 69 61 73 | .(!is_array($aliases).&&.!$alias |
78920 | 65 73 20 69 6e 73 74 61 6e 63 65 6f 66 20 5c 54 72 61 76 65 72 73 61 62 6c 65 29 20 7b 0a 20 20 | es.instanceof.\Traversable).{... |
78940 | 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 61 6c 69 64 41 72 67 75 6d | ..........throw.new.InvalidArgum |
78960 | 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 27 24 61 6c 69 61 73 65 73 20 6d 75 73 74 20 62 65 20 61 | entException('$aliases.must.be.a |
78980 | 6e 20 61 72 72 61 79 20 6f 72 20 61 6e 20 69 6e 73 74 61 6e 63 65 20 6f 66 20 5c 54 72 61 76 65 | n.array.or.an.instance.of.\Trave |
789a0 | 72 73 61 62 6c 65 27 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 66 6f 72 | rsable');.........}..........for |
789c0 | 65 61 63 68 20 28 24 61 6c 69 61 73 65 73 20 61 73 20 24 61 6c 69 61 73 29 20 7b 0a 20 20 20 20 | each.($aliases.as.$alias).{..... |
789e0 | 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 76 61 6c 69 64 61 74 65 4e 61 6d 65 28 24 61 6c 69 | ........$this->validateName($ali |
78a00 | 61 73 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 61 | as);.........}..........$this->a |
78a20 | 6c 69 61 73 65 73 20 3d 20 24 61 6c 69 61 73 65 73 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 | liases.=.$aliases;..........retu |
78a40 | 72 6e 20 24 74 68 69 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 | rn.$this;.....}....../**......*. |
78a60 | 52 65 74 75 72 6e 73 20 74 68 65 20 61 6c 69 61 73 65 73 20 66 6f 72 20 74 68 65 20 63 6f 6d 6d | Returns.the.aliases.for.the.comm |
78a80 | 61 6e 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 61 72 72 61 79 | and.......*......*.@return.array |
78aa0 | 20 41 6e 20 61 72 72 61 79 20 6f 66 20 61 6c 69 61 73 65 73 20 66 6f 72 20 74 68 65 20 63 6f 6d | .An.array.of.aliases.for.the.com |
78ac0 | 6d 61 6e 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e | mand......*/.....public.function |
78ae0 | 20 67 65 74 41 6c 69 61 73 65 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 | .getAliases().....{.........retu |
78b00 | 72 6e 20 24 74 68 69 73 2d 3e 61 6c 69 61 73 65 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a | rn.$this->aliases;.....}....../* |
78b20 | 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 74 68 65 20 73 79 6e 6f 70 73 69 73 20 66 6f | *......*.Returns.the.synopsis.fo |
78b40 | 72 20 74 68 65 20 63 6f 6d 6d 61 6e 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 | r.the.command.......*......*.@pa |
78b60 | 72 61 6d 20 62 6f 6f 6c 20 24 73 68 6f 72 74 20 57 68 65 74 68 65 72 20 74 6f 20 73 68 6f 77 20 | ram.bool.$short.Whether.to.show. |
78b80 | 74 68 65 20 73 68 6f 72 74 20 76 65 72 73 69 6f 6e 20 6f 66 20 74 68 65 20 73 79 6e 6f 70 73 69 | the.short.version.of.the.synopsi |
78ba0 | 73 20 28 77 69 74 68 20 6f 70 74 69 6f 6e 73 20 66 6f 6c 64 65 64 29 20 6f 72 20 6e 6f 74 0a 20 | s.(with.options.folded).or.not.. |
78bc0 | 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 20 54 68 65 20 | ....*......*.@return.string.The. |
78be0 | 73 79 6e 6f 70 73 69 73 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 | synopsis......*/.....public.func |
78c00 | 74 69 6f 6e 20 67 65 74 53 79 6e 6f 70 73 69 73 28 24 73 68 6f 72 74 20 3d 20 66 61 6c 73 65 29 | tion.getSynopsis($short.=.false) |
78c20 | 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 6b 65 79 20 3d 20 24 73 68 6f 72 74 20 3f 20 27 | .....{.........$key.=.$short.?.' |
78c40 | 73 68 6f 72 74 27 20 3a 20 27 6c 6f 6e 67 27 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 69 | short'.:.'long';..........if.(!i |
78c60 | 73 73 65 74 28 24 74 68 69 73 2d 3e 73 79 6e 6f 70 73 69 73 5b 24 6b 65 79 5d 29 29 20 7b 0a 20 | sset($this->synopsis[$key])).{.. |
78c80 | 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 79 6e 6f 70 73 69 73 5b 24 6b 65 79 5d | ...........$this->synopsis[$key] |
78ca0 | 20 3d 20 74 72 69 6d 28 73 70 72 69 6e 74 66 28 27 25 73 20 25 73 27 2c 20 24 74 68 69 73 2d 3e | .=.trim(sprintf('%s.%s',.$this-> |
78cc0 | 6e 61 6d 65 2c 20 24 74 68 69 73 2d 3e 64 65 66 69 6e 69 74 69 6f 6e 2d 3e 67 65 74 53 79 6e 6f | name,.$this->definition->getSyno |
78ce0 | 70 73 69 73 28 24 73 68 6f 72 74 29 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 | psis($short)));.........}....... |
78d00 | 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 73 79 6e 6f 70 73 69 73 5b 24 6b 65 79 5d 3b | ...return.$this->synopsis[$key]; |
78d20 | 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 41 64 64 20 61 20 63 6f 6d | .....}....../**......*.Add.a.com |
78d40 | 6d 61 6e 64 20 75 73 61 67 65 20 65 78 61 6d 70 6c 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 | mand.usage.example.......*...... |
78d60 | 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 75 73 61 67 65 20 54 68 65 20 75 73 61 67 65 | *.@param.string.$usage.The.usage |
78d80 | 2c 20 69 74 27 6c 6c 20 62 65 20 70 72 65 66 69 78 65 64 20 77 69 74 68 20 74 68 65 20 63 6f 6d | ,.it'll.be.prefixed.with.the.com |
78da0 | 6d 61 6e 64 20 6e 61 6d 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 | mand.name......*......*.@return. |
78dc0 | 43 6f 6d 6d 61 6e 64 20 54 68 65 20 63 75 72 72 65 6e 74 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 | Command.The.current.instance.... |
78de0 | 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 61 64 64 55 73 61 67 | ..*/.....public.function.addUsag |
78e00 | 65 28 24 75 73 61 67 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 30 20 21 3d | e($usage).....{.........if.(0.!= |
78e20 | 3d 20 73 74 72 70 6f 73 28 24 75 73 61 67 65 2c 20 24 74 68 69 73 2d 3e 6e 61 6d 65 29 29 20 7b | =.strpos($usage,.$this->name)).{ |
78e40 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 75 73 61 67 65 20 3d 20 73 70 72 69 6e 74 66 28 27 25 | .............$usage.=.sprintf('% |
78e60 | 73 20 25 73 27 2c 20 24 74 68 69 73 2d 3e 6e 61 6d 65 2c 20 24 75 73 61 67 65 29 3b 0a 20 20 20 | s.%s',.$this->name,.$usage);.... |
78e80 | 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 75 73 61 67 65 73 5b 5d 20 | .....}..........$this->usages[]. |
78ea0 | 3d 20 24 75 73 61 67 65 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 3b | =.$usage;..........return.$this; |
78ec0 | 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 74 75 72 6e 73 20 61 | .....}....../**......*.Returns.a |
78ee0 | 6c 74 65 72 6e 61 74 69 76 65 20 75 73 61 67 65 73 20 6f 66 20 74 68 65 20 63 6f 6d 6d 61 6e 64 | lternative.usages.of.the.command |
78f00 | 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 61 72 72 61 79 0a 20 20 | .......*......*.@return.array... |
78f20 | 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 55 73 61 | ...*/.....public.function.getUsa |
78f40 | 67 65 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 | ges().....{.........return.$this |
78f60 | 2d 3e 75 73 61 67 65 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 | ->usages;.....}....../**......*. |
78f80 | 47 65 74 73 20 61 20 68 65 6c 70 65 72 20 69 6e 73 74 61 6e 63 65 20 62 79 20 6e 61 6d 65 2e 0a | Gets.a.helper.instance.by.name.. |
78fa0 | 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6e 61 6d | .....*......*.@param.string.$nam |
78fc0 | 65 20 54 68 65 20 68 65 6c 70 65 72 20 6e 61 6d 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 | e.The.helper.name......*......*. |
78fe0 | 40 72 65 74 75 72 6e 20 6d 69 78 65 64 20 54 68 65 20 68 65 6c 70 65 72 20 76 61 6c 75 65 0a 20 | @return.mixed.The.helper.value.. |
79000 | 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 4c 6f 67 69 63 45 78 63 65 70 74 | ....*......*.@throws.LogicExcept |
79020 | 69 6f 6e 20 20 20 20 20 20 20 20 20 20 20 69 66 20 6e 6f 20 48 65 6c 70 65 72 53 65 74 20 69 73 | ion...........if.no.HelperSet.is |
79040 | 20 64 65 66 69 6e 65 64 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 49 6e 76 61 6c 69 64 41 | .defined......*.@throws.InvalidA |
79060 | 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 20 69 66 20 74 68 65 20 68 65 6c 70 65 72 20 69 | rgumentException.if.the.helper.i |
79080 | 73 20 6e 6f 74 20 64 65 66 69 6e 65 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 | s.not.defined......*/.....public |
790a0 | 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 48 65 6c 70 65 72 28 24 6e 61 6d 65 29 0a 20 20 20 20 7b | .function.getHelper($name).....{ |
790c0 | 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 74 68 69 73 2d 3e 68 65 6c | .........if.(null.===.$this->hel |
790e0 | 70 65 72 53 65 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 | perSet).{.............throw.new. |
79100 | 4c 6f 67 69 63 45 78 63 65 70 74 69 6f 6e 28 73 70 72 69 6e 74 66 28 27 43 61 6e 6e 6f 74 20 72 | LogicException(sprintf('Cannot.r |
79120 | 65 74 72 69 65 76 65 20 68 65 6c 70 65 72 20 22 25 73 22 20 62 65 63 61 75 73 65 20 74 68 65 72 | etrieve.helper."%s".because.ther |
79140 | 65 20 69 73 20 6e 6f 20 48 65 6c 70 65 72 53 65 74 20 64 65 66 69 6e 65 64 2e 20 44 69 64 20 79 | e.is.no.HelperSet.defined..Did.y |
79160 | 6f 75 20 66 6f 72 67 65 74 20 74 6f 20 61 64 64 20 79 6f 75 72 20 63 6f 6d 6d 61 6e 64 20 74 6f | ou.forget.to.add.your.command.to |
79180 | 20 74 68 65 20 61 70 70 6c 69 63 61 74 69 6f 6e 20 6f 72 20 74 6f 20 73 65 74 20 74 68 65 20 61 | .the.application.or.to.set.the.a |
791a0 | 70 70 6c 69 63 61 74 69 6f 6e 20 6f 6e 20 74 68 65 20 63 6f 6d 6d 61 6e 64 20 75 73 69 6e 67 20 | pplication.on.the.command.using. |
791c0 | 74 68 65 20 73 65 74 41 70 70 6c 69 63 61 74 69 6f 6e 28 29 20 6d 65 74 68 6f 64 3f 20 59 6f 75 | the.setApplication().method?.You |
791e0 | 20 63 61 6e 20 61 6c 73 6f 20 73 65 74 20 74 68 65 20 48 65 6c 70 65 72 53 65 74 20 64 69 72 65 | .can.also.set.the.HelperSet.dire |
79200 | 63 74 6c 79 20 75 73 69 6e 67 20 74 68 65 20 73 65 74 48 65 6c 70 65 72 53 65 74 28 29 20 6d 65 | ctly.using.the.setHelperSet().me |
79220 | 74 68 6f 64 2e 27 2c 20 24 6e 61 6d 65 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 | thod.',.$name));.........}...... |
79240 | 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 68 65 6c 70 65 72 53 65 74 2d 3e 67 65 74 | ....return.$this->helperSet->get |
79260 | 28 24 6e 61 6d 65 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 56 | ($name);.....}....../**......*.V |
79280 | 61 6c 69 64 61 74 65 73 20 61 20 63 6f 6d 6d 61 6e 64 20 6e 61 6d 65 2e 0a 20 20 20 20 20 2a 0a | alidates.a.command.name.......*. |
792a0 | 20 20 20 20 20 2a 20 49 74 20 6d 75 73 74 20 62 65 20 6e 6f 6e 2d 65 6d 70 74 79 20 61 6e 64 20 | .....*.It.must.be.non-empty.and. |
792c0 | 70 61 72 74 73 20 63 61 6e 20 6f 70 74 69 6f 6e 61 6c 6c 79 20 62 65 20 73 65 70 61 72 61 74 65 | parts.can.optionally.be.separate |
792e0 | 64 20 62 79 20 22 3a 22 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 | d.by.":".......*......*.@param.s |
79300 | 74 72 69 6e 67 20 24 6e 61 6d 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 | tring.$name......*......*.@throw |
79320 | 73 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 20 57 68 65 6e 20 | s.InvalidArgumentException.When. |
79340 | 74 68 65 20 6e 61 6d 65 20 69 73 20 69 6e 76 61 6c 69 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 | the.name.is.invalid......*/..... |
79360 | 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 76 61 6c 69 64 61 74 65 4e 61 6d 65 28 24 6e | private.function.validateName($n |
79380 | 61 6d 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 70 72 65 67 5f 6d 61 74 | ame).....{.........if.(!preg_mat |
793a0 | 63 68 28 27 2f 5e 5b 5e 5c 3a 5d 2b 2b 28 5c 3a 5b 5e 5c 3a 5d 2b 2b 29 2a 24 2f 27 2c 20 24 6e | ch('/^[^\:]++(\:[^\:]++)*$/',.$n |
793c0 | 61 6d 65 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 49 6e | ame)).{.............throw.new.In |
793e0 | 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 73 70 72 69 6e 74 66 28 27 | validArgumentException(sprintf(' |
79400 | 43 6f 6d 6d 61 6e 64 20 6e 61 6d 65 20 22 25 73 22 20 69 73 20 69 6e 76 61 6c 69 64 2e 27 2c 20 | Command.name."%s".is.invalid.',. |
79420 | 24 6e 61 6d 65 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 | $name));.........}.....}.}.<?php |
79440 | 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 | ../*..*.This.file.is.part.of.the |
79460 | 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 | .Symfony.package...*..*.(c).Fabi |
79480 | 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d | en.Potencier.<fabien@symfony.com |
794a0 | 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 | >..*..*.For.the.full.copyright.a |
794c0 | 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 | nd.license.information,.please.v |
794e0 | 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 | iew.the.LICENSE..*.file.that.was |
79500 | 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f | .distributed.with.this.source.co |
79520 | 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f | de...*/..namespace.Symfony\Compo |
79540 | 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 43 6f 6d 6d 61 6e 64 3b 0a 0a 75 73 65 20 53 79 6d 66 6f | nent\Console\Command;..use.Symfo |
79560 | 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 48 65 6c 70 65 72 5c 44 65 73 63 | ny\Component\Console\Helper\Desc |
79580 | 72 69 70 74 6f 72 48 65 6c 70 65 72 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e | riptorHelper;.use.Symfony\Compon |
795a0 | 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 5c 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 3b | ent\Console\Input\InputArgument; |
795c0 | 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 | .use.Symfony\Component\Console\I |
795e0 | 6e 70 75 74 5c 49 6e 70 75 74 4f 70 74 69 6f 6e 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f | nput\InputOption;.use.Symfony\Co |
79600 | 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 5c 49 6e 70 75 74 49 6e 74 65 72 | mponent\Console\Input\InputInter |
79620 | 66 61 63 65 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 | face;.use.Symfony\Component\Cons |
79640 | 6f 6c 65 5c 4f 75 74 70 75 74 5c 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 3b 0a 75 73 65 20 | ole\Output\OutputInterface;.use. |
79660 | 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 5c | Symfony\Component\Console\Input\ |
79680 | 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 3b 0a 0a 2f 2a 2a 0a 20 2a 20 4c 69 73 74 43 6f 6d | InputDefinition;../**..*.ListCom |
796a0 | 6d 61 6e 64 20 64 69 73 70 6c 61 79 73 20 74 68 65 20 6c 69 73 74 20 6f 66 20 61 6c 6c 20 61 76 | mand.displays.the.list.of.all.av |
796c0 | 61 69 6c 61 62 6c 65 20 63 6f 6d 6d 61 6e 64 73 20 66 6f 72 20 74 68 65 20 61 70 70 6c 69 63 61 | ailable.commands.for.the.applica |
796e0 | 74 69 6f 6e 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 46 61 62 69 65 6e 20 50 6f 74 65 6e | tion...*..*.@author.Fabien.Poten |
79700 | 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 2f 0a 63 6c | cier.<fabien@symfony.com>..*/.cl |
79720 | 61 73 73 20 4c 69 73 74 43 6f 6d 6d 61 6e 64 20 65 78 74 65 6e 64 73 20 43 6f 6d 6d 61 6e 64 0a | ass.ListCommand.extends.Command. |
79740 | 7b 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 | {...../**......*.{@inheritdoc}.. |
79760 | 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 63 6f | ....*/.....protected.function.co |
79780 | 6e 66 69 67 75 72 65 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 0a 20 20 | nfigure().....{.........$this... |
797a0 | 20 20 20 20 20 20 20 20 20 20 2d 3e 73 65 74 4e 61 6d 65 28 27 6c 69 73 74 27 29 0a 20 20 20 20 | ..........->setName('list')..... |
797c0 | 20 20 20 20 20 20 20 20 2d 3e 73 65 74 44 65 66 69 6e 69 74 69 6f 6e 28 24 74 68 69 73 2d 3e 63 | ........->setDefinition($this->c |
797e0 | 72 65 61 74 65 44 65 66 69 6e 69 74 69 6f 6e 28 29 29 0a 20 20 20 20 20 20 20 20 20 20 20 20 2d | reateDefinition()).............- |
79800 | 3e 73 65 74 44 65 73 63 72 69 70 74 69 6f 6e 28 27 4c 69 73 74 73 20 63 6f 6d 6d 61 6e 64 73 27 | >setDescription('Lists.commands' |
79820 | 29 0a 20 20 20 20 20 20 20 20 20 20 20 20 2d 3e 73 65 74 48 65 6c 70 28 3c 3c 3c 27 45 4f 46 27 | ).............->setHelp(<<<'EOF' |
79840 | 0a 54 68 65 20 3c 69 6e 66 6f 3e 25 63 6f 6d 6d 61 6e 64 2e 6e 61 6d 65 25 3c 2f 69 6e 66 6f 3e | .The.<info>%command.name%</info> |
79860 | 20 63 6f 6d 6d 61 6e 64 20 6c 69 73 74 73 20 61 6c 6c 20 63 6f 6d 6d 61 6e 64 73 3a 0a 0a 20 20 | .command.lists.all.commands:.... |
79880 | 3c 69 6e 66 6f 3e 70 68 70 20 25 63 6f 6d 6d 61 6e 64 2e 66 75 6c 6c 5f 6e 61 6d 65 25 3c 2f 69 | <info>php.%command.full_name%</i |
798a0 | 6e 66 6f 3e 0a 0a 59 6f 75 20 63 61 6e 20 61 6c 73 6f 20 64 69 73 70 6c 61 79 20 74 68 65 20 63 | nfo>..You.can.also.display.the.c |
798c0 | 6f 6d 6d 61 6e 64 73 20 66 6f 72 20 61 20 73 70 65 63 69 66 69 63 20 6e 61 6d 65 73 70 61 63 65 | ommands.for.a.specific.namespace |
798e0 | 3a 0a 0a 20 20 3c 69 6e 66 6f 3e 70 68 70 20 25 63 6f 6d 6d 61 6e 64 2e 66 75 6c 6c 5f 6e 61 6d | :....<info>php.%command.full_nam |
79900 | 65 25 20 74 65 73 74 3c 2f 69 6e 66 6f 3e 0a 0a 59 6f 75 20 63 61 6e 20 61 6c 73 6f 20 6f 75 74 | e%.test</info>..You.can.also.out |
79920 | 70 75 74 20 74 68 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 20 69 6e 20 6f 74 68 65 72 20 66 6f 72 | put.the.information.in.other.for |
79940 | 6d 61 74 73 20 62 79 20 75 73 69 6e 67 20 74 68 65 20 3c 63 6f 6d 6d 65 6e 74 3e 2d 2d 66 6f 72 | mats.by.using.the.<comment>--for |
79960 | 6d 61 74 3c 2f 63 6f 6d 6d 65 6e 74 3e 20 6f 70 74 69 6f 6e 3a 0a 0a 20 20 3c 69 6e 66 6f 3e 70 | mat</comment>.option:....<info>p |
79980 | 68 70 20 25 63 6f 6d 6d 61 6e 64 2e 66 75 6c 6c 5f 6e 61 6d 65 25 20 2d 2d 66 6f 72 6d 61 74 3d | hp.%command.full_name%.--format= |
799a0 | 78 6d 6c 3c 2f 69 6e 66 6f 3e 0a 0a 49 74 27 73 20 61 6c 73 6f 20 70 6f 73 73 69 62 6c 65 20 74 | xml</info>..It's.also.possible.t |
799c0 | 6f 20 67 65 74 20 72 61 77 20 6c 69 73 74 20 6f 66 20 63 6f 6d 6d 61 6e 64 73 20 28 75 73 65 66 | o.get.raw.list.of.commands.(usef |
799e0 | 75 6c 20 66 6f 72 20 65 6d 62 65 64 64 69 6e 67 20 63 6f 6d 6d 61 6e 64 20 72 75 6e 6e 65 72 29 | ul.for.embedding.command.runner) |
79a00 | 3a 0a 0a 20 20 3c 69 6e 66 6f 3e 70 68 70 20 25 63 6f 6d 6d 61 6e 64 2e 66 75 6c 6c 5f 6e 61 6d | :....<info>php.%command.full_nam |
79a20 | 65 25 20 2d 2d 72 61 77 3c 2f 69 6e 66 6f 3e 0a 45 4f 46 0a 20 20 20 20 20 20 20 20 20 20 20 20 | e%.--raw</info>.EOF............. |
79a40 | 29 0a 20 20 20 20 20 20 20 20 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 | ).........;.....}....../**...... |
79a60 | 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c | *.{@inheritdoc}......*/.....publ |
79a80 | 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 4e 61 74 69 76 65 44 65 66 69 6e 69 74 69 6f 6e 28 | ic.function.getNativeDefinition( |
79aa0 | 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 63 72 | ).....{.........return.$this->cr |
79ac0 | 65 61 74 65 44 65 66 69 6e 69 74 69 6f 6e 28 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a | eateDefinition();.....}....../** |
79ae0 | 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 | ......*.{@inheritdoc}......*/... |
79b00 | 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 65 78 65 63 75 74 65 28 49 6e 70 | ..protected.function.execute(Inp |
79b20 | 75 74 49 6e 74 65 72 66 61 63 65 20 24 69 6e 70 75 74 2c 20 4f 75 74 70 75 74 49 6e 74 65 72 66 | utInterface.$input,.OutputInterf |
79b40 | 61 63 65 20 24 6f 75 74 70 75 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 68 65 6c 70 | ace.$output).....{.........$help |
79b60 | 65 72 20 3d 20 6e 65 77 20 44 65 73 63 72 69 70 74 6f 72 48 65 6c 70 65 72 28 29 3b 0a 20 20 20 | er.=.new.DescriptorHelper();.... |
79b80 | 20 20 20 20 20 24 68 65 6c 70 65 72 2d 3e 64 65 73 63 72 69 62 65 28 24 6f 75 74 70 75 74 2c 20 | .....$helper->describe($output,. |
79ba0 | 24 74 68 69 73 2d 3e 67 65 74 41 70 70 6c 69 63 61 74 69 6f 6e 28 29 2c 20 61 72 72 61 79 28 0a | $this->getApplication(),.array(. |
79bc0 | 20 20 20 20 20 20 20 20 20 20 20 20 27 66 6f 72 6d 61 74 27 20 3d 3e 20 24 69 6e 70 75 74 2d 3e | ............'format'.=>.$input-> |
79be0 | 67 65 74 4f 70 74 69 6f 6e 28 27 66 6f 72 6d 61 74 27 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 | getOption('format'),............ |
79c00 | 20 27 72 61 77 5f 74 65 78 74 27 20 3d 3e 20 24 69 6e 70 75 74 2d 3e 67 65 74 4f 70 74 69 6f 6e | .'raw_text'.=>.$input->getOption |
79c20 | 28 27 72 61 77 27 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 6e 61 6d 65 73 70 61 63 65 27 | ('raw'),.............'namespace' |
79c40 | 20 3d 3e 20 24 69 6e 70 75 74 2d 3e 67 65 74 41 72 67 75 6d 65 6e 74 28 27 6e 61 6d 65 73 70 61 | .=>.$input->getArgument('namespa |
79c60 | 63 65 27 29 2c 0a 20 20 20 20 20 20 20 20 29 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a | ce'),.........));.....}....../** |
79c80 | 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 | ......*.{@inheritdoc}......*/... |
79ca0 | 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 63 72 65 61 74 65 44 65 66 69 6e 69 74 | ..private.function.createDefinit |
79cc0 | 69 6f 6e 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6e 65 77 20 49 | ion().....{.........return.new.I |
79ce0 | 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 28 61 72 72 61 79 28 0a 20 20 20 20 20 20 20 20 20 20 | nputDefinition(array(........... |
79d00 | 20 20 6e 65 77 20 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 28 27 6e 61 6d 65 73 70 61 63 65 27 2c | ..new.InputArgument('namespace', |
79d20 | 20 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 3a 3a 4f 50 54 49 4f 4e 41 4c 2c 20 27 54 68 65 20 6e | .InputArgument::OPTIONAL,.'The.n |
79d40 | 61 6d 65 73 70 61 63 65 20 6e 61 6d 65 27 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 6e 65 77 | amespace.name'),.............new |
79d60 | 20 49 6e 70 75 74 4f 70 74 69 6f 6e 28 27 72 61 77 27 2c 20 6e 75 6c 6c 2c 20 49 6e 70 75 74 4f | .InputOption('raw',.null,.InputO |
79d80 | 70 74 69 6f 6e 3a 3a 56 41 4c 55 45 5f 4e 4f 4e 45 2c 20 27 54 6f 20 6f 75 74 70 75 74 20 72 61 | ption::VALUE_NONE,.'To.output.ra |
79da0 | 77 20 63 6f 6d 6d 61 6e 64 20 6c 69 73 74 27 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 6e 65 | w.command.list'),.............ne |
79dc0 | 77 20 49 6e 70 75 74 4f 70 74 69 6f 6e 28 27 66 6f 72 6d 61 74 27 2c 20 6e 75 6c 6c 2c 20 49 6e | w.InputOption('format',.null,.In |
79de0 | 70 75 74 4f 70 74 69 6f 6e 3a 3a 56 41 4c 55 45 5f 52 45 51 55 49 52 45 44 2c 20 27 54 68 65 20 | putOption::VALUE_REQUIRED,.'The. |
79e00 | 6f 75 74 70 75 74 20 66 6f 72 6d 61 74 20 28 74 78 74 2c 20 78 6d 6c 2c 20 6a 73 6f 6e 2c 20 6f | output.format.(txt,.xml,.json,.o |
79e20 | 72 20 6d 64 29 27 2c 20 27 74 78 74 27 29 2c 0a 20 20 20 20 20 20 20 20 29 29 3b 0a 20 20 20 20 | r.md)',.'txt'),.........));..... |
79e40 | 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 | }.}.<?php../*..*.This.file.is.pa |
79e60 | 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a | rt.of.the.Symfony.package...*..* |
79e80 | 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 | .(c).Fabien.Potencier.<fabien@sy |
79ea0 | 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f | mfony.com>..*..*.For.the.full.co |
79ec0 | 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c | pyright.and.license.information, |
79ee0 | 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 | .please.view.the.LICENSE..*.file |
79f00 | 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 | .that.was.distributed.with.this. |
79f20 | 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 | source.code...*/..namespace.Symf |
79f40 | 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 44 65 73 63 72 69 70 74 6f 72 | ony\Component\Console\Descriptor |
79f60 | 3b 0a 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 | ;..use.Symfony\Component\Console |
79f80 | 5c 41 70 70 6c 69 63 61 74 69 6f 6e 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e | \Application;.use.Symfony\Compon |
79fa0 | 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 43 6f 6d 6d 61 6e 64 5c 43 6f 6d 6d 61 6e 64 3b 0a 75 73 65 | ent\Console\Command\Command;.use |
79fc0 | 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 | .Symfony\Component\Console\Input |
79fe0 | 5c 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 | \InputArgument;.use.Symfony\Comp |
7a000 | 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 5c 49 6e 70 75 74 44 65 66 69 6e 69 74 | onent\Console\Input\InputDefinit |
7a020 | 69 6f 6e 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f | ion;.use.Symfony\Component\Conso |
7a040 | 6c 65 5c 49 6e 70 75 74 5c 49 6e 70 75 74 4f 70 74 69 6f 6e 3b 0a 0a 2f 2a 2a 0a 20 2a 20 58 4d | le\Input\InputOption;../**..*.XM |
7a060 | 4c 20 64 65 73 63 72 69 70 74 6f 72 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 4a 65 61 6e | L.descriptor...*..*.@author.Jean |
7a080 | 2d 46 72 61 6e c3 a7 6f 69 73 20 53 69 6d 6f 6e 20 3c 63 6f 6e 74 61 63 74 40 6a 66 73 69 6d 6f | -Fran..ois.Simon.<contact@jfsimo |
7a0a0 | 6e 2e 66 72 3e 0a 20 2a 0a 20 2a 20 40 69 6e 74 65 72 6e 61 6c 0a 20 2a 2f 0a 63 6c 61 73 73 20 | n.fr>..*..*.@internal..*/.class. |
7a0c0 | 58 6d 6c 44 65 73 63 72 69 70 74 6f 72 20 65 78 74 65 6e 64 73 20 44 65 73 63 72 69 70 74 6f 72 | XmlDescriptor.extends.Descriptor |
7a0e0 | 0a 7b 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 49 6e 70 75 74 44 65 | .{...../**......*.@param.InputDe |
7a100 | 66 69 6e 69 74 69 6f 6e 20 24 64 65 66 69 6e 69 74 69 6f 6e 0a 20 20 20 20 20 2a 0a 20 20 20 20 | finition.$definition......*..... |
7a120 | 20 2a 20 40 72 65 74 75 72 6e 20 5c 44 4f 4d 44 6f 63 75 6d 65 6e 74 0a 20 20 20 20 20 2a 2f 0a | .*.@return.\DOMDocument......*/. |
7a140 | 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 49 6e 70 75 74 44 65 66 69 | ....public.function.getInputDefi |
7a160 | 6e 69 74 69 6f 6e 44 6f 63 75 6d 65 6e 74 28 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 20 24 | nitionDocument(InputDefinition.$ |
7a180 | 64 65 66 69 6e 69 74 69 6f 6e 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 64 6f 6d 20 3d | definition).....{.........$dom.= |
7a1a0 | 20 6e 65 77 20 5c 44 4f 4d 44 6f 63 75 6d 65 6e 74 28 27 31 2e 30 27 2c 20 27 55 54 46 2d 38 27 | .new.\DOMDocument('1.0',.'UTF-8' |
7a1c0 | 29 3b 0a 20 20 20 20 20 20 20 20 24 64 6f 6d 2d 3e 61 70 70 65 6e 64 43 68 69 6c 64 28 24 64 65 | );.........$dom->appendChild($de |
7a1e0 | 66 69 6e 69 74 69 6f 6e 58 4d 4c 20 3d 20 24 64 6f 6d 2d 3e 63 72 65 61 74 65 45 6c 65 6d 65 6e | finitionXML.=.$dom->createElemen |
7a200 | 74 28 27 64 65 66 69 6e 69 74 69 6f 6e 27 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 64 65 66 69 | t('definition'));..........$defi |
7a220 | 6e 69 74 69 6f 6e 58 4d 4c 2d 3e 61 70 70 65 6e 64 43 68 69 6c 64 28 24 61 72 67 75 6d 65 6e 74 | nitionXML->appendChild($argument |
7a240 | 73 58 4d 4c 20 3d 20 24 64 6f 6d 2d 3e 63 72 65 61 74 65 45 6c 65 6d 65 6e 74 28 27 61 72 67 75 | sXML.=.$dom->createElement('argu |
7a260 | 6d 65 6e 74 73 27 29 29 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 64 65 66 69 | ments'));.........foreach.($defi |
7a280 | 6e 69 74 69 6f 6e 2d 3e 67 65 74 41 72 67 75 6d 65 6e 74 73 28 29 20 61 73 20 24 61 72 67 75 6d | nition->getArguments().as.$argum |
7a2a0 | 65 6e 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 61 70 70 65 6e 64 | ent).{.............$this->append |
7a2c0 | 44 6f 63 75 6d 65 6e 74 28 24 61 72 67 75 6d 65 6e 74 73 58 4d 4c 2c 20 24 74 68 69 73 2d 3e 67 | Document($argumentsXML,.$this->g |
7a2e0 | 65 74 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 44 6f 63 75 6d 65 6e 74 28 24 61 72 67 75 6d 65 6e | etInputArgumentDocument($argumen |
7a300 | 74 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 64 65 66 69 6e 69 74 | t));.........}..........$definit |
7a320 | 69 6f 6e 58 4d 4c 2d 3e 61 70 70 65 6e 64 43 68 69 6c 64 28 24 6f 70 74 69 6f 6e 73 58 4d 4c 20 | ionXML->appendChild($optionsXML. |
7a340 | 3d 20 24 64 6f 6d 2d 3e 63 72 65 61 74 65 45 6c 65 6d 65 6e 74 28 27 6f 70 74 69 6f 6e 73 27 29 | =.$dom->createElement('options') |
7a360 | 29 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 64 65 66 69 6e 69 74 69 6f 6e 2d | );.........foreach.($definition- |
7a380 | 3e 67 65 74 4f 70 74 69 6f 6e 73 28 29 20 61 73 20 24 6f 70 74 69 6f 6e 29 20 7b 0a 20 20 20 20 | >getOptions().as.$option).{..... |
7a3a0 | 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 61 70 70 65 6e 64 44 6f 63 75 6d 65 6e 74 28 24 6f | ........$this->appendDocument($o |
7a3c0 | 70 74 69 6f 6e 73 58 4d 4c 2c 20 24 74 68 69 73 2d 3e 67 65 74 49 6e 70 75 74 4f 70 74 69 6f 6e | ptionsXML,.$this->getInputOption |
7a3e0 | 44 6f 63 75 6d 65 6e 74 28 24 6f 70 74 69 6f 6e 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 | Document($option));.........}... |
7a400 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 64 6f 6d 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f | .......return.$dom;.....}....../ |
7a420 | 2a 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 43 6f 6d 6d 61 6e 64 20 24 63 6f 6d 6d 61 6e | **......*.@param.Command.$comman |
7a440 | 64 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 5c 44 4f 4d 44 6f 63 75 | d......*......*.@return.\DOMDocu |
7a460 | 6d 65 6e 74 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e | ment......*/.....public.function |
7a480 | 20 67 65 74 43 6f 6d 6d 61 6e 64 44 6f 63 75 6d 65 6e 74 28 43 6f 6d 6d 61 6e 64 20 24 63 6f 6d | .getCommandDocument(Command.$com |
7a4a0 | 6d 61 6e 64 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 64 6f 6d 20 3d 20 6e 65 77 20 5c | mand).....{.........$dom.=.new.\ |
7a4c0 | 44 4f 4d 44 6f 63 75 6d 65 6e 74 28 27 31 2e 30 27 2c 20 27 55 54 46 2d 38 27 29 3b 0a 20 20 20 | DOMDocument('1.0',.'UTF-8');.... |
7a4e0 | 20 20 20 20 20 24 64 6f 6d 2d 3e 61 70 70 65 6e 64 43 68 69 6c 64 28 24 63 6f 6d 6d 61 6e 64 58 | .....$dom->appendChild($commandX |
7a500 | 4d 4c 20 3d 20 24 64 6f 6d 2d 3e 63 72 65 61 74 65 45 6c 65 6d 65 6e 74 28 27 63 6f 6d 6d 61 6e | ML.=.$dom->createElement('comman |
7a520 | 64 27 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 63 6f 6d 6d 61 6e 64 2d 3e 67 65 74 53 79 6e 6f | d'));..........$command->getSyno |
7a540 | 70 73 69 73 28 29 3b 0a 20 20 20 20 20 20 20 20 24 63 6f 6d 6d 61 6e 64 2d 3e 6d 65 72 67 65 41 | psis();.........$command->mergeA |
7a560 | 70 70 6c 69 63 61 74 69 6f 6e 44 65 66 69 6e 69 74 69 6f 6e 28 66 61 6c 73 65 29 3b 0a 0a 20 20 | pplicationDefinition(false);.... |
7a580 | 20 20 20 20 20 20 24 63 6f 6d 6d 61 6e 64 58 4d 4c 2d 3e 73 65 74 41 74 74 72 69 62 75 74 65 28 | ......$commandXML->setAttribute( |
7a5a0 | 27 69 64 27 2c 20 24 63 6f 6d 6d 61 6e 64 2d 3e 67 65 74 4e 61 6d 65 28 29 29 3b 0a 20 20 20 20 | 'id',.$command->getName());..... |
7a5c0 | 20 20 20 20 24 63 6f 6d 6d 61 6e 64 58 4d 4c 2d 3e 73 65 74 41 74 74 72 69 62 75 74 65 28 27 6e | ....$commandXML->setAttribute('n |
7a5e0 | 61 6d 65 27 2c 20 24 63 6f 6d 6d 61 6e 64 2d 3e 67 65 74 4e 61 6d 65 28 29 29 3b 0a 0a 20 20 20 | ame',.$command->getName());..... |
7a600 | 20 20 20 20 20 24 63 6f 6d 6d 61 6e 64 58 4d 4c 2d 3e 61 70 70 65 6e 64 43 68 69 6c 64 28 24 75 | .....$commandXML->appendChild($u |
7a620 | 73 61 67 65 73 58 4d 4c 20 3d 20 24 64 6f 6d 2d 3e 63 72 65 61 74 65 45 6c 65 6d 65 6e 74 28 27 | sagesXML.=.$dom->createElement(' |
7a640 | 75 73 61 67 65 73 27 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 61 72 72 | usages'));..........foreach.(arr |
7a660 | 61 79 5f 6d 65 72 67 65 28 61 72 72 61 79 28 24 63 6f 6d 6d 61 6e 64 2d 3e 67 65 74 53 79 6e 6f | ay_merge(array($command->getSyno |
7a680 | 70 73 69 73 28 29 29 2c 20 24 63 6f 6d 6d 61 6e 64 2d 3e 67 65 74 41 6c 69 61 73 65 73 28 29 2c | psis()),.$command->getAliases(), |
7a6a0 | 20 24 63 6f 6d 6d 61 6e 64 2d 3e 67 65 74 55 73 61 67 65 73 28 29 29 20 61 73 20 24 75 73 61 67 | .$command->getUsages()).as.$usag |
7a6c0 | 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 75 73 61 67 65 73 58 4d 4c 2d 3e 61 70 70 | e).{.............$usagesXML->app |
7a6e0 | 65 6e 64 43 68 69 6c 64 28 24 64 6f 6d 2d 3e 63 72 65 61 74 65 45 6c 65 6d 65 6e 74 28 27 75 73 | endChild($dom->createElement('us |
7a700 | 61 67 65 27 2c 20 24 75 73 61 67 65 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 | age',.$usage));.........}....... |
7a720 | 20 20 20 24 63 6f 6d 6d 61 6e 64 58 4d 4c 2d 3e 61 70 70 65 6e 64 43 68 69 6c 64 28 24 64 65 73 | ...$commandXML->appendChild($des |
7a740 | 63 72 69 70 74 69 6f 6e 58 4d 4c 20 3d 20 24 64 6f 6d 2d 3e 63 72 65 61 74 65 45 6c 65 6d 65 6e | criptionXML.=.$dom->createElemen |
7a760 | 74 28 27 64 65 73 63 72 69 70 74 69 6f 6e 27 29 29 3b 0a 20 20 20 20 20 20 20 20 24 64 65 73 63 | t('description'));.........$desc |
7a780 | 72 69 70 74 69 6f 6e 58 4d 4c 2d 3e 61 70 70 65 6e 64 43 68 69 6c 64 28 24 64 6f 6d 2d 3e 63 72 | riptionXML->appendChild($dom->cr |
7a7a0 | 65 61 74 65 54 65 78 74 4e 6f 64 65 28 73 74 72 5f 72 65 70 6c 61 63 65 28 22 5c 6e 22 2c 20 22 | eateTextNode(str_replace("\n",." |
7a7c0 | 5c 6e 20 22 2c 20 24 63 6f 6d 6d 61 6e 64 2d 3e 67 65 74 44 65 73 63 72 69 70 74 69 6f 6e 28 29 | \n.",.$command->getDescription() |
7a7e0 | 29 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 63 6f 6d 6d 61 6e 64 58 4d 4c 2d 3e 61 70 70 65 6e | )));..........$commandXML->appen |
7a800 | 64 43 68 69 6c 64 28 24 68 65 6c 70 58 4d 4c 20 3d 20 24 64 6f 6d 2d 3e 63 72 65 61 74 65 45 6c | dChild($helpXML.=.$dom->createEl |
7a820 | 65 6d 65 6e 74 28 27 68 65 6c 70 27 29 29 3b 0a 20 20 20 20 20 20 20 20 24 68 65 6c 70 58 4d 4c | ement('help'));.........$helpXML |
7a840 | 2d 3e 61 70 70 65 6e 64 43 68 69 6c 64 28 24 64 6f 6d 2d 3e 63 72 65 61 74 65 54 65 78 74 4e 6f | ->appendChild($dom->createTextNo |
7a860 | 64 65 28 73 74 72 5f 72 65 70 6c 61 63 65 28 22 5c 6e 22 2c 20 22 5c 6e 20 22 2c 20 24 63 6f 6d | de(str_replace("\n",."\n.",.$com |
7a880 | 6d 61 6e 64 2d 3e 67 65 74 50 72 6f 63 65 73 73 65 64 48 65 6c 70 28 29 29 29 29 3b 0a 0a 20 20 | mand->getProcessedHelp())));.... |
7a8a0 | 20 20 20 20 20 20 24 64 65 66 69 6e 69 74 69 6f 6e 58 4d 4c 20 3d 20 24 74 68 69 73 2d 3e 67 65 | ......$definitionXML.=.$this->ge |
7a8c0 | 74 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 44 6f 63 75 6d 65 6e 74 28 24 63 6f 6d 6d 61 6e | tInputDefinitionDocument($comman |
7a8e0 | 64 2d 3e 67 65 74 4e 61 74 69 76 65 44 65 66 69 6e 69 74 69 6f 6e 28 29 29 3b 0a 20 20 20 20 20 | d->getNativeDefinition());...... |
7a900 | 20 20 20 24 74 68 69 73 2d 3e 61 70 70 65 6e 64 44 6f 63 75 6d 65 6e 74 28 24 63 6f 6d 6d 61 6e | ...$this->appendDocument($comman |
7a920 | 64 58 4d 4c 2c 20 24 64 65 66 69 6e 69 74 69 6f 6e 58 4d 4c 2d 3e 67 65 74 45 6c 65 6d 65 6e 74 | dXML,.$definitionXML->getElement |
7a940 | 73 42 79 54 61 67 4e 61 6d 65 28 27 64 65 66 69 6e 69 74 69 6f 6e 27 29 2d 3e 69 74 65 6d 28 30 | sByTagName('definition')->item(0 |
7a960 | 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 64 6f 6d 3b 0a 20 20 20 20 7d 0a | ));..........return.$dom;.....}. |
7a980 | 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 41 70 70 6c 69 63 61 74 69 | ...../**......*.@param.Applicati |
7a9a0 | 6f 6e 20 24 61 70 70 6c 69 63 61 74 69 6f 6e 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 | on.$application......*.@param.st |
7a9c0 | 72 69 6e 67 7c 6e 75 6c 6c 20 24 6e 61 6d 65 73 70 61 63 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 | ring|null.$namespace......*..... |
7a9e0 | 20 2a 20 40 72 65 74 75 72 6e 20 5c 44 4f 4d 44 6f 63 75 6d 65 6e 74 0a 20 20 20 20 20 2a 2f 0a | .*.@return.\DOMDocument......*/. |
7aa00 | 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 41 70 70 6c 69 63 61 74 69 | ....public.function.getApplicati |
7aa20 | 6f 6e 44 6f 63 75 6d 65 6e 74 28 41 70 70 6c 69 63 61 74 69 6f 6e 20 24 61 70 70 6c 69 63 61 74 | onDocument(Application.$applicat |
7aa40 | 69 6f 6e 2c 20 24 6e 61 6d 65 73 70 61 63 65 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 | ion,.$namespace.=.null).....{... |
7aa60 | 20 20 20 20 20 20 24 64 6f 6d 20 3d 20 6e 65 77 20 5c 44 4f 4d 44 6f 63 75 6d 65 6e 74 28 27 31 | ......$dom.=.new.\DOMDocument('1 |
7aa80 | 2e 30 27 2c 20 27 55 54 46 2d 38 27 29 3b 0a 20 20 20 20 20 20 20 20 24 64 6f 6d 2d 3e 61 70 70 | .0',.'UTF-8');.........$dom->app |
7aaa0 | 65 6e 64 43 68 69 6c 64 28 24 72 6f 6f 74 58 6d 6c 20 3d 20 24 64 6f 6d 2d 3e 63 72 65 61 74 65 | endChild($rootXml.=.$dom->create |
7aac0 | 45 6c 65 6d 65 6e 74 28 27 73 79 6d 66 6f 6e 79 27 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 | Element('symfony'));..........if |
7aae0 | 20 28 24 61 70 70 6c 69 63 61 74 69 6f 6e 2d 3e 67 65 74 4e 61 6d 65 28 29 20 21 3d 3d 20 27 55 | .($application->getName().!==.'U |
7ab00 | 4e 4b 4e 4f 57 4e 27 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 72 6f 6f 74 58 6d 6c 2d | NKNOWN').{.............$rootXml- |
7ab20 | 3e 73 65 74 41 74 74 72 69 62 75 74 65 28 27 6e 61 6d 65 27 2c 20 24 61 70 70 6c 69 63 61 74 69 | >setAttribute('name',.$applicati |
7ab40 | 6f 6e 2d 3e 67 65 74 4e 61 6d 65 28 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 | on->getName());.............if.( |
7ab60 | 24 61 70 70 6c 69 63 61 74 69 6f 6e 2d 3e 67 65 74 56 65 72 73 69 6f 6e 28 29 20 21 3d 3d 20 27 | $application->getVersion().!==.' |
7ab80 | 55 4e 4b 4e 4f 57 4e 27 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 72 6f 6f | UNKNOWN').{.................$roo |
7aba0 | 74 58 6d 6c 2d 3e 73 65 74 41 74 74 72 69 62 75 74 65 28 27 76 65 72 73 69 6f 6e 27 2c 20 24 61 | tXml->setAttribute('version',.$a |
7abc0 | 70 70 6c 69 63 61 74 69 6f 6e 2d 3e 67 65 74 56 65 72 73 69 6f 6e 28 29 29 3b 0a 20 20 20 20 20 | pplication->getVersion());...... |
7abe0 | 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 72 6f 6f | .......}.........}..........$roo |
7ac00 | 74 58 6d 6c 2d 3e 61 70 70 65 6e 64 43 68 69 6c 64 28 24 63 6f 6d 6d 61 6e 64 73 58 4d 4c 20 3d | tXml->appendChild($commandsXML.= |
7ac20 | 20 24 64 6f 6d 2d 3e 63 72 65 61 74 65 45 6c 65 6d 65 6e 74 28 27 63 6f 6d 6d 61 6e 64 73 27 29 | .$dom->createElement('commands') |
7ac40 | 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 64 65 73 63 72 69 70 74 69 6f 6e 20 3d 20 6e 65 77 20 41 | );..........$description.=.new.A |
7ac60 | 70 70 6c 69 63 61 74 69 6f 6e 44 65 73 63 72 69 70 74 69 6f 6e 28 24 61 70 70 6c 69 63 61 74 69 | pplicationDescription($applicati |
7ac80 | 6f 6e 2c 20 24 6e 61 6d 65 73 70 61 63 65 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 6e | on,.$namespace);..........if.($n |
7aca0 | 61 6d 65 73 70 61 63 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6f 6d 6d 61 6e 64 | amespace).{.............$command |
7acc0 | 73 58 4d 4c 2d 3e 73 65 74 41 74 74 72 69 62 75 74 65 28 27 6e 61 6d 65 73 70 61 63 65 27 2c 20 | sXML->setAttribute('namespace',. |
7ace0 | 24 6e 61 6d 65 73 70 61 63 65 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 | $namespace);.........}.......... |
7ad00 | 66 6f 72 65 61 63 68 20 28 24 64 65 73 63 72 69 70 74 69 6f 6e 2d 3e 67 65 74 43 6f 6d 6d 61 6e | foreach.($description->getComman |
7ad20 | 64 73 28 29 20 61 73 20 24 63 6f 6d 6d 61 6e 64 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ds().as.$command).{............. |
7ad40 | 24 74 68 69 73 2d 3e 61 70 70 65 6e 64 44 6f 63 75 6d 65 6e 74 28 24 63 6f 6d 6d 61 6e 64 73 58 | $this->appendDocument($commandsX |
7ad60 | 4d 4c 2c 20 24 74 68 69 73 2d 3e 67 65 74 43 6f 6d 6d 61 6e 64 44 6f 63 75 6d 65 6e 74 28 24 63 | ML,.$this->getCommandDocument($c |
7ad80 | 6f 6d 6d 61 6e 64 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 | ommand));.........}..........if. |
7ada0 | 28 21 24 6e 61 6d 65 73 70 61 63 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 72 6f 6f | (!$namespace).{.............$roo |
7adc0 | 74 58 6d 6c 2d 3e 61 70 70 65 6e 64 43 68 69 6c 64 28 24 6e 61 6d 65 73 70 61 63 65 73 58 4d 4c | tXml->appendChild($namespacesXML |
7ade0 | 20 3d 20 24 64 6f 6d 2d 3e 63 72 65 61 74 65 45 6c 65 6d 65 6e 74 28 27 6e 61 6d 65 73 70 61 63 | .=.$dom->createElement('namespac |
7ae00 | 65 73 27 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 64 65 | es'));..............foreach.($de |
7ae20 | 73 63 72 69 70 74 69 6f 6e 2d 3e 67 65 74 4e 61 6d 65 73 70 61 63 65 73 28 29 20 61 73 20 24 6e | scription->getNamespaces().as.$n |
7ae40 | 61 6d 65 73 70 61 63 65 44 65 73 63 72 69 70 74 69 6f 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | amespaceDescription).{.......... |
7ae60 | 20 20 20 20 20 20 20 24 6e 61 6d 65 73 70 61 63 65 73 58 4d 4c 2d 3e 61 70 70 65 6e 64 43 68 69 | .......$namespacesXML->appendChi |
7ae80 | 6c 64 28 24 6e 61 6d 65 73 70 61 63 65 41 72 72 61 79 58 4d 4c 20 3d 20 24 64 6f 6d 2d 3e 63 72 | ld($namespaceArrayXML.=.$dom->cr |
7aea0 | 65 61 74 65 45 6c 65 6d 65 6e 74 28 27 6e 61 6d 65 73 70 61 63 65 27 29 29 3b 0a 20 20 20 20 20 | eateElement('namespace'));...... |
7aec0 | 20 20 20 20 20 20 20 20 20 20 20 24 6e 61 6d 65 73 70 61 63 65 41 72 72 61 79 58 4d 4c 2d 3e 73 | ...........$namespaceArrayXML->s |
7aee0 | 65 74 41 74 74 72 69 62 75 74 65 28 27 69 64 27 2c 20 24 6e 61 6d 65 73 70 61 63 65 44 65 73 63 | etAttribute('id',.$namespaceDesc |
7af00 | 72 69 70 74 69 6f 6e 5b 27 69 64 27 5d 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ription['id']);................. |
7af20 | 20 66 6f 72 65 61 63 68 20 28 24 6e 61 6d 65 73 70 61 63 65 44 65 73 63 72 69 70 74 69 6f 6e 5b | .foreach.($namespaceDescription[ |
7af40 | 27 63 6f 6d 6d 61 6e 64 73 27 5d 20 61 73 20 24 6e 61 6d 65 29 20 7b 0a 20 20 20 20 20 20 20 20 | 'commands'].as.$name).{......... |
7af60 | 20 20 20 20 20 20 20 20 20 20 20 20 24 6e 61 6d 65 73 70 61 63 65 41 72 72 61 79 58 4d 4c 2d 3e | ............$namespaceArrayXML-> |
7af80 | 61 70 70 65 6e 64 43 68 69 6c 64 28 24 63 6f 6d 6d 61 6e 64 58 4d 4c 20 3d 20 24 64 6f 6d 2d 3e | appendChild($commandXML.=.$dom-> |
7afa0 | 63 72 65 61 74 65 45 6c 65 6d 65 6e 74 28 27 63 6f 6d 6d 61 6e 64 27 29 29 3b 0a 20 20 20 20 20 | createElement('command'));...... |
7afc0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6f 6d 6d 61 6e 64 58 4d 4c 2d 3e 61 70 70 65 | ...............$commandXML->appe |
7afe0 | 6e 64 43 68 69 6c 64 28 24 64 6f 6d 2d 3e 63 72 65 61 74 65 54 65 78 74 4e 6f 64 65 28 24 6e 61 | ndChild($dom->createTextNode($na |
7b000 | 6d 65 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 | me));.................}......... |
7b020 | 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 | ....}.........}..........return. |
7b040 | 24 64 6f 6d 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e | $dom;.....}....../**......*.{@in |
7b060 | 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 | heritdoc}......*/.....protected. |
7b080 | 66 75 6e 63 74 69 6f 6e 20 64 65 73 63 72 69 62 65 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 28 49 | function.describeInputArgument(I |
7b0a0 | 6e 70 75 74 41 72 67 75 6d 65 6e 74 20 24 61 72 67 75 6d 65 6e 74 2c 20 61 72 72 61 79 20 24 6f | nputArgument.$argument,.array.$o |
7b0c0 | 70 74 69 6f 6e 73 20 3d 20 61 72 72 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | ptions.=.array()).....{......... |
7b0e0 | 24 74 68 69 73 2d 3e 77 72 69 74 65 44 6f 63 75 6d 65 6e 74 28 24 74 68 69 73 2d 3e 67 65 74 49 | $this->writeDocument($this->getI |
7b100 | 6e 70 75 74 41 72 67 75 6d 65 6e 74 44 6f 63 75 6d 65 6e 74 28 24 61 72 67 75 6d 65 6e 74 29 29 | nputArgumentDocument($argument)) |
7b120 | 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 | ;.....}....../**......*.{@inheri |
7b140 | 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 | tdoc}......*/.....protected.func |
7b160 | 74 69 6f 6e 20 64 65 73 63 72 69 62 65 49 6e 70 75 74 4f 70 74 69 6f 6e 28 49 6e 70 75 74 4f 70 | tion.describeInputOption(InputOp |
7b180 | 74 69 6f 6e 20 24 6f 70 74 69 6f 6e 2c 20 61 72 72 61 79 20 24 6f 70 74 69 6f 6e 73 20 3d 20 61 | tion.$option,.array.$options.=.a |
7b1a0 | 72 72 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 | rray()).....{.........$this->wri |
7b1c0 | 74 65 44 6f 63 75 6d 65 6e 74 28 24 74 68 69 73 2d 3e 67 65 74 49 6e 70 75 74 4f 70 74 69 6f 6e | teDocument($this->getInputOption |
7b1e0 | 44 6f 63 75 6d 65 6e 74 28 24 6f 70 74 69 6f 6e 29 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f | Document($option));.....}....../ |
7b200 | 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a | **......*.{@inheritdoc}......*/. |
7b220 | 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 64 65 73 63 72 69 62 65 49 | ....protected.function.describeI |
7b240 | 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 28 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 20 24 | nputDefinition(InputDefinition.$ |
7b260 | 64 65 66 69 6e 69 74 69 6f 6e 2c 20 61 72 72 61 79 20 24 6f 70 74 69 6f 6e 73 20 3d 20 61 72 72 | definition,.array.$options.=.arr |
7b280 | 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 | ay()).....{.........$this->write |
7b2a0 | 44 6f 63 75 6d 65 6e 74 28 24 74 68 69 73 2d 3e 67 65 74 49 6e 70 75 74 44 65 66 69 6e 69 74 69 | Document($this->getInputDefiniti |
7b2c0 | 6f 6e 44 6f 63 75 6d 65 6e 74 28 24 64 65 66 69 6e 69 74 69 6f 6e 29 29 3b 0a 20 20 20 20 7d 0a | onDocument($definition));.....}. |
7b2e0 | 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 | ...../**......*.{@inheritdoc}... |
7b300 | 20 20 20 2a 2f 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 64 65 73 | ...*/.....protected.function.des |
7b320 | 63 72 69 62 65 43 6f 6d 6d 61 6e 64 28 43 6f 6d 6d 61 6e 64 20 24 63 6f 6d 6d 61 6e 64 2c 20 61 | cribeCommand(Command.$command,.a |
7b340 | 72 72 61 79 20 24 6f 70 74 69 6f 6e 73 20 3d 20 61 72 72 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 | rray.$options.=.array()).....{.. |
7b360 | 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 44 6f 63 75 6d 65 6e 74 28 24 74 68 69 | .......$this->writeDocument($thi |
7b380 | 73 2d 3e 67 65 74 43 6f 6d 6d 61 6e 64 44 6f 63 75 6d 65 6e 74 28 24 63 6f 6d 6d 61 6e 64 29 29 | s->getCommandDocument($command)) |
7b3a0 | 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 | ;.....}....../**......*.{@inheri |
7b3c0 | 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 | tdoc}......*/.....protected.func |
7b3e0 | 74 69 6f 6e 20 64 65 73 63 72 69 62 65 41 70 70 6c 69 63 61 74 69 6f 6e 28 41 70 70 6c 69 63 61 | tion.describeApplication(Applica |
7b400 | 74 69 6f 6e 20 24 61 70 70 6c 69 63 61 74 69 6f 6e 2c 20 61 72 72 61 79 20 24 6f 70 74 69 6f 6e | tion.$application,.array.$option |
7b420 | 73 20 3d 20 61 72 72 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 | s.=.array()).....{.........$this |
7b440 | 2d 3e 77 72 69 74 65 44 6f 63 75 6d 65 6e 74 28 24 74 68 69 73 2d 3e 67 65 74 41 70 70 6c 69 63 | ->writeDocument($this->getApplic |
7b460 | 61 74 69 6f 6e 44 6f 63 75 6d 65 6e 74 28 24 61 70 70 6c 69 63 61 74 69 6f 6e 2c 20 69 73 73 65 | ationDocument($application,.isse |
7b480 | 74 28 24 6f 70 74 69 6f 6e 73 5b 27 6e 61 6d 65 73 70 61 63 65 27 5d 29 20 3f 20 24 6f 70 74 69 | t($options['namespace']).?.$opti |
7b4a0 | 6f 6e 73 5b 27 6e 61 6d 65 73 70 61 63 65 27 5d 20 3a 20 6e 75 6c 6c 29 29 3b 0a 20 20 20 20 7d | ons['namespace'].:.null));.....} |
7b4c0 | 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 41 70 70 65 6e 64 73 20 64 6f 63 75 6d 65 6e | ....../**......*.Appends.documen |
7b4e0 | 74 20 63 68 69 6c 64 72 65 6e 20 74 6f 20 70 61 72 65 6e 74 20 6e 6f 64 65 2e 0a 20 20 20 20 20 | t.children.to.parent.node....... |
7b500 | 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 5c 44 4f 4d 4e 6f 64 65 20 24 70 61 72 65 6e 74 | *......*.@param.\DOMNode.$parent |
7b520 | 4e 6f 64 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 5c 44 4f 4d 4e 6f 64 65 20 24 69 6d 70 | Node......*.@param.\DOMNode.$imp |
7b540 | 6f 72 74 65 64 50 61 72 65 6e 74 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 | ortedParent......*/.....private. |
7b560 | 66 75 6e 63 74 69 6f 6e 20 61 70 70 65 6e 64 44 6f 63 75 6d 65 6e 74 28 5c 44 4f 4d 4e 6f 64 65 | function.appendDocument(\DOMNode |
7b580 | 20 24 70 61 72 65 6e 74 4e 6f 64 65 2c 20 5c 44 4f 4d 4e 6f 64 65 20 24 69 6d 70 6f 72 74 65 64 | .$parentNode,.\DOMNode.$imported |
7b5a0 | 50 61 72 65 6e 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 | Parent).....{.........foreach.($ |
7b5c0 | 69 6d 70 6f 72 74 65 64 50 61 72 65 6e 74 2d 3e 63 68 69 6c 64 4e 6f 64 65 73 20 61 73 20 24 63 | importedParent->childNodes.as.$c |
7b5e0 | 68 69 6c 64 4e 6f 64 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 70 61 72 65 6e 74 4e | hildNode).{.............$parentN |
7b600 | 6f 64 65 2d 3e 61 70 70 65 6e 64 43 68 69 6c 64 28 24 70 61 72 65 6e 74 4e 6f 64 65 2d 3e 6f 77 | ode->appendChild($parentNode->ow |
7b620 | 6e 65 72 44 6f 63 75 6d 65 6e 74 2d 3e 69 6d 70 6f 72 74 4e 6f 64 65 28 24 63 68 69 6c 64 4e 6f | nerDocument->importNode($childNo |
7b640 | 64 65 2c 20 74 72 75 65 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 | de,.true));.........}.....}..... |
7b660 | 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 57 72 69 74 65 73 20 44 4f 4d 20 64 6f 63 75 6d 65 6e 74 2e | ./**......*.Writes.DOM.document. |
7b680 | 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 5c 44 4f 4d 44 6f 63 75 6d 65 | ......*......*.@param.\DOMDocume |
7b6a0 | 6e 74 20 24 64 6f 6d 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 5c 44 | nt.$dom......*......*.@return.\D |
7b6c0 | 4f 4d 44 6f 63 75 6d 65 6e 74 7c 73 74 72 69 6e 67 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 | OMDocument|string......*/.....pr |
7b6e0 | 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 77 72 69 74 65 44 6f 63 75 6d 65 6e 74 28 5c 44 4f | ivate.function.writeDocument(\DO |
7b700 | 4d 44 6f 63 75 6d 65 6e 74 20 24 64 6f 6d 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 64 | MDocument.$dom).....{.........$d |
7b720 | 6f 6d 2d 3e 66 6f 72 6d 61 74 4f 75 74 70 75 74 20 3d 20 74 72 75 65 3b 0a 20 20 20 20 20 20 20 | om->formatOutput.=.true;........ |
7b740 | 20 24 74 68 69 73 2d 3e 77 72 69 74 65 28 24 64 6f 6d 2d 3e 73 61 76 65 58 4d 4c 28 29 29 3b 0a | .$this->write($dom->saveXML());. |
7b760 | 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 49 6e 70 | ....}....../**......*.@param.Inp |
7b780 | 75 74 41 72 67 75 6d 65 6e 74 20 24 61 72 67 75 6d 65 6e 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 | utArgument.$argument......*..... |
7b7a0 | 20 2a 20 40 72 65 74 75 72 6e 20 5c 44 4f 4d 44 6f 63 75 6d 65 6e 74 0a 20 20 20 20 20 2a 2f 0a | .*.@return.\DOMDocument......*/. |
7b7c0 | 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 49 6e 70 75 74 41 72 67 | ....private.function.getInputArg |
7b7e0 | 75 6d 65 6e 74 44 6f 63 75 6d 65 6e 74 28 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 20 24 61 72 67 | umentDocument(InputArgument.$arg |
7b800 | 75 6d 65 6e 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 64 6f 6d 20 3d 20 6e 65 77 20 | ument).....{.........$dom.=.new. |
7b820 | 5c 44 4f 4d 44 6f 63 75 6d 65 6e 74 28 27 31 2e 30 27 2c 20 27 55 54 46 2d 38 27 29 3b 0a 0a 20 | \DOMDocument('1.0',.'UTF-8');... |
7b840 | 20 20 20 20 20 20 20 24 64 6f 6d 2d 3e 61 70 70 65 6e 64 43 68 69 6c 64 28 24 6f 62 6a 65 63 74 | .......$dom->appendChild($object |
7b860 | 58 4d 4c 20 3d 20 24 64 6f 6d 2d 3e 63 72 65 61 74 65 45 6c 65 6d 65 6e 74 28 27 61 72 67 75 6d | XML.=.$dom->createElement('argum |
7b880 | 65 6e 74 27 29 29 3b 0a 20 20 20 20 20 20 20 20 24 6f 62 6a 65 63 74 58 4d 4c 2d 3e 73 65 74 41 | ent'));.........$objectXML->setA |
7b8a0 | 74 74 72 69 62 75 74 65 28 27 6e 61 6d 65 27 2c 20 24 61 72 67 75 6d 65 6e 74 2d 3e 67 65 74 4e | ttribute('name',.$argument->getN |
7b8c0 | 61 6d 65 28 29 29 3b 0a 20 20 20 20 20 20 20 20 24 6f 62 6a 65 63 74 58 4d 4c 2d 3e 73 65 74 41 | ame());.........$objectXML->setA |
7b8e0 | 74 74 72 69 62 75 74 65 28 27 69 73 5f 72 65 71 75 69 72 65 64 27 2c 20 24 61 72 67 75 6d 65 6e | ttribute('is_required',.$argumen |
7b900 | 74 2d 3e 69 73 52 65 71 75 69 72 65 64 28 29 20 3f 20 31 20 3a 20 30 29 3b 0a 20 20 20 20 20 20 | t->isRequired().?.1.:.0);....... |
7b920 | 20 20 24 6f 62 6a 65 63 74 58 4d 4c 2d 3e 73 65 74 41 74 74 72 69 62 75 74 65 28 27 69 73 5f 61 | ..$objectXML->setAttribute('is_a |
7b940 | 72 72 61 79 27 2c 20 24 61 72 67 75 6d 65 6e 74 2d 3e 69 73 41 72 72 61 79 28 29 20 3f 20 31 20 | rray',.$argument->isArray().?.1. |
7b960 | 3a 20 30 29 3b 0a 20 20 20 20 20 20 20 20 24 6f 62 6a 65 63 74 58 4d 4c 2d 3e 61 70 70 65 6e 64 | :.0);.........$objectXML->append |
7b980 | 43 68 69 6c 64 28 24 64 65 73 63 72 69 70 74 69 6f 6e 58 4d 4c 20 3d 20 24 64 6f 6d 2d 3e 63 72 | Child($descriptionXML.=.$dom->cr |
7b9a0 | 65 61 74 65 45 6c 65 6d 65 6e 74 28 27 64 65 73 63 72 69 70 74 69 6f 6e 27 29 29 3b 0a 20 20 20 | eateElement('description'));.... |
7b9c0 | 20 20 20 20 20 24 64 65 73 63 72 69 70 74 69 6f 6e 58 4d 4c 2d 3e 61 70 70 65 6e 64 43 68 69 6c | .....$descriptionXML->appendChil |
7b9e0 | 64 28 24 64 6f 6d 2d 3e 63 72 65 61 74 65 54 65 78 74 4e 6f 64 65 28 24 61 72 67 75 6d 65 6e 74 | d($dom->createTextNode($argument |
7ba00 | 2d 3e 67 65 74 44 65 73 63 72 69 70 74 69 6f 6e 28 29 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 | ->getDescription()));..........$ |
7ba20 | 6f 62 6a 65 63 74 58 4d 4c 2d 3e 61 70 70 65 6e 64 43 68 69 6c 64 28 24 64 65 66 61 75 6c 74 73 | objectXML->appendChild($defaults |
7ba40 | 58 4d 4c 20 3d 20 24 64 6f 6d 2d 3e 63 72 65 61 74 65 45 6c 65 6d 65 6e 74 28 27 64 65 66 61 75 | XML.=.$dom->createElement('defau |
7ba60 | 6c 74 73 27 29 29 3b 0a 20 20 20 20 20 20 20 20 24 64 65 66 61 75 6c 74 73 20 3d 20 69 73 5f 61 | lts'));.........$defaults.=.is_a |
7ba80 | 72 72 61 79 28 24 61 72 67 75 6d 65 6e 74 2d 3e 67 65 74 44 65 66 61 75 6c 74 28 29 29 20 3f 20 | rray($argument->getDefault()).?. |
7baa0 | 24 61 72 67 75 6d 65 6e 74 2d 3e 67 65 74 44 65 66 61 75 6c 74 28 29 20 3a 20 28 69 73 5f 62 6f | $argument->getDefault().:.(is_bo |
7bac0 | 6f 6c 28 24 61 72 67 75 6d 65 6e 74 2d 3e 67 65 74 44 65 66 61 75 6c 74 28 29 29 20 3f 20 61 72 | ol($argument->getDefault()).?.ar |
7bae0 | 72 61 79 28 76 61 72 5f 65 78 70 6f 72 74 28 24 61 72 67 75 6d 65 6e 74 2d 3e 67 65 74 44 65 66 | ray(var_export($argument->getDef |
7bb00 | 61 75 6c 74 28 29 2c 20 74 72 75 65 29 29 20 3a 20 28 24 61 72 67 75 6d 65 6e 74 2d 3e 67 65 74 | ault(),.true)).:.($argument->get |
7bb20 | 44 65 66 61 75 6c 74 28 29 20 3f 20 61 72 72 61 79 28 24 61 72 67 75 6d 65 6e 74 2d 3e 67 65 74 | Default().?.array($argument->get |
7bb40 | 44 65 66 61 75 6c 74 28 29 29 20 3a 20 61 72 72 61 79 28 29 29 29 3b 0a 20 20 20 20 20 20 20 20 | Default()).:.array()));......... |
7bb60 | 66 6f 72 65 61 63 68 20 28 24 64 65 66 61 75 6c 74 73 20 61 73 20 24 64 65 66 61 75 6c 74 29 20 | foreach.($defaults.as.$default). |
7bb80 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 64 65 66 61 75 6c 74 73 58 4d 4c 2d 3e 61 70 70 65 | {.............$defaultsXML->appe |
7bba0 | 6e 64 43 68 69 6c 64 28 24 64 65 66 61 75 6c 74 58 4d 4c 20 3d 20 24 64 6f 6d 2d 3e 63 72 65 61 | ndChild($defaultXML.=.$dom->crea |
7bbc0 | 74 65 45 6c 65 6d 65 6e 74 28 27 64 65 66 61 75 6c 74 27 29 29 3b 0a 20 20 20 20 20 20 20 20 20 | teElement('default'));.......... |
7bbe0 | 20 20 20 24 64 65 66 61 75 6c 74 58 4d 4c 2d 3e 61 70 70 65 6e 64 43 68 69 6c 64 28 24 64 6f 6d | ...$defaultXML->appendChild($dom |
7bc00 | 2d 3e 63 72 65 61 74 65 54 65 78 74 4e 6f 64 65 28 24 64 65 66 61 75 6c 74 29 29 3b 0a 20 20 20 | ->createTextNode($default));.... |
7bc20 | 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 64 6f 6d 3b 0a 20 20 20 | .....}..........return.$dom;.... |
7bc40 | 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 49 6e 70 75 74 4f | .}....../**......*.@param.InputO |
7bc60 | 70 74 69 6f 6e 20 24 6f 70 74 69 6f 6e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 | ption.$option......*......*.@ret |
7bc80 | 75 72 6e 20 5c 44 4f 4d 44 6f 63 75 6d 65 6e 74 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 | urn.\DOMDocument......*/.....pri |
7bca0 | 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 49 6e 70 75 74 4f 70 74 69 6f 6e 44 6f 63 75 | vate.function.getInputOptionDocu |
7bcc0 | 6d 65 6e 74 28 49 6e 70 75 74 4f 70 74 69 6f 6e 20 24 6f 70 74 69 6f 6e 29 0a 20 20 20 20 7b 0a | ment(InputOption.$option).....{. |
7bce0 | 20 20 20 20 20 20 20 20 24 64 6f 6d 20 3d 20 6e 65 77 20 5c 44 4f 4d 44 6f 63 75 6d 65 6e 74 28 | ........$dom.=.new.\DOMDocument( |
7bd00 | 27 31 2e 30 27 2c 20 27 55 54 46 2d 38 27 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 64 6f 6d 2d 3e | '1.0',.'UTF-8');..........$dom-> |
7bd20 | 61 70 70 65 6e 64 43 68 69 6c 64 28 24 6f 62 6a 65 63 74 58 4d 4c 20 3d 20 24 64 6f 6d 2d 3e 63 | appendChild($objectXML.=.$dom->c |
7bd40 | 72 65 61 74 65 45 6c 65 6d 65 6e 74 28 27 6f 70 74 69 6f 6e 27 29 29 3b 0a 20 20 20 20 20 20 20 | reateElement('option'));........ |
7bd60 | 20 24 6f 62 6a 65 63 74 58 4d 4c 2d 3e 73 65 74 41 74 74 72 69 62 75 74 65 28 27 6e 61 6d 65 27 | .$objectXML->setAttribute('name' |
7bd80 | 2c 20 27 2d 2d 27 2e 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 4e 61 6d 65 28 29 29 3b 0a 20 20 20 20 | ,.'--'.$option->getName());..... |
7bda0 | 20 20 20 20 24 70 6f 73 20 3d 20 73 74 72 70 6f 73 28 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 53 68 | ....$pos.=.strpos($option->getSh |
7bdc0 | 6f 72 74 63 75 74 28 29 2c 20 27 7c 27 29 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 66 61 6c 73 | ortcut(),.'|');.........if.(fals |
7bde0 | 65 20 21 3d 3d 20 24 70 6f 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 62 6a 65 63 | e.!==.$pos).{.............$objec |
7be00 | 74 58 4d 4c 2d 3e 73 65 74 41 74 74 72 69 62 75 74 65 28 27 73 68 6f 72 74 63 75 74 27 2c 20 27 | tXML->setAttribute('shortcut',.' |
7be20 | 2d 27 2e 73 75 62 73 74 72 28 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 53 68 6f 72 74 63 75 74 28 29 | -'.substr($option->getShortcut() |
7be40 | 2c 20 30 2c 20 24 70 6f 73 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 62 6a 65 63 74 | ,.0,.$pos));.............$object |
7be60 | 58 4d 4c 2d 3e 73 65 74 41 74 74 72 69 62 75 74 65 28 27 73 68 6f 72 74 63 75 74 73 27 2c 20 27 | XML->setAttribute('shortcuts',.' |
7be80 | 2d 27 2e 69 6d 70 6c 6f 64 65 28 27 7c 2d 27 2c 20 65 78 70 6c 6f 64 65 28 27 7c 27 2c 20 24 6f | -'.implode('|-',.explode('|',.$o |
7bea0 | 70 74 69 6f 6e 2d 3e 67 65 74 53 68 6f 72 74 63 75 74 28 29 29 29 29 3b 0a 20 20 20 20 20 20 20 | ption->getShortcut())));........ |
7bec0 | 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 62 6a 65 63 74 58 4d 4c | .}.else.{.............$objectXML |
7bee0 | 2d 3e 73 65 74 41 74 74 72 69 62 75 74 65 28 27 73 68 6f 72 74 63 75 74 27 2c 20 24 6f 70 74 69 | ->setAttribute('shortcut',.$opti |
7bf00 | 6f 6e 2d 3e 67 65 74 53 68 6f 72 74 63 75 74 28 29 20 3f 20 27 2d 27 2e 24 6f 70 74 69 6f 6e 2d | on->getShortcut().?.'-'.$option- |
7bf20 | 3e 67 65 74 53 68 6f 72 74 63 75 74 28 29 20 3a 20 27 27 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a | >getShortcut().:.'');.........}. |
7bf40 | 20 20 20 20 20 20 20 20 24 6f 62 6a 65 63 74 58 4d 4c 2d 3e 73 65 74 41 74 74 72 69 62 75 74 65 | ........$objectXML->setAttribute |
7bf60 | 28 27 61 63 63 65 70 74 5f 76 61 6c 75 65 27 2c 20 24 6f 70 74 69 6f 6e 2d 3e 61 63 63 65 70 74 | ('accept_value',.$option->accept |
7bf80 | 56 61 6c 75 65 28 29 20 3f 20 31 20 3a 20 30 29 3b 0a 20 20 20 20 20 20 20 20 24 6f 62 6a 65 63 | Value().?.1.:.0);.........$objec |
7bfa0 | 74 58 4d 4c 2d 3e 73 65 74 41 74 74 72 69 62 75 74 65 28 27 69 73 5f 76 61 6c 75 65 5f 72 65 71 | tXML->setAttribute('is_value_req |
7bfc0 | 75 69 72 65 64 27 2c 20 24 6f 70 74 69 6f 6e 2d 3e 69 73 56 61 6c 75 65 52 65 71 75 69 72 65 64 | uired',.$option->isValueRequired |
7bfe0 | 28 29 20 3f 20 31 20 3a 20 30 29 3b 0a 20 20 20 20 20 20 20 20 24 6f 62 6a 65 63 74 58 4d 4c 2d | ().?.1.:.0);.........$objectXML- |
7c000 | 3e 73 65 74 41 74 74 72 69 62 75 74 65 28 27 69 73 5f 6d 75 6c 74 69 70 6c 65 27 2c 20 24 6f 70 | >setAttribute('is_multiple',.$op |
7c020 | 74 69 6f 6e 2d 3e 69 73 41 72 72 61 79 28 29 20 3f 20 31 20 3a 20 30 29 3b 0a 20 20 20 20 20 20 | tion->isArray().?.1.:.0);....... |
7c040 | 20 20 24 6f 62 6a 65 63 74 58 4d 4c 2d 3e 61 70 70 65 6e 64 43 68 69 6c 64 28 24 64 65 73 63 72 | ..$objectXML->appendChild($descr |
7c060 | 69 70 74 69 6f 6e 58 4d 4c 20 3d 20 24 64 6f 6d 2d 3e 63 72 65 61 74 65 45 6c 65 6d 65 6e 74 28 | iptionXML.=.$dom->createElement( |
7c080 | 27 64 65 73 63 72 69 70 74 69 6f 6e 27 29 29 3b 0a 20 20 20 20 20 20 20 20 24 64 65 73 63 72 69 | 'description'));.........$descri |
7c0a0 | 70 74 69 6f 6e 58 4d 4c 2d 3e 61 70 70 65 6e 64 43 68 69 6c 64 28 24 64 6f 6d 2d 3e 63 72 65 61 | ptionXML->appendChild($dom->crea |
7c0c0 | 74 65 54 65 78 74 4e 6f 64 65 28 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 44 65 73 63 72 69 70 74 69 | teTextNode($option->getDescripti |
7c0e0 | 6f 6e 28 29 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 6f 70 74 69 6f 6e 2d 3e 61 63 | on()));..........if.($option->ac |
7c100 | 63 65 70 74 56 61 6c 75 65 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 64 65 66 61 | ceptValue()).{.............$defa |
7c120 | 75 6c 74 73 20 3d 20 69 73 5f 61 72 72 61 79 28 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 44 65 66 61 | ults.=.is_array($option->getDefa |
7c140 | 75 6c 74 28 29 29 20 3f 20 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 44 65 66 61 75 6c 74 28 29 20 3a | ult()).?.$option->getDefault().: |
7c160 | 20 28 69 73 5f 62 6f 6f 6c 28 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 44 65 66 61 75 6c 74 28 29 29 | .(is_bool($option->getDefault()) |
7c180 | 20 3f 20 61 72 72 61 79 28 76 61 72 5f 65 78 70 6f 72 74 28 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 | .?.array(var_export($option->get |
7c1a0 | 44 65 66 61 75 6c 74 28 29 2c 20 74 72 75 65 29 29 20 3a 20 28 24 6f 70 74 69 6f 6e 2d 3e 67 65 | Default(),.true)).:.($option->ge |
7c1c0 | 74 44 65 66 61 75 6c 74 28 29 20 3f 20 61 72 72 61 79 28 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 44 | tDefault().?.array($option->getD |
7c1e0 | 65 66 61 75 6c 74 28 29 29 20 3a 20 61 72 72 61 79 28 29 29 29 3b 0a 20 20 20 20 20 20 20 20 20 | efault()).:.array()));.......... |
7c200 | 20 20 20 24 6f 62 6a 65 63 74 58 4d 4c 2d 3e 61 70 70 65 6e 64 43 68 69 6c 64 28 24 64 65 66 61 | ...$objectXML->appendChild($defa |
7c220 | 75 6c 74 73 58 4d 4c 20 3d 20 24 64 6f 6d 2d 3e 63 72 65 61 74 65 45 6c 65 6d 65 6e 74 28 27 64 | ultsXML.=.$dom->createElement('d |
7c240 | 65 66 61 75 6c 74 73 27 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 21 65 6d | efaults'));..............if.(!em |
7c260 | 70 74 79 28 24 64 65 66 61 75 6c 74 73 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | pty($defaults)).{............... |
7c280 | 20 20 66 6f 72 65 61 63 68 20 28 24 64 65 66 61 75 6c 74 73 20 61 73 20 24 64 65 66 61 75 6c 74 | ..foreach.($defaults.as.$default |
7c2a0 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 64 65 66 61 75 6c 74 | ).{.....................$default |
7c2c0 | 73 58 4d 4c 2d 3e 61 70 70 65 6e 64 43 68 69 6c 64 28 24 64 65 66 61 75 6c 74 58 4d 4c 20 3d 20 | sXML->appendChild($defaultXML.=. |
7c2e0 | 24 64 6f 6d 2d 3e 63 72 65 61 74 65 45 6c 65 6d 65 6e 74 28 27 64 65 66 61 75 6c 74 27 29 29 3b | $dom->createElement('default')); |
7c300 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 64 65 66 61 75 6c 74 58 4d 4c | .....................$defaultXML |
7c320 | 2d 3e 61 70 70 65 6e 64 43 68 69 6c 64 28 24 64 6f 6d 2d 3e 63 72 65 61 74 65 54 65 78 74 4e 6f | ->appendChild($dom->createTextNo |
7c340 | 64 65 28 24 64 65 66 61 75 6c 74 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d | de($default));.................} |
7c360 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 | .............}.........}........ |
7c380 | 20 20 72 65 74 75 72 6e 20 24 64 6f 6d 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a | ..return.$dom;.....}.}.<?php../* |
7c3a0 | 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d | ..*.This.file.is.part.of.the.Sym |
7c3c0 | 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 | fony.package...*..*.(c).Fabien.P |
7c3e0 | 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a | otencier.<fabien@symfony.com>..* |
7c400 | 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c | ..*.For.the.full.copyright.and.l |
7c420 | 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 | icense.information,.please.view. |
7c440 | 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 | the.LICENSE..*.file.that.was.dis |
7c460 | 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a | tributed.with.this.source.code.. |
7c480 | 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 | .*/..namespace.Symfony\Component |
7c4a0 | 5c 43 6f 6e 73 6f 6c 65 5c 44 65 73 63 72 69 70 74 6f 72 3b 0a 0a 75 73 65 20 53 79 6d 66 6f 6e | \Console\Descriptor;..use.Symfon |
7c4c0 | 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 4f 75 74 70 75 74 5c 4f 75 74 70 75 | y\Component\Console\Output\Outpu |
7c4e0 | 74 49 6e 74 65 72 66 61 63 65 3b 0a 0a 2f 2a 2a 0a 20 2a 20 44 65 73 63 72 69 70 74 6f 72 20 69 | tInterface;../**..*.Descriptor.i |
7c500 | 6e 74 65 72 66 61 63 65 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 4a 65 61 6e 2d 46 72 61 | nterface...*..*.@author.Jean-Fra |
7c520 | 6e c3 a7 6f 69 73 20 53 69 6d 6f 6e 20 3c 63 6f 6e 74 61 63 74 40 6a 66 73 69 6d 6f 6e 2e 66 72 | n..ois.Simon.<contact@jfsimon.fr |
7c540 | 3e 0a 20 2a 2f 0a 69 6e 74 65 72 66 61 63 65 20 44 65 73 63 72 69 70 74 6f 72 49 6e 74 65 72 66 | >..*/.interface.DescriptorInterf |
7c560 | 61 63 65 0a 7b 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 44 65 73 63 72 69 62 65 73 20 61 | ace.{...../**......*.Describes.a |
7c580 | 6e 20 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 20 69 6e 73 74 61 6e 63 65 2e 0a 20 20 20 20 20 2a | n.InputArgument.instance.......* |
7c5a0 | 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 | ......*.@param.OutputInterface.$ |
7c5c0 | 6f 75 74 70 75 74 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 6f 62 6a 65 63 74 20 20 20 20 20 | output......*.@param.object..... |
7c5e0 | 20 20 20 20 20 24 6f 62 6a 65 63 74 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 | .....$object......*.@param.array |
7c600 | 20 20 20 20 20 20 20 20 20 20 20 24 6f 70 74 69 6f 6e 73 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 | ...........$options......*/..... |
7c620 | 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 64 65 73 63 72 69 62 65 28 4f 75 74 70 75 74 49 | public.function.describe(OutputI |
7c640 | 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 2c 20 24 6f 62 6a 65 63 74 2c 20 61 72 72 61 79 | nterface.$output,.$object,.array |
7c660 | 20 24 6f 70 74 69 6f 6e 73 20 3d 20 61 72 72 61 79 28 29 29 3b 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f | .$options.=.array());.}.<?php../ |
7c680 | 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 | *..*.This.file.is.part.of.the.Sy |
7c6a0 | 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 | mfony.package...*..*.(c).Fabien. |
7c6c0 | 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 | Potencier.<fabien@symfony.com>.. |
7c6e0 | 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 | *..*.For.the.full.copyright.and. |
7c700 | 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 | license.information,.please.view |
7c720 | 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 | .the.LICENSE..*.file.that.was.di |
7c740 | 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e | stributed.with.this.source.code. |
7c760 | 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e | ..*/..namespace.Symfony\Componen |
7c780 | 74 5c 43 6f 6e 73 6f 6c 65 5c 44 65 73 63 72 69 70 74 6f 72 3b 0a 0a 75 73 65 20 53 79 6d 66 6f | t\Console\Descriptor;..use.Symfo |
7c7a0 | 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 41 70 70 6c 69 63 61 74 69 6f 6e | ny\Component\Console\Application |
7c7c0 | 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c | ;.use.Symfony\Component\Console\ |
7c7e0 | 43 6f 6d 6d 61 6e 64 5c 43 6f 6d 6d 61 6e 64 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d | Command\Command;.use.Symfony\Com |
7c800 | 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 78 63 65 70 74 69 6f 6e 5c 43 6f 6d 6d 61 6e 64 | ponent\Console\Exception\Command |
7c820 | 4e 6f 74 46 6f 75 6e 64 45 78 63 65 70 74 69 6f 6e 3b 0a 0a 2f 2a 2a 0a 20 2a 20 40 61 75 74 68 | NotFoundException;../**..*.@auth |
7c840 | 6f 72 20 4a 65 61 6e 2d 46 72 61 6e c3 a7 6f 69 73 20 53 69 6d 6f 6e 20 3c 6a 65 61 6e 66 72 61 | or.Jean-Fran..ois.Simon.<jeanfra |
7c860 | 6e 63 6f 69 73 2e 73 69 6d 6f 6e 40 73 65 6e 73 69 6f 6c 61 62 73 2e 63 6f 6d 3e 0a 20 2a 0a 20 | ncois.simon@sensiolabs.com>..*.. |
7c880 | 2a 20 40 69 6e 74 65 72 6e 61 6c 0a 20 2a 2f 0a 63 6c 61 73 73 20 41 70 70 6c 69 63 61 74 69 6f | *.@internal..*/.class.Applicatio |
7c8a0 | 6e 44 65 73 63 72 69 70 74 69 6f 6e 0a 7b 0a 20 20 20 20 63 6f 6e 73 74 20 47 4c 4f 42 41 4c 5f | nDescription.{.....const.GLOBAL_ |
7c8c0 | 4e 41 4d 45 53 50 41 43 45 20 3d 20 27 5f 67 6c 6f 62 61 6c 27 3b 0a 0a 20 20 20 20 2f 2a 2a 0a | NAMESPACE.=.'_global';....../**. |
7c8e0 | 20 20 20 20 20 2a 20 40 76 61 72 20 41 70 70 6c 69 63 61 74 69 6f 6e 0a 20 20 20 20 20 2a 2f 0a | .....*.@var.Application......*/. |
7c900 | 20 20 20 20 70 72 69 76 61 74 65 20 24 61 70 70 6c 69 63 61 74 69 6f 6e 3b 0a 0a 20 20 20 20 2f | ....private.$application;....../ |
7c920 | 2a 2a 0a 20 20 20 20 20 2a 20 40 76 61 72 20 6e 75 6c 6c 7c 73 74 72 69 6e 67 0a 20 20 20 20 20 | **......*.@var.null|string...... |
7c940 | 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 6e 61 6d 65 73 70 61 63 65 3b 0a 0a 20 20 20 20 | */.....private.$namespace;...... |
7c960 | 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 76 61 72 20 61 72 72 61 79 0a 20 20 20 20 20 2a 2f 0a 20 20 | /**......*.@var.array......*/... |
7c980 | 20 20 70 72 69 76 61 74 65 20 24 6e 61 6d 65 73 70 61 63 65 73 3b 0a 0a 20 20 20 20 2f 2a 2a 0a | ..private.$namespaces;....../**. |
7c9a0 | 20 20 20 20 20 2a 20 40 76 61 72 20 43 6f 6d 6d 61 6e 64 5b 5d 0a 20 20 20 20 20 2a 2f 0a 20 20 | .....*.@var.Command[]......*/... |
7c9c0 | 20 20 70 72 69 76 61 74 65 20 24 63 6f 6d 6d 61 6e 64 73 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 | ..private.$commands;....../**... |
7c9e0 | 20 20 20 2a 20 40 76 61 72 20 43 6f 6d 6d 61 6e 64 5b 5d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 | ...*.@var.Command[]......*/..... |
7ca00 | 70 72 69 76 61 74 65 20 24 61 6c 69 61 73 65 73 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 | private.$aliases;....../**...... |
7ca20 | 2a 20 43 6f 6e 73 74 72 75 63 74 6f 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 | *.Constructor.......*......*.@pa |
7ca40 | 72 61 6d 20 41 70 70 6c 69 63 61 74 69 6f 6e 20 24 61 70 70 6c 69 63 61 74 69 6f 6e 0a 20 20 20 | ram.Application.$application.... |
7ca60 | 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 7c 6e 75 6c 6c 20 24 6e 61 6d 65 73 70 61 63 | ..*.@param.string|null.$namespac |
7ca80 | 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f | e......*/.....public.function.__ |
7caa0 | 63 6f 6e 73 74 72 75 63 74 28 41 70 70 6c 69 63 61 74 69 6f 6e 20 24 61 70 70 6c 69 63 61 74 69 | construct(Application.$applicati |
7cac0 | 6f 6e 2c 20 24 6e 61 6d 65 73 70 61 63 65 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 | on,.$namespace.=.null).....{.... |
7cae0 | 20 20 20 20 20 24 74 68 69 73 2d 3e 61 70 70 6c 69 63 61 74 69 6f 6e 20 3d 20 24 61 70 70 6c 69 | .....$this->application.=.$appli |
7cb00 | 63 61 74 69 6f 6e 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6e 61 6d 65 73 70 61 63 65 | cation;.........$this->namespace |
7cb20 | 20 3d 20 24 6e 61 6d 65 73 70 61 63 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 | .=.$namespace;.....}....../**... |
7cb40 | 20 20 20 2a 20 40 72 65 74 75 72 6e 20 61 72 72 61 79 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 | ...*.@return.array......*/.....p |
7cb60 | 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 4e 61 6d 65 73 70 61 63 65 73 28 29 0a 20 | ublic.function.getNamespaces().. |
7cb80 | 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 74 68 69 73 2d | ...{.........if.(null.===.$this- |
7cba0 | 3e 6e 61 6d 65 73 70 61 63 65 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 | >namespaces).{.............$this |
7cbc0 | 2d 3e 69 6e 73 70 65 63 74 41 70 70 6c 69 63 61 74 69 6f 6e 28 29 3b 0a 20 20 20 20 20 20 20 20 | ->inspectApplication();......... |
7cbe0 | 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 6e 61 6d 65 73 70 61 | }..........return.$this->namespa |
7cc00 | 63 65 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 | ces;.....}....../**......*.@retu |
7cc20 | 72 6e 20 43 6f 6d 6d 61 6e 64 5b 5d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 | rn.Command[]......*/.....public. |
7cc40 | 66 75 6e 63 74 69 6f 6e 20 67 65 74 43 6f 6d 6d 61 6e 64 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 | function.getCommands().....{.... |
7cc60 | 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 74 68 69 73 2d 3e 63 6f 6d 6d 61 6e 64 | .....if.(null.===.$this->command |
7cc80 | 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 69 6e 73 70 65 63 74 41 | s).{.............$this->inspectA |
7cca0 | 70 70 6c 69 63 61 74 69 6f 6e 28 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 | pplication();.........}......... |
7ccc0 | 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 63 6f 6d 6d 61 6e 64 73 3b 0a 20 20 20 20 7d 0a 0a | .return.$this->commands;.....}.. |
7cce0 | 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6e 61 | ..../**......*.@param.string.$na |
7cd00 | 6d 65 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 43 6f 6d 6d 61 6e 64 | me......*......*.@return.Command |
7cd20 | 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 20 43 6f 6d 6d 61 6e 64 4e 6f | ......*......*.@throws.CommandNo |
7cd40 | 74 46 6f 75 6e 64 45 78 63 65 70 74 69 6f 6e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c | tFoundException......*/.....publ |
7cd60 | 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 43 6f 6d 6d 61 6e 64 28 24 6e 61 6d 65 29 0a 20 20 | ic.function.getCommand($name)... |
7cd80 | 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 69 73 73 65 74 28 24 74 68 69 73 2d 3e 63 6f | ..{.........if.(!isset($this->co |
7cda0 | 6d 6d 61 6e 64 73 5b 24 6e 61 6d 65 5d 29 20 26 26 20 21 69 73 73 65 74 28 24 74 68 69 73 2d 3e | mmands[$name]).&&.!isset($this-> |
7cdc0 | 61 6c 69 61 73 65 73 5b 24 6e 61 6d 65 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 | aliases[$name])).{.............t |
7cde0 | 68 72 6f 77 20 6e 65 77 20 43 6f 6d 6d 61 6e 64 4e 6f 74 46 6f 75 6e 64 45 78 63 65 70 74 69 6f | hrow.new.CommandNotFoundExceptio |
7ce00 | 6e 28 73 70 72 69 6e 74 66 28 27 43 6f 6d 6d 61 6e 64 20 25 73 20 64 6f 65 73 20 6e 6f 74 20 65 | n(sprintf('Command.%s.does.not.e |
7ce20 | 78 69 73 74 2e 27 2c 20 24 6e 61 6d 65 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 | xist.',.$name));.........}...... |
7ce40 | 20 20 20 20 72 65 74 75 72 6e 20 69 73 73 65 74 28 24 74 68 69 73 2d 3e 63 6f 6d 6d 61 6e 64 73 | ....return.isset($this->commands |
7ce60 | 5b 24 6e 61 6d 65 5d 29 20 3f 20 24 74 68 69 73 2d 3e 63 6f 6d 6d 61 6e 64 73 5b 24 6e 61 6d 65 | [$name]).?.$this->commands[$name |
7ce80 | 5d 20 3a 20 24 74 68 69 73 2d 3e 61 6c 69 61 73 65 73 5b 24 6e 61 6d 65 5d 3b 0a 20 20 20 20 7d | ].:.$this->aliases[$name];.....} |
7cea0 | 0a 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 69 6e 73 70 65 63 74 41 70 | ......private.function.inspectAp |
7cec0 | 70 6c 69 63 61 74 69 6f 6e 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d | plication().....{.........$this- |
7cee0 | 3e 63 6f 6d 6d 61 6e 64 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 | >commands.=.array();.........$th |
7cf00 | 69 73 2d 3e 6e 61 6d 65 73 70 61 63 65 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 0a 20 20 20 20 20 | is->namespaces.=.array();....... |
7cf20 | 20 20 20 24 61 6c 6c 20 3d 20 24 74 68 69 73 2d 3e 61 70 70 6c 69 63 61 74 69 6f 6e 2d 3e 61 6c | ...$all.=.$this->application->al |
7cf40 | 6c 28 24 74 68 69 73 2d 3e 6e 61 6d 65 73 70 61 63 65 20 3f 20 24 74 68 69 73 2d 3e 61 70 70 6c | l($this->namespace.?.$this->appl |
7cf60 | 69 63 61 74 69 6f 6e 2d 3e 66 69 6e 64 4e 61 6d 65 73 70 61 63 65 28 24 74 68 69 73 2d 3e 6e 61 | ication->findNamespace($this->na |
7cf80 | 6d 65 73 70 61 63 65 29 20 3a 20 6e 75 6c 6c 29 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 | mespace).:.null);.........foreac |
7cfa0 | 68 20 28 24 74 68 69 73 2d 3e 73 6f 72 74 43 6f 6d 6d 61 6e 64 73 28 24 61 6c 6c 29 20 61 73 20 | h.($this->sortCommands($all).as. |
7cfc0 | 24 6e 61 6d 65 73 70 61 63 65 20 3d 3e 20 24 63 6f 6d 6d 61 6e 64 73 29 20 7b 0a 20 20 20 20 20 | $namespace.=>.$commands).{...... |
7cfe0 | 20 20 20 20 20 20 20 24 6e 61 6d 65 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 0a 20 20 20 20 20 20 | .......$names.=.array();........ |
7d000 | 20 20 20 20 20 20 2f 2a 2a 20 40 76 61 72 20 43 6f 6d 6d 61 6e 64 20 24 63 6f 6d 6d 61 6e 64 20 | ....../**.@var.Command.$command. |
7d020 | 2a 2f 0a 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 63 6f 6d 6d 61 6e 64 | */.............foreach.($command |
7d040 | 73 20 61 73 20 24 6e 61 6d 65 20 3d 3e 20 24 63 6f 6d 6d 61 6e 64 29 20 7b 0a 20 20 20 20 20 20 | s.as.$name.=>.$command).{....... |
7d060 | 20 20 20 20 20 20 20 20 20 20 69 66 20 28 21 24 63 6f 6d 6d 61 6e 64 2d 3e 67 65 74 4e 61 6d 65 | ..........if.(!$command->getName |
7d080 | 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 63 6f 6e 74 69 6e | ()).{.....................contin |
7d0a0 | 75 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 | ue;.................}........... |
7d0c0 | 20 20 20 20 20 20 20 69 66 20 28 24 63 6f 6d 6d 61 6e 64 2d 3e 67 65 74 4e 61 6d 65 28 29 20 3d | .......if.($command->getName().= |
7d0e0 | 3d 3d 20 24 6e 61 6d 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ==.$name).{..................... |
7d100 | 24 74 68 69 73 2d 3e 63 6f 6d 6d 61 6e 64 73 5b 24 6e 61 6d 65 5d 20 3d 20 24 63 6f 6d 6d 61 6e | $this->commands[$name].=.$comman |
7d120 | 64 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 | d;.................}.else.{..... |
7d140 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 61 6c 69 61 73 65 73 5b 24 | ................$this->aliases[$ |
7d160 | 6e 61 6d 65 5d 20 3d 20 24 63 6f 6d 6d 61 6e 64 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | name].=.$command;............... |
7d180 | 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6e 61 6d 65 73 5b 5d 20 3d 20 | ..}..................$names[].=. |
7d1a0 | 24 6e 61 6d 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 | $name;.............}............ |
7d1c0 | 20 20 24 74 68 69 73 2d 3e 6e 61 6d 65 73 70 61 63 65 73 5b 24 6e 61 6d 65 73 70 61 63 65 5d 20 | ..$this->namespaces[$namespace]. |
7d1e0 | 3d 20 61 72 72 61 79 28 27 69 64 27 20 3d 3e 20 24 6e 61 6d 65 73 70 61 63 65 2c 20 27 63 6f 6d | =.array('id'.=>.$namespace,.'com |
7d200 | 6d 61 6e 64 73 27 20 3d 3e 20 24 6e 61 6d 65 73 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 | mands'.=>.$names);.........}.... |
7d220 | 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 | .}....../**......*.@param.array. |
7d240 | 24 63 6f 6d 6d 61 6e 64 73 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 | $commands......*......*.@return. |
7d260 | 61 72 72 61 79 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 | array......*/.....private.functi |
7d280 | 6f 6e 20 73 6f 72 74 43 6f 6d 6d 61 6e 64 73 28 61 72 72 61 79 20 24 63 6f 6d 6d 61 6e 64 73 29 | on.sortCommands(array.$commands) |
7d2a0 | 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 6e 61 6d 65 73 70 61 63 65 64 43 6f 6d 6d 61 6e | .....{.........$namespacedComman |
7d2c0 | 64 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 24 67 6c 6f 62 61 6c 43 6f 6d | ds.=.array();.........$globalCom |
7d2e0 | 6d 61 6e 64 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 | mands.=.array();.........foreach |
7d300 | 20 28 24 63 6f 6d 6d 61 6e 64 73 20 61 73 20 24 6e 61 6d 65 20 3d 3e 20 24 63 6f 6d 6d 61 6e 64 | .($commands.as.$name.=>.$command |
7d320 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6b 65 79 20 3d 20 24 74 68 69 73 2d 3e 61 70 | ).{.............$key.=.$this->ap |
7d340 | 70 6c 69 63 61 74 69 6f 6e 2d 3e 65 78 74 72 61 63 74 4e 61 6d 65 73 70 61 63 65 28 24 6e 61 6d | plication->extractNamespace($nam |
7d360 | 65 2c 20 31 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 21 24 6b 65 79 29 20 7b 0a | e,.1);.............if.(!$key).{. |
7d380 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 67 6c 6f 62 61 6c 43 6f 6d 6d 61 6e 64 73 5b | ................$globalCommands[ |
7d3a0 | 27 5f 67 6c 6f 62 61 6c 27 5d 5b 24 6e 61 6d 65 5d 20 3d 20 24 63 6f 6d 6d 61 6e 64 3b 0a 20 20 | '_global'][$name].=.$command;... |
7d3c0 | 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | ..........}.else.{.............. |
7d3e0 | 20 20 20 24 6e 61 6d 65 73 70 61 63 65 64 43 6f 6d 6d 61 6e 64 73 5b 24 6b 65 79 5d 5b 24 6e 61 | ...$namespacedCommands[$key][$na |
7d400 | 6d 65 5d 20 3d 20 24 63 6f 6d 6d 61 6e 64 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 | me].=.$command;.............}... |
7d420 | 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 6b 73 6f 72 74 28 24 6e 61 6d 65 73 70 61 63 65 | ......}.........ksort($namespace |
7d440 | 64 43 6f 6d 6d 61 6e 64 73 29 3b 0a 20 20 20 20 20 20 20 20 24 6e 61 6d 65 73 70 61 63 65 64 43 | dCommands);.........$namespacedC |
7d460 | 6f 6d 6d 61 6e 64 73 20 3d 20 61 72 72 61 79 5f 6d 65 72 67 65 28 24 67 6c 6f 62 61 6c 43 6f 6d | ommands.=.array_merge($globalCom |
7d480 | 6d 61 6e 64 73 2c 20 24 6e 61 6d 65 73 70 61 63 65 64 43 6f 6d 6d 61 6e 64 73 29 3b 0a 0a 20 20 | mands,.$namespacedCommands);.... |
7d4a0 | 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 6e 61 6d 65 73 70 61 63 65 64 43 6f 6d 6d 61 6e | ......foreach.($namespacedComman |
7d4c0 | 64 73 20 61 73 20 26 24 63 6f 6d 6d 61 6e 64 73 53 65 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | ds.as.&$commandsSet).{.......... |
7d4e0 | 20 20 20 6b 73 6f 72 74 28 24 63 6f 6d 6d 61 6e 64 73 53 65 74 29 3b 0a 20 20 20 20 20 20 20 20 | ...ksort($commandsSet);......... |
7d500 | 7d 0a 20 20 20 20 20 20 20 20 2f 2f 20 75 6e 73 65 74 20 72 65 66 65 72 65 6e 63 65 20 74 6f 20 | }.........//.unset.reference.to. |
7d520 | 6b 65 65 70 20 73 63 6f 70 65 20 63 6c 65 61 72 0a 20 20 20 20 20 20 20 20 75 6e 73 65 74 28 24 | keep.scope.clear.........unset($ |
7d540 | 63 6f 6d 6d 61 6e 64 73 53 65 74 29 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 6e | commandsSet);..........return.$n |
7d560 | 61 6d 65 73 70 61 63 65 64 43 6f 6d 6d 61 6e 64 73 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 | amespacedCommands;.....}.}.<?php |
7d580 | 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 | ../*..*.This.file.is.part.of.the |
7d5a0 | 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 | .Symfony.package...*..*.(c).Fabi |
7d5c0 | 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d | en.Potencier.<fabien@symfony.com |
7d5e0 | 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 | >..*..*.For.the.full.copyright.a |
7d600 | 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 | nd.license.information,.please.v |
7d620 | 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 | iew.the.LICENSE..*.file.that.was |
7d640 | 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f | .distributed.with.this.source.co |
7d660 | 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f | de...*/..namespace.Symfony\Compo |
7d680 | 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 44 65 73 63 72 69 70 74 6f 72 3b 0a 0a 75 73 65 20 53 79 | nent\Console\Descriptor;..use.Sy |
7d6a0 | 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 41 70 70 6c 69 63 61 74 | mfony\Component\Console\Applicat |
7d6c0 | 69 6f 6e 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f | ion;.use.Symfony\Component\Conso |
7d6e0 | 6c 65 5c 43 6f 6d 6d 61 6e 64 5c 43 6f 6d 6d 61 6e 64 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c | le\Command\Command;.use.Symfony\ |
7d700 | 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 5c 49 6e 70 75 74 41 72 67 | Component\Console\Input\InputArg |
7d720 | 75 6d 65 6e 74 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e | ument;.use.Symfony\Component\Con |
7d740 | 73 6f 6c 65 5c 49 6e 70 75 74 5c 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 3b 0a 75 73 65 20 | sole\Input\InputDefinition;.use. |
7d760 | 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 5c | Symfony\Component\Console\Input\ |
7d780 | 49 6e 70 75 74 4f 70 74 69 6f 6e 3b 0a 0a 2f 2a 2a 0a 20 2a 20 4d 61 72 6b 64 6f 77 6e 20 64 65 | InputOption;../**..*.Markdown.de |
7d7a0 | 73 63 72 69 70 74 6f 72 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 4a 65 61 6e 2d 46 72 61 | scriptor...*..*.@author.Jean-Fra |
7d7c0 | 6e c3 a7 6f 69 73 20 53 69 6d 6f 6e 20 3c 63 6f 6e 74 61 63 74 40 6a 66 73 69 6d 6f 6e 2e 66 72 | n..ois.Simon.<contact@jfsimon.fr |
7d7e0 | 3e 0a 20 2a 0a 20 2a 20 40 69 6e 74 65 72 6e 61 6c 0a 20 2a 2f 0a 63 6c 61 73 73 20 4d 61 72 6b | >..*..*.@internal..*/.class.Mark |
7d800 | 64 6f 77 6e 44 65 73 63 72 69 70 74 6f 72 20 65 78 74 65 6e 64 73 20 44 65 73 63 72 69 70 74 6f | downDescriptor.extends.Descripto |
7d820 | 72 0a 7b 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d | r.{...../**......*.{@inheritdoc} |
7d840 | 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 | ......*/.....protected.function. |
7d860 | 64 65 73 63 72 69 62 65 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 28 49 6e 70 75 74 41 72 67 75 6d | describeInputArgument(InputArgum |
7d880 | 65 6e 74 20 24 61 72 67 75 6d 65 6e 74 2c 20 61 72 72 61 79 20 24 6f 70 74 69 6f 6e 73 20 3d 20 | ent.$argument,.array.$options.=. |
7d8a0 | 61 72 72 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 | array()).....{.........$this->wr |
7d8c0 | 69 74 65 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 2a 2a 27 2e 24 61 72 67 75 6d 65 6e 74 2d | ite(.............'**'.$argument- |
7d8e0 | 3e 67 65 74 4e 61 6d 65 28 29 2e 27 3a 2a 2a 27 2e 22 5c 6e 5c 6e 22 0a 20 20 20 20 20 20 20 20 | >getName().':**'."\n\n"......... |
7d900 | 20 20 20 20 2e 27 2a 20 4e 61 6d 65 3a 20 27 2e 28 24 61 72 67 75 6d 65 6e 74 2d 3e 67 65 74 4e | .....'*.Name:.'.($argument->getN |
7d920 | 61 6d 65 28 29 20 3f 3a 20 27 3c 6e 6f 6e 65 3e 27 29 2e 22 5c 6e 22 0a 20 20 20 20 20 20 20 20 | ame().?:.'<none>')."\n"......... |
7d940 | 20 20 20 20 2e 27 2a 20 49 73 20 72 65 71 75 69 72 65 64 3a 20 27 2e 28 24 61 72 67 75 6d 65 6e | .....'*.Is.required:.'.($argumen |
7d960 | 74 2d 3e 69 73 52 65 71 75 69 72 65 64 28 29 20 3f 20 27 79 65 73 27 20 3a 20 27 6e 6f 27 29 2e | t->isRequired().?.'yes'.:.'no'). |
7d980 | 22 5c 6e 22 0a 20 20 20 20 20 20 20 20 20 20 20 20 2e 27 2a 20 49 73 20 61 72 72 61 79 3a 20 27 | "\n"..............'*.Is.array:.' |
7d9a0 | 2e 28 24 61 72 67 75 6d 65 6e 74 2d 3e 69 73 41 72 72 61 79 28 29 20 3f 20 27 79 65 73 27 20 3a | .($argument->isArray().?.'yes'.: |
7d9c0 | 20 27 6e 6f 27 29 2e 22 5c 6e 22 0a 20 20 20 20 20 20 20 20 20 20 20 20 2e 27 2a 20 44 65 73 63 | .'no')."\n"..............'*.Desc |
7d9e0 | 72 69 70 74 69 6f 6e 3a 20 27 2e 70 72 65 67 5f 72 65 70 6c 61 63 65 28 27 2f 5c 73 2a 5b 5c 72 | ription:.'.preg_replace('/\s*[\r |
7da00 | 5c 6e 5d 5c 73 2a 2f 27 2c 20 22 5c 6e 20 20 22 2c 20 24 61 72 67 75 6d 65 6e 74 2d 3e 67 65 74 | \n]\s*/',."\n..",.$argument->get |
7da20 | 44 65 73 63 72 69 70 74 69 6f 6e 28 29 20 3f 3a 20 27 3c 6e 6f 6e 65 3e 27 29 2e 22 5c 6e 22 0a | Description().?:.'<none>')."\n". |
7da40 | 20 20 20 20 20 20 20 20 20 20 20 20 2e 27 2a 20 44 65 66 61 75 6c 74 3a 20 60 27 2e 73 74 72 5f | .............'*.Default:.`'.str_ |
7da60 | 72 65 70 6c 61 63 65 28 22 5c 6e 22 2c 20 27 27 2c 20 76 61 72 5f 65 78 70 6f 72 74 28 24 61 72 | replace("\n",.'',.var_export($ar |
7da80 | 67 75 6d 65 6e 74 2d 3e 67 65 74 44 65 66 61 75 6c 74 28 29 2c 20 74 72 75 65 29 29 2e 27 60 27 | gument->getDefault(),.true)).'`' |
7daa0 | 0a 20 20 20 20 20 20 20 20 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 | .........);.....}....../**...... |
7dac0 | 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 6f 74 | *.{@inheritdoc}......*/.....prot |
7dae0 | 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 64 65 73 63 72 69 62 65 49 6e 70 75 74 4f 70 74 69 | ected.function.describeInputOpti |
7db00 | 6f 6e 28 49 6e 70 75 74 4f 70 74 69 6f 6e 20 24 6f 70 74 69 6f 6e 2c 20 61 72 72 61 79 20 24 6f | on(InputOption.$option,.array.$o |
7db20 | 70 74 69 6f 6e 73 20 3d 20 61 72 72 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | ptions.=.array()).....{......... |
7db40 | 24 74 68 69 73 2d 3e 77 72 69 74 65 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 2a 2a 27 2e 24 | $this->write(.............'**'.$ |
7db60 | 6f 70 74 69 6f 6e 2d 3e 67 65 74 4e 61 6d 65 28 29 2e 27 3a 2a 2a 27 2e 22 5c 6e 5c 6e 22 0a 20 | option->getName().':**'."\n\n".. |
7db80 | 20 20 20 20 20 20 20 20 20 20 20 2e 27 2a 20 4e 61 6d 65 3a 20 60 2d 2d 27 2e 24 6f 70 74 69 6f | ............'*.Name:.`--'.$optio |
7dba0 | 6e 2d 3e 67 65 74 4e 61 6d 65 28 29 2e 27 60 27 2e 22 5c 6e 22 0a 20 20 20 20 20 20 20 20 20 20 | n->getName().'`'."\n"........... |
7dbc0 | 20 20 2e 27 2a 20 53 68 6f 72 74 63 75 74 3a 20 27 2e 28 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 53 | ...'*.Shortcut:.'.($option->getS |
7dbe0 | 68 6f 72 74 63 75 74 28 29 20 3f 20 27 60 2d 27 2e 69 6d 70 6c 6f 64 65 28 27 7c 2d 27 2c 20 65 | hortcut().?.'`-'.implode('|-',.e |
7dc00 | 78 70 6c 6f 64 65 28 27 7c 27 2c 20 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 53 68 6f 72 74 63 75 74 | xplode('|',.$option->getShortcut |
7dc20 | 28 29 29 29 2e 27 60 27 20 3a 20 27 3c 6e 6f 6e 65 3e 27 29 2e 22 5c 6e 22 0a 20 20 20 20 20 20 | ())).'`'.:.'<none>')."\n"....... |
7dc40 | 20 20 20 20 20 20 2e 27 2a 20 41 63 63 65 70 74 20 76 61 6c 75 65 3a 20 27 2e 28 24 6f 70 74 69 | .......'*.Accept.value:.'.($opti |
7dc60 | 6f 6e 2d 3e 61 63 63 65 70 74 56 61 6c 75 65 28 29 20 3f 20 27 79 65 73 27 20 3a 20 27 6e 6f 27 | on->acceptValue().?.'yes'.:.'no' |
7dc80 | 29 2e 22 5c 6e 22 0a 20 20 20 20 20 20 20 20 20 20 20 20 2e 27 2a 20 49 73 20 76 61 6c 75 65 20 | )."\n"..............'*.Is.value. |
7dca0 | 72 65 71 75 69 72 65 64 3a 20 27 2e 28 24 6f 70 74 69 6f 6e 2d 3e 69 73 56 61 6c 75 65 52 65 71 | required:.'.($option->isValueReq |
7dcc0 | 75 69 72 65 64 28 29 20 3f 20 27 79 65 73 27 20 3a 20 27 6e 6f 27 29 2e 22 5c 6e 22 0a 20 20 20 | uired().?.'yes'.:.'no')."\n".... |
7dce0 | 20 20 20 20 20 20 20 20 20 2e 27 2a 20 49 73 20 6d 75 6c 74 69 70 6c 65 3a 20 27 2e 28 24 6f 70 | ..........'*.Is.multiple:.'.($op |
7dd00 | 74 69 6f 6e 2d 3e 69 73 41 72 72 61 79 28 29 20 3f 20 27 79 65 73 27 20 3a 20 27 6e 6f 27 29 2e | tion->isArray().?.'yes'.:.'no'). |
7dd20 | 22 5c 6e 22 0a 20 20 20 20 20 20 20 20 20 20 20 20 2e 27 2a 20 44 65 73 63 72 69 70 74 69 6f 6e | "\n"..............'*.Description |
7dd40 | 3a 20 27 2e 70 72 65 67 5f 72 65 70 6c 61 63 65 28 27 2f 5c 73 2a 5b 5c 72 5c 6e 5d 5c 73 2a 2f | :.'.preg_replace('/\s*[\r\n]\s*/ |
7dd60 | 27 2c 20 22 5c 6e 20 20 22 2c 20 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 44 65 73 63 72 69 70 74 69 | ',."\n..",.$option->getDescripti |
7dd80 | 6f 6e 28 29 20 3f 3a 20 27 3c 6e 6f 6e 65 3e 27 29 2e 22 5c 6e 22 0a 20 20 20 20 20 20 20 20 20 | on().?:.'<none>')."\n".......... |
7dda0 | 20 20 20 2e 27 2a 20 44 65 66 61 75 6c 74 3a 20 60 27 2e 73 74 72 5f 72 65 70 6c 61 63 65 28 22 | ....'*.Default:.`'.str_replace(" |
7ddc0 | 5c 6e 22 2c 20 27 27 2c 20 76 61 72 5f 65 78 70 6f 72 74 28 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 | \n",.'',.var_export($option->get |
7dde0 | 44 65 66 61 75 6c 74 28 29 2c 20 74 72 75 65 29 29 2e 27 60 27 0a 20 20 20 20 20 20 20 20 29 3b | Default(),.true)).'`'.........); |
7de00 | 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 | .....}....../**......*.{@inherit |
7de20 | 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 | doc}......*/.....protected.funct |
7de40 | 69 6f 6e 20 64 65 73 63 72 69 62 65 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 28 49 6e 70 75 | ion.describeInputDefinition(Inpu |
7de60 | 74 44 65 66 69 6e 69 74 69 6f 6e 20 24 64 65 66 69 6e 69 74 69 6f 6e 2c 20 61 72 72 61 79 20 24 | tDefinition.$definition,.array.$ |
7de80 | 6f 70 74 69 6f 6e 73 20 3d 20 61 72 72 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 | options.=.array()).....{........ |
7dea0 | 20 69 66 20 28 24 73 68 6f 77 41 72 67 75 6d 65 6e 74 73 20 3d 20 63 6f 75 6e 74 28 24 64 65 66 | .if.($showArguments.=.count($def |
7dec0 | 69 6e 69 74 69 6f 6e 2d 3e 67 65 74 41 72 67 75 6d 65 6e 74 73 28 29 29 20 3e 20 30 29 20 7b 0a | inition->getArguments()).>.0).{. |
7dee0 | 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 28 27 23 23 23 20 41 72 | ............$this->write('###.Ar |
7df00 | 67 75 6d 65 6e 74 73 3a 27 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 | guments:');.............foreach. |
7df20 | 28 24 64 65 66 69 6e 69 74 69 6f 6e 2d 3e 67 65 74 41 72 67 75 6d 65 6e 74 73 28 29 20 61 73 20 | ($definition->getArguments().as. |
7df40 | 24 61 72 67 75 6d 65 6e 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 | $argument).{.................$th |
7df60 | 69 73 2d 3e 77 72 69 74 65 28 22 5c 6e 5c 6e 22 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | is->write("\n\n");.............. |
7df80 | 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 28 24 74 68 69 73 2d 3e 64 65 73 63 72 69 62 65 49 | ...$this->write($this->describeI |
7dfa0 | 6e 70 75 74 41 72 67 75 6d 65 6e 74 28 24 61 72 67 75 6d 65 6e 74 29 29 3b 0a 20 20 20 20 20 20 | nputArgument($argument));....... |
7dfc0 | 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 63 | ......}.........}..........if.(c |
7dfe0 | 6f 75 6e 74 28 24 64 65 66 69 6e 69 74 69 6f 6e 2d 3e 67 65 74 4f 70 74 69 6f 6e 73 28 29 29 20 | ount($definition->getOptions()). |
7e000 | 3e 20 30 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 73 68 6f 77 41 72 67 75 | >.0).{.............if.($showArgu |
7e020 | 6d 65 6e 74 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e | ments).{.................$this-> |
7e040 | 77 72 69 74 65 28 22 5c 6e 5c 6e 22 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 | write("\n\n");.............}.... |
7e060 | 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 28 27 23 23 23 20 4f 70 74 69 | ..........$this->write('###.Opti |
7e080 | 6f 6e 73 3a 27 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 64 65 | ons:');.............foreach.($de |
7e0a0 | 66 69 6e 69 74 69 6f 6e 2d 3e 67 65 74 4f 70 74 69 6f 6e 73 28 29 20 61 73 20 24 6f 70 74 69 6f | finition->getOptions().as.$optio |
7e0c0 | 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 | n).{.................$this->writ |
7e0e0 | 65 28 22 5c 6e 5c 6e 22 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 | e("\n\n");.................$this |
7e100 | 2d 3e 77 72 69 74 65 28 24 74 68 69 73 2d 3e 64 65 73 63 72 69 62 65 49 6e 70 75 74 4f 70 74 69 | ->write($this->describeInputOpti |
7e120 | 6f 6e 28 24 6f 70 74 69 6f 6e 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 | on($option));.............}..... |
7e140 | 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e | ....}.....}....../**......*.{@in |
7e160 | 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 | heritdoc}......*/.....protected. |
7e180 | 66 75 6e 63 74 69 6f 6e 20 64 65 73 63 72 69 62 65 43 6f 6d 6d 61 6e 64 28 43 6f 6d 6d 61 6e 64 | function.describeCommand(Command |
7e1a0 | 20 24 63 6f 6d 6d 61 6e 64 2c 20 61 72 72 61 79 20 24 6f 70 74 69 6f 6e 73 20 3d 20 61 72 72 61 | .$command,.array.$options.=.arra |
7e1c0 | 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 63 6f 6d 6d 61 6e 64 2d 3e 67 65 74 | y()).....{.........$command->get |
7e1e0 | 53 79 6e 6f 70 73 69 73 28 29 3b 0a 20 20 20 20 20 20 20 20 24 63 6f 6d 6d 61 6e 64 2d 3e 6d 65 | Synopsis();.........$command->me |
7e200 | 72 67 65 41 70 70 6c 69 63 61 74 69 6f 6e 44 65 66 69 6e 69 74 69 6f 6e 28 66 61 6c 73 65 29 3b | rgeApplicationDefinition(false); |
7e220 | 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 28 0a 20 20 20 20 20 20 20 20 | ..........$this->write(......... |
7e240 | 20 20 20 20 24 63 6f 6d 6d 61 6e 64 2d 3e 67 65 74 4e 61 6d 65 28 29 2e 22 5c 6e 22 0a 20 20 20 | ....$command->getName()."\n".... |
7e260 | 20 20 20 20 20 20 20 20 20 2e 73 74 72 5f 72 65 70 65 61 74 28 27 2d 27 2c 20 73 74 72 6c 65 6e | ..........str_repeat('-',.strlen |
7e280 | 28 24 63 6f 6d 6d 61 6e 64 2d 3e 67 65 74 4e 61 6d 65 28 29 29 29 2e 22 5c 6e 5c 6e 22 0a 20 20 | ($command->getName()))."\n\n"... |
7e2a0 | 20 20 20 20 20 20 20 20 20 20 2e 27 2a 20 44 65 73 63 72 69 70 74 69 6f 6e 3a 20 27 2e 28 24 63 | ...........'*.Description:.'.($c |
7e2c0 | 6f 6d 6d 61 6e 64 2d 3e 67 65 74 44 65 73 63 72 69 70 74 69 6f 6e 28 29 20 3f 3a 20 27 3c 6e 6f | ommand->getDescription().?:.'<no |
7e2e0 | 6e 65 3e 27 29 2e 22 5c 6e 22 0a 20 20 20 20 20 20 20 20 20 20 20 20 2e 27 2a 20 55 73 61 67 65 | ne>')."\n"..............'*.Usage |
7e300 | 3a 27 2e 22 5c 6e 5c 6e 22 0a 20 20 20 20 20 20 20 20 20 20 20 20 2e 61 72 72 61 79 5f 72 65 64 | :'."\n\n"..............array_red |
7e320 | 75 63 65 28 61 72 72 61 79 5f 6d 65 72 67 65 28 61 72 72 61 79 28 24 63 6f 6d 6d 61 6e 64 2d 3e | uce(array_merge(array($command-> |
7e340 | 67 65 74 53 79 6e 6f 70 73 69 73 28 29 29 2c 20 24 63 6f 6d 6d 61 6e 64 2d 3e 67 65 74 41 6c 69 | getSynopsis()),.$command->getAli |
7e360 | 61 73 65 73 28 29 2c 20 24 63 6f 6d 6d 61 6e 64 2d 3e 67 65 74 55 73 61 67 65 73 28 29 29 2c 20 | ases(),.$command->getUsages()),. |
7e380 | 66 75 6e 63 74 69 6f 6e 20 28 24 63 61 72 72 79 2c 20 24 75 73 61 67 65 29 20 7b 0a 20 20 20 20 | function.($carry,.$usage).{..... |
7e3a0 | 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 63 61 72 72 79 2e 27 20 20 2a 20 60 | ............return.$carry.'..*.` |
7e3c0 | 27 2e 24 75 73 61 67 65 2e 27 60 27 2e 22 5c 6e 22 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d | '.$usage.'`'."\n";.............} |
7e3e0 | 29 0a 20 20 20 20 20 20 20 20 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 68 65 6c 70 20 | ).........);..........if.($help. |
7e400 | 3d 20 24 63 6f 6d 6d 61 6e 64 2d 3e 67 65 74 50 72 6f 63 65 73 73 65 64 48 65 6c 70 28 29 29 20 | =.$command->getProcessedHelp()). |
7e420 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 28 22 5c 6e 22 29 | {.............$this->write("\n") |
7e440 | 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 28 24 68 65 6c 70 | ;.............$this->write($help |
7e460 | 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 63 6f 6d 6d 61 | );.........}..........if.($comma |
7e480 | 6e 64 2d 3e 67 65 74 4e 61 74 69 76 65 44 65 66 69 6e 69 74 69 6f 6e 28 29 29 20 7b 0a 20 20 20 | nd->getNativeDefinition()).{.... |
7e4a0 | 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 28 22 5c 6e 5c 6e 22 29 3b 0a 20 | .........$this->write("\n\n");.. |
7e4c0 | 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 64 65 73 63 72 69 62 65 49 6e 70 75 74 44 | ...........$this->describeInputD |
7e4e0 | 65 66 69 6e 69 74 69 6f 6e 28 24 63 6f 6d 6d 61 6e 64 2d 3e 67 65 74 4e 61 74 69 76 65 44 65 66 | efinition($command->getNativeDef |
7e500 | 69 6e 69 74 69 6f 6e 28 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 | inition());.........}.....}..... |
7e520 | 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a | ./**......*.{@inheritdoc}......* |
7e540 | 2f 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 64 65 73 63 72 69 62 | /.....protected.function.describ |
7e560 | 65 41 70 70 6c 69 63 61 74 69 6f 6e 28 41 70 70 6c 69 63 61 74 69 6f 6e 20 24 61 70 70 6c 69 63 | eApplication(Application.$applic |
7e580 | 61 74 69 6f 6e 2c 20 61 72 72 61 79 20 24 6f 70 74 69 6f 6e 73 20 3d 20 61 72 72 61 79 28 29 29 | ation,.array.$options.=.array()) |
7e5a0 | 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 64 65 73 63 72 69 62 65 64 4e 61 6d 65 73 70 61 | .....{.........$describedNamespa |
7e5c0 | 63 65 20 3d 20 69 73 73 65 74 28 24 6f 70 74 69 6f 6e 73 5b 27 6e 61 6d 65 73 70 61 63 65 27 5d | ce.=.isset($options['namespace'] |
7e5e0 | 29 20 3f 20 24 6f 70 74 69 6f 6e 73 5b 27 6e 61 6d 65 73 70 61 63 65 27 5d 20 3a 20 6e 75 6c 6c | ).?.$options['namespace'].:.null |
7e600 | 3b 0a 20 20 20 20 20 20 20 20 24 64 65 73 63 72 69 70 74 69 6f 6e 20 3d 20 6e 65 77 20 41 70 70 | ;.........$description.=.new.App |
7e620 | 6c 69 63 61 74 69 6f 6e 44 65 73 63 72 69 70 74 69 6f 6e 28 24 61 70 70 6c 69 63 61 74 69 6f 6e | licationDescription($application |
7e640 | 2c 20 24 64 65 73 63 72 69 62 65 64 4e 61 6d 65 73 70 61 63 65 29 3b 0a 0a 20 20 20 20 20 20 20 | ,.$describedNamespace);......... |
7e660 | 20 24 74 68 69 73 2d 3e 77 72 69 74 65 28 24 61 70 70 6c 69 63 61 74 69 6f 6e 2d 3e 67 65 74 4e | .$this->write($application->getN |
7e680 | 61 6d 65 28 29 2e 22 5c 6e 22 2e 73 74 72 5f 72 65 70 65 61 74 28 27 3d 27 2c 20 73 74 72 6c 65 | ame()."\n".str_repeat('=',.strle |
7e6a0 | 6e 28 24 61 70 70 6c 69 63 61 74 69 6f 6e 2d 3e 67 65 74 4e 61 6d 65 28 29 29 29 29 3b 0a 0a 20 | n($application->getName())));... |
7e6c0 | 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 64 65 73 63 72 69 70 74 69 6f 6e 2d 3e 67 65 | .......foreach.($description->ge |
7e6e0 | 74 4e 61 6d 65 73 70 61 63 65 73 28 29 20 61 73 20 24 6e 61 6d 65 73 70 61 63 65 29 20 7b 0a 20 | tNamespaces().as.$namespace).{.. |
7e700 | 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 41 70 70 6c 69 63 61 74 69 6f 6e 44 65 73 63 72 69 | ...........if.(ApplicationDescri |
7e720 | 70 74 69 6f 6e 3a 3a 47 4c 4f 42 41 4c 5f 4e 41 4d 45 53 50 41 43 45 20 21 3d 3d 20 24 6e 61 6d | ption::GLOBAL_NAMESPACE.!==.$nam |
7e740 | 65 73 70 61 63 65 5b 27 69 64 27 5d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | espace['id']).{................. |
7e760 | 24 74 68 69 73 2d 3e 77 72 69 74 65 28 22 5c 6e 5c 6e 22 29 3b 0a 20 20 20 20 20 20 20 20 20 20 | $this->write("\n\n");........... |
7e780 | 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 28 27 2a 2a 27 2e 24 6e 61 6d 65 73 70 61 | ......$this->write('**'.$namespa |
7e7a0 | 63 65 5b 27 69 64 27 5d 2e 27 3a 2a 2a 27 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a | ce['id'].':**');.............}.. |
7e7c0 | 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 28 22 5c 6e 5c 6e 22 29 | ............$this->write("\n\n") |
7e7e0 | 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 28 69 6d 70 6c 6f | ;.............$this->write(implo |
7e800 | 64 65 28 22 5c 6e 22 2c 20 61 72 72 61 79 5f 6d 61 70 28 66 75 6e 63 74 69 6f 6e 20 28 24 63 6f | de("\n",.array_map(function.($co |
7e820 | 6d 6d 61 6e 64 4e 61 6d 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 | mmandName).{.................ret |
7e840 | 75 72 6e 20 27 2a 20 27 2e 24 63 6f 6d 6d 61 6e 64 4e 61 6d 65 3b 0a 20 20 20 20 20 20 20 20 20 | urn.'*.'.$commandName;.......... |
7e860 | 20 20 20 7d 2c 20 24 6e 61 6d 65 73 70 61 63 65 5b 27 63 6f 6d 6d 61 6e 64 73 27 5d 29 29 29 3b | ...},.$namespace['commands']))); |
7e880 | 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 64 65 | .........}..........foreach.($de |
7e8a0 | 73 63 72 69 70 74 69 6f 6e 2d 3e 67 65 74 43 6f 6d 6d 61 6e 64 73 28 29 20 61 73 20 24 63 6f 6d | scription->getCommands().as.$com |
7e8c0 | 6d 61 6e 64 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 | mand).{.............$this->write |
7e8e0 | 28 22 5c 6e 5c 6e 22 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 | ("\n\n");.............$this->wri |
7e900 | 74 65 28 24 74 68 69 73 2d 3e 64 65 73 63 72 69 62 65 43 6f 6d 6d 61 6e 64 28 24 63 6f 6d 6d 61 | te($this->describeCommand($comma |
7e920 | 6e 64 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f | nd));.........}.....}.}.<?php../ |
7e940 | 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 | *..*.This.file.is.part.of.the.Sy |
7e960 | 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 | mfony.package...*..*.(c).Fabien. |
7e980 | 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 | Potencier.<fabien@symfony.com>.. |
7e9a0 | 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 | *..*.For.the.full.copyright.and. |
7e9c0 | 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 | license.information,.please.view |
7e9e0 | 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 | .the.LICENSE..*.file.that.was.di |
7ea00 | 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e | stributed.with.this.source.code. |
7ea20 | 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e | ..*/..namespace.Symfony\Componen |
7ea40 | 74 5c 43 6f 6e 73 6f 6c 65 5c 44 65 73 63 72 69 70 74 6f 72 3b 0a 0a 75 73 65 20 53 79 6d 66 6f | t\Console\Descriptor;..use.Symfo |
7ea60 | 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 41 70 70 6c 69 63 61 74 69 6f 6e | ny\Component\Console\Application |
7ea80 | 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c | ;.use.Symfony\Component\Console\ |
7eaa0 | 43 6f 6d 6d 61 6e 64 5c 43 6f 6d 6d 61 6e 64 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d | Command\Command;.use.Symfony\Com |
7eac0 | 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 5c 49 6e 70 75 74 41 72 67 75 6d 65 | ponent\Console\Input\InputArgume |
7eae0 | 6e 74 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c | nt;.use.Symfony\Component\Consol |
7eb00 | 65 5c 49 6e 70 75 74 5c 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 3b 0a 75 73 65 20 53 79 6d | e\Input\InputDefinition;.use.Sym |
7eb20 | 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 5c 49 6e 70 | fony\Component\Console\Input\Inp |
7eb40 | 75 74 4f 70 74 69 6f 6e 3b 0a 0a 2f 2a 2a 0a 20 2a 20 4a 53 4f 4e 20 64 65 73 63 72 69 70 74 6f | utOption;../**..*.JSON.descripto |
7eb60 | 72 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 4a 65 61 6e 2d 46 72 61 6e c3 a7 6f 69 73 20 | r...*..*.@author.Jean-Fran..ois. |
7eb80 | 53 69 6d 6f 6e 20 3c 63 6f 6e 74 61 63 74 40 6a 66 73 69 6d 6f 6e 2e 66 72 3e 0a 20 2a 0a 20 2a | Simon.<contact@jfsimon.fr>..*..* |
7eba0 | 20 40 69 6e 74 65 72 6e 61 6c 0a 20 2a 2f 0a 63 6c 61 73 73 20 4a 73 6f 6e 44 65 73 63 72 69 70 | .@internal..*/.class.JsonDescrip |
7ebc0 | 74 6f 72 20 65 78 74 65 6e 64 73 20 44 65 73 63 72 69 70 74 6f 72 0a 7b 0a 20 20 20 20 2f 2a 2a | tor.extends.Descriptor.{...../** |
7ebe0 | 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 | ......*.{@inheritdoc}......*/... |
7ec00 | 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 64 65 73 63 72 69 62 65 49 6e 70 | ..protected.function.describeInp |
7ec20 | 75 74 41 72 67 75 6d 65 6e 74 28 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 20 24 61 72 67 75 6d 65 | utArgument(InputArgument.$argume |
7ec40 | 6e 74 2c 20 61 72 72 61 79 20 24 6f 70 74 69 6f 6e 73 20 3d 20 61 72 72 61 79 28 29 29 0a 20 20 | nt,.array.$options.=.array())... |
7ec60 | 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 44 61 74 61 28 24 74 68 | ..{.........$this->writeData($th |
7ec80 | 69 73 2d 3e 67 65 74 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 44 61 74 61 28 24 61 72 67 75 6d 65 | is->getInputArgumentData($argume |
7eca0 | 6e 74 29 2c 20 24 6f 70 74 69 6f 6e 73 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 | nt),.$options);.....}....../**.. |
7ecc0 | 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 | ....*.{@inheritdoc}......*/..... |
7ece0 | 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 64 65 73 63 72 69 62 65 49 6e 70 75 74 | protected.function.describeInput |
7ed00 | 4f 70 74 69 6f 6e 28 49 6e 70 75 74 4f 70 74 69 6f 6e 20 24 6f 70 74 69 6f 6e 2c 20 61 72 72 61 | Option(InputOption.$option,.arra |
7ed20 | 79 20 24 6f 70 74 69 6f 6e 73 20 3d 20 61 72 72 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 | y.$options.=.array()).....{..... |
7ed40 | 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 44 61 74 61 28 24 74 68 69 73 2d 3e 67 65 74 49 | ....$this->writeData($this->getI |
7ed60 | 6e 70 75 74 4f 70 74 69 6f 6e 44 61 74 61 28 24 6f 70 74 69 6f 6e 29 2c 20 24 6f 70 74 69 6f 6e | nputOptionData($option),.$option |
7ed80 | 73 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 | s);.....}....../**......*.{@inhe |
7eda0 | 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 | ritdoc}......*/.....protected.fu |
7edc0 | 6e 63 74 69 6f 6e 20 64 65 73 63 72 69 62 65 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 28 49 | nction.describeInputDefinition(I |
7ede0 | 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 20 24 64 65 66 69 6e 69 74 69 6f 6e 2c 20 61 72 72 61 | nputDefinition.$definition,.arra |
7ee00 | 79 20 24 6f 70 74 69 6f 6e 73 20 3d 20 61 72 72 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 | y.$options.=.array()).....{..... |
7ee20 | 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 44 61 74 61 28 24 74 68 69 73 2d 3e 67 65 74 49 | ....$this->writeData($this->getI |
7ee40 | 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 44 61 74 61 28 24 64 65 66 69 6e 69 74 69 6f 6e 29 2c | nputDefinitionData($definition), |
7ee60 | 20 24 6f 70 74 69 6f 6e 73 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 | .$options);.....}....../**...... |
7ee80 | 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 6f 74 | *.{@inheritdoc}......*/.....prot |
7eea0 | 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 64 65 73 63 72 69 62 65 43 6f 6d 6d 61 6e 64 28 43 | ected.function.describeCommand(C |
7eec0 | 6f 6d 6d 61 6e 64 20 24 63 6f 6d 6d 61 6e 64 2c 20 61 72 72 61 79 20 24 6f 70 74 69 6f 6e 73 20 | ommand.$command,.array.$options. |
7eee0 | 3d 20 61 72 72 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e | =.array()).....{.........$this-> |
7ef00 | 77 72 69 74 65 44 61 74 61 28 24 74 68 69 73 2d 3e 67 65 74 43 6f 6d 6d 61 6e 64 44 61 74 61 28 | writeData($this->getCommandData( |
7ef20 | 24 63 6f 6d 6d 61 6e 64 29 2c 20 24 6f 70 74 69 6f 6e 73 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 | $command),.$options);.....}..... |
7ef40 | 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a | ./**......*.{@inheritdoc}......* |
7ef60 | 2f 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 64 65 73 63 72 69 62 | /.....protected.function.describ |
7ef80 | 65 41 70 70 6c 69 63 61 74 69 6f 6e 28 41 70 70 6c 69 63 61 74 69 6f 6e 20 24 61 70 70 6c 69 63 | eApplication(Application.$applic |
7efa0 | 61 74 69 6f 6e 2c 20 61 72 72 61 79 20 24 6f 70 74 69 6f 6e 73 20 3d 20 61 72 72 61 79 28 29 29 | ation,.array.$options.=.array()) |
7efc0 | 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 64 65 73 63 72 69 62 65 64 4e 61 6d 65 73 70 61 | .....{.........$describedNamespa |
7efe0 | 63 65 20 3d 20 69 73 73 65 74 28 24 6f 70 74 69 6f 6e 73 5b 27 6e 61 6d 65 73 70 61 63 65 27 5d | ce.=.isset($options['namespace'] |
7f000 | 29 20 3f 20 24 6f 70 74 69 6f 6e 73 5b 27 6e 61 6d 65 73 70 61 63 65 27 5d 20 3a 20 6e 75 6c 6c | ).?.$options['namespace'].:.null |
7f020 | 3b 0a 20 20 20 20 20 20 20 20 24 64 65 73 63 72 69 70 74 69 6f 6e 20 3d 20 6e 65 77 20 41 70 70 | ;.........$description.=.new.App |
7f040 | 6c 69 63 61 74 69 6f 6e 44 65 73 63 72 69 70 74 69 6f 6e 28 24 61 70 70 6c 69 63 61 74 69 6f 6e | licationDescription($application |
7f060 | 2c 20 24 64 65 73 63 72 69 62 65 64 4e 61 6d 65 73 70 61 63 65 29 3b 0a 20 20 20 20 20 20 20 20 | ,.$describedNamespace);......... |
7f080 | 24 63 6f 6d 6d 61 6e 64 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 0a 20 20 20 20 20 20 20 20 66 6f | $commands.=.array();..........fo |
7f0a0 | 72 65 61 63 68 20 28 24 64 65 73 63 72 69 70 74 69 6f 6e 2d 3e 67 65 74 43 6f 6d 6d 61 6e 64 73 | reach.($description->getCommands |
7f0c0 | 28 29 20 61 73 20 24 63 6f 6d 6d 61 6e 64 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 63 | ().as.$command).{.............$c |
7f0e0 | 6f 6d 6d 61 6e 64 73 5b 5d 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 43 6f 6d 6d 61 6e 64 44 61 74 | ommands[].=.$this->getCommandDat |
7f100 | 61 28 24 63 6f 6d 6d 61 6e 64 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 | a($command);.........}.......... |
7f120 | 24 64 61 74 61 20 3d 20 24 64 65 73 63 72 69 62 65 64 4e 61 6d 65 73 70 61 63 65 0a 20 20 20 20 | $data.=.$describedNamespace..... |
7f140 | 20 20 20 20 20 20 20 20 3f 20 61 72 72 61 79 28 27 63 6f 6d 6d 61 6e 64 73 27 20 3d 3e 20 24 63 | ........?.array('commands'.=>.$c |
7f160 | 6f 6d 6d 61 6e 64 73 2c 20 27 6e 61 6d 65 73 70 61 63 65 27 20 3d 3e 20 24 64 65 73 63 72 69 62 | ommands,.'namespace'.=>.$describ |
7f180 | 65 64 4e 61 6d 65 73 70 61 63 65 29 0a 20 20 20 20 20 20 20 20 20 20 20 20 3a 20 61 72 72 61 79 | edNamespace).............:.array |
7f1a0 | 28 27 63 6f 6d 6d 61 6e 64 73 27 20 3d 3e 20 24 63 6f 6d 6d 61 6e 64 73 2c 20 27 6e 61 6d 65 73 | ('commands'.=>.$commands,.'names |
7f1c0 | 70 61 63 65 73 27 20 3d 3e 20 61 72 72 61 79 5f 76 61 6c 75 65 73 28 24 64 65 73 63 72 69 70 74 | paces'.=>.array_values($descript |
7f1e0 | 69 6f 6e 2d 3e 67 65 74 4e 61 6d 65 73 70 61 63 65 73 28 29 29 29 3b 0a 0a 20 20 20 20 20 20 20 | ion->getNamespaces()));......... |
7f200 | 20 24 74 68 69 73 2d 3e 77 72 69 74 65 44 61 74 61 28 24 64 61 74 61 2c 20 24 6f 70 74 69 6f 6e | .$this->writeData($data,.$option |
7f220 | 73 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 57 72 69 74 65 73 | s);.....}....../**......*.Writes |
7f240 | 20 64 61 74 61 20 61 73 20 6a 73 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 | .data.as.json.......*......*.@pa |
7f260 | 72 61 6d 20 61 72 72 61 79 20 24 64 61 74 61 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 | ram.array.$data......*.@param.ar |
7f280 | 72 61 79 20 24 6f 70 74 69 6f 6e 73 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 | ray.$options......*......*.@retu |
7f2a0 | 72 6e 20 61 72 72 61 79 7c 73 74 72 69 6e 67 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 | rn.array|string......*/.....priv |
7f2c0 | 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 77 72 69 74 65 44 61 74 61 28 61 72 72 61 79 20 24 64 61 | ate.function.writeData(array.$da |
7f2e0 | 74 61 2c 20 61 72 72 61 79 20 24 6f 70 74 69 6f 6e 73 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 | ta,.array.$options).....{....... |
7f300 | 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 28 6a 73 6f 6e 5f 65 6e 63 6f 64 65 28 24 64 61 74 61 | ..$this->write(json_encode($data |
7f320 | 2c 20 69 73 73 65 74 28 24 6f 70 74 69 6f 6e 73 5b 27 6a 73 6f 6e 5f 65 6e 63 6f 64 69 6e 67 27 | ,.isset($options['json_encoding' |
7f340 | 5d 29 20 3f 20 24 6f 70 74 69 6f 6e 73 5b 27 6a 73 6f 6e 5f 65 6e 63 6f 64 69 6e 67 27 5d 20 3a | ]).?.$options['json_encoding'].: |
7f360 | 20 30 29 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 | .0));.....}....../**......*.@par |
7f380 | 61 6d 20 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 20 24 61 72 67 75 6d 65 6e 74 0a 20 20 20 20 20 | am.InputArgument.$argument...... |
7f3a0 | 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 61 72 72 61 79 0a 20 20 20 20 20 2a 2f 0a 20 | *......*.@return.array......*/.. |
7f3c0 | 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 49 6e 70 75 74 41 72 67 75 | ...private.function.getInputArgu |
7f3e0 | 6d 65 6e 74 44 61 74 61 28 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 20 24 61 72 67 75 6d 65 6e 74 | mentData(InputArgument.$argument |
7f400 | 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 61 72 72 61 79 28 0a 20 20 | ).....{.........return.array(... |
7f420 | 20 20 20 20 20 20 20 20 20 20 27 6e 61 6d 65 27 20 3d 3e 20 24 61 72 67 75 6d 65 6e 74 2d 3e 67 | ..........'name'.=>.$argument->g |
7f440 | 65 74 4e 61 6d 65 28 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 69 73 5f 72 65 71 75 69 72 | etName(),.............'is_requir |
7f460 | 65 64 27 20 3d 3e 20 24 61 72 67 75 6d 65 6e 74 2d 3e 69 73 52 65 71 75 69 72 65 64 28 29 2c 0a | ed'.=>.$argument->isRequired(),. |
7f480 | 20 20 20 20 20 20 20 20 20 20 20 20 27 69 73 5f 61 72 72 61 79 27 20 3d 3e 20 24 61 72 67 75 6d | ............'is_array'.=>.$argum |
7f4a0 | 65 6e 74 2d 3e 69 73 41 72 72 61 79 28 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 64 65 73 | ent->isArray(),.............'des |
7f4c0 | 63 72 69 70 74 69 6f 6e 27 20 3d 3e 20 70 72 65 67 5f 72 65 70 6c 61 63 65 28 27 2f 5c 73 2a 5b | cription'.=>.preg_replace('/\s*[ |
7f4e0 | 5c 72 5c 6e 5d 5c 73 2a 2f 27 2c 20 27 20 27 2c 20 24 61 72 67 75 6d 65 6e 74 2d 3e 67 65 74 44 | \r\n]\s*/',.'.',.$argument->getD |
7f500 | 65 73 63 72 69 70 74 69 6f 6e 28 29 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 64 65 66 61 | escription()),.............'defa |
7f520 | 75 6c 74 27 20 3d 3e 20 24 61 72 67 75 6d 65 6e 74 2d 3e 67 65 74 44 65 66 61 75 6c 74 28 29 2c | ult'.=>.$argument->getDefault(), |
7f540 | 0a 20 20 20 20 20 20 20 20 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 | .........);.....}....../**...... |
7f560 | 2a 20 40 70 61 72 61 6d 20 49 6e 70 75 74 4f 70 74 69 6f 6e 20 24 6f 70 74 69 6f 6e 0a 20 20 20 | *.@param.InputOption.$option.... |
7f580 | 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 61 72 72 61 79 0a 20 20 20 20 20 2a 2f | ..*......*.@return.array......*/ |
7f5a0 | 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 49 6e 70 75 74 4f 70 | .....private.function.getInputOp |
7f5c0 | 74 69 6f 6e 44 61 74 61 28 49 6e 70 75 74 4f 70 74 69 6f 6e 20 24 6f 70 74 69 6f 6e 29 0a 20 20 | tionData(InputOption.$option)... |
7f5e0 | 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 61 72 72 61 79 28 0a 20 20 20 20 20 20 | ..{.........return.array(....... |
7f600 | 20 20 20 20 20 20 27 6e 61 6d 65 27 20 3d 3e 20 27 2d 2d 27 2e 24 6f 70 74 69 6f 6e 2d 3e 67 65 | ......'name'.=>.'--'.$option->ge |
7f620 | 74 4e 61 6d 65 28 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 73 68 6f 72 74 63 75 74 27 20 | tName(),.............'shortcut'. |
7f640 | 3d 3e 20 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 53 68 6f 72 74 63 75 74 28 29 20 3f 20 27 2d 27 2e | =>.$option->getShortcut().?.'-'. |
7f660 | 69 6d 70 6c 6f 64 65 28 27 7c 2d 27 2c 20 65 78 70 6c 6f 64 65 28 27 7c 27 2c 20 24 6f 70 74 69 | implode('|-',.explode('|',.$opti |
7f680 | 6f 6e 2d 3e 67 65 74 53 68 6f 72 74 63 75 74 28 29 29 29 20 3a 20 27 27 2c 0a 20 20 20 20 20 20 | on->getShortcut())).:.'',....... |
7f6a0 | 20 20 20 20 20 20 27 61 63 63 65 70 74 5f 76 61 6c 75 65 27 20 3d 3e 20 24 6f 70 74 69 6f 6e 2d | ......'accept_value'.=>.$option- |
7f6c0 | 3e 61 63 63 65 70 74 56 61 6c 75 65 28 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 69 73 5f | >acceptValue(),.............'is_ |
7f6e0 | 76 61 6c 75 65 5f 72 65 71 75 69 72 65 64 27 20 3d 3e 20 24 6f 70 74 69 6f 6e 2d 3e 69 73 56 61 | value_required'.=>.$option->isVa |
7f700 | 6c 75 65 52 65 71 75 69 72 65 64 28 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 69 73 5f 6d | lueRequired(),.............'is_m |
7f720 | 75 6c 74 69 70 6c 65 27 20 3d 3e 20 24 6f 70 74 69 6f 6e 2d 3e 69 73 41 72 72 61 79 28 29 2c 0a | ultiple'.=>.$option->isArray(),. |
7f740 | 20 20 20 20 20 20 20 20 20 20 20 20 27 64 65 73 63 72 69 70 74 69 6f 6e 27 20 3d 3e 20 70 72 65 | ............'description'.=>.pre |
7f760 | 67 5f 72 65 70 6c 61 63 65 28 27 2f 5c 73 2a 5b 5c 72 5c 6e 5d 5c 73 2a 2f 27 2c 20 27 20 27 2c | g_replace('/\s*[\r\n]\s*/',.'.', |
7f780 | 20 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 44 65 73 63 72 69 70 74 69 6f 6e 28 29 29 2c 0a 20 20 20 | .$option->getDescription()),.... |
7f7a0 | 20 20 20 20 20 20 20 20 20 27 64 65 66 61 75 6c 74 27 20 3d 3e 20 24 6f 70 74 69 6f 6e 2d 3e 67 | .........'default'.=>.$option->g |
7f7c0 | 65 74 44 65 66 61 75 6c 74 28 29 2c 0a 20 20 20 20 20 20 20 20 29 3b 0a 20 20 20 20 7d 0a 0a 20 | etDefault(),.........);.....}... |
7f7e0 | 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 49 6e 70 75 74 44 65 66 69 6e 69 | .../**......*.@param.InputDefini |
7f800 | 74 69 6f 6e 20 24 64 65 66 69 6e 69 74 69 6f 6e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 | tion.$definition......*......*.@ |
7f820 | 72 65 74 75 72 6e 20 61 72 72 61 79 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 | return.array......*/.....private |
7f840 | 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 44 61 74 61 | .function.getInputDefinitionData |
7f860 | 28 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 20 24 64 65 66 69 6e 69 74 69 6f 6e 29 0a 20 20 | (InputDefinition.$definition)... |
7f880 | 20 20 7b 0a 20 20 20 20 20 20 20 20 24 69 6e 70 75 74 41 72 67 75 6d 65 6e 74 73 20 3d 20 61 72 | ..{.........$inputArguments.=.ar |
7f8a0 | 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 64 65 66 69 6e 69 74 | ray();.........foreach.($definit |
7f8c0 | 69 6f 6e 2d 3e 67 65 74 41 72 67 75 6d 65 6e 74 73 28 29 20 61 73 20 24 6e 61 6d 65 20 3d 3e 20 | ion->getArguments().as.$name.=>. |
7f8e0 | 24 61 72 67 75 6d 65 6e 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 69 6e 70 75 74 41 | $argument).{.............$inputA |
7f900 | 72 67 75 6d 65 6e 74 73 5b 24 6e 61 6d 65 5d 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 49 6e 70 75 | rguments[$name].=.$this->getInpu |
7f920 | 74 41 72 67 75 6d 65 6e 74 44 61 74 61 28 24 61 72 67 75 6d 65 6e 74 29 3b 0a 20 20 20 20 20 20 | tArgumentData($argument);....... |
7f940 | 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 69 6e 70 75 74 4f 70 74 69 6f 6e 73 20 3d 20 61 72 72 | ..}..........$inputOptions.=.arr |
7f960 | 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 64 65 66 69 6e 69 74 69 | ay();.........foreach.($definiti |
7f980 | 6f 6e 2d 3e 67 65 74 4f 70 74 69 6f 6e 73 28 29 20 61 73 20 24 6e 61 6d 65 20 3d 3e 20 24 6f 70 | on->getOptions().as.$name.=>.$op |
7f9a0 | 74 69 6f 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 69 6e 70 75 74 4f 70 74 69 6f 6e | tion).{.............$inputOption |
7f9c0 | 73 5b 24 6e 61 6d 65 5d 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 49 6e 70 75 74 4f 70 74 69 6f 6e | s[$name].=.$this->getInputOption |
7f9e0 | 44 61 74 61 28 24 6f 70 74 69 6f 6e 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 | Data($option);.........}........ |
7fa00 | 20 20 72 65 74 75 72 6e 20 61 72 72 61 79 28 27 61 72 67 75 6d 65 6e 74 73 27 20 3d 3e 20 24 69 | ..return.array('arguments'.=>.$i |
7fa20 | 6e 70 75 74 41 72 67 75 6d 65 6e 74 73 2c 20 27 6f 70 74 69 6f 6e 73 27 20 3d 3e 20 24 69 6e 70 | nputArguments,.'options'.=>.$inp |
7fa40 | 75 74 4f 70 74 69 6f 6e 73 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 | utOptions);.....}....../**...... |
7fa60 | 2a 20 40 70 61 72 61 6d 20 43 6f 6d 6d 61 6e 64 20 24 63 6f 6d 6d 61 6e 64 0a 20 20 20 20 20 2a | *.@param.Command.$command......* |
7fa80 | 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 61 72 72 61 79 0a 20 20 20 20 20 2a 2f 0a 20 20 | ......*.@return.array......*/... |
7faa0 | 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 43 6f 6d 6d 61 6e 64 44 61 74 | ..private.function.getCommandDat |
7fac0 | 61 28 43 6f 6d 6d 61 6e 64 20 24 63 6f 6d 6d 61 6e 64 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 | a(Command.$command).....{....... |
7fae0 | 20 20 24 63 6f 6d 6d 61 6e 64 2d 3e 67 65 74 53 79 6e 6f 70 73 69 73 28 29 3b 0a 20 20 20 20 20 | ..$command->getSynopsis();...... |
7fb00 | 20 20 20 24 63 6f 6d 6d 61 6e 64 2d 3e 6d 65 72 67 65 41 70 70 6c 69 63 61 74 69 6f 6e 44 65 66 | ...$command->mergeApplicationDef |
7fb20 | 69 6e 69 74 69 6f 6e 28 66 61 6c 73 65 29 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 | inition(false);..........return. |
7fb40 | 61 72 72 61 79 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 6e 61 6d 65 27 20 3d 3e 20 24 63 6f | array(.............'name'.=>.$co |
7fb60 | 6d 6d 61 6e 64 2d 3e 67 65 74 4e 61 6d 65 28 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 75 | mmand->getName(),.............'u |
7fb80 | 73 61 67 65 27 20 3d 3e 20 61 72 72 61 79 5f 6d 65 72 67 65 28 61 72 72 61 79 28 24 63 6f 6d 6d | sage'.=>.array_merge(array($comm |
7fba0 | 61 6e 64 2d 3e 67 65 74 53 79 6e 6f 70 73 69 73 28 29 29 2c 20 24 63 6f 6d 6d 61 6e 64 2d 3e 67 | and->getSynopsis()),.$command->g |
7fbc0 | 65 74 55 73 61 67 65 73 28 29 2c 20 24 63 6f 6d 6d 61 6e 64 2d 3e 67 65 74 41 6c 69 61 73 65 73 | etUsages(),.$command->getAliases |
7fbe0 | 28 29 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 64 65 73 63 72 69 70 74 69 6f 6e 27 20 3d | ()),.............'description'.= |
7fc00 | 3e 20 24 63 6f 6d 6d 61 6e 64 2d 3e 67 65 74 44 65 73 63 72 69 70 74 69 6f 6e 28 29 2c 0a 20 20 | >.$command->getDescription(),... |
7fc20 | 20 20 20 20 20 20 20 20 20 20 27 68 65 6c 70 27 20 3d 3e 20 24 63 6f 6d 6d 61 6e 64 2d 3e 67 65 | ..........'help'.=>.$command->ge |
7fc40 | 74 50 72 6f 63 65 73 73 65 64 48 65 6c 70 28 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 27 64 | tProcessedHelp(),.............'d |
7fc60 | 65 66 69 6e 69 74 69 6f 6e 27 20 3d 3e 20 24 74 68 69 73 2d 3e 67 65 74 49 6e 70 75 74 44 65 66 | efinition'.=>.$this->getInputDef |
7fc80 | 69 6e 69 74 69 6f 6e 44 61 74 61 28 24 63 6f 6d 6d 61 6e 64 2d 3e 67 65 74 4e 61 74 69 76 65 44 | initionData($command->getNativeD |
7fca0 | 65 66 69 6e 69 74 69 6f 6e 28 29 29 2c 0a 20 20 20 20 20 20 20 20 29 3b 0a 20 20 20 20 7d 0a 7d | efinition()),.........);.....}.} |
7fcc0 | 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 | .<?php../*..*.This.file.is.part. |
7fce0 | 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 | of.the.Symfony.package...*..*.(c |
7fd00 | 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f | ).Fabien.Potencier.<fabien@symfo |
7fd20 | 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 | ny.com>..*..*.For.the.full.copyr |
7fd40 | 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c | ight.and.license.information,.pl |
7fd60 | 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 | ease.view.the.LICENSE..*.file.th |
7fd80 | 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 | at.was.distributed.with.this.sou |
7fda0 | 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 | rce.code...*/..namespace.Symfony |
7fdc0 | 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 44 65 73 63 72 69 70 74 6f 72 3b 0a 0a | \Component\Console\Descriptor;.. |
7fde0 | 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 41 70 | use.Symfony\Component\Console\Ap |
7fe00 | 70 6c 69 63 61 74 69 6f 6e 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 | plication;.use.Symfony\Component |
7fe20 | 5c 43 6f 6e 73 6f 6c 65 5c 43 6f 6d 6d 61 6e 64 5c 43 6f 6d 6d 61 6e 64 3b 0a 75 73 65 20 53 79 | \Console\Command\Command;.use.Sy |
7fe40 | 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 5c 49 6e | mfony\Component\Console\Input\In |
7fe60 | 70 75 74 41 72 67 75 6d 65 6e 74 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 | putArgument;.use.Symfony\Compone |
7fe80 | 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 5c 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e | nt\Console\Input\InputDefinition |
7fea0 | 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c | ;.use.Symfony\Component\Console\ |
7fec0 | 49 6e 70 75 74 5c 49 6e 70 75 74 4f 70 74 69 6f 6e 3b 0a 0a 2f 2a 2a 0a 20 2a 20 54 65 78 74 20 | Input\InputOption;../**..*.Text. |
7fee0 | 64 65 73 63 72 69 70 74 6f 72 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 4a 65 61 6e 2d 46 | descriptor...*..*.@author.Jean-F |
7ff00 | 72 61 6e c3 a7 6f 69 73 20 53 69 6d 6f 6e 20 3c 63 6f 6e 74 61 63 74 40 6a 66 73 69 6d 6f 6e 2e | ran..ois.Simon.<contact@jfsimon. |
7ff20 | 66 72 3e 0a 20 2a 0a 20 2a 20 40 69 6e 74 65 72 6e 61 6c 0a 20 2a 2f 0a 63 6c 61 73 73 20 54 65 | fr>..*..*.@internal..*/.class.Te |
7ff40 | 78 74 44 65 73 63 72 69 70 74 6f 72 20 65 78 74 65 6e 64 73 20 44 65 73 63 72 69 70 74 6f 72 0a | xtDescriptor.extends.Descriptor. |
7ff60 | 7b 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 | {...../**......*.{@inheritdoc}.. |
7ff80 | 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 64 65 | ....*/.....protected.function.de |
7ffa0 | 73 63 72 69 62 65 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 28 49 6e 70 75 74 41 72 67 75 6d 65 6e | scribeInputArgument(InputArgumen |
7ffc0 | 74 20 24 61 72 67 75 6d 65 6e 74 2c 20 61 72 72 61 79 20 24 6f 70 74 69 6f 6e 73 20 3d 20 61 72 | t.$argument,.array.$options.=.ar |
7ffe0 | 72 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 21 3d | ray()).....{.........if.(null.!= |
80000 | 3d 20 24 61 72 67 75 6d 65 6e 74 2d 3e 67 65 74 44 65 66 61 75 6c 74 28 29 20 26 26 20 28 21 69 | =.$argument->getDefault().&&.(!i |
80020 | 73 5f 61 72 72 61 79 28 24 61 72 67 75 6d 65 6e 74 2d 3e 67 65 74 44 65 66 61 75 6c 74 28 29 29 | s_array($argument->getDefault()) |
80040 | 20 7c 7c 20 63 6f 75 6e 74 28 24 61 72 67 75 6d 65 6e 74 2d 3e 67 65 74 44 65 66 61 75 6c 74 28 | .||.count($argument->getDefault( |
80060 | 29 29 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 64 65 66 61 75 6c 74 20 3d 20 73 70 | )))).{.............$default.=.sp |
80080 | 72 69 6e 74 66 28 27 3c 63 6f 6d 6d 65 6e 74 3e 20 5b 64 65 66 61 75 6c 74 3a 20 25 73 5d 3c 2f | rintf('<comment>.[default:.%s]</ |
800a0 | 63 6f 6d 6d 65 6e 74 3e 27 2c 20 24 74 68 69 73 2d 3e 66 6f 72 6d 61 74 44 65 66 61 75 6c 74 56 | comment>',.$this->formatDefaultV |
800c0 | 61 6c 75 65 28 24 61 72 67 75 6d 65 6e 74 2d 3e 67 65 74 44 65 66 61 75 6c 74 28 29 29 29 3b 0a | alue($argument->getDefault()));. |
800e0 | 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 64 65 | ........}.else.{.............$de |
80100 | 66 61 75 6c 74 20 3d 20 27 27 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 | fault.=.'';.........}..........$ |
80120 | 74 6f 74 61 6c 57 69 64 74 68 20 3d 20 69 73 73 65 74 28 24 6f 70 74 69 6f 6e 73 5b 27 74 6f 74 | totalWidth.=.isset($options['tot |
80140 | 61 6c 5f 77 69 64 74 68 27 5d 29 20 3f 20 24 6f 70 74 69 6f 6e 73 5b 27 74 6f 74 61 6c 5f 77 69 | al_width']).?.$options['total_wi |
80160 | 64 74 68 27 5d 20 3a 20 73 74 72 6c 65 6e 28 24 61 72 67 75 6d 65 6e 74 2d 3e 67 65 74 4e 61 6d | dth'].:.strlen($argument->getNam |
80180 | 65 28 29 29 3b 0a 20 20 20 20 20 20 20 20 24 73 70 61 63 69 6e 67 57 69 64 74 68 20 3d 20 24 74 | e());.........$spacingWidth.=.$t |
801a0 | 6f 74 61 6c 57 69 64 74 68 20 2d 20 73 74 72 6c 65 6e 28 24 61 72 67 75 6d 65 6e 74 2d 3e 67 65 | otalWidth.-.strlen($argument->ge |
801c0 | 74 4e 61 6d 65 28 29 29 20 2b 20 32 3b 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 | tName()).+.2;..........$this->wr |
801e0 | 69 74 65 54 65 78 74 28 73 70 72 69 6e 74 66 28 27 20 20 3c 69 6e 66 6f 3e 25 73 3c 2f 69 6e 66 | iteText(sprintf('..<info>%s</inf |
80200 | 6f 3e 25 73 25 73 25 73 27 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 61 72 67 75 6d 65 6e 74 | o>%s%s%s',.............$argument |
80220 | 2d 3e 67 65 74 4e 61 6d 65 28 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 73 74 72 5f 72 65 70 | ->getName(),.............str_rep |
80240 | 65 61 74 28 27 20 27 2c 20 24 73 70 61 63 69 6e 67 57 69 64 74 68 29 2c 0a 20 20 20 20 20 20 20 | eat('.',.$spacingWidth),........ |
80260 | 20 20 20 20 20 2f 2f 20 2b 20 31 37 20 3d 20 32 20 73 70 61 63 65 73 20 2b 20 3c 69 6e 66 6f 3e | .....//.+.17.=.2.spaces.+.<info> |
80280 | 20 2b 20 3c 2f 69 6e 66 6f 3e 20 2b 20 32 20 73 70 61 63 65 73 0a 20 20 20 20 20 20 20 20 20 20 | .+.</info>.+.2.spaces........... |
802a0 | 20 20 70 72 65 67 5f 72 65 70 6c 61 63 65 28 27 2f 5c 73 2a 5b 5c 72 5c 6e 5d 5c 73 2a 2f 27 2c | ..preg_replace('/\s*[\r\n]\s*/', |
802c0 | 20 22 5c 6e 22 2e 73 74 72 5f 72 65 70 65 61 74 28 27 20 27 2c 20 24 74 6f 74 61 6c 57 69 64 74 | ."\n".str_repeat('.',.$totalWidt |
802e0 | 68 20 2b 20 31 37 29 2c 20 24 61 72 67 75 6d 65 6e 74 2d 3e 67 65 74 44 65 73 63 72 69 70 74 69 | h.+.17),.$argument->getDescripti |
80300 | 6f 6e 28 29 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 64 65 66 61 75 6c 74 0a 20 20 20 20 | on()),.............$default..... |
80320 | 20 20 20 20 29 2c 20 24 6f 70 74 69 6f 6e 73 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a | ....),.$options);.....}....../** |
80340 | 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 | ......*.{@inheritdoc}......*/... |
80360 | 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 64 65 73 63 72 69 62 65 49 6e 70 | ..protected.function.describeInp |
80380 | 75 74 4f 70 74 69 6f 6e 28 49 6e 70 75 74 4f 70 74 69 6f 6e 20 24 6f 70 74 69 6f 6e 2c 20 61 72 | utOption(InputOption.$option,.ar |
803a0 | 72 61 79 20 24 6f 70 74 69 6f 6e 73 20 3d 20 61 72 72 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 | ray.$options.=.array()).....{... |
803c0 | 20 20 20 20 20 20 69 66 20 28 24 6f 70 74 69 6f 6e 2d 3e 61 63 63 65 70 74 56 61 6c 75 65 28 29 | ......if.($option->acceptValue() |
803e0 | 20 26 26 20 6e 75 6c 6c 20 21 3d 3d 20 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 44 65 66 61 75 6c 74 | .&&.null.!==.$option->getDefault |
80400 | 28 29 20 26 26 20 28 21 69 73 5f 61 72 72 61 79 28 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 44 65 66 | ().&&.(!is_array($option->getDef |
80420 | 61 75 6c 74 28 29 29 20 7c 7c 20 63 6f 75 6e 74 28 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 44 65 66 | ault()).||.count($option->getDef |
80440 | 61 75 6c 74 28 29 29 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 64 65 66 61 75 6c 74 | ault()))).{.............$default |
80460 | 20 3d 20 73 70 72 69 6e 74 66 28 27 3c 63 6f 6d 6d 65 6e 74 3e 20 5b 64 65 66 61 75 6c 74 3a 20 | .=.sprintf('<comment>.[default:. |
80480 | 25 73 5d 3c 2f 63 6f 6d 6d 65 6e 74 3e 27 2c 20 24 74 68 69 73 2d 3e 66 6f 72 6d 61 74 44 65 66 | %s]</comment>',.$this->formatDef |
804a0 | 61 75 6c 74 56 61 6c 75 65 28 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 44 65 66 61 75 6c 74 28 29 29 | aultValue($option->getDefault()) |
804c0 | 29 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | );.........}.else.{............. |
804e0 | 24 64 65 66 61 75 6c 74 20 3d 20 27 27 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 | $default.=.'';.........}........ |
80500 | 20 20 24 76 61 6c 75 65 20 3d 20 27 27 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 6f 70 74 69 | ..$value.=.'';.........if.($opti |
80520 | 6f 6e 2d 3e 61 63 63 65 70 74 56 61 6c 75 65 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | on->acceptValue()).{............ |
80540 | 20 24 76 61 6c 75 65 20 3d 20 27 3d 27 2e 73 74 72 74 6f 75 70 70 65 72 28 24 6f 70 74 69 6f 6e | .$value.=.'='.strtoupper($option |
80560 | 2d 3e 67 65 74 4e 61 6d 65 28 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 | ->getName());..............if.($ |
80580 | 6f 70 74 69 6f 6e 2d 3e 69 73 56 61 6c 75 65 4f 70 74 69 6f 6e 61 6c 28 29 29 20 7b 0a 20 20 20 | option->isValueOptional()).{.... |
805a0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 24 76 61 6c 75 65 20 3d 20 27 5b 27 2e 24 76 61 6c 75 65 | .............$value.=.'['.$value |
805c0 | 2e 27 5d 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 | .']';.............}.........}... |
805e0 | 20 20 20 20 20 20 20 24 74 6f 74 61 6c 57 69 64 74 68 20 3d 20 69 73 73 65 74 28 24 6f 70 74 69 | .......$totalWidth.=.isset($opti |
80600 | 6f 6e 73 5b 27 74 6f 74 61 6c 5f 77 69 64 74 68 27 5d 29 20 3f 20 24 6f 70 74 69 6f 6e 73 5b 27 | ons['total_width']).?.$options[' |
80620 | 74 6f 74 61 6c 5f 77 69 64 74 68 27 5d 20 3a 20 24 74 68 69 73 2d 3e 63 61 6c 63 75 6c 61 74 65 | total_width'].:.$this->calculate |
80640 | 54 6f 74 61 6c 57 69 64 74 68 46 6f 72 4f 70 74 69 6f 6e 73 28 61 72 72 61 79 28 24 6f 70 74 69 | TotalWidthForOptions(array($opti |
80660 | 6f 6e 29 29 3b 0a 20 20 20 20 20 20 20 20 24 73 79 6e 6f 70 73 69 73 20 3d 20 73 70 72 69 6e 74 | on));.........$synopsis.=.sprint |
80680 | 66 28 27 25 73 25 73 27 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 70 74 69 6f 6e 2d 3e 67 | f('%s%s',.............$option->g |
806a0 | 65 74 53 68 6f 72 74 63 75 74 28 29 20 3f 20 73 70 72 69 6e 74 66 28 27 2d 25 73 2c 20 27 2c 20 | etShortcut().?.sprintf('-%s,.',. |
806c0 | 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 53 68 6f 72 74 63 75 74 28 29 29 20 3a 20 27 20 20 20 20 27 | $option->getShortcut()).:.'....' |
806e0 | 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 73 70 72 69 6e 74 66 28 27 2d 2d 25 73 25 73 27 2c 20 | ,.............sprintf('--%s%s',. |
80700 | 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 4e 61 6d 65 28 29 2c 20 24 76 61 6c 75 65 29 0a 20 20 20 20 | $option->getName(),.$value)..... |
80720 | 20 20 20 20 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 73 70 61 63 69 6e 67 57 69 64 74 68 20 3d 20 | ....);..........$spacingWidth.=. |
80740 | 24 74 6f 74 61 6c 57 69 64 74 68 20 2d 20 73 74 72 6c 65 6e 28 24 73 79 6e 6f 70 73 69 73 29 20 | $totalWidth.-.strlen($synopsis). |
80760 | 2b 20 32 3b 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 54 65 78 74 28 73 | +.2;..........$this->writeText(s |
80780 | 70 72 69 6e 74 66 28 27 20 20 3c 69 6e 66 6f 3e 25 73 3c 2f 69 6e 66 6f 3e 25 73 25 73 25 73 25 | printf('..<info>%s</info>%s%s%s% |
807a0 | 73 27 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 73 79 6e 6f 70 73 69 73 2c 0a 20 20 20 20 20 | s',.............$synopsis,...... |
807c0 | 20 20 20 20 20 20 20 73 74 72 5f 72 65 70 65 61 74 28 27 20 27 2c 20 24 73 70 61 63 69 6e 67 57 | .......str_repeat('.',.$spacingW |
807e0 | 69 64 74 68 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 2b 20 31 37 20 3d 20 32 20 73 | idth),.............//.+.17.=.2.s |
80800 | 70 61 63 65 73 20 2b 20 3c 69 6e 66 6f 3e 20 2b 20 3c 2f 69 6e 66 6f 3e 20 2b 20 32 20 73 70 61 | paces.+.<info>.+.</info>.+.2.spa |
80820 | 63 65 73 0a 20 20 20 20 20 20 20 20 20 20 20 20 70 72 65 67 5f 72 65 70 6c 61 63 65 28 27 2f 5c | ces.............preg_replace('/\ |
80840 | 73 2a 5b 5c 72 5c 6e 5d 5c 73 2a 2f 27 2c 20 22 5c 6e 22 2e 73 74 72 5f 72 65 70 65 61 74 28 27 | s*[\r\n]\s*/',."\n".str_repeat(' |
80860 | 20 27 2c 20 24 74 6f 74 61 6c 57 69 64 74 68 20 2b 20 31 37 29 2c 20 24 6f 70 74 69 6f 6e 2d 3e | .',.$totalWidth.+.17),.$option-> |
80880 | 67 65 74 44 65 73 63 72 69 70 74 69 6f 6e 28 29 29 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 | getDescription()),.............$ |
808a0 | 64 65 66 61 75 6c 74 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 70 74 69 6f 6e 2d 3e 69 73 | default,.............$option->is |
808c0 | 41 72 72 61 79 28 29 20 3f 20 27 3c 63 6f 6d 6d 65 6e 74 3e 20 28 6d 75 6c 74 69 70 6c 65 20 76 | Array().?.'<comment>.(multiple.v |
808e0 | 61 6c 75 65 73 20 61 6c 6c 6f 77 65 64 29 3c 2f 63 6f 6d 6d 65 6e 74 3e 27 20 3a 20 27 27 0a 20 | alues.allowed)</comment>'.:.''.. |
80900 | 20 20 20 20 20 20 20 29 2c 20 24 6f 70 74 69 6f 6e 73 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 | .......),.$options);.....}...... |
80920 | 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f | /**......*.{@inheritdoc}......*/ |
80940 | 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 64 65 73 63 72 69 62 65 | .....protected.function.describe |
80960 | 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 28 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 20 | InputDefinition(InputDefinition. |
80980 | 24 64 65 66 69 6e 69 74 69 6f 6e 2c 20 61 72 72 61 79 20 24 6f 70 74 69 6f 6e 73 20 3d 20 61 72 | $definition,.array.$options.=.ar |
809a0 | 72 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 6f 74 61 6c 57 69 64 74 68 | ray()).....{.........$totalWidth |
809c0 | 20 3d 20 24 74 68 69 73 2d 3e 63 61 6c 63 75 6c 61 74 65 54 6f 74 61 6c 57 69 64 74 68 46 6f 72 | .=.$this->calculateTotalWidthFor |
809e0 | 4f 70 74 69 6f 6e 73 28 24 64 65 66 69 6e 69 74 69 6f 6e 2d 3e 67 65 74 4f 70 74 69 6f 6e 73 28 | Options($definition->getOptions( |
80a00 | 29 29 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 64 65 66 69 6e 69 74 69 6f 6e | ));.........foreach.($definition |
80a20 | 2d 3e 67 65 74 41 72 67 75 6d 65 6e 74 73 28 29 20 61 73 20 24 61 72 67 75 6d 65 6e 74 29 20 7b | ->getArguments().as.$argument).{ |
80a40 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 6f 74 61 6c 57 69 64 74 68 20 3d 20 6d 61 78 28 24 | .............$totalWidth.=.max($ |
80a60 | 74 6f 74 61 6c 57 69 64 74 68 2c 20 73 74 72 6c 65 6e 28 24 61 72 67 75 6d 65 6e 74 2d 3e 67 65 | totalWidth,.strlen($argument->ge |
80a80 | 74 4e 61 6d 65 28 29 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 | tName()));.........}..........if |
80aa0 | 20 28 24 64 65 66 69 6e 69 74 69 6f 6e 2d 3e 67 65 74 41 72 67 75 6d 65 6e 74 73 28 29 29 20 7b | .($definition->getArguments()).{ |
80ac0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 54 65 78 74 28 27 3c | .............$this->writeText('< |
80ae0 | 63 6f 6d 6d 65 6e 74 3e 41 72 67 75 6d 65 6e 74 73 3a 3c 2f 63 6f 6d 6d 65 6e 74 3e 27 2c 20 24 | comment>Arguments:</comment>',.$ |
80b00 | 6f 70 74 69 6f 6e 73 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 | options);.............$this->wri |
80b20 | 74 65 54 65 78 74 28 22 5c 6e 22 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 | teText("\n");.............foreac |
80b40 | 68 20 28 24 64 65 66 69 6e 69 74 69 6f 6e 2d 3e 67 65 74 41 72 67 75 6d 65 6e 74 73 28 29 20 61 | h.($definition->getArguments().a |
80b60 | 73 20 24 61 72 67 75 6d 65 6e 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 | s.$argument).{.................$ |
80b80 | 74 68 69 73 2d 3e 64 65 73 63 72 69 62 65 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 28 24 61 72 67 | this->describeInputArgument($arg |
80ba0 | 75 6d 65 6e 74 2c 20 61 72 72 61 79 5f 6d 65 72 67 65 28 24 6f 70 74 69 6f 6e 73 2c 20 61 72 72 | ument,.array_merge($options,.arr |
80bc0 | 61 79 28 27 74 6f 74 61 6c 5f 77 69 64 74 68 27 20 3d 3e 20 24 74 6f 74 61 6c 57 69 64 74 68 29 | ay('total_width'.=>.$totalWidth) |
80be0 | 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 | ));.................$this->write |
80c00 | 54 65 78 74 28 22 5c 6e 22 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 | Text("\n");.............}....... |
80c20 | 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 64 65 66 69 6e 69 74 69 6f 6e 2d 3e 67 65 | ..}..........if.($definition->ge |
80c40 | 74 41 72 67 75 6d 65 6e 74 73 28 29 20 26 26 20 24 64 65 66 69 6e 69 74 69 6f 6e 2d 3e 67 65 74 | tArguments().&&.$definition->get |
80c60 | 4f 70 74 69 6f 6e 73 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e | Options()).{.............$this-> |
80c80 | 77 72 69 74 65 54 65 78 74 28 22 5c 6e 22 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 | writeText("\n");.........}...... |
80ca0 | 20 20 20 20 69 66 20 28 24 64 65 66 69 6e 69 74 69 6f 6e 2d 3e 67 65 74 4f 70 74 69 6f 6e 73 28 | ....if.($definition->getOptions( |
80cc0 | 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 61 74 65 72 4f 70 74 69 6f 6e 73 20 3d | )).{.............$laterOptions.= |
80ce0 | 20 61 72 72 61 79 28 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 | .array();..............$this->wr |
80d00 | 69 74 65 54 65 78 74 28 27 3c 63 6f 6d 6d 65 6e 74 3e 4f 70 74 69 6f 6e 73 3a 3c 2f 63 6f 6d 6d | iteText('<comment>Options:</comm |
80d20 | 65 6e 74 3e 27 2c 20 24 6f 70 74 69 6f 6e 73 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 66 6f | ent>',.$options);.............fo |
80d40 | 72 65 61 63 68 20 28 24 64 65 66 69 6e 69 74 69 6f 6e 2d 3e 67 65 74 4f 70 74 69 6f 6e 73 28 29 | reach.($definition->getOptions() |
80d60 | 20 61 73 20 24 6f 70 74 69 6f 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 | .as.$option).{.................i |
80d80 | 66 20 28 73 74 72 6c 65 6e 28 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 53 68 6f 72 74 63 75 74 28 29 | f.(strlen($option->getShortcut() |
80da0 | 29 20 3e 20 31 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 61 | ).>.1).{.....................$la |
80dc0 | 74 65 72 4f 70 74 69 6f 6e 73 5b 5d 20 3d 20 24 6f 70 74 69 6f 6e 3b 0a 20 20 20 20 20 20 20 20 | terOptions[].=.$option;......... |
80de0 | 20 20 20 20 20 20 20 20 20 20 20 20 63 6f 6e 74 69 6e 75 65 3b 0a 20 20 20 20 20 20 20 20 20 20 | ............continue;........... |
80e00 | 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 | ......}.................$this->w |
80e20 | 72 69 74 65 54 65 78 74 28 22 5c 6e 22 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | riteText("\n");................. |
80e40 | 24 74 68 69 73 2d 3e 64 65 73 63 72 69 62 65 49 6e 70 75 74 4f 70 74 69 6f 6e 28 24 6f 70 74 69 | $this->describeInputOption($opti |
80e60 | 6f 6e 2c 20 61 72 72 61 79 5f 6d 65 72 67 65 28 24 6f 70 74 69 6f 6e 73 2c 20 61 72 72 61 79 28 | on,.array_merge($options,.array( |
80e80 | 27 74 6f 74 61 6c 5f 77 69 64 74 68 27 20 3d 3e 20 24 74 6f 74 61 6c 57 69 64 74 68 29 29 29 3b | 'total_width'.=>.$totalWidth))); |
80ea0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 | .............}.............forea |
80ec0 | 63 68 20 28 24 6c 61 74 65 72 4f 70 74 69 6f 6e 73 20 61 73 20 24 6f 70 74 69 6f 6e 29 20 7b 0a | ch.($laterOptions.as.$option).{. |
80ee0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 54 65 78 74 | ................$this->writeText |
80f00 | 28 22 5c 6e 22 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 64 | ("\n");.................$this->d |
80f20 | 65 73 63 72 69 62 65 49 6e 70 75 74 4f 70 74 69 6f 6e 28 24 6f 70 74 69 6f 6e 2c 20 61 72 72 61 | escribeInputOption($option,.arra |
80f40 | 79 5f 6d 65 72 67 65 28 24 6f 70 74 69 6f 6e 73 2c 20 61 72 72 61 79 28 27 74 6f 74 61 6c 5f 77 | y_merge($options,.array('total_w |
80f60 | 69 64 74 68 27 20 3d 3e 20 24 74 6f 74 61 6c 57 69 64 74 68 29 29 29 3b 0a 20 20 20 20 20 20 20 | idth'.=>.$totalWidth)));........ |
80f80 | 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a | .....}.........}.....}....../**. |
80fa0 | 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 | .....*.{@inheritdoc}......*/.... |
80fc0 | 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 64 65 73 63 72 69 62 65 43 6f 6d 6d | .protected.function.describeComm |
80fe0 | 61 6e 64 28 43 6f 6d 6d 61 6e 64 20 24 63 6f 6d 6d 61 6e 64 2c 20 61 72 72 61 79 20 24 6f 70 74 | and(Command.$command,.array.$opt |
81000 | 69 6f 6e 73 20 3d 20 61 72 72 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 63 | ions.=.array()).....{.........$c |
81020 | 6f 6d 6d 61 6e 64 2d 3e 67 65 74 53 79 6e 6f 70 73 69 73 28 74 72 75 65 29 3b 0a 20 20 20 20 20 | ommand->getSynopsis(true);...... |
81040 | 20 20 20 24 63 6f 6d 6d 61 6e 64 2d 3e 67 65 74 53 79 6e 6f 70 73 69 73 28 66 61 6c 73 65 29 3b | ...$command->getSynopsis(false); |
81060 | 0a 20 20 20 20 20 20 20 20 24 63 6f 6d 6d 61 6e 64 2d 3e 6d 65 72 67 65 41 70 70 6c 69 63 61 74 | .........$command->mergeApplicat |
81080 | 69 6f 6e 44 65 66 69 6e 69 74 69 6f 6e 28 66 61 6c 73 65 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 | ionDefinition(false);..........$ |
810a0 | 74 68 69 73 2d 3e 77 72 69 74 65 54 65 78 74 28 27 3c 63 6f 6d 6d 65 6e 74 3e 55 73 61 67 65 3a | this->writeText('<comment>Usage: |
810c0 | 3c 2f 63 6f 6d 6d 65 6e 74 3e 27 2c 20 24 6f 70 74 69 6f 6e 73 29 3b 0a 20 20 20 20 20 20 20 20 | </comment>',.$options);......... |
810e0 | 66 6f 72 65 61 63 68 20 28 61 72 72 61 79 5f 6d 65 72 67 65 28 61 72 72 61 79 28 24 63 6f 6d 6d | foreach.(array_merge(array($comm |
81100 | 61 6e 64 2d 3e 67 65 74 53 79 6e 6f 70 73 69 73 28 74 72 75 65 29 29 2c 20 24 63 6f 6d 6d 61 6e | and->getSynopsis(true)),.$comman |
81120 | 64 2d 3e 67 65 74 41 6c 69 61 73 65 73 28 29 2c 20 24 63 6f 6d 6d 61 6e 64 2d 3e 67 65 74 55 73 | d->getAliases(),.$command->getUs |
81140 | 61 67 65 73 28 29 29 20 61 73 20 24 75 73 61 67 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | ages()).as.$usage).{............ |
81160 | 20 24 74 68 69 73 2d 3e 77 72 69 74 65 54 65 78 74 28 22 5c 6e 22 29 3b 0a 20 20 20 20 20 20 20 | .$this->writeText("\n");........ |
81180 | 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 54 65 78 74 28 27 20 20 27 2e 24 75 73 61 67 | .....$this->writeText('..'.$usag |
811a0 | 65 2c 20 24 6f 70 74 69 6f 6e 73 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 | e,.$options);.........}......... |
811c0 | 24 74 68 69 73 2d 3e 77 72 69 74 65 54 65 78 74 28 22 5c 6e 22 29 3b 0a 0a 20 20 20 20 20 20 20 | $this->writeText("\n");......... |
811e0 | 20 24 64 65 66 69 6e 69 74 69 6f 6e 20 3d 20 24 63 6f 6d 6d 61 6e 64 2d 3e 67 65 74 4e 61 74 69 | .$definition.=.$command->getNati |
81200 | 76 65 44 65 66 69 6e 69 74 69 6f 6e 28 29 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 64 65 66 | veDefinition();.........if.($def |
81220 | 69 6e 69 74 69 6f 6e 2d 3e 67 65 74 4f 70 74 69 6f 6e 73 28 29 20 7c 7c 20 24 64 65 66 69 6e 69 | inition->getOptions().||.$defini |
81240 | 74 69 6f 6e 2d 3e 67 65 74 41 72 67 75 6d 65 6e 74 73 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 | tion->getArguments()).{......... |
81260 | 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 54 65 78 74 28 22 5c 6e 22 29 3b 0a 20 20 20 20 | ....$this->writeText("\n");..... |
81280 | 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 64 65 73 63 72 69 62 65 49 6e 70 75 74 44 65 66 69 | ........$this->describeInputDefi |
812a0 | 6e 69 74 69 6f 6e 28 24 64 65 66 69 6e 69 74 69 6f 6e 2c 20 24 6f 70 74 69 6f 6e 73 29 3b 0a 20 | nition($definition,.$options);.. |
812c0 | 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 54 65 78 74 28 22 5c 6e 22 | ...........$this->writeText("\n" |
812e0 | 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 68 65 6c 70 20 | );.........}..........if.($help. |
81300 | 3d 20 24 63 6f 6d 6d 61 6e 64 2d 3e 67 65 74 50 72 6f 63 65 73 73 65 64 48 65 6c 70 28 29 29 20 | =.$command->getProcessedHelp()). |
81320 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 54 65 78 74 28 22 | {.............$this->writeText(" |
81340 | 5c 6e 22 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 54 65 | \n");.............$this->writeTe |
81360 | 78 74 28 27 3c 63 6f 6d 6d 65 6e 74 3e 48 65 6c 70 3a 3c 2f 63 6f 6d 6d 65 6e 74 3e 27 2c 20 24 | xt('<comment>Help:</comment>',.$ |
81380 | 6f 70 74 69 6f 6e 73 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 | options);.............$this->wri |
813a0 | 74 65 54 65 78 74 28 22 5c 6e 22 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d | teText("\n");.............$this- |
813c0 | 3e 77 72 69 74 65 54 65 78 74 28 27 20 20 27 2e 73 74 72 5f 72 65 70 6c 61 63 65 28 22 5c 6e 22 | >writeText('..'.str_replace("\n" |
813e0 | 2c 20 22 5c 6e 20 20 22 2c 20 24 68 65 6c 70 29 2c 20 24 6f 70 74 69 6f 6e 73 29 3b 0a 20 20 20 | ,."\n..",.$help),.$options);.... |
81400 | 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 54 65 78 74 28 22 5c 6e 22 29 3b | .........$this->writeText("\n"); |
81420 | 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a | .........}.....}....../**......* |
81440 | 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 6f 74 65 | .{@inheritdoc}......*/.....prote |
81460 | 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 64 65 73 63 72 69 62 65 41 70 70 6c 69 63 61 74 69 6f | cted.function.describeApplicatio |
81480 | 6e 28 41 70 70 6c 69 63 61 74 69 6f 6e 20 24 61 70 70 6c 69 63 61 74 69 6f 6e 2c 20 61 72 72 61 | n(Application.$application,.arra |
814a0 | 79 20 24 6f 70 74 69 6f 6e 73 20 3d 20 61 72 72 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 | y.$options.=.array()).....{..... |
814c0 | 20 20 20 20 24 64 65 73 63 72 69 62 65 64 4e 61 6d 65 73 70 61 63 65 20 3d 20 69 73 73 65 74 28 | ....$describedNamespace.=.isset( |
814e0 | 24 6f 70 74 69 6f 6e 73 5b 27 6e 61 6d 65 73 70 61 63 65 27 5d 29 20 3f 20 24 6f 70 74 69 6f 6e | $options['namespace']).?.$option |
81500 | 73 5b 27 6e 61 6d 65 73 70 61 63 65 27 5d 20 3a 20 6e 75 6c 6c 3b 0a 20 20 20 20 20 20 20 20 24 | s['namespace'].:.null;.........$ |
81520 | 64 65 73 63 72 69 70 74 69 6f 6e 20 3d 20 6e 65 77 20 41 70 70 6c 69 63 61 74 69 6f 6e 44 65 73 | description.=.new.ApplicationDes |
81540 | 63 72 69 70 74 69 6f 6e 28 24 61 70 70 6c 69 63 61 74 69 6f 6e 2c 20 24 64 65 73 63 72 69 62 65 | cription($application,.$describe |
81560 | 64 4e 61 6d 65 73 70 61 63 65 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 69 73 73 65 74 28 | dNamespace);..........if.(isset( |
81580 | 24 6f 70 74 69 6f 6e 73 5b 27 72 61 77 5f 74 65 78 74 27 5d 29 20 26 26 20 24 6f 70 74 69 6f 6e | $options['raw_text']).&&.$option |
815a0 | 73 5b 27 72 61 77 5f 74 65 78 74 27 5d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 77 69 | s['raw_text']).{.............$wi |
815c0 | 64 74 68 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 43 6f 6c 75 6d 6e 57 69 64 74 68 28 24 64 65 73 | dth.=.$this->getColumnWidth($des |
815e0 | 63 72 69 70 74 69 6f 6e 2d 3e 67 65 74 43 6f 6d 6d 61 6e 64 73 28 29 29 3b 0a 0a 20 20 20 20 20 | cription->getCommands());....... |
81600 | 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 64 65 73 63 72 69 70 74 69 6f 6e 2d 3e 67 65 | .......foreach.($description->ge |
81620 | 74 43 6f 6d 6d 61 6e 64 73 28 29 20 61 73 20 24 63 6f 6d 6d 61 6e 64 29 20 7b 0a 20 20 20 20 20 | tCommands().as.$command).{...... |
81640 | 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 54 65 78 74 28 73 70 72 69 | ...........$this->writeText(spri |
81660 | 6e 74 66 28 22 25 2d 7b 24 77 69 64 74 68 7d 73 20 25 73 22 2c 20 24 63 6f 6d 6d 61 6e 64 2d 3e | ntf("%-{$width}s.%s",.$command-> |
81680 | 67 65 74 4e 61 6d 65 28 29 2c 20 24 63 6f 6d 6d 61 6e 64 2d 3e 67 65 74 44 65 73 63 72 69 70 74 | getName(),.$command->getDescript |
816a0 | 69 6f 6e 28 29 29 2c 20 24 6f 70 74 69 6f 6e 73 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | ion()),.$options);.............. |
816c0 | 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 54 65 78 74 28 22 5c 6e 22 29 3b 0a 20 20 20 20 20 | ...$this->writeText("\n");...... |
816e0 | 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 | .......}.........}.else.{....... |
81700 | 20 20 20 20 20 20 69 66 20 28 27 27 20 21 3d 20 24 68 65 6c 70 20 3d 20 24 61 70 70 6c 69 63 61 | ......if.(''.!=.$help.=.$applica |
81720 | 74 69 6f 6e 2d 3e 67 65 74 48 65 6c 70 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | tion->getHelp()).{.............. |
81740 | 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 54 65 78 74 28 22 24 68 65 6c 70 5c 6e 5c 6e 22 2c | ...$this->writeText("$help\n\n", |
81760 | 20 24 6f 70 74 69 6f 6e 73 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 | .$options);.............}....... |
81780 | 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 54 65 78 74 28 22 3c 63 6f 6d 6d 65 6e | .......$this->writeText("<commen |
817a0 | 74 3e 55 73 61 67 65 3a 3c 2f 63 6f 6d 6d 65 6e 74 3e 5c 6e 22 2c 20 24 6f 70 74 69 6f 6e 73 29 | t>Usage:</comment>\n",.$options) |
817c0 | 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 54 65 78 74 28 22 | ;.............$this->writeText(" |
817e0 | 20 20 63 6f 6d 6d 61 6e 64 20 5b 6f 70 74 69 6f 6e 73 5d 20 5b 61 72 67 75 6d 65 6e 74 73 5d 5c | ..command.[options].[arguments]\ |
81800 | 6e 5c 6e 22 2c 20 24 6f 70 74 69 6f 6e 73 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 | n\n",.$options);..............$t |
81820 | 68 69 73 2d 3e 64 65 73 63 72 69 62 65 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 28 6e 65 77 | his->describeInputDefinition(new |
81840 | 20 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 28 24 61 70 70 6c 69 63 61 74 69 6f 6e 2d 3e 67 | .InputDefinition($application->g |
81860 | 65 74 44 65 66 69 6e 69 74 69 6f 6e 28 29 2d 3e 67 65 74 4f 70 74 69 6f 6e 73 28 29 29 2c 20 24 | etDefinition()->getOptions()),.$ |
81880 | 6f 70 74 69 6f 6e 73 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 | options);..............$this->wr |
818a0 | 69 74 65 54 65 78 74 28 22 5c 6e 22 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 | iteText("\n");.............$this |
818c0 | 2d 3e 77 72 69 74 65 54 65 78 74 28 22 5c 6e 22 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ->writeText("\n");.............. |
818e0 | 24 77 69 64 74 68 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 43 6f 6c 75 6d 6e 57 69 64 74 68 28 24 | $width.=.$this->getColumnWidth($ |
81900 | 64 65 73 63 72 69 70 74 69 6f 6e 2d 3e 67 65 74 43 6f 6d 6d 61 6e 64 73 28 29 29 3b 0a 0a 20 20 | description->getCommands());.... |
81920 | 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 64 65 73 63 72 69 62 65 64 4e 61 6d 65 73 70 61 63 | ..........if.($describedNamespac |
81940 | 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 | e).{.................$this->writ |
81960 | 65 54 65 78 74 28 73 70 72 69 6e 74 66 28 27 3c 63 6f 6d 6d 65 6e 74 3e 41 76 61 69 6c 61 62 6c | eText(sprintf('<comment>Availabl |
81980 | 65 20 63 6f 6d 6d 61 6e 64 73 20 66 6f 72 20 74 68 65 20 22 25 73 22 20 6e 61 6d 65 73 70 61 63 | e.commands.for.the."%s".namespac |
819a0 | 65 3a 3c 2f 63 6f 6d 6d 65 6e 74 3e 27 2c 20 24 64 65 73 63 72 69 62 65 64 4e 61 6d 65 73 70 61 | e:</comment>',.$describedNamespa |
819c0 | 63 65 29 2c 20 24 6f 70 74 69 6f 6e 73 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c | ce),.$options);.............}.el |
819e0 | 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 | se.{.................$this->writ |
81a00 | 65 54 65 78 74 28 27 3c 63 6f 6d 6d 65 6e 74 3e 41 76 61 69 6c 61 62 6c 65 20 63 6f 6d 6d 61 6e | eText('<comment>Available.comman |
81a20 | 64 73 3a 3c 2f 63 6f 6d 6d 65 6e 74 3e 27 2c 20 24 6f 70 74 69 6f 6e 73 29 3b 0a 20 20 20 20 20 | ds:</comment>',.$options);...... |
81a40 | 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 61 64 64 20 63 6f 6d | .......}..............//.add.com |
81a60 | 6d 61 6e 64 73 20 62 79 20 6e 61 6d 65 73 70 61 63 65 0a 20 20 20 20 20 20 20 20 20 20 20 20 66 | mands.by.namespace.............f |
81a80 | 6f 72 65 61 63 68 20 28 24 64 65 73 63 72 69 70 74 69 6f 6e 2d 3e 67 65 74 4e 61 6d 65 73 70 61 | oreach.($description->getNamespa |
81aa0 | 63 65 73 28 29 20 61 73 20 24 6e 61 6d 65 73 70 61 63 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | ces().as.$namespace).{.......... |
81ac0 | 20 20 20 20 20 20 20 69 66 20 28 21 24 64 65 73 63 72 69 62 65 64 4e 61 6d 65 73 70 61 63 65 20 | .......if.(!$describedNamespace. |
81ae0 | 26 26 20 41 70 70 6c 69 63 61 74 69 6f 6e 44 65 73 63 72 69 70 74 69 6f 6e 3a 3a 47 4c 4f 42 41 | &&.ApplicationDescription::GLOBA |
81b00 | 4c 5f 4e 41 4d 45 53 50 41 43 45 20 21 3d 3d 20 24 6e 61 6d 65 73 70 61 63 65 5b 27 69 64 27 5d | L_NAMESPACE.!==.$namespace['id'] |
81b20 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 | ).{.....................$this->w |
81b40 | 72 69 74 65 54 65 78 74 28 22 5c 6e 22 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | riteText("\n");................. |
81b60 | 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 54 65 78 74 28 27 20 3c 63 6f 6d 6d 65 6e 74 3e | ....$this->writeText('.<comment> |
81b80 | 27 2e 24 6e 61 6d 65 73 70 61 63 65 5b 27 69 64 27 5d 2e 27 3c 2f 63 6f 6d 6d 65 6e 74 3e 27 2c | '.$namespace['id'].'</comment>', |
81ba0 | 20 24 6f 70 74 69 6f 6e 73 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 | .$options);.................}... |
81bc0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 6e 61 6d 65 73 70 61 | ...............foreach.($namespa |
81be0 | 63 65 5b 27 63 6f 6d 6d 61 6e 64 73 27 5d 20 61 73 20 24 6e 61 6d 65 29 20 7b 0a 20 20 20 20 20 | ce['commands'].as.$name).{...... |
81c00 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 69 74 65 54 65 78 74 28 | ...............$this->writeText( |
81c20 | 22 5c 6e 22 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 73 70 61 63 | "\n");.....................$spac |
81c40 | 69 6e 67 57 69 64 74 68 20 3d 20 24 77 69 64 74 68 20 2d 20 73 74 72 6c 65 6e 28 24 6e 61 6d 65 | ingWidth.=.$width.-.strlen($name |
81c60 | 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 77 72 | );.....................$this->wr |
81c80 | 69 74 65 54 65 78 74 28 73 70 72 69 6e 74 66 28 27 20 20 3c 69 6e 66 6f 3e 25 73 3c 2f 69 6e 66 | iteText(sprintf('..<info>%s</inf |
81ca0 | 6f 3e 25 73 25 73 27 2c 20 24 6e 61 6d 65 2c 20 73 74 72 5f 72 65 70 65 61 74 28 27 20 27 2c 20 | o>%s%s',.$name,.str_repeat('.',. |
81cc0 | 24 73 70 61 63 69 6e 67 57 69 64 74 68 29 2c 20 24 64 65 73 63 72 69 70 74 69 6f 6e 2d 3e 67 65 | $spacingWidth),.$description->ge |
81ce0 | 74 43 6f 6d 6d 61 6e 64 28 24 6e 61 6d 65 29 2d 3e 67 65 74 44 65 73 63 72 69 70 74 69 6f 6e 28 | tCommand($name)->getDescription( |
81d00 | 29 29 2c 20 24 6f 70 74 69 6f 6e 73 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d | )),.$options);.................} |
81d20 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 | .............}..............$thi |
81d40 | 73 2d 3e 77 72 69 74 65 54 65 78 74 28 22 5c 6e 22 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 | s->writeText("\n");.........}... |
81d60 | 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 | ..}....../**......*.{@inheritdoc |
81d80 | 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 77 | }......*/.....private.function.w |
81da0 | 72 69 74 65 54 65 78 74 28 24 63 6f 6e 74 65 6e 74 2c 20 61 72 72 61 79 20 24 6f 70 74 69 6f 6e | riteText($content,.array.$option |
81dc0 | 73 20 3d 20 61 72 72 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 | s.=.array()).....{.........$this |
81de0 | 2d 3e 77 72 69 74 65 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 73 73 65 74 28 24 6f 70 74 69 | ->write(.............isset($opti |
81e00 | 6f 6e 73 5b 27 72 61 77 5f 74 65 78 74 27 5d 29 20 26 26 20 24 6f 70 74 69 6f 6e 73 5b 27 72 61 | ons['raw_text']).&&.$options['ra |
81e20 | 77 5f 74 65 78 74 27 5d 20 3f 20 73 74 72 69 70 5f 74 61 67 73 28 24 63 6f 6e 74 65 6e 74 29 20 | w_text'].?.strip_tags($content). |
81e40 | 3a 20 24 63 6f 6e 74 65 6e 74 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 73 73 65 74 28 24 6f | :.$content,.............isset($o |
81e60 | 70 74 69 6f 6e 73 5b 27 72 61 77 5f 6f 75 74 70 75 74 27 5d 29 20 3f 20 21 24 6f 70 74 69 6f 6e | ptions['raw_output']).?.!$option |
81e80 | 73 5b 27 72 61 77 5f 6f 75 74 70 75 74 27 5d 20 3a 20 74 72 75 65 0a 20 20 20 20 20 20 20 20 29 | s['raw_output'].:.true.........) |
81ea0 | 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 46 6f 72 6d 61 74 73 20 | ;.....}....../**......*.Formats. |
81ec0 | 69 6e 70 75 74 20 6f 70 74 69 6f 6e 2f 61 72 67 75 6d 65 6e 74 20 64 65 66 61 75 6c 74 20 76 61 | input.option/argument.default.va |
81ee0 | 6c 75 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 6d 69 78 65 64 20 | lue.......*......*.@param.mixed. |
81f00 | 24 64 65 66 61 75 6c 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 | $default......*......*.@return.s |
81f20 | 74 72 69 6e 67 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 | tring......*/.....private.functi |
81f40 | 6f 6e 20 66 6f 72 6d 61 74 44 65 66 61 75 6c 74 56 61 6c 75 65 28 24 64 65 66 61 75 6c 74 29 0a | on.formatDefaultValue($default). |
81f60 | 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 74 72 5f 72 65 70 6c 61 63 65 | ....{.........return.str_replace |
81f80 | 28 27 5c 5c 5c 5c 27 2c 20 27 5c 5c 27 2c 20 6a 73 6f 6e 5f 65 6e 63 6f 64 65 28 24 64 65 66 61 | ('\\\\',.'\\',.json_encode($defa |
81fa0 | 75 6c 74 2c 20 4a 53 4f 4e 5f 55 4e 45 53 43 41 50 45 44 5f 53 4c 41 53 48 45 53 20 7c 20 4a 53 | ult,.JSON_UNESCAPED_SLASHES.|.JS |
81fc0 | 4f 4e 5f 55 4e 45 53 43 41 50 45 44 5f 55 4e 49 43 4f 44 45 29 29 3b 0a 20 20 20 20 7d 0a 0a 20 | ON_UNESCAPED_UNICODE));.....}... |
81fe0 | 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 43 6f 6d 6d 61 6e 64 5b 5d 20 24 | .../**......*.@param.Command[].$ |
82000 | 63 6f 6d 6d 61 6e 64 73 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 69 | commands......*......*.@return.i |
82020 | 6e 74 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 | nt......*/.....private.function. |
82040 | 67 65 74 43 6f 6c 75 6d 6e 57 69 64 74 68 28 61 72 72 61 79 20 24 63 6f 6d 6d 61 6e 64 73 29 0a | getColumnWidth(array.$commands). |
82060 | 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 77 69 64 74 68 73 20 3d 20 61 72 72 61 79 28 29 3b | ....{.........$widths.=.array(); |
82080 | 0a 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 63 6f 6d 6d 61 6e 64 73 20 61 73 20 | ..........foreach.($commands.as. |
820a0 | 24 63 6f 6d 6d 61 6e 64 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 77 69 64 74 68 73 5b | $command).{.............$widths[ |
820c0 | 5d 20 3d 20 73 74 72 6c 65 6e 28 24 63 6f 6d 6d 61 6e 64 2d 3e 67 65 74 4e 61 6d 65 28 29 29 3b | ].=.strlen($command->getName()); |
820e0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 63 6f 6d 6d 61 6e 64 2d 3e | .............foreach.($command-> |
82100 | 67 65 74 41 6c 69 61 73 65 73 28 29 20 61 73 20 24 61 6c 69 61 73 29 20 7b 0a 20 20 20 20 20 20 | getAliases().as.$alias).{....... |
82120 | 20 20 20 20 20 20 20 20 20 20 24 77 69 64 74 68 73 5b 5d 20 3d 20 73 74 72 6c 65 6e 28 24 61 6c | ..........$widths[].=.strlen($al |
82140 | 69 61 73 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 | ias);.............}.........}... |
82160 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6d 61 78 28 24 77 69 64 74 68 73 29 20 2b 20 32 3b 0a | .......return.max($widths).+.2;. |
82180 | 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 49 6e 70 | ....}....../**......*.@param.Inp |
821a0 | 75 74 4f 70 74 69 6f 6e 5b 5d 20 24 6f 70 74 69 6f 6e 73 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 | utOption[].$options......*...... |
821c0 | 2a 20 40 72 65 74 75 72 6e 20 69 6e 74 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 | *.@return.int......*/.....privat |
821e0 | 65 20 66 75 6e 63 74 69 6f 6e 20 63 61 6c 63 75 6c 61 74 65 54 6f 74 61 6c 57 69 64 74 68 46 6f | e.function.calculateTotalWidthFo |
82200 | 72 4f 70 74 69 6f 6e 73 28 24 6f 70 74 69 6f 6e 73 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 | rOptions($options).....{........ |
82220 | 20 24 74 6f 74 61 6c 57 69 64 74 68 20 3d 20 30 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 | .$totalWidth.=.0;.........foreac |
82240 | 68 20 28 24 6f 70 74 69 6f 6e 73 20 61 73 20 24 6f 70 74 69 6f 6e 29 20 7b 0a 20 20 20 20 20 20 | h.($options.as.$option).{....... |
82260 | 20 20 20 20 20 20 2f 2f 20 22 2d 22 20 2b 20 73 68 6f 72 74 63 75 74 20 2b 20 22 2c 20 2d 2d 22 | ......//."-".+.shortcut.+.",.--" |
82280 | 20 2b 20 6e 61 6d 65 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6e 61 6d 65 4c 65 6e 67 74 68 20 | .+.name.............$nameLength. |
822a0 | 3d 20 31 20 2b 20 6d 61 78 28 73 74 72 6c 65 6e 28 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 53 68 6f | =.1.+.max(strlen($option->getSho |
822c0 | 72 74 63 75 74 28 29 29 2c 20 31 29 20 2b 20 34 20 2b 20 73 74 72 6c 65 6e 28 24 6f 70 74 69 6f | rtcut()),.1).+.4.+.strlen($optio |
822e0 | 6e 2d 3e 67 65 74 4e 61 6d 65 28 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 | n->getName());..............if.( |
82300 | 24 6f 70 74 69 6f 6e 2d 3e 61 63 63 65 70 74 56 61 6c 75 65 28 29 29 20 7b 0a 20 20 20 20 20 20 | $option->acceptValue()).{....... |
82320 | 20 20 20 20 20 20 20 20 20 20 24 76 61 6c 75 65 4c 65 6e 67 74 68 20 3d 20 31 20 2b 20 73 74 72 | ..........$valueLength.=.1.+.str |
82340 | 6c 65 6e 28 24 6f 70 74 69 6f 6e 2d 3e 67 65 74 4e 61 6d 65 28 29 29 3b 20 2f 2f 20 3d 20 2b 20 | len($option->getName());.//.=.+. |
82360 | 76 61 6c 75 65 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 76 61 6c 75 65 4c 65 6e 67 | value.................$valueLeng |
82380 | 74 68 20 2b 3d 20 24 6f 70 74 69 6f 6e 2d 3e 69 73 56 61 6c 75 65 4f 70 74 69 6f 6e 61 6c 28 29 | th.+=.$option->isValueOptional() |
823a0 | 20 3f 20 32 20 3a 20 30 3b 20 2f 2f 20 5b 20 2b 20 5d 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 | .?.2.:.0;.//.[.+.].............. |
823c0 | 20 20 20 20 24 6e 61 6d 65 4c 65 6e 67 74 68 20 2b 3d 20 24 76 61 6c 75 65 4c 65 6e 67 74 68 3b | ....$nameLength.+=.$valueLength; |
823e0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 6f 74 61 | .............}.............$tota |
82400 | 6c 57 69 64 74 68 20 3d 20 6d 61 78 28 24 74 6f 74 61 6c 57 69 64 74 68 2c 20 24 6e 61 6d 65 4c | lWidth.=.max($totalWidth,.$nameL |
82420 | 65 6e 67 74 68 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 | ength);.........}..........retur |
82440 | 6e 20 24 74 6f 74 61 6c 57 69 64 74 68 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a | n.$totalWidth;.....}.}.<?php../* |
82460 | 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d | ..*.This.file.is.part.of.the.Sym |
82480 | 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 | fony.package...*..*.(c).Fabien.P |
824a0 | 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a | otencier.<fabien@symfony.com>..* |
824c0 | 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c | ..*.For.the.full.copyright.and.l |
824e0 | 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 | icense.information,.please.view. |
82500 | 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 | the.LICENSE..*.file.that.was.dis |
82520 | 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a | tributed.with.this.source.code.. |
82540 | 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 | .*/..namespace.Symfony\Component |
82560 | 5c 43 6f 6e 73 6f 6c 65 5c 44 65 73 63 72 69 70 74 6f 72 3b 0a 0a 75 73 65 20 53 79 6d 66 6f 6e | \Console\Descriptor;..use.Symfon |
82580 | 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 41 70 70 6c 69 63 61 74 69 6f 6e 3b | y\Component\Console\Application; |
825a0 | 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 43 | .use.Symfony\Component\Console\C |
825c0 | 6f 6d 6d 61 6e 64 5c 43 6f 6d 6d 61 6e 64 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 | ommand\Command;.use.Symfony\Comp |
825e0 | 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 5c 49 6e 70 75 74 41 72 67 75 6d 65 6e | onent\Console\Input\InputArgumen |
82600 | 74 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 | t;.use.Symfony\Component\Console |
82620 | 5c 49 6e 70 75 74 5c 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 3b 0a 75 73 65 20 53 79 6d 66 | \Input\InputDefinition;.use.Symf |
82640 | 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 5c 49 6e 70 75 | ony\Component\Console\Input\Inpu |
82660 | 74 4f 70 74 69 6f 6e 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 | tOption;.use.Symfony\Component\C |
82680 | 6f 6e 73 6f 6c 65 5c 4f 75 74 70 75 74 5c 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 3b 0a 75 | onsole\Output\OutputInterface;.u |
826a0 | 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 78 63 | se.Symfony\Component\Console\Exc |
826c0 | 65 70 74 69 6f 6e 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 3b | eption\InvalidArgumentException; |
826e0 | 0a 0a 2f 2a 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 4a 65 61 6e 2d 46 72 61 6e c3 a7 6f 69 73 20 | ../**..*.@author.Jean-Fran..ois. |
82700 | 53 69 6d 6f 6e 20 3c 6a 65 61 6e 66 72 61 6e 63 6f 69 73 2e 73 69 6d 6f 6e 40 73 65 6e 73 69 6f | Simon.<jeanfrancois.simon@sensio |
82720 | 6c 61 62 73 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 40 69 6e 74 65 72 6e 61 6c 0a 20 2a 2f 0a 61 62 | labs.com>..*..*.@internal..*/.ab |
82740 | 73 74 72 61 63 74 20 63 6c 61 73 73 20 44 65 73 63 72 69 70 74 6f 72 20 69 6d 70 6c 65 6d 65 6e | stract.class.Descriptor.implemen |
82760 | 74 73 20 44 65 73 63 72 69 70 74 6f 72 49 6e 74 65 72 66 61 63 65 0a 7b 0a 20 20 20 20 2f 2a 2a | ts.DescriptorInterface.{...../** |
82780 | 0a 20 20 20 20 20 2a 20 40 76 61 72 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 0a 20 20 20 | ......*.@var.OutputInterface.... |
827a0 | 20 20 2a 2f 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 24 6f 75 74 70 75 74 3b 0a 0a 20 20 20 | ..*/.....protected.$output;..... |
827c0 | 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a | ./**......*.{@inheritdoc}......* |
827e0 | 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 64 65 73 63 72 69 62 65 28 4f | /.....public.function.describe(O |
82800 | 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 2c 20 24 6f 62 6a 65 63 74 2c | utputInterface.$output,.$object, |
82820 | 20 61 72 72 61 79 20 24 6f 70 74 69 6f 6e 73 20 3d 20 61 72 72 61 79 28 29 29 0a 20 20 20 20 7b | .array.$options.=.array()).....{ |
82840 | 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 20 3d 20 24 6f 75 74 70 75 74 | .........$this->output.=.$output |
82860 | 3b 0a 0a 20 20 20 20 20 20 20 20 73 77 69 74 63 68 20 28 74 72 75 65 29 20 7b 0a 20 20 20 20 20 | ;..........switch.(true).{...... |
82880 | 20 20 20 20 20 20 20 63 61 73 65 20 24 6f 62 6a 65 63 74 20 69 6e 73 74 61 6e 63 65 6f 66 20 49 | .......case.$object.instanceof.I |
828a0 | 6e 70 75 74 41 72 67 75 6d 65 6e 74 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 | nputArgument:.................$t |
828c0 | 68 69 73 2d 3e 64 65 73 63 72 69 62 65 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 28 24 6f 62 6a 65 | his->describeInputArgument($obje |
828e0 | 63 74 2c 20 24 6f 70 74 69 6f 6e 73 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 62 | ct,.$options);.................b |
82900 | 72 65 61 6b 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 63 61 73 65 20 24 6f 62 6a 65 63 74 20 69 | reak;.............case.$object.i |
82920 | 6e 73 74 61 6e 63 65 6f 66 20 49 6e 70 75 74 4f 70 74 69 6f 6e 3a 0a 20 20 20 20 20 20 20 20 20 | nstanceof.InputOption:.......... |
82940 | 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 64 65 73 63 72 69 62 65 49 6e 70 75 74 4f 70 74 69 6f | .......$this->describeInputOptio |
82960 | 6e 28 24 6f 62 6a 65 63 74 2c 20 24 6f 70 74 69 6f 6e 73 29 3b 0a 20 20 20 20 20 20 20 20 20 20 | n($object,.$options);........... |
82980 | 20 20 20 20 20 20 62 72 65 61 6b 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 63 61 73 65 20 24 6f | ......break;.............case.$o |
829a0 | 62 6a 65 63 74 20 69 6e 73 74 61 6e 63 65 6f 66 20 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e | bject.instanceof.InputDefinition |
829c0 | 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 64 65 73 63 72 69 62 | :.................$this->describ |
829e0 | 65 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 28 24 6f 62 6a 65 63 74 2c 20 24 6f 70 74 69 6f | eInputDefinition($object,.$optio |
82a00 | 6e 73 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 62 72 65 61 6b 3b 0a 20 20 20 20 | ns);.................break;..... |
82a20 | 20 20 20 20 20 20 20 20 63 61 73 65 20 24 6f 62 6a 65 63 74 20 69 6e 73 74 61 6e 63 65 6f 66 20 | ........case.$object.instanceof. |
82a40 | 43 6f 6d 6d 61 6e 64 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e | Command:.................$this-> |
82a60 | 64 65 73 63 72 69 62 65 43 6f 6d 6d 61 6e 64 28 24 6f 62 6a 65 63 74 2c 20 24 6f 70 74 69 6f 6e | describeCommand($object,.$option |
82a80 | 73 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 62 72 65 61 6b 3b 0a 20 20 20 20 20 | s);.................break;...... |
82aa0 | 20 20 20 20 20 20 20 63 61 73 65 20 24 6f 62 6a 65 63 74 20 69 6e 73 74 61 6e 63 65 6f 66 20 41 | .......case.$object.instanceof.A |
82ac0 | 70 70 6c 69 63 61 74 69 6f 6e 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 | pplication:.................$thi |
82ae0 | 73 2d 3e 64 65 73 63 72 69 62 65 41 70 70 6c 69 63 61 74 69 6f 6e 28 24 6f 62 6a 65 63 74 2c 20 | s->describeApplication($object,. |
82b00 | 24 6f 70 74 69 6f 6e 73 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 62 72 65 61 6b | $options);.................break |
82b20 | 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 64 65 66 61 75 6c 74 3a 0a 20 20 20 20 20 20 20 20 20 | ;.............default:.......... |
82b40 | 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 | .......throw.new.InvalidArgument |
82b60 | 45 78 63 65 70 74 69 6f 6e 28 73 70 72 69 6e 74 66 28 27 4f 62 6a 65 63 74 20 6f 66 20 74 79 70 | Exception(sprintf('Object.of.typ |
82b80 | 65 20 22 25 73 22 20 69 73 20 6e 6f 74 20 64 65 73 63 72 69 62 61 62 6c 65 2e 27 2c 20 67 65 74 | e."%s".is.not.describable.',.get |
82ba0 | 5f 63 6c 61 73 73 28 24 6f 62 6a 65 63 74 29 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 | _class($object)));.........}.... |
82bc0 | 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 57 72 69 74 65 73 20 63 6f 6e 74 65 6e | .}....../**......*.Writes.conten |
82be0 | 74 20 74 6f 20 6f 75 74 70 75 74 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 | t.to.output.......*......*.@para |
82c00 | 6d 20 73 74 72 69 6e 67 20 24 63 6f 6e 74 65 6e 74 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 | m.string.$content......*.@param. |
82c20 | 62 6f 6f 6c 20 20 20 24 64 65 63 6f 72 61 74 65 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 | bool...$decorated......*/.....pr |
82c40 | 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 77 72 69 74 65 28 24 63 6f 6e 74 65 6e 74 2c | otected.function.write($content, |
82c60 | 20 24 64 65 63 6f 72 61 74 65 64 20 3d 20 66 61 6c 73 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 | .$decorated.=.false).....{...... |
82c80 | 20 20 20 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 28 24 63 6f 6e 74 65 6e 74 | ...$this->output->write($content |
82ca0 | 2c 20 66 61 6c 73 65 2c 20 24 64 65 63 6f 72 61 74 65 64 20 3f 20 4f 75 74 70 75 74 49 6e 74 65 | ,.false,.$decorated.?.OutputInte |
82cc0 | 72 66 61 63 65 3a 3a 4f 55 54 50 55 54 5f 4e 4f 52 4d 41 4c 20 3a 20 4f 75 74 70 75 74 49 6e 74 | rface::OUTPUT_NORMAL.:.OutputInt |
82ce0 | 65 72 66 61 63 65 3a 3a 4f 55 54 50 55 54 5f 52 41 57 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 | erface::OUTPUT_RAW);.....}...... |
82d00 | 2f 2a 2a 0a 20 20 20 20 20 2a 20 44 65 73 63 72 69 62 65 73 20 61 6e 20 49 6e 70 75 74 41 72 67 | /**......*.Describes.an.InputArg |
82d20 | 75 6d 65 6e 74 20 69 6e 73 74 61 6e 63 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 | ument.instance.......*......*.@p |
82d40 | 61 72 61 6d 20 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 20 24 61 72 67 75 6d 65 6e 74 0a 20 20 20 | aram.InputArgument.$argument.... |
82d60 | 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 20 20 20 20 20 20 20 20 24 6f 70 74 69 6f 6e | ..*.@param.array.........$option |
82d80 | 73 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 7c 6d | s......*......*.@return.string|m |
82da0 | 69 78 65 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 61 62 73 74 72 61 63 74 20 70 72 6f 74 65 63 | ixed......*/.....abstract.protec |
82dc0 | 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 64 65 73 63 72 69 62 65 49 6e 70 75 74 41 72 67 75 6d 65 | ted.function.describeInputArgume |
82de0 | 6e 74 28 49 6e 70 75 74 41 72 67 75 6d 65 6e 74 20 24 61 72 67 75 6d 65 6e 74 2c 20 61 72 72 61 | nt(InputArgument.$argument,.arra |
82e00 | 79 20 24 6f 70 74 69 6f 6e 73 20 3d 20 61 72 72 61 79 28 29 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a | y.$options.=.array());....../**. |
82e20 | 20 20 20 20 20 2a 20 44 65 73 63 72 69 62 65 73 20 61 6e 20 49 6e 70 75 74 4f 70 74 69 6f 6e 20 | .....*.Describes.an.InputOption. |
82e40 | 69 6e 73 74 61 6e 63 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 49 | instance.......*......*.@param.I |
82e60 | 6e 70 75 74 4f 70 74 69 6f 6e 20 24 6f 70 74 69 6f 6e 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d | nputOption.$option......*.@param |
82e80 | 20 61 72 72 61 79 20 20 20 20 20 20 20 24 6f 70 74 69 6f 6e 73 0a 20 20 20 20 20 2a 0a 20 20 20 | .array.......$options......*.... |
82ea0 | 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 7c 6d 69 78 65 64 0a 20 20 20 20 20 2a 2f | ..*.@return.string|mixed......*/ |
82ec0 | 0a 20 20 20 20 61 62 73 74 72 61 63 74 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e | .....abstract.protected.function |
82ee0 | 20 64 65 73 63 72 69 62 65 49 6e 70 75 74 4f 70 74 69 6f 6e 28 49 6e 70 75 74 4f 70 74 69 6f 6e | .describeInputOption(InputOption |
82f00 | 20 24 6f 70 74 69 6f 6e 2c 20 61 72 72 61 79 20 24 6f 70 74 69 6f 6e 73 20 3d 20 61 72 72 61 79 | .$option,.array.$options.=.array |
82f20 | 28 29 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 44 65 73 63 72 69 62 65 73 20 61 | ());....../**......*.Describes.a |
82f40 | 6e 20 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 20 69 6e 73 74 61 6e 63 65 2e 0a 20 20 20 20 | n.InputDefinition.instance...... |
82f60 | 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e | .*......*.@param.InputDefinition |
82f80 | 20 24 64 65 66 69 6e 69 74 69 6f 6e 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 | .$definition......*.@param.array |
82fa0 | 20 20 20 20 20 20 20 20 20 20 20 24 6f 70 74 69 6f 6e 73 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 | ...........$options......*...... |
82fc0 | 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 7c 6d 69 78 65 64 0a 20 20 20 20 20 2a 2f 0a 20 | *.@return.string|mixed......*/.. |
82fe0 | 20 20 20 61 62 73 74 72 61 63 74 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 64 | ...abstract.protected.function.d |
83000 | 65 73 63 72 69 62 65 49 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 28 49 6e 70 75 74 44 65 66 69 | escribeInputDefinition(InputDefi |
83020 | 6e 69 74 69 6f 6e 20 24 64 65 66 69 6e 69 74 69 6f 6e 2c 20 61 72 72 61 79 20 24 6f 70 74 69 6f | nition.$definition,.array.$optio |
83040 | 6e 73 20 3d 20 61 72 72 61 79 28 29 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 44 | ns.=.array());....../**......*.D |
83060 | 65 73 63 72 69 62 65 73 20 61 20 43 6f 6d 6d 61 6e 64 20 69 6e 73 74 61 6e 63 65 2e 0a 20 20 20 | escribes.a.Command.instance..... |
83080 | 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 43 6f 6d 6d 61 6e 64 20 24 63 6f 6d 6d 61 | ..*......*.@param.Command.$comma |
830a0 | 6e 64 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 20 20 24 6f 70 74 69 6f 6e | nd......*.@param.array...$option |
830c0 | 73 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 7c 6d | s......*......*.@return.string|m |
830e0 | 69 78 65 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 61 62 73 74 72 61 63 74 20 70 72 6f 74 65 63 | ixed......*/.....abstract.protec |
83100 | 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 64 65 73 63 72 69 62 65 43 6f 6d 6d 61 6e 64 28 43 6f 6d | ted.function.describeCommand(Com |
83120 | 6d 61 6e 64 20 24 63 6f 6d 6d 61 6e 64 2c 20 61 72 72 61 79 20 24 6f 70 74 69 6f 6e 73 20 3d 20 | mand.$command,.array.$options.=. |
83140 | 61 72 72 61 79 28 29 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 44 65 73 63 72 69 | array());....../**......*.Descri |
83160 | 62 65 73 20 61 6e 20 41 70 70 6c 69 63 61 74 69 6f 6e 20 69 6e 73 74 61 6e 63 65 2e 0a 20 20 20 | bes.an.Application.instance..... |
83180 | 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 41 70 70 6c 69 63 61 74 69 6f 6e 20 24 61 | ..*......*.@param.Application.$a |
831a0 | 70 70 6c 69 63 61 74 69 6f 6e 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 20 | pplication......*.@param.array.. |
831c0 | 20 20 20 20 20 24 6f 70 74 69 6f 6e 73 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 | .....$options......*......*.@ret |
831e0 | 75 72 6e 20 73 74 72 69 6e 67 7c 6d 69 78 65 64 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 61 62 73 | urn.string|mixed......*/.....abs |
83200 | 74 72 61 63 74 20 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 64 65 73 63 72 69 62 | tract.protected.function.describ |
83220 | 65 41 70 70 6c 69 63 61 74 69 6f 6e 28 41 70 70 6c 69 63 61 74 69 6f 6e 20 24 61 70 70 6c 69 63 | eApplication(Application.$applic |
83240 | 61 74 69 6f 6e 2c 20 61 72 72 61 79 20 24 6f 70 74 69 6f 6e 73 20 3d 20 61 72 72 61 79 28 29 29 | ation,.array.$options.=.array()) |
83260 | 3b 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 | ;.}.<?php../*..*.This.file.is.pa |
83280 | 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a | rt.of.the.Symfony.package...*..* |
832a0 | 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 | .(c).Fabien.Potencier.<fabien@sy |
832c0 | 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f | mfony.com>..*..*.For.the.full.co |
832e0 | 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c | pyright.and.license.information, |
83300 | 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 | .please.view.the.LICENSE..*.file |
83320 | 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 | .that.was.distributed.with.this. |
83340 | 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 | source.code...*/..namespace.Symf |
83360 | 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 54 65 73 74 65 72 3b 0a 0a 75 | ony\Component\Console\Tester;..u |
83380 | 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 41 70 70 | se.Symfony\Component\Console\App |
833a0 | 6c 69 63 61 74 69 6f 6e 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c | lication;.use.Symfony\Component\ |
833c0 | 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 5c 41 72 72 61 79 49 6e 70 75 74 3b 0a 75 73 65 20 53 79 | Console\Input\ArrayInput;.use.Sy |
833e0 | 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 5c 49 6e | mfony\Component\Console\Input\In |
83400 | 70 75 74 49 6e 74 65 72 66 61 63 65 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e | putInterface;.use.Symfony\Compon |
83420 | 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 4f 75 74 70 75 74 5c 43 6f 6e 73 6f 6c 65 4f 75 74 70 75 74 | ent\Console\Output\ConsoleOutput |
83440 | 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c | ;.use.Symfony\Component\Console\ |
83460 | 4f 75 74 70 75 74 5c 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 3b 0a 75 73 65 20 53 79 6d 66 | Output\OutputInterface;.use.Symf |
83480 | 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 4f 75 74 70 75 74 5c 53 74 72 | ony\Component\Console\Output\Str |
834a0 | 65 61 6d 4f 75 74 70 75 74 3b 0a 0a 2f 2a 2a 0a 20 2a 20 45 61 73 65 73 20 74 68 65 20 74 65 73 | eamOutput;../**..*.Eases.the.tes |
834c0 | 74 69 6e 67 20 6f 66 20 63 6f 6e 73 6f 6c 65 20 61 70 70 6c 69 63 61 74 69 6f 6e 73 2e 0a 20 2a | ting.of.console.applications...* |
834e0 | 0a 20 2a 20 57 68 65 6e 20 74 65 73 74 69 6e 67 20 61 6e 20 61 70 70 6c 69 63 61 74 69 6f 6e 2c | ..*.When.testing.an.application, |
83500 | 20 64 6f 6e 27 74 20 66 6f 72 67 65 74 20 74 6f 20 64 69 73 61 62 6c 65 20 74 68 65 20 61 75 74 | .don't.forget.to.disable.the.aut |
83520 | 6f 20 65 78 69 74 20 66 6c 61 67 3a 0a 20 2a 0a 20 2a 20 20 20 20 20 24 61 70 70 6c 69 63 61 74 | o.exit.flag:..*..*.....$applicat |
83540 | 69 6f 6e 20 3d 20 6e 65 77 20 41 70 70 6c 69 63 61 74 69 6f 6e 28 29 3b 0a 20 2a 20 20 20 20 20 | ion.=.new.Application();..*..... |
83560 | 24 61 70 70 6c 69 63 61 74 69 6f 6e 2d 3e 73 65 74 41 75 74 6f 45 78 69 74 28 66 61 6c 73 65 29 | $application->setAutoExit(false) |
83580 | 3b 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 | ;..*..*.@author.Fabien.Potencier |
835a0 | 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 | .<fabien@symfony.com>..*/.class. |
835c0 | 41 70 70 6c 69 63 61 74 69 6f 6e 54 65 73 74 65 72 0a 7b 0a 20 20 20 20 70 72 69 76 61 74 65 20 | ApplicationTester.{.....private. |
835e0 | 24 61 70 70 6c 69 63 61 74 69 6f 6e 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 69 6e 70 75 74 | $application;.....private.$input |
83600 | 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 73 74 61 74 75 73 43 6f 64 65 3b 0a 20 20 20 20 2f | ;.....private.$statusCode;...../ |
83620 | 2a 2a 0a 20 20 20 20 20 2a 20 40 76 61 72 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 0a 20 | **......*.@var.OutputInterface.. |
83640 | 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 6f 75 74 70 75 74 3b 0a 20 20 20 20 | ....*/.....private.$output;..... |
83660 | 70 72 69 76 61 74 65 20 24 63 61 70 74 75 72 65 53 74 72 65 61 6d 73 49 6e 64 65 70 65 6e 64 65 | private.$captureStreamsIndepende |
83680 | 6e 74 6c 79 20 3d 20 66 61 6c 73 65 3b 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 | ntly.=.false;......public.functi |
836a0 | 6f 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 74 28 41 70 70 6c 69 63 61 74 69 6f 6e 20 24 61 70 70 6c | on.__construct(Application.$appl |
836c0 | 69 63 61 74 69 6f 6e 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 61 70 | ication).....{.........$this->ap |
836e0 | 70 6c 69 63 61 74 69 6f 6e 20 3d 20 24 61 70 70 6c 69 63 61 74 69 6f 6e 3b 0a 20 20 20 20 7d 0a | plication.=.$application;.....}. |
83700 | 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 45 78 65 63 75 74 65 73 20 74 68 65 20 61 70 70 | ...../**......*.Executes.the.app |
83720 | 6c 69 63 61 74 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 41 76 61 69 6c 61 62 6c | lication.......*......*.Availabl |
83740 | 65 20 6f 70 74 69 6f 6e 73 3a 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 20 2a 20 69 6e 74 65 | e.options:......*......*..*.inte |
83760 | 72 61 63 74 69 76 65 3a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 53 65 74 73 20 74 68 65 20 | ractive:...............Sets.the. |
83780 | 69 6e 70 75 74 20 69 6e 74 65 72 61 63 74 69 76 65 20 66 6c 61 67 0a 20 20 20 20 20 2a 20 20 2a | input.interactive.flag......*..* |
837a0 | 20 64 65 63 6f 72 61 74 65 64 3a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 53 65 74 73 | .decorated:.................Sets |
837c0 | 20 74 68 65 20 6f 75 74 70 75 74 20 64 65 63 6f 72 61 74 65 64 20 66 6c 61 67 0a 20 20 20 20 20 | .the.output.decorated.flag...... |
837e0 | 2a 20 20 2a 20 76 65 72 62 6f 73 69 74 79 3a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | *..*.verbosity:................. |
83800 | 53 65 74 73 20 74 68 65 20 6f 75 74 70 75 74 20 76 65 72 62 6f 73 69 74 79 20 66 6c 61 67 0a 20 | Sets.the.output.verbosity.flag.. |
83820 | 20 20 20 20 2a 20 20 2a 20 63 61 70 74 75 72 65 5f 73 74 64 65 72 72 5f 73 65 70 61 72 61 74 65 | ....*..*.capture_stderr_separate |
83840 | 6c 79 3a 20 4d 61 6b 65 20 6f 75 74 70 75 74 20 6f 66 20 73 74 64 4f 75 74 20 61 6e 64 20 73 74 | ly:.Make.output.of.stdOut.and.st |
83860 | 64 45 72 72 20 73 65 70 61 72 61 74 65 6c 79 20 61 76 61 69 6c 61 62 6c 65 0a 20 20 20 20 20 2a | dErr.separately.available......* |
83880 | 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 24 69 6e 70 75 74 20 20 20 41 6e | ......*.@param.array.$input...An |
838a0 | 20 61 72 72 61 79 20 6f 66 20 61 72 67 75 6d 65 6e 74 73 20 61 6e 64 20 6f 70 74 69 6f 6e 73 0a | .array.of.arguments.and.options. |
838c0 | 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 24 6f 70 74 69 6f 6e 73 20 41 6e 20 | .....*.@param.array.$options.An. |
838e0 | 61 72 72 61 79 20 6f 66 20 6f 70 74 69 6f 6e 73 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 | array.of.options......*......*.@ |
83900 | 72 65 74 75 72 6e 20 69 6e 74 20 54 68 65 20 63 6f 6d 6d 61 6e 64 20 65 78 69 74 20 63 6f 64 65 | return.int.The.command.exit.code |
83920 | 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 72 75 6e | ......*/.....public.function.run |
83940 | 28 61 72 72 61 79 20 24 69 6e 70 75 74 2c 20 24 6f 70 74 69 6f 6e 73 20 3d 20 61 72 72 61 79 28 | (array.$input,.$options.=.array( |
83960 | 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 69 6e 70 75 74 20 3d 20 | )).....{.........$this->input.=. |
83980 | 6e 65 77 20 41 72 72 61 79 49 6e 70 75 74 28 24 69 6e 70 75 74 29 3b 0a 20 20 20 20 20 20 20 20 | new.ArrayInput($input);......... |
839a0 | 69 66 20 28 69 73 73 65 74 28 24 6f 70 74 69 6f 6e 73 5b 27 69 6e 74 65 72 61 63 74 69 76 65 27 | if.(isset($options['interactive' |
839c0 | 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 69 6e 70 75 74 2d 3e | ])).{.............$this->input-> |
839e0 | 73 65 74 49 6e 74 65 72 61 63 74 69 76 65 28 24 6f 70 74 69 6f 6e 73 5b 27 69 6e 74 65 72 61 63 | setInteractive($options['interac |
83a00 | 74 69 76 65 27 5d 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 | tive']);.........}..........$thi |
83a20 | 73 2d 3e 63 61 70 74 75 72 65 53 74 72 65 61 6d 73 49 6e 64 65 70 65 6e 64 65 6e 74 6c 79 20 3d | s->captureStreamsIndependently.= |
83a40 | 20 61 72 72 61 79 5f 6b 65 79 5f 65 78 69 73 74 73 28 27 63 61 70 74 75 72 65 5f 73 74 64 65 72 | .array_key_exists('capture_stder |
83a60 | 72 5f 73 65 70 61 72 61 74 65 6c 79 27 2c 20 24 6f 70 74 69 6f 6e 73 29 20 26 26 20 24 6f 70 74 | r_separately',.$options).&&.$opt |
83a80 | 69 6f 6e 73 5b 27 63 61 70 74 75 72 65 5f 73 74 64 65 72 72 5f 73 65 70 61 72 61 74 65 6c 79 27 | ions['capture_stderr_separately' |
83aa0 | 5d 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 24 74 68 69 73 2d 3e 63 61 70 74 75 72 65 53 74 | ];.........if.(!$this->captureSt |
83ac0 | 72 65 61 6d 73 49 6e 64 65 70 65 6e 64 65 6e 74 6c 79 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | reamsIndependently).{........... |
83ae0 | 20 20 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 20 3d 20 6e 65 77 20 53 74 72 65 61 6d 4f 75 74 70 | ..$this->output.=.new.StreamOutp |
83b00 | 75 74 28 66 6f 70 65 6e 28 27 70 68 70 3a 2f 2f 6d 65 6d 6f 72 79 27 2c 20 27 77 27 2c 20 66 61 | ut(fopen('php://memory',.'w',.fa |
83b20 | 6c 73 65 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 69 73 73 65 74 28 24 6f 70 | lse));.............if.(isset($op |
83b40 | 74 69 6f 6e 73 5b 27 64 65 63 6f 72 61 74 65 64 27 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | tions['decorated'])).{.......... |
83b60 | 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 2d 3e 73 65 74 44 65 63 6f 72 61 74 | .......$this->output->setDecorat |
83b80 | 65 64 28 24 6f 70 74 69 6f 6e 73 5b 27 64 65 63 6f 72 61 74 65 64 27 5d 29 3b 0a 20 20 20 20 20 | ed($options['decorated']);...... |
83ba0 | 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 69 73 73 65 74 28 24 | .......}.............if.(isset($ |
83bc0 | 6f 70 74 69 6f 6e 73 5b 27 76 65 72 62 6f 73 69 74 79 27 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 | options['verbosity'])).{........ |
83be0 | 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 2d 3e 73 65 74 56 65 72 62 6f | .........$this->output->setVerbo |
83c00 | 73 69 74 79 28 24 6f 70 74 69 6f 6e 73 5b 27 76 65 72 62 6f 73 69 74 79 27 5d 29 3b 0a 20 20 20 | sity($options['verbosity']);.... |
83c20 | 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 | .........}.........}.else.{..... |
83c40 | 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 20 3d 20 6e 65 77 20 43 6f 6e 73 | ........$this->output.=.new.Cons |
83c60 | 6f 6c 65 4f 75 74 70 75 74 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 73 73 65 74 | oleOutput(.................isset |
83c80 | 28 24 6f 70 74 69 6f 6e 73 5b 27 76 65 72 62 6f 73 69 74 79 27 5d 29 20 3f 20 24 6f 70 74 69 6f | ($options['verbosity']).?.$optio |
83ca0 | 6e 73 5b 27 76 65 72 62 6f 73 69 74 79 27 5d 20 3a 20 43 6f 6e 73 6f 6c 65 4f 75 74 70 75 74 3a | ns['verbosity'].:.ConsoleOutput: |
83cc0 | 3a 56 45 52 42 4f 53 49 54 59 5f 4e 4f 52 4d 41 4c 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | :VERBOSITY_NORMAL,.............. |
83ce0 | 20 20 20 69 73 73 65 74 28 24 6f 70 74 69 6f 6e 73 5b 27 64 65 63 6f 72 61 74 65 64 27 5d 29 20 | ...isset($options['decorated']). |
83d00 | 3f 20 24 6f 70 74 69 6f 6e 73 5b 27 64 65 63 6f 72 61 74 65 64 27 5d 20 3a 20 6e 75 6c 6c 0a 20 | ?.$options['decorated'].:.null.. |
83d20 | 20 20 20 20 20 20 20 20 20 20 20 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 65 72 72 6f | ...........);..............$erro |
83d40 | 72 4f 75 74 70 75 74 20 3d 20 6e 65 77 20 53 74 72 65 61 6d 4f 75 74 70 75 74 28 66 6f 70 65 6e | rOutput.=.new.StreamOutput(fopen |
83d60 | 28 27 70 68 70 3a 2f 2f 6d 65 6d 6f 72 79 27 2c 20 27 77 27 2c 20 66 61 6c 73 65 29 29 3b 0a 20 | ('php://memory',.'w',.false));.. |
83d80 | 20 20 20 20 20 20 20 20 20 20 20 24 65 72 72 6f 72 4f 75 74 70 75 74 2d 3e 73 65 74 46 6f 72 6d | ...........$errorOutput->setForm |
83da0 | 61 74 74 65 72 28 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 2d 3e 67 65 74 46 6f 72 6d 61 74 74 65 | atter($this->output->getFormatte |
83dc0 | 72 28 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 65 72 72 6f 72 4f 75 74 70 75 74 2d 3e | r());.............$errorOutput-> |
83de0 | 73 65 74 56 65 72 62 6f 73 69 74 79 28 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 2d 3e 67 65 74 56 | setVerbosity($this->output->getV |
83e00 | 65 72 62 6f 73 69 74 79 28 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 65 72 72 6f 72 4f | erbosity());.............$errorO |
83e20 | 75 74 70 75 74 2d 3e 73 65 74 44 65 63 6f 72 61 74 65 64 28 24 74 68 69 73 2d 3e 6f 75 74 70 75 | utput->setDecorated($this->outpu |
83e40 | 74 2d 3e 69 73 44 65 63 6f 72 61 74 65 64 28 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 20 20 20 | t->isDecorated());.............. |
83e60 | 24 72 65 66 6c 65 63 74 65 64 4f 75 74 70 75 74 20 3d 20 6e 65 77 20 5c 52 65 66 6c 65 63 74 69 | $reflectedOutput.=.new.\Reflecti |
83e80 | 6f 6e 4f 62 6a 65 63 74 28 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 29 3b 0a 20 20 20 20 20 20 20 | onObject($this->output);........ |
83ea0 | 20 20 20 20 20 24 73 74 72 45 72 72 50 72 6f 70 65 72 74 79 20 3d 20 24 72 65 66 6c 65 63 74 65 | .....$strErrProperty.=.$reflecte |
83ec0 | 64 4f 75 74 70 75 74 2d 3e 67 65 74 50 72 6f 70 65 72 74 79 28 27 73 74 64 65 72 72 27 29 3b 0a | dOutput->getProperty('stderr');. |
83ee0 | 20 20 20 20 20 20 20 20 20 20 20 20 24 73 74 72 45 72 72 50 72 6f 70 65 72 74 79 2d 3e 73 65 74 | ............$strErrProperty->set |
83f00 | 41 63 63 65 73 73 69 62 6c 65 28 74 72 75 65 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 73 | Accessible(true);.............$s |
83f20 | 74 72 45 72 72 50 72 6f 70 65 72 74 79 2d 3e 73 65 74 56 61 6c 75 65 28 24 74 68 69 73 2d 3e 6f | trErrProperty->setValue($this->o |
83f40 | 75 74 70 75 74 2c 20 24 65 72 72 6f 72 4f 75 74 70 75 74 29 3b 0a 0a 20 20 20 20 20 20 20 20 20 | utput,.$errorOutput);........... |
83f60 | 20 20 20 24 72 65 66 6c 65 63 74 65 64 50 61 72 65 6e 74 20 3d 20 24 72 65 66 6c 65 63 74 65 64 | ...$reflectedParent.=.$reflected |
83f80 | 4f 75 74 70 75 74 2d 3e 67 65 74 50 61 72 65 6e 74 43 6c 61 73 73 28 29 3b 0a 20 20 20 20 20 20 | Output->getParentClass();....... |
83fa0 | 20 20 20 20 20 20 24 73 74 72 65 61 6d 50 72 6f 70 65 72 74 79 20 3d 20 24 72 65 66 6c 65 63 74 | ......$streamProperty.=.$reflect |
83fc0 | 65 64 50 61 72 65 6e 74 2d 3e 67 65 74 50 72 6f 70 65 72 74 79 28 27 73 74 72 65 61 6d 27 29 3b | edParent->getProperty('stream'); |
83fe0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 73 74 72 65 61 6d 50 72 6f 70 65 72 74 79 2d 3e 73 65 | .............$streamProperty->se |
84000 | 74 41 63 63 65 73 73 69 62 6c 65 28 74 72 75 65 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 | tAccessible(true);.............$ |
84020 | 73 74 72 65 61 6d 50 72 6f 70 65 72 74 79 2d 3e 73 65 74 56 61 6c 75 65 28 24 74 68 69 73 2d 3e | streamProperty->setValue($this-> |
84040 | 6f 75 74 70 75 74 2c 20 66 6f 70 65 6e 28 27 70 68 70 3a 2f 2f 6d 65 6d 6f 72 79 27 2c 20 27 77 | output,.fopen('php://memory',.'w |
84060 | 27 2c 20 66 61 6c 73 65 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 | ',.false));.........}..........r |
84080 | 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 73 74 61 74 75 73 43 6f 64 65 20 3d 20 24 74 68 69 73 2d | eturn.$this->statusCode.=.$this- |
840a0 | 3e 61 70 70 6c 69 63 61 74 69 6f 6e 2d 3e 72 75 6e 28 24 74 68 69 73 2d 3e 69 6e 70 75 74 2c 20 | >application->run($this->input,. |
840c0 | 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 | $this->output);.....}....../**.. |
840e0 | 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 64 69 73 70 6c 61 79 20 72 65 74 75 72 6e 65 64 20 | ....*.Gets.the.display.returned. |
84100 | 62 79 20 74 68 65 20 6c 61 73 74 20 65 78 65 63 75 74 69 6f 6e 20 6f 66 20 74 68 65 20 61 70 70 | by.the.last.execution.of.the.app |
84120 | 6c 69 63 61 74 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 62 | lication.......*......*.@param.b |
84140 | 6f 6f 6c 20 24 6e 6f 72 6d 61 6c 69 7a 65 20 57 68 65 74 68 65 72 20 74 6f 20 6e 6f 72 6d 61 6c | ool.$normalize.Whether.to.normal |
84160 | 69 7a 65 20 65 6e 64 20 6f 66 20 6c 69 6e 65 73 20 74 6f 20 5c 6e 20 6f 72 20 6e 6f 74 0a 20 20 | ize.end.of.lines.to.\n.or.not... |
84180 | 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 20 54 68 65 20 64 | ...*......*.@return.string.The.d |
841a0 | 69 73 70 6c 61 79 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 | isplay......*/.....public.functi |
841c0 | 6f 6e 20 67 65 74 44 69 73 70 6c 61 79 28 24 6e 6f 72 6d 61 6c 69 7a 65 20 3d 20 66 61 6c 73 65 | on.getDisplay($normalize.=.false |
841e0 | 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 77 69 6e 64 28 24 74 68 69 73 2d 3e 6f 75 | ).....{.........rewind($this->ou |
84200 | 74 70 75 74 2d 3e 67 65 74 53 74 72 65 61 6d 28 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 64 69 | tput->getStream());..........$di |
84220 | 73 70 6c 61 79 20 3d 20 73 74 72 65 61 6d 5f 67 65 74 5f 63 6f 6e 74 65 6e 74 73 28 24 74 68 69 | splay.=.stream_get_contents($thi |
84240 | 73 2d 3e 6f 75 74 70 75 74 2d 3e 67 65 74 53 74 72 65 61 6d 28 29 29 3b 0a 0a 20 20 20 20 20 20 | s->output->getStream());........ |
84260 | 20 20 69 66 20 28 24 6e 6f 72 6d 61 6c 69 7a 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ..if.($normalize).{............. |
84280 | 24 64 69 73 70 6c 61 79 20 3d 20 73 74 72 5f 72 65 70 6c 61 63 65 28 50 48 50 5f 45 4f 4c 2c 20 | $display.=.str_replace(PHP_EOL,. |
842a0 | 22 5c 6e 22 2c 20 24 64 69 73 70 6c 61 79 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 | "\n",.$display);.........}...... |
842c0 | 20 20 20 20 72 65 74 75 72 6e 20 24 64 69 73 70 6c 61 79 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 | ....return.$display;.....}...... |
842e0 | 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 6f 75 74 70 75 74 20 77 72 69 74 74 | /**......*.Gets.the.output.writt |
84300 | 65 6e 20 74 6f 20 53 54 44 45 52 52 20 62 79 20 74 68 65 20 61 70 70 6c 69 63 61 74 69 6f 6e 2e | en.to.STDERR.by.the.application. |
84320 | 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 62 6f 6f 6c 20 24 6e 6f 72 6d | ......*......*.@param.bool.$norm |
84340 | 61 6c 69 7a 65 20 57 68 65 74 68 65 72 20 74 6f 20 6e 6f 72 6d 61 6c 69 7a 65 20 65 6e 64 20 6f | alize.Whether.to.normalize.end.o |
84360 | 66 20 6c 69 6e 65 73 20 74 6f 20 5c 6e 20 6f 72 20 6e 6f 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 | f.lines.to.\n.or.not......*..... |
84380 | 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 | .*.@return.string......*/.....pu |
843a0 | 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 45 72 72 6f 72 4f 75 74 70 75 74 28 24 6e 6f | blic.function.getErrorOutput($no |
843c0 | 72 6d 61 6c 69 7a 65 20 3d 20 66 61 6c 73 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 | rmalize.=.false).....{.........i |
843e0 | 66 20 28 21 24 74 68 69 73 2d 3e 63 61 70 74 75 72 65 53 74 72 65 61 6d 73 49 6e 64 65 70 65 6e | f.(!$this->captureStreamsIndepen |
84400 | 64 65 6e 74 6c 79 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 | dently).{.............throw.new. |
84420 | 5c 4c 6f 67 69 63 45 78 63 65 70 74 69 6f 6e 28 27 54 68 65 20 65 72 72 6f 72 20 6f 75 74 70 75 | \LogicException('The.error.outpu |
84440 | 74 20 69 73 20 6e 6f 74 20 61 76 61 69 6c 61 62 6c 65 20 77 68 65 6e 20 74 68 65 20 74 65 73 74 | t.is.not.available.when.the.test |
84460 | 65 72 20 69 73 20 72 75 6e 20 77 69 74 68 6f 75 74 20 22 63 61 70 74 75 72 65 5f 73 74 64 65 72 | er.is.run.without."capture_stder |
84480 | 72 5f 73 65 70 61 72 61 74 65 6c 79 22 20 6f 70 74 69 6f 6e 20 73 65 74 2e 27 29 3b 0a 20 20 20 | r_separately".option.set.');.... |
844a0 | 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 77 69 6e 64 28 24 74 68 69 73 2d 3e 6f 75 | .....}..........rewind($this->ou |
844c0 | 74 70 75 74 2d 3e 67 65 74 45 72 72 6f 72 4f 75 74 70 75 74 28 29 2d 3e 67 65 74 53 74 72 65 61 | tput->getErrorOutput()->getStrea |
844e0 | 6d 28 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 64 69 73 70 6c 61 79 20 3d 20 73 74 72 65 61 6d | m());..........$display.=.stream |
84500 | 5f 67 65 74 5f 63 6f 6e 74 65 6e 74 73 28 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 2d 3e 67 65 74 | _get_contents($this->output->get |
84520 | 45 72 72 6f 72 4f 75 74 70 75 74 28 29 2d 3e 67 65 74 53 74 72 65 61 6d 28 29 29 3b 0a 0a 20 20 | ErrorOutput()->getStream());.... |
84540 | 20 20 20 20 20 20 69 66 20 28 24 6e 6f 72 6d 61 6c 69 7a 65 29 20 7b 0a 20 20 20 20 20 20 20 20 | ......if.($normalize).{......... |
84560 | 20 20 20 20 24 64 69 73 70 6c 61 79 20 3d 20 73 74 72 5f 72 65 70 6c 61 63 65 28 50 48 50 5f 45 | ....$display.=.str_replace(PHP_E |
84580 | 4f 4c 2c 20 22 5c 6e 22 2c 20 24 64 69 73 70 6c 61 79 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a | OL,."\n",.$display);.........}.. |
845a0 | 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 64 69 73 70 6c 61 79 3b 0a 20 20 20 20 7d 0a 0a | ........return.$display;.....}.. |
845c0 | 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 69 6e 70 75 74 20 69 6e | ..../**......*.Gets.the.input.in |
845e0 | 73 74 61 6e 63 65 20 75 73 65 64 20 62 79 20 74 68 65 20 6c 61 73 74 20 65 78 65 63 75 74 69 6f | stance.used.by.the.last.executio |
84600 | 6e 20 6f 66 20 74 68 65 20 61 70 70 6c 69 63 61 74 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 | n.of.the.application.......*.... |
84620 | 20 20 2a 20 40 72 65 74 75 72 6e 20 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 20 54 68 65 20 63 | ..*.@return.InputInterface.The.c |
84640 | 75 72 72 65 6e 74 20 69 6e 70 75 74 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 | urrent.input.instance......*/... |
84660 | 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 49 6e 70 75 74 28 29 0a 20 20 20 | ..public.function.getInput().... |
84680 | 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 69 6e 70 75 74 3b 0a | .{.........return.$this->input;. |
846a0 | 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 6f | ....}....../**......*.Gets.the.o |
846c0 | 75 74 70 75 74 20 69 6e 73 74 61 6e 63 65 20 75 73 65 64 20 62 79 20 74 68 65 20 6c 61 73 74 20 | utput.instance.used.by.the.last. |
846e0 | 65 78 65 63 75 74 69 6f 6e 20 6f 66 20 74 68 65 20 61 70 70 6c 69 63 61 74 69 6f 6e 2e 0a 20 20 | execution.of.the.application.... |
84700 | 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 4f 75 74 70 75 74 49 6e 74 65 72 66 | ...*......*.@return.OutputInterf |
84720 | 61 63 65 20 54 68 65 20 63 75 72 72 65 6e 74 20 6f 75 74 70 75 74 20 69 6e 73 74 61 6e 63 65 0a | ace.The.current.output.instance. |
84740 | 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 4f | .....*/.....public.function.getO |
84760 | 75 74 70 75 74 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 | utput().....{.........return.$th |
84780 | 69 73 2d 3e 6f 75 74 70 75 74 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 | is->output;.....}....../**...... |
847a0 | 2a 20 47 65 74 73 20 74 68 65 20 73 74 61 74 75 73 20 63 6f 64 65 20 72 65 74 75 72 6e 65 64 20 | *.Gets.the.status.code.returned. |
847c0 | 62 79 20 74 68 65 20 6c 61 73 74 20 65 78 65 63 75 74 69 6f 6e 20 6f 66 20 74 68 65 20 61 70 70 | by.the.last.execution.of.the.app |
847e0 | 6c 69 63 61 74 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 | lication.......*......*.@return. |
84800 | 69 6e 74 20 54 68 65 20 73 74 61 74 75 73 20 63 6f 64 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 | int.The.status.code......*/..... |
84820 | 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 53 74 61 74 75 73 43 6f 64 65 28 29 0a | public.function.getStatusCode(). |
84840 | 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 73 74 61 74 | ....{.........return.$this->stat |
84860 | 75 73 43 6f 64 65 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 | usCode;.....}.}.<?php../*..*.Thi |
84880 | 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 | s.file.is.part.of.the.Symfony.pa |
848a0 | 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 | ckage...*..*.(c).Fabien.Potencie |
848c0 | 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 | r.<fabien@symfony.com>..*..*.For |
848e0 | 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 | .the.full.copyright.and.license. |
84900 | 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 | information,.please.view.the.LIC |
84920 | 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 | ENSE..*.file.that.was.distribute |
84940 | 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 | d.with.this.source.code...*/..na |
84960 | 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c | mespace.Symfony\Component\Consol |
84980 | 65 5c 54 65 73 74 65 72 3b 0a 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 | e\Tester;..use.Symfony\Component |
849a0 | 5c 43 6f 6e 73 6f 6c 65 5c 43 6f 6d 6d 61 6e 64 5c 43 6f 6d 6d 61 6e 64 3b 0a 75 73 65 20 53 79 | \Console\Command\Command;.use.Sy |
849c0 | 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 5c 41 72 | mfony\Component\Console\Input\Ar |
849e0 | 72 61 79 49 6e 70 75 74 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c | rayInput;.use.Symfony\Component\ |
84a00 | 43 6f 6e 73 6f 6c 65 5c 4f 75 74 70 75 74 5c 53 74 72 65 61 6d 4f 75 74 70 75 74 3b 0a 75 73 65 | Console\Output\StreamOutput;.use |
84a20 | 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 | .Symfony\Component\Console\Input |
84a40 | 5c 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d | \InputInterface;.use.Symfony\Com |
84a60 | 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 4f 75 74 70 75 74 5c 4f 75 74 70 75 74 49 6e 74 65 | ponent\Console\Output\OutputInte |
84a80 | 72 66 61 63 65 3b 0a 0a 2f 2a 2a 0a 20 2a 20 45 61 73 65 73 20 74 68 65 20 74 65 73 74 69 6e 67 | rface;../**..*.Eases.the.testing |
84aa0 | 20 6f 66 20 63 6f 6e 73 6f 6c 65 20 63 6f 6d 6d 61 6e 64 73 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 | .of.console.commands...*..*.@aut |
84ac0 | 68 6f 72 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d | hor.Fabien.Potencier.<fabien@sym |
84ae0 | 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 43 6f 6d 6d 61 6e 64 54 65 73 74 65 | fony.com>..*/.class.CommandTeste |
84b00 | 72 0a 7b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 63 6f 6d 6d 61 6e 64 3b 0a 20 20 20 20 70 72 | r.{.....private.$command;.....pr |
84b20 | 69 76 61 74 65 20 24 69 6e 70 75 74 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 6f 75 74 70 75 | ivate.$input;.....private.$outpu |
84b40 | 74 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 73 74 61 74 75 73 43 6f 64 65 3b 0a 0a 20 20 20 | t;.....private.$statusCode;..... |
84b60 | 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 43 6f 6e 73 74 72 75 63 74 6f 72 2e 0a 20 20 20 20 20 2a 0a | ./**......*.Constructor.......*. |
84b80 | 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 43 6f 6d 6d 61 6e 64 20 24 63 6f 6d 6d 61 6e 64 20 41 | .....*.@param.Command.$command.A |
84ba0 | 20 43 6f 6d 6d 61 6e 64 20 69 6e 73 74 61 6e 63 65 20 74 6f 20 74 65 73 74 0a 20 20 20 20 20 2a | .Command.instance.to.test......* |
84bc0 | 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 | /.....public.function.__construc |
84be0 | 74 28 43 6f 6d 6d 61 6e 64 20 24 63 6f 6d 6d 61 6e 64 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 | t(Command.$command).....{....... |
84c00 | 20 20 24 74 68 69 73 2d 3e 63 6f 6d 6d 61 6e 64 20 3d 20 24 63 6f 6d 6d 61 6e 64 3b 0a 20 20 20 | ..$this->command.=.$command;.... |
84c20 | 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 45 78 65 63 75 74 65 73 20 74 68 65 20 | .}....../**......*.Executes.the. |
84c40 | 63 6f 6d 6d 61 6e 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 41 76 61 69 6c 61 62 6c 65 | command.......*......*.Available |
84c60 | 20 65 78 65 63 75 74 69 6f 6e 20 6f 70 74 69 6f 6e 73 3a 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 | .execution.options:......*...... |
84c80 | 2a 20 20 2a 20 69 6e 74 65 72 61 63 74 69 76 65 3a 20 53 65 74 73 20 74 68 65 20 69 6e 70 75 74 | *..*.interactive:.Sets.the.input |
84ca0 | 20 69 6e 74 65 72 61 63 74 69 76 65 20 66 6c 61 67 0a 20 20 20 20 20 2a 20 20 2a 20 64 65 63 6f | .interactive.flag......*..*.deco |
84cc0 | 72 61 74 65 64 3a 20 20 20 53 65 74 73 20 74 68 65 20 6f 75 74 70 75 74 20 64 65 63 6f 72 61 74 | rated:...Sets.the.output.decorat |
84ce0 | 65 64 20 66 6c 61 67 0a 20 20 20 20 20 2a 20 20 2a 20 76 65 72 62 6f 73 69 74 79 3a 20 20 20 53 | ed.flag......*..*.verbosity:...S |
84d00 | 65 74 73 20 74 68 65 20 6f 75 74 70 75 74 20 76 65 72 62 6f 73 69 74 79 20 66 6c 61 67 0a 20 20 | ets.the.output.verbosity.flag... |
84d20 | 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 24 69 6e 70 75 74 20 | ...*......*.@param.array.$input. |
84d40 | 20 20 41 6e 20 61 72 72 61 79 20 6f 66 20 63 6f 6d 6d 61 6e 64 20 61 72 67 75 6d 65 6e 74 73 20 | ..An.array.of.command.arguments. |
84d60 | 61 6e 64 20 6f 70 74 69 6f 6e 73 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 | and.options......*.@param.array. |
84d80 | 24 6f 70 74 69 6f 6e 73 20 41 6e 20 61 72 72 61 79 20 6f 66 20 65 78 65 63 75 74 69 6f 6e 20 6f | $options.An.array.of.execution.o |
84da0 | 70 74 69 6f 6e 73 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 69 6e 74 | ptions......*......*.@return.int |
84dc0 | 20 54 68 65 20 63 6f 6d 6d 61 6e 64 20 65 78 69 74 20 63 6f 64 65 0a 20 20 20 20 20 2a 2f 0a 20 | .The.command.exit.code......*/.. |
84de0 | 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 65 78 65 63 75 74 65 28 61 72 72 61 79 | ...public.function.execute(array |
84e00 | 20 24 69 6e 70 75 74 2c 20 61 72 72 61 79 20 24 6f 70 74 69 6f 6e 73 20 3d 20 61 72 72 61 79 28 | .$input,.array.$options.=.array( |
84e20 | 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 2f 2f 20 73 65 74 20 74 68 65 20 63 6f 6d 6d | )).....{.........//.set.the.comm |
84e40 | 61 6e 64 20 6e 61 6d 65 20 61 75 74 6f 6d 61 74 69 63 61 6c 6c 79 20 69 66 20 74 68 65 20 61 70 | and.name.automatically.if.the.ap |
84e60 | 70 6c 69 63 61 74 69 6f 6e 20 72 65 71 75 69 72 65 73 0a 20 20 20 20 20 20 20 20 2f 2f 20 74 68 | plication.requires.........//.th |
84e80 | 69 73 20 61 72 67 75 6d 65 6e 74 20 61 6e 64 20 6e 6f 20 63 6f 6d 6d 61 6e 64 20 6e 61 6d 65 20 | is.argument.and.no.command.name. |
84ea0 | 77 61 73 20 70 61 73 73 65 64 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 69 73 73 65 74 28 24 69 | was.passed.........if.(!isset($i |
84ec0 | 6e 70 75 74 5b 27 63 6f 6d 6d 61 6e 64 27 5d 29 0a 20 20 20 20 20 20 20 20 20 20 20 20 26 26 20 | nput['command']).............&&. |
84ee0 | 28 6e 75 6c 6c 20 21 3d 3d 20 24 61 70 70 6c 69 63 61 74 69 6f 6e 20 3d 20 24 74 68 69 73 2d 3e | (null.!==.$application.=.$this-> |
84f00 | 63 6f 6d 6d 61 6e 64 2d 3e 67 65 74 41 70 70 6c 69 63 61 74 69 6f 6e 28 29 29 0a 20 20 20 20 20 | command->getApplication())...... |
84f20 | 20 20 20 20 20 20 20 26 26 20 24 61 70 70 6c 69 63 61 74 69 6f 6e 2d 3e 67 65 74 44 65 66 69 6e | .......&&.$application->getDefin |
84f40 | 69 74 69 6f 6e 28 29 2d 3e 68 61 73 41 72 67 75 6d 65 6e 74 28 27 63 6f 6d 6d 61 6e 64 27 29 0a | ition()->hasArgument('command'). |
84f60 | 20 20 20 20 20 20 20 20 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 69 6e 70 75 74 20 3d | ........).{.............$input.= |
84f80 | 20 61 72 72 61 79 5f 6d 65 72 67 65 28 61 72 72 61 79 28 27 63 6f 6d 6d 61 6e 64 27 20 3d 3e 20 | .array_merge(array('command'.=>. |
84fa0 | 24 74 68 69 73 2d 3e 63 6f 6d 6d 61 6e 64 2d 3e 67 65 74 4e 61 6d 65 28 29 29 2c 20 24 69 6e 70 | $this->command->getName()),.$inp |
84fc0 | 75 74 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 69 | ut);.........}..........$this->i |
84fe0 | 6e 70 75 74 20 3d 20 6e 65 77 20 41 72 72 61 79 49 6e 70 75 74 28 24 69 6e 70 75 74 29 3b 0a 20 | nput.=.new.ArrayInput($input);.. |
85000 | 20 20 20 20 20 20 20 69 66 20 28 69 73 73 65 74 28 24 6f 70 74 69 6f 6e 73 5b 27 69 6e 74 65 72 | .......if.(isset($options['inter |
85020 | 61 63 74 69 76 65 27 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e | active'])).{.............$this-> |
85040 | 69 6e 70 75 74 2d 3e 73 65 74 49 6e 74 65 72 61 63 74 69 76 65 28 24 6f 70 74 69 6f 6e 73 5b 27 | input->setInteractive($options[' |
85060 | 69 6e 74 65 72 61 63 74 69 76 65 27 5d 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 | interactive']);.........}....... |
85080 | 20 20 20 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 20 3d 20 6e 65 77 20 53 74 72 65 61 6d 4f 75 74 | ...$this->output.=.new.StreamOut |
850a0 | 70 75 74 28 66 6f 70 65 6e 28 27 70 68 70 3a 2f 2f 6d 65 6d 6f 72 79 27 2c 20 27 77 27 2c 20 66 | put(fopen('php://memory',.'w',.f |
850c0 | 61 6c 73 65 29 29 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 69 73 73 65 74 28 24 6f 70 74 69 6f | alse));.........if.(isset($optio |
850e0 | 6e 73 5b 27 64 65 63 6f 72 61 74 65 64 27 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ns['decorated'])).{............. |
85100 | 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 2d 3e 73 65 74 44 65 63 6f 72 61 74 65 64 28 24 6f 70 74 | $this->output->setDecorated($opt |
85120 | 69 6f 6e 73 5b 27 64 65 63 6f 72 61 74 65 64 27 5d 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 | ions['decorated']);.........}... |
85140 | 20 20 20 20 20 20 69 66 20 28 69 73 73 65 74 28 24 6f 70 74 69 6f 6e 73 5b 27 76 65 72 62 6f 73 | ......if.(isset($options['verbos |
85160 | 69 74 79 27 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6f 75 74 | ity'])).{.............$this->out |
85180 | 70 75 74 2d 3e 73 65 74 56 65 72 62 6f 73 69 74 79 28 24 6f 70 74 69 6f 6e 73 5b 27 76 65 72 62 | put->setVerbosity($options['verb |
851a0 | 6f 73 69 74 79 27 5d 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 | osity']);.........}..........ret |
851c0 | 75 72 6e 20 24 74 68 69 73 2d 3e 73 74 61 74 75 73 43 6f 64 65 20 3d 20 24 74 68 69 73 2d 3e 63 | urn.$this->statusCode.=.$this->c |
851e0 | 6f 6d 6d 61 6e 64 2d 3e 72 75 6e 28 24 74 68 69 73 2d 3e 69 6e 70 75 74 2c 20 24 74 68 69 73 2d | ommand->run($this->input,.$this- |
85200 | 3e 6f 75 74 70 75 74 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 | >output);.....}....../**......*. |
85220 | 47 65 74 73 20 74 68 65 20 64 69 73 70 6c 61 79 20 72 65 74 75 72 6e 65 64 20 62 79 20 74 68 65 | Gets.the.display.returned.by.the |
85240 | 20 6c 61 73 74 20 65 78 65 63 75 74 69 6f 6e 20 6f 66 20 74 68 65 20 63 6f 6d 6d 61 6e 64 2e 0a | .last.execution.of.the.command.. |
85260 | 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 62 6f 6f 6c 20 24 6e 6f 72 6d 61 | .....*......*.@param.bool.$norma |
85280 | 6c 69 7a 65 20 57 68 65 74 68 65 72 20 74 6f 20 6e 6f 72 6d 61 6c 69 7a 65 20 65 6e 64 20 6f 66 | lize.Whether.to.normalize.end.of |
852a0 | 20 6c 69 6e 65 73 20 74 6f 20 5c 6e 20 6f 72 20 6e 6f 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 | .lines.to.\n.or.not......*...... |
852c0 | 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 20 54 68 65 20 64 69 73 70 6c 61 79 0a 20 20 20 | *.@return.string.The.display.... |
852e0 | 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 44 69 73 70 | ..*/.....public.function.getDisp |
85300 | 6c 61 79 28 24 6e 6f 72 6d 61 6c 69 7a 65 20 3d 20 66 61 6c 73 65 29 0a 20 20 20 20 7b 0a 20 20 | lay($normalize.=.false).....{... |
85320 | 20 20 20 20 20 20 72 65 77 69 6e 64 28 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 2d 3e 67 65 74 53 | ......rewind($this->output->getS |
85340 | 74 72 65 61 6d 28 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 64 69 73 70 6c 61 79 20 3d 20 73 74 | tream());..........$display.=.st |
85360 | 72 65 61 6d 5f 67 65 74 5f 63 6f 6e 74 65 6e 74 73 28 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 2d | ream_get_contents($this->output- |
85380 | 3e 67 65 74 53 74 72 65 61 6d 28 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 6e 6f 72 | >getStream());..........if.($nor |
853a0 | 6d 61 6c 69 7a 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 64 69 73 70 6c 61 79 20 3d | malize).{.............$display.= |
853c0 | 20 73 74 72 5f 72 65 70 6c 61 63 65 28 50 48 50 5f 45 4f 4c 2c 20 22 5c 6e 22 2c 20 24 64 69 73 | .str_replace(PHP_EOL,."\n",.$dis |
853e0 | 70 6c 61 79 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e | play);.........}..........return |
85400 | 20 24 64 69 73 70 6c 61 79 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a | .$display;.....}....../**......* |
85420 | 20 47 65 74 73 20 74 68 65 20 69 6e 70 75 74 20 69 6e 73 74 61 6e 63 65 20 75 73 65 64 20 62 79 | .Gets.the.input.instance.used.by |
85440 | 20 74 68 65 20 6c 61 73 74 20 65 78 65 63 75 74 69 6f 6e 20 6f 66 20 74 68 65 20 63 6f 6d 6d 61 | .the.last.execution.of.the.comma |
85460 | 6e 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 49 6e 70 75 74 49 | nd.......*......*.@return.InputI |
85480 | 6e 74 65 72 66 61 63 65 20 54 68 65 20 63 75 72 72 65 6e 74 20 69 6e 70 75 74 20 69 6e 73 74 61 | nterface.The.current.input.insta |
854a0 | 6e 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 | nce......*/.....public.function. |
854c0 | 67 65 74 49 6e 70 75 74 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 | getInput().....{.........return. |
854e0 | 24 74 68 69 73 2d 3e 69 6e 70 75 74 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 | $this->input;.....}....../**.... |
85500 | 20 20 2a 20 47 65 74 73 20 74 68 65 20 6f 75 74 70 75 74 20 69 6e 73 74 61 6e 63 65 20 75 73 65 | ..*.Gets.the.output.instance.use |
85520 | 64 20 62 79 20 74 68 65 20 6c 61 73 74 20 65 78 65 63 75 74 69 6f 6e 20 6f 66 20 74 68 65 20 63 | d.by.the.last.execution.of.the.c |
85540 | 6f 6d 6d 61 6e 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 4f 75 | ommand.......*......*.@return.Ou |
85560 | 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 54 68 65 20 63 75 72 72 65 6e 74 20 6f 75 74 70 75 74 | tputInterface.The.current.output |
85580 | 20 69 6e 73 74 61 6e 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e | .instance......*/.....public.fun |
855a0 | 63 74 69 6f 6e 20 67 65 74 4f 75 74 70 75 74 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | ction.getOutput().....{......... |
855c0 | 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 | return.$this->output;.....}..... |
855e0 | 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 47 65 74 73 20 74 68 65 20 73 74 61 74 75 73 20 63 6f 64 65 | ./**......*.Gets.the.status.code |
85600 | 20 72 65 74 75 72 6e 65 64 20 62 79 20 74 68 65 20 6c 61 73 74 20 65 78 65 63 75 74 69 6f 6e 20 | .returned.by.the.last.execution. |
85620 | 6f 66 20 74 68 65 20 61 70 70 6c 69 63 61 74 69 6f 6e 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 | of.the.application.......*...... |
85640 | 2a 20 40 72 65 74 75 72 6e 20 69 6e 74 20 54 68 65 20 73 74 61 74 75 73 20 63 6f 64 65 0a 20 20 | *.@return.int.The.status.code... |
85660 | 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 53 74 61 | ...*/.....public.function.getSta |
85680 | 74 75 73 43 6f 64 65 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 | tusCode().....{.........return.$ |
856a0 | 74 68 69 73 2d 3e 73 74 61 74 75 73 43 6f 64 65 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a | this->statusCode;.....}.}.<?php. |
856c0 | 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 | ./*..*.This.file.is.part.of.the. |
856e0 | 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 | Symfony.package...*..*.(c).Fabie |
85700 | 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e | n.Potencier.<fabien@symfony.com> |
85720 | 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e | ..*..*.For.the.full.copyright.an |
85740 | 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 | d.license.information,.please.vi |
85760 | 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 | ew.the.LICENSE..*.file.that.was. |
85780 | 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 | distributed.with.this.source.cod |
857a0 | 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e | e...*/..namespace.Symfony\Compon |
857c0 | 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 4c 6f 67 67 65 72 3b 0a 0a 75 73 65 20 50 73 72 5c 4c 6f 67 | ent\Console\Logger;..use.Psr\Log |
857e0 | 5c 41 62 73 74 72 61 63 74 4c 6f 67 67 65 72 3b 0a 75 73 65 20 50 73 72 5c 4c 6f 67 5c 49 6e 76 | \AbstractLogger;.use.Psr\Log\Inv |
85800 | 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 3b 0a 75 73 65 20 50 73 72 5c 4c | alidArgumentException;.use.Psr\L |
85820 | 6f 67 5c 4c 6f 67 4c 65 76 65 6c 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 | og\LogLevel;.use.Symfony\Compone |
85840 | 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 4f 75 74 70 75 74 5c 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 | nt\Console\Output\OutputInterfac |
85860 | 65 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 | e;.use.Symfony\Component\Console |
85880 | 5c 4f 75 74 70 75 74 5c 43 6f 6e 73 6f 6c 65 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 3b 0a | \Output\ConsoleOutputInterface;. |
858a0 | 0a 2f 2a 2a 0a 20 2a 20 50 53 52 2d 33 20 63 6f 6d 70 6c 69 61 6e 74 20 63 6f 6e 73 6f 6c 65 20 | ./**..*.PSR-3.compliant.console. |
858c0 | 6c 6f 67 67 65 72 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 4b c3 a9 76 69 6e 20 44 75 6e | logger...*..*.@author.K..vin.Dun |
858e0 | 67 6c 61 73 20 3c 64 75 6e 67 6c 61 73 40 67 6d 61 69 6c 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 40 | glas.<dunglas@gmail.com>..*..*.@ |
85900 | 6c 69 6e 6b 20 68 74 74 70 3a 2f 2f 77 77 77 2e 70 68 70 2d 66 69 67 2e 6f 72 67 2f 70 73 72 2f | link.http://www.php-fig.org/psr/ |
85920 | 70 73 72 2d 33 2f 0a 20 2a 2f 0a 63 6c 61 73 73 20 43 6f 6e 73 6f 6c 65 4c 6f 67 67 65 72 20 65 | psr-3/..*/.class.ConsoleLogger.e |
85940 | 78 74 65 6e 64 73 20 41 62 73 74 72 61 63 74 4c 6f 67 67 65 72 0a 7b 0a 20 20 20 20 63 6f 6e 73 | xtends.AbstractLogger.{.....cons |
85960 | 74 20 49 4e 46 4f 20 3d 20 27 69 6e 66 6f 27 3b 0a 20 20 20 20 63 6f 6e 73 74 20 45 52 52 4f 52 | t.INFO.=.'info';.....const.ERROR |
85980 | 20 3d 20 27 65 72 72 6f 72 27 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 76 61 72 | .=.'error';....../**......*.@var |
859a0 | 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 | .OutputInterface......*/.....pri |
859c0 | 76 61 74 65 20 24 6f 75 74 70 75 74 3b 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 76 61 | vate.$output;...../**......*.@va |
859e0 | 72 20 61 72 72 61 79 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 76 65 72 | r.array......*/.....private.$ver |
85a00 | 62 6f 73 69 74 79 4c 65 76 65 6c 4d 61 70 20 3d 20 61 72 72 61 79 28 0a 20 20 20 20 20 20 20 20 | bosityLevelMap.=.array(......... |
85a20 | 4c 6f 67 4c 65 76 65 6c 3a 3a 45 4d 45 52 47 45 4e 43 59 20 3d 3e 20 4f 75 74 70 75 74 49 6e 74 | LogLevel::EMERGENCY.=>.OutputInt |
85a40 | 65 72 66 61 63 65 3a 3a 56 45 52 42 4f 53 49 54 59 5f 4e 4f 52 4d 41 4c 2c 0a 20 20 20 20 20 20 | erface::VERBOSITY_NORMAL,....... |
85a60 | 20 20 4c 6f 67 4c 65 76 65 6c 3a 3a 41 4c 45 52 54 20 3d 3e 20 4f 75 74 70 75 74 49 6e 74 65 72 | ..LogLevel::ALERT.=>.OutputInter |
85a80 | 66 61 63 65 3a 3a 56 45 52 42 4f 53 49 54 59 5f 4e 4f 52 4d 41 4c 2c 0a 20 20 20 20 20 20 20 20 | face::VERBOSITY_NORMAL,......... |
85aa0 | 4c 6f 67 4c 65 76 65 6c 3a 3a 43 52 49 54 49 43 41 4c 20 3d 3e 20 4f 75 74 70 75 74 49 6e 74 65 | LogLevel::CRITICAL.=>.OutputInte |
85ac0 | 72 66 61 63 65 3a 3a 56 45 52 42 4f 53 49 54 59 5f 4e 4f 52 4d 41 4c 2c 0a 20 20 20 20 20 20 20 | rface::VERBOSITY_NORMAL,........ |
85ae0 | 20 4c 6f 67 4c 65 76 65 6c 3a 3a 45 52 52 4f 52 20 3d 3e 20 4f 75 74 70 75 74 49 6e 74 65 72 66 | .LogLevel::ERROR.=>.OutputInterf |
85b00 | 61 63 65 3a 3a 56 45 52 42 4f 53 49 54 59 5f 4e 4f 52 4d 41 4c 2c 0a 20 20 20 20 20 20 20 20 4c | ace::VERBOSITY_NORMAL,.........L |
85b20 | 6f 67 4c 65 76 65 6c 3a 3a 57 41 52 4e 49 4e 47 20 3d 3e 20 4f 75 74 70 75 74 49 6e 74 65 72 66 | ogLevel::WARNING.=>.OutputInterf |
85b40 | 61 63 65 3a 3a 56 45 52 42 4f 53 49 54 59 5f 4e 4f 52 4d 41 4c 2c 0a 20 20 20 20 20 20 20 20 4c | ace::VERBOSITY_NORMAL,.........L |
85b60 | 6f 67 4c 65 76 65 6c 3a 3a 4e 4f 54 49 43 45 20 3d 3e 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 | ogLevel::NOTICE.=>.OutputInterfa |
85b80 | 63 65 3a 3a 56 45 52 42 4f 53 49 54 59 5f 56 45 52 42 4f 53 45 2c 0a 20 20 20 20 20 20 20 20 4c | ce::VERBOSITY_VERBOSE,.........L |
85ba0 | 6f 67 4c 65 76 65 6c 3a 3a 49 4e 46 4f 20 3d 3e 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 | ogLevel::INFO.=>.OutputInterface |
85bc0 | 3a 3a 56 45 52 42 4f 53 49 54 59 5f 56 45 52 59 5f 56 45 52 42 4f 53 45 2c 0a 20 20 20 20 20 20 | ::VERBOSITY_VERY_VERBOSE,....... |
85be0 | 20 20 4c 6f 67 4c 65 76 65 6c 3a 3a 44 45 42 55 47 20 3d 3e 20 4f 75 74 70 75 74 49 6e 74 65 72 | ..LogLevel::DEBUG.=>.OutputInter |
85c00 | 66 61 63 65 3a 3a 56 45 52 42 4f 53 49 54 59 5f 44 45 42 55 47 2c 0a 20 20 20 20 29 3b 0a 20 20 | face::VERBOSITY_DEBUG,.....);... |
85c20 | 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 76 61 72 20 61 72 72 61 79 0a 20 20 20 20 20 2a 2f 0a | ../**......*.@var.array......*/. |
85c40 | 20 20 20 20 70 72 69 76 61 74 65 20 24 66 6f 72 6d 61 74 4c 65 76 65 6c 4d 61 70 20 3d 20 61 72 | ....private.$formatLevelMap.=.ar |
85c60 | 72 61 79 28 0a 20 20 20 20 20 20 20 20 4c 6f 67 4c 65 76 65 6c 3a 3a 45 4d 45 52 47 45 4e 43 59 | ray(.........LogLevel::EMERGENCY |
85c80 | 20 3d 3e 20 73 65 6c 66 3a 3a 45 52 52 4f 52 2c 0a 20 20 20 20 20 20 20 20 4c 6f 67 4c 65 76 65 | .=>.self::ERROR,.........LogLeve |
85ca0 | 6c 3a 3a 41 4c 45 52 54 20 3d 3e 20 73 65 6c 66 3a 3a 45 52 52 4f 52 2c 0a 20 20 20 20 20 20 20 | l::ALERT.=>.self::ERROR,........ |
85cc0 | 20 4c 6f 67 4c 65 76 65 6c 3a 3a 43 52 49 54 49 43 41 4c 20 3d 3e 20 73 65 6c 66 3a 3a 45 52 52 | .LogLevel::CRITICAL.=>.self::ERR |
85ce0 | 4f 52 2c 0a 20 20 20 20 20 20 20 20 4c 6f 67 4c 65 76 65 6c 3a 3a 45 52 52 4f 52 20 3d 3e 20 73 | OR,.........LogLevel::ERROR.=>.s |
85d00 | 65 6c 66 3a 3a 45 52 52 4f 52 2c 0a 20 20 20 20 20 20 20 20 4c 6f 67 4c 65 76 65 6c 3a 3a 57 41 | elf::ERROR,.........LogLevel::WA |
85d20 | 52 4e 49 4e 47 20 3d 3e 20 73 65 6c 66 3a 3a 49 4e 46 4f 2c 0a 20 20 20 20 20 20 20 20 4c 6f 67 | RNING.=>.self::INFO,.........Log |
85d40 | 4c 65 76 65 6c 3a 3a 4e 4f 54 49 43 45 20 3d 3e 20 73 65 6c 66 3a 3a 49 4e 46 4f 2c 0a 20 20 20 | Level::NOTICE.=>.self::INFO,.... |
85d60 | 20 20 20 20 20 4c 6f 67 4c 65 76 65 6c 3a 3a 49 4e 46 4f 20 3d 3e 20 73 65 6c 66 3a 3a 49 4e 46 | .....LogLevel::INFO.=>.self::INF |
85d80 | 4f 2c 0a 20 20 20 20 20 20 20 20 4c 6f 67 4c 65 76 65 6c 3a 3a 44 45 42 55 47 20 3d 3e 20 73 65 | O,.........LogLevel::DEBUG.=>.se |
85da0 | 6c 66 3a 3a 49 4e 46 4f 2c 0a 20 20 20 20 29 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a | lf::INFO,.....);....../**......* |
85dc0 | 20 40 70 61 72 61 6d 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 0a | .@param.OutputInterface.$output. |
85de0 | 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 20 20 20 20 20 20 20 20 20 20 24 76 | .....*.@param.array...........$v |
85e00 | 65 72 62 6f 73 69 74 79 4c 65 76 65 6c 4d 61 70 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 | erbosityLevelMap......*.@param.a |
85e20 | 72 72 61 79 20 20 20 20 20 20 20 20 20 20 20 24 66 6f 72 6d 61 74 4c 65 76 65 6c 4d 61 70 0a 20 | rray...........$formatLevelMap.. |
85e40 | 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 63 6f 6e | ....*/.....public.function.__con |
85e60 | 73 74 72 75 63 74 28 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 2c 20 | struct(OutputInterface.$output,. |
85e80 | 61 72 72 61 79 20 24 76 65 72 62 6f 73 69 74 79 4c 65 76 65 6c 4d 61 70 20 3d 20 61 72 72 61 79 | array.$verbosityLevelMap.=.array |
85ea0 | 28 29 2c 20 61 72 72 61 79 20 24 66 6f 72 6d 61 74 4c 65 76 65 6c 4d 61 70 20 3d 20 61 72 72 61 | (),.array.$formatLevelMap.=.arra |
85ec0 | 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 | y()).....{.........$this->output |
85ee0 | 20 3d 20 24 6f 75 74 70 75 74 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 76 65 72 62 6f | .=.$output;.........$this->verbo |
85f00 | 73 69 74 79 4c 65 76 65 6c 4d 61 70 20 3d 20 24 76 65 72 62 6f 73 69 74 79 4c 65 76 65 6c 4d 61 | sityLevelMap.=.$verbosityLevelMa |
85f20 | 70 20 2b 20 24 74 68 69 73 2d 3e 76 65 72 62 6f 73 69 74 79 4c 65 76 65 6c 4d 61 70 3b 0a 20 20 | p.+.$this->verbosityLevelMap;... |
85f40 | 20 20 20 20 20 20 24 74 68 69 73 2d 3e 66 6f 72 6d 61 74 4c 65 76 65 6c 4d 61 70 20 3d 20 24 66 | ......$this->formatLevelMap.=.$f |
85f60 | 6f 72 6d 61 74 4c 65 76 65 6c 4d 61 70 20 2b 20 24 74 68 69 73 2d 3e 66 6f 72 6d 61 74 4c 65 76 | ormatLevelMap.+.$this->formatLev |
85f80 | 65 6c 4d 61 70 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 7b 40 69 | elMap;.....}....../**......*.{@i |
85fa0 | 6e 68 65 72 69 74 64 6f 63 7d 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 | nheritdoc}......*/.....public.fu |
85fc0 | 6e 63 74 69 6f 6e 20 6c 6f 67 28 24 6c 65 76 65 6c 2c 20 24 6d 65 73 73 61 67 65 2c 20 61 72 72 | nction.log($level,.$message,.arr |
85fe0 | 61 79 20 24 63 6f 6e 74 65 78 74 20 3d 20 61 72 72 61 79 28 29 29 0a 20 20 20 20 7b 0a 20 20 20 | ay.$context.=.array()).....{.... |
86000 | 20 20 20 20 20 69 66 20 28 21 69 73 73 65 74 28 24 74 68 69 73 2d 3e 76 65 72 62 6f 73 69 74 79 | .....if.(!isset($this->verbosity |
86020 | 4c 65 76 65 6c 4d 61 70 5b 24 6c 65 76 65 6c 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | LevelMap[$level])).{............ |
86040 | 20 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 | .throw.new.InvalidArgumentExcept |
86060 | 69 6f 6e 28 73 70 72 69 6e 74 66 28 27 54 68 65 20 6c 6f 67 20 6c 65 76 65 6c 20 22 25 73 22 20 | ion(sprintf('The.log.level."%s". |
86080 | 64 6f 65 73 20 6e 6f 74 20 65 78 69 73 74 2e 27 2c 20 24 6c 65 76 65 6c 29 29 3b 0a 20 20 20 20 | does.not.exist.',.$level));..... |
860a0 | 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 2f 2f 20 57 72 69 74 65 20 74 6f 20 74 68 65 20 65 | ....}..........//.Write.to.the.e |
860c0 | 72 72 6f 72 20 6f 75 74 70 75 74 20 69 66 20 6e 65 63 65 73 73 61 72 79 20 61 6e 64 20 61 76 61 | rror.output.if.necessary.and.ava |
860e0 | 69 6c 61 62 6c 65 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 74 68 69 73 2d 3e 66 6f 72 6d 61 74 | ilable.........if.($this->format |
86100 | 4c 65 76 65 6c 4d 61 70 5b 24 6c 65 76 65 6c 5d 20 3d 3d 3d 20 73 65 6c 66 3a 3a 45 52 52 4f 52 | LevelMap[$level].===.self::ERROR |
86120 | 20 26 26 20 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 20 69 6e 73 74 61 6e 63 65 6f 66 20 43 6f 6e | .&&.$this->output.instanceof.Con |
86140 | 73 6f 6c 65 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | soleOutputInterface).{.......... |
86160 | 20 20 20 24 6f 75 74 70 75 74 20 3d 20 24 74 68 69 73 2d 3e 6f 75 74 70 75 74 2d 3e 67 65 74 45 | ...$output.=.$this->output->getE |
86180 | 72 72 6f 72 4f 75 74 70 75 74 28 29 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 | rrorOutput();.........}.else.{.. |
861a0 | 20 20 20 20 20 20 20 20 20 20 20 24 6f 75 74 70 75 74 20 3d 20 24 74 68 69 73 2d 3e 6f 75 74 70 | ...........$output.=.$this->outp |
861c0 | 75 74 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 6f 75 74 70 | ut;.........}..........if.($outp |
861e0 | 75 74 2d 3e 67 65 74 56 65 72 62 6f 73 69 74 79 28 29 20 3e 3d 20 24 74 68 69 73 2d 3e 76 65 72 | ut->getVerbosity().>=.$this->ver |
86200 | 62 6f 73 69 74 79 4c 65 76 65 6c 4d 61 70 5b 24 6c 65 76 65 6c 5d 29 20 7b 0a 20 20 20 20 20 20 | bosityLevelMap[$level]).{....... |
86220 | 20 20 20 20 20 20 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 73 70 72 69 6e 74 66 28 27 | ......$output->writeln(sprintf(' |
86240 | 3c 25 31 24 73 3e 5b 25 32 24 73 5d 20 25 33 24 73 3c 2f 25 31 24 73 3e 27 2c 20 24 74 68 69 73 | <%1$s>[%2$s].%3$s</%1$s>',.$this |
86260 | 2d 3e 66 6f 72 6d 61 74 4c 65 76 65 6c 4d 61 70 5b 24 6c 65 76 65 6c 5d 2c 20 24 6c 65 76 65 6c | ->formatLevelMap[$level],.$level |
86280 | 2c 20 24 74 68 69 73 2d 3e 69 6e 74 65 72 70 6f 6c 61 74 65 28 24 6d 65 73 73 61 67 65 2c 20 24 | ,.$this->interpolate($message,.$ |
862a0 | 63 6f 6e 74 65 78 74 29 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 | context)));.........}.....}..... |
862c0 | 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 49 6e 74 65 72 70 6f 6c 61 74 65 73 20 63 6f 6e 74 65 78 74 | ./**......*.Interpolates.context |
862e0 | 20 76 61 6c 75 65 73 20 69 6e 74 6f 20 74 68 65 20 6d 65 73 73 61 67 65 20 70 6c 61 63 65 68 6f | .values.into.the.message.placeho |
86300 | 6c 64 65 72 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 61 75 74 68 6f 72 20 50 48 50 | lders.......*......*.@author.PHP |
86320 | 20 46 72 61 6d 65 77 6f 72 6b 20 49 6e 74 65 72 6f 70 65 72 61 62 69 6c 69 74 79 20 47 72 6f 75 | .Framework.Interoperability.Grou |
86340 | 70 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6d | p......*......*.@param.string.$m |
86360 | 65 73 73 61 67 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 20 24 63 6f 6e | essage......*.@param.array..$con |
86380 | 74 65 78 74 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e | text......*......*.@return.strin |
863a0 | 67 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 69 | g......*/.....private.function.i |
863c0 | 6e 74 65 72 70 6f 6c 61 74 65 28 24 6d 65 73 73 61 67 65 2c 20 61 72 72 61 79 20 24 63 6f 6e 74 | nterpolate($message,.array.$cont |
863e0 | 65 78 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 2f 2f 20 62 75 69 6c 64 20 61 20 72 65 | ext).....{.........//.build.a.re |
86400 | 70 6c 61 63 65 6d 65 6e 74 20 61 72 72 61 79 20 77 69 74 68 20 62 72 61 63 65 73 20 61 72 6f 75 | placement.array.with.braces.arou |
86420 | 6e 64 20 74 68 65 20 63 6f 6e 74 65 78 74 20 6b 65 79 73 0a 20 20 20 20 20 20 20 20 24 72 65 70 | nd.the.context.keys.........$rep |
86440 | 6c 61 63 65 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 | lace.=.array();.........foreach. |
86460 | 28 24 63 6f 6e 74 65 78 74 20 61 73 20 24 6b 65 79 20 3d 3e 20 24 76 61 6c 29 20 7b 0a 20 20 20 | ($context.as.$key.=>.$val).{.... |
86480 | 20 20 20 20 20 20 20 20 20 69 66 20 28 21 69 73 5f 61 72 72 61 79 28 24 76 61 6c 29 20 26 26 20 | .........if.(!is_array($val).&&. |
864a0 | 28 21 69 73 5f 6f 62 6a 65 63 74 28 24 76 61 6c 29 20 7c 7c 20 6d 65 74 68 6f 64 5f 65 78 69 73 | (!is_object($val).||.method_exis |
864c0 | 74 73 28 24 76 61 6c 2c 20 27 5f 5f 74 6f 53 74 72 69 6e 67 27 29 29 29 20 7b 0a 20 20 20 20 20 | ts($val,.'__toString'))).{...... |
864e0 | 20 20 20 20 20 20 20 20 20 20 20 24 72 65 70 6c 61 63 65 5b 73 70 72 69 6e 74 66 28 27 7b 25 73 | ...........$replace[sprintf('{%s |
86500 | 7d 27 2c 20 24 6b 65 79 29 5d 20 3d 20 24 76 61 6c 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d | }',.$key)].=.$val;.............} |
86520 | 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 2f 2f 20 69 6e 74 65 72 70 6f 6c 61 | .........}..........//.interpola |
86540 | 74 65 20 72 65 70 6c 61 63 65 6d 65 6e 74 20 76 61 6c 75 65 73 20 69 6e 74 6f 20 74 68 65 20 6d | te.replacement.values.into.the.m |
86560 | 65 73 73 61 67 65 20 61 6e 64 20 72 65 74 75 72 6e 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e | essage.and.return.........return |
86580 | 20 73 74 72 74 72 28 24 6d 65 73 73 61 67 65 2c 20 24 72 65 70 6c 61 63 65 29 3b 0a 20 20 20 20 | .strtr($message,.$replace);..... |
865a0 | 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 | }.}.<?php../*..*.This.file.is.pa |
865c0 | 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a | rt.of.the.Symfony.package...*..* |
865e0 | 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 | .(c).Fabien.Potencier.<fabien@sy |
86600 | 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f | mfony.com>..*..*.For.the.full.co |
86620 | 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c | pyright.and.license.information, |
86640 | 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 | .please.view.the.LICENSE..*.file |
86660 | 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 | .that.was.distributed.with.this. |
86680 | 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 | source.code...*/..namespace.Symf |
866a0 | 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 78 63 65 70 74 69 6f 6e 3b | ony\Component\Console\Exception; |
866c0 | 0a 0a 2f 2a 2a 0a 20 2a 20 45 78 63 65 70 74 69 6f 6e 49 6e 74 65 72 66 61 63 65 2e 0a 20 2a 0a | ../**..*.ExceptionInterface...*. |
866e0 | 20 2a 20 40 61 75 74 68 6f 72 20 4a c3 a9 72 c3 b4 6d 65 20 54 61 6d 61 72 65 6c 6c 65 20 3c 6a | .*.@author.J..r..me.Tamarelle.<j |
86700 | 65 72 6f 6d 65 40 74 61 6d 61 72 65 6c 6c 65 2e 6e 65 74 3e 0a 20 2a 2f 0a 69 6e 74 65 72 66 61 | erome@tamarelle.net>..*/.interfa |
86720 | 63 65 20 45 78 63 65 70 74 69 6f 6e 49 6e 74 65 72 66 61 63 65 0a 7b 0a 7d 0a 3c 3f 70 68 70 0a | ce.ExceptionInterface.{.}.<?php. |
86740 | 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 | ./*..*.This.file.is.part.of.the. |
86760 | 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 | Symfony.package...*..*.(c).Fabie |
86780 | 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e | n.Potencier.<fabien@symfony.com> |
867a0 | 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e | ..*..*.For.the.full.copyright.an |
867c0 | 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 | d.license.information,.please.vi |
867e0 | 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 | ew.the.LICENSE..*.file.that.was. |
86800 | 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 | distributed.with.this.source.cod |
86820 | 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e | e...*/..namespace.Symfony\Compon |
86840 | 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 78 63 65 70 74 69 6f 6e 3b 0a 0a 2f 2a 2a 0a 20 2a 20 40 | ent\Console\Exception;../**..*.@ |
86860 | 61 75 74 68 6f 72 20 4a c3 a9 72 c3 b4 6d 65 20 54 61 6d 61 72 65 6c 6c 65 20 3c 6a 65 72 6f 6d | author.J..r..me.Tamarelle.<jerom |
86880 | 65 40 74 61 6d 61 72 65 6c 6c 65 2e 6e 65 74 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 4c 6f 67 69 63 | e@tamarelle.net>..*/.class.Logic |
868a0 | 45 78 63 65 70 74 69 6f 6e 20 65 78 74 65 6e 64 73 20 5c 4c 6f 67 69 63 45 78 63 65 70 74 69 6f | Exception.extends.\LogicExceptio |
868c0 | 6e 20 69 6d 70 6c 65 6d 65 6e 74 73 20 45 78 63 65 70 74 69 6f 6e 49 6e 74 65 72 66 61 63 65 0a | n.implements.ExceptionInterface. |
868e0 | 7b 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 | {.}.<?php../*..*.This.file.is.pa |
86900 | 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a | rt.of.the.Symfony.package...*..* |
86920 | 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 | .(c).Fabien.Potencier.<fabien@sy |
86940 | 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f | mfony.com>..*..*.For.the.full.co |
86960 | 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c | pyright.and.license.information, |
86980 | 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 | .please.view.the.LICENSE..*.file |
869a0 | 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 | .that.was.distributed.with.this. |
869c0 | 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 | source.code...*/..namespace.Symf |
869e0 | 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 78 63 65 70 74 69 6f 6e 3b | ony\Component\Console\Exception; |
86a00 | 0a 0a 2f 2a 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 4a c3 a9 72 c3 b4 6d 65 20 54 61 6d 61 72 65 | ../**..*.@author.J..r..me.Tamare |
86a20 | 6c 6c 65 20 3c 6a 65 72 6f 6d 65 40 74 61 6d 61 72 65 6c 6c 65 2e 6e 65 74 3e 0a 20 2a 2f 0a 63 | lle.<jerome@tamarelle.net>..*/.c |
86a40 | 6c 61 73 73 20 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 20 65 78 | lass.InvalidArgumentException.ex |
86a60 | 74 65 6e 64 73 20 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 20 | tends.\InvalidArgumentException. |
86a80 | 69 6d 70 6c 65 6d 65 6e 74 73 20 45 78 63 65 70 74 69 6f 6e 49 6e 74 65 72 66 61 63 65 0a 7b 0a | implements.ExceptionInterface.{. |
86aa0 | 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 | }.<?php../*..*.This.file.is.part |
86ac0 | 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 | .of.the.Symfony.package...*..*.( |
86ae0 | 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 | c).Fabien.Potencier.<fabien@symf |
86b00 | 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 | ony.com>..*..*.For.the.full.copy |
86b20 | 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 | right.and.license.information,.p |
86b40 | 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 | lease.view.the.LICENSE..*.file.t |
86b60 | 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 73 20 73 6f | hat.was.distributed.with.this.so |
86b80 | 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e | urce.code...*/..namespace.Symfon |
86ba0 | 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 45 78 63 65 70 74 69 6f 6e 3b 0a 0a | y\Component\Console\Exception;.. |
86bc0 | 2f 2a 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 4a c3 a9 72 c3 b4 6d 65 20 54 61 6d 61 72 65 6c 6c | /**..*.@author.J..r..me.Tamarell |
86be0 | 65 20 3c 6a 65 72 6f 6d 65 40 74 61 6d 61 72 65 6c 6c 65 2e 6e 65 74 3e 0a 20 2a 2f 0a 63 6c 61 | e.<jerome@tamarelle.net>..*/.cla |
86c00 | 73 73 20 52 75 6e 74 69 6d 65 45 78 63 65 70 74 69 6f 6e 20 65 78 74 65 6e 64 73 20 5c 52 75 6e | ss.RuntimeException.extends.\Run |
86c20 | 74 69 6d 65 45 78 63 65 70 74 69 6f 6e 20 69 6d 70 6c 65 6d 65 6e 74 73 20 45 78 63 65 70 74 69 | timeException.implements.Excepti |
86c40 | 6f 6e 49 6e 74 65 72 66 61 63 65 0a 7b 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 | onInterface.{.}.<?php../*..*.Thi |
86c60 | 73 20 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 | s.file.is.part.of.the.Symfony.pa |
86c80 | 63 6b 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 | ckage...*..*.(c).Fabien.Potencie |
86ca0 | 72 20 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 | r.<fabien@symfony.com>..*..*.For |
86cc0 | 20 74 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 | .the.full.copyright.and.license. |
86ce0 | 69 6e 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 | information,.please.view.the.LIC |
86d00 | 45 4e 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 | ENSE..*.file.that.was.distribute |
86d20 | 64 20 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 | d.with.this.source.code...*/..na |
86d40 | 6d 65 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c | mespace.Symfony\Component\Consol |
86d60 | 65 5c 45 78 63 65 70 74 69 6f 6e 3b 0a 0a 2f 2a 2a 0a 20 2a 20 52 65 70 72 65 73 65 6e 74 73 20 | e\Exception;../**..*.Represents. |
86d80 | 61 6e 20 69 6e 63 6f 72 72 65 63 74 20 63 6f 6d 6d 61 6e 64 20 6e 61 6d 65 20 74 79 70 65 64 20 | an.incorrect.command.name.typed. |
86da0 | 69 6e 20 74 68 65 20 63 6f 6e 73 6f 6c 65 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 4a c3 | in.the.console...*..*.@author.J. |
86dc0 | a9 72 c3 b4 6d 65 20 54 61 6d 61 72 65 6c 6c 65 20 3c 6a 65 72 6f 6d 65 40 74 61 6d 61 72 65 6c | .r..me.Tamarelle.<jerome@tamarel |
86de0 | 6c 65 2e 6e 65 74 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 43 6f 6d 6d 61 6e 64 4e 6f 74 46 6f 75 6e | le.net>..*/.class.CommandNotFoun |
86e00 | 64 45 78 63 65 70 74 69 6f 6e 20 65 78 74 65 6e 64 73 20 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d | dException.extends.\InvalidArgum |
86e20 | 65 6e 74 45 78 63 65 70 74 69 6f 6e 20 69 6d 70 6c 65 6d 65 6e 74 73 20 45 78 63 65 70 74 69 6f | entException.implements.Exceptio |
86e40 | 6e 49 6e 74 65 72 66 61 63 65 0a 7b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 61 6c 74 65 72 6e | nInterface.{.....private.$altern |
86e60 | 61 74 69 76 65 73 3b 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 | atives;....../**......*.@param.s |
86e80 | 74 72 69 6e 67 20 20 20 20 24 6d 65 73 73 61 67 65 20 20 20 20 20 20 45 78 63 65 70 74 69 6f 6e | tring....$message......Exception |
86ea0 | 20 6d 65 73 73 61 67 65 20 74 6f 20 74 68 72 6f 77 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 | .message.to.throw......*.@param. |
86ec0 | 61 72 72 61 79 20 20 20 20 20 24 61 6c 74 65 72 6e 61 74 69 76 65 73 20 4c 69 73 74 20 6f 66 20 | array.....$alternatives.List.of. |
86ee0 | 73 69 6d 69 6c 61 72 20 64 65 66 69 6e 65 64 20 6e 61 6d 65 73 0a 20 20 20 20 20 2a 20 40 70 61 | similar.defined.names......*.@pa |
86f00 | 72 61 6d 20 69 6e 74 20 20 20 20 20 20 20 24 63 6f 64 65 20 20 20 20 20 20 20 20 20 45 78 63 65 | ram.int.......$code.........Exce |
86f20 | 70 74 69 6f 6e 20 63 6f 64 65 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 45 78 63 65 70 74 69 | ption.code......*.@param.Excepti |
86f40 | 6f 6e 20 24 70 72 65 76 69 6f 75 73 20 20 20 20 20 70 72 65 76 69 6f 75 73 20 65 78 63 65 70 74 | on.$previous.....previous.except |
86f60 | 69 6f 6e 20 75 73 65 64 20 66 6f 72 20 74 68 65 20 65 78 63 65 70 74 69 6f 6e 20 63 68 61 69 6e | ion.used.for.the.exception.chain |
86f80 | 69 6e 67 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 | ing......*/.....public.function. |
86fa0 | 5f 5f 63 6f 6e 73 74 72 75 63 74 28 24 6d 65 73 73 61 67 65 2c 20 61 72 72 61 79 20 24 61 6c 74 | __construct($message,.array.$alt |
86fc0 | 65 72 6e 61 74 69 76 65 73 20 3d 20 61 72 72 61 79 28 29 2c 20 24 63 6f 64 65 20 3d 20 30 2c 20 | ernatives.=.array(),.$code.=.0,. |
86fe0 | 5c 45 78 63 65 70 74 69 6f 6e 20 24 70 72 65 76 69 6f 75 73 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 | \Exception.$previous.=.null).... |
87000 | 20 7b 0a 20 20 20 20 20 20 20 20 70 61 72 65 6e 74 3a 3a 5f 5f 63 6f 6e 73 74 72 75 63 74 28 24 | .{.........parent::__construct($ |
87020 | 6d 65 73 73 61 67 65 2c 20 24 63 6f 64 65 2c 20 24 70 72 65 76 69 6f 75 73 29 3b 0a 0a 20 20 20 | message,.$code,.$previous);..... |
87040 | 20 20 20 20 20 24 74 68 69 73 2d 3e 61 6c 74 65 72 6e 61 74 69 76 65 73 20 3d 20 24 61 6c 74 65 | .....$this->alternatives.=.$alte |
87060 | 72 6e 61 74 69 76 65 73 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 | rnatives;.....}....../**......*. |
87080 | 40 72 65 74 75 72 6e 20 61 72 72 61 79 20 41 20 6c 69 73 74 20 6f 66 20 73 69 6d 69 6c 61 72 20 | @return.array.A.list.of.similar. |
870a0 | 64 65 66 69 6e 65 64 20 6e 61 6d 65 73 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 | defined.names......*/.....public |
870c0 | 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 41 6c 74 65 72 6e 61 74 69 76 65 73 28 29 0a 20 20 20 20 | .function.getAlternatives()..... |
870e0 | 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 61 6c 74 65 72 6e 61 74 | {.........return.$this->alternat |
87100 | 69 76 65 73 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 | ives;.....}.}.<?php../*..*.This. |
87120 | 66 69 6c 65 20 69 73 20 70 61 72 74 20 6f 66 20 74 68 65 20 53 79 6d 66 6f 6e 79 20 70 61 63 6b | file.is.part.of.the.Symfony.pack |
87140 | 61 67 65 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 | age...*..*.(c).Fabien.Potencier. |
87160 | 3c 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 | <fabien@symfony.com>..*..*.For.t |
87180 | 68 65 20 66 75 6c 6c 20 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e | he.full.copyright.and.license.in |
871a0 | 66 6f 72 6d 61 74 69 6f 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e | formation,.please.view.the.LICEN |
871c0 | 53 45 0a 20 2a 20 66 69 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 | SE..*.file.that.was.distributed. |
871e0 | 77 69 74 68 20 74 68 69 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 | with.this.source.code...*/..name |
87200 | 73 70 61 63 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c | space.Symfony\Component\Console\ |
87220 | 45 78 63 65 70 74 69 6f 6e 3b 0a 0a 2f 2a 2a 0a 20 2a 20 52 65 70 72 65 73 65 6e 74 73 20 61 6e | Exception;../**..*.Represents.an |
87240 | 20 69 6e 63 6f 72 72 65 63 74 20 6f 70 74 69 6f 6e 20 6e 61 6d 65 20 74 79 70 65 64 20 69 6e 20 | .incorrect.option.name.typed.in. |
87260 | 74 68 65 20 63 6f 6e 73 6f 6c 65 2e 0a 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 4a c3 a9 72 c3 | the.console...*..*.@author.J..r. |
87280 | b4 6d 65 20 54 61 6d 61 72 65 6c 6c 65 20 3c 6a 65 72 6f 6d 65 40 74 61 6d 61 72 65 6c 6c 65 2e | .me.Tamarelle.<jerome@tamarelle. |
872a0 | 6e 65 74 3e 0a 20 2a 2f 0a 63 6c 61 73 73 20 49 6e 76 61 6c 69 64 4f 70 74 69 6f 6e 45 78 63 65 | net>..*/.class.InvalidOptionExce |
872c0 | 70 74 69 6f 6e 20 65 78 74 65 6e 64 73 20 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 | ption.extends.\InvalidArgumentEx |
872e0 | 63 65 70 74 69 6f 6e 20 69 6d 70 6c 65 6d 65 6e 74 73 20 45 78 63 65 70 74 69 6f 6e 49 6e 74 65 | ception.implements.ExceptionInte |
87300 | 72 66 61 63 65 0a 7b 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2f 20 61 75 74 6f 6c 6f 61 64 2e 70 68 70 | rface.{.}.<?php..//.autoload.php |
87320 | 20 40 67 65 6e 65 72 61 74 65 64 20 62 79 20 43 6f 6d 70 6f 73 65 72 0a 0a 72 65 71 75 69 72 65 | .@generated.by.Composer..require |
87340 | 5f 6f 6e 63 65 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 63 6f 6d 70 6f 73 65 72 2f 61 75 74 6f 6c | _once.__DIR__...'/composer/autol |
87360 | 6f 61 64 5f 72 65 61 6c 2e 70 68 70 27 3b 0a 0a 72 65 74 75 72 6e 20 43 6f 6d 70 6f 73 65 72 41 | oad_real.php';..return.ComposerA |
87380 | 75 74 6f 6c 6f 61 64 65 72 49 6e 69 74 39 39 34 62 38 64 38 37 30 64 64 62 39 32 33 65 62 63 33 | utoloaderInit994b8d870ddb923ebc3 |
873a0 | 66 66 30 63 65 61 61 61 61 39 36 61 36 3a 3a 67 65 74 4c 6f 61 64 65 72 28 29 3b 0a 3c 3f 70 68 | ff0ceaaaa96a6::getLoader();.<?ph |
873c0 | 70 0a 2f 2a 2a 0a 20 2a 20 40 63 6f 70 79 72 69 67 68 74 20 43 6f 70 79 72 69 67 68 74 20 28 63 | p./**..*.@copyright.Copyright.(c |
873e0 | 29 20 32 30 31 36 20 4d 6f 72 72 69 73 20 4a 6f 62 6b 65 20 3c 68 65 79 40 6d 6f 72 72 69 73 6a | ).2016.Morris.Jobke.<hey@morrisj |
87400 | 6f 62 6b 65 2e 64 65 3e 0a 20 2a 0a 20 2a 20 40 6c 69 63 65 6e 73 65 20 47 4e 55 20 41 47 50 4c | obke.de>..*..*.@license.GNU.AGPL |
87420 | 20 76 65 72 73 69 6f 6e 20 33 20 6f 72 20 61 6e 79 20 6c 61 74 65 72 20 76 65 72 73 69 6f 6e 0a | .version.3.or.any.later.version. |
87440 | 20 2a 0a 20 2a 20 54 68 69 73 20 70 72 6f 67 72 61 6d 20 69 73 20 66 72 65 65 20 73 6f 66 74 77 | .*..*.This.program.is.free.softw |
87460 | 61 72 65 3a 20 79 6f 75 20 63 61 6e 20 72 65 64 69 73 74 72 69 62 75 74 65 20 69 74 20 61 6e 64 | are:.you.can.redistribute.it.and |
87480 | 2f 6f 72 20 6d 6f 64 69 66 79 0a 20 2a 20 69 74 20 75 6e 64 65 72 20 74 68 65 20 74 65 72 6d 73 | /or.modify..*.it.under.the.terms |
874a0 | 20 6f 66 20 74 68 65 20 47 4e 55 20 41 66 66 65 72 6f 20 47 65 6e 65 72 61 6c 20 50 75 62 6c 69 | .of.the.GNU.Affero.General.Publi |
874c0 | 63 20 4c 69 63 65 6e 73 65 20 61 73 0a 20 2a 20 70 75 62 6c 69 73 68 65 64 20 62 79 20 74 68 65 | c.License.as..*.published.by.the |
874e0 | 20 46 72 65 65 20 53 6f 66 74 77 61 72 65 20 46 6f 75 6e 64 61 74 69 6f 6e 2c 20 65 69 74 68 65 | .Free.Software.Foundation,.eithe |
87500 | 72 20 76 65 72 73 69 6f 6e 20 33 20 6f 66 20 74 68 65 0a 20 2a 20 4c 69 63 65 6e 73 65 2c 20 6f | r.version.3.of.the..*.License,.o |
87520 | 72 20 28 61 74 20 79 6f 75 72 20 6f 70 74 69 6f 6e 29 20 61 6e 79 20 6c 61 74 65 72 20 76 65 72 | r.(at.your.option).any.later.ver |
87540 | 73 69 6f 6e 2e 0a 20 2a 0a 20 2a 20 54 68 69 73 20 70 72 6f 67 72 61 6d 20 69 73 20 64 69 73 74 | sion...*..*.This.program.is.dist |
87560 | 72 69 62 75 74 65 64 20 69 6e 20 74 68 65 20 68 6f 70 65 20 74 68 61 74 20 69 74 20 77 69 6c 6c | ributed.in.the.hope.that.it.will |
87580 | 20 62 65 20 75 73 65 66 75 6c 2c 0a 20 2a 20 62 75 74 20 57 49 54 48 4f 55 54 20 41 4e 59 20 57 | .be.useful,..*.but.WITHOUT.ANY.W |
875a0 | 41 52 52 41 4e 54 59 3b 20 77 69 74 68 6f 75 74 20 65 76 65 6e 20 74 68 65 20 69 6d 70 6c 69 65 | ARRANTY;.without.even.the.implie |
875c0 | 64 20 77 61 72 72 61 6e 74 79 20 6f 66 0a 20 2a 20 4d 45 52 43 48 41 4e 54 41 42 49 4c 49 54 59 | d.warranty.of..*.MERCHANTABILITY |
875e0 | 20 6f 72 20 46 49 54 4e 45 53 53 20 46 4f 52 20 41 20 50 41 52 54 49 43 55 4c 41 52 20 50 55 52 | .or.FITNESS.FOR.A.PARTICULAR.PUR |
87600 | 50 4f 53 45 2e 20 20 53 65 65 20 74 68 65 0a 20 2a 20 47 4e 55 20 41 66 66 65 72 6f 20 47 65 6e | POSE...See.the..*.GNU.Affero.Gen |
87620 | 65 72 61 6c 20 50 75 62 6c 69 63 20 4c 69 63 65 6e 73 65 20 66 6f 72 20 6d 6f 72 65 20 64 65 74 | eral.Public.License.for.more.det |
87640 | 61 69 6c 73 2e 0a 20 2a 0a 20 2a 20 59 6f 75 20 73 68 6f 75 6c 64 20 68 61 76 65 20 72 65 63 65 | ails...*..*.You.should.have.rece |
87660 | 69 76 65 64 20 61 20 63 6f 70 79 20 6f 66 20 74 68 65 20 47 4e 55 20 41 66 66 65 72 6f 20 47 65 | ived.a.copy.of.the.GNU.Affero.Ge |
87680 | 6e 65 72 61 6c 20 50 75 62 6c 69 63 20 4c 69 63 65 6e 73 65 0a 20 2a 20 61 6c 6f 6e 67 20 77 69 | neral.Public.License..*.along.wi |
876a0 | 74 68 20 74 68 69 73 20 70 72 6f 67 72 61 6d 2e 20 20 49 66 20 6e 6f 74 2c 20 73 65 65 20 3c 68 | th.this.program...If.not,.see.<h |
876c0 | 74 74 70 3a 2f 2f 77 77 77 2e 67 6e 75 2e 6f 72 67 2f 6c 69 63 65 6e 73 65 73 2f 3e 2e 0a 20 2a | ttp://www.gnu.org/licenses/>...* |
876e0 | 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 4e 43 5c 55 70 64 61 74 65 72 3b 0a 0a 75 73 65 | ..*/..namespace.NC\Updater;..use |
87700 | 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 41 70 70 6c 69 | .Symfony\Component\Console\Appli |
87720 | 63 61 74 69 6f 6e 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f | cation;.use.Symfony\Component\Co |
87740 | 6e 73 6f 6c 65 5c 49 6e 70 75 74 5c 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 3b 0a 0a 2f 2a 2a | nsole\Input\InputInterface;../** |
87760 | 0a 20 2a 20 43 6c 61 73 73 20 43 6f 6d 6d 61 6e 64 41 70 70 6c 69 63 61 74 69 6f 6e 0a 20 2a 0a | ..*.Class.CommandApplication..*. |
87780 | 20 2a 20 73 65 65 20 68 74 74 70 3a 2f 2f 73 79 6d 66 6f 6e 79 2e 63 6f 6d 2f 64 6f 63 2f 63 75 | .*.see.http://symfony.com/doc/cu |
877a0 | 72 72 65 6e 74 2f 63 6f 6d 70 6f 6e 65 6e 74 73 2f 63 6f 6e 73 6f 6c 65 2f 73 69 6e 67 6c 65 5f | rrent/components/console/single_ |
877c0 | 63 6f 6d 6d 61 6e 64 5f 74 6f 6f 6c 2e 68 74 6d 6c 0a 20 2a 0a 20 2a 20 40 70 61 63 6b 61 67 65 | command_tool.html..*..*.@package |
877e0 | 20 4e 43 5c 55 70 64 61 74 65 72 0a 20 2a 2f 0a 63 6c 61 73 73 20 43 6f 6d 6d 61 6e 64 41 70 70 | .NC\Updater..*/.class.CommandApp |
87800 | 6c 69 63 61 74 69 6f 6e 20 65 78 74 65 6e 64 73 20 41 70 70 6c 69 63 61 74 69 6f 6e 20 7b 0a 09 | lication.extends.Application.{.. |
87820 | 2f 2a 2a 0a 09 20 2a 20 47 65 74 73 20 74 68 65 20 6e 61 6d 65 20 6f 66 20 74 68 65 20 63 6f 6d | /**...*.Gets.the.name.of.the.com |
87840 | 6d 61 6e 64 20 62 61 73 65 64 20 6f 6e 20 69 6e 70 75 74 2e 0a 09 20 2a 0a 09 20 2a 20 40 70 61 | mand.based.on.input....*...*.@pa |
87860 | 72 61 6d 20 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 69 6e 70 75 74 20 54 68 65 20 69 6e | ram.InputInterface.$input.The.in |
87880 | 70 75 74 20 69 6e 74 65 72 66 61 63 65 0a 09 20 2a 0a 09 20 2a 20 40 72 65 74 75 72 6e 20 73 74 | put.interface...*...*.@return.st |
878a0 | 72 69 6e 67 20 54 68 65 20 63 6f 6d 6d 61 6e 64 20 6e 61 6d 65 0a 09 20 2a 2f 0a 09 70 72 6f 74 | ring.The.command.name...*/..prot |
878c0 | 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 43 6f 6d 6d 61 6e 64 4e 61 6d 65 28 49 6e | ected.function.getCommandName(In |
878e0 | 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 69 6e 70 75 74 29 0a 09 7b 0a 09 09 2f 2f 20 54 68 69 | putInterface.$input)..{...//.Thi |
87900 | 73 20 73 68 6f 75 6c 64 20 72 65 74 75 72 6e 20 74 68 65 20 6e 61 6d 65 20 6f 66 20 79 6f 75 72 | s.should.return.the.name.of.your |
87920 | 20 63 6f 6d 6d 61 6e 64 2e 0a 09 09 72 65 74 75 72 6e 20 27 75 70 64 61 74 65 27 3b 0a 09 7d 0a | .command....return.'update';..}. |
87940 | 0a 09 2f 2a 2a 0a 09 20 2a 20 47 65 74 73 20 74 68 65 20 64 65 66 61 75 6c 74 20 63 6f 6d 6d 61 | ../**...*.Gets.the.default.comma |
87960 | 6e 64 73 20 74 68 61 74 20 73 68 6f 75 6c 64 20 61 6c 77 61 79 73 20 62 65 20 61 76 61 69 6c 61 | nds.that.should.always.be.availa |
87980 | 62 6c 65 2e 0a 09 20 2a 0a 09 20 2a 20 40 72 65 74 75 72 6e 20 61 72 72 61 79 20 41 6e 20 61 72 | ble....*...*.@return.array.An.ar |
879a0 | 72 61 79 20 6f 66 20 64 65 66 61 75 6c 74 20 43 6f 6d 6d 61 6e 64 20 69 6e 73 74 61 6e 63 65 73 | ray.of.default.Command.instances |
879c0 | 0a 09 20 2a 2f 0a 09 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 44 65 66 | ...*/..protected.function.getDef |
879e0 | 61 75 6c 74 43 6f 6d 6d 61 6e 64 73 28 29 0a 09 7b 0a 09 09 2f 2f 20 4b 65 65 70 20 74 68 65 20 | aultCommands()..{...//.Keep.the. |
87a00 | 63 6f 72 65 20 64 65 66 61 75 6c 74 20 63 6f 6d 6d 61 6e 64 73 20 74 6f 20 68 61 76 65 20 74 68 | core.default.commands.to.have.th |
87a20 | 65 20 48 65 6c 70 43 6f 6d 6d 61 6e 64 0a 09 09 2f 2f 20 77 68 69 63 68 20 69 73 20 75 73 65 64 | e.HelpCommand...//.which.is.used |
87a40 | 20 77 68 65 6e 20 75 73 69 6e 67 20 74 68 65 20 2d 2d 68 65 6c 70 20 6f 70 74 69 6f 6e 0a 09 09 | .when.using.the.--help.option... |
87a60 | 24 64 65 66 61 75 6c 74 43 6f 6d 6d 61 6e 64 73 20 3d 20 70 61 72 65 6e 74 3a 3a 67 65 74 44 65 | $defaultCommands.=.parent::getDe |
87a80 | 66 61 75 6c 74 43 6f 6d 6d 61 6e 64 73 28 29 3b 0a 0a 09 09 24 64 65 66 61 75 6c 74 43 6f 6d 6d | faultCommands();....$defaultComm |
87aa0 | 61 6e 64 73 5b 5d 20 3d 20 6e 65 77 20 55 70 64 61 74 65 43 6f 6d 6d 61 6e 64 28 29 3b 0a 0a 09 | ands[].=.new.UpdateCommand();... |
87ac0 | 09 72 65 74 75 72 6e 20 24 64 65 66 61 75 6c 74 43 6f 6d 6d 61 6e 64 73 3b 0a 09 7d 0a 0a 09 2f | .return.$defaultCommands;..}.../ |
87ae0 | 2a 2a 0a 09 20 2a 20 4f 76 65 72 72 69 64 64 65 6e 20 73 6f 20 74 68 61 74 20 74 68 65 20 61 70 | **...*.Overridden.so.that.the.ap |
87b00 | 70 6c 69 63 61 74 69 6f 6e 20 64 6f 65 73 6e 27 74 20 65 78 70 65 63 74 20 74 68 65 20 63 6f 6d | plication.doesn't.expect.the.com |
87b20 | 6d 61 6e 64 0a 09 20 2a 20 6e 61 6d 65 20 74 6f 20 62 65 20 74 68 65 20 66 69 72 73 74 20 61 72 | mand...*.name.to.be.the.first.ar |
87b40 | 67 75 6d 65 6e 74 2e 0a 09 20 2a 2f 0a 09 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 | gument....*/..public.function.ge |
87b60 | 74 44 65 66 69 6e 69 74 69 6f 6e 28 29 0a 09 7b 0a 09 09 24 69 6e 70 75 74 44 65 66 69 6e 69 74 | tDefinition()..{...$inputDefinit |
87b80 | 69 6f 6e 20 3d 20 70 61 72 65 6e 74 3a 3a 67 65 74 44 65 66 69 6e 69 74 69 6f 6e 28 29 3b 0a 09 | ion.=.parent::getDefinition();.. |
87ba0 | 09 2f 2f 20 63 6c 65 61 72 20 6f 75 74 20 74 68 65 20 6e 6f 72 6d 61 6c 20 66 69 72 73 74 20 61 | .//.clear.out.the.normal.first.a |
87bc0 | 72 67 75 6d 65 6e 74 2c 20 77 68 69 63 68 20 69 73 20 74 68 65 20 63 6f 6d 6d 61 6e 64 20 6e 61 | rgument,.which.is.the.command.na |
87be0 | 6d 65 0a 09 09 24 69 6e 70 75 74 44 65 66 69 6e 69 74 69 6f 6e 2d 3e 73 65 74 41 72 67 75 6d 65 | me...$inputDefinition->setArgume |
87c00 | 6e 74 73 28 29 3b 0a 0a 09 09 72 65 74 75 72 6e 20 24 69 6e 70 75 74 44 65 66 69 6e 69 74 69 6f | nts();....return.$inputDefinitio |
87c20 | 6e 3b 0a 09 7d 0a 7d 3c 3f 70 68 70 0a 2f 2a 2a 0a 20 2a 20 40 63 6f 70 79 72 69 67 68 74 20 43 | n;..}.}<?php./**..*.@copyright.C |
87c40 | 6f 70 79 72 69 67 68 74 20 28 63 29 20 32 30 31 36 20 4c 75 6b 61 73 20 52 65 73 63 68 6b 65 20 | opyright.(c).2016.Lukas.Reschke. |
87c60 | 3c 6c 75 6b 61 73 40 73 74 61 74 75 73 63 6f 64 65 2e 63 68 3e 0a 20 2a 20 40 63 6f 70 79 72 69 | <lukas@statuscode.ch>..*.@copyri |
87c80 | 67 68 74 20 43 6f 70 79 72 69 67 68 74 20 28 63 29 20 32 30 31 36 20 4d 6f 72 72 69 73 20 4a 6f | ght.Copyright.(c).2016.Morris.Jo |
87ca0 | 62 6b 65 20 3c 68 65 79 40 6d 6f 72 72 69 73 6a 6f 62 6b 65 2e 64 65 3e 0a 20 2a 0a 20 2a 20 40 | bke.<hey@morrisjobke.de>..*..*.@ |
87cc0 | 6c 69 63 65 6e 73 65 20 47 4e 55 20 41 47 50 4c 20 76 65 72 73 69 6f 6e 20 33 20 6f 72 20 61 6e | license.GNU.AGPL.version.3.or.an |
87ce0 | 79 20 6c 61 74 65 72 20 76 65 72 73 69 6f 6e 0a 20 2a 0a 20 2a 20 54 68 69 73 20 70 72 6f 67 72 | y.later.version..*..*.This.progr |
87d00 | 61 6d 20 69 73 20 66 72 65 65 20 73 6f 66 74 77 61 72 65 3a 20 79 6f 75 20 63 61 6e 20 72 65 64 | am.is.free.software:.you.can.red |
87d20 | 69 73 74 72 69 62 75 74 65 20 69 74 20 61 6e 64 2f 6f 72 20 6d 6f 64 69 66 79 0a 20 2a 20 69 74 | istribute.it.and/or.modify..*.it |
87d40 | 20 75 6e 64 65 72 20 74 68 65 20 74 65 72 6d 73 20 6f 66 20 74 68 65 20 47 4e 55 20 41 66 66 65 | .under.the.terms.of.the.GNU.Affe |
87d60 | 72 6f 20 47 65 6e 65 72 61 6c 20 50 75 62 6c 69 63 20 4c 69 63 65 6e 73 65 20 61 73 0a 20 2a 20 | ro.General.Public.License.as..*. |
87d80 | 70 75 62 6c 69 73 68 65 64 20 62 79 20 74 68 65 20 46 72 65 65 20 53 6f 66 74 77 61 72 65 20 46 | published.by.the.Free.Software.F |
87da0 | 6f 75 6e 64 61 74 69 6f 6e 2c 20 65 69 74 68 65 72 20 76 65 72 73 69 6f 6e 20 33 20 6f 66 20 74 | oundation,.either.version.3.of.t |
87dc0 | 68 65 0a 20 2a 20 4c 69 63 65 6e 73 65 2c 20 6f 72 20 28 61 74 20 79 6f 75 72 20 6f 70 74 69 6f | he..*.License,.or.(at.your.optio |
87de0 | 6e 29 20 61 6e 79 20 6c 61 74 65 72 20 76 65 72 73 69 6f 6e 2e 0a 20 2a 0a 20 2a 20 54 68 69 73 | n).any.later.version...*..*.This |
87e00 | 20 70 72 6f 67 72 61 6d 20 69 73 20 64 69 73 74 72 69 62 75 74 65 64 20 69 6e 20 74 68 65 20 68 | .program.is.distributed.in.the.h |
87e20 | 6f 70 65 20 74 68 61 74 20 69 74 20 77 69 6c 6c 20 62 65 20 75 73 65 66 75 6c 2c 0a 20 2a 20 62 | ope.that.it.will.be.useful,..*.b |
87e40 | 75 74 20 57 49 54 48 4f 55 54 20 41 4e 59 20 57 41 52 52 41 4e 54 59 3b 20 77 69 74 68 6f 75 74 | ut.WITHOUT.ANY.WARRANTY;.without |
87e60 | 20 65 76 65 6e 20 74 68 65 20 69 6d 70 6c 69 65 64 20 77 61 72 72 61 6e 74 79 20 6f 66 0a 20 2a | .even.the.implied.warranty.of..* |
87e80 | 20 4d 45 52 43 48 41 4e 54 41 42 49 4c 49 54 59 20 6f 72 20 46 49 54 4e 45 53 53 20 46 4f 52 20 | .MERCHANTABILITY.or.FITNESS.FOR. |
87ea0 | 41 20 50 41 52 54 49 43 55 4c 41 52 20 50 55 52 50 4f 53 45 2e 20 20 53 65 65 20 74 68 65 0a 20 | A.PARTICULAR.PURPOSE...See.the.. |
87ec0 | 2a 20 47 4e 55 20 41 66 66 65 72 6f 20 47 65 6e 65 72 61 6c 20 50 75 62 6c 69 63 20 4c 69 63 65 | *.GNU.Affero.General.Public.Lice |
87ee0 | 6e 73 65 20 66 6f 72 20 6d 6f 72 65 20 64 65 74 61 69 6c 73 2e 0a 20 2a 0a 20 2a 20 59 6f 75 20 | nse.for.more.details...*..*.You. |
87f00 | 73 68 6f 75 6c 64 20 68 61 76 65 20 72 65 63 65 69 76 65 64 20 61 20 63 6f 70 79 20 6f 66 20 74 | should.have.received.a.copy.of.t |
87f20 | 68 65 20 47 4e 55 20 41 66 66 65 72 6f 20 47 65 6e 65 72 61 6c 20 50 75 62 6c 69 63 20 4c 69 63 | he.GNU.Affero.General.Public.Lic |
87f40 | 65 6e 73 65 0a 20 2a 20 61 6c 6f 6e 67 20 77 69 74 68 20 74 68 69 73 20 70 72 6f 67 72 61 6d 2e | ense..*.along.with.this.program. |
87f60 | 20 20 49 66 20 6e 6f 74 2c 20 73 65 65 20 3c 68 74 74 70 3a 2f 2f 77 77 77 2e 67 6e 75 2e 6f 72 | ..If.not,.see.<http://www.gnu.or |
87f80 | 67 2f 6c 69 63 65 6e 73 65 73 2f 3e 2e 0a 20 2a 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 | g/licenses/>...*..*/..namespace. |
87fa0 | 4e 43 5c 55 70 64 61 74 65 72 3b 0a 0a 63 6c 61 73 73 20 55 70 64 61 74 65 45 78 63 65 70 74 69 | NC\Updater;..class.UpdateExcepti |
87fc0 | 6f 6e 20 65 78 74 65 6e 64 73 20 5c 45 78 63 65 70 74 69 6f 6e 20 7b 0a 09 70 72 6f 74 65 63 74 | on.extends.\Exception.{..protect |
87fe0 | 65 64 20 24 64 61 74 61 3b 0a 0a 09 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 63 6f | ed.$data;...public.function.__co |
88000 | 6e 73 74 72 75 63 74 28 24 64 61 74 61 29 20 7b 0a 09 09 24 74 68 69 73 2d 3e 64 61 74 61 20 3d | nstruct($data).{...$this->data.= |
88020 | 20 24 64 61 74 61 3b 0a 09 7d 0a 0a 09 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 | .$data;..}...public.function.get |
88040 | 44 61 74 61 28 29 20 7b 0a 09 09 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 64 61 74 61 3b 0a 09 | Data().{...return.$this->data;.. |
88060 | 7d 0a 7d 0a 3c 3f 70 68 70 0a 2f 2a 2a 0a 20 2a 20 40 63 6f 70 79 72 69 67 68 74 20 43 6f 70 79 | }.}.<?php./**..*.@copyright.Copy |
88080 | 72 69 67 68 74 20 28 63 29 20 32 30 31 36 20 4c 75 6b 61 73 20 52 65 73 63 68 6b 65 20 3c 6c 75 | right.(c).2016.Lukas.Reschke.<lu |
880a0 | 6b 61 73 40 73 74 61 74 75 73 63 6f 64 65 2e 63 68 3e 0a 20 2a 20 40 63 6f 70 79 72 69 67 68 74 | kas@statuscode.ch>..*.@copyright |
880c0 | 20 43 6f 70 79 72 69 67 68 74 20 28 63 29 20 32 30 31 36 20 4d 6f 72 72 69 73 20 4a 6f 62 6b 65 | .Copyright.(c).2016.Morris.Jobke |
880e0 | 20 3c 68 65 79 40 6d 6f 72 72 69 73 6a 6f 62 6b 65 2e 64 65 3e 0a 20 2a 0a 20 2a 20 40 6c 69 63 | .<hey@morrisjobke.de>..*..*.@lic |
88100 | 65 6e 73 65 20 47 4e 55 20 41 47 50 4c 20 76 65 72 73 69 6f 6e 20 33 20 6f 72 20 61 6e 79 20 6c | ense.GNU.AGPL.version.3.or.any.l |
88120 | 61 74 65 72 20 76 65 72 73 69 6f 6e 0a 20 2a 0a 20 2a 20 54 68 69 73 20 70 72 6f 67 72 61 6d 20 | ater.version..*..*.This.program. |
88140 | 69 73 20 66 72 65 65 20 73 6f 66 74 77 61 72 65 3a 20 79 6f 75 20 63 61 6e 20 72 65 64 69 73 74 | is.free.software:.you.can.redist |
88160 | 72 69 62 75 74 65 20 69 74 20 61 6e 64 2f 6f 72 20 6d 6f 64 69 66 79 0a 20 2a 20 69 74 20 75 6e | ribute.it.and/or.modify..*.it.un |
88180 | 64 65 72 20 74 68 65 20 74 65 72 6d 73 20 6f 66 20 74 68 65 20 47 4e 55 20 41 66 66 65 72 6f 20 | der.the.terms.of.the.GNU.Affero. |
881a0 | 47 65 6e 65 72 61 6c 20 50 75 62 6c 69 63 20 4c 69 63 65 6e 73 65 20 61 73 0a 20 2a 20 70 75 62 | General.Public.License.as..*.pub |
881c0 | 6c 69 73 68 65 64 20 62 79 20 74 68 65 20 46 72 65 65 20 53 6f 66 74 77 61 72 65 20 46 6f 75 6e | lished.by.the.Free.Software.Foun |
881e0 | 64 61 74 69 6f 6e 2c 20 65 69 74 68 65 72 20 76 65 72 73 69 6f 6e 20 33 20 6f 66 20 74 68 65 0a | dation,.either.version.3.of.the. |
88200 | 20 2a 20 4c 69 63 65 6e 73 65 2c 20 6f 72 20 28 61 74 20 79 6f 75 72 20 6f 70 74 69 6f 6e 29 20 | .*.License,.or.(at.your.option). |
88220 | 61 6e 79 20 6c 61 74 65 72 20 76 65 72 73 69 6f 6e 2e 0a 20 2a 0a 20 2a 20 54 68 69 73 20 70 72 | any.later.version...*..*.This.pr |
88240 | 6f 67 72 61 6d 20 69 73 20 64 69 73 74 72 69 62 75 74 65 64 20 69 6e 20 74 68 65 20 68 6f 70 65 | ogram.is.distributed.in.the.hope |
88260 | 20 74 68 61 74 20 69 74 20 77 69 6c 6c 20 62 65 20 75 73 65 66 75 6c 2c 0a 20 2a 20 62 75 74 20 | .that.it.will.be.useful,..*.but. |
88280 | 57 49 54 48 4f 55 54 20 41 4e 59 20 57 41 52 52 41 4e 54 59 3b 20 77 69 74 68 6f 75 74 20 65 76 | WITHOUT.ANY.WARRANTY;.without.ev |
882a0 | 65 6e 20 74 68 65 20 69 6d 70 6c 69 65 64 20 77 61 72 72 61 6e 74 79 20 6f 66 0a 20 2a 20 4d 45 | en.the.implied.warranty.of..*.ME |
882c0 | 52 43 48 41 4e 54 41 42 49 4c 49 54 59 20 6f 72 20 46 49 54 4e 45 53 53 20 46 4f 52 20 41 20 50 | RCHANTABILITY.or.FITNESS.FOR.A.P |
882e0 | 41 52 54 49 43 55 4c 41 52 20 50 55 52 50 4f 53 45 2e 20 20 53 65 65 20 74 68 65 0a 20 2a 20 47 | ARTICULAR.PURPOSE...See.the..*.G |
88300 | 4e 55 20 41 66 66 65 72 6f 20 47 65 6e 65 72 61 6c 20 50 75 62 6c 69 63 20 4c 69 63 65 6e 73 65 | NU.Affero.General.Public.License |
88320 | 20 66 6f 72 20 6d 6f 72 65 20 64 65 74 61 69 6c 73 2e 0a 20 2a 0a 20 2a 20 59 6f 75 20 73 68 6f | .for.more.details...*..*.You.sho |
88340 | 75 6c 64 20 68 61 76 65 20 72 65 63 65 69 76 65 64 20 61 20 63 6f 70 79 20 6f 66 20 74 68 65 20 | uld.have.received.a.copy.of.the. |
88360 | 47 4e 55 20 41 66 66 65 72 6f 20 47 65 6e 65 72 61 6c 20 50 75 62 6c 69 63 20 4c 69 63 65 6e 73 | GNU.Affero.General.Public.Licens |
88380 | 65 0a 20 2a 20 61 6c 6f 6e 67 20 77 69 74 68 20 74 68 69 73 20 70 72 6f 67 72 61 6d 2e 20 20 49 | e..*.along.with.this.program...I |
883a0 | 66 20 6e 6f 74 2c 20 73 65 65 20 3c 68 74 74 70 3a 2f 2f 77 77 77 2e 67 6e 75 2e 6f 72 67 2f 6c | f.not,.see.<http://www.gnu.org/l |
883c0 | 69 63 65 6e 73 65 73 2f 3e 2e 0a 20 2a 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 4e 43 5c | icenses/>...*..*/..namespace.NC\ |
883e0 | 55 70 64 61 74 65 72 3b 0a 0a 63 6c 61 73 73 20 52 65 63 75 72 73 69 76 65 44 69 72 65 63 74 6f | Updater;..class.RecursiveDirecto |
88400 | 72 79 49 74 65 72 61 74 6f 72 57 69 74 68 6f 75 74 44 61 74 61 20 65 78 74 65 6e 64 73 20 5c 52 | ryIteratorWithoutData.extends.\R |
88420 | 65 63 75 72 73 69 76 65 46 69 6c 74 65 72 49 74 65 72 61 74 6f 72 20 7b 0a 09 70 75 62 6c 69 63 | ecursiveFilterIterator.{..public |
88440 | 20 66 75 6e 63 74 69 6f 6e 20 61 63 63 65 70 74 28 29 20 7b 0a 09 09 2f 2a 2a 20 40 76 61 72 20 | .function.accept().{.../**.@var. |
88460 | 5c 44 69 72 65 63 74 6f 72 79 49 74 65 72 61 74 6f 72 20 24 74 68 69 73 20 2a 2f 0a 09 09 24 65 | \DirectoryIterator.$this.*/...$e |
88480 | 78 63 6c 75 64 65 73 20 3d 20 5b 0a 09 09 09 27 2e 72 6e 64 27 2c 0a 09 09 09 27 2e 77 65 6c 6c | xcludes.=.[....'.rnd',....'.well |
884a0 | 2d 6b 6e 6f 77 6e 27 2c 0a 09 09 09 27 64 61 74 61 27 2c 0a 09 09 09 27 2e 2e 27 2c 0a 09 09 5d | -known',....'data',....'..',...] |
884c0 | 3b 0a 09 09 72 65 74 75 72 6e 20 21 28 69 6e 5f 61 72 72 61 79 28 24 74 68 69 73 2d 3e 63 75 72 | ;...return.!(in_array($this->cur |
884e0 | 72 65 6e 74 28 29 2d 3e 67 65 74 46 69 6c 65 6e 61 6d 65 28 29 2c 20 24 65 78 63 6c 75 64 65 73 | rent()->getFilename(),.$excludes |
88500 | 2c 20 74 72 75 65 29 20 7c 7c 20 24 74 68 69 73 2d 3e 63 75 72 72 65 6e 74 28 29 2d 3e 69 73 44 | ,.true).||.$this->current()->isD |
88520 | 69 72 28 29 29 3b 0a 09 7d 0a 7d 0a 3c 3f 70 68 70 0a 2f 2a 2a 0a 20 2a 20 40 63 6f 70 79 72 69 | ir());..}.}.<?php./**..*.@copyri |
88540 | 67 68 74 20 43 6f 70 79 72 69 67 68 74 20 28 63 29 20 32 30 31 36 2d 32 30 31 37 20 4c 75 6b 61 | ght.Copyright.(c).2016-2017.Luka |
88560 | 73 20 52 65 73 63 68 6b 65 20 3c 6c 75 6b 61 73 40 73 74 61 74 75 73 63 6f 64 65 2e 63 68 3e 0a | s.Reschke.<lukas@statuscode.ch>. |
88580 | 20 2a 20 40 63 6f 70 79 72 69 67 68 74 20 43 6f 70 79 72 69 67 68 74 20 28 63 29 20 32 30 31 36 | .*.@copyright.Copyright.(c).2016 |
885a0 | 20 4d 6f 72 72 69 73 20 4a 6f 62 6b 65 20 3c 68 65 79 40 6d 6f 72 72 69 73 6a 6f 62 6b 65 2e 64 | .Morris.Jobke.<hey@morrisjobke.d |
885c0 | 65 3e 0a 20 2a 20 40 63 6f 70 79 72 69 67 68 74 20 43 6f 70 79 72 69 67 68 74 20 28 63 29 20 32 | e>..*.@copyright.Copyright.(c).2 |
885e0 | 30 31 38 20 4a 6f 6e 61 73 20 53 75 6c 7a 65 72 20 3c 6a 6f 6e 61 73 40 76 69 6f 6c 6f 6e 63 65 | 018.Jonas.Sulzer.<jonas@violonce |
88600 | 6c 6c 6f 2e 63 68 3e 0a 20 2a 0a 20 2a 20 40 6c 69 63 65 6e 73 65 20 47 4e 55 20 41 47 50 4c 20 | llo.ch>..*..*.@license.GNU.AGPL. |
88620 | 76 65 72 73 69 6f 6e 20 33 20 6f 72 20 61 6e 79 20 6c 61 74 65 72 20 76 65 72 73 69 6f 6e 0a 20 | version.3.or.any.later.version.. |
88640 | 2a 0a 20 2a 20 54 68 69 73 20 70 72 6f 67 72 61 6d 20 69 73 20 66 72 65 65 20 73 6f 66 74 77 61 | *..*.This.program.is.free.softwa |
88660 | 72 65 3a 20 79 6f 75 20 63 61 6e 20 72 65 64 69 73 74 72 69 62 75 74 65 20 69 74 20 61 6e 64 2f | re:.you.can.redistribute.it.and/ |
88680 | 6f 72 20 6d 6f 64 69 66 79 0a 20 2a 20 69 74 20 75 6e 64 65 72 20 74 68 65 20 74 65 72 6d 73 20 | or.modify..*.it.under.the.terms. |
886a0 | 6f 66 20 74 68 65 20 47 4e 55 20 41 66 66 65 72 6f 20 47 65 6e 65 72 61 6c 20 50 75 62 6c 69 63 | of.the.GNU.Affero.General.Public |
886c0 | 20 4c 69 63 65 6e 73 65 20 61 73 0a 20 2a 20 70 75 62 6c 69 73 68 65 64 20 62 79 20 74 68 65 20 | .License.as..*.published.by.the. |
886e0 | 46 72 65 65 20 53 6f 66 74 77 61 72 65 20 46 6f 75 6e 64 61 74 69 6f 6e 2c 20 65 69 74 68 65 72 | Free.Software.Foundation,.either |
88700 | 20 76 65 72 73 69 6f 6e 20 33 20 6f 66 20 74 68 65 0a 20 2a 20 4c 69 63 65 6e 73 65 2c 20 6f 72 | .version.3.of.the..*.License,.or |
88720 | 20 28 61 74 20 79 6f 75 72 20 6f 70 74 69 6f 6e 29 20 61 6e 79 20 6c 61 74 65 72 20 76 65 72 73 | .(at.your.option).any.later.vers |
88740 | 69 6f 6e 2e 0a 20 2a 0a 20 2a 20 54 68 69 73 20 70 72 6f 67 72 61 6d 20 69 73 20 64 69 73 74 72 | ion...*..*.This.program.is.distr |
88760 | 69 62 75 74 65 64 20 69 6e 20 74 68 65 20 68 6f 70 65 20 74 68 61 74 20 69 74 20 77 69 6c 6c 20 | ibuted.in.the.hope.that.it.will. |
88780 | 62 65 20 75 73 65 66 75 6c 2c 0a 20 2a 20 62 75 74 20 57 49 54 48 4f 55 54 20 41 4e 59 20 57 41 | be.useful,..*.but.WITHOUT.ANY.WA |
887a0 | 52 52 41 4e 54 59 3b 20 77 69 74 68 6f 75 74 20 65 76 65 6e 20 74 68 65 20 69 6d 70 6c 69 65 64 | RRANTY;.without.even.the.implied |
887c0 | 20 77 61 72 72 61 6e 74 79 20 6f 66 0a 20 2a 20 4d 45 52 43 48 41 4e 54 41 42 49 4c 49 54 59 20 | .warranty.of..*.MERCHANTABILITY. |
887e0 | 6f 72 20 46 49 54 4e 45 53 53 20 46 4f 52 20 41 20 50 41 52 54 49 43 55 4c 41 52 20 50 55 52 50 | or.FITNESS.FOR.A.PARTICULAR.PURP |
88800 | 4f 53 45 2e 20 20 53 65 65 20 74 68 65 0a 20 2a 20 47 4e 55 20 41 66 66 65 72 6f 20 47 65 6e 65 | OSE...See.the..*.GNU.Affero.Gene |
88820 | 72 61 6c 20 50 75 62 6c 69 63 20 4c 69 63 65 6e 73 65 20 66 6f 72 20 6d 6f 72 65 20 64 65 74 61 | ral.Public.License.for.more.deta |
88840 | 69 6c 73 2e 0a 20 2a 0a 20 2a 20 59 6f 75 20 73 68 6f 75 6c 64 20 68 61 76 65 20 72 65 63 65 69 | ils...*..*.You.should.have.recei |
88860 | 76 65 64 20 61 20 63 6f 70 79 20 6f 66 20 74 68 65 20 47 4e 55 20 41 66 66 65 72 6f 20 47 65 6e | ved.a.copy.of.the.GNU.Affero.Gen |
88880 | 65 72 61 6c 20 50 75 62 6c 69 63 20 4c 69 63 65 6e 73 65 0a 20 2a 20 61 6c 6f 6e 67 20 77 69 74 | eral.Public.License..*.along.wit |
888a0 | 68 20 74 68 69 73 20 70 72 6f 67 72 61 6d 2e 20 20 49 66 20 6e 6f 74 2c 20 73 65 65 20 3c 68 74 | h.this.program...If.not,.see.<ht |
888c0 | 74 70 3a 2f 2f 77 77 77 2e 67 6e 75 2e 6f 72 67 2f 6c 69 63 65 6e 73 65 73 2f 3e 2e 0a 20 2a 0a | tp://www.gnu.org/licenses/>...*. |
888e0 | 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 4e 43 5c 55 70 64 61 74 65 72 3b 0a 0a 63 6c 61 73 | .*/..namespace.NC\Updater;..clas |
88900 | 73 20 55 70 64 61 74 65 72 20 7b 0a 09 2f 2a 2a 20 40 76 61 72 20 73 74 72 69 6e 67 20 2a 2f 0a | s.Updater.{../**.@var.string.*/. |
88920 | 09 70 72 69 76 61 74 65 20 24 62 61 73 65 44 69 72 3b 0a 09 2f 2a 2a 20 40 76 61 72 20 61 72 72 | .private.$baseDir;../**.@var.arr |
88940 | 61 79 20 2a 2f 0a 09 70 72 69 76 61 74 65 20 24 63 6f 6e 66 69 67 56 61 6c 75 65 73 20 3d 20 5b | ay.*/..private.$configValues.=.[ |
88960 | 5d 3b 0a 09 2f 2a 2a 20 40 76 61 72 20 73 74 72 69 6e 67 20 2a 2f 0a 09 70 72 69 76 61 74 65 20 | ];../**.@var.string.*/..private. |
88980 | 24 63 75 72 72 65 6e 74 56 65 72 73 69 6f 6e 20 3d 20 27 75 6e 6b 6e 6f 77 6e 27 3b 0a 09 2f 2a | $currentVersion.=.'unknown';../* |
889a0 | 2a 20 40 76 61 72 20 73 74 72 69 6e 67 20 2a 2f 0a 09 70 72 69 76 61 74 65 20 24 62 75 69 6c 64 | *.@var.string.*/..private.$build |
889c0 | 54 69 6d 65 3b 0a 09 2f 2a 2a 20 40 76 61 72 20 62 6f 6f 6c 20 2a 2f 0a 09 70 72 69 76 61 74 65 | Time;../**.@var.bool.*/..private |
889e0 | 20 24 75 70 64 61 74 65 41 76 61 69 6c 61 62 6c 65 20 3d 20 66 61 6c 73 65 3b 0a 09 2f 2a 2a 20 | .$updateAvailable.=.false;../**. |
88a00 | 40 76 61 72 20 73 74 72 69 6e 67 20 2a 2f 0a 09 70 72 69 76 61 74 65 20 24 72 65 71 75 65 73 74 | @var.string.*/..private.$request |
88a20 | 49 44 20 3d 20 6e 75 6c 6c 3b 0a 09 2f 2a 2a 20 40 76 61 72 20 62 6f 6f 6c 20 2a 2f 0a 09 70 72 | ID.=.null;../**.@var.bool.*/..pr |
88a40 | 69 76 61 74 65 20 24 64 69 73 61 62 6c 65 64 20 3d 20 66 61 6c 73 65 3b 0a 0a 09 2f 2a 2a 0a 09 | ivate.$disabled.=.false;.../**.. |
88a60 | 20 2a 20 55 70 64 61 74 65 72 20 63 6f 6e 73 74 72 75 63 74 6f 72 0a 09 20 2a 20 40 70 61 72 61 | .*.Updater.constructor...*.@para |
88a80 | 6d 20 24 62 61 73 65 44 69 72 20 73 74 72 69 6e 67 20 74 68 65 20 61 62 73 6f 6c 75 74 65 20 70 | m.$baseDir.string.the.absolute.p |
88aa0 | 61 74 68 20 74 6f 20 74 68 65 20 2f 75 70 64 61 74 65 72 2f 20 64 69 72 65 63 74 6f 72 79 20 69 | ath.to.the./updater/.directory.i |
88ac0 | 6e 20 74 68 65 20 4e 65 78 74 63 6c 6f 75 64 20 72 6f 6f 74 0a 09 20 2a 20 40 74 68 72 6f 77 73 | n.the.Nextcloud.root...*.@throws |
88ae0 | 20 5c 45 78 63 65 70 74 69 6f 6e 0a 09 20 2a 2f 0a 09 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f | .\Exception...*/..public.functio |
88b00 | 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 74 28 24 62 61 73 65 44 69 72 29 20 7b 0a 09 09 24 74 68 69 | n.__construct($baseDir).{...$thi |
88b20 | 73 2d 3e 62 61 73 65 44 69 72 20 3d 20 24 62 61 73 65 44 69 72 3b 0a 0a 09 09 69 66 28 24 64 69 | s->baseDir.=.$baseDir;....if($di |
88b40 | 72 20 3d 20 67 65 74 65 6e 76 28 27 4e 45 58 54 43 4c 4f 55 44 5f 43 4f 4e 46 49 47 5f 44 49 52 | r.=.getenv('NEXTCLOUD_CONFIG_DIR |
88b60 | 27 29 29 20 7b 0a 09 09 09 24 63 6f 6e 66 69 67 46 69 6c 65 4e 61 6d 65 20 3d 20 72 74 72 69 6d | ')).{....$configFileName.=.rtrim |
88b80 | 28 24 64 69 72 2c 20 27 2f 27 29 20 2e 20 27 2f 63 6f 6e 66 69 67 2e 70 68 70 27 3b 0a 09 09 7d | ($dir,.'/')...'/config.php';...} |
88ba0 | 20 65 6c 73 65 20 7b 0a 09 09 09 24 63 6f 6e 66 69 67 46 69 6c 65 4e 61 6d 65 20 3d 20 24 74 68 | .else.{....$configFileName.=.$th |
88bc0 | 69 73 2d 3e 62 61 73 65 44 69 72 20 2e 20 27 2f 2e 2e 2f 63 6f 6e 66 69 67 2f 63 6f 6e 66 69 67 | is->baseDir...'/../config/config |
88be0 | 2e 70 68 70 27 3b 0a 09 09 7d 0a 09 09 69 66 20 28 21 66 69 6c 65 5f 65 78 69 73 74 73 28 24 63 | .php';...}...if.(!file_exists($c |
88c00 | 6f 6e 66 69 67 46 69 6c 65 4e 61 6d 65 29 29 20 7b 0a 09 09 09 74 68 72 6f 77 20 6e 65 77 20 5c | onfigFileName)).{....throw.new.\ |
88c20 | 45 78 63 65 70 74 69 6f 6e 28 27 43 6f 75 6c 64 20 6e 6f 74 20 66 69 6e 64 20 63 6f 6e 66 69 67 | Exception('Could.not.find.config |
88c40 | 2e 70 68 70 2e 20 49 73 20 74 68 69 73 20 66 69 6c 65 20 69 6e 20 74 68 65 20 22 75 70 64 61 74 | .php..Is.this.file.in.the."updat |
88c60 | 65 72 22 20 73 75 62 66 6f 6c 64 65 72 20 6f 66 20 4e 65 78 74 63 6c 6f 75 64 3f 27 29 3b 0a 09 | er".subfolder.of.Nextcloud?');.. |
88c80 | 09 7d 0a 0a 09 09 2f 2a 2a 20 40 76 61 72 20 61 72 72 61 79 20 24 43 4f 4e 46 49 47 20 2a 2f 0a | .}..../**.@var.array.$CONFIG.*/. |
88ca0 | 09 09 72 65 71 75 69 72 65 5f 6f 6e 63 65 20 24 63 6f 6e 66 69 67 46 69 6c 65 4e 61 6d 65 3b 0a | ..require_once.$configFileName;. |
88cc0 | 09 09 24 74 68 69 73 2d 3e 63 6f 6e 66 69 67 56 61 6c 75 65 73 20 3d 20 24 43 4f 4e 46 49 47 3b | ..$this->configValues.=.$CONFIG; |
88ce0 | 0a 0a 09 09 69 66 20 28 70 68 70 5f 73 61 70 69 5f 6e 61 6d 65 28 29 20 21 3d 3d 20 27 63 6c 69 | ....if.(php_sapi_name().!==.'cli |
88d00 | 27 20 26 26 20 28 24 74 68 69 73 2d 3e 63 6f 6e 66 69 67 56 61 6c 75 65 73 5b 27 75 70 67 72 61 | '.&&.($this->configValues['upgra |
88d20 | 64 65 2e 64 69 73 61 62 6c 65 2d 77 65 62 27 5d 20 3f 3f 20 66 61 6c 73 65 29 29 20 7b 0a 09 09 | de.disable-web'].??.false)).{... |
88d40 | 09 2f 2f 20 75 70 64 61 74 65 72 20 64 69 73 61 62 6c 65 64 0a 09 09 09 24 74 68 69 73 2d 3e 64 | .//.updater.disabled....$this->d |
88d60 | 69 73 61 62 6c 65 64 20 3d 20 74 72 75 65 3b 0a 09 09 09 72 65 74 75 72 6e 3b 0a 09 09 7d 0a 0a | isabled.=.true;....return;...}.. |
88d80 | 09 09 24 64 61 74 61 44 69 72 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 44 61 74 61 44 69 72 65 63 | ..$dataDir.=.$this->getDataDirec |
88da0 | 74 6f 72 79 4c 6f 63 61 74 69 6f 6e 28 29 3b 0a 09 09 69 66 28 65 6d 70 74 79 28 24 64 61 74 61 | toryLocation();...if(empty($data |
88dc0 | 44 69 72 29 20 7c 7c 20 21 69 73 5f 73 74 72 69 6e 67 28 24 64 61 74 61 44 69 72 29 29 20 7b 0a | Dir).||.!is_string($dataDir)).{. |
88de0 | 09 09 09 74 68 72 6f 77 20 6e 65 77 20 5c 45 78 63 65 70 74 69 6f 6e 28 27 43 6f 75 6c 64 20 6e | ...throw.new.\Exception('Could.n |
88e00 | 6f 74 20 72 65 61 64 20 64 61 74 61 20 64 69 72 65 63 74 6f 72 79 20 66 72 6f 6d 20 63 6f 6e 66 | ot.read.data.directory.from.conf |
88e20 | 69 67 2e 70 68 70 2e 27 29 3b 0a 09 09 7d 0a 0a 09 09 24 76 65 72 73 69 6f 6e 46 69 6c 65 4e 61 | ig.php.');...}....$versionFileNa |
88e40 | 6d 65 20 3d 20 24 74 68 69 73 2d 3e 62 61 73 65 44 69 72 20 2e 20 27 2f 2e 2e 2f 76 65 72 73 69 | me.=.$this->baseDir...'/../versi |
88e60 | 6f 6e 2e 70 68 70 27 3b 0a 09 09 69 66 20 28 21 66 69 6c 65 5f 65 78 69 73 74 73 28 24 76 65 72 | on.php';...if.(!file_exists($ver |
88e80 | 73 69 6f 6e 46 69 6c 65 4e 61 6d 65 29 29 20 7b 0a 09 09 09 2f 2f 20 66 61 6c 6c 62 61 63 6b 20 | sionFileName)).{....//.fallback. |
88ea0 | 74 6f 20 76 65 72 73 69 6f 6e 20 69 6e 20 63 6f 6e 66 69 67 2e 70 68 70 0a 09 09 09 24 76 65 72 | to.version.in.config.php....$ver |
88ec0 | 73 69 6f 6e 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 43 6f 6e 66 69 67 4f 70 74 69 6f 6e 28 27 76 | sion.=.$this->getConfigOption('v |
88ee0 | 65 72 73 69 6f 6e 27 29 3b 0a 09 09 09 24 62 75 69 6c 64 54 69 6d 65 20 3d 20 27 27 3b 0a 09 09 | ersion');....$buildTime.=.'';... |
88f00 | 7d 20 65 6c 73 65 20 7b 0a 09 09 09 2f 2a 2a 20 40 76 61 72 20 73 74 72 69 6e 67 20 24 4f 43 5f | }.else.{..../**.@var.string.$OC_ |
88f20 | 56 65 72 73 69 6f 6e 53 74 72 69 6e 67 20 2a 2f 0a 09 09 09 2f 2a 2a 20 40 76 61 72 20 73 74 72 | VersionString.*/..../**.@var.str |
88f40 | 69 6e 67 20 24 4f 43 5f 42 75 69 6c 64 20 2a 2f 0a 09 09 09 72 65 71 75 69 72 65 5f 6f 6e 63 65 | ing.$OC_Build.*/....require_once |
88f60 | 20 24 76 65 72 73 69 6f 6e 46 69 6c 65 4e 61 6d 65 3b 0a 09 09 09 24 76 65 72 73 69 6f 6e 20 3d | .$versionFileName;....$version.= |
88f80 | 20 24 4f 43 5f 56 65 72 73 69 6f 6e 53 74 72 69 6e 67 3b 0a 09 09 09 24 62 75 69 6c 64 54 69 6d | .$OC_VersionString;....$buildTim |
88fa0 | 65 20 3d 20 24 4f 43 5f 42 75 69 6c 64 3b 0a 09 09 7d 0a 0a 09 09 69 66 28 24 76 65 72 73 69 6f | e.=.$OC_Build;...}....if($versio |
88fc0 | 6e 20 3d 3d 3d 20 6e 75 6c 6c 29 20 7b 0a 09 09 09 72 65 74 75 72 6e 3b 0a 09 09 7d 0a 09 09 69 | n.===.null).{....return;...}...i |
88fe0 | 66 28 24 62 75 69 6c 64 54 69 6d 65 20 3d 3d 3d 20 6e 75 6c 6c 29 20 7b 0a 09 09 09 72 65 74 75 | f($buildTime.===.null).{....retu |
89000 | 72 6e 3b 0a 09 09 7d 0a 0a 09 09 2f 2f 20 6e 6f 72 6d 61 6c 69 7a 65 20 76 65 72 73 69 6f 6e 20 | rn;...}....//.normalize.version. |
89020 | 74 6f 20 33 20 64 69 67 69 74 73 0a 09 09 24 73 70 6c 69 74 74 65 64 56 65 72 73 69 6f 6e 20 3d | to.3.digits...$splittedVersion.= |
89040 | 20 65 78 70 6c 6f 64 65 28 27 2e 27 2c 20 24 76 65 72 73 69 6f 6e 29 3b 0a 09 09 69 66 28 73 69 | .explode('.',.$version);...if(si |
89060 | 7a 65 6f 66 28 24 73 70 6c 69 74 74 65 64 56 65 72 73 69 6f 6e 29 20 3e 3d 20 33 29 20 7b 0a 09 | zeof($splittedVersion).>=.3).{.. |
89080 | 09 09 24 73 70 6c 69 74 74 65 64 56 65 72 73 69 6f 6e 20 3d 20 61 72 72 61 79 5f 73 6c 69 63 65 | ..$splittedVersion.=.array_slice |
890a0 | 28 24 73 70 6c 69 74 74 65 64 56 65 72 73 69 6f 6e 2c 20 30 2c 20 33 29 3b 0a 09 09 7d 0a 0a 09 | ($splittedVersion,.0,.3);...}... |
890c0 | 09 24 74 68 69 73 2d 3e 63 75 72 72 65 6e 74 56 65 72 73 69 6f 6e 20 3d 20 69 6d 70 6c 6f 64 65 | .$this->currentVersion.=.implode |
890e0 | 28 27 2e 27 2c 20 24 73 70 6c 69 74 74 65 64 56 65 72 73 69 6f 6e 29 3b 0a 09 09 24 74 68 69 73 | ('.',.$splittedVersion);...$this |
89100 | 2d 3e 62 75 69 6c 64 54 69 6d 65 20 3d 20 24 62 75 69 6c 64 54 69 6d 65 3b 0a 09 7d 0a 0a 09 2f | ->buildTime.=.$buildTime;..}.../ |
89120 | 2a 2a 0a 09 20 2a 20 52 65 74 75 72 6e 73 20 77 68 65 74 68 65 72 20 74 68 65 20 77 65 62 20 75 | **...*.Returns.whether.the.web.u |
89140 | 70 64 61 74 65 72 20 69 73 20 64 69 73 61 62 6c 65 64 0a 09 20 2a 0a 09 20 2a 20 40 72 65 74 75 | pdater.is.disabled...*...*.@retu |
89160 | 72 6e 20 62 6f 6f 6c 0a 09 20 2a 2f 0a 09 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 69 73 | rn.bool...*/..public.function.is |
89180 | 44 69 73 61 62 6c 65 64 28 29 20 7b 0a 09 09 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 64 69 73 | Disabled().{...return.$this->dis |
891a0 | 61 62 6c 65 64 3b 0a 09 7d 0a 0a 09 2f 2a 2a 0a 09 20 2a 20 52 65 74 75 72 6e 73 20 63 75 72 72 | abled;..}.../**...*.Returns.curr |
891c0 | 65 6e 74 20 76 65 72 73 69 6f 6e 20 6f 72 20 22 75 6e 6b 6e 6f 77 6e 22 20 69 66 20 74 68 69 73 | ent.version.or."unknown".if.this |
891e0 | 20 63 6f 75 6c 64 20 6e 6f 74 20 62 65 20 64 65 74 65 72 6d 69 6e 65 64 2e 0a 09 20 2a 0a 09 20 | .could.not.be.determined....*... |
89200 | 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 0a 09 20 2a 2f 0a 09 70 75 62 6c 69 63 20 66 75 | *.@return.string...*/..public.fu |
89220 | 6e 63 74 69 6f 6e 20 67 65 74 43 75 72 72 65 6e 74 56 65 72 73 69 6f 6e 28 29 20 7b 0a 09 09 72 | nction.getCurrentVersion().{...r |
89240 | 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 63 75 72 72 65 6e 74 56 65 72 73 69 6f 6e 3b 0a 09 7d 0a | eturn.$this->currentVersion;..}. |
89260 | 0a 09 2f 2a 2a 0a 09 20 2a 20 52 65 74 75 72 6e 73 20 63 75 72 72 65 6e 74 6c 79 20 75 73 65 64 | ../**...*.Returns.currently.used |
89280 | 20 72 65 6c 65 61 73 65 20 63 68 61 6e 6e 65 6c 0a 09 20 2a 0a 09 20 2a 20 40 72 65 74 75 72 6e | .release.channel...*...*.@return |
892a0 | 20 73 74 72 69 6e 67 0a 09 20 2a 2f 0a 09 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 67 | .string...*/..private.function.g |
892c0 | 65 74 43 75 72 72 65 6e 74 52 65 6c 65 61 73 65 43 68 61 6e 6e 65 6c 28 29 20 7b 0a 09 09 72 65 | etCurrentReleaseChannel().{...re |
892e0 | 74 75 72 6e 20 21 69 73 5f 6e 75 6c 6c 28 24 74 68 69 73 2d 3e 67 65 74 43 6f 6e 66 69 67 4f 70 | turn.!is_null($this->getConfigOp |
89300 | 74 69 6f 6e 28 27 75 70 64 61 74 65 72 2e 72 65 6c 65 61 73 65 2e 63 68 61 6e 6e 65 6c 27 29 29 | tion('updater.release.channel')) |
89320 | 20 3f 20 24 74 68 69 73 2d 3e 67 65 74 43 6f 6e 66 69 67 4f 70 74 69 6f 6e 28 27 75 70 64 61 74 | .?.$this->getConfigOption('updat |
89340 | 65 72 2e 72 65 6c 65 61 73 65 2e 63 68 61 6e 6e 65 6c 27 29 20 3a 20 27 73 74 61 62 6c 65 27 3b | er.release.channel').:.'stable'; |
89360 | 0a 09 7d 0a 0a 09 2f 2a 2a 0a 09 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 0a 09 20 2a | ..}.../**...*.@return.string...* |
89380 | 20 40 74 68 72 6f 77 73 20 5c 45 78 63 65 70 74 69 6f 6e 0a 09 20 2a 2f 0a 09 70 75 62 6c 69 63 | .@throws.\Exception...*/..public |
893a0 | 20 66 75 6e 63 74 69 6f 6e 20 63 68 65 63 6b 46 6f 72 55 70 64 61 74 65 28 29 20 7b 0a 09 09 24 | .function.checkForUpdate().{...$ |
893c0 | 72 65 73 70 6f 6e 73 65 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 55 70 64 61 74 65 53 65 72 76 65 | response.=.$this->getUpdateServe |
893e0 | 72 52 65 73 70 6f 6e 73 65 28 29 3b 0a 0a 09 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 | rResponse();....$this->silentLog |
89400 | 28 27 5b 69 6e 66 6f 5d 20 63 68 65 63 6b 46 6f 72 55 70 64 61 74 65 28 29 20 27 20 2e 20 70 72 | ('[info].checkForUpdate().'...pr |
89420 | 69 6e 74 5f 72 28 24 72 65 73 70 6f 6e 73 65 2c 20 74 72 75 65 29 29 3b 0a 0a 09 09 24 76 65 72 | int_r($response,.true));....$ver |
89440 | 73 69 6f 6e 20 3d 20 69 73 73 65 74 28 24 72 65 73 70 6f 6e 73 65 5b 27 76 65 72 73 69 6f 6e 27 | sion.=.isset($response['version' |
89460 | 5d 29 20 3f 20 24 72 65 73 70 6f 6e 73 65 5b 27 76 65 72 73 69 6f 6e 27 5d 20 3a 20 27 27 3b 0a | ]).?.$response['version'].:.'';. |
89480 | 09 09 24 76 65 72 73 69 6f 6e 53 74 72 69 6e 67 20 3d 20 69 73 73 65 74 28 24 72 65 73 70 6f 6e | ..$versionString.=.isset($respon |
894a0 | 73 65 5b 27 76 65 72 73 69 6f 6e 73 74 72 69 6e 67 27 5d 29 20 3f 20 24 72 65 73 70 6f 6e 73 65 | se['versionstring']).?.$response |
894c0 | 5b 27 76 65 72 73 69 6f 6e 73 74 72 69 6e 67 27 5d 20 3a 20 27 27 3b 0a 0a 09 09 69 66 20 28 24 | ['versionstring'].:.'';....if.($ |
894e0 | 76 65 72 73 69 6f 6e 20 21 3d 3d 20 27 27 20 26 26 20 24 76 65 72 73 69 6f 6e 20 21 3d 3d 20 24 | version.!==.''.&&.$version.!==.$ |
89500 | 74 68 69 73 2d 3e 63 75 72 72 65 6e 74 56 65 72 73 69 6f 6e 29 20 7b 0a 09 09 09 24 74 68 69 73 | this->currentVersion).{....$this |
89520 | 2d 3e 75 70 64 61 74 65 41 76 61 69 6c 61 62 6c 65 20 3d 20 74 72 75 65 3b 0a 09 09 09 24 72 65 | ->updateAvailable.=.true;....$re |
89540 | 6c 65 61 73 65 43 68 61 6e 6e 65 6c 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 43 75 72 72 65 6e 74 | leaseChannel.=.$this->getCurrent |
89560 | 52 65 6c 65 61 73 65 43 68 61 6e 6e 65 6c 28 29 3b 0a 09 09 09 24 75 70 64 61 74 65 54 65 78 74 | ReleaseChannel();....$updateText |
89580 | 20 3d 20 27 55 70 64 61 74 65 20 74 6f 20 27 20 2e 20 68 74 6d 6c 65 6e 74 69 74 69 65 73 28 24 | .=.'Update.to.'...htmlentities($ |
895a0 | 76 65 72 73 69 6f 6e 53 74 72 69 6e 67 29 20 2e 20 27 20 61 76 61 69 6c 61 62 6c 65 2e 20 28 63 | versionString)...'.available..(c |
895c0 | 68 61 6e 6e 65 6c 3a 20 22 27 20 2e 20 68 74 6d 6c 65 6e 74 69 74 69 65 73 28 24 72 65 6c 65 61 | hannel:."'...htmlentities($relea |
895e0 | 73 65 43 68 61 6e 6e 65 6c 29 20 2e 20 27 22 29 3c 62 72 20 2f 3e 3c 73 70 61 6e 20 63 6c 61 73 | seChannel)...'")<br./><span.clas |
89600 | 73 3d 22 6c 69 67 68 74 22 3e 46 6f 6c 6c 6f 77 69 6e 67 20 66 69 6c 65 20 77 69 6c 6c 20 62 65 | s="light">Following.file.will.be |
89620 | 20 64 6f 77 6e 6c 6f 61 64 65 64 20 61 75 74 6f 6d 61 74 69 63 61 6c 6c 79 3a 3c 2f 73 70 61 6e | .downloaded.automatically:</span |
89640 | 3e 20 3c 63 6f 64 65 20 63 6c 61 73 73 3d 22 6c 69 67 68 74 22 3e 27 20 2e 20 24 72 65 73 70 6f | >.<code.class="light">'...$respo |
89660 | 6e 73 65 5b 27 75 72 6c 27 5d 20 2e 20 27 3c 2f 63 6f 64 65 3e 27 3b 0a 0a 09 09 09 2f 2f 20 6f | nse['url']...'</code>';.....//.o |
89680 | 6e 6c 79 20 73 68 6f 77 20 63 68 61 6e 67 65 6c 6f 67 20 6c 69 6e 6b 20 66 6f 72 20 73 74 61 62 | nly.show.changelog.link.for.stab |
896a0 | 6c 65 20 72 65 6c 65 61 73 65 73 20 28 6e 6f 6e 2d 52 43 20 26 20 6e 6f 6e 2d 62 65 74 61 29 0a | le.releases.(non-RC.&.non-beta). |
896c0 | 09 09 09 69 66 20 28 21 70 72 65 67 5f 6d 61 74 63 68 28 27 21 28 72 63 7c 62 65 74 61 29 21 69 | ...if.(!preg_match('!(rc|beta)!i |
896e0 | 27 2c 20 24 76 65 72 73 69 6f 6e 53 74 72 69 6e 67 29 29 20 7b 0a 09 09 09 09 24 63 68 61 6e 67 | ',.$versionString)).{.....$chang |
89700 | 65 6c 6f 67 55 52 4c 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 43 68 61 6e 67 65 6c 6f 67 55 52 4c | elogURL.=.$this->getChangelogURL |
89720 | 28 73 75 62 73 74 72 28 24 76 65 72 73 69 6f 6e 2c 20 30 2c 20 73 74 72 72 70 6f 73 28 24 76 65 | (substr($version,.0,.strrpos($ve |
89740 | 72 73 69 6f 6e 2c 20 27 2e 27 29 29 29 3b 0a 09 09 09 09 24 75 70 64 61 74 65 54 65 78 74 20 2e | rsion,.'.')));.....$updateText.. |
89760 | 3d 20 27 3c 62 72 20 2f 3e 3c 61 20 63 6c 61 73 73 3d 22 65 78 74 65 72 6e 61 6c 5f 6c 69 6e 6b | =.'<br./><a.class="external_link |
89780 | 22 20 68 72 65 66 3d 22 27 20 2e 20 24 63 68 61 6e 67 65 6c 6f 67 55 52 4c 20 2e 20 27 22 20 74 | ".href="'...$changelogURL...'".t |
897a0 | 61 72 67 65 74 3d 22 5f 62 6c 61 6e 6b 22 20 72 65 6c 3d 22 6e 6f 72 65 66 65 72 72 65 72 20 6e | arget="_blank".rel="noreferrer.n |
897c0 | 6f 6f 70 65 6e 65 72 22 3e 4f 70 65 6e 20 63 68 61 6e 67 65 6c 6f 67 20 e2 86 97 3c 2f 61 3e 27 | oopener">Open.changelog....</a>' |
897e0 | 3b 0a 09 09 09 7d 0a 09 09 7d 20 65 6c 73 65 20 7b 0a 09 09 09 24 75 70 64 61 74 65 54 65 78 74 | ;....}...}.else.{....$updateText |
89800 | 20 3d 20 27 4e 6f 20 75 70 64 61 74 65 20 61 76 61 69 6c 61 62 6c 65 2e 27 3b 0a 09 09 7d 0a 0a | .=.'No.update.available.';...}.. |
89820 | 09 09 69 66 20 28 24 74 68 69 73 2d 3e 75 70 64 61 74 65 41 76 61 69 6c 61 62 6c 65 20 26 26 20 | ..if.($this->updateAvailable.&&. |
89840 | 69 73 73 65 74 28 24 72 65 73 70 6f 6e 73 65 5b 27 61 75 74 6f 75 70 64 61 74 65 72 27 5d 29 20 | isset($response['autoupdater']). |
89860 | 26 26 20 21 28 24 72 65 73 70 6f 6e 73 65 5b 27 61 75 74 6f 75 70 64 61 74 65 72 27 5d 20 3d 3d | &&.!($response['autoupdater'].== |
89880 | 3d 20 31 20 7c 7c 20 24 72 65 73 70 6f 6e 73 65 5b 27 61 75 74 6f 75 70 64 61 74 65 72 27 5d 20 | =.1.||.$response['autoupdater']. |
898a0 | 3d 3d 3d 20 27 31 27 29 29 20 7b 0a 09 09 09 24 74 68 69 73 2d 3e 75 70 64 61 74 65 41 76 61 69 | ===.'1')).{....$this->updateAvai |
898c0 | 6c 61 62 6c 65 20 3d 20 66 61 6c 73 65 3b 0a 0a 09 09 09 24 75 70 64 61 74 65 54 65 78 74 20 2e | lable.=.false;.....$updateText.. |
898e0 | 3d 20 27 3c 62 72 20 2f 3e 54 68 65 20 75 70 64 61 74 65 72 20 69 73 20 64 69 73 61 62 6c 65 64 | =.'<br./>The.updater.is.disabled |
89900 | 20 66 6f 72 20 74 68 69 73 20 75 70 64 61 74 65 20 2d 20 70 6c 65 61 73 65 20 75 70 64 61 74 65 | .for.this.update.-.please.update |
89920 | 20 6d 61 6e 75 61 6c 6c 79 2e 27 3b 0a 09 09 7d 0a 0a 09 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e | .manually.';...}....$this->silen |
89940 | 74 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 65 6e 64 20 6f 66 20 63 68 65 63 6b 46 6f 72 55 70 64 61 | tLog('[info].end.of.checkForUpda |
89960 | 74 65 28 29 20 27 20 2e 20 24 75 70 64 61 74 65 54 65 78 74 29 3b 0a 09 09 72 65 74 75 72 6e 20 | te().'...$updateText);...return. |
89980 | 24 75 70 64 61 74 65 54 65 78 74 3b 0a 09 7d 0a 0a 09 2f 2a 2a 0a 09 20 2a 20 52 65 74 75 72 6e | $updateText;..}.../**...*.Return |
899a0 | 73 20 62 6f 6f 6c 20 77 68 65 74 68 65 72 20 75 70 64 61 74 65 20 69 73 20 61 76 61 69 6c 61 62 | s.bool.whether.update.is.availab |
899c0 | 6c 65 20 6f 72 20 6e 6f 74 0a 09 20 2a 0a 09 20 2a 20 40 72 65 74 75 72 6e 20 62 6f 6f 6c 0a 09 | le.or.not...*...*.@return.bool.. |
899e0 | 20 2a 2f 0a 09 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 75 70 64 61 74 65 41 76 61 69 6c | .*/..public.function.updateAvail |
89a00 | 61 62 6c 65 28 29 20 7b 0a 09 09 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 75 70 64 61 74 65 41 | able().{...return.$this->updateA |
89a20 | 76 61 69 6c 61 62 6c 65 3b 0a 09 7d 0a 0a 09 2f 2a 2a 0a 09 20 2a 20 52 65 74 75 72 6e 73 20 74 | vailable;..}.../**...*.Returns.t |
89a40 | 68 65 20 73 70 65 63 69 66 69 65 64 20 63 6f 6e 66 69 67 20 6f 70 74 69 6f 6e 73 0a 09 20 2a 0a | he.specified.config.options...*. |
89a60 | 09 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6b 65 79 0a 09 20 2a 20 40 72 65 74 75 | ..*.@param.string.$key...*.@retu |
89a80 | 72 6e 20 6d 69 78 65 64 7c 6e 75 6c 6c 20 4e 75 6c 6c 20 69 66 20 74 68 65 20 65 6e 74 72 79 20 | rn.mixed|null.Null.if.the.entry. |
89aa0 | 69 73 20 6e 6f 74 20 66 6f 75 6e 64 0a 09 20 2a 2f 0a 09 70 75 62 6c 69 63 20 66 75 6e 63 74 69 | is.not.found...*/..public.functi |
89ac0 | 6f 6e 20 67 65 74 43 6f 6e 66 69 67 4f 70 74 69 6f 6e 28 24 6b 65 79 29 20 7b 0a 09 09 72 65 74 | on.getConfigOption($key).{...ret |
89ae0 | 75 72 6e 20 69 73 73 65 74 28 24 74 68 69 73 2d 3e 63 6f 6e 66 69 67 56 61 6c 75 65 73 5b 24 6b | urn.isset($this->configValues[$k |
89b00 | 65 79 5d 29 20 3f 20 24 74 68 69 73 2d 3e 63 6f 6e 66 69 67 56 61 6c 75 65 73 5b 24 6b 65 79 5d | ey]).?.$this->configValues[$key] |
89b20 | 20 3a 20 6e 75 6c 6c 3b 0a 09 7d 0a 0a 09 2f 2a 2a 0a 09 20 2a 20 47 65 74 73 20 74 68 65 20 64 | .:.null;..}.../**...*.Gets.the.d |
89b40 | 61 74 61 20 64 69 72 65 63 74 6f 72 79 20 6c 6f 63 61 74 69 6f 6e 20 6f 6e 20 74 68 65 20 6c 6f | ata.directory.location.on.the.lo |
89b60 | 63 61 6c 20 66 69 6c 65 73 79 73 74 65 6d 0a 09 20 2a 0a 09 20 2a 20 40 72 65 74 75 72 6e 20 73 | cal.filesystem...*...*.@return.s |
89b80 | 74 72 69 6e 67 0a 09 20 2a 2f 0a 09 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 | tring...*/..private.function.get |
89ba0 | 44 61 74 61 44 69 72 65 63 74 6f 72 79 4c 6f 63 61 74 69 6f 6e 28 29 20 7b 0a 09 09 72 65 74 75 | DataDirectoryLocation().{...retu |
89bc0 | 72 6e 20 24 74 68 69 73 2d 3e 63 6f 6e 66 69 67 56 61 6c 75 65 73 5b 27 64 61 74 61 64 69 72 65 | rn.$this->configValues['datadire |
89be0 | 63 74 6f 72 79 27 5d 3b 0a 09 7d 0a 0a 09 2f 2a 2a 0a 09 20 2a 20 52 65 74 75 72 6e 73 20 74 68 | ctory'];..}.../**...*.Returns.th |
89c00 | 65 20 65 78 70 65 63 74 65 64 20 66 69 6c 65 73 20 61 6e 64 20 66 6f 6c 64 65 72 73 20 61 73 20 | e.expected.files.and.folders.as. |
89c20 | 61 72 72 61 79 0a 09 20 2a 0a 09 20 2a 20 40 72 65 74 75 72 6e 20 61 72 72 61 79 0a 09 20 2a 2f | array...*...*.@return.array...*/ |
89c40 | 0a 09 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 45 78 70 65 63 74 65 64 45 6c | ..private.function.getExpectedEl |
89c60 | 65 6d 65 6e 74 73 4c 69 73 74 28 29 20 7b 0a 09 09 24 65 78 70 65 63 74 65 64 20 3d 20 5b 0a 09 | ementsList().{...$expected.=.[.. |
89c80 | 09 09 2f 2f 20 47 65 6e 65 72 69 63 0a 09 09 09 27 2e 27 2c 0a 09 09 09 27 2e 2e 27 2c 0a 09 09 | ..//.Generic....'.',....'..',... |
89ca0 | 09 2f 2f 20 46 6f 6c 64 65 72 73 0a 09 09 09 27 2e 77 65 6c 6c 2d 6b 6e 6f 77 6e 27 2c 0a 09 09 | .//.Folders....'.well-known',... |
89cc0 | 09 27 33 72 64 70 61 72 74 79 27 2c 0a 09 09 09 27 61 70 70 73 27 2c 0a 09 09 09 27 63 6f 6e 66 | .'3rdparty',....'apps',....'conf |
89ce0 | 69 67 27 2c 0a 09 09 09 27 63 6f 72 65 27 2c 0a 09 09 09 27 64 61 74 61 27 2c 0a 09 09 09 27 64 | ig',....'core',....'data',....'d |
89d00 | 69 73 74 27 2c 0a 09 09 09 27 6c 31 30 6e 27 2c 0a 09 09 09 27 6c 69 62 27 2c 0a 09 09 09 27 6f | ist',....'l10n',....'lib',....'o |
89d20 | 63 73 27 2c 0a 09 09 09 27 6f 63 73 2d 70 72 6f 76 69 64 65 72 27 2c 0a 09 09 09 27 6f 63 6d 2d | cs',....'ocs-provider',....'ocm- |
89d40 | 70 72 6f 76 69 64 65 72 27 2c 0a 09 09 09 27 72 65 73 6f 75 72 63 65 73 27 2c 0a 09 09 09 27 73 | provider',....'resources',....'s |
89d60 | 65 74 74 69 6e 67 73 27 2c 0a 09 09 09 27 74 68 65 6d 65 73 27 2c 0a 09 09 09 27 75 70 64 61 74 | ettings',....'themes',....'updat |
89d80 | 65 72 27 2c 0a 09 09 09 2f 2f 20 46 69 6c 65 73 0a 09 09 09 27 2e 72 6e 64 27 2c 0a 09 09 09 27 | er',....//.Files....'.rnd',....' |
89da0 | 69 6e 64 65 78 2e 68 74 6d 6c 27 2c 0a 09 09 09 27 69 6e 64 69 65 2e 6a 73 6f 6e 27 2c 0a 09 09 | index.html',....'indie.json',... |
89dc0 | 09 27 2e 75 73 65 72 2e 69 6e 69 27 2c 0a 09 09 09 27 63 6f 6e 73 6f 6c 65 2e 70 68 70 27 2c 0a | .'.user.ini',....'console.php',. |
89de0 | 09 09 09 27 63 72 6f 6e 2e 70 68 70 27 2c 0a 09 09 09 27 69 6e 64 65 78 2e 70 68 70 27 2c 0a 09 | ...'cron.php',....'index.php',.. |
89e00 | 09 09 27 70 75 62 6c 69 63 2e 70 68 70 27 2c 0a 09 09 09 27 72 65 6d 6f 74 65 2e 70 68 70 27 2c | ..'public.php',....'remote.php', |
89e20 | 0a 09 09 09 27 73 74 61 74 75 73 2e 70 68 70 27 2c 0a 09 09 09 27 76 65 72 73 69 6f 6e 2e 70 68 | ....'status.php',....'version.ph |
89e40 | 70 27 2c 0a 09 09 09 27 72 6f 62 6f 74 73 2e 74 78 74 27 2c 0a 09 09 09 27 2e 68 74 61 63 63 65 | p',....'robots.txt',....'.htacce |
89e60 | 73 73 27 2c 0a 09 09 09 27 41 55 54 48 4f 52 53 27 2c 0a 09 09 09 27 43 48 41 4e 47 45 4c 4f 47 | ss',....'AUTHORS',....'CHANGELOG |
89e80 | 2e 6d 64 27 2c 0a 09 09 09 27 43 4f 50 59 49 4e 47 27 2c 0a 09 09 09 27 43 4f 50 59 49 4e 47 2d | .md',....'COPYING',....'COPYING- |
89ea0 | 41 47 50 4c 27 2c 0a 09 09 09 27 6f 63 63 27 2c 0a 09 09 09 27 64 62 5f 73 74 72 75 63 74 75 72 | AGPL',....'occ',....'db_structur |
89ec0 | 65 2e 78 6d 6c 27 2c 0a 09 09 5d 3b 0a 09 09 72 65 74 75 72 6e 20 61 72 72 61 79 5f 6d 65 72 67 | e.xml',...];...return.array_merg |
89ee0 | 65 28 24 65 78 70 65 63 74 65 64 2c 20 24 74 68 69 73 2d 3e 67 65 74 41 70 70 44 69 72 65 63 74 | e($expected,.$this->getAppDirect |
89f00 | 6f 72 69 65 73 28 29 29 3b 0a 09 7d 0a 0a 09 2f 2a 2a 0a 09 20 2a 20 52 65 74 75 72 6e 73 20 61 | ories());..}.../**...*.Returns.a |
89f20 | 70 70 20 64 69 72 65 63 74 6f 72 69 65 73 20 73 70 65 63 69 66 69 65 64 20 69 6e 20 63 6f 6e 66 | pp.directories.specified.in.conf |
89f40 | 69 67 2e 70 68 70 0a 09 20 2a 0a 09 20 2a 20 40 72 65 74 75 72 6e 20 61 72 72 61 79 0a 09 20 2a | ig.php...*...*.@return.array...* |
89f60 | 2f 0a 09 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 41 70 70 44 69 72 65 63 74 | /..private.function.getAppDirect |
89f80 | 6f 72 69 65 73 28 29 20 7b 0a 09 09 24 65 78 70 65 63 74 65 64 20 3d 20 5b 5d 3b 0a 09 09 69 66 | ories().{...$expected.=.[];...if |
89fa0 | 28 24 61 70 70 73 50 61 74 68 73 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 43 6f 6e 66 69 67 4f 70 | ($appsPaths.=.$this->getConfigOp |
89fc0 | 74 69 6f 6e 28 27 61 70 70 73 5f 70 61 74 68 73 27 29 29 20 7b 0a 09 09 09 66 6f 72 65 61 63 68 | tion('apps_paths')).{....foreach |
89fe0 | 20 28 24 61 70 70 73 50 61 74 68 73 20 61 73 20 24 61 70 70 73 50 61 74 68 29 20 7b 0a 09 09 09 | .($appsPaths.as.$appsPath).{.... |
8a000 | 09 24 70 61 72 65 6e 74 44 69 72 20 3d 20 72 65 61 6c 70 61 74 68 28 24 74 68 69 73 2d 3e 62 61 | .$parentDir.=.realpath($this->ba |
8a020 | 73 65 44 69 72 20 2e 20 27 2f 2e 2e 2f 27 29 3b 0a 09 09 09 09 24 61 70 70 44 69 72 20 3d 20 62 | seDir...'/../');.....$appDir.=.b |
8a040 | 61 73 65 6e 61 6d 65 28 24 61 70 70 73 50 61 74 68 5b 27 70 61 74 68 27 5d 29 3b 0a 09 09 09 09 | asename($appsPath['path']);..... |
8a060 | 69 66 28 73 74 72 70 6f 73 28 24 61 70 70 73 50 61 74 68 5b 27 70 61 74 68 27 5d 2c 20 24 70 61 | if(strpos($appsPath['path'],.$pa |
8a080 | 72 65 6e 74 44 69 72 29 20 3d 3d 3d 20 30 20 26 26 20 24 61 70 70 44 69 72 20 21 3d 3d 20 27 61 | rentDir).===.0.&&.$appDir.!==.'a |
8a0a0 | 70 70 73 27 29 20 7b 0a 09 09 09 09 09 24 65 78 70 65 63 74 65 64 5b 5d 20 3d 20 24 61 70 70 44 | pps').{......$expected[].=.$appD |
8a0c0 | 69 72 3b 0a 09 09 09 09 7d 0a 09 09 09 7d 0a 09 09 7d 0a 09 09 72 65 74 75 72 6e 20 24 65 78 70 | ir;.....}....}...}...return.$exp |
8a0e0 | 65 63 74 65 64 3b 0a 09 7d 0a 0a 09 2f 2a 2a 0a 09 20 2a 20 47 65 74 73 20 74 68 65 20 72 65 63 | ected;..}.../**...*.Gets.the.rec |
8a100 | 75 72 73 69 76 65 20 64 69 72 65 63 74 6f 72 79 20 69 74 65 72 61 74 6f 72 20 6f 76 65 72 20 74 | ursive.directory.iterator.over.t |
8a120 | 68 65 20 4e 65 78 74 63 6c 6f 75 64 20 66 6f 6c 64 65 72 0a 09 20 2a 0a 09 20 2a 20 40 70 61 72 | he.Nextcloud.folder...*...*.@par |
8a140 | 61 6d 20 73 74 72 69 6e 67 20 24 66 6f 6c 64 65 72 0a 09 20 2a 20 40 72 65 74 75 72 6e 20 5c 52 | am.string.$folder...*.@return.\R |
8a160 | 65 63 75 72 73 69 76 65 49 74 65 72 61 74 6f 72 49 74 65 72 61 74 6f 72 0a 09 20 2a 2f 0a 09 70 | ecursiveIteratorIterator...*/..p |
8a180 | 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 52 65 63 75 72 73 69 76 65 44 69 72 65 | rivate.function.getRecursiveDire |
8a1a0 | 63 74 6f 72 79 49 74 65 72 61 74 6f 72 28 24 66 6f 6c 64 65 72 20 3d 20 6e 75 6c 6c 29 20 7b 0a | ctoryIterator($folder.=.null).{. |
8a1c0 | 09 09 69 66 20 28 24 66 6f 6c 64 65 72 20 3d 3d 3d 20 6e 75 6c 6c 29 20 7b 0a 09 09 09 24 66 6f | ..if.($folder.===.null).{....$fo |
8a1e0 | 6c 64 65 72 20 3d 20 24 74 68 69 73 2d 3e 62 61 73 65 44 69 72 20 2e 20 27 2f 2e 2e 2f 27 3b 0a | lder.=.$this->baseDir...'/../';. |
8a200 | 09 09 7d 0a 09 09 72 65 74 75 72 6e 20 6e 65 77 20 5c 52 65 63 75 72 73 69 76 65 49 74 65 72 61 | ..}...return.new.\RecursiveItera |
8a220 | 74 6f 72 49 74 65 72 61 74 6f 72 28 0a 09 09 09 6e 65 77 20 5c 52 65 63 75 72 73 69 76 65 44 69 | torIterator(....new.\RecursiveDi |
8a240 | 72 65 63 74 6f 72 79 49 74 65 72 61 74 6f 72 28 24 66 6f 6c 64 65 72 2c 20 5c 52 65 63 75 72 73 | rectoryIterator($folder,.\Recurs |
8a260 | 69 76 65 44 69 72 65 63 74 6f 72 79 49 74 65 72 61 74 6f 72 3a 3a 53 4b 49 50 5f 44 4f 54 53 29 | iveDirectoryIterator::SKIP_DOTS) |
8a280 | 2c 0a 09 09 09 5c 52 65 63 75 72 73 69 76 65 49 74 65 72 61 74 6f 72 49 74 65 72 61 74 6f 72 3a | ,....\RecursiveIteratorIterator: |
8a2a0 | 3a 43 48 49 4c 44 5f 46 49 52 53 54 0a 09 09 29 3b 0a 09 7d 0a 0a 09 2f 2a 2a 0a 09 20 2a 20 43 | :CHILD_FIRST...);..}.../**...*.C |
8a2c0 | 68 65 63 6b 73 20 66 6f 72 20 66 69 6c 65 73 20 74 68 61 74 20 61 72 65 20 75 6e 65 78 70 65 63 | hecks.for.files.that.are.unexpec |
8a2e0 | 74 65 64 2e 0a 09 20 2a 2f 0a 09 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 63 68 65 63 6b | ted....*/..public.function.check |
8a300 | 46 6f 72 45 78 70 65 63 74 65 64 46 69 6c 65 73 41 6e 64 46 6f 6c 64 65 72 73 28 29 20 7b 0a 09 | ForExpectedFilesAndFolders().{.. |
8a320 | 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 63 68 65 63 6b 46 | .$this->silentLog('[info].checkF |
8a340 | 6f 72 45 78 70 65 63 74 65 64 46 69 6c 65 73 41 6e 64 46 6f 6c 64 65 72 73 28 29 27 29 3b 0a 0a | orExpectedFilesAndFolders()');.. |
8a360 | 09 09 24 65 78 70 65 63 74 65 64 45 6c 65 6d 65 6e 74 73 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 | ..$expectedElements.=.$this->get |
8a380 | 45 78 70 65 63 74 65 64 45 6c 65 6d 65 6e 74 73 4c 69 73 74 28 29 3b 0a 09 09 24 75 6e 65 78 70 | ExpectedElementsList();...$unexp |
8a3a0 | 65 63 74 65 64 45 6c 65 6d 65 6e 74 73 20 3d 20 5b 5d 3b 0a 09 09 66 6f 72 65 61 63 68 20 28 6e | ectedElements.=.[];...foreach.(n |
8a3c0 | 65 77 20 5c 44 69 72 65 63 74 6f 72 79 49 74 65 72 61 74 6f 72 28 24 74 68 69 73 2d 3e 62 61 73 | ew.\DirectoryIterator($this->bas |
8a3e0 | 65 44 69 72 20 2e 20 27 2f 2e 2e 2f 27 29 20 61 73 20 24 66 69 6c 65 49 6e 66 6f 29 20 7b 0a 09 | eDir...'/../').as.$fileInfo).{.. |
8a400 | 09 09 69 66 28 61 72 72 61 79 5f 73 65 61 72 63 68 28 24 66 69 6c 65 49 6e 66 6f 2d 3e 67 65 74 | ..if(array_search($fileInfo->get |
8a420 | 46 69 6c 65 6e 61 6d 65 28 29 2c 20 24 65 78 70 65 63 74 65 64 45 6c 65 6d 65 6e 74 73 29 20 3d | Filename(),.$expectedElements).= |
8a440 | 3d 3d 20 66 61 6c 73 65 29 20 7b 0a 09 09 09 09 24 75 6e 65 78 70 65 63 74 65 64 45 6c 65 6d 65 | ==.false).{.....$unexpectedEleme |
8a460 | 6e 74 73 5b 5d 20 3d 20 24 66 69 6c 65 49 6e 66 6f 2d 3e 67 65 74 46 69 6c 65 6e 61 6d 65 28 29 | nts[].=.$fileInfo->getFilename() |
8a480 | 3b 0a 09 09 09 7d 0a 09 09 7d 0a 0a 09 09 69 66 20 28 63 6f 75 6e 74 28 24 75 6e 65 78 70 65 63 | ;....}...}....if.(count($unexpec |
8a4a0 | 74 65 64 45 6c 65 6d 65 6e 74 73 29 20 21 3d 3d 20 30 29 20 7b 0a 09 09 09 74 68 72 6f 77 20 6e | tedElements).!==.0).{....throw.n |
8a4c0 | 65 77 20 55 70 64 61 74 65 45 78 63 65 70 74 69 6f 6e 28 24 75 6e 65 78 70 65 63 74 65 64 45 6c | ew.UpdateException($unexpectedEl |
8a4e0 | 65 6d 65 6e 74 73 29 3b 0a 09 09 7d 0a 09 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 28 | ements);...}...$this->silentLog( |
8a500 | 27 5b 69 6e 66 6f 5d 20 65 6e 64 20 6f 66 20 63 68 65 63 6b 46 6f 72 45 78 70 65 63 74 65 64 46 | '[info].end.of.checkForExpectedF |
8a520 | 69 6c 65 73 41 6e 64 46 6f 6c 64 65 72 73 28 29 27 29 3b 0a 09 7d 0a 0a 09 2f 2a 2a 0a 09 20 2a | ilesAndFolders()');..}.../**...* |
8a540 | 20 43 68 65 63 6b 73 20 66 6f 72 20 66 69 6c 65 73 20 74 68 61 74 20 61 72 65 20 6e 6f 74 20 77 | .Checks.for.files.that.are.not.w |
8a560 | 72 69 74 61 62 6c 65 0a 09 20 2a 2f 0a 09 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 63 68 | ritable...*/..public.function.ch |
8a580 | 65 63 6b 57 72 69 74 65 50 65 72 6d 69 73 73 69 6f 6e 73 28 29 20 7b 0a 09 09 24 74 68 69 73 2d | eckWritePermissions().{...$this- |
8a5a0 | 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 63 68 65 63 6b 57 72 69 74 65 50 65 72 | >silentLog('[info].checkWritePer |
8a5c0 | 6d 69 73 73 69 6f 6e 73 28 29 27 29 3b 0a 0a 09 09 24 6e 6f 74 57 72 69 74 61 62 6c 65 50 61 74 | missions()');....$notWritablePat |
8a5e0 | 68 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 09 09 24 64 69 72 20 3d 20 6e 65 77 20 5c 52 65 63 75 | hs.=.array();...$dir.=.new.\Recu |
8a600 | 72 73 69 76 65 44 69 72 65 63 74 6f 72 79 49 74 65 72 61 74 6f 72 28 24 74 68 69 73 2d 3e 62 61 | rsiveDirectoryIterator($this->ba |
8a620 | 73 65 44 69 72 20 2e 20 27 2f 2e 2e 2f 27 29 3b 0a 09 09 24 66 69 6c 74 65 72 20 3d 20 6e 65 77 | seDir...'/../');...$filter.=.new |
8a640 | 20 52 65 63 75 72 73 69 76 65 44 69 72 65 63 74 6f 72 79 49 74 65 72 61 74 6f 72 57 69 74 68 6f | .RecursiveDirectoryIteratorWitho |
8a660 | 75 74 44 61 74 61 28 24 64 69 72 29 3b 0a 09 09 24 69 74 20 3d 20 6e 65 77 20 5c 52 65 63 75 72 | utData($dir);...$it.=.new.\Recur |
8a680 | 73 69 76 65 49 74 65 72 61 74 6f 72 49 74 65 72 61 74 6f 72 28 24 66 69 6c 74 65 72 29 3b 0a 0a | siveIteratorIterator($filter);.. |
8a6a0 | 09 09 66 6f 72 65 61 63 68 20 28 24 69 74 20 61 73 20 24 70 61 74 68 20 3d 3e 20 24 64 69 72 29 | ..foreach.($it.as.$path.=>.$dir) |
8a6c0 | 20 7b 0a 09 09 09 69 66 28 21 69 73 5f 77 72 69 74 61 62 6c 65 28 24 70 61 74 68 29 29 20 7b 0a | .{....if(!is_writable($path)).{. |
8a6e0 | 09 09 09 09 24 6e 6f 74 57 72 69 74 61 62 6c 65 50 61 74 68 73 5b 5d 20 3d 20 24 70 61 74 68 3b | ....$notWritablePaths[].=.$path; |
8a700 | 0a 09 09 09 7d 0a 09 09 7d 0a 09 09 69 66 28 63 6f 75 6e 74 28 24 6e 6f 74 57 72 69 74 61 62 6c | ....}...}...if(count($notWritabl |
8a720 | 65 50 61 74 68 73 29 20 3e 20 30 29 20 7b 0a 09 09 09 74 68 72 6f 77 20 6e 65 77 20 55 70 64 61 | ePaths).>.0).{....throw.new.Upda |
8a740 | 74 65 45 78 63 65 70 74 69 6f 6e 28 24 6e 6f 74 57 72 69 74 61 62 6c 65 50 61 74 68 73 29 3b 0a | teException($notWritablePaths);. |
8a760 | 09 09 7d 0a 0a 09 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 | ..}....$this->silentLog('[info]. |
8a780 | 65 6e 64 20 6f 66 20 63 68 65 63 6b 57 72 69 74 65 50 65 72 6d 69 73 73 69 6f 6e 73 28 29 27 29 | end.of.checkWritePermissions()') |
8a7a0 | 3b 0a 09 7d 0a 0a 09 2f 2a 2a 0a 09 20 2a 20 53 65 74 73 20 74 68 65 20 6d 61 69 6e 74 65 6e 61 | ;..}.../**...*.Sets.the.maintena |
8a7c0 | 6e 63 65 20 6d 6f 64 65 20 74 6f 20 74 68 65 20 64 65 66 69 6e 65 64 20 76 61 6c 75 65 0a 09 20 | nce.mode.to.the.defined.value... |
8a7e0 | 2a 0a 09 20 2a 20 40 70 61 72 61 6d 20 62 6f 6f 6c 20 24 73 74 61 74 65 0a 09 20 2a 20 40 74 68 | *...*.@param.bool.$state...*.@th |
8a800 | 72 6f 77 73 20 5c 45 78 63 65 70 74 69 6f 6e 20 77 68 65 6e 20 63 6f 6e 66 69 67 2e 70 68 70 20 | rows.\Exception.when.config.php. |
8a820 | 63 61 6e 27 74 20 62 65 20 77 72 69 74 74 65 6e 0a 09 20 2a 2f 0a 09 70 75 62 6c 69 63 20 66 75 | can't.be.written...*/..public.fu |
8a840 | 6e 63 74 69 6f 6e 20 73 65 74 4d 61 69 6e 74 65 6e 61 6e 63 65 4d 6f 64 65 28 24 73 74 61 74 65 | nction.setMaintenanceMode($state |
8a860 | 29 20 7b 0a 09 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 73 | ).{...$this->silentLog('[info].s |
8a880 | 65 74 4d 61 69 6e 74 65 6e 61 6e 63 65 4d 6f 64 65 28 22 27 20 2e 20 28 24 73 74 61 74 65 20 3f | etMaintenanceMode("'...($state.? |
8a8a0 | 20 27 74 72 75 65 27 20 3a 20 27 66 61 6c 73 65 27 29 20 2e 20 20 27 22 29 27 29 3b 0a 0a 09 09 | .'true'.:.'false')....'")');.... |
8a8c0 | 69 66 28 24 64 69 72 20 3d 20 67 65 74 65 6e 76 28 27 4e 45 58 54 43 4c 4f 55 44 5f 43 4f 4e 46 | if($dir.=.getenv('NEXTCLOUD_CONF |
8a8e0 | 49 47 5f 44 49 52 27 29 29 20 7b 0a 09 09 09 24 63 6f 6e 66 69 67 46 69 6c 65 4e 61 6d 65 20 3d | IG_DIR')).{....$configFileName.= |
8a900 | 20 72 74 72 69 6d 28 24 64 69 72 2c 20 27 2f 27 29 20 2e 20 27 2f 63 6f 6e 66 69 67 2e 70 68 70 | .rtrim($dir,.'/')...'/config.php |
8a920 | 27 3b 0a 09 09 7d 20 65 6c 73 65 20 7b 0a 09 09 09 24 63 6f 6e 66 69 67 46 69 6c 65 4e 61 6d 65 | ';...}.else.{....$configFileName |
8a940 | 20 3d 20 24 74 68 69 73 2d 3e 62 61 73 65 44 69 72 20 2e 20 27 2f 2e 2e 2f 63 6f 6e 66 69 67 2f | .=.$this->baseDir...'/../config/ |
8a960 | 63 6f 6e 66 69 67 2e 70 68 70 27 3b 0a 09 09 7d 0a 09 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e 74 | config.php';...}...$this->silent |
8a980 | 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 63 6f 6e 66 69 67 46 69 6c 65 4e 61 6d 65 20 27 20 2e 20 24 | Log('[info].configFileName.'...$ |
8a9a0 | 63 6f 6e 66 69 67 46 69 6c 65 4e 61 6d 65 29 3b 0a 0a 09 09 2f 2f 20 75 73 75 61 6c 6c 79 20 69 | configFileName);....//.usually.i |
8a9c0 | 73 20 61 6c 72 65 61 64 79 20 74 65 73 74 65 64 20 69 6e 20 74 68 65 20 63 6f 6e 73 74 72 75 63 | s.already.tested.in.the.construc |
8a9e0 | 74 6f 72 20 62 75 74 20 6a 75 73 74 20 74 6f 20 62 65 20 6f 6e 20 74 68 65 20 73 61 66 65 20 73 | tor.but.just.to.be.on.the.safe.s |
8aa00 | 69 64 65 0a 09 09 69 66 20 28 21 66 69 6c 65 5f 65 78 69 73 74 73 28 24 63 6f 6e 66 69 67 46 69 | ide...if.(!file_exists($configFi |
8aa20 | 6c 65 4e 61 6d 65 29 29 20 7b 0a 09 09 09 74 68 72 6f 77 20 6e 65 77 20 5c 45 78 63 65 70 74 69 | leName)).{....throw.new.\Excepti |
8aa40 | 6f 6e 28 27 43 6f 75 6c 64 20 6e 6f 74 20 66 69 6e 64 20 63 6f 6e 66 69 67 2e 70 68 70 2e 27 29 | on('Could.not.find.config.php.') |
8aa60 | 3b 0a 09 09 7d 0a 09 09 2f 2a 2a 20 40 76 61 72 20 61 72 72 61 79 20 24 43 4f 4e 46 49 47 20 2a | ;...}.../**.@var.array.$CONFIG.* |
8aa80 | 2f 0a 09 09 72 65 71 75 69 72 65 20 24 63 6f 6e 66 69 67 46 69 6c 65 4e 61 6d 65 3b 0a 09 09 24 | /...require.$configFileName;...$ |
8aaa0 | 43 4f 4e 46 49 47 5b 27 6d 61 69 6e 74 65 6e 61 6e 63 65 27 5d 20 3d 20 24 73 74 61 74 65 3b 0a | CONFIG['maintenance'].=.$state;. |
8aac0 | 09 09 24 63 6f 6e 74 65 6e 74 20 3d 20 22 3c 3f 70 68 70 5c 6e 22 3b 0a 09 09 24 63 6f 6e 74 65 | ..$content.=."<?php\n";...$conte |
8aae0 | 6e 74 20 2e 3d 20 27 24 43 4f 4e 46 49 47 20 3d 20 27 3b 0a 09 09 24 63 6f 6e 74 65 6e 74 20 2e | nt..=.'$CONFIG.=.';...$content.. |
8ab00 | 3d 20 76 61 72 5f 65 78 70 6f 72 74 28 24 43 4f 4e 46 49 47 2c 20 74 72 75 65 29 3b 0a 09 09 24 | =.var_export($CONFIG,.true);...$ |
8ab20 | 63 6f 6e 74 65 6e 74 20 2e 3d 20 22 3b 5c 6e 22 3b 0a 09 09 24 73 74 61 74 65 20 3d 20 66 69 6c | content..=.";\n";...$state.=.fil |
8ab40 | 65 5f 70 75 74 5f 63 6f 6e 74 65 6e 74 73 28 24 63 6f 6e 66 69 67 46 69 6c 65 4e 61 6d 65 2c 20 | e_put_contents($configFileName,. |
8ab60 | 24 63 6f 6e 74 65 6e 74 29 3b 0a 09 09 69 66 20 28 24 73 74 61 74 65 20 3d 3d 3d 20 66 61 6c 73 | $content);...if.($state.===.fals |
8ab80 | 65 29 20 7b 0a 09 09 09 74 68 72 6f 77 20 6e 65 77 20 5c 45 78 63 65 70 74 69 6f 6e 28 27 43 6f | e).{....throw.new.\Exception('Co |
8aba0 | 75 6c 64 20 6e 6f 74 20 77 72 69 74 65 20 74 6f 20 63 6f 6e 66 69 67 2e 70 68 70 27 29 3b 0a 09 | uld.not.write.to.config.php');.. |
8abc0 | 09 7d 0a 09 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 65 6e | .}...$this->silentLog('[info].en |
8abe0 | 64 20 6f 66 20 73 65 74 4d 61 69 6e 74 65 6e 61 6e 63 65 4d 6f 64 65 28 29 27 29 3b 0a 09 7d 0a | d.of.setMaintenanceMode()');..}. |
8ac00 | 0a 09 2f 2a 2a 0a 09 20 2a 20 43 72 65 61 74 65 73 20 61 20 62 61 63 6b 75 70 20 6f 66 20 61 6c | ../**...*.Creates.a.backup.of.al |
8ac20 | 6c 20 66 69 6c 65 73 20 61 6e 64 20 6d 6f 76 65 73 20 69 74 20 69 6e 74 6f 20 64 61 74 61 2f 75 | l.files.and.moves.it.into.data/u |
8ac40 | 70 64 61 74 65 72 2d 24 69 6e 73 74 61 6e 63 65 69 64 2f 62 61 63 6b 75 70 73 2f 6e 65 78 74 63 | pdater-$instanceid/backups/nextc |
8ac60 | 6c 6f 75 64 2d 58 2d 59 2d 5a 2f 0a 09 20 2a 0a 09 20 2a 20 40 74 68 72 6f 77 73 20 5c 45 78 63 | loud-X-Y-Z/...*...*.@throws.\Exc |
8ac80 | 65 70 74 69 6f 6e 0a 09 20 2a 2f 0a 09 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 63 72 65 | eption...*/..public.function.cre |
8aca0 | 61 74 65 42 61 63 6b 75 70 28 29 20 7b 0a 09 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 | ateBackup().{...$this->silentLog |
8acc0 | 28 27 5b 69 6e 66 6f 5d 20 63 72 65 61 74 65 42 61 63 6b 75 70 28 29 27 29 3b 0a 0a 09 09 24 65 | ('[info].createBackup()');....$e |
8ace0 | 78 63 6c 75 64 65 64 45 6c 65 6d 65 6e 74 73 20 3d 20 5b 0a 09 09 09 27 2e 72 6e 64 27 2c 0a 09 | xcludedElements.=.[....'.rnd',.. |
8ad00 | 09 09 27 2e 77 65 6c 6c 2d 6b 6e 6f 77 6e 27 2c 0a 09 09 09 27 64 61 74 61 27 2c 0a 09 09 5d 3b | ..'.well-known',....'data',...]; |
8ad20 | 0a 0a 09 09 2f 2f 20 43 72 65 61 74 65 20 6e 65 77 20 66 6f 6c 64 65 72 20 66 6f 72 20 74 68 65 | ....//.Create.new.folder.for.the |
8ad40 | 20 62 61 63 6b 75 70 0a 09 09 24 62 61 63 6b 75 70 46 6f 6c 64 65 72 4c 6f 63 61 74 69 6f 6e 20 | .backup...$backupFolderLocation. |
8ad60 | 3d 20 24 74 68 69 73 2d 3e 67 65 74 44 61 74 61 44 69 72 65 63 74 6f 72 79 4c 6f 63 61 74 69 6f | =.$this->getDataDirectoryLocatio |
8ad80 | 6e 28 29 20 2e 20 27 2f 75 70 64 61 74 65 72 2d 27 2e 24 74 68 69 73 2d 3e 67 65 74 43 6f 6e 66 | n()...'/updater-'.$this->getConf |
8ada0 | 69 67 4f 70 74 69 6f 6e 28 27 69 6e 73 74 61 6e 63 65 69 64 27 29 2e 27 2f 62 61 63 6b 75 70 73 | igOption('instanceid').'/backups |
8adc0 | 2f 6e 65 78 74 63 6c 6f 75 64 2d 27 2e 24 74 68 69 73 2d 3e 67 65 74 43 6f 6e 66 69 67 4f 70 74 | /nextcloud-'.$this->getConfigOpt |
8ade0 | 69 6f 6e 28 27 76 65 72 73 69 6f 6e 27 29 20 2e 20 27 2d 27 20 2e 20 74 69 6d 65 28 29 20 2e 20 | ion('version')...'-'...time()... |
8ae00 | 27 2f 27 3b 0a 09 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 | '/';...$this->silentLog('[info]. |
8ae20 | 62 61 63 6b 75 70 20 66 6f 6c 64 65 72 20 6c 6f 63 61 74 69 6f 6e 3a 20 27 20 2e 20 24 62 61 63 | backup.folder.location:.'...$bac |
8ae40 | 6b 75 70 46 6f 6c 64 65 72 4c 6f 63 61 74 69 6f 6e 29 3b 0a 0a 09 09 24 73 74 61 74 65 20 3d 20 | kupFolderLocation);....$state.=. |
8ae60 | 6d 6b 64 69 72 28 24 62 61 63 6b 75 70 46 6f 6c 64 65 72 4c 6f 63 61 74 69 6f 6e 2c 20 30 37 35 | mkdir($backupFolderLocation,.075 |
8ae80 | 30 2c 20 74 72 75 65 29 3b 0a 09 09 69 66 28 24 73 74 61 74 65 20 3d 3d 3d 20 66 61 6c 73 65 29 | 0,.true);...if($state.===.false) |
8aea0 | 20 7b 0a 09 09 09 74 68 72 6f 77 20 6e 65 77 20 5c 45 78 63 65 70 74 69 6f 6e 28 27 43 6f 75 6c | .{....throw.new.\Exception('Coul |
8aec0 | 64 20 6e 6f 74 20 63 72 65 61 74 65 20 62 61 63 6b 75 70 20 66 6f 6c 64 65 72 20 6c 6f 63 61 74 | d.not.create.backup.folder.locat |
8aee0 | 69 6f 6e 27 29 3b 0a 09 09 7d 0a 0a 09 09 2f 2f 20 43 6f 70 79 20 74 68 65 20 62 61 63 6b 75 70 | ion');...}....//.Copy.the.backup |
8af00 | 20 66 69 6c 65 73 0a 09 09 24 63 75 72 72 65 6e 74 44 69 72 20 3d 20 24 74 68 69 73 2d 3e 62 61 | .files...$currentDir.=.$this->ba |
8af20 | 73 65 44 69 72 20 2e 20 27 2f 2e 2e 2f 27 3b 0a 0a 09 09 2f 2a 2a 0a 09 09 20 2a 20 40 76 61 72 | seDir...'/../';..../**....*.@var |
8af40 | 20 73 74 72 69 6e 67 20 24 70 61 74 68 0a 09 09 20 2a 20 40 76 61 72 20 5c 53 70 6c 46 69 6c 65 | .string.$path....*.@var.\SplFile |
8af60 | 49 6e 66 6f 20 24 66 69 6c 65 49 6e 66 6f 0a 09 09 20 2a 2f 0a 09 09 66 6f 72 65 61 63 68 20 28 | Info.$fileInfo....*/...foreach.( |
8af80 | 24 74 68 69 73 2d 3e 67 65 74 52 65 63 75 72 73 69 76 65 44 69 72 65 63 74 6f 72 79 49 74 65 72 | $this->getRecursiveDirectoryIter |
8afa0 | 61 74 6f 72 28 24 63 75 72 72 65 6e 74 44 69 72 29 20 61 73 20 24 70 61 74 68 20 3d 3e 20 24 66 | ator($currentDir).as.$path.=>.$f |
8afc0 | 69 6c 65 49 6e 66 6f 29 20 7b 0a 09 09 09 24 66 69 6c 65 4e 61 6d 65 20 3d 20 65 78 70 6c 6f 64 | ileInfo).{....$fileName.=.explod |
8afe0 | 65 28 24 63 75 72 72 65 6e 74 44 69 72 2c 20 24 70 61 74 68 29 5b 31 5d 3b 0a 09 09 09 24 66 6f | e($currentDir,.$path)[1];....$fo |
8b000 | 6c 64 65 72 53 74 72 75 63 74 75 72 65 20 3d 20 65 78 70 6c 6f 64 65 28 27 2f 27 2c 20 24 66 69 | lderStructure.=.explode('/',.$fi |
8b020 | 6c 65 4e 61 6d 65 2c 20 2d 31 29 3b 0a 0a 09 09 09 2f 2f 20 45 78 63 6c 75 64 65 20 74 68 65 20 | leName,.-1);.....//.Exclude.the. |
8b040 | 65 78 63 6c 75 73 69 6f 6e 73 0a 09 09 09 69 66 28 69 73 73 65 74 28 24 66 6f 6c 64 65 72 53 74 | exclusions....if(isset($folderSt |
8b060 | 72 75 63 74 75 72 65 5b 30 5d 29 29 20 7b 0a 09 09 09 09 69 66 28 61 72 72 61 79 5f 73 65 61 72 | ructure[0])).{.....if(array_sear |
8b080 | 63 68 28 24 66 6f 6c 64 65 72 53 74 72 75 63 74 75 72 65 5b 30 5d 2c 20 24 65 78 63 6c 75 64 65 | ch($folderStructure[0],.$exclude |
8b0a0 | 64 45 6c 65 6d 65 6e 74 73 29 20 21 3d 3d 20 66 61 6c 73 65 29 20 7b 0a 09 09 09 09 09 63 6f 6e | dElements).!==.false).{......con |
8b0c0 | 74 69 6e 75 65 3b 0a 09 09 09 09 7d 0a 09 09 09 7d 20 65 6c 73 65 20 7b 0a 09 09 09 09 69 66 28 | tinue;.....}....}.else.{.....if( |
8b0e0 | 61 72 72 61 79 5f 73 65 61 72 63 68 28 24 66 69 6c 65 4e 61 6d 65 2c 20 24 65 78 63 6c 75 64 65 | array_search($fileName,.$exclude |
8b100 | 64 45 6c 65 6d 65 6e 74 73 29 20 21 3d 3d 20 66 61 6c 73 65 29 20 7b 0a 09 09 09 09 09 63 6f 6e | dElements).!==.false).{......con |
8b120 | 74 69 6e 75 65 3b 0a 09 09 09 09 7d 0a 09 09 09 7d 0a 0a 09 09 09 2f 2f 20 43 72 65 61 74 65 20 | tinue;.....}....}.....//.Create. |
8b140 | 66 6f 6c 64 65 72 20 69 66 20 69 74 20 64 6f 65 73 6e 27 74 20 65 78 69 73 74 0a 09 09 09 69 66 | folder.if.it.doesn't.exist....if |
8b160 | 28 21 66 69 6c 65 5f 65 78 69 73 74 73 28 24 62 61 63 6b 75 70 46 6f 6c 64 65 72 4c 6f 63 61 74 | (!file_exists($backupFolderLocat |
8b180 | 69 6f 6e 20 2e 20 27 2f 27 20 2e 20 64 69 72 6e 61 6d 65 28 24 66 69 6c 65 4e 61 6d 65 29 29 29 | ion...'/'...dirname($fileName))) |
8b1a0 | 20 7b 0a 09 09 09 09 24 73 74 61 74 65 20 3d 20 6d 6b 64 69 72 28 24 62 61 63 6b 75 70 46 6f 6c | .{.....$state.=.mkdir($backupFol |
8b1c0 | 64 65 72 4c 6f 63 61 74 69 6f 6e 20 2e 20 27 2f 27 20 2e 20 64 69 72 6e 61 6d 65 28 24 66 69 6c | derLocation...'/'...dirname($fil |
8b1e0 | 65 4e 61 6d 65 29 2c 20 30 37 35 30 2c 20 74 72 75 65 29 3b 0a 09 09 09 09 69 66 28 24 73 74 61 | eName),.0750,.true);.....if($sta |
8b200 | 74 65 20 3d 3d 3d 20 66 61 6c 73 65 29 20 7b 0a 09 09 09 09 09 74 68 72 6f 77 20 6e 65 77 20 5c | te.===.false).{......throw.new.\ |
8b220 | 45 78 63 65 70 74 69 6f 6e 28 27 43 6f 75 6c 64 20 6e 6f 74 20 63 72 65 61 74 65 20 66 6f 6c 64 | Exception('Could.not.create.fold |
8b240 | 65 72 3a 20 27 2e 24 62 61 63 6b 75 70 46 6f 6c 64 65 72 4c 6f 63 61 74 69 6f 6e 2e 27 2f 27 2e | er:.'.$backupFolderLocation.'/'. |
8b260 | 64 69 72 6e 61 6d 65 28 24 66 69 6c 65 4e 61 6d 65 29 29 3b 0a 09 09 09 09 7d 0a 09 09 09 7d 0a | dirname($fileName));.....}....}. |
8b280 | 0a 09 09 09 2f 2f 20 49 66 20 69 74 20 69 73 20 61 20 66 69 6c 65 20 63 6f 70 79 20 69 74 0a 09 | ....//.If.it.is.a.file.copy.it.. |
8b2a0 | 09 09 69 66 28 24 66 69 6c 65 49 6e 66 6f 2d 3e 69 73 46 69 6c 65 28 29 29 20 7b 0a 09 09 09 09 | ..if($fileInfo->isFile()).{..... |
8b2c0 | 24 73 74 61 74 65 20 3d 20 63 6f 70 79 28 24 66 69 6c 65 49 6e 66 6f 2d 3e 67 65 74 52 65 61 6c | $state.=.copy($fileInfo->getReal |
8b2e0 | 50 61 74 68 28 29 2c 20 24 62 61 63 6b 75 70 46 6f 6c 64 65 72 4c 6f 63 61 74 69 6f 6e 20 2e 20 | Path(),.$backupFolderLocation... |
8b300 | 24 66 69 6c 65 4e 61 6d 65 29 3b 0a 09 09 09 09 69 66 28 24 73 74 61 74 65 20 3d 3d 3d 20 66 61 | $fileName);.....if($state.===.fa |
8b320 | 6c 73 65 29 20 7b 0a 09 09 09 09 09 24 6d 65 73 73 61 67 65 20 3d 20 73 70 72 69 6e 74 66 28 0a | lse).{......$message.=.sprintf(. |
8b340 | 09 09 09 09 09 09 27 43 6f 75 6c 64 20 6e 6f 74 20 63 6f 70 79 20 22 25 73 22 20 74 6f 20 22 25 | ......'Could.not.copy."%s".to."% |
8b360 | 73 22 27 2c 0a 09 09 09 09 09 09 24 66 69 6c 65 49 6e 66 6f 2d 3e 67 65 74 52 65 61 6c 50 61 74 | s"',.......$fileInfo->getRealPat |
8b380 | 68 28 29 2c 0a 09 09 09 09 09 09 24 62 61 63 6b 75 70 46 6f 6c 64 65 72 4c 6f 63 61 74 69 6f 6e | h(),.......$backupFolderLocation |
8b3a0 | 20 2e 20 24 66 69 6c 65 4e 61 6d 65 0a 09 09 09 09 09 29 3b 0a 0a 09 09 09 09 09 69 66 28 69 73 | ...$fileName......);.......if(is |
8b3c0 | 5f 72 65 61 64 61 62 6c 65 28 24 66 69 6c 65 49 6e 66 6f 2d 3e 67 65 74 52 65 61 6c 50 61 74 68 | _readable($fileInfo->getRealPath |
8b3e0 | 28 29 29 20 3d 3d 3d 20 66 61 6c 73 65 29 20 7b 0a 09 09 09 09 09 09 24 6d 65 73 73 61 67 65 20 | ()).===.false).{.......$message. |
8b400 | 3d 20 73 70 72 69 6e 74 66 28 0a 09 09 09 09 09 09 09 27 25 73 2e 20 53 6f 75 72 63 65 20 25 73 | =.sprintf(........'%s..Source.%s |
8b420 | 20 69 73 20 6e 6f 74 20 72 65 61 64 61 62 6c 65 27 2c 0a 09 09 09 09 09 09 09 24 6d 65 73 73 61 | .is.not.readable',........$messa |
8b440 | 67 65 2c 0a 09 09 09 09 09 09 09 24 66 69 6c 65 49 6e 66 6f 2d 3e 67 65 74 52 65 61 6c 50 61 74 | ge,........$fileInfo->getRealPat |
8b460 | 68 28 29 0a 09 09 09 09 09 09 29 3b 0a 09 09 09 09 09 7d 0a 0a 09 09 09 09 09 69 66 28 69 73 5f | h().......);......}.......if(is_ |
8b480 | 77 72 69 74 61 62 6c 65 28 24 62 61 63 6b 75 70 46 6f 6c 64 65 72 4c 6f 63 61 74 69 6f 6e 20 2e | writable($backupFolderLocation.. |
8b4a0 | 20 24 66 69 6c 65 4e 61 6d 65 29 20 3d 3d 3d 20 66 61 6c 73 65 29 20 7b 0a 09 09 09 09 09 09 24 | .$fileName).===.false).{.......$ |
8b4c0 | 6d 65 73 73 61 67 65 20 3d 20 73 70 72 69 6e 74 66 28 0a 09 09 09 09 09 09 09 27 25 73 2e 20 44 | message.=.sprintf(........'%s..D |
8b4e0 | 65 73 74 69 6e 61 74 69 6f 6e 20 25 73 20 69 73 20 6e 6f 74 20 77 72 69 74 61 62 6c 65 27 2c 0a | estination.%s.is.not.writable',. |
8b500 | 09 09 09 09 09 09 09 24 6d 65 73 73 61 67 65 2c 0a 09 09 09 09 09 09 09 24 62 61 63 6b 75 70 46 | .......$message,........$backupF |
8b520 | 6f 6c 64 65 72 4c 6f 63 61 74 69 6f 6e 20 2e 20 24 66 69 6c 65 4e 61 6d 65 0a 09 09 09 09 09 09 | olderLocation...$fileName....... |
8b540 | 29 3b 0a 09 09 09 09 09 7d 0a 0a 09 09 09 09 09 74 68 72 6f 77 20 6e 65 77 20 5c 45 78 63 65 70 | );......}.......throw.new.\Excep |
8b560 | 74 69 6f 6e 28 24 6d 65 73 73 61 67 65 29 3b 0a 09 09 09 09 7d 0a 09 09 09 7d 0a 09 09 7d 0a 09 | tion($message);.....}....}...}.. |
8b580 | 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 65 6e 64 20 6f 66 | .$this->silentLog('[info].end.of |
8b5a0 | 20 63 72 65 61 74 65 42 61 63 6b 75 70 28 29 27 29 3b 0a 09 7d 0a 0a 09 70 72 69 76 61 74 65 20 | .createBackup()');..}...private. |
8b5c0 | 66 75 6e 63 74 69 6f 6e 20 67 65 74 43 68 61 6e 67 65 6c 6f 67 55 52 4c 28 24 76 65 72 73 69 6f | function.getChangelogURL($versio |
8b5e0 | 6e 53 74 72 69 6e 67 29 20 7b 0a 09 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 5b | nString).{...$this->silentLog('[ |
8b600 | 69 6e 66 6f 5d 20 67 65 74 43 68 61 6e 67 65 6c 6f 67 55 52 4c 28 29 27 29 3b 0a 09 09 24 63 68 | info].getChangelogURL()');...$ch |
8b620 | 61 6e 67 65 6c 6f 67 57 65 62 73 69 74 65 20 3d 20 27 68 74 74 70 73 3a 2f 2f 6e 65 78 74 63 6c | angelogWebsite.=.'https://nextcl |
8b640 | 6f 75 64 2e 63 6f 6d 2f 63 68 61 6e 67 65 6c 6f 67 2f 27 3b 0a 09 09 24 63 68 61 6e 67 65 6c 6f | oud.com/changelog/';...$changelo |
8b660 | 67 55 52 4c 20 3d 20 24 63 68 61 6e 67 65 6c 6f 67 57 65 62 73 69 74 65 20 2e 20 27 23 27 20 2e | gURL.=.$changelogWebsite...'#'.. |
8b680 | 20 73 74 72 5f 72 65 70 6c 61 63 65 28 27 2e 27 2c 20 27 2d 27 2c 20 24 76 65 72 73 69 6f 6e 53 | .str_replace('.',.'-',.$versionS |
8b6a0 | 74 72 69 6e 67 29 3b 0a 09 09 72 65 74 75 72 6e 20 24 63 68 61 6e 67 65 6c 6f 67 55 52 4c 3b 0a | tring);...return.$changelogURL;. |
8b6c0 | 09 7d 0a 0a 09 2f 2a 2a 0a 09 20 2a 20 40 72 65 74 75 72 6e 20 61 72 72 61 79 0a 09 20 2a 20 40 | .}.../**...*.@return.array...*.@ |
8b6e0 | 74 68 72 6f 77 73 20 5c 45 78 63 65 70 74 69 6f 6e 0a 09 20 2a 2f 0a 09 70 72 69 76 61 74 65 20 | throws.\Exception...*/..private. |
8b700 | 66 75 6e 63 74 69 6f 6e 20 67 65 74 55 70 64 61 74 65 53 65 72 76 65 72 52 65 73 70 6f 6e 73 65 | function.getUpdateServerResponse |
8b720 | 28 29 20 7b 0a 09 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 | ().{...$this->silentLog('[info]. |
8b740 | 67 65 74 55 70 64 61 74 65 53 65 72 76 65 72 52 65 73 70 6f 6e 73 65 28 29 27 29 3b 0a 0a 09 09 | getUpdateServerResponse()');.... |
8b760 | 24 75 70 64 61 74 65 72 53 65 72 76 65 72 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 43 6f 6e 66 69 | $updaterServer.=.$this->getConfi |
8b780 | 67 4f 70 74 69 6f 6e 28 27 75 70 64 61 74 65 72 2e 73 65 72 76 65 72 2e 75 72 6c 27 29 3b 0a 09 | gOption('updater.server.url');.. |
8b7a0 | 09 69 66 28 24 75 70 64 61 74 65 72 53 65 72 76 65 72 20 3d 3d 3d 20 6e 75 6c 6c 29 20 7b 0a 09 | .if($updaterServer.===.null).{.. |
8b7c0 | 09 09 2f 2f 20 46 49 58 4d 45 3a 20 75 73 65 64 20 64 65 70 6c 6f 79 65 64 20 55 52 4c 0a 09 09 | ..//.FIXME:.used.deployed.URL... |
8b7e0 | 09 24 75 70 64 61 74 65 72 53 65 72 76 65 72 20 3d 20 27 68 74 74 70 73 3a 2f 2f 75 70 64 61 74 | .$updaterServer.=.'https://updat |
8b800 | 65 73 2e 6e 65 78 74 63 6c 6f 75 64 2e 63 6f 6d 2f 75 70 64 61 74 65 72 5f 73 65 72 76 65 72 2f | es.nextcloud.com/updater_server/ |
8b820 | 27 3b 0a 09 09 7d 0a 09 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 5b 69 6e 66 6f | ';...}...$this->silentLog('[info |
8b840 | 5d 20 75 70 64 61 74 65 72 53 65 72 76 65 72 3a 20 27 20 2e 20 24 75 70 64 61 74 65 72 53 65 72 | ].updaterServer:.'...$updaterSer |
8b860 | 76 65 72 29 3b 0a 0a 09 09 24 72 65 6c 65 61 73 65 43 68 61 6e 6e 65 6c 20 3d 20 24 74 68 69 73 | ver);....$releaseChannel.=.$this |
8b880 | 2d 3e 67 65 74 43 75 72 72 65 6e 74 52 65 6c 65 61 73 65 43 68 61 6e 6e 65 6c 28 29 3b 0a 09 09 | ->getCurrentReleaseChannel();... |
8b8a0 | 24 74 68 69 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 72 65 6c 65 61 73 65 | $this->silentLog('[info].release |
8b8c0 | 43 68 61 6e 6e 65 6c 3a 20 27 20 2e 20 24 72 65 6c 65 61 73 65 43 68 61 6e 6e 65 6c 29 3b 0a 09 | Channel:.'...$releaseChannel);.. |
8b8e0 | 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 69 6e 74 65 72 6e | .$this->silentLog('[info].intern |
8b900 | 61 6c 20 76 65 72 73 69 6f 6e 3a 20 27 20 2e 20 24 74 68 69 73 2d 3e 67 65 74 43 6f 6e 66 69 67 | al.version:.'...$this->getConfig |
8b920 | 4f 70 74 69 6f 6e 28 27 76 65 72 73 69 6f 6e 27 29 29 3b 0a 0a 09 09 24 75 70 64 61 74 65 55 52 | Option('version'));....$updateUR |
8b940 | 4c 20 3d 20 24 75 70 64 61 74 65 72 53 65 72 76 65 72 20 2e 20 27 3f 76 65 72 73 69 6f 6e 3d 27 | L.=.$updaterServer...'?version=' |
8b960 | 2e 20 73 74 72 5f 72 65 70 6c 61 63 65 28 27 2e 27 2c 20 27 78 27 2c 20 24 74 68 69 73 2d 3e 67 | ..str_replace('.',.'x',.$this->g |
8b980 | 65 74 43 6f 6e 66 69 67 4f 70 74 69 6f 6e 28 27 76 65 72 73 69 6f 6e 27 29 29 20 2e 27 78 78 78 | etConfigOption('version'))..'xxx |
8b9a0 | 27 2e 24 72 65 6c 65 61 73 65 43 68 61 6e 6e 65 6c 2e 27 78 78 27 2e 75 72 6c 65 6e 63 6f 64 65 | '.$releaseChannel.'xx'.urlencode |
8b9c0 | 28 24 74 68 69 73 2d 3e 62 75 69 6c 64 54 69 6d 65 29 2e 27 78 27 2e 50 48 50 5f 4d 41 4a 4f 52 | ($this->buildTime).'x'.PHP_MAJOR |
8b9e0 | 5f 56 45 52 53 49 4f 4e 2e 27 78 27 2e 50 48 50 5f 4d 49 4e 4f 52 5f 56 45 52 53 49 4f 4e 2e 27 | _VERSION.'x'.PHP_MINOR_VERSION.' |
8ba00 | 78 27 2e 50 48 50 5f 52 45 4c 45 41 53 45 5f 56 45 52 53 49 4f 4e 3b 0a 09 09 24 74 68 69 73 2d | x'.PHP_RELEASE_VERSION;...$this- |
8ba20 | 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 75 70 64 61 74 65 55 52 4c 3a 20 27 20 | >silentLog('[info].updateURL:.'. |
8ba40 | 2e 20 24 75 70 64 61 74 65 55 52 4c 29 3b 0a 0a 09 09 2f 2f 20 44 6f 77 6e 6c 6f 61 64 20 75 70 | ..$updateURL);....//.Download.up |
8ba60 | 64 61 74 65 20 72 65 73 70 6f 6e 73 65 0a 09 09 24 63 75 72 6c 20 3d 20 63 75 72 6c 5f 69 6e 69 | date.response...$curl.=.curl_ini |
8ba80 | 74 28 29 3b 0a 09 09 63 75 72 6c 5f 73 65 74 6f 70 74 5f 61 72 72 61 79 28 24 63 75 72 6c 2c 20 | t();...curl_setopt_array($curl,. |
8baa0 | 5b 0a 09 09 09 43 55 52 4c 4f 50 54 5f 52 45 54 55 52 4e 54 52 41 4e 53 46 45 52 20 3d 3e 20 31 | [....CURLOPT_RETURNTRANSFER.=>.1 |
8bac0 | 2c 0a 09 09 09 43 55 52 4c 4f 50 54 5f 55 52 4c 20 3d 3e 20 24 75 70 64 61 74 65 55 52 4c 2c 0a | ,....CURLOPT_URL.=>.$updateURL,. |
8bae0 | 09 09 09 43 55 52 4c 4f 50 54 5f 55 53 45 52 41 47 45 4e 54 20 3d 3e 20 27 4e 65 78 74 63 6c 6f | ...CURLOPT_USERAGENT.=>.'Nextclo |
8bb00 | 75 64 20 55 70 64 61 74 65 72 27 2c 0a 09 09 5d 29 3b 0a 0a 09 09 69 66 20 28 24 74 68 69 73 2d | ud.Updater',...]);....if.($this- |
8bb20 | 3e 67 65 74 43 6f 6e 66 69 67 4f 70 74 69 6f 6e 28 27 70 72 6f 78 79 27 29 20 21 3d 3d 20 6e 75 | >getConfigOption('proxy').!==.nu |
8bb40 | 6c 6c 29 20 7b 0a 09 09 09 63 75 72 6c 5f 73 65 74 6f 70 74 5f 61 72 72 61 79 28 24 63 75 72 6c | ll).{....curl_setopt_array($curl |
8bb60 | 2c 20 5b 0a 09 09 09 09 43 55 52 4c 4f 50 54 5f 50 52 4f 58 59 20 3d 3e 20 24 74 68 69 73 2d 3e | ,.[.....CURLOPT_PROXY.=>.$this-> |
8bb80 | 67 65 74 43 6f 6e 66 69 67 4f 70 74 69 6f 6e 28 27 70 72 6f 78 79 27 29 2c 0a 09 09 09 09 43 55 | getConfigOption('proxy'),.....CU |
8bba0 | 52 4c 4f 50 54 5f 50 52 4f 58 59 55 53 45 52 50 57 44 20 3d 3e 20 24 74 68 69 73 2d 3e 67 65 74 | RLOPT_PROXYUSERPWD.=>.$this->get |
8bbc0 | 43 6f 6e 66 69 67 4f 70 74 69 6f 6e 28 27 70 72 6f 78 79 75 73 65 72 70 77 64 27 29 2c 0a 09 09 | ConfigOption('proxyuserpwd'),... |
8bbe0 | 09 09 43 55 52 4c 4f 50 54 5f 48 54 54 50 50 52 4f 58 59 54 55 4e 4e 45 4c 20 3d 3e 20 24 74 68 | ..CURLOPT_HTTPPROXYTUNNEL.=>.$th |
8bc00 | 69 73 2d 3e 67 65 74 43 6f 6e 66 69 67 4f 70 74 69 6f 6e 28 27 70 72 6f 78 79 27 29 20 3f 20 31 | is->getConfigOption('proxy').?.1 |
8bc20 | 20 3a 20 30 2c 0a 09 09 09 5d 29 3b 0a 09 09 7d 0a 0a 09 09 24 72 65 73 70 6f 6e 73 65 20 3d 20 | .:.0,....]);...}....$response.=. |
8bc40 | 63 75 72 6c 5f 65 78 65 63 28 24 63 75 72 6c 29 3b 0a 09 09 69 66 28 24 72 65 73 70 6f 6e 73 65 | curl_exec($curl);...if($response |
8bc60 | 20 3d 3d 3d 20 66 61 6c 73 65 29 20 7b 0a 09 09 09 74 68 72 6f 77 20 6e 65 77 20 5c 45 78 63 65 | .===.false).{....throw.new.\Exce |
8bc80 | 70 74 69 6f 6e 28 27 43 6f 75 6c 64 20 6e 6f 74 20 64 6f 20 72 65 71 75 65 73 74 20 74 6f 20 75 | ption('Could.not.do.request.to.u |
8bca0 | 70 64 61 74 65 72 20 73 65 72 76 65 72 3a 20 27 2e 63 75 72 6c 5f 65 72 72 6f 72 28 24 63 75 72 | pdater.server:.'.curl_error($cur |
8bcc0 | 6c 29 29 3b 0a 09 09 7d 0a 09 09 63 75 72 6c 5f 63 6c 6f 73 65 28 24 63 75 72 6c 29 3b 0a 0a 09 | l));...}...curl_close($curl);... |
8bce0 | 09 2f 2f 20 52 65 73 70 6f 6e 73 65 20 63 61 6e 20 62 65 20 65 6d 70 74 79 20 77 68 65 6e 20 6e | .//.Response.can.be.empty.when.n |
8bd00 | 6f 20 75 70 64 61 74 65 20 69 73 20 61 76 61 69 6c 61 62 6c 65 0a 09 09 69 66 28 24 72 65 73 70 | o.update.is.available...if($resp |
8bd20 | 6f 6e 73 65 20 3d 3d 3d 20 27 27 29 20 7b 0a 09 09 09 72 65 74 75 72 6e 20 5b 5d 3b 0a 09 09 7d | onse.===.'').{....return.[];...} |
8bd40 | 0a 0a 09 09 24 78 6d 6c 20 3d 20 73 69 6d 70 6c 65 78 6d 6c 5f 6c 6f 61 64 5f 73 74 72 69 6e 67 | ....$xml.=.simplexml_load_string |
8bd60 | 28 24 72 65 73 70 6f 6e 73 65 29 3b 0a 09 09 69 66 28 24 78 6d 6c 20 3d 3d 3d 20 66 61 6c 73 65 | ($response);...if($xml.===.false |
8bd80 | 29 20 7b 0a 09 09 09 74 68 72 6f 77 20 6e 65 77 20 5c 45 78 63 65 70 74 69 6f 6e 28 27 43 6f 75 | ).{....throw.new.\Exception('Cou |
8bda0 | 6c 64 20 6e 6f 74 20 70 61 72 73 65 20 75 70 64 61 74 65 72 20 73 65 72 76 65 72 20 58 4d 4c 20 | ld.not.parse.updater.server.XML. |
8bdc0 | 72 65 73 70 6f 6e 73 65 27 29 3b 0a 09 09 7d 0a 09 09 24 6a 73 6f 6e 20 3d 20 6a 73 6f 6e 5f 65 | response');...}...$json.=.json_e |
8bde0 | 6e 63 6f 64 65 28 24 78 6d 6c 29 3b 0a 09 09 69 66 28 24 6a 73 6f 6e 20 3d 3d 3d 20 66 61 6c 73 | ncode($xml);...if($json.===.fals |
8be00 | 65 29 20 7b 0a 09 09 09 74 68 72 6f 77 20 6e 65 77 20 5c 45 78 63 65 70 74 69 6f 6e 28 27 43 6f | e).{....throw.new.\Exception('Co |
8be20 | 75 6c 64 20 6e 6f 74 20 4a 53 4f 4e 20 65 6e 63 6f 64 65 20 75 70 64 61 74 65 72 20 73 65 72 76 | uld.not.JSON.encode.updater.serv |
8be40 | 65 72 20 72 65 73 70 6f 6e 73 65 27 29 3b 0a 09 09 7d 0a 09 09 24 72 65 73 70 6f 6e 73 65 20 3d | er.response');...}...$response.= |
8be60 | 20 6a 73 6f 6e 5f 64 65 63 6f 64 65 28 24 6a 73 6f 6e 2c 20 74 72 75 65 29 3b 0a 09 09 69 66 28 | .json_decode($json,.true);...if( |
8be80 | 24 72 65 73 70 6f 6e 73 65 20 3d 3d 3d 20 6e 75 6c 6c 29 20 7b 0a 09 09 09 74 68 72 6f 77 20 6e | $response.===.null).{....throw.n |
8bea0 | 65 77 20 5c 45 78 63 65 70 74 69 6f 6e 28 27 43 6f 75 6c 64 20 6e 6f 74 20 4a 53 4f 4e 20 64 65 | ew.\Exception('Could.not.JSON.de |
8bec0 | 63 6f 64 65 20 75 70 64 61 74 65 72 20 73 65 72 76 65 72 20 72 65 73 70 6f 6e 73 65 2e 27 29 3b | code.updater.server.response.'); |
8bee0 | 0a 09 09 7d 0a 09 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 | ...}...$this->silentLog('[info]. |
8bf00 | 67 65 74 55 70 64 61 74 65 53 65 72 76 65 72 52 65 73 70 6f 6e 73 65 20 72 65 73 70 6f 6e 73 65 | getUpdateServerResponse.response |
8bf20 | 3a 20 27 20 2e 20 70 72 69 6e 74 5f 72 28 24 72 65 73 70 6f 6e 73 65 2c 20 74 72 75 65 29 29 3b | :.'...print_r($response,.true)); |
8bf40 | 0a 09 09 72 65 74 75 72 6e 20 24 72 65 73 70 6f 6e 73 65 3b 0a 09 7d 0a 0a 09 2f 2a 2a 0a 09 20 | ...return.$response;..}.../**... |
8bf60 | 2a 20 44 6f 77 6e 6c 6f 61 64 73 20 74 68 65 20 6e 65 78 74 63 6c 6f 75 64 20 66 6f 6c 64 65 72 | *.Downloads.the.nextcloud.folder |
8bf80 | 20 74 6f 20 24 44 41 54 41 44 49 52 2f 75 70 64 61 74 65 72 2d 24 69 6e 73 74 61 6e 63 65 69 64 | .to.$DATADIR/updater-$instanceid |
8bfa0 | 2f 64 6f 77 6e 6c 6f 61 64 73 2f 24 66 69 6c 65 6e 61 6d 65 0a 09 20 2a 0a 09 20 2a 20 40 74 68 | /downloads/$filename...*...*.@th |
8bfc0 | 72 6f 77 73 20 5c 45 78 63 65 70 74 69 6f 6e 0a 09 20 2a 2f 0a 09 70 75 62 6c 69 63 20 66 75 6e | rows.\Exception...*/..public.fun |
8bfe0 | 63 74 69 6f 6e 20 64 6f 77 6e 6c 6f 61 64 55 70 64 61 74 65 28 29 20 7b 0a 09 09 24 74 68 69 73 | ction.downloadUpdate().{...$this |
8c000 | 2d 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 64 6f 77 6e 6c 6f 61 64 55 70 64 61 | ->silentLog('[info].downloadUpda |
8c020 | 74 65 28 29 27 29 3b 0a 0a 09 09 24 72 65 73 70 6f 6e 73 65 20 3d 20 24 74 68 69 73 2d 3e 67 65 | te()');....$response.=.$this->ge |
8c040 | 74 55 70 64 61 74 65 53 65 72 76 65 72 52 65 73 70 6f 6e 73 65 28 29 3b 0a 09 09 24 73 74 6f 72 | tUpdateServerResponse();...$stor |
8c060 | 61 67 65 4c 6f 63 61 74 69 6f 6e 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 44 61 74 61 44 69 72 65 | ageLocation.=.$this->getDataDire |
8c080 | 63 74 6f 72 79 4c 6f 63 61 74 69 6f 6e 28 29 20 2e 20 27 2f 75 70 64 61 74 65 72 2d 27 2e 24 74 | ctoryLocation()...'/updater-'.$t |
8c0a0 | 68 69 73 2d 3e 67 65 74 43 6f 6e 66 69 67 4f 70 74 69 6f 6e 28 27 69 6e 73 74 61 6e 63 65 69 64 | his->getConfigOption('instanceid |
8c0c0 | 27 29 20 2e 20 27 2f 64 6f 77 6e 6c 6f 61 64 73 2f 27 3b 0a 09 09 69 66 28 66 69 6c 65 5f 65 78 | ')...'/downloads/';...if(file_ex |
8c0e0 | 69 73 74 73 28 24 73 74 6f 72 61 67 65 4c 6f 63 61 74 69 6f 6e 29 29 20 7b 0a 09 09 09 24 74 68 | ists($storageLocation)).{....$th |
8c100 | 69 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 73 74 6f 72 61 67 65 20 6c 6f | is->silentLog('[info].storage.lo |
8c120 | 63 61 74 69 6f 6e 20 65 78 69 73 74 73 27 29 3b 0a 09 09 09 24 74 68 69 73 2d 3e 72 65 63 75 72 | cation.exists');....$this->recur |
8c140 | 73 69 76 65 44 65 6c 65 74 65 28 24 73 74 6f 72 61 67 65 4c 6f 63 61 74 69 6f 6e 29 3b 0a 09 09 | siveDelete($storageLocation);... |
8c160 | 7d 0a 09 09 24 73 74 61 74 65 20 3d 20 6d 6b 64 69 72 28 24 73 74 6f 72 61 67 65 4c 6f 63 61 74 | }...$state.=.mkdir($storageLocat |
8c180 | 69 6f 6e 2c 20 30 37 35 30 2c 20 74 72 75 65 29 3b 0a 09 09 69 66 28 24 73 74 61 74 65 20 3d 3d | ion,.0750,.true);...if($state.== |
8c1a0 | 3d 20 66 61 6c 73 65 29 20 7b 0a 09 09 09 74 68 72 6f 77 20 6e 65 77 20 5c 45 78 63 65 70 74 69 | =.false).{....throw.new.\Excepti |
8c1c0 | 6f 6e 28 27 43 6f 75 6c 64 20 6e 6f 74 20 6d 6b 64 69 72 20 73 74 6f 72 61 67 65 20 6c 6f 63 61 | on('Could.not.mkdir.storage.loca |
8c1e0 | 74 69 6f 6e 27 29 3b 0a 09 09 7d 0a 0a 09 09 24 66 70 20 3d 20 66 6f 70 65 6e 28 24 73 74 6f 72 | tion');...}....$fp.=.fopen($stor |
8c200 | 61 67 65 4c 6f 63 61 74 69 6f 6e 20 2e 20 62 61 73 65 6e 61 6d 65 28 24 72 65 73 70 6f 6e 73 65 | ageLocation...basename($response |
8c220 | 5b 27 75 72 6c 27 5d 29 2c 20 27 77 2b 27 29 3b 0a 09 09 24 63 68 20 3d 20 63 75 72 6c 5f 69 6e | ['url']),.'w+');...$ch.=.curl_in |
8c240 | 69 74 28 24 72 65 73 70 6f 6e 73 65 5b 27 75 72 6c 27 5d 29 3b 0a 09 09 63 75 72 6c 5f 73 65 74 | it($response['url']);...curl_set |
8c260 | 6f 70 74 5f 61 72 72 61 79 28 24 63 68 2c 20 5b 0a 09 09 09 43 55 52 4c 4f 50 54 5f 46 49 4c 45 | opt_array($ch,.[....CURLOPT_FILE |
8c280 | 20 3d 3e 20 24 66 70 2c 0a 09 09 09 43 55 52 4c 4f 50 54 5f 55 53 45 52 41 47 45 4e 54 20 3d 3e | .=>.$fp,....CURLOPT_USERAGENT.=> |
8c2a0 | 20 27 4e 65 78 74 63 6c 6f 75 64 20 55 70 64 61 74 65 72 27 2c 0a 09 09 5d 29 3b 0a 0a 09 09 69 | .'Nextcloud.Updater',...]);....i |
8c2c0 | 66 20 28 24 74 68 69 73 2d 3e 67 65 74 43 6f 6e 66 69 67 4f 70 74 69 6f 6e 28 27 70 72 6f 78 79 | f.($this->getConfigOption('proxy |
8c2e0 | 27 29 20 21 3d 3d 20 6e 75 6c 6c 29 20 7b 0a 09 09 09 63 75 72 6c 5f 73 65 74 6f 70 74 5f 61 72 | ').!==.null).{....curl_setopt_ar |
8c300 | 72 61 79 28 24 63 68 2c 20 5b 0a 09 09 09 09 43 55 52 4c 4f 50 54 5f 50 52 4f 58 59 20 3d 3e 20 | ray($ch,.[.....CURLOPT_PROXY.=>. |
8c320 | 24 74 68 69 73 2d 3e 67 65 74 43 6f 6e 66 69 67 4f 70 74 69 6f 6e 28 27 70 72 6f 78 79 27 29 2c | $this->getConfigOption('proxy'), |
8c340 | 0a 09 09 09 09 43 55 52 4c 4f 50 54 5f 50 52 4f 58 59 55 53 45 52 50 57 44 20 3d 3e 20 24 74 68 | .....CURLOPT_PROXYUSERPWD.=>.$th |
8c360 | 69 73 2d 3e 67 65 74 43 6f 6e 66 69 67 4f 70 74 69 6f 6e 28 27 70 72 6f 78 79 75 73 65 72 70 77 | is->getConfigOption('proxyuserpw |
8c380 | 64 27 29 2c 0a 09 09 09 09 43 55 52 4c 4f 50 54 5f 48 54 54 50 50 52 4f 58 59 54 55 4e 4e 45 4c | d'),.....CURLOPT_HTTPPROXYTUNNEL |
8c3a0 | 20 3d 3e 20 24 74 68 69 73 2d 3e 67 65 74 43 6f 6e 66 69 67 4f 70 74 69 6f 6e 28 27 70 72 6f 78 | .=>.$this->getConfigOption('prox |
8c3c0 | 79 27 29 20 3f 20 31 20 3a 20 30 2c 0a 09 09 09 5d 29 3b 0a 09 09 7d 0a 0a 09 09 69 66 28 63 75 | y').?.1.:.0,....]);...}....if(cu |
8c3e0 | 72 6c 5f 65 78 65 63 28 24 63 68 29 20 3d 3d 3d 20 66 61 6c 73 65 29 20 7b 0a 09 09 09 74 68 72 | rl_exec($ch).===.false).{....thr |
8c400 | 6f 77 20 6e 65 77 20 5c 45 78 63 65 70 74 69 6f 6e 28 27 43 75 72 6c 20 65 72 72 6f 72 3a 20 27 | ow.new.\Exception('Curl.error:.' |
8c420 | 20 2e 20 63 75 72 6c 5f 65 72 72 6f 72 28 24 63 68 29 29 3b 0a 09 09 7d 0a 09 09 24 68 74 74 70 | ...curl_error($ch));...}...$http |
8c440 | 43 6f 64 65 20 3d 20 63 75 72 6c 5f 67 65 74 69 6e 66 6f 28 24 63 68 2c 20 43 55 52 4c 49 4e 46 | Code.=.curl_getinfo($ch,.CURLINF |
8c460 | 4f 5f 48 54 54 50 5f 43 4f 44 45 29 3b 0a 09 09 69 66 28 24 68 74 74 70 43 6f 64 65 20 21 3d 3d | O_HTTP_CODE);...if($httpCode.!== |
8c480 | 20 32 30 30 29 20 7b 0a 09 09 09 24 73 74 61 74 75 73 43 6f 64 65 73 20 3d 20 5b 0a 09 09 09 09 | .200).{....$statusCodes.=.[..... |
8c4a0 | 34 30 30 20 3d 3e 20 27 42 61 64 20 72 65 71 75 65 73 74 27 2c 0a 09 09 09 09 34 30 31 20 3d 3e | 400.=>.'Bad.request',.....401.=> |
8c4c0 | 20 27 55 6e 61 75 74 68 6f 72 69 7a 65 64 27 2c 0a 09 09 09 09 34 30 33 20 3d 3e 20 27 46 6f 72 | .'Unauthorized',.....403.=>.'For |
8c4e0 | 62 69 64 64 65 6e 27 2c 0a 09 09 09 09 34 30 34 20 3d 3e 20 27 4e 6f 74 20 46 6f 75 6e 64 27 2c | bidden',.....404.=>.'Not.Found', |
8c500 | 0a 09 09 09 09 35 30 30 20 3d 3e 20 27 49 6e 74 65 72 6e 61 6c 20 53 65 72 76 65 72 20 45 72 72 | .....500.=>.'Internal.Server.Err |
8c520 | 6f 72 27 2c 0a 09 09 09 09 35 30 32 20 3d 3e 20 27 42 61 64 20 47 61 74 65 77 61 79 27 2c 0a 09 | or',.....502.=>.'Bad.Gateway',.. |
8c540 | 09 09 09 35 30 33 20 3d 3e 20 27 53 65 72 76 69 63 65 20 55 6e 61 76 61 69 6c 61 62 6c 65 27 2c | ...503.=>.'Service.Unavailable', |
8c560 | 0a 09 09 09 09 35 30 34 20 3d 3e 20 27 47 61 74 65 77 61 79 20 54 69 6d 65 6f 75 74 27 2c 0a 09 | .....504.=>.'Gateway.Timeout',.. |
8c580 | 09 09 5d 3b 0a 0a 09 09 09 24 6d 65 73 73 61 67 65 20 3d 20 27 44 6f 77 6e 6c 6f 61 64 20 66 61 | ..];.....$message.=.'Download.fa |
8c5a0 | 69 6c 65 64 27 3b 0a 09 09 09 69 66 28 69 73 73 65 74 28 24 73 74 61 74 75 73 43 6f 64 65 73 5b | iled';....if(isset($statusCodes[ |
8c5c0 | 24 68 74 74 70 43 6f 64 65 5d 29 29 20 7b 0a 09 09 09 09 24 6d 65 73 73 61 67 65 20 2e 3d 20 27 | $httpCode])).{.....$message..=.' |
8c5e0 | 20 2d 20 27 20 2e 20 24 73 74 61 74 75 73 43 6f 64 65 73 5b 24 68 74 74 70 43 6f 64 65 5d 20 2e | .-.'...$statusCodes[$httpCode].. |
8c600 | 20 27 20 28 48 54 54 50 20 27 20 2e 20 24 68 74 74 70 43 6f 64 65 20 2e 20 27 29 27 3b 0a 09 09 | .'.(HTTP.'...$httpCode...')';... |
8c620 | 09 7d 20 65 6c 73 65 20 7b 0a 09 09 09 09 24 6d 65 73 73 61 67 65 20 2e 3d 20 27 20 2d 20 48 54 | .}.else.{.....$message..=.'.-.HT |
8c640 | 54 50 20 73 74 61 74 75 73 20 63 6f 64 65 3a 20 27 20 2e 20 24 68 74 74 70 43 6f 64 65 3b 0a 09 | TP.status.code:.'...$httpCode;.. |
8c660 | 09 09 7d 0a 0a 09 09 09 24 63 75 72 6c 45 72 72 6f 72 4d 65 73 73 61 67 65 20 3d 20 63 75 72 6c | ..}.....$curlErrorMessage.=.curl |
8c680 | 5f 65 72 72 6f 72 28 24 63 68 29 3b 0a 09 09 09 69 66 28 21 65 6d 70 74 79 28 24 63 75 72 6c 45 | _error($ch);....if(!empty($curlE |
8c6a0 | 72 72 6f 72 4d 65 73 73 61 67 65 29 29 20 7b 0a 09 09 09 09 24 6d 65 73 73 61 67 65 20 2e 3d 20 | rrorMessage)).{.....$message..=. |
8c6c0 | 27 20 2d 20 63 75 72 6c 20 65 72 72 6f 72 20 6d 65 73 73 61 67 65 3a 20 27 20 2e 20 24 63 75 72 | '.-.curl.error.message:.'...$cur |
8c6e0 | 6c 45 72 72 6f 72 4d 65 73 73 61 67 65 3b 0a 09 09 09 7d 0a 0a 09 09 09 24 6d 65 73 73 61 67 65 | lErrorMessage;....}.....$message |
8c700 | 20 2e 3d 20 27 20 2d 20 55 52 4c 3a 20 27 20 2e 20 68 74 6d 6c 65 6e 74 69 74 69 65 73 28 24 72 | ..=.'.-.URL:.'...htmlentities($r |
8c720 | 65 73 70 6f 6e 73 65 5b 27 75 72 6c 27 5d 29 3b 0a 0a 09 09 09 74 68 72 6f 77 20 6e 65 77 20 5c | esponse['url']);.....throw.new.\ |
8c740 | 45 78 63 65 70 74 69 6f 6e 28 24 6d 65 73 73 61 67 65 29 3b 0a 09 09 7d 0a 09 09 63 75 72 6c 5f | Exception($message);...}...curl_ |
8c760 | 63 6c 6f 73 65 28 24 63 68 29 3b 0a 09 09 66 63 6c 6f 73 65 28 24 66 70 29 3b 0a 0a 09 09 24 74 | close($ch);...fclose($fp);....$t |
8c780 | 68 69 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 65 6e 64 20 6f 66 20 64 6f | his->silentLog('[info].end.of.do |
8c7a0 | 77 6e 6c 6f 61 64 55 70 64 61 74 65 28 29 27 29 3b 0a 09 7d 0a 0a 09 2f 2a 2a 0a 09 20 2a 20 40 | wnloadUpdate()');..}.../**...*.@ |
8c7c0 | 72 65 74 75 72 6e 20 73 74 72 69 6e 67 0a 09 20 2a 20 40 74 68 72 6f 77 73 20 5c 45 78 63 65 70 | return.string...*.@throws.\Excep |
8c7e0 | 74 69 6f 6e 0a 09 20 2a 2f 0a 09 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 44 | tion...*/..private.function.getD |
8c800 | 6f 77 6e 6c 6f 61 64 65 64 46 69 6c 65 50 61 74 68 28 29 20 7b 0a 09 09 24 73 74 6f 72 61 67 65 | ownloadedFilePath().{...$storage |
8c820 | 4c 6f 63 61 74 69 6f 6e 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 44 61 74 61 44 69 72 65 63 74 6f | Location.=.$this->getDataDirecto |
8c840 | 72 79 4c 6f 63 61 74 69 6f 6e 28 29 20 2e 20 27 2f 75 70 64 61 74 65 72 2d 27 2e 24 74 68 69 73 | ryLocation()...'/updater-'.$this |
8c860 | 2d 3e 67 65 74 43 6f 6e 66 69 67 4f 70 74 69 6f 6e 28 27 69 6e 73 74 61 6e 63 65 69 64 27 29 20 | ->getConfigOption('instanceid'). |
8c880 | 2e 20 27 2f 64 6f 77 6e 6c 6f 61 64 73 2f 27 3b 0a 09 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e 74 | ..'/downloads/';...$this->silent |
8c8a0 | 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 73 74 6f 72 61 67 65 20 6c 6f 63 61 74 69 6f 6e 3a 20 27 20 | Log('[info].storage.location:.'. |
8c8c0 | 2e 20 24 73 74 6f 72 61 67 65 4c 6f 63 61 74 69 6f 6e 29 3b 0a 0a 09 09 24 66 69 6c 65 73 49 6e | ..$storageLocation);....$filesIn |
8c8e0 | 53 74 6f 72 61 67 65 4c 6f 63 61 74 69 6f 6e 20 3d 20 73 63 61 6e 64 69 72 28 24 73 74 6f 72 61 | StorageLocation.=.scandir($stora |
8c900 | 67 65 4c 6f 63 61 74 69 6f 6e 29 3b 0a 09 09 24 66 69 6c 65 73 20 3d 20 61 72 72 61 79 5f 76 61 | geLocation);...$files.=.array_va |
8c920 | 6c 75 65 73 28 61 72 72 61 79 5f 66 69 6c 74 65 72 28 24 66 69 6c 65 73 49 6e 53 74 6f 72 61 67 | lues(array_filter($filesInStorag |
8c940 | 65 4c 6f 63 61 74 69 6f 6e 2c 20 66 75 6e 63 74 69 6f 6e 28 24 70 61 74 68 29 7b 0a 09 09 09 72 | eLocation,.function($path){....r |
8c960 | 65 74 75 72 6e 20 24 70 61 74 68 20 21 3d 3d 20 27 2e 27 20 26 26 20 24 70 61 74 68 20 21 3d 3d | eturn.$path.!==.'.'.&&.$path.!== |
8c980 | 20 27 2e 2e 27 3b 0a 09 09 7d 29 29 3b 0a 09 09 2f 2f 20 6f 6e 6c 79 20 74 68 65 20 64 6f 77 6e | .'..';...}));...//.only.the.down |
8c9a0 | 6c 6f 61 64 65 64 20 61 72 63 68 69 76 65 0a 09 09 69 66 28 63 6f 75 6e 74 28 24 66 69 6c 65 73 | loaded.archive...if(count($files |
8c9c0 | 29 20 21 3d 3d 20 31 29 20 7b 0a 09 09 09 74 68 72 6f 77 20 6e 65 77 20 5c 45 78 63 65 70 74 69 | ).!==.1).{....throw.new.\Excepti |
8c9e0 | 6f 6e 28 27 54 68 65 72 65 20 61 72 65 20 6d 6f 72 65 20 66 69 6c 65 73 20 74 68 61 6e 20 74 68 | on('There.are.more.files.than.th |
8ca00 | 65 20 64 6f 77 6e 6c 6f 61 64 65 64 20 61 72 63 68 69 76 65 20 69 6e 20 74 68 65 20 64 6f 77 6e | e.downloaded.archive.in.the.down |
8ca20 | 6c 6f 61 64 73 2f 20 66 6f 6c 64 65 72 2e 27 29 3b 0a 09 09 7d 0a 09 09 72 65 74 75 72 6e 20 24 | loads/.folder.');...}...return.$ |
8ca40 | 73 74 6f 72 61 67 65 4c 6f 63 61 74 69 6f 6e 20 2e 20 27 2f 27 20 2e 20 24 66 69 6c 65 73 5b 30 | storageLocation...'/'...$files[0 |
8ca60 | 5d 3b 0a 09 7d 0a 0a 09 2f 2a 2a 0a 09 20 2a 20 56 65 72 69 66 69 65 73 20 74 68 65 20 69 6e 74 | ];..}.../**...*.Verifies.the.int |
8ca80 | 65 67 72 69 74 79 20 6f 66 20 74 68 65 20 64 6f 77 6e 6c 6f 61 64 65 64 20 66 69 6c 65 0a 09 20 | egrity.of.the.downloaded.file... |
8caa0 | 2a 0a 09 20 2a 20 40 74 68 72 6f 77 73 20 5c 45 78 63 65 70 74 69 6f 6e 0a 09 20 2a 2f 0a 09 70 | *...*.@throws.\Exception...*/..p |
8cac0 | 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 76 65 72 69 66 79 49 6e 74 65 67 72 69 74 79 28 29 | ublic.function.verifyIntegrity() |
8cae0 | 20 7b 0a 09 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 76 65 | .{...$this->silentLog('[info].ve |
8cb00 | 72 69 66 79 49 6e 74 65 67 72 69 74 79 28 29 27 29 3b 0a 0a 09 09 69 66 28 24 74 68 69 73 2d 3e | rifyIntegrity()');....if($this-> |
8cb20 | 67 65 74 43 75 72 72 65 6e 74 52 65 6c 65 61 73 65 43 68 61 6e 6e 65 6c 28 29 20 3d 3d 3d 20 27 | getCurrentReleaseChannel().===.' |
8cb40 | 64 61 69 6c 79 27 29 20 7b 0a 09 09 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 5b | daily').{....$this->silentLog('[ |
8cb60 | 69 6e 66 6f 5d 20 63 75 72 72 65 6e 74 20 63 68 61 6e 6e 65 6c 20 69 73 20 22 64 61 69 6c 79 22 | info].current.channel.is."daily" |
8cb80 | 20 77 68 69 63 68 20 69 73 20 6e 6f 74 20 73 69 67 6e 65 64 2e 20 53 6b 69 70 70 69 6e 67 20 76 | .which.is.not.signed..Skipping.v |
8cba0 | 65 72 69 66 69 63 61 74 69 6f 6e 2e 27 29 3b 0a 09 09 09 72 65 74 75 72 6e 3b 0a 09 09 7d 0a 0a | erification.');....return;...}.. |
8cbc0 | 09 09 24 72 65 73 70 6f 6e 73 65 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 55 70 64 61 74 65 53 65 | ..$response.=.$this->getUpdateSe |
8cbe0 | 72 76 65 72 52 65 73 70 6f 6e 73 65 28 29 3b 0a 09 09 69 66 28 21 69 73 73 65 74 28 24 72 65 73 | rverResponse();...if(!isset($res |
8cc00 | 70 6f 6e 73 65 5b 27 73 69 67 6e 61 74 75 72 65 27 5d 29 29 20 7b 0a 09 09 09 74 68 72 6f 77 20 | ponse['signature'])).{....throw. |
8cc20 | 6e 65 77 20 5c 45 78 63 65 70 74 69 6f 6e 28 27 4e 6f 20 73 69 67 6e 61 74 75 72 65 20 73 70 65 | new.\Exception('No.signature.spe |
8cc40 | 63 69 66 69 65 64 20 66 6f 72 20 64 65 66 69 6e 65 64 20 75 70 64 61 74 65 27 29 3b 0a 09 09 7d | cified.for.defined.update');...} |
8cc60 | 0a 0a 09 09 24 63 65 72 74 69 66 69 63 61 74 65 20 3d 20 3c 3c 3c 45 4f 46 0a 2d 2d 2d 2d 2d 42 | ....$certificate.=.<<<EOF.-----B |
8cc80 | 45 47 49 4e 20 43 45 52 54 49 46 49 43 41 54 45 2d 2d 2d 2d 2d 0a 4d 49 49 45 6f 6a 43 43 41 34 | EGIN.CERTIFICATE-----.MIIEojCCA4 |
8cca0 | 71 67 41 77 49 42 41 67 49 43 45 41 41 77 44 51 59 4a 4b 6f 5a 49 68 76 63 4e 41 51 45 4c 42 51 | qgAwIBAgICEAAwDQYJKoZIhvcNAQELBQ |
8ccc0 | 41 77 65 7a 45 4c 4d 41 6b 47 41 31 55 45 42 68 4d 43 52 45 55 78 0a 47 7a 41 5a 42 67 4e 56 42 | AwezELMAkGA1UEBhMCREUx.GzAZBgNVB |
8cce0 | 41 67 4d 45 6b 4a 68 5a 47 56 75 4c 56 64 31 5a 58 4a 30 64 47 56 74 59 6d 56 79 5a 7a 45 58 4d | AgMEkJhZGVuLVd1ZXJ0dGVtYmVyZzEXM |
8cd00 | 42 55 47 41 31 55 45 43 67 77 4f 54 6d 56 34 64 47 4e 73 62 33 56 6b 0a 49 45 64 74 59 6b 67 78 | BUGA1UECgwOTmV4dGNsb3Vk.IEdtYkgx |
8cd20 | 4e 6a 41 30 42 67 4e 56 42 41 4d 4d 4c 55 35 6c 65 48 52 6a 62 47 39 31 5a 43 42 44 62 32 52 6c | NjA0BgNVBAMMLU5leHRjbG91ZCBDb2Rl |
8cd40 | 49 46 4e 70 5a 32 35 70 62 6d 63 67 53 57 35 30 5a 58 4a 74 5a 57 52 70 0a 59 58 52 6c 49 45 46 | IFNpZ25pbmcgSW50ZXJtZWRp.YXRlIEF |
8cd60 | 31 64 47 68 76 63 6d 6c 30 65 54 41 65 46 77 30 78 4e 6a 41 32 4d 54 49 79 4d 54 41 31 4d 44 5a | 1dGhvcml0eTAeFw0xNjA2MTIyMTA1MDZ |
8cd80 | 61 46 77 30 30 4d 54 41 32 4d 44 59 79 4d 54 41 31 4d 44 5a 61 4d 47 59 78 0a 43 7a 41 4a 42 67 | aFw00MTA2MDYyMTA1MDZaMGYx.CzAJBg |
8cda0 | 4e 56 42 41 59 54 41 6b 52 46 4d 52 73 77 47 51 59 44 56 51 51 49 44 42 4a 43 59 57 52 6c 62 69 | NVBAYTAkRFMRswGQYDVQQIDBJCYWRlbi |
8cdc0 | 31 58 64 57 56 79 64 48 52 6c 62 57 4a 6c 63 6d 63 78 45 6a 41 51 42 67 4e 56 0a 42 41 63 4d 43 | 1XdWVydHRlbWJlcmcxEjAQBgNV.BAcMC |
8cde0 | 56 4e 30 64 58 52 30 5a 32 46 79 64 44 45 58 4d 42 55 47 41 31 55 45 43 67 77 4f 54 6d 56 34 64 | VN0dXR0Z2FydDEXMBUGA1UECgwOTmV4d |
8ce00 | 47 4e 73 62 33 56 6b 49 45 64 74 59 6b 67 78 44 54 41 4c 42 67 4e 56 42 41 4d 4d 0a 42 47 4e 76 | GNsb3VkIEdtYkgxDTALBgNVBAMM.BGNv |
8ce20 | 63 6d 55 77 67 67 45 69 4d 41 30 47 43 53 71 47 53 49 62 33 44 51 45 42 41 51 55 41 41 34 49 42 | cmUwggEiMA0GCSqGSIb3DQEBAQUAA4IB |
8ce40 | 44 77 41 77 67 67 45 4b 41 6f 49 42 41 51 44 55 78 63 72 6e 32 44 43 38 39 32 49 58 0a 38 2b 64 | DwAwggEKAoIBAQDUxcrn2DC892IX.8+d |
8ce60 | 4a 6a 5a 56 68 39 59 65 48 46 36 35 6e 32 68 61 38 38 36 6f 65 41 69 7a 4f 75 48 42 64 57 42 66 | JjZVh9YeHF65n2ha886oeAizOuHBdWBf |
8ce80 | 7a 71 74 2b 47 6f 55 59 54 4f 6a 71 5a 46 39 33 48 5a 4d 63 77 79 30 50 2b 78 79 43 66 0a 51 71 | zqt+GoUYTOjqZF93HZMcwy0P+xyCf.Qq |
8cea0 | 61 6b 35 4b 65 39 64 79 62 4e 30 36 52 58 55 75 47 50 34 35 6b 39 55 59 42 70 30 33 71 7a 6c 55 | ak5Ke9dybN06RXUuGP45k9UYBp03qzlU |
8cec0 | 7a 43 44 61 6c 72 6b 6a 2b 4a 64 33 30 4c 71 63 53 43 31 73 6a 52 54 73 66 75 68 63 2b 75 0a 76 | zCDalrkj+Jd30LqcSC1sjRTsfuhc+u.v |
8cee0 | 48 31 49 42 75 42 6e 66 37 53 4d 55 4a 55 63 6f 45 66 66 62 6d 6d 70 41 50 6c 45 63 4c 48 78 6c | H1IBuBnf7SMUJUcoEffbmmpAPlEcLHxl |
8cf00 | 55 47 6c 47 6e 7a 30 71 31 65 38 55 46 7a 6a 62 45 46 6a 33 4a 75 63 4d 4f 34 79 73 33 35 46 0a | UGlGnz0q1e8UFzjbEFj3JucMO4ys35F. |
8cf20 | 71 5a 53 34 64 68 76 43 6e 67 51 68 52 57 33 44 61 4d 6c 51 4c 58 45 55 4c 39 6b 33 6b 46 56 2b | qZS4dhvCngQhRW3DaMlQLXEUL9k3kFV+ |
8cf40 | 42 7a 6c 6b 50 7a 56 5a 45 74 53 6d 6b 34 48 4a 75 6a 46 43 6e 5a 6a 31 76 4d 63 6a 51 42 67 2f | BzlkPzVZEtSmk4HJujFCnZj1vMcjQBg/ |
8cf60 | 0a 42 71 71 31 48 43 6d 55 42 36 74 75 6c 6e 47 63 78 55 7a 74 2f 5a 2f 6f 53 49 67 6e 75 47 79 | .Bqq1HCmUB6tulnGcxUzt/Z/oSIgnuGy |
8cf80 | 45 4e 65 6b 65 30 37 37 57 33 45 79 72 79 49 4e 4c 37 45 49 79 44 34 58 70 37 73 78 4c 69 7a 54 | ENeke077W3EyryINL7EIyD4Xp7sxLizT |
8cfa0 | 4d 0a 46 43 46 43 6a 6a 48 31 41 67 4d 42 41 41 47 6a 67 67 46 44 4d 49 49 42 50 7a 41 4a 42 67 | M.FCFCjjH1AgMBAAGjggFDMIIBPzAJBg |
8cfc0 | 4e 56 48 52 4d 45 41 6a 41 41 4d 42 45 47 43 57 43 47 53 41 47 47 2b 45 49 42 41 51 51 45 41 77 | NVHRMEAjAAMBEGCWCGSAGG+EIBAQQEAw |
8cfe0 | 49 47 0a 51 44 41 7a 42 67 6c 67 68 6b 67 42 68 76 68 43 41 51 30 45 4a 68 59 6b 54 33 42 6c 62 | IG.QDAzBglghkgBhvhCAQ0EJhYkT3Blb |
8d000 | 6c 4e 54 54 43 42 48 5a 57 35 6c 63 6d 46 30 5a 57 51 67 55 32 56 79 64 6d 56 79 49 45 4e 6c 63 | lNTTCBHZW5lcmF0ZWQgU2VydmVyIENlc |
8d020 | 6e 52 70 0a 5a 6d 6c 6a 59 58 52 6c 4d 42 30 47 41 31 55 64 44 67 51 57 42 42 51 77 63 31 48 39 | nRp.ZmljYXRlMB0GA1UdDgQWBBQwc1H9 |
8d040 | 41 4c 38 70 52 6c 57 32 65 35 53 4c 43 66 50 50 71 74 71 63 30 44 43 42 70 51 59 44 56 52 30 6a | AL8pRlW2e5SLCfPPqtqc0DCBpQYDVR0j |
8d060 | 42 49 47 64 0a 4d 49 47 61 67 42 52 74 36 6d 36 71 71 54 63 73 50 49 6b 74 46 7a 37 39 52 75 37 | BIGd.MIGagBRt6m6qqTcsPIktFz79Ru7 |
8d080 | 44 6e 6e 6a 74 64 4b 46 2b 70 48 77 77 65 6a 45 4c 4d 41 6b 47 41 31 55 45 42 68 4d 43 52 45 55 | DnnjtdKF+pHwwejELMAkGA1UEBhMCREU |
8d0a0 | 78 47 7a 41 5a 0a 42 67 4e 56 42 41 67 4d 45 6b 4a 68 5a 47 56 75 4c 56 64 31 5a 58 4a 30 64 47 | xGzAZ.BgNVBAgMEkJhZGVuLVd1ZXJ0dG |
8d0c0 | 56 74 59 6d 56 79 5a 7a 45 53 4d 42 41 47 41 31 55 45 42 77 77 4a 55 33 52 31 64 48 52 6e 59 58 | VtYmVyZzESMBAGA1UEBwwJU3R1dHRnYX |
8d0e0 | 4a 30 4d 52 63 77 0a 46 51 59 44 56 51 51 4b 44 41 35 4f 5a 58 68 30 59 32 78 76 64 57 51 67 52 | J0MRcw.FQYDVQQKDA5OZXh0Y2xvdWQgR |
8d100 | 32 31 69 53 44 45 68 4d 42 38 47 41 31 55 45 41 77 77 59 54 6d 56 34 64 47 4e 73 62 33 56 6b 49 | 21iSDEhMB8GA1UEAwwYTmV4dGNsb3VkI |
8d120 | 46 4a 76 62 33 51 67 0a 51 58 56 30 61 47 39 79 61 58 52 35 67 67 49 51 41 44 41 4f 42 67 4e 56 | FJvb3Qg.QXV0aG9yaXR5ggIQADAOBgNV |
8d140 | 48 51 38 42 41 66 38 45 42 41 4d 43 42 61 41 77 45 77 59 44 56 52 30 6c 42 41 77 77 43 67 59 49 | HQ8BAf8EBAMCBaAwEwYDVR0lBAwwCgYI |
8d160 | 4b 77 59 42 42 51 55 48 0a 41 77 45 77 44 51 59 4a 4b 6f 5a 49 68 76 63 4e 41 51 45 4c 42 51 41 | KwYBBQUH.AwEwDQYJKoZIhvcNAQELBQA |
8d180 | 44 67 67 45 42 41 44 5a 36 2b 48 56 2f 2b 30 4e 45 48 33 6e 61 68 54 42 46 78 4f 36 6e 4b 79 52 | DggEBADZ6+HV/+0NEH3nahTBFxO6nKyR |
8d1a0 | 2f 56 57 69 67 41 43 48 30 0a 6e 61 56 30 65 63 54 63 6f 51 77 44 6a 4b 44 4e 4e 46 72 2b 34 53 | /VWigACH0.naV0ecTcoQwDjKDNNFr+4S |
8d1c0 | 31 57 6c 48 64 77 49 54 6c 6e 4e 61 62 43 37 76 39 72 5a 2f 36 51 76 62 6b 72 4f 54 75 4f 39 66 | 1WlHdwITlnNabC7v9rZ/6QvbkrOTuO9f |
8d1e0 | 4f 52 36 61 7a 70 31 45 77 57 0a 32 70 69 78 57 71 6a 30 53 62 39 2f 64 53 49 56 52 70 53 71 2b | OR6azp1EwW.2pixWqj0Sb9/dSIVRpSq+ |
8d200 | 6a 70 42 45 36 4a 41 69 58 34 34 64 53 52 37 7a 6f 42 78 52 42 38 44 67 56 4f 32 41 66 79 30 73 | jpBE6JAiX44dSR7zoBxRB8DgVO2Afy0s |
8d220 | 38 30 78 45 70 72 35 4a 41 7a 62 0a 4e 59 75 50 53 37 4d 35 55 48 64 41 76 32 64 72 31 36 66 44 | 80xEpr5JAzb.NYuPS7M5UHdAv2dr16fD |
8d240 | 63 44 49 76 6e 2b 76 6b 39 32 4b 70 4e 68 31 4e 54 65 5a 46 6a 42 62 52 56 51 39 44 58 72 67 6b | cDIvn+vk92KpNh1NTeZFjBbRVQ9DXrgk |
8d260 | 52 47 57 33 34 54 4b 38 75 53 4c 49 0a 59 47 36 6a 6e 66 4a 36 65 4a 67 54 61 4f 34 33 31 79 77 | RGW34TK8uSLI.YG6jnfJ6eJgTaO431yw |
8d280 | 57 50 58 4e 67 31 6d 55 4d 61 54 2f 2b 51 42 4f 67 42 32 39 39 51 56 43 4b 51 55 2b 6c 63 5a 57 | WPXNg1mUMaT/+QBOgB299QVCKQU+lcZW |
8d2a0 | 70 74 51 74 2b 52 64 73 4a 55 6d 34 36 0a 4e 59 2f 6e 41 52 79 34 4f 69 34 75 4f 65 38 38 53 75 | ptQt+RdsJUm46.NY/nARy4Oi4uOe88Su |
8d2c0 | 57 49 54 6a 39 4b 68 72 46 6d 45 76 72 55 6c 67 4d 38 46 76 6f 58 41 31 6c 64 72 52 37 4b 69 45 | WITj9KhrFmEvrUlgM8FvoXA1ldrR7KiE |
8d2e0 | 67 3d 0a 2d 2d 2d 2d 2d 45 4e 44 20 43 45 52 54 49 46 49 43 41 54 45 2d 2d 2d 2d 2d 0a 45 4f 46 | g=.-----END.CERTIFICATE-----.EOF |
8d300 | 3b 0a 0a 09 09 24 76 61 6c 69 64 53 69 67 6e 61 74 75 72 65 20 3d 20 28 62 6f 6f 6c 29 6f 70 65 | ;....$validSignature.=.(bool)ope |
8d320 | 6e 73 73 6c 5f 76 65 72 69 66 79 28 0a 09 09 09 66 69 6c 65 5f 67 65 74 5f 63 6f 6e 74 65 6e 74 | nssl_verify(....file_get_content |
8d340 | 73 28 24 74 68 69 73 2d 3e 67 65 74 44 6f 77 6e 6c 6f 61 64 65 64 46 69 6c 65 50 61 74 68 28 29 | s($this->getDownloadedFilePath() |
8d360 | 29 2c 0a 09 09 09 62 61 73 65 36 34 5f 64 65 63 6f 64 65 28 24 72 65 73 70 6f 6e 73 65 5b 27 73 | ),....base64_decode($response['s |
8d380 | 69 67 6e 61 74 75 72 65 27 5d 29 2c 0a 09 09 09 24 63 65 72 74 69 66 69 63 61 74 65 2c 0a 09 09 | ignature']),....$certificate,... |
8d3a0 | 09 4f 50 45 4e 53 53 4c 5f 41 4c 47 4f 5f 53 48 41 35 31 32 0a 09 09 29 3b 0a 0a 09 09 69 66 28 | .OPENSSL_ALGO_SHA512...);....if( |
8d3c0 | 24 76 61 6c 69 64 53 69 67 6e 61 74 75 72 65 20 3d 3d 3d 20 66 61 6c 73 65 29 20 7b 0a 09 09 09 | $validSignature.===.false).{.... |
8d3e0 | 74 68 72 6f 77 20 6e 65 77 20 5c 45 78 63 65 70 74 69 6f 6e 28 27 53 69 67 6e 61 74 75 72 65 20 | throw.new.\Exception('Signature. |
8d400 | 6f 66 20 75 70 64 61 74 65 20 69 73 20 6e 6f 74 20 76 61 6c 69 64 27 29 3b 0a 09 09 7d 0a 0a 09 | of.update.is.not.valid');...}... |
8d420 | 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 65 6e 64 20 6f 66 | .$this->silentLog('[info].end.of |
8d440 | 20 76 65 72 69 66 79 49 6e 74 65 67 72 69 74 79 28 29 27 29 3b 0a 09 7d 0a 0a 09 2f 2a 2a 0a 09 | .verifyIntegrity()');..}.../**.. |
8d460 | 20 2a 20 47 65 74 73 20 74 68 65 20 76 65 72 73 69 6f 6e 20 61 73 20 64 65 63 6c 61 72 65 64 20 | .*.Gets.the.version.as.declared. |
8d480 | 69 6e 20 24 76 65 72 73 69 6f 6e 46 69 6c 65 0a 09 20 2a 0a 09 20 2a 20 40 70 61 72 61 6d 20 73 | in.$versionFile...*...*.@param.s |
8d4a0 | 74 72 69 6e 67 20 24 76 65 72 73 69 6f 6e 46 69 6c 65 0a 09 20 2a 20 40 72 65 74 75 72 6e 20 73 | tring.$versionFile...*.@return.s |
8d4c0 | 74 72 69 6e 67 0a 09 20 2a 20 40 74 68 72 6f 77 73 20 5c 45 78 63 65 70 74 69 6f 6e 20 49 66 20 | tring...*.@throws.\Exception.If. |
8d4e0 | 24 4f 43 5f 56 65 72 73 69 6f 6e 20 69 73 20 6e 6f 74 20 64 65 66 69 6e 65 64 20 69 6e 20 24 76 | $OC_Version.is.not.defined.in.$v |
8d500 | 65 72 73 69 6f 6e 46 69 6c 65 0a 09 20 2a 2f 0a 09 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f | ersionFile...*/..private.functio |
8d520 | 6e 20 67 65 74 56 65 72 73 69 6f 6e 42 79 56 65 72 73 69 6f 6e 46 69 6c 65 28 24 76 65 72 73 69 | n.getVersionByVersionFile($versi |
8d540 | 6f 6e 46 69 6c 65 29 20 7b 0a 09 09 72 65 71 75 69 72 65 20 24 76 65 72 73 69 6f 6e 46 69 6c 65 | onFile).{...require.$versionFile |
8d560 | 3b 0a 0a 09 09 69 66 28 69 73 73 65 74 28 24 4f 43 5f 56 65 72 73 69 6f 6e 29 29 20 7b 0a 09 09 | ;....if(isset($OC_Version)).{... |
8d580 | 09 2f 2a 2a 20 40 76 61 72 20 61 72 72 61 79 20 24 4f 43 5f 56 65 72 73 69 6f 6e 20 2a 2f 0a 09 | ./**.@var.array.$OC_Version.*/.. |
8d5a0 | 09 09 72 65 74 75 72 6e 20 69 6d 70 6c 6f 64 65 28 27 2e 27 2c 20 24 4f 43 5f 56 65 72 73 69 6f | ..return.implode('.',.$OC_Versio |
8d5c0 | 6e 29 3b 0a 09 09 7d 0a 0a 09 09 74 68 72 6f 77 20 6e 65 77 20 5c 45 78 63 65 70 74 69 6f 6e 28 | n);...}....throw.new.\Exception( |
8d5e0 | 22 4f 43 5f 56 65 72 73 69 6f 6e 20 6e 6f 74 20 66 6f 75 6e 64 20 69 6e 20 24 76 65 72 73 69 6f | "OC_Version.not.found.in.$versio |
8d600 | 6e 46 69 6c 65 22 29 3b 0a 09 7d 0a 0a 09 2f 2a 2a 0a 09 20 2a 20 45 78 74 72 61 63 74 73 20 74 | nFile");..}.../**...*.Extracts.t |
8d620 | 68 65 20 64 6f 77 6e 6c 6f 61 64 0a 09 20 2a 0a 09 20 2a 20 40 74 68 72 6f 77 73 20 5c 45 78 63 | he.download...*...*.@throws.\Exc |
8d640 | 65 70 74 69 6f 6e 0a 09 20 2a 2f 0a 09 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 65 78 74 | eption...*/..public.function.ext |
8d660 | 72 61 63 74 44 6f 77 6e 6c 6f 61 64 28 29 20 7b 0a 09 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e 74 | ractDownload().{...$this->silent |
8d680 | 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 65 78 74 72 61 63 74 44 6f 77 6e 6c 6f 61 64 28 29 27 29 3b | Log('[info].extractDownload()'); |
8d6a0 | 0a 09 09 24 64 6f 77 6e 6c 6f 61 64 65 64 46 69 6c 65 50 61 74 68 20 3d 20 24 74 68 69 73 2d 3e | ...$downloadedFilePath.=.$this-> |
8d6c0 | 67 65 74 44 6f 77 6e 6c 6f 61 64 65 64 46 69 6c 65 50 61 74 68 28 29 3b 0a 0a 09 09 24 7a 69 70 | getDownloadedFilePath();....$zip |
8d6e0 | 20 3d 20 6e 65 77 20 5c 5a 69 70 41 72 63 68 69 76 65 3b 0a 09 09 24 7a 69 70 53 74 61 74 65 20 | .=.new.\ZipArchive;...$zipState. |
8d700 | 3d 20 24 7a 69 70 2d 3e 6f 70 65 6e 28 24 64 6f 77 6e 6c 6f 61 64 65 64 46 69 6c 65 50 61 74 68 | =.$zip->open($downloadedFilePath |
8d720 | 29 3b 0a 09 09 69 66 20 28 24 7a 69 70 53 74 61 74 65 20 3d 3d 3d 20 74 72 75 65 29 20 7b 0a 09 | );...if.($zipState.===.true).{.. |
8d740 | 09 09 24 65 78 74 72 61 63 74 69 6f 6e 20 3d 20 24 7a 69 70 2d 3e 65 78 74 72 61 63 74 54 6f 28 | ..$extraction.=.$zip->extractTo( |
8d760 | 64 69 72 6e 61 6d 65 28 24 64 6f 77 6e 6c 6f 61 64 65 64 46 69 6c 65 50 61 74 68 29 29 3b 0a 09 | dirname($downloadedFilePath));.. |
8d780 | 09 09 69 66 28 24 65 78 74 72 61 63 74 69 6f 6e 20 3d 3d 3d 20 66 61 6c 73 65 29 20 7b 0a 09 09 | ..if($extraction.===.false).{... |
8d7a0 | 09 09 74 68 72 6f 77 20 6e 65 77 20 5c 45 78 63 65 70 74 69 6f 6e 28 27 45 72 72 6f 72 20 64 75 | ..throw.new.\Exception('Error.du |
8d7c0 | 72 69 6e 67 20 75 6e 70 61 63 6b 69 6e 67 20 7a 69 70 66 69 6c 65 3a 20 27 2e 28 24 7a 69 70 2d | ring.unpacking.zipfile:.'.($zip- |
8d7e0 | 3e 67 65 74 53 74 61 74 75 73 53 74 72 69 6e 67 28 29 29 29 3b 0a 09 09 09 7d 0a 09 09 09 24 7a | >getStatusString()));....}....$z |
8d800 | 69 70 2d 3e 63 6c 6f 73 65 28 29 3b 0a 09 09 09 24 73 74 61 74 65 20 3d 20 75 6e 6c 69 6e 6b 28 | ip->close();....$state.=.unlink( |
8d820 | 24 64 6f 77 6e 6c 6f 61 64 65 64 46 69 6c 65 50 61 74 68 29 3b 0a 09 09 09 69 66 28 24 73 74 61 | $downloadedFilePath);....if($sta |
8d840 | 74 65 20 3d 3d 3d 20 66 61 6c 73 65 29 20 7b 0a 09 09 09 09 74 68 72 6f 77 20 6e 65 77 20 5c 45 | te.===.false).{.....throw.new.\E |
8d860 | 78 63 65 70 74 69 6f 6e 28 22 43 61 6e 27 74 20 75 6e 6c 69 6e 6b 20 22 2e 20 24 64 6f 77 6e 6c | xception("Can't.unlink."..$downl |
8d880 | 6f 61 64 65 64 46 69 6c 65 50 61 74 68 29 3b 0a 09 09 09 7d 0a 09 09 7d 20 65 6c 73 65 20 7b 0a | oadedFilePath);....}...}.else.{. |
8d8a0 | 09 09 09 74 68 72 6f 77 20 6e 65 77 20 5c 45 78 63 65 70 74 69 6f 6e 28 22 43 61 6e 27 74 20 68 | ...throw.new.\Exception("Can't.h |
8d8c0 | 61 6e 64 6c 65 20 5a 49 50 20 66 69 6c 65 2e 20 45 72 72 6f 72 20 63 6f 64 65 20 69 73 3a 20 22 | andle.ZIP.file..Error.code.is:." |
8d8e0 | 2e 24 7a 69 70 53 74 61 74 65 29 3b 0a 09 09 7d 0a 0a 09 09 2f 2f 20 45 6e 73 75 72 65 20 74 68 | .$zipState);...}....//.Ensure.th |
8d900 | 61 74 20 74 68 65 20 64 6f 77 6e 6c 6f 61 64 65 64 20 76 65 72 73 69 6f 6e 20 69 73 20 6e 6f 74 | at.the.downloaded.version.is.not |
8d920 | 20 6c 6f 77 65 72 0a 09 09 24 64 6f 77 6e 6c 6f 61 64 65 64 56 65 72 73 69 6f 6e 20 3d 20 24 74 | .lower...$downloadedVersion.=.$t |
8d940 | 68 69 73 2d 3e 67 65 74 56 65 72 73 69 6f 6e 42 79 56 65 72 73 69 6f 6e 46 69 6c 65 28 64 69 72 | his->getVersionByVersionFile(dir |
8d960 | 6e 61 6d 65 28 24 64 6f 77 6e 6c 6f 61 64 65 64 46 69 6c 65 50 61 74 68 29 20 2e 20 27 2f 6e 65 | name($downloadedFilePath)...'/ne |
8d980 | 78 74 63 6c 6f 75 64 2f 76 65 72 73 69 6f 6e 2e 70 68 70 27 29 3b 0a 09 09 24 63 75 72 72 65 6e | xtcloud/version.php');...$curren |
8d9a0 | 74 56 65 72 73 69 6f 6e 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 56 65 72 73 69 6f 6e 42 79 56 65 | tVersion.=.$this->getVersionByVe |
8d9c0 | 72 73 69 6f 6e 46 69 6c 65 28 24 74 68 69 73 2d 3e 62 61 73 65 44 69 72 20 2e 20 27 2f 2e 2e 2f | rsionFile($this->baseDir...'/../ |
8d9e0 | 76 65 72 73 69 6f 6e 2e 70 68 70 27 29 3b 0a 09 09 69 66 28 76 65 72 73 69 6f 6e 5f 63 6f 6d 70 | version.php');...if(version_comp |
8da00 | 61 72 65 28 24 64 6f 77 6e 6c 6f 61 64 65 64 56 65 72 73 69 6f 6e 2c 20 24 63 75 72 72 65 6e 74 | are($downloadedVersion,.$current |
8da20 | 56 65 72 73 69 6f 6e 2c 20 27 3c 27 29 29 20 7b 0a 09 09 09 74 68 72 6f 77 20 6e 65 77 20 5c 45 | Version,.'<')).{....throw.new.\E |
8da40 | 78 63 65 70 74 69 6f 6e 28 27 44 6f 77 6e 6c 6f 61 64 65 64 20 76 65 72 73 69 6f 6e 20 69 73 20 | xception('Downloaded.version.is. |
8da60 | 6c 6f 77 65 72 20 74 68 61 6e 20 69 6e 73 74 61 6c 6c 65 64 20 76 65 72 73 69 6f 6e 27 29 3b 0a | lower.than.installed.version');. |
8da80 | 09 09 7d 0a 0a 09 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 | ..}....$this->silentLog('[info]. |
8daa0 | 65 6e 64 20 6f 66 20 65 78 74 72 61 63 74 44 6f 77 6e 6c 6f 61 64 28 29 27 29 3b 0a 09 7d 0a 0a | end.of.extractDownload()');..}.. |
8dac0 | 09 2f 2a 2a 0a 09 20 2a 20 52 65 70 6c 61 63 65 73 20 74 68 65 20 65 6e 74 72 79 20 70 6f 69 6e | ./**...*.Replaces.the.entry.poin |
8dae0 | 74 20 66 69 6c 65 73 20 77 69 74 68 20 66 69 6c 65 73 20 74 68 61 74 20 6f 6e 6c 79 20 72 65 74 | t.files.with.files.that.only.ret |
8db00 | 75 72 6e 20 61 20 35 30 33 0a 09 20 2a 0a 09 20 2a 20 40 74 68 72 6f 77 73 20 5c 45 78 63 65 70 | urn.a.503...*...*.@throws.\Excep |
8db20 | 74 69 6f 6e 0a 09 20 2a 2f 0a 09 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 72 65 70 6c 61 | tion...*/..public.function.repla |
8db40 | 63 65 45 6e 74 72 79 50 6f 69 6e 74 73 28 29 20 7b 0a 09 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e | ceEntryPoints().{...$this->silen |
8db60 | 74 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 72 65 70 6c 61 63 65 45 6e 74 72 79 50 6f 69 6e 74 73 28 | tLog('[info].replaceEntryPoints( |
8db80 | 29 27 29 3b 0a 0a 09 09 24 66 69 6c 65 73 54 6f 52 65 70 6c 61 63 65 20 3d 20 5b 0a 09 09 09 27 | )');....$filesToReplace.=.[....' |
8dba0 | 69 6e 64 65 78 2e 70 68 70 27 2c 0a 09 09 09 27 73 74 61 74 75 73 2e 70 68 70 27 2c 0a 09 09 09 | index.php',....'status.php',.... |
8dbc0 | 27 72 65 6d 6f 74 65 2e 70 68 70 27 2c 0a 09 09 09 27 70 75 62 6c 69 63 2e 70 68 70 27 2c 0a 09 | 'remote.php',....'public.php',.. |
8dbe0 | 09 09 27 6f 63 73 2f 76 31 2e 70 68 70 27 2c 0a 09 09 09 27 6f 63 73 2f 76 32 2e 70 68 70 27 2c | ..'ocs/v1.php',....'ocs/v2.php', |
8dc00 | 0a 09 09 5d 3b 0a 0a 09 09 24 63 6f 6e 74 65 6e 74 20 3d 20 22 3c 3f 70 68 70 5c 6e 68 74 74 70 | ...];....$content.=."<?php\nhttp |
8dc20 | 5f 72 65 73 70 6f 6e 73 65 5f 63 6f 64 65 28 35 30 33 29 3b 5c 6e 64 69 65 28 27 55 70 64 61 74 | _response_code(503);\ndie('Updat |
8dc40 | 65 20 69 6e 20 70 72 6f 63 65 73 73 2e 27 29 3b 22 3b 0a 09 09 66 6f 72 65 61 63 68 28 24 66 69 | e.in.process.');";...foreach($fi |
8dc60 | 6c 65 73 54 6f 52 65 70 6c 61 63 65 20 61 73 20 24 66 69 6c 65 29 20 7b 0a 09 09 09 24 74 68 69 | lesToReplace.as.$file).{....$thi |
8dc80 | 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 72 65 70 6c 61 63 65 20 27 20 2e | s->silentLog('[info].replace.'.. |
8dca0 | 20 24 66 69 6c 65 29 3b 0a 09 09 09 24 70 61 72 65 6e 74 44 69 72 20 3d 20 64 69 72 6e 61 6d 65 | .$file);....$parentDir.=.dirname |
8dcc0 | 28 24 74 68 69 73 2d 3e 62 61 73 65 44 69 72 20 2e 20 27 2f 2e 2e 2f 27 20 2e 20 24 66 69 6c 65 | ($this->baseDir...'/../'...$file |
8dce0 | 29 3b 0a 09 09 09 69 66 28 21 66 69 6c 65 5f 65 78 69 73 74 73 28 24 70 61 72 65 6e 74 44 69 72 | );....if(!file_exists($parentDir |
8dd00 | 29 29 20 7b 0a 09 09 09 09 24 72 20 3d 20 6d 6b 64 69 72 28 24 70 61 72 65 6e 74 44 69 72 29 3b | )).{.....$r.=.mkdir($parentDir); |
8dd20 | 0a 09 09 09 09 69 66 28 24 72 20 21 3d 3d 20 74 72 75 65 29 20 7b 0a 09 09 09 09 09 74 68 72 6f | .....if($r.!==.true).{......thro |
8dd40 | 77 20 6e 65 77 20 5c 45 78 63 65 70 74 69 6f 6e 28 27 43 61 6e 5c 27 74 20 63 72 65 61 74 65 20 | w.new.\Exception('Can\'t.create. |
8dd60 | 70 61 72 65 6e 74 20 64 69 72 65 63 74 6f 72 79 20 66 6f 72 20 65 6e 74 72 79 20 70 6f 69 6e 74 | parent.directory.for.entry.point |
8dd80 | 3a 20 27 20 2e 20 24 66 69 6c 65 29 3b 0a 09 09 09 09 7d 0a 09 09 09 7d 0a 09 09 09 24 73 74 61 | :.'...$file);.....}....}....$sta |
8dda0 | 74 65 20 3d 20 66 69 6c 65 5f 70 75 74 5f 63 6f 6e 74 65 6e 74 73 28 24 74 68 69 73 2d 3e 62 61 | te.=.file_put_contents($this->ba |
8ddc0 | 73 65 44 69 72 20 20 2e 20 27 2f 2e 2e 2f 27 20 2e 20 24 66 69 6c 65 2c 20 24 63 6f 6e 74 65 6e | seDir....'/../'...$file,.$conten |
8dde0 | 74 29 3b 0a 09 09 09 69 66 28 24 73 74 61 74 65 20 3d 3d 3d 20 66 61 6c 73 65 29 20 7b 0a 09 09 | t);....if($state.===.false).{... |
8de00 | 09 09 74 68 72 6f 77 20 6e 65 77 20 5c 45 78 63 65 70 74 69 6f 6e 28 27 43 61 6e 5c 27 74 20 72 | ..throw.new.\Exception('Can\'t.r |
8de20 | 65 70 6c 61 63 65 20 65 6e 74 72 79 20 70 6f 69 6e 74 3a 20 27 2e 24 66 69 6c 65 29 3b 0a 09 09 | eplace.entry.point:.'.$file);... |
8de40 | 09 7d 0a 09 09 7d 0a 0a 09 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 5b 69 6e 66 | .}...}....$this->silentLog('[inf |
8de60 | 6f 5d 20 65 6e 64 20 6f 66 20 72 65 70 6c 61 63 65 45 6e 74 72 79 50 6f 69 6e 74 73 28 29 27 29 | o].end.of.replaceEntryPoints()') |
8de80 | 3b 0a 09 7d 0a 0a 09 2f 2a 2a 0a 09 20 2a 20 52 65 63 75 72 73 69 76 65 6c 79 20 64 65 6c 65 74 | ;..}.../**...*.Recursively.delet |
8dea0 | 65 73 20 74 68 65 20 73 70 65 63 69 66 69 65 64 20 66 6f 6c 64 65 72 20 66 72 6f 6d 20 74 68 65 | es.the.specified.folder.from.the |
8dec0 | 20 73 79 73 74 65 6d 0a 09 20 2a 0a 09 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 66 | .system...*...*.@param.string.$f |
8dee0 | 6f 6c 64 65 72 0a 09 20 2a 20 40 74 68 72 6f 77 73 20 5c 45 78 63 65 70 74 69 6f 6e 0a 09 20 2a | older...*.@throws.\Exception...* |
8df00 | 2f 0a 09 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 72 65 63 75 72 73 69 76 65 44 65 6c | /..private.function.recursiveDel |
8df20 | 65 74 65 28 24 66 6f 6c 64 65 72 29 20 7b 0a 09 09 69 66 28 21 66 69 6c 65 5f 65 78 69 73 74 73 | ete($folder).{...if(!file_exists |
8df40 | 28 24 66 6f 6c 64 65 72 29 29 20 7b 0a 09 09 09 72 65 74 75 72 6e 3b 0a 09 09 7d 0a 09 09 24 69 | ($folder)).{....return;...}...$i |
8df60 | 74 65 72 61 74 6f 72 20 3d 20 6e 65 77 20 5c 52 65 63 75 72 73 69 76 65 49 74 65 72 61 74 6f 72 | terator.=.new.\RecursiveIterator |
8df80 | 49 74 65 72 61 74 6f 72 28 0a 09 09 09 6e 65 77 20 5c 52 65 63 75 72 73 69 76 65 44 69 72 65 63 | Iterator(....new.\RecursiveDirec |
8dfa0 | 74 6f 72 79 49 74 65 72 61 74 6f 72 28 24 66 6f 6c 64 65 72 2c 20 5c 52 65 63 75 72 73 69 76 65 | toryIterator($folder,.\Recursive |
8dfc0 | 44 69 72 65 63 74 6f 72 79 49 74 65 72 61 74 6f 72 3a 3a 53 4b 49 50 5f 44 4f 54 53 29 2c 0a 09 | DirectoryIterator::SKIP_DOTS),.. |
8dfe0 | 09 09 5c 52 65 63 75 72 73 69 76 65 49 74 65 72 61 74 6f 72 49 74 65 72 61 74 6f 72 3a 3a 43 48 | ..\RecursiveIteratorIterator::CH |
8e000 | 49 4c 44 5f 46 49 52 53 54 0a 09 09 29 3b 0a 0a 09 09 24 64 69 72 65 63 74 6f 72 69 65 73 20 3d | ILD_FIRST...);....$directories.= |
8e020 | 20 61 72 72 61 79 28 29 3b 0a 09 09 24 66 69 6c 65 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 09 09 | .array();...$files.=.array();... |
8e040 | 66 6f 72 65 61 63 68 20 28 24 69 74 65 72 61 74 6f 72 20 61 73 20 24 66 69 6c 65 49 6e 66 6f 29 | foreach.($iterator.as.$fileInfo) |
8e060 | 20 7b 0a 09 09 09 69 66 20 28 24 66 69 6c 65 49 6e 66 6f 2d 3e 69 73 44 69 72 28 29 29 20 7b 0a | .{....if.($fileInfo->isDir()).{. |
8e080 | 09 09 09 09 24 64 69 72 65 63 74 6f 72 69 65 73 5b 5d 20 3d 20 24 66 69 6c 65 49 6e 66 6f 2d 3e | ....$directories[].=.$fileInfo-> |
8e0a0 | 67 65 74 52 65 61 6c 50 61 74 68 28 29 3b 0a 09 09 09 7d 20 65 6c 73 65 20 7b 0a 09 09 09 09 69 | getRealPath();....}.else.{.....i |
8e0c0 | 66 20 28 24 66 69 6c 65 49 6e 66 6f 2d 3e 69 73 4c 69 6e 6b 28 29 29 20 7b 0a 09 09 09 09 09 24 | f.($fileInfo->isLink()).{......$ |
8e0e0 | 66 69 6c 65 73 5b 5d 20 3d 20 24 66 69 6c 65 49 6e 66 6f 2d 3e 67 65 74 50 61 74 68 4e 61 6d 65 | files[].=.$fileInfo->getPathName |
8e100 | 28 29 3b 0a 09 09 09 09 7d 20 65 6c 73 65 20 7b 0a 09 09 09 09 09 24 66 69 6c 65 73 5b 5d 20 3d | ();.....}.else.{......$files[].= |
8e120 | 20 24 66 69 6c 65 49 6e 66 6f 2d 3e 67 65 74 52 65 61 6c 50 61 74 68 28 29 3b 0a 09 09 09 09 7d | .$fileInfo->getRealPath();.....} |
8e140 | 0a 09 09 09 7d 0a 09 09 7d 0a 0a 09 09 66 6f 72 65 61 63 68 20 28 24 66 69 6c 65 73 20 61 73 20 | ....}...}....foreach.($files.as. |
8e160 | 24 66 69 6c 65 29 20 7b 0a 09 09 09 75 6e 6c 69 6e 6b 28 24 66 69 6c 65 29 3b 0a 09 09 7d 0a 09 | $file).{....unlink($file);...}.. |
8e180 | 09 66 6f 72 65 61 63 68 20 28 24 64 69 72 65 63 74 6f 72 69 65 73 20 61 73 20 24 64 69 72 29 20 | .foreach.($directories.as.$dir). |
8e1a0 | 7b 0a 09 09 09 72 6d 64 69 72 28 24 64 69 72 29 3b 0a 09 09 7d 0a 0a 09 09 24 73 74 61 74 65 20 | {....rmdir($dir);...}....$state. |
8e1c0 | 3d 20 72 6d 64 69 72 28 24 66 6f 6c 64 65 72 29 3b 0a 09 09 69 66 28 24 73 74 61 74 65 20 3d 3d | =.rmdir($folder);...if($state.== |
8e1e0 | 3d 20 66 61 6c 73 65 29 20 7b 0a 09 09 09 74 68 72 6f 77 20 6e 65 77 20 5c 45 78 63 65 70 74 69 | =.false).{....throw.new.\Excepti |
8e200 | 6f 6e 28 27 43 6f 75 6c 64 20 6e 6f 74 20 72 6d 64 69 72 20 27 20 2e 20 24 66 6f 6c 64 65 72 29 | on('Could.not.rmdir.'...$folder) |
8e220 | 3b 0a 09 09 7d 0a 09 7d 0a 0a 09 2f 2a 2a 0a 09 20 2a 20 44 65 6c 65 74 65 20 6f 6c 64 20 66 69 | ;...}..}.../**...*.Delete.old.fi |
8e240 | 6c 65 73 20 66 72 6f 6d 20 74 68 65 20 73 79 73 74 65 6d 20 61 73 20 6d 75 63 68 20 61 73 20 70 | les.from.the.system.as.much.as.p |
8e260 | 6f 73 73 69 62 6c 65 0a 09 20 2a 0a 09 20 2a 20 40 74 68 72 6f 77 73 20 5c 45 78 63 65 70 74 69 | ossible...*...*.@throws.\Excepti |
8e280 | 6f 6e 0a 09 20 2a 2f 0a 09 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 64 65 6c 65 74 65 4f | on...*/..public.function.deleteO |
8e2a0 | 6c 64 46 69 6c 65 73 28 29 20 7b 0a 09 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 | ldFiles().{...$this->silentLog(' |
8e2c0 | 5b 69 6e 66 6f 5d 20 64 65 6c 65 74 65 4f 6c 64 46 69 6c 65 73 28 29 27 29 3b 0a 0a 09 09 24 73 | [info].deleteOldFiles()');....$s |
8e2e0 | 68 69 70 70 65 64 41 70 70 73 46 69 6c 65 20 3d 20 24 74 68 69 73 2d 3e 62 61 73 65 44 69 72 20 | hippedAppsFile.=.$this->baseDir. |
8e300 | 2e 20 27 2f 2e 2e 2f 63 6f 72 65 2f 73 68 69 70 70 65 64 2e 6a 73 6f 6e 27 3b 0a 09 09 69 66 28 | ..'/../core/shipped.json';...if( |
8e320 | 21 66 69 6c 65 5f 65 78 69 73 74 73 28 24 73 68 69 70 70 65 64 41 70 70 73 46 69 6c 65 29 29 20 | !file_exists($shippedAppsFile)). |
8e340 | 7b 0a 09 09 09 74 68 72 6f 77 20 6e 65 77 20 5c 45 78 63 65 70 74 69 6f 6e 28 27 63 6f 72 65 2f | {....throw.new.\Exception('core/ |
8e360 | 73 68 69 70 70 65 64 2e 6a 73 6f 6e 20 69 73 20 6e 6f 74 20 61 76 61 69 6c 61 62 6c 65 27 29 3b | shipped.json.is.not.available'); |
8e380 | 0a 09 09 7d 0a 0a 09 09 24 6e 65 77 53 68 69 70 70 65 64 41 70 70 73 46 69 6c 65 20 3d 20 24 74 | ...}....$newShippedAppsFile.=.$t |
8e3a0 | 68 69 73 2d 3e 67 65 74 44 61 74 61 44 69 72 65 63 74 6f 72 79 4c 6f 63 61 74 69 6f 6e 28 29 20 | his->getDataDirectoryLocation(). |
8e3c0 | 2e 20 27 2f 75 70 64 61 74 65 72 2d 27 2e 24 74 68 69 73 2d 3e 67 65 74 43 6f 6e 66 69 67 4f 70 | ..'/updater-'.$this->getConfigOp |
8e3e0 | 74 69 6f 6e 28 27 69 6e 73 74 61 6e 63 65 69 64 27 29 20 2e 20 27 2f 64 6f 77 6e 6c 6f 61 64 73 | tion('instanceid')...'/downloads |
8e400 | 2f 6e 65 78 74 63 6c 6f 75 64 2f 63 6f 72 65 2f 73 68 69 70 70 65 64 2e 6a 73 6f 6e 27 3b 0a 09 | /nextcloud/core/shipped.json';.. |
8e420 | 09 69 66 28 21 66 69 6c 65 5f 65 78 69 73 74 73 28 24 6e 65 77 53 68 69 70 70 65 64 41 70 70 73 | .if(!file_exists($newShippedApps |
8e440 | 46 69 6c 65 29 29 20 7b 0a 09 09 09 74 68 72 6f 77 20 6e 65 77 20 5c 45 78 63 65 70 74 69 6f 6e | File)).{....throw.new.\Exception |
8e460 | 28 27 63 6f 72 65 2f 73 68 69 70 70 65 64 2e 6a 73 6f 6e 20 69 73 20 6e 6f 74 20 61 76 61 69 6c | ('core/shipped.json.is.not.avail |
8e480 | 61 62 6c 65 20 69 6e 20 74 68 65 20 6e 65 77 20 72 65 6c 65 61 73 65 27 29 3b 0a 09 09 7d 0a 0a | able.in.the.new.release');...}.. |
8e4a0 | 09 09 2f 2f 20 44 65 6c 65 74 65 20 73 68 69 70 70 65 64 20 61 70 70 73 0a 09 09 24 73 68 69 70 | ..//.Delete.shipped.apps...$ship |
8e4c0 | 70 65 64 41 70 70 73 20 3d 20 61 72 72 61 79 5f 6d 65 72 67 65 28 0a 09 09 09 6a 73 6f 6e 5f 64 | pedApps.=.array_merge(....json_d |
8e4e0 | 65 63 6f 64 65 28 66 69 6c 65 5f 67 65 74 5f 63 6f 6e 74 65 6e 74 73 28 24 73 68 69 70 70 65 64 | ecode(file_get_contents($shipped |
8e500 | 41 70 70 73 46 69 6c 65 29 2c 20 74 72 75 65 29 5b 27 73 68 69 70 70 65 64 41 70 70 73 27 5d 2c | AppsFile),.true)['shippedApps'], |
8e520 | 0a 09 09 09 6a 73 6f 6e 5f 64 65 63 6f 64 65 28 66 69 6c 65 5f 67 65 74 5f 63 6f 6e 74 65 6e 74 | ....json_decode(file_get_content |
8e540 | 73 28 24 6e 65 77 53 68 69 70 70 65 64 41 70 70 73 46 69 6c 65 29 2c 20 74 72 75 65 29 5b 27 73 | s($newShippedAppsFile),.true)['s |
8e560 | 68 69 70 70 65 64 41 70 70 73 27 5d 0a 09 09 29 3b 0a 09 09 66 6f 72 65 61 63 68 28 24 73 68 69 | hippedApps']...);...foreach($shi |
8e580 | 70 70 65 64 41 70 70 73 20 61 73 20 24 61 70 70 29 20 7b 0a 09 09 09 24 74 68 69 73 2d 3e 72 65 | ppedApps.as.$app).{....$this->re |
8e5a0 | 63 75 72 73 69 76 65 44 65 6c 65 74 65 28 24 74 68 69 73 2d 3e 62 61 73 65 44 69 72 20 2e 20 27 | cursiveDelete($this->baseDir...' |
8e5c0 | 2f 2e 2e 2f 61 70 70 73 2f 27 20 2e 20 24 61 70 70 29 3b 0a 09 09 7d 0a 0a 09 09 24 63 6f 6e 66 | /../apps/'...$app);...}....$conf |
8e5e0 | 69 67 53 61 6d 70 6c 65 46 69 6c 65 20 3d 20 24 74 68 69 73 2d 3e 62 61 73 65 44 69 72 20 2e 20 | igSampleFile.=.$this->baseDir... |
8e600 | 27 2f 2e 2e 2f 63 6f 6e 66 69 67 2f 63 6f 6e 66 69 67 2e 73 61 6d 70 6c 65 2e 70 68 70 27 3b 0a | '/../config/config.sample.php';. |
8e620 | 09 09 69 66 28 66 69 6c 65 5f 65 78 69 73 74 73 28 24 63 6f 6e 66 69 67 53 61 6d 70 6c 65 46 69 | ..if(file_exists($configSampleFi |
8e640 | 6c 65 29 29 20 7b 0a 09 09 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 5b 69 6e 66 | le)).{....$this->silentLog('[inf |
8e660 | 6f 5d 20 63 6f 6e 66 69 67 20 73 61 6d 70 6c 65 20 65 78 69 73 74 73 27 29 3b 0a 0a 09 09 09 2f | o].config.sample.exists');...../ |
8e680 | 2f 20 44 65 6c 65 74 65 20 65 78 61 6d 70 6c 65 20 63 6f 6e 66 69 67 0a 09 09 09 24 73 74 61 74 | /.Delete.example.config....$stat |
8e6a0 | 65 20 3d 20 75 6e 6c 69 6e 6b 28 24 63 6f 6e 66 69 67 53 61 6d 70 6c 65 46 69 6c 65 29 3b 0a 09 | e.=.unlink($configSampleFile);.. |
8e6c0 | 09 09 69 66 20 28 24 73 74 61 74 65 20 3d 3d 3d 20 66 61 6c 73 65 29 20 7b 0a 09 09 09 09 74 68 | ..if.($state.===.false).{.....th |
8e6e0 | 72 6f 77 20 6e 65 77 20 5c 45 78 63 65 70 74 69 6f 6e 28 27 43 6f 75 6c 64 20 6e 6f 74 20 75 6e | row.new.\Exception('Could.not.un |
8e700 | 6c 69 6e 6b 20 73 61 6d 70 6c 65 20 63 6f 6e 66 69 67 27 29 3b 0a 09 09 09 7d 0a 09 09 7d 0a 0a | link.sample.config');....}...}.. |
8e720 | 09 09 24 74 68 65 6d 65 73 52 65 61 64 6d 65 20 3d 20 24 74 68 69 73 2d 3e 62 61 73 65 44 69 72 | ..$themesReadme.=.$this->baseDir |
8e740 | 20 2e 20 27 2f 2e 2e 2f 74 68 65 6d 65 73 2f 52 45 41 44 4d 45 27 3b 0a 09 09 69 66 28 66 69 6c | ...'/../themes/README';...if(fil |
8e760 | 65 5f 65 78 69 73 74 73 28 24 74 68 65 6d 65 73 52 65 61 64 6d 65 29 29 20 7b 0a 09 09 09 24 74 | e_exists($themesReadme)).{....$t |
8e780 | 68 69 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 74 68 65 6d 65 73 20 52 45 | his->silentLog('[info].themes.RE |
8e7a0 | 41 44 4d 45 20 65 78 69 73 74 73 27 29 3b 0a 0a 09 09 09 2f 2f 20 44 65 6c 65 74 65 20 74 68 65 | ADME.exists');.....//.Delete.the |
8e7c0 | 6d 65 73 0a 09 09 09 24 73 74 61 74 65 20 3d 20 75 6e 6c 69 6e 6b 28 24 74 68 65 6d 65 73 52 65 | mes....$state.=.unlink($themesRe |
8e7e0 | 61 64 6d 65 29 3b 0a 09 09 09 69 66 20 28 24 73 74 61 74 65 20 3d 3d 3d 20 66 61 6c 73 65 29 20 | adme);....if.($state.===.false). |
8e800 | 7b 0a 09 09 09 09 74 68 72 6f 77 20 6e 65 77 20 5c 45 78 63 65 70 74 69 6f 6e 28 27 43 6f 75 6c | {.....throw.new.\Exception('Coul |
8e820 | 64 20 6e 6f 74 20 64 65 6c 65 74 65 20 74 68 65 6d 65 73 20 52 45 41 44 4d 45 27 29 3b 0a 09 09 | d.not.delete.themes.README');... |
8e840 | 09 7d 0a 09 09 7d 0a 09 09 24 74 68 69 73 2d 3e 72 65 63 75 72 73 69 76 65 44 65 6c 65 74 65 28 | .}...}...$this->recursiveDelete( |
8e860 | 24 74 68 69 73 2d 3e 62 61 73 65 44 69 72 20 2e 20 27 2f 2e 2e 2f 74 68 65 6d 65 73 2f 65 78 61 | $this->baseDir...'/../themes/exa |
8e880 | 6d 70 6c 65 2f 27 29 3b 0a 0a 09 09 2f 2f 20 44 65 6c 65 74 65 20 74 68 65 20 72 65 73 74 0a 09 | mple/');....//.Delete.the.rest.. |
8e8a0 | 09 24 65 78 63 6c 75 64 65 64 45 6c 65 6d 65 6e 74 73 20 3d 20 5b 0a 09 09 09 27 2e 77 65 6c 6c | .$excludedElements.=.[....'.well |
8e8c0 | 2d 6b 6e 6f 77 6e 27 2c 0a 09 09 09 27 64 61 74 61 27 2c 0a 09 09 09 27 69 6e 64 65 78 2e 70 68 | -known',....'data',....'index.ph |
8e8e0 | 70 27 2c 0a 09 09 09 27 73 74 61 74 75 73 2e 70 68 70 27 2c 0a 09 09 09 27 72 65 6d 6f 74 65 2e | p',....'status.php',....'remote. |
8e900 | 70 68 70 27 2c 0a 09 09 09 27 70 75 62 6c 69 63 2e 70 68 70 27 2c 0a 09 09 09 27 6f 63 73 2f 76 | php',....'public.php',....'ocs/v |
8e920 | 31 2e 70 68 70 27 2c 0a 09 09 09 27 6f 63 73 2f 76 32 2e 70 68 70 27 2c 0a 09 09 09 27 63 6f 6e | 1.php',....'ocs/v2.php',....'con |
8e940 | 66 69 67 27 2c 0a 09 09 09 27 74 68 65 6d 65 73 27 2c 0a 09 09 09 27 61 70 70 73 27 2c 0a 09 09 | fig',....'themes',....'apps',... |
8e960 | 09 27 75 70 64 61 74 65 72 27 2c 0a 09 09 5d 3b 0a 09 09 24 65 78 63 6c 75 64 65 64 45 6c 65 6d | .'updater',...];...$excludedElem |
8e980 | 65 6e 74 73 20 3d 20 61 72 72 61 79 5f 6d 65 72 67 65 28 24 65 78 63 6c 75 64 65 64 45 6c 65 6d | ents.=.array_merge($excludedElem |
8e9a0 | 65 6e 74 73 2c 20 24 74 68 69 73 2d 3e 67 65 74 41 70 70 44 69 72 65 63 74 6f 72 69 65 73 28 29 | ents,.$this->getAppDirectories() |
8e9c0 | 29 3b 0a 09 09 2f 2a 2a 0a 09 09 20 2a 20 40 76 61 72 20 73 74 72 69 6e 67 20 24 70 61 74 68 0a | );.../**....*.@var.string.$path. |
8e9e0 | 09 09 20 2a 20 40 76 61 72 20 5c 53 70 6c 46 69 6c 65 49 6e 66 6f 20 24 66 69 6c 65 49 6e 66 6f | ...*.@var.\SplFileInfo.$fileInfo |
8ea00 | 0a 09 09 20 2a 2f 0a 09 09 66 6f 72 65 61 63 68 20 28 24 74 68 69 73 2d 3e 67 65 74 52 65 63 75 | ....*/...foreach.($this->getRecu |
8ea20 | 72 73 69 76 65 44 69 72 65 63 74 6f 72 79 49 74 65 72 61 74 6f 72 28 29 20 61 73 20 24 70 61 74 | rsiveDirectoryIterator().as.$pat |
8ea40 | 68 20 3d 3e 20 24 66 69 6c 65 49 6e 66 6f 29 20 7b 0a 09 09 09 24 63 75 72 72 65 6e 74 44 69 72 | h.=>.$fileInfo).{....$currentDir |
8ea60 | 20 3d 20 24 74 68 69 73 2d 3e 62 61 73 65 44 69 72 20 2e 20 27 2f 2e 2e 2f 27 3b 0a 09 09 09 24 | .=.$this->baseDir...'/../';....$ |
8ea80 | 66 69 6c 65 4e 61 6d 65 20 3d 20 65 78 70 6c 6f 64 65 28 24 63 75 72 72 65 6e 74 44 69 72 2c 20 | fileName.=.explode($currentDir,. |
8eaa0 | 24 70 61 74 68 29 5b 31 5d 3b 0a 09 09 09 24 66 6f 6c 64 65 72 53 74 72 75 63 74 75 72 65 20 3d | $path)[1];....$folderStructure.= |
8eac0 | 20 65 78 70 6c 6f 64 65 28 27 2f 27 2c 20 24 66 69 6c 65 4e 61 6d 65 2c 20 2d 31 29 3b 0a 09 09 | .explode('/',.$fileName,.-1);... |
8eae0 | 09 2f 2f 20 45 78 63 6c 75 64 65 20 74 68 65 20 65 78 63 6c 75 73 69 6f 6e 73 0a 09 09 09 69 66 | .//.Exclude.the.exclusions....if |
8eb00 | 28 69 73 73 65 74 28 24 66 6f 6c 64 65 72 53 74 72 75 63 74 75 72 65 5b 30 5d 29 29 20 7b 0a 09 | (isset($folderStructure[0])).{.. |
8eb20 | 09 09 09 69 66 28 61 72 72 61 79 5f 73 65 61 72 63 68 28 24 66 6f 6c 64 65 72 53 74 72 75 63 74 | ...if(array_search($folderStruct |
8eb40 | 75 72 65 5b 30 5d 2c 20 24 65 78 63 6c 75 64 65 64 45 6c 65 6d 65 6e 74 73 29 20 21 3d 3d 20 66 | ure[0],.$excludedElements).!==.f |
8eb60 | 61 6c 73 65 29 20 7b 0a 09 09 09 09 09 63 6f 6e 74 69 6e 75 65 3b 0a 09 09 09 09 7d 0a 09 09 09 | alse).{......continue;.....}.... |
8eb80 | 7d 20 65 6c 73 65 20 7b 0a 09 09 09 09 69 66 28 61 72 72 61 79 5f 73 65 61 72 63 68 28 24 66 69 | }.else.{.....if(array_search($fi |
8eba0 | 6c 65 4e 61 6d 65 2c 20 24 65 78 63 6c 75 64 65 64 45 6c 65 6d 65 6e 74 73 29 20 21 3d 3d 20 66 | leName,.$excludedElements).!==.f |
8ebc0 | 61 6c 73 65 29 20 7b 0a 09 09 09 09 09 63 6f 6e 74 69 6e 75 65 3b 0a 09 09 09 09 7d 0a 09 09 09 | alse).{......continue;.....}.... |
8ebe0 | 7d 0a 09 09 09 69 66 28 24 66 69 6c 65 49 6e 66 6f 2d 3e 69 73 46 69 6c 65 28 29 20 7c 7c 20 24 | }....if($fileInfo->isFile().||.$ |
8ec00 | 66 69 6c 65 49 6e 66 6f 2d 3e 69 73 4c 69 6e 6b 28 29 29 20 7b 0a 09 09 09 09 24 73 74 61 74 65 | fileInfo->isLink()).{.....$state |
8ec20 | 20 3d 20 75 6e 6c 69 6e 6b 28 24 70 61 74 68 29 3b 0a 09 09 09 09 69 66 28 24 73 74 61 74 65 20 | .=.unlink($path);.....if($state. |
8ec40 | 3d 3d 3d 20 66 61 6c 73 65 29 20 7b 0a 09 09 09 09 09 74 68 72 6f 77 20 6e 65 77 20 5c 45 78 63 | ===.false).{......throw.new.\Exc |
8ec60 | 65 70 74 69 6f 6e 28 27 43 6f 75 6c 64 20 6e 6f 74 20 75 6e 6c 69 6e 6b 3a 20 27 2e 24 70 61 74 | eption('Could.not.unlink:.'.$pat |
8ec80 | 68 29 3b 0a 09 09 09 09 7d 0a 09 09 09 7d 20 65 6c 73 65 69 66 28 24 66 69 6c 65 49 6e 66 6f 2d | h);.....}....}.elseif($fileInfo- |
8eca0 | 3e 69 73 44 69 72 28 29 29 20 7b 0a 09 09 09 09 24 73 74 61 74 65 20 3d 20 72 6d 64 69 72 28 24 | >isDir()).{.....$state.=.rmdir($ |
8ecc0 | 70 61 74 68 29 3b 0a 09 09 09 09 69 66 28 24 73 74 61 74 65 20 3d 3d 3d 20 66 61 6c 73 65 29 20 | path);.....if($state.===.false). |
8ece0 | 7b 0a 09 09 09 09 09 74 68 72 6f 77 20 6e 65 77 20 5c 45 78 63 65 70 74 69 6f 6e 28 27 43 6f 75 | {......throw.new.\Exception('Cou |
8ed00 | 6c 64 20 6e 6f 74 20 72 6d 64 69 72 3a 20 27 2e 24 70 61 74 68 29 3b 0a 09 09 09 09 7d 0a 09 09 | ld.not.rmdir:.'.$path);.....}... |
8ed20 | 09 7d 0a 09 09 7d 0a 0a 09 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 5b 69 6e 66 | .}...}....$this->silentLog('[inf |
8ed40 | 6f 5d 20 65 6e 64 20 6f 66 20 64 65 6c 65 74 65 4f 6c 64 46 69 6c 65 73 28 29 27 29 3b 0a 09 7d | o].end.of.deleteOldFiles()');..} |
8ed60 | 0a 0a 09 2f 2a 2a 0a 09 20 2a 20 4d 6f 76 65 73 20 74 68 65 20 73 70 65 63 69 66 69 65 64 20 66 | .../**...*.Moves.the.specified.f |
8ed80 | 69 6c 65 64 20 65 78 63 65 70 74 20 74 68 65 20 65 78 63 6c 75 64 65 64 20 65 6c 65 6d 65 6e 74 | iled.except.the.excluded.element |
8eda0 | 73 20 74 6f 20 74 68 65 20 63 6f 72 72 65 63 74 20 70 6f 73 69 74 69 6f 6e 0a 09 20 2a 0a 09 20 | s.to.the.correct.position...*... |
8edc0 | 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 64 61 74 61 4c 6f 63 61 74 69 6f 6e 0a 09 20 | *.@param.string.$dataLocation... |
8ede0 | 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 20 24 65 78 63 6c 75 64 65 64 45 6c 65 6d 65 6e 74 73 | *.@param.array.$excludedElements |
8ee00 | 0a 09 20 2a 20 40 74 68 72 6f 77 73 20 5c 45 78 63 65 70 74 69 6f 6e 0a 09 20 2a 2f 0a 09 70 72 | ...*.@throws.\Exception...*/..pr |
8ee20 | 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 6d 6f 76 65 57 69 74 68 45 78 63 6c 75 73 69 6f 6e | ivate.function.moveWithExclusion |
8ee40 | 73 28 24 64 61 74 61 4c 6f 63 61 74 69 6f 6e 2c 20 61 72 72 61 79 20 24 65 78 63 6c 75 64 65 64 | s($dataLocation,.array.$excluded |
8ee60 | 45 6c 65 6d 65 6e 74 73 29 20 7b 0a 09 09 2f 2a 2a 0a 09 09 20 2a 20 40 76 61 72 20 5c 53 70 6c | Elements).{.../**....*.@var.\Spl |
8ee80 | 46 69 6c 65 49 6e 66 6f 20 24 66 69 6c 65 49 6e 66 6f 0a 09 09 20 2a 2f 0a 09 09 66 6f 72 65 61 | FileInfo.$fileInfo....*/...forea |
8eea0 | 63 68 20 28 24 74 68 69 73 2d 3e 67 65 74 52 65 63 75 72 73 69 76 65 44 69 72 65 63 74 6f 72 79 | ch.($this->getRecursiveDirectory |
8eec0 | 49 74 65 72 61 74 6f 72 28 24 64 61 74 61 4c 6f 63 61 74 69 6f 6e 29 20 61 73 20 24 70 61 74 68 | Iterator($dataLocation).as.$path |
8eee0 | 20 3d 3e 20 24 66 69 6c 65 49 6e 66 6f 29 20 7b 0a 09 09 09 24 66 69 6c 65 4e 61 6d 65 20 3d 20 | .=>.$fileInfo).{....$fileName.=. |
8ef00 | 65 78 70 6c 6f 64 65 28 24 64 61 74 61 4c 6f 63 61 74 69 6f 6e 2c 20 24 70 61 74 68 29 5b 31 5d | explode($dataLocation,.$path)[1] |
8ef20 | 3b 0a 09 09 09 24 66 6f 6c 64 65 72 53 74 72 75 63 74 75 72 65 20 3d 20 65 78 70 6c 6f 64 65 28 | ;....$folderStructure.=.explode( |
8ef40 | 27 2f 27 2c 20 24 66 69 6c 65 4e 61 6d 65 2c 20 2d 31 29 3b 0a 0a 09 09 09 2f 2f 20 45 78 63 6c | '/',.$fileName,.-1);.....//.Excl |
8ef60 | 75 64 65 20 74 68 65 20 65 78 63 6c 75 73 69 6f 6e 73 0a 09 09 09 69 66 20 28 69 73 73 65 74 28 | ude.the.exclusions....if.(isset( |
8ef80 | 24 66 6f 6c 64 65 72 53 74 72 75 63 74 75 72 65 5b 30 5d 29 29 20 7b 0a 09 09 09 09 69 66 20 28 | $folderStructure[0])).{.....if.( |
8efa0 | 61 72 72 61 79 5f 73 65 61 72 63 68 28 24 66 6f 6c 64 65 72 53 74 72 75 63 74 75 72 65 5b 30 5d | array_search($folderStructure[0] |
8efc0 | 2c 20 24 65 78 63 6c 75 64 65 64 45 6c 65 6d 65 6e 74 73 29 20 21 3d 3d 20 66 61 6c 73 65 29 20 | ,.$excludedElements).!==.false). |
8efe0 | 7b 0a 09 09 09 09 09 63 6f 6e 74 69 6e 75 65 3b 0a 09 09 09 09 7d 0a 09 09 09 7d 20 65 6c 73 65 | {......continue;.....}....}.else |
8f000 | 20 7b 0a 09 09 09 09 69 66 20 28 61 72 72 61 79 5f 73 65 61 72 63 68 28 24 66 69 6c 65 4e 61 6d | .{.....if.(array_search($fileNam |
8f020 | 65 2c 20 24 65 78 63 6c 75 64 65 64 45 6c 65 6d 65 6e 74 73 29 20 21 3d 3d 20 66 61 6c 73 65 29 | e,.$excludedElements).!==.false) |
8f040 | 20 7b 0a 09 09 09 09 09 63 6f 6e 74 69 6e 75 65 3b 0a 09 09 09 09 7d 0a 09 09 09 7d 0a 0a 09 09 | .{......continue;.....}....}.... |
8f060 | 09 69 66 28 24 66 69 6c 65 49 6e 66 6f 2d 3e 69 73 46 69 6c 65 28 29 29 20 7b 0a 09 09 09 09 69 | .if($fileInfo->isFile()).{.....i |
8f080 | 66 28 21 66 69 6c 65 5f 65 78 69 73 74 73 28 24 74 68 69 73 2d 3e 62 61 73 65 44 69 72 20 2e 20 | f(!file_exists($this->baseDir... |
8f0a0 | 27 2f 2e 2e 2f 27 20 2e 20 64 69 72 6e 61 6d 65 28 24 66 69 6c 65 4e 61 6d 65 29 29 29 20 7b 0a | '/../'...dirname($fileName))).{. |
8f0c0 | 09 09 09 09 09 24 73 74 61 74 65 20 3d 20 6d 6b 64 69 72 28 24 74 68 69 73 2d 3e 62 61 73 65 44 | .....$state.=.mkdir($this->baseD |
8f0e0 | 69 72 20 2e 20 27 2f 2e 2e 2f 27 20 2e 20 64 69 72 6e 61 6d 65 28 24 66 69 6c 65 4e 61 6d 65 29 | ir...'/../'...dirname($fileName) |
8f100 | 2c 20 30 37 35 35 2c 20 74 72 75 65 29 3b 0a 09 09 09 09 09 69 66 28 24 73 74 61 74 65 20 3d 3d | ,.0755,.true);......if($state.== |
8f120 | 3d 20 66 61 6c 73 65 29 20 7b 0a 09 09 09 09 09 09 74 68 72 6f 77 20 6e 65 77 20 5c 45 78 63 65 | =.false).{.......throw.new.\Exce |
8f140 | 70 74 69 6f 6e 28 27 43 6f 75 6c 64 20 6e 6f 74 20 6d 6b 64 69 72 20 27 20 2e 20 24 74 68 69 73 | ption('Could.not.mkdir.'...$this |
8f160 | 2d 3e 62 61 73 65 44 69 72 20 20 2e 20 27 2f 2e 2e 2f 27 20 2e 20 64 69 72 6e 61 6d 65 28 24 66 | ->baseDir....'/../'...dirname($f |
8f180 | 69 6c 65 4e 61 6d 65 29 29 3b 0a 09 09 09 09 09 7d 0a 09 09 09 09 7d 0a 09 09 09 09 24 73 74 61 | ileName));......}.....}.....$sta |
8f1a0 | 74 65 20 3d 20 72 65 6e 61 6d 65 28 24 70 61 74 68 2c 20 24 74 68 69 73 2d 3e 62 61 73 65 44 69 | te.=.rename($path,.$this->baseDi |
8f1c0 | 72 20 20 2e 20 27 2f 2e 2e 2f 27 20 2e 20 24 66 69 6c 65 4e 61 6d 65 29 3b 0a 09 09 09 09 69 66 | r....'/../'...$fileName);.....if |
8f1e0 | 28 24 73 74 61 74 65 20 3d 3d 3d 20 66 61 6c 73 65 29 20 7b 0a 09 09 09 09 09 74 68 72 6f 77 20 | ($state.===.false).{......throw. |
8f200 | 6e 65 77 20 5c 45 78 63 65 70 74 69 6f 6e 28 0a 09 09 09 09 09 09 73 70 72 69 6e 74 66 28 0a 09 | new.\Exception(.......sprintf(.. |
8f220 | 09 09 09 09 09 09 27 43 6f 75 6c 64 20 6e 6f 74 20 72 65 6e 61 6d 65 20 25 73 20 74 6f 20 25 73 | ......'Could.not.rename.%s.to.%s |
8f240 | 27 2c 0a 09 09 09 09 09 09 09 24 70 61 74 68 2c 0a 09 09 09 09 09 09 09 24 74 68 69 73 2d 3e 62 | ',........$path,........$this->b |
8f260 | 61 73 65 44 69 72 20 2e 20 27 2f 2e 2e 2f 27 20 2e 20 24 66 69 6c 65 4e 61 6d 65 0a 09 09 09 09 | aseDir...'/../'...$fileName..... |
8f280 | 09 09 29 0a 09 09 09 09 09 29 3b 0a 09 09 09 09 7d 0a 09 09 09 7d 0a 09 09 09 69 66 28 24 66 69 | ..)......);.....}....}....if($fi |
8f2a0 | 6c 65 49 6e 66 6f 2d 3e 69 73 44 69 72 28 29 29 20 7b 0a 09 09 09 09 24 73 74 61 74 65 20 3d 20 | leInfo->isDir()).{.....$state.=. |
8f2c0 | 72 6d 64 69 72 28 24 70 61 74 68 29 3b 0a 09 09 09 09 69 66 28 24 73 74 61 74 65 20 3d 3d 3d 20 | rmdir($path);.....if($state.===. |
8f2e0 | 66 61 6c 73 65 29 20 7b 0a 09 09 09 09 09 74 68 72 6f 77 20 6e 65 77 20 5c 45 78 63 65 70 74 69 | false).{......throw.new.\Excepti |
8f300 | 6f 6e 28 27 43 6f 75 6c 64 20 6e 6f 74 20 72 6d 64 69 72 20 27 20 2e 20 24 70 61 74 68 29 3b 0a | on('Could.not.rmdir.'...$path);. |
8f320 | 09 09 09 09 7d 0a 09 09 09 7d 0a 09 09 7d 0a 09 7d 0a 0a 09 2f 2a 2a 0a 09 20 2a 20 4d 6f 76 65 | ....}....}...}..}.../**...*.Move |
8f340 | 73 20 74 68 65 20 6e 65 77 6c 79 20 64 6f 77 6e 6c 6f 61 64 65 64 20 66 69 6c 65 73 20 69 6e 74 | s.the.newly.downloaded.files.int |
8f360 | 6f 20 70 6c 61 63 65 0a 09 20 2a 0a 09 20 2a 20 40 74 68 72 6f 77 73 20 5c 45 78 63 65 70 74 69 | o.place...*...*.@throws.\Excepti |
8f380 | 6f 6e 0a 09 20 2a 2f 0a 09 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 6d 6f 76 65 4e 65 77 | on...*/..public.function.moveNew |
8f3a0 | 56 65 72 73 69 6f 6e 49 6e 50 6c 61 63 65 28 29 20 7b 0a 09 09 24 74 68 69 73 2d 3e 73 69 6c 65 | VersionInPlace().{...$this->sile |
8f3c0 | 6e 74 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 6d 6f 76 65 4e 65 77 56 65 72 73 69 6f 6e 49 6e 50 6c | ntLog('[info].moveNewVersionInPl |
8f3e0 | 61 63 65 28 29 27 29 3b 0a 0a 09 09 2f 2f 20 52 65 6e 61 6d 65 20 65 76 65 72 79 74 68 69 6e 67 | ace()');....//.Rename.everything |
8f400 | 20 65 6c 73 65 20 65 78 63 65 70 74 20 74 68 65 20 65 6e 74 72 79 20 61 6e 64 20 75 70 64 61 74 | .else.except.the.entry.and.updat |
8f420 | 65 72 20 66 69 6c 65 73 0a 09 09 24 65 78 63 6c 75 64 65 64 45 6c 65 6d 65 6e 74 73 20 3d 20 5b | er.files...$excludedElements.=.[ |
8f440 | 0a 09 09 09 27 75 70 64 61 74 65 72 27 2c 0a 09 09 09 27 69 6e 64 65 78 2e 70 68 70 27 2c 0a 09 | ....'updater',....'index.php',.. |
8f460 | 09 09 27 73 74 61 74 75 73 2e 70 68 70 27 2c 0a 09 09 09 27 72 65 6d 6f 74 65 2e 70 68 70 27 2c | ..'status.php',....'remote.php', |
8f480 | 0a 09 09 09 27 70 75 62 6c 69 63 2e 70 68 70 27 2c 0a 09 09 09 27 6f 63 73 2f 76 31 2e 70 68 70 | ....'public.php',....'ocs/v1.php |
8f4a0 | 27 2c 0a 09 09 09 27 6f 63 73 2f 76 32 2e 70 68 70 27 2c 0a 09 09 5d 3b 0a 09 09 24 73 74 6f 72 | ',....'ocs/v2.php',...];...$stor |
8f4c0 | 61 67 65 4c 6f 63 61 74 69 6f 6e 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 44 61 74 61 44 69 72 65 | ageLocation.=.$this->getDataDire |
8f4e0 | 63 74 6f 72 79 4c 6f 63 61 74 69 6f 6e 28 29 20 2e 20 27 2f 75 70 64 61 74 65 72 2d 27 2e 24 74 | ctoryLocation()...'/updater-'.$t |
8f500 | 68 69 73 2d 3e 67 65 74 43 6f 6e 66 69 67 4f 70 74 69 6f 6e 28 27 69 6e 73 74 61 6e 63 65 69 64 | his->getConfigOption('instanceid |
8f520 | 27 29 20 2e 20 27 2f 64 6f 77 6e 6c 6f 61 64 73 2f 6e 65 78 74 63 6c 6f 75 64 2f 27 3b 0a 09 09 | ')...'/downloads/nextcloud/';... |
8f540 | 24 74 68 69 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 73 74 6f 72 61 67 65 | $this->silentLog('[info].storage |
8f560 | 20 6c 6f 63 61 74 69 6f 6e 3a 20 27 20 2e 20 24 73 74 6f 72 61 67 65 4c 6f 63 61 74 69 6f 6e 29 | .location:.'...$storageLocation) |
8f580 | 3b 0a 09 09 24 74 68 69 73 2d 3e 6d 6f 76 65 57 69 74 68 45 78 63 6c 75 73 69 6f 6e 73 28 24 73 | ;...$this->moveWithExclusions($s |
8f5a0 | 74 6f 72 61 67 65 4c 6f 63 61 74 69 6f 6e 2c 20 24 65 78 63 6c 75 64 65 64 45 6c 65 6d 65 6e 74 | torageLocation,.$excludedElement |
8f5c0 | 73 29 3b 0a 0a 09 09 2f 2f 20 52 65 6e 61 6d 65 20 65 76 65 72 79 74 68 69 6e 67 20 65 78 63 65 | s);....//.Rename.everything.exce |
8f5e0 | 70 74 20 74 68 65 20 75 70 64 61 74 65 72 20 66 69 6c 65 73 0a 09 09 24 74 68 69 73 2d 3e 6d 6f | pt.the.updater.files...$this->mo |
8f600 | 76 65 57 69 74 68 45 78 63 6c 75 73 69 6f 6e 73 28 24 73 74 6f 72 61 67 65 4c 6f 63 61 74 69 6f | veWithExclusions($storageLocatio |
8f620 | 6e 2c 20 5b 27 75 70 64 61 74 65 72 27 5d 29 3b 0a 0a 09 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e | n,.['updater']);....$this->silen |
8f640 | 74 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 65 6e 64 20 6f 66 20 6d 6f 76 65 4e 65 77 56 65 72 73 69 | tLog('[info].end.of.moveNewVersi |
8f660 | 6f 6e 49 6e 50 6c 61 63 65 28 29 27 29 3b 0a 09 7d 0a 0a 09 2f 2a 2a 0a 09 20 2a 20 46 69 6e 61 | onInPlace()');..}.../**...*.Fina |
8f680 | 6c 69 7a 65 20 61 6e 64 20 63 6c 65 61 6e 75 70 20 74 68 65 20 75 70 64 61 74 65 72 20 62 79 20 | lize.and.cleanup.the.updater.by. |
8f6a0 | 66 69 6e 61 6c 6c 79 20 72 65 70 6c 61 63 69 6e 67 20 74 68 65 20 75 70 64 61 74 65 72 20 73 63 | finally.replacing.the.updater.sc |
8f6c0 | 72 69 70 74 0a 09 20 2a 2f 0a 09 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 66 69 6e 61 6c | ript...*/..public.function.final |
8f6e0 | 69 7a 65 28 29 20 7b 0a 09 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 5b 69 6e 66 | ize().{...$this->silentLog('[inf |
8f700 | 6f 5d 20 66 69 6e 61 6c 69 7a 65 28 29 27 29 3b 0a 0a 09 09 24 73 74 6f 72 61 67 65 4c 6f 63 61 | o].finalize()');....$storageLoca |
8f720 | 74 69 6f 6e 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 44 61 74 61 44 69 72 65 63 74 6f 72 79 4c 6f | tion.=.$this->getDataDirectoryLo |
8f740 | 63 61 74 69 6f 6e 28 29 20 2e 20 27 2f 75 70 64 61 74 65 72 2d 27 2e 24 74 68 69 73 2d 3e 67 65 | cation()...'/updater-'.$this->ge |
8f760 | 74 43 6f 6e 66 69 67 4f 70 74 69 6f 6e 28 27 69 6e 73 74 61 6e 63 65 69 64 27 29 20 2e 20 27 2f | tConfigOption('instanceid')...'/ |
8f780 | 64 6f 77 6e 6c 6f 61 64 73 2f 6e 65 78 74 63 6c 6f 75 64 2f 27 3b 0a 09 09 24 74 68 69 73 2d 3e | downloads/nextcloud/';...$this-> |
8f7a0 | 73 69 6c 65 6e 74 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 73 74 6f 72 61 67 65 20 6c 6f 63 61 74 69 | silentLog('[info].storage.locati |
8f7c0 | 6f 6e 3a 20 27 20 2e 20 24 73 74 6f 72 61 67 65 4c 6f 63 61 74 69 6f 6e 29 3b 0a 09 09 24 74 68 | on:.'...$storageLocation);...$th |
8f7e0 | 69 73 2d 3e 6d 6f 76 65 57 69 74 68 45 78 63 6c 75 73 69 6f 6e 73 28 24 73 74 6f 72 61 67 65 4c | is->moveWithExclusions($storageL |
8f800 | 6f 63 61 74 69 6f 6e 2c 20 5b 5d 29 3b 0a 09 09 24 73 74 61 74 65 20 3d 20 72 6d 64 69 72 28 24 | ocation,.[]);...$state.=.rmdir($ |
8f820 | 73 74 6f 72 61 67 65 4c 6f 63 61 74 69 6f 6e 29 3b 0a 09 09 69 66 28 24 73 74 61 74 65 20 3d 3d | storageLocation);...if($state.== |
8f840 | 3d 20 66 61 6c 73 65 29 20 7b 0a 09 09 09 74 68 72 6f 77 20 6e 65 77 20 5c 45 78 63 65 70 74 69 | =.false).{....throw.new.\Excepti |
8f860 | 6f 6e 28 27 43 6f 75 6c 64 20 6e 6f 74 20 72 6d 64 69 72 20 24 73 74 6f 72 61 67 65 6c 6f 63 61 | on('Could.not.rmdir.$storageloca |
8f880 | 74 69 6f 6e 27 29 3b 0a 09 09 7d 0a 09 09 24 73 74 61 74 65 20 3d 20 75 6e 6c 69 6e 6b 28 24 74 | tion');...}...$state.=.unlink($t |
8f8a0 | 68 69 73 2d 3e 67 65 74 44 61 74 61 44 69 72 65 63 74 6f 72 79 4c 6f 63 61 74 69 6f 6e 28 29 20 | his->getDataDirectoryLocation(). |
8f8c0 | 2e 20 27 2f 75 70 64 61 74 65 72 2d 27 2e 24 74 68 69 73 2d 3e 67 65 74 43 6f 6e 66 69 67 4f 70 | ..'/updater-'.$this->getConfigOp |
8f8e0 | 74 69 6f 6e 28 27 69 6e 73 74 61 6e 63 65 69 64 27 29 20 2e 20 27 2f 2e 73 74 65 70 27 29 3b 0a | tion('instanceid')...'/.step');. |
8f900 | 09 09 69 66 28 24 73 74 61 74 65 20 3d 3d 3d 20 66 61 6c 73 65 29 20 7b 0a 09 09 09 74 68 72 6f | ..if($state.===.false).{....thro |
8f920 | 77 20 6e 65 77 20 5c 45 78 63 65 70 74 69 6f 6e 28 27 43 6f 75 6c 64 20 6e 6f 74 20 72 6d 64 69 | w.new.\Exception('Could.not.rmdi |
8f940 | 72 20 2e 73 74 65 70 27 29 3b 0a 09 09 7d 0a 0a 09 09 69 66 20 28 66 75 6e 63 74 69 6f 6e 5f 65 | r..step');...}....if.(function_e |
8f960 | 78 69 73 74 73 28 27 6f 70 63 61 63 68 65 5f 72 65 73 65 74 27 29 29 20 7b 0a 09 09 09 24 74 68 | xists('opcache_reset')).{....$th |
8f980 | 69 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 63 61 6c 6c 20 6f 70 63 61 63 | is->silentLog('[info].call.opcac |
8f9a0 | 68 65 5f 72 65 73 65 74 28 29 27 29 3b 0a 09 09 09 6f 70 63 61 63 68 65 5f 72 65 73 65 74 28 29 | he_reset()');....opcache_reset() |
8f9c0 | 3b 0a 09 09 7d 0a 0a 09 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 5b 69 6e 66 6f | ;...}....$this->silentLog('[info |
8f9e0 | 5d 20 65 6e 64 20 6f 66 20 66 69 6e 61 6c 69 7a 65 28 29 27 29 3b 0a 09 7d 0a 0a 09 2f 2a 2a 0a | ].end.of.finalize()');..}.../**. |
8fa00 | 09 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 73 74 61 74 65 0a 09 20 2a 20 40 70 61 | ..*.@param.string.$state...*.@pa |
8fa20 | 72 61 6d 20 69 6e 74 20 24 73 74 65 70 0a 09 20 2a 20 40 74 68 72 6f 77 73 20 5c 45 78 63 65 70 | ram.int.$step...*.@throws.\Excep |
8fa40 | 74 69 6f 6e 0a 09 20 2a 2f 0a 09 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 77 72 69 74 | tion...*/..private.function.writ |
8fa60 | 65 53 74 65 70 28 24 73 74 61 74 65 2c 20 24 73 74 65 70 29 20 7b 0a 09 09 24 75 70 64 61 74 65 | eStep($state,.$step).{...$update |
8fa80 | 72 44 69 72 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 44 61 74 61 44 69 72 65 63 74 6f 72 79 4c 6f | rDir.=.$this->getDataDirectoryLo |
8faa0 | 63 61 74 69 6f 6e 28 29 20 2e 20 27 2f 75 70 64 61 74 65 72 2d 27 2e 24 74 68 69 73 2d 3e 67 65 | cation()...'/updater-'.$this->ge |
8fac0 | 74 43 6f 6e 66 69 67 4f 70 74 69 6f 6e 28 27 69 6e 73 74 61 6e 63 65 69 64 27 29 3b 0a 09 09 69 | tConfigOption('instanceid');...i |
8fae0 | 66 28 21 66 69 6c 65 5f 65 78 69 73 74 73 28 24 75 70 64 61 74 65 72 44 69 72 20 2e 20 27 2f 2e | f(!file_exists($updaterDir...'/. |
8fb00 | 73 74 65 70 27 29 29 20 7b 0a 09 09 09 69 66 28 21 66 69 6c 65 5f 65 78 69 73 74 73 28 24 75 70 | step')).{....if(!file_exists($up |
8fb20 | 64 61 74 65 72 44 69 72 29 29 20 7b 0a 09 09 09 09 24 72 65 73 75 6c 74 20 3d 20 6d 6b 64 69 72 | daterDir)).{.....$result.=.mkdir |
8fb40 | 28 24 75 70 64 61 74 65 72 44 69 72 29 3b 0a 09 09 09 09 69 66 20 28 24 72 65 73 75 6c 74 20 3d | ($updaterDir);.....if.($result.= |
8fb60 | 3d 3d 20 66 61 6c 73 65 29 20 7b 0a 09 09 09 09 09 74 68 72 6f 77 20 6e 65 77 20 5c 45 78 63 65 | ==.false).{......throw.new.\Exce |
8fb80 | 70 74 69 6f 6e 28 27 43 6f 75 6c 64 20 6e 6f 74 20 63 72 65 61 74 65 20 24 75 70 64 61 74 65 72 | ption('Could.not.create.$updater |
8fba0 | 44 69 72 27 29 3b 0a 09 09 09 09 7d 0a 09 09 09 7d 0a 09 09 09 24 72 65 73 75 6c 74 20 3d 20 74 | Dir');.....}....}....$result.=.t |
8fbc0 | 6f 75 63 68 28 24 75 70 64 61 74 65 72 44 69 72 20 2e 20 27 2f 2e 73 74 65 70 27 29 3b 0a 09 09 | ouch($updaterDir...'/.step');... |
8fbe0 | 09 69 66 28 24 72 65 73 75 6c 74 20 3d 3d 3d 20 66 61 6c 73 65 29 20 7b 0a 09 09 09 09 74 68 72 | .if($result.===.false).{.....thr |
8fc00 | 6f 77 20 6e 65 77 20 5c 45 78 63 65 70 74 69 6f 6e 28 27 43 6f 75 6c 64 20 6e 6f 74 20 63 72 65 | ow.new.\Exception('Could.not.cre |
8fc20 | 61 74 65 20 2e 73 74 65 70 27 29 3b 0a 09 09 09 7d 0a 09 09 7d 0a 0a 09 09 24 72 65 73 75 6c 74 | ate..step');....}...}....$result |
8fc40 | 20 3d 20 66 69 6c 65 5f 70 75 74 5f 63 6f 6e 74 65 6e 74 73 28 24 75 70 64 61 74 65 72 44 69 72 | .=.file_put_contents($updaterDir |
8fc60 | 20 2e 20 27 2f 2e 73 74 65 70 27 2c 20 6a 73 6f 6e 5f 65 6e 63 6f 64 65 28 5b 27 73 74 61 74 65 | ...'/.step',.json_encode(['state |
8fc80 | 27 20 3d 3e 20 24 73 74 61 74 65 2c 20 27 73 74 65 70 27 20 3d 3e 20 24 73 74 65 70 5d 29 29 3b | '.=>.$state,.'step'.=>.$step])); |
8fca0 | 0a 09 09 69 66 28 24 72 65 73 75 6c 74 20 3d 3d 3d 20 66 61 6c 73 65 29 20 7b 0a 09 09 09 74 68 | ...if($result.===.false).{....th |
8fcc0 | 72 6f 77 20 6e 65 77 20 5c 45 78 63 65 70 74 69 6f 6e 28 27 43 6f 75 6c 64 20 6e 6f 74 20 77 72 | row.new.\Exception('Could.not.wr |
8fce0 | 69 74 65 20 74 6f 20 2e 73 74 65 70 27 29 3b 0a 09 09 7d 0a 09 7d 0a 0a 09 2f 2a 2a 0a 09 20 2a | ite.to..step');...}..}.../**...* |
8fd00 | 20 40 70 61 72 61 6d 20 69 6e 74 20 24 73 74 65 70 0a 09 20 2a 20 40 74 68 72 6f 77 73 20 5c 45 | .@param.int.$step...*.@throws.\E |
8fd20 | 78 63 65 70 74 69 6f 6e 0a 09 20 2a 2f 0a 09 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 | xception...*/..public.function.s |
8fd40 | 74 61 72 74 53 74 65 70 28 24 73 74 65 70 29 20 7b 0a 09 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e | tartStep($step).{...$this->silen |
8fd60 | 74 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 73 74 61 72 74 53 74 65 70 28 22 27 20 2e 20 24 73 74 65 | tLog('[info].startStep("'...$ste |
8fd80 | 70 20 2e 20 27 22 29 27 29 3b 0a 09 09 24 74 68 69 73 2d 3e 77 72 69 74 65 53 74 65 70 28 27 73 | p...'")');...$this->writeStep('s |
8fda0 | 74 61 72 74 27 2c 20 24 73 74 65 70 29 3b 0a 09 7d 0a 0a 09 2f 2a 2a 0a 09 20 2a 20 40 70 61 72 | tart',.$step);..}.../**...*.@par |
8fdc0 | 61 6d 20 69 6e 74 20 24 73 74 65 70 0a 09 20 2a 20 40 74 68 72 6f 77 73 20 5c 45 78 63 65 70 74 | am.int.$step...*.@throws.\Except |
8fde0 | 69 6f 6e 0a 09 20 2a 2f 0a 09 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 65 6e 64 53 74 65 | ion...*/..public.function.endSte |
8fe00 | 70 28 24 73 74 65 70 29 20 7b 0a 09 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 5b | p($step).{...$this->silentLog('[ |
8fe20 | 69 6e 66 6f 5d 20 65 6e 64 53 74 65 70 28 22 27 20 2e 20 24 73 74 65 70 20 2e 20 27 22 29 27 29 | info].endStep("'...$step...'")') |
8fe40 | 3b 0a 09 09 24 74 68 69 73 2d 3e 77 72 69 74 65 53 74 65 70 28 27 65 6e 64 27 2c 20 24 73 74 65 | ;...$this->writeStep('end',.$ste |
8fe60 | 70 29 3b 0a 09 7d 0a 0a 09 2f 2a 2a 0a 09 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 0a | p);..}.../**...*.@return.string. |
8fe80 | 09 20 2a 20 40 74 68 72 6f 77 73 20 5c 45 78 63 65 70 74 69 6f 6e 0a 09 20 2a 2f 0a 09 70 75 62 | ..*.@throws.\Exception...*/..pub |
8fea0 | 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 63 75 72 72 65 6e 74 53 74 65 70 28 29 20 7b 0a 09 09 24 | lic.function.currentStep().{...$ |
8fec0 | 74 68 69 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 63 75 72 72 65 6e 74 53 | this->silentLog('[info].currentS |
8fee0 | 74 65 70 28 29 27 29 3b 0a 0a 09 09 24 75 70 64 61 74 65 72 44 69 72 20 3d 20 24 74 68 69 73 2d | tep()');....$updaterDir.=.$this- |
8ff00 | 3e 67 65 74 44 61 74 61 44 69 72 65 63 74 6f 72 79 4c 6f 63 61 74 69 6f 6e 28 29 20 2e 20 27 2f | >getDataDirectoryLocation()...'/ |
8ff20 | 75 70 64 61 74 65 72 2d 27 2e 24 74 68 69 73 2d 3e 67 65 74 43 6f 6e 66 69 67 4f 70 74 69 6f 6e | updater-'.$this->getConfigOption |
8ff40 | 28 27 69 6e 73 74 61 6e 63 65 69 64 27 29 3b 0a 09 09 24 6a 73 6f 6e 44 61 74 61 20 3d 20 5b 5d | ('instanceid');...$jsonData.=.[] |
8ff60 | 3b 0a 09 09 69 66 28 66 69 6c 65 5f 65 78 69 73 74 73 28 24 75 70 64 61 74 65 72 44 69 72 2e 20 | ;...if(file_exists($updaterDir.. |
8ff80 | 27 2f 2e 73 74 65 70 27 29 29 20 7b 0a 09 09 09 24 73 74 61 74 65 20 3d 20 66 69 6c 65 5f 67 65 | '/.step')).{....$state.=.file_ge |
8ffa0 | 74 5f 63 6f 6e 74 65 6e 74 73 28 24 75 70 64 61 74 65 72 44 69 72 20 2e 20 27 2f 2e 73 74 65 70 | t_contents($updaterDir...'/.step |
8ffc0 | 27 29 3b 0a 09 09 09 69 66 20 28 24 73 74 61 74 65 20 3d 3d 3d 20 66 61 6c 73 65 29 20 7b 0a 09 | ');....if.($state.===.false).{.. |
8ffe0 | 09 09 09 74 68 72 6f 77 20 6e 65 77 20 5c 45 78 63 65 70 74 69 6f 6e 28 27 43 6f 75 6c 64 20 6e | ...throw.new.\Exception('Could.n |
90000 | 6f 74 20 72 65 61 64 20 66 72 6f 6d 20 2e 73 74 65 70 27 29 3b 0a 09 09 09 7d 0a 0a 09 09 09 24 | ot.read.from..step');....}.....$ |
90020 | 6a 73 6f 6e 44 61 74 61 20 3d 20 6a 73 6f 6e 5f 64 65 63 6f 64 65 28 24 73 74 61 74 65 2c 20 74 | jsonData.=.json_decode($state,.t |
90040 | 72 75 65 29 3b 0a 09 09 09 69 66 20 28 21 69 73 5f 61 72 72 61 79 28 24 6a 73 6f 6e 44 61 74 61 | rue);....if.(!is_array($jsonData |
90060 | 29 29 20 7b 0a 09 09 09 09 74 68 72 6f 77 20 6e 65 77 20 5c 45 78 63 65 70 74 69 6f 6e 28 27 43 | )).{.....throw.new.\Exception('C |
90080 | 61 6e 5c 27 74 20 64 65 63 6f 64 65 20 2e 73 74 65 70 20 4a 53 4f 4e 20 64 61 74 61 27 29 3b 0a | an\'t.decode..step.JSON.data');. |
900a0 | 09 09 09 7d 0a 09 09 7d 0a 09 09 72 65 74 75 72 6e 20 24 6a 73 6f 6e 44 61 74 61 3b 0a 09 7d 0a | ...}...}...return.$jsonData;..}. |
900c0 | 0a 09 2f 2a 2a 0a 09 20 2a 20 52 6f 6c 6c 62 61 63 6b 20 74 68 65 20 63 68 61 6e 67 65 73 20 69 | ../**...*.Rollback.the.changes.i |
900e0 | 66 20 24 73 74 65 70 20 68 61 73 20 66 61 69 6c 65 64 0a 09 20 2a 0a 09 20 2a 20 40 70 61 72 61 | f.$step.has.failed...*...*.@para |
90100 | 6d 20 69 6e 74 20 24 73 74 65 70 0a 09 20 2a 20 40 74 68 72 6f 77 73 20 5c 45 78 63 65 70 74 69 | m.int.$step...*.@throws.\Excepti |
90120 | 6f 6e 0a 09 20 2a 2f 0a 09 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 72 6f 6c 6c 62 61 63 | on...*/..public.function.rollbac |
90140 | 6b 43 68 61 6e 67 65 73 28 24 73 74 65 70 29 20 7b 0a 09 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e | kChanges($step).{...$this->silen |
90160 | 74 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 72 6f 6c 6c 62 61 63 6b 43 68 61 6e 67 65 73 28 22 27 20 | tLog('[info].rollbackChanges("'. |
90180 | 2e 20 24 73 74 65 70 20 2e 20 27 22 29 27 29 3b 0a 0a 09 09 24 75 70 64 61 74 65 72 44 69 72 20 | ..$step...'")');....$updaterDir. |
901a0 | 3d 20 24 74 68 69 73 2d 3e 67 65 74 44 61 74 61 44 69 72 65 63 74 6f 72 79 4c 6f 63 61 74 69 6f | =.$this->getDataDirectoryLocatio |
901c0 | 6e 28 29 20 2e 20 27 2f 75 70 64 61 74 65 72 2d 27 2e 24 74 68 69 73 2d 3e 67 65 74 43 6f 6e 66 | n()...'/updater-'.$this->getConf |
901e0 | 69 67 4f 70 74 69 6f 6e 28 27 69 6e 73 74 61 6e 63 65 69 64 27 29 3b 0a 09 09 69 66 28 66 69 6c | igOption('instanceid');...if(fil |
90200 | 65 5f 65 78 69 73 74 73 28 24 75 70 64 61 74 65 72 44 69 72 20 2e 20 27 2f 2e 73 74 65 70 27 29 | e_exists($updaterDir...'/.step') |
90220 | 29 20 7b 0a 09 09 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 | ).{....$this->silentLog('[info]. |
90240 | 75 6e 6c 69 6e 6b 20 2e 73 74 65 70 27 29 3b 0a 09 09 09 24 73 74 61 74 65 20 3d 20 75 6e 6c 69 | unlink..step');....$state.=.unli |
90260 | 6e 6b 28 24 75 70 64 61 74 65 72 44 69 72 20 2e 20 27 2f 2e 73 74 65 70 27 29 3b 0a 09 09 09 69 | nk($updaterDir...'/.step');....i |
90280 | 66 20 28 24 73 74 61 74 65 20 3d 3d 3d 20 66 61 6c 73 65 29 20 7b 0a 09 09 09 09 74 68 72 6f 77 | f.($state.===.false).{.....throw |
902a0 | 20 6e 65 77 20 5c 45 78 63 65 70 74 69 6f 6e 28 27 43 6f 75 6c 64 20 6e 6f 74 20 64 65 6c 65 74 | .new.\Exception('Could.not.delet |
902c0 | 65 20 2e 73 74 65 70 27 29 3b 0a 09 09 09 7d 0a 09 09 7d 0a 0a 09 09 69 66 28 24 73 74 65 70 20 | e..step');....}...}....if($step. |
902e0 | 3e 3d 20 37 29 20 7b 0a 09 09 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 5b 69 6e | >=.7).{....$this->silentLog('[in |
90300 | 66 6f 5d 20 72 6f 6c 6c 62 61 63 6b 43 68 61 6e 67 65 73 20 2d 20 73 74 65 70 20 3e 3d 20 37 27 | fo].rollbackChanges.-.step.>=.7' |
90320 | 29 3b 0a 09 09 09 2f 2f 20 54 4f 44 4f 3a 20 49 66 20 69 74 20 66 61 69 6c 73 20 61 66 74 65 72 | );....//.TODO:.If.it.fails.after |
90340 | 20 73 74 65 70 20 37 3a 20 52 6f 6c 6c 62 61 63 6b 0a 09 09 7d 0a 09 09 24 74 68 69 73 2d 3e 73 | .step.7:.Rollback...}...$this->s |
90360 | 69 6c 65 6e 74 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 65 6e 64 20 6f 66 20 20 72 6f 6c 6c 62 61 63 | ilentLog('[info].end.of..rollbac |
90380 | 6b 43 68 61 6e 67 65 73 28 29 27 29 3b 0a 09 7d 0a 0a 09 2f 2a 2a 0a 09 20 2a 20 4c 6f 67 73 20 | kChanges()');..}.../**...*.Logs. |
903a0 | 61 6e 20 65 78 63 65 70 74 69 6f 6e 20 77 69 74 68 20 63 75 72 72 65 6e 74 20 64 61 74 65 74 69 | an.exception.with.current.dateti |
903c0 | 6d 65 20 70 72 65 70 65 6e 64 65 64 20 74 6f 20 75 70 64 61 74 65 72 2e 6c 6f 67 0a 09 20 2a 0a | me.prepended.to.updater.log...*. |
903e0 | 09 20 2a 20 40 70 61 72 61 6d 20 5c 45 78 63 65 70 74 69 6f 6e 20 24 65 0a 09 20 2a 20 40 74 68 | ..*.@param.\Exception.$e...*.@th |
90400 | 72 6f 77 73 20 4c 6f 67 45 78 63 65 70 74 69 6f 6e 0a 09 20 2a 2f 0a 09 70 75 62 6c 69 63 20 66 | rows.LogException...*/..public.f |
90420 | 75 6e 63 74 69 6f 6e 20 6c 6f 67 45 78 63 65 70 74 69 6f 6e 28 5c 45 78 63 65 70 74 69 6f 6e 20 | unction.logException(\Exception. |
90440 | 24 65 29 20 7b 0a 09 09 24 6d 65 73 73 61 67 65 20 3d 20 27 5b 65 72 72 6f 72 5d 20 27 3b 0a 0a | $e).{...$message.=.'[error].';.. |
90460 | 09 09 24 6d 65 73 73 61 67 65 20 2e 3d 20 27 45 78 63 65 70 74 69 6f 6e 3a 20 27 20 2e 20 67 65 | ..$message..=.'Exception:.'...ge |
90480 | 74 5f 63 6c 61 73 73 28 24 65 29 20 2e 20 50 48 50 5f 45 4f 4c 3b 0a 09 09 24 6d 65 73 73 61 67 | t_class($e)...PHP_EOL;...$messag |
904a0 | 65 20 2e 3d 20 27 4d 65 73 73 61 67 65 3a 20 27 20 2e 20 24 65 2d 3e 67 65 74 4d 65 73 73 61 67 | e..=.'Message:.'...$e->getMessag |
904c0 | 65 28 29 20 2e 20 50 48 50 5f 45 4f 4c 3b 0a 09 09 24 6d 65 73 73 61 67 65 20 2e 3d 20 27 43 6f | e()...PHP_EOL;...$message..=.'Co |
904e0 | 64 65 3a 27 20 2e 20 24 65 2d 3e 67 65 74 43 6f 64 65 28 29 20 2e 20 50 48 50 5f 45 4f 4c 3b 0a | de:'...$e->getCode()...PHP_EOL;. |
90500 | 09 09 24 6d 65 73 73 61 67 65 20 2e 3d 20 27 54 72 61 63 65 3a 27 20 2e 20 50 48 50 5f 45 4f 4c | ..$message..=.'Trace:'...PHP_EOL |
90520 | 20 2e 20 24 65 2d 3e 67 65 74 54 72 61 63 65 41 73 53 74 72 69 6e 67 28 29 20 2e 20 50 48 50 5f | ...$e->getTraceAsString()...PHP_ |
90540 | 45 4f 4c 3b 0a 09 09 24 6d 65 73 73 61 67 65 20 2e 3d 20 27 46 69 6c 65 3a 27 20 2e 20 24 65 2d | EOL;...$message..=.'File:'...$e- |
90560 | 3e 67 65 74 46 69 6c 65 28 29 20 2e 20 50 48 50 5f 45 4f 4c 3b 0a 09 09 24 6d 65 73 73 61 67 65 | >getFile()...PHP_EOL;...$message |
90580 | 20 2e 3d 20 27 4c 69 6e 65 3a 27 20 2e 20 24 65 2d 3e 67 65 74 4c 69 6e 65 28 29 20 2e 20 50 48 | ..=.'Line:'...$e->getLine()...PH |
905a0 | 50 5f 45 4f 4c 3b 0a 09 09 69 66 28 24 65 20 69 6e 73 74 61 6e 63 65 6f 66 20 55 70 64 61 74 65 | P_EOL;...if($e.instanceof.Update |
905c0 | 45 78 63 65 70 74 69 6f 6e 29 20 7b 0a 09 09 09 24 6d 65 73 73 61 67 65 20 2e 3d 20 27 44 61 74 | Exception).{....$message..=.'Dat |
905e0 | 61 3a 27 20 2e 20 50 48 50 5f 45 4f 4c 20 2e 20 70 72 69 6e 74 5f 72 28 24 65 2d 3e 67 65 74 44 | a:'...PHP_EOL...print_r($e->getD |
90600 | 61 74 61 28 29 2c 20 74 72 75 65 29 20 2e 20 50 48 50 5f 45 4f 4c 3b 0a 09 09 7d 0a 09 09 24 74 | ata(),.true)...PHP_EOL;...}...$t |
90620 | 68 69 73 2d 3e 6c 6f 67 28 24 6d 65 73 73 61 67 65 29 3b 0a 09 7d 0a 0a 09 2f 2a 2a 0a 09 20 2a | his->log($message);..}.../**...* |
90640 | 20 4c 6f 67 73 20 61 20 6d 65 73 73 61 67 65 20 77 69 74 68 20 63 75 72 72 65 6e 74 20 64 61 74 | .Logs.a.message.with.current.dat |
90660 | 65 74 69 6d 65 20 70 72 65 70 65 6e 64 65 64 20 74 6f 20 75 70 64 61 74 65 72 2e 6c 6f 67 0a 09 | etime.prepended.to.updater.log.. |
90680 | 20 2a 0a 09 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6d 65 73 73 61 67 65 0a 09 20 | .*...*.@param.string.$message... |
906a0 | 2a 20 40 74 68 72 6f 77 73 20 4c 6f 67 45 78 63 65 70 74 69 6f 6e 0a 09 20 2a 2f 0a 09 70 75 62 | *.@throws.LogException...*/..pub |
906c0 | 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 6c 6f 67 28 24 6d 65 73 73 61 67 65 29 20 7b 0a 09 09 24 | lic.function.log($message).{...$ |
906e0 | 75 70 64 61 74 65 72 4c 6f 67 50 61 74 68 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 44 61 74 61 44 | updaterLogPath.=.$this->getDataD |
90700 | 69 72 65 63 74 6f 72 79 4c 6f 63 61 74 69 6f 6e 28 29 20 2e 20 27 2f 75 70 64 61 74 65 72 2e 6c | irectoryLocation()...'/updater.l |
90720 | 6f 67 27 3b 0a 0a 09 09 24 66 68 20 3d 20 66 6f 70 65 6e 28 24 75 70 64 61 74 65 72 4c 6f 67 50 | og';....$fh.=.fopen($updaterLogP |
90740 | 61 74 68 2c 20 27 61 27 29 3b 0a 09 09 69 66 28 24 66 68 20 3d 3d 3d 20 66 61 6c 73 65 29 20 7b | ath,.'a');...if($fh.===.false).{ |
90760 | 0a 09 09 09 74 68 72 6f 77 20 6e 65 77 20 4c 6f 67 45 78 63 65 70 74 69 6f 6e 28 27 43 6f 75 6c | ....throw.new.LogException('Coul |
90780 | 64 20 6e 6f 74 20 6f 70 65 6e 20 75 70 64 61 74 65 72 2e 6c 6f 67 27 29 3b 0a 09 09 7d 0a 0a 09 | d.not.open.updater.log');...}... |
907a0 | 09 69 66 28 24 74 68 69 73 2d 3e 72 65 71 75 65 73 74 49 44 20 3d 3d 3d 20 6e 75 6c 6c 29 20 7b | .if($this->requestID.===.null).{ |
907c0 | 0a 09 09 09 24 63 68 61 72 61 63 74 65 72 73 20 3d 20 27 30 31 32 33 34 35 36 37 38 39 61 62 63 | ....$characters.=.'0123456789abc |
907e0 | 64 65 66 67 68 69 6a 6b 6c 6d 6e 6f 70 71 72 73 74 75 76 77 78 79 7a 41 42 43 44 45 46 47 48 49 | defghijklmnopqrstuvwxyzABCDEFGHI |
90800 | 4a 4b 4c 4d 4e 4f 50 51 52 53 54 55 56 57 58 59 5a 27 3b 0a 09 09 09 24 63 68 61 72 61 63 74 65 | JKLMNOPQRSTUVWXYZ';....$characte |
90820 | 72 73 4c 65 6e 67 74 68 20 3d 20 73 74 72 6c 65 6e 28 24 63 68 61 72 61 63 74 65 72 73 29 3b 0a | rsLength.=.strlen($characters);. |
90840 | 09 09 09 24 72 61 6e 64 6f 6d 53 74 72 69 6e 67 20 3d 20 27 27 3b 0a 09 09 09 66 6f 72 20 28 24 | ...$randomString.=.'';....for.($ |
90860 | 69 20 3d 20 30 3b 20 24 69 20 3c 20 31 30 3b 20 24 69 2b 2b 29 20 7b 0a 09 09 09 09 24 72 61 6e | i.=.0;.$i.<.10;.$i++).{.....$ran |
90880 | 64 6f 6d 53 74 72 69 6e 67 20 2e 3d 20 24 63 68 61 72 61 63 74 65 72 73 5b 72 61 6e 64 28 30 2c | domString..=.$characters[rand(0, |
908a0 | 20 24 63 68 61 72 61 63 74 65 72 73 4c 65 6e 67 74 68 20 2d 20 31 29 5d 3b 0a 09 09 09 7d 0a 09 | .$charactersLength.-.1)];....}.. |
908c0 | 09 09 24 74 68 69 73 2d 3e 72 65 71 75 65 73 74 49 44 20 3d 20 24 72 61 6e 64 6f 6d 53 74 72 69 | ..$this->requestID.=.$randomStri |
908e0 | 6e 67 3b 0a 09 09 7d 0a 0a 09 09 24 6c 6f 67 4c 69 6e 65 20 3d 20 64 61 74 65 28 5c 44 61 74 65 | ng;...}....$logLine.=.date(\Date |
90900 | 54 69 6d 65 3a 3a 49 53 4f 38 36 30 31 29 20 2e 20 27 20 27 20 2e 20 24 74 68 69 73 2d 3e 72 65 | Time::ISO8601)...'.'...$this->re |
90920 | 71 75 65 73 74 49 44 20 2e 20 27 20 27 20 2e 20 24 6d 65 73 73 61 67 65 20 2e 20 50 48 50 5f 45 | questID...'.'...$message...PHP_E |
90940 | 4f 4c 3b 0a 0a 09 09 24 72 65 73 75 6c 74 20 3d 20 66 77 72 69 74 65 28 24 66 68 2c 20 24 6c 6f | OL;....$result.=.fwrite($fh,.$lo |
90960 | 67 4c 69 6e 65 29 3b 0a 09 09 69 66 28 24 72 65 73 75 6c 74 20 3d 3d 3d 20 66 61 6c 73 65 29 20 | gLine);...if($result.===.false). |
90980 | 7b 0a 09 09 09 74 68 72 6f 77 20 6e 65 77 20 4c 6f 67 45 78 63 65 70 74 69 6f 6e 28 27 43 6f 75 | {....throw.new.LogException('Cou |
909a0 | 6c 64 20 6e 6f 74 20 77 72 69 74 65 20 74 6f 20 75 70 64 61 74 65 72 2e 6c 6f 67 27 29 3b 0a 09 | ld.not.write.to.updater.log');.. |
909c0 | 09 7d 0a 0a 09 09 66 63 6c 6f 73 65 28 24 66 68 29 3b 0a 09 7d 0a 0a 0a 09 2f 2a 2a 0a 09 20 2a | .}....fclose($fh);..}..../**...* |
909e0 | 20 4c 6f 67 73 20 61 20 6d 65 73 73 61 67 65 20 77 69 74 68 20 63 75 72 72 65 6e 74 20 64 61 74 | .Logs.a.message.with.current.dat |
90a00 | 65 74 69 6d 65 20 70 72 65 70 65 6e 64 65 64 20 74 6f 20 75 70 64 61 74 65 72 2e 6c 6f 67 20 62 | etime.prepended.to.updater.log.b |
90a20 | 75 74 20 64 72 6f 70 73 20 70 6f 73 73 69 62 6c 65 20 4c 6f 67 45 78 63 65 70 74 69 6f 6e 0a 09 | ut.drops.possible.LogException.. |
90a40 | 20 2a 0a 09 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 24 6d 65 73 73 61 67 65 0a 09 20 | .*...*.@param.string.$message... |
90a60 | 2a 2f 0a 09 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 69 6c 65 6e 74 4c 6f 67 28 24 6d | */..public.function.silentLog($m |
90a80 | 65 73 73 61 67 65 29 20 7b 0a 09 09 74 72 79 20 7b 0a 09 09 09 24 74 68 69 73 2d 3e 6c 6f 67 28 | essage).{...try.{....$this->log( |
90aa0 | 24 6d 65 73 73 61 67 65 29 3b 0a 09 09 7d 20 63 61 74 63 68 20 28 4c 6f 67 45 78 63 65 70 74 69 | $message);...}.catch.(LogExcepti |
90ac0 | 6f 6e 20 24 6c 6f 67 45 29 20 7b 0a 09 09 09 2f 2a 20 69 67 6e 6f 72 65 20 6c 6f 67 20 65 78 63 | on.$logE).{..../*.ignore.log.exc |
90ae0 | 65 70 74 69 6f 6e 20 68 65 72 65 20 28 61 6c 72 65 61 64 79 20 64 65 74 65 63 74 65 64 20 6c 61 | eption.here.(already.detected.la |
90b00 | 74 65 72 20 61 6e 79 77 61 79 73 29 20 2a 2f 0a 09 09 7d 0a 09 7d 0a 0a 0a 09 2f 2a 2a 0a 09 20 | ter.anyways).*/...}..}..../**... |
90b20 | 2a 20 4c 6f 67 73 20 63 75 72 72 65 6e 74 20 76 65 72 73 69 6f 6e 0a 09 20 2a 0a 09 20 2a 2f 0a | *.Logs.current.version...*...*/. |
90b40 | 09 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 6c 6f 67 56 65 72 73 69 6f 6e 28 29 20 7b 0a | .public.function.logVersion().{. |
90b60 | 09 09 24 74 68 69 73 2d 3e 73 69 6c 65 6e 74 4c 6f 67 28 27 5b 69 6e 66 6f 5d 20 63 75 72 72 65 | ..$this->silentLog('[info].curre |
90b80 | 6e 74 20 76 65 72 73 69 6f 6e 3a 20 27 20 2e 20 24 74 68 69 73 2d 3e 63 75 72 72 65 6e 74 56 65 | nt.version:.'...$this->currentVe |
90ba0 | 72 73 69 6f 6e 20 2e 20 27 20 62 75 69 6c 64 20 74 69 6d 65 3a 20 27 20 2e 20 24 74 68 69 73 2d | rsion...'.build.time:.'...$this- |
90bc0 | 3e 62 75 69 6c 64 54 69 6d 65 29 3b 0a 09 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 6e 61 6d 65 73 70 61 | >buildTime);..}.}.<?php..namespa |
90be0 | 63 65 20 4e 43 5c 55 70 64 61 74 65 72 3b 0a 0a 63 6c 61 73 73 20 56 65 72 73 69 6f 6e 20 7b 0a | ce.NC\Updater;..class.Version.{. |
90c00 | 09 66 75 6e 63 74 69 6f 6e 20 67 65 74 28 29 20 7b 0a 09 09 72 65 74 75 72 6e 20 27 76 32 34 2e | .function.get().{...return.'v24. |
90c20 | 30 2e 30 62 65 74 61 33 2d 31 2d 67 36 37 62 66 31 33 62 20 64 69 72 74 79 27 3b 0a 09 7d 0a 7d | 0.0beta3-1-g67bf13b.dirty';..}.} |
90c40 | 0a 3c 3f 70 68 70 0a 2f 2a 2a 0a 20 2a 20 40 63 6f 70 79 72 69 67 68 74 20 43 6f 70 79 72 69 67 | .<?php./**..*.@copyright.Copyrig |
90c60 | 68 74 20 28 63 29 20 32 30 31 36 20 4c 75 6b 61 73 20 52 65 73 63 68 6b 65 20 3c 6c 75 6b 61 73 | ht.(c).2016.Lukas.Reschke.<lukas |
90c80 | 40 73 74 61 74 75 73 63 6f 64 65 2e 63 68 3e 0a 20 2a 20 40 63 6f 70 79 72 69 67 68 74 20 43 6f | @statuscode.ch>..*.@copyright.Co |
90ca0 | 70 79 72 69 67 68 74 20 28 63 29 20 32 30 31 36 20 4d 6f 72 72 69 73 20 4a 6f 62 6b 65 20 3c 68 | pyright.(c).2016.Morris.Jobke.<h |
90cc0 | 65 79 40 6d 6f 72 72 69 73 6a 6f 62 6b 65 2e 64 65 3e 0a 20 2a 0a 20 2a 20 40 6c 69 63 65 6e 73 | ey@morrisjobke.de>..*..*.@licens |
90ce0 | 65 20 47 4e 55 20 41 47 50 4c 20 76 65 72 73 69 6f 6e 20 33 20 6f 72 20 61 6e 79 20 6c 61 74 65 | e.GNU.AGPL.version.3.or.any.late |
90d00 | 72 20 76 65 72 73 69 6f 6e 0a 20 2a 0a 20 2a 20 54 68 69 73 20 70 72 6f 67 72 61 6d 20 69 73 20 | r.version..*..*.This.program.is. |
90d20 | 66 72 65 65 20 73 6f 66 74 77 61 72 65 3a 20 79 6f 75 20 63 61 6e 20 72 65 64 69 73 74 72 69 62 | free.software:.you.can.redistrib |
90d40 | 75 74 65 20 69 74 20 61 6e 64 2f 6f 72 20 6d 6f 64 69 66 79 0a 20 2a 20 69 74 20 75 6e 64 65 72 | ute.it.and/or.modify..*.it.under |
90d60 | 20 74 68 65 20 74 65 72 6d 73 20 6f 66 20 74 68 65 20 47 4e 55 20 41 66 66 65 72 6f 20 47 65 6e | .the.terms.of.the.GNU.Affero.Gen |
90d80 | 65 72 61 6c 20 50 75 62 6c 69 63 20 4c 69 63 65 6e 73 65 20 61 73 0a 20 2a 20 70 75 62 6c 69 73 | eral.Public.License.as..*.publis |
90da0 | 68 65 64 20 62 79 20 74 68 65 20 46 72 65 65 20 53 6f 66 74 77 61 72 65 20 46 6f 75 6e 64 61 74 | hed.by.the.Free.Software.Foundat |
90dc0 | 69 6f 6e 2c 20 65 69 74 68 65 72 20 76 65 72 73 69 6f 6e 20 33 20 6f 66 20 74 68 65 0a 20 2a 20 | ion,.either.version.3.of.the..*. |
90de0 | 4c 69 63 65 6e 73 65 2c 20 6f 72 20 28 61 74 20 79 6f 75 72 20 6f 70 74 69 6f 6e 29 20 61 6e 79 | License,.or.(at.your.option).any |
90e00 | 20 6c 61 74 65 72 20 76 65 72 73 69 6f 6e 2e 0a 20 2a 0a 20 2a 20 54 68 69 73 20 70 72 6f 67 72 | .later.version...*..*.This.progr |
90e20 | 61 6d 20 69 73 20 64 69 73 74 72 69 62 75 74 65 64 20 69 6e 20 74 68 65 20 68 6f 70 65 20 74 68 | am.is.distributed.in.the.hope.th |
90e40 | 61 74 20 69 74 20 77 69 6c 6c 20 62 65 20 75 73 65 66 75 6c 2c 0a 20 2a 20 62 75 74 20 57 49 54 | at.it.will.be.useful,..*.but.WIT |
90e60 | 48 4f 55 54 20 41 4e 59 20 57 41 52 52 41 4e 54 59 3b 20 77 69 74 68 6f 75 74 20 65 76 65 6e 20 | HOUT.ANY.WARRANTY;.without.even. |
90e80 | 74 68 65 20 69 6d 70 6c 69 65 64 20 77 61 72 72 61 6e 74 79 20 6f 66 0a 20 2a 20 4d 45 52 43 48 | the.implied.warranty.of..*.MERCH |
90ea0 | 41 4e 54 41 42 49 4c 49 54 59 20 6f 72 20 46 49 54 4e 45 53 53 20 46 4f 52 20 41 20 50 41 52 54 | ANTABILITY.or.FITNESS.FOR.A.PART |
90ec0 | 49 43 55 4c 41 52 20 50 55 52 50 4f 53 45 2e 20 20 53 65 65 20 74 68 65 0a 20 2a 20 47 4e 55 20 | ICULAR.PURPOSE...See.the..*.GNU. |
90ee0 | 41 66 66 65 72 6f 20 47 65 6e 65 72 61 6c 20 50 75 62 6c 69 63 20 4c 69 63 65 6e 73 65 20 66 6f | Affero.General.Public.License.fo |
90f00 | 72 20 6d 6f 72 65 20 64 65 74 61 69 6c 73 2e 0a 20 2a 0a 20 2a 20 59 6f 75 20 73 68 6f 75 6c 64 | r.more.details...*..*.You.should |
90f20 | 20 68 61 76 65 20 72 65 63 65 69 76 65 64 20 61 20 63 6f 70 79 20 6f 66 20 74 68 65 20 47 4e 55 | .have.received.a.copy.of.the.GNU |
90f40 | 20 41 66 66 65 72 6f 20 47 65 6e 65 72 61 6c 20 50 75 62 6c 69 63 20 4c 69 63 65 6e 73 65 0a 20 | .Affero.General.Public.License.. |
90f60 | 2a 20 61 6c 6f 6e 67 20 77 69 74 68 20 74 68 69 73 20 70 72 6f 67 72 61 6d 2e 20 20 49 66 20 6e | *.along.with.this.program...If.n |
90f80 | 6f 74 2c 20 73 65 65 20 3c 68 74 74 70 3a 2f 2f 77 77 77 2e 67 6e 75 2e 6f 72 67 2f 6c 69 63 65 | ot,.see.<http://www.gnu.org/lice |
90fa0 | 6e 73 65 73 2f 3e 2e 0a 20 2a 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 4e 43 5c 55 70 64 | nses/>...*..*/..namespace.NC\Upd |
90fc0 | 61 74 65 72 3b 0a 0a 63 6c 61 73 73 20 4c 6f 67 45 78 63 65 70 74 69 6f 6e 20 65 78 74 65 6e 64 | ater;..class.LogException.extend |
90fe0 | 73 20 5c 45 78 63 65 70 74 69 6f 6e 20 7b 0a 7d 0a 3c 3f 70 68 70 0a 2f 2a 2a 0a 20 2a 20 40 63 | s.\Exception.{.}.<?php./**..*.@c |
91000 | 6f 70 79 72 69 67 68 74 20 43 6f 70 79 72 69 67 68 74 20 28 63 29 20 32 30 31 36 20 4d 6f 72 72 | opyright.Copyright.(c).2016.Morr |
91020 | 69 73 20 4a 6f 62 6b 65 20 3c 68 65 79 40 6d 6f 72 72 69 73 6a 6f 62 6b 65 2e 64 65 3e 0a 20 2a | is.Jobke.<hey@morrisjobke.de>..* |
91040 | 20 40 63 6f 70 79 72 69 67 68 74 20 43 6f 70 79 72 69 67 68 74 20 28 63 29 20 32 30 31 37 20 4c | .@copyright.Copyright.(c).2017.L |
91060 | 75 6b 61 73 20 52 65 73 63 68 6b 65 20 3c 6c 75 6b 61 73 40 73 74 61 74 75 73 63 6f 64 65 2e 63 | ukas.Reschke.<lukas@statuscode.c |
91080 | 68 3e 0a 20 2a 0a 20 2a 20 40 6c 69 63 65 6e 73 65 20 47 4e 55 20 41 47 50 4c 20 76 65 72 73 69 | h>..*..*.@license.GNU.AGPL.versi |
910a0 | 6f 6e 20 33 20 6f 72 20 61 6e 79 20 6c 61 74 65 72 20 76 65 72 73 69 6f 6e 0a 20 2a 0a 20 2a 20 | on.3.or.any.later.version..*..*. |
910c0 | 54 68 69 73 20 70 72 6f 67 72 61 6d 20 69 73 20 66 72 65 65 20 73 6f 66 74 77 61 72 65 3a 20 79 | This.program.is.free.software:.y |
910e0 | 6f 75 20 63 61 6e 20 72 65 64 69 73 74 72 69 62 75 74 65 20 69 74 20 61 6e 64 2f 6f 72 20 6d 6f | ou.can.redistribute.it.and/or.mo |
91100 | 64 69 66 79 0a 20 2a 20 69 74 20 75 6e 64 65 72 20 74 68 65 20 74 65 72 6d 73 20 6f 66 20 74 68 | dify..*.it.under.the.terms.of.th |
91120 | 65 20 47 4e 55 20 41 66 66 65 72 6f 20 47 65 6e 65 72 61 6c 20 50 75 62 6c 69 63 20 4c 69 63 65 | e.GNU.Affero.General.Public.Lice |
91140 | 6e 73 65 20 61 73 0a 20 2a 20 70 75 62 6c 69 73 68 65 64 20 62 79 20 74 68 65 20 46 72 65 65 20 | nse.as..*.published.by.the.Free. |
91160 | 53 6f 66 74 77 61 72 65 20 46 6f 75 6e 64 61 74 69 6f 6e 2c 20 65 69 74 68 65 72 20 76 65 72 73 | Software.Foundation,.either.vers |
91180 | 69 6f 6e 20 33 20 6f 66 20 74 68 65 0a 20 2a 20 4c 69 63 65 6e 73 65 2c 20 6f 72 20 28 61 74 20 | ion.3.of.the..*.License,.or.(at. |
911a0 | 79 6f 75 72 20 6f 70 74 69 6f 6e 29 20 61 6e 79 20 6c 61 74 65 72 20 76 65 72 73 69 6f 6e 2e 0a | your.option).any.later.version.. |
911c0 | 20 2a 0a 20 2a 20 54 68 69 73 20 70 72 6f 67 72 61 6d 20 69 73 20 64 69 73 74 72 69 62 75 74 65 | .*..*.This.program.is.distribute |
911e0 | 64 20 69 6e 20 74 68 65 20 68 6f 70 65 20 74 68 61 74 20 69 74 20 77 69 6c 6c 20 62 65 20 75 73 | d.in.the.hope.that.it.will.be.us |
91200 | 65 66 75 6c 2c 0a 20 2a 20 62 75 74 20 57 49 54 48 4f 55 54 20 41 4e 59 20 57 41 52 52 41 4e 54 | eful,..*.but.WITHOUT.ANY.WARRANT |
91220 | 59 3b 20 77 69 74 68 6f 75 74 20 65 76 65 6e 20 74 68 65 20 69 6d 70 6c 69 65 64 20 77 61 72 72 | Y;.without.even.the.implied.warr |
91240 | 61 6e 74 79 20 6f 66 0a 20 2a 20 4d 45 52 43 48 41 4e 54 41 42 49 4c 49 54 59 20 6f 72 20 46 49 | anty.of..*.MERCHANTABILITY.or.FI |
91260 | 54 4e 45 53 53 20 46 4f 52 20 41 20 50 41 52 54 49 43 55 4c 41 52 20 50 55 52 50 4f 53 45 2e 20 | TNESS.FOR.A.PARTICULAR.PURPOSE.. |
91280 | 20 53 65 65 20 74 68 65 0a 20 2a 20 47 4e 55 20 41 66 66 65 72 6f 20 47 65 6e 65 72 61 6c 20 50 | .See.the..*.GNU.Affero.General.P |
912a0 | 75 62 6c 69 63 20 4c 69 63 65 6e 73 65 20 66 6f 72 20 6d 6f 72 65 20 64 65 74 61 69 6c 73 2e 0a | ublic.License.for.more.details.. |
912c0 | 20 2a 0a 20 2a 20 59 6f 75 20 73 68 6f 75 6c 64 20 68 61 76 65 20 72 65 63 65 69 76 65 64 20 61 | .*..*.You.should.have.received.a |
912e0 | 20 63 6f 70 79 20 6f 66 20 74 68 65 20 47 4e 55 20 41 66 66 65 72 6f 20 47 65 6e 65 72 61 6c 20 | .copy.of.the.GNU.Affero.General. |
91300 | 50 75 62 6c 69 63 20 4c 69 63 65 6e 73 65 0a 20 2a 20 61 6c 6f 6e 67 20 77 69 74 68 20 74 68 69 | Public.License..*.along.with.thi |
91320 | 73 20 70 72 6f 67 72 61 6d 2e 20 20 49 66 20 6e 6f 74 2c 20 73 65 65 20 3c 68 74 74 70 3a 2f 2f | s.program...If.not,.see.<http:// |
91340 | 77 77 77 2e 67 6e 75 2e 6f 72 67 2f 6c 69 63 65 6e 73 65 73 2f 3e 2e 0a 20 2a 0a 20 2a 2f 0a 0a | www.gnu.org/licenses/>...*..*/.. |
91360 | 6e 61 6d 65 73 70 61 63 65 20 4e 43 5c 55 70 64 61 74 65 72 3b 0a 0a 75 73 65 20 53 79 6d 66 6f | namespace.NC\Updater;..use.Symfo |
91380 | 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 43 6f 6d 6d 61 6e 64 5c 43 6f 6d | ny\Component\Console\Command\Com |
913a0 | 6d 61 6e 64 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 | mand;.use.Symfony\Component\Cons |
913c0 | 6f 6c 65 5c 48 65 6c 70 65 72 5c 50 72 6f 67 72 65 73 73 42 61 72 3b 0a 75 73 65 20 53 79 6d 66 | ole\Helper\ProgressBar;.use.Symf |
913e0 | 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 5c 49 6e 70 75 | ony\Component\Console\Input\Inpu |
91400 | 74 49 6e 74 65 72 66 61 63 65 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e | tInterface;.use.Symfony\Componen |
91420 | 74 5c 43 6f 6e 73 6f 6c 65 5c 49 6e 70 75 74 5c 49 6e 70 75 74 4f 70 74 69 6f 6e 3b 0a 75 73 65 | t\Console\Input\InputOption;.use |
91440 | 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 4f 75 74 70 75 | .Symfony\Component\Console\Outpu |
91460 | 74 5c 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 3b 0a 75 73 65 20 53 79 6d 66 6f 6e 79 5c 43 | t\OutputInterface;.use.Symfony\C |
91480 | 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 5c 51 75 65 73 74 69 6f 6e 5c 43 6f 6e 66 69 72 | omponent\Console\Question\Confir |
914a0 | 6d 61 74 69 6f 6e 51 75 65 73 74 69 6f 6e 3b 0a 0a 63 6c 61 73 73 20 55 70 64 61 74 65 43 6f 6d | mationQuestion;..class.UpdateCom |
914c0 | 6d 61 6e 64 20 65 78 74 65 6e 64 73 20 43 6f 6d 6d 61 6e 64 20 7b 0a 0a 09 2f 2a 2a 20 40 76 61 | mand.extends.Command.{.../**.@va |
914e0 | 72 20 55 70 64 61 74 65 72 20 2a 2f 0a 09 70 72 6f 74 65 63 74 65 64 20 24 75 70 64 61 74 65 72 | r.Updater.*/..protected.$updater |
91500 | 3b 0a 0a 09 2f 2a 2a 20 40 76 61 72 20 62 6f 6f 6c 20 2a 2f 0a 09 70 72 6f 74 65 63 74 65 64 20 | ;.../**.@var.bool.*/..protected. |
91520 | 24 73 68 6f 75 6c 64 53 74 6f 70 20 3d 20 66 61 6c 73 65 3b 0a 0a 09 2f 2a 2a 20 40 76 61 72 20 | $shouldStop.=.false;.../**.@var. |
91540 | 62 6f 6f 6c 20 2a 2f 0a 09 70 72 6f 74 65 63 74 65 64 20 24 73 6b 69 70 42 61 63 6b 75 70 20 3d | bool.*/..protected.$skipBackup.= |
91560 | 20 66 61 6c 73 65 3b 0a 0a 09 2f 2a 2a 20 40 76 61 72 20 61 72 72 61 79 20 73 74 72 69 6e 67 73 | .false;.../**.@var.array.strings |
91580 | 20 6f 66 20 74 65 78 74 20 66 6f 72 20 73 74 61 67 65 73 20 6f 66 20 75 70 64 61 74 65 72 20 2a | .of.text.for.stages.of.updater.* |
915a0 | 2f 0a 09 70 72 6f 74 65 63 74 65 64 20 24 63 68 65 63 6b 54 65 78 74 73 20 3d 20 5b 0a 09 09 30 | /..protected.$checkTexts.=.[...0 |
915c0 | 20 3d 3e 20 27 27 2c 0a 09 09 31 20 3d 3e 20 27 43 68 65 63 6b 20 66 6f 72 20 65 78 70 65 63 74 | .=>.'',...1.=>.'Check.for.expect |
915e0 | 65 64 20 66 69 6c 65 73 27 2c 0a 09 09 32 20 3d 3e 20 27 43 68 65 63 6b 20 66 6f 72 20 77 72 69 | ed.files',...2.=>.'Check.for.wri |
91600 | 74 65 20 70 65 72 6d 69 73 73 69 6f 6e 73 27 2c 0a 09 09 33 20 3d 3e 20 27 43 72 65 61 74 65 20 | te.permissions',...3.=>.'Create. |
91620 | 62 61 63 6b 75 70 27 2c 0a 09 09 34 20 3d 3e 20 27 44 6f 77 6e 6c 6f 61 64 69 6e 67 27 2c 0a 09 | backup',...4.=>.'Downloading',.. |
91640 | 09 35 20 3d 3e 20 27 56 65 72 69 66 79 20 69 6e 74 65 67 72 69 74 79 27 2c 0a 09 09 36 20 3d 3e | .5.=>.'Verify.integrity',...6.=> |
91660 | 20 27 45 78 74 72 61 63 74 69 6e 67 27 2c 0a 09 09 37 20 3d 3e 20 27 45 6e 61 62 6c 65 20 6d 61 | .'Extracting',...7.=>.'Enable.ma |
91680 | 69 6e 74 65 6e 61 6e 63 65 20 6d 6f 64 65 27 2c 0a 09 09 38 20 3d 3e 20 27 52 65 70 6c 61 63 65 | intenance.mode',...8.=>.'Replace |
916a0 | 20 65 6e 74 72 79 20 70 6f 69 6e 74 73 27 2c 0a 09 09 39 20 3d 3e 20 27 44 65 6c 65 74 65 20 6f | .entry.points',...9.=>.'Delete.o |
916c0 | 6c 64 20 66 69 6c 65 73 27 2c 0a 09 09 31 30 20 3d 3e 20 27 4d 6f 76 65 20 6e 65 77 20 66 69 6c | ld.files',...10.=>.'Move.new.fil |
916e0 | 65 73 20 69 6e 20 70 6c 61 63 65 27 2c 0a 09 09 31 31 20 3d 3e 20 27 4b 65 65 70 20 6d 61 69 6e | es.in.place',...11.=>.'Keep.main |
91700 | 74 65 6e 61 6e 63 65 20 6d 6f 64 65 20 61 63 74 69 76 65 3f 27 2c 0a 09 09 31 32 20 3d 3e 20 27 | tenance.mode.active?',...12.=>.' |
91720 | 44 6f 6e 65 27 2c 0a 09 5d 3b 0a 0a 09 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 | Done',..];...protected.function. |
91740 | 63 6f 6e 66 69 67 75 72 65 28 29 20 7b 0a 09 09 24 74 68 69 73 0a 09 09 09 2d 3e 73 65 74 4e 61 | configure().{...$this....->setNa |
91760 | 6d 65 28 27 75 70 64 61 74 65 27 29 0a 09 09 09 2d 3e 73 65 74 44 65 73 63 72 69 70 74 69 6f 6e | me('update')....->setDescription |
91780 | 28 27 55 70 64 61 74 65 73 20 74 68 65 20 63 6f 64 65 20 6f 66 20 61 6e 20 4e 65 78 74 63 6c 6f | ('Updates.the.code.of.an.Nextclo |
917a0 | 75 64 20 69 6e 73 74 61 6e 63 65 27 29 0a 09 09 09 2d 3e 73 65 74 48 65 6c 70 28 22 54 68 69 73 | ud.instance')....->setHelp("This |
917c0 | 20 63 6f 6d 6d 61 6e 64 20 66 65 74 63 68 65 73 20 74 68 65 20 6c 61 74 65 73 74 20 63 6f 64 65 | .command.fetches.the.latest.code |
917e0 | 20 74 68 61 74 20 69 73 20 61 6e 6e 6f 75 6e 63 65 64 20 76 69 61 20 74 68 65 20 75 70 64 61 74 | .that.is.announced.via.the.updat |
91800 | 65 72 20 73 65 72 76 65 72 20 61 6e 64 20 73 61 66 65 6c 79 20 72 65 70 6c 61 63 65 73 20 74 68 | er.server.and.safely.replaces.th |
91820 | 65 20 65 78 69 73 74 69 6e 67 20 63 6f 64 65 20 77 69 74 68 20 74 68 65 20 6e 65 77 20 6f 6e 65 | e.existing.code.with.the.new.one |
91840 | 2e 22 29 0a 09 09 09 2d 3e 61 64 64 4f 70 74 69 6f 6e 28 27 6e 6f 2d 62 61 63 6b 75 70 27 2c 20 | .")....->addOption('no-backup',. |
91860 | 6e 75 6c 6c 2c 20 49 6e 70 75 74 4f 70 74 69 6f 6e 3a 3a 56 41 4c 55 45 5f 4e 4f 4e 45 2c 20 27 | null,.InputOption::VALUE_NONE,.' |
91880 | 53 6b 69 70 20 62 61 63 6b 75 70 20 6f 66 20 63 75 72 72 65 6e 74 20 4e 65 78 74 63 6c 6f 75 64 | Skip.backup.of.current.Nextcloud |
918a0 | 20 76 65 72 73 69 6f 6e 27 29 3b 0a 09 7d 0a 0a 09 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 | .version');..}...protected.funct |
918c0 | 69 6f 6e 20 65 78 65 63 75 74 65 28 49 6e 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 69 6e 70 75 | ion.execute(InputInterface.$inpu |
918e0 | 74 2c 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 29 20 7b 0a 09 09 | t,.OutputInterface.$output).{... |
91900 | 24 74 68 69 73 2d 3e 73 6b 69 70 42 61 63 6b 75 70 20 3d 20 24 69 6e 70 75 74 2d 3e 67 65 74 4f | $this->skipBackup.=.$input->getO |
91920 | 70 74 69 6f 6e 28 27 6e 6f 2d 62 61 63 6b 75 70 27 29 3b 0a 0a 09 09 69 66 20 28 63 6c 61 73 73 | ption('no-backup');....if.(class |
91940 | 5f 65 78 69 73 74 73 28 27 4e 43 5c 55 70 64 61 74 65 72 5c 56 65 72 73 69 6f 6e 27 29 29 20 7b | _exists('NC\Updater\Version')).{ |
91960 | 0a 09 09 09 24 76 65 72 73 69 6f 6e 43 6c 61 73 73 20 3d 20 6e 65 77 20 56 65 72 73 69 6f 6e 28 | ....$versionClass.=.new.Version( |
91980 | 29 3b 0a 09 09 09 24 76 65 72 73 69 6f 6e 20 3d 20 24 76 65 72 73 69 6f 6e 43 6c 61 73 73 2d 3e | );....$version.=.$versionClass-> |
919a0 | 67 65 74 28 29 3b 0a 09 09 7d 20 65 6c 73 65 20 7b 0a 09 09 09 24 76 65 72 73 69 6f 6e 20 3d 20 | get();...}.else.{....$version.=. |
919c0 | 27 64 69 72 65 63 74 6c 79 20 72 75 6e 20 66 72 6f 6d 20 67 69 74 20 63 68 65 63 6b 6f 75 74 27 | 'directly.run.from.git.checkout' |
919e0 | 3b 0a 09 09 7d 0a 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 27 4e 65 78 74 63 6c | ;...}...$output->writeln('Nextcl |
91a00 | 6f 75 64 20 55 70 64 61 74 65 72 20 2d 20 76 65 72 73 69 6f 6e 3a 20 27 20 2e 20 24 76 65 72 73 | oud.Updater.-.version:.'...$vers |
91a20 | 69 6f 6e 29 3b 0a 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 27 27 29 3b 0a 0a 09 | ion);...$output->writeln('');... |
91a40 | 09 2f 2f 20 43 68 65 63 6b 20 69 66 20 74 68 65 20 63 6f 6e 66 69 67 2e 70 68 70 20 69 73 20 61 | .//.Check.if.the.config.php.is.a |
91a60 | 74 20 74 68 65 20 65 78 70 65 63 74 65 64 20 70 6c 61 63 65 0a 09 09 74 72 79 20 7b 0a 09 09 09 | t.the.expected.place...try.{.... |
91a80 | 24 70 61 74 68 20 3d 20 64 69 72 6e 61 6d 65 28 5f 5f 44 49 52 5f 5f 29 3b 20 2f 2f 20 64 69 72 | $path.=.dirname(__DIR__);.//.dir |
91aa0 | 6e 61 6d 65 28 29 20 62 65 63 61 75 73 65 20 77 65 20 61 72 65 20 69 6e 73 69 64 65 20 74 68 65 | name().because.we.are.inside.the |
91ac0 | 20 6c 69 62 2f 20 73 75 62 66 6f 6c 64 65 72 0a 09 09 09 24 70 68 61 72 50 61 74 68 20 3d 20 5c | .lib/.subfolder....$pharPath.=.\ |
91ae0 | 50 68 61 72 3a 3a 72 75 6e 6e 69 6e 67 28 66 61 6c 73 65 29 3b 0a 09 09 09 69 66 20 28 24 70 68 | Phar::running(false);....if.($ph |
91b00 | 61 72 50 61 74 68 20 21 3d 3d 20 27 27 29 20 7b 0a 09 09 09 09 24 70 61 74 68 20 3d 20 64 69 72 | arPath.!==.'').{.....$path.=.dir |
91b20 | 6e 61 6d 65 28 24 70 68 61 72 50 61 74 68 29 3b 0a 09 09 09 7d 0a 09 09 09 24 74 68 69 73 2d 3e | name($pharPath);....}....$this-> |
91b40 | 75 70 64 61 74 65 72 20 3d 20 6e 65 77 20 55 70 64 61 74 65 72 28 24 70 61 74 68 29 3b 0a 09 09 | updater.=.new.Updater($path);... |
91b60 | 7d 20 63 61 74 63 68 20 28 5c 45 78 63 65 70 74 69 6f 6e 20 24 65 29 20 7b 0a 09 09 09 2f 2f 20 | }.catch.(\Exception.$e).{....//. |
91b80 | 6c 6f 67 67 69 6e 67 20 68 65 72 65 20 69 73 20 6e 6f 74 20 70 6f 73 73 69 62 6c 65 20 62 65 63 | logging.here.is.not.possible.bec |
91ba0 | 61 75 73 65 20 77 65 20 64 6f 6e 27 74 20 6b 6e 6f 77 20 74 68 65 20 64 61 74 61 20 64 69 72 65 | ause.we.don't.know.the.data.dire |
91bc0 | 63 74 6f 72 79 0a 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 24 65 2d 3e 67 65 | ctory....$output->writeln($e->ge |
91be0 | 74 4d 65 73 73 61 67 65 28 29 29 3b 0a 09 09 09 72 65 74 75 72 6e 20 2d 31 3b 0a 09 09 7d 0a 0a | tMessage());....return.-1;...}.. |
91c00 | 09 09 69 66 20 28 21 66 75 6e 63 74 69 6f 6e 5f 65 78 69 73 74 73 28 27 70 6f 73 69 78 5f 67 65 | ..if.(!function_exists('posix_ge |
91c20 | 74 75 69 64 27 29 29 20 7b 0a 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 22 54 | tuid')).{....$output->writeln("T |
91c40 | 68 65 20 70 6f 73 69 78 20 65 78 74 65 6e 73 69 6f 6e 73 20 61 72 65 20 72 65 71 75 69 72 65 64 | he.posix.extensions.are.required |
91c60 | 20 2d 20 73 65 65 20 68 74 74 70 3a 2f 2f 70 68 70 2e 6e 65 74 2f 6d 61 6e 75 61 6c 2f 65 6e 2f | .-.see.http://php.net/manual/en/ |
91c80 | 62 6f 6f 6b 2e 70 6f 73 69 78 2e 70 68 70 22 29 3b 0a 09 09 09 72 65 74 75 72 6e 20 2d 31 3b 0a | book.posix.php");....return.-1;. |
91ca0 | 09 09 7d 0a 0a 09 09 69 66 28 24 64 69 72 20 3d 20 67 65 74 65 6e 76 28 27 4e 45 58 54 43 4c 4f | ..}....if($dir.=.getenv('NEXTCLO |
91cc0 | 55 44 5f 43 4f 4e 46 49 47 5f 44 49 52 27 29 29 20 7b 0a 09 09 09 24 63 6f 6e 66 69 67 46 69 6c | UD_CONFIG_DIR')).{....$configFil |
91ce0 | 65 4e 61 6d 65 20 3d 20 72 74 72 69 6d 28 24 64 69 72 2c 20 27 2f 27 29 20 2e 20 27 2f 63 6f 6e | eName.=.rtrim($dir,.'/')...'/con |
91d00 | 66 69 67 2e 70 68 70 27 3b 0a 09 09 7d 20 65 6c 73 65 20 7b 0a 09 09 09 24 63 6f 6e 66 69 67 46 | fig.php';...}.else.{....$configF |
91d20 | 69 6c 65 4e 61 6d 65 20 3d 20 24 70 61 74 68 20 2e 20 27 2f 2e 2e 2f 63 6f 6e 66 69 67 2f 63 6f | ileName.=.$path...'/../config/co |
91d40 | 6e 66 69 67 2e 70 68 70 27 3b 0a 09 09 7d 0a 09 09 24 75 73 65 72 20 3d 20 70 6f 73 69 78 5f 67 | nfig.php';...}...$user.=.posix_g |
91d60 | 65 74 70 77 75 69 64 28 70 6f 73 69 78 5f 67 65 74 75 69 64 28 29 29 3b 0a 09 09 24 63 6f 6e 66 | etpwuid(posix_getuid());...$conf |
91d80 | 69 67 55 73 65 72 20 3d 20 70 6f 73 69 78 5f 67 65 74 70 77 75 69 64 28 66 69 6c 65 6f 77 6e 65 | igUser.=.posix_getpwuid(fileowne |
91da0 | 72 28 24 63 6f 6e 66 69 67 46 69 6c 65 4e 61 6d 65 29 29 3b 0a 09 09 69 66 20 28 24 75 73 65 72 | r($configFileName));...if.($user |
91dc0 | 5b 27 6e 61 6d 65 27 5d 20 21 3d 3d 20 24 63 6f 6e 66 69 67 55 73 65 72 5b 27 6e 61 6d 65 27 5d | ['name'].!==.$configUser['name'] |
91de0 | 29 20 7b 0a 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 22 43 6f 6e 73 6f 6c 65 | ).{....$output->writeln("Console |
91e00 | 20 68 61 73 20 74 6f 20 62 65 20 65 78 65 63 75 74 65 64 20 77 69 74 68 20 74 68 65 20 75 73 65 | .has.to.be.executed.with.the.use |
91e20 | 72 20 74 68 61 74 20 6f 77 6e 73 20 74 68 65 20 66 69 6c 65 20 63 6f 6e 66 69 67 2f 63 6f 6e 66 | r.that.owns.the.file.config/conf |
91e40 | 69 67 2e 70 68 70 22 29 3b 0a 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 22 43 | ig.php");....$output->writeln("C |
91e60 | 75 72 72 65 6e 74 20 75 73 65 72 3a 20 22 20 2e 20 24 75 73 65 72 5b 27 6e 61 6d 65 27 5d 29 3b | urrent.user:."...$user['name']); |
91e80 | 0a 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 22 4f 77 6e 65 72 20 6f 66 20 63 | ....$output->writeln("Owner.of.c |
91ea0 | 6f 6e 66 69 67 2e 70 68 70 3a 20 22 20 2e 20 24 63 6f 6e 66 69 67 55 73 65 72 5b 27 6e 61 6d 65 | onfig.php:."...$configUser['name |
91ec0 | 27 5d 29 3b 0a 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 22 54 72 79 20 61 64 | ']);....$output->writeln("Try.ad |
91ee0 | 64 69 6e 67 20 27 73 75 64 6f 20 2d 75 20 22 20 2e 20 24 63 6f 6e 66 69 67 55 73 65 72 5b 27 6e | ding.'sudo.-u."...$configUser['n |
91f00 | 61 6d 65 27 5d 20 2e 20 22 20 27 20 74 6f 20 74 68 65 20 62 65 67 69 6e 6e 69 6e 67 20 6f 66 20 | ame']...".'.to.the.beginning.of. |
91f20 | 74 68 65 20 63 6f 6d 6d 61 6e 64 20 28 77 69 74 68 6f 75 74 20 74 68 65 20 73 69 6e 67 6c 65 20 | the.command.(without.the.single. |
91f40 | 71 75 6f 74 65 73 29 22 29 3b 0a 09 09 09 72 65 74 75 72 6e 20 2d 31 3b 0a 09 09 7d 0a 0a 09 09 | quotes)");....return.-1;...}.... |
91f60 | 2f 2f 20 43 68 65 63 6b 20 69 66 20 74 68 65 20 75 70 64 61 74 65 72 2e 6c 6f 67 20 63 61 6e 20 | //.Check.if.the.updater.log.can. |
91f80 | 62 65 20 77 72 69 74 74 65 6e 20 74 6f 0a 09 09 74 72 79 20 7b 0a 09 09 09 24 74 68 69 73 2d 3e | be.written.to...try.{....$this-> |
91fa0 | 75 70 64 61 74 65 72 2d 3e 6c 6f 67 28 27 5b 69 6e 66 6f 5d 20 75 70 64 61 74 65 72 20 63 6c 69 | updater->log('[info].updater.cli |
91fc0 | 20 69 73 20 65 78 65 63 75 74 65 64 27 29 3b 0a 09 09 7d 20 63 61 74 63 68 20 28 5c 45 78 63 65 | .is.executed');...}.catch.(\Exce |
91fe0 | 70 74 69 6f 6e 20 24 65 29 20 7b 0a 09 09 09 2f 2f 20 73 68 6f 77 20 6c 6f 67 67 69 6e 67 20 65 | ption.$e).{....//.show.logging.e |
92000 | 72 72 6f 72 20 74 6f 20 75 73 65 72 0a 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e | rror.to.user....$output->writeln |
92020 | 28 24 65 2d 3e 67 65 74 4d 65 73 73 61 67 65 28 29 29 3b 0a 09 09 09 72 65 74 75 72 6e 20 2d 31 | ($e->getMessage());....return.-1 |
92040 | 3b 0a 09 09 7d 0a 0a 09 09 2f 2f 20 43 68 65 63 6b 20 69 66 20 61 6c 72 65 61 64 79 20 61 20 73 | ;...}....//.Check.if.already.a.s |
92060 | 74 65 70 20 69 73 20 69 6e 20 70 72 6f 63 65 73 73 0a 09 09 24 63 75 72 72 65 6e 74 53 74 65 70 | tep.is.in.process...$currentStep |
92080 | 20 3d 20 24 74 68 69 73 2d 3e 75 70 64 61 74 65 72 2d 3e 63 75 72 72 65 6e 74 53 74 65 70 28 29 | .=.$this->updater->currentStep() |
920a0 | 3b 0a 09 09 24 73 74 65 70 4e 75 6d 62 65 72 20 3d 20 30 3b 0a 09 09 69 66 28 24 63 75 72 72 65 | ;...$stepNumber.=.0;...if($curre |
920c0 | 6e 74 53 74 65 70 20 21 3d 3d 20 5b 5d 29 20 7b 0a 09 09 09 24 73 74 65 70 53 74 61 74 65 20 3d | ntStep.!==.[]).{....$stepState.= |
920e0 | 20 24 63 75 72 72 65 6e 74 53 74 65 70 5b 27 73 74 61 74 65 27 5d 3b 0a 09 09 09 24 73 74 65 70 | .$currentStep['state'];....$step |
92100 | 4e 75 6d 62 65 72 20 3d 20 24 63 75 72 72 65 6e 74 53 74 65 70 5b 27 73 74 65 70 27 5d 3b 0a 09 | Number.=.$currentStep['step'];.. |
92120 | 09 09 24 74 68 69 73 2d 3e 75 70 64 61 74 65 72 2d 3e 6c 6f 67 28 27 5b 69 6e 66 6f 5d 20 53 74 | ..$this->updater->log('[info].St |
92140 | 65 70 20 27 20 2e 20 24 73 74 65 70 4e 75 6d 62 65 72 20 2e 20 27 20 69 73 20 69 6e 20 73 74 61 | ep.'...$stepNumber...'.is.in.sta |
92160 | 74 65 20 22 27 20 2e 20 24 73 74 65 70 53 74 61 74 65 20 2e 20 27 22 2e 27 29 3b 0a 0a 09 09 09 | te."'...$stepState...'".');..... |
92180 | 69 66 28 24 73 74 65 70 53 74 61 74 65 20 3d 3d 3d 20 27 73 74 61 72 74 27 29 20 7b 0a 09 09 09 | if($stepState.===.'start').{.... |
921a0 | 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 0a 09 09 09 09 09 73 70 72 69 6e 74 66 28 | .$output->writeln(......sprintf( |
921c0 | 0a 09 09 09 09 09 09 27 53 74 65 70 20 25 73 20 69 73 20 63 75 72 72 65 6e 74 6c 79 20 69 6e 20 | .......'Step.%s.is.currently.in. |
921e0 | 70 72 6f 63 65 73 73 2e 20 50 6c 65 61 73 65 20 63 61 6c 6c 20 74 68 69 73 20 63 6f 6d 6d 61 6e | process..Please.call.this.comman |
92200 | 64 20 6c 61 74 65 72 2e 27 2c 0a 09 09 09 09 09 09 24 73 74 65 70 4e 75 6d 62 65 72 0a 09 09 09 | d.later.',.......$stepNumber.... |
92220 | 09 09 29 0a 09 09 09 09 29 3b 0a 09 09 09 09 72 65 74 75 72 6e 20 2d 31 3b 0a 09 09 09 7d 0a 09 | ..).....);.....return.-1;....}.. |
92240 | 09 7d 0a 0a 09 09 24 74 68 69 73 2d 3e 75 70 64 61 74 65 72 2d 3e 6c 6f 67 56 65 72 73 69 6f 6e | .}....$this->updater->logVersion |
92260 | 28 29 3b 0a 0a 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 27 43 75 72 72 65 6e 74 | ();....$output->writeln('Current |
92280 | 20 76 65 72 73 69 6f 6e 20 69 73 20 27 20 2e 20 24 74 68 69 73 2d 3e 75 70 64 61 74 65 72 2d 3e | .version.is.'...$this->updater-> |
922a0 | 67 65 74 43 75 72 72 65 6e 74 56 65 72 73 69 6f 6e 28 29 20 2e 20 27 2e 27 29 3b 0a 0a 09 09 2f | getCurrentVersion()...'.');..../ |
922c0 | 2f 20 6e 65 65 64 73 20 74 6f 20 62 65 20 63 61 6c 6c 65 64 20 74 68 61 74 20 65 61 72 6c 79 20 | /.needs.to.be.called.that.early. |
922e0 | 62 65 63 61 75 73 65 20 6f 74 68 65 72 77 69 73 65 20 75 70 64 61 74 65 41 76 61 69 6c 61 62 6c | because.otherwise.updateAvailabl |
92300 | 65 28 29 20 72 65 74 75 72 6e 73 20 66 61 6c 73 65 0a 09 09 24 75 70 64 61 74 65 53 74 72 69 6e | e().returns.false...$updateStrin |
92320 | 67 20 3d 20 24 74 68 69 73 2d 3e 75 70 64 61 74 65 72 2d 3e 63 68 65 63 6b 46 6f 72 55 70 64 61 | g.=.$this->updater->checkForUpda |
92340 | 74 65 28 29 3b 0a 0a 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 27 27 29 3b 0a 0a | te();....$output->writeln('');.. |
92360 | 09 09 24 6c 69 6e 65 73 20 3d 20 65 78 70 6c 6f 64 65 28 27 3c 62 72 20 2f 3e 27 2c 20 24 75 70 | ..$lines.=.explode('<br./>',.$up |
92380 | 64 61 74 65 53 74 72 69 6e 67 29 3b 0a 0a 09 09 66 6f 72 65 61 63 68 20 28 24 6c 69 6e 65 73 20 | dateString);....foreach.($lines. |
923a0 | 61 73 20 24 6c 69 6e 65 29 20 7b 0a 09 09 09 2f 2f 20 73 74 72 69 70 20 48 54 4d 4c 0a 09 09 09 | as.$line).{....//.strip.HTML.... |
923c0 | 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 27 3c 69 6e 66 6f 3e 27 20 2e 20 70 72 65 67 | $output->writeln('<info>'...preg |
923e0 | 5f 72 65 70 6c 61 63 65 28 27 2f 3c 5b 5e 3e 5d 2a 3e 2f 27 2c 20 27 27 2c 20 24 6c 69 6e 65 29 | _replace('/<[^>]*>/',.'',.$line) |
92400 | 20 2e 20 27 3c 2f 69 6e 66 6f 3e 27 29 3b 0a 09 09 7d 0a 0a 09 09 24 6f 75 74 70 75 74 2d 3e 77 | ...'</info>');...}....$output->w |
92420 | 72 69 74 65 6c 6e 28 27 27 29 3b 0a 0a 09 09 69 66 28 21 24 74 68 69 73 2d 3e 75 70 64 61 74 65 | riteln('');....if(!$this->update |
92440 | 72 2d 3e 75 70 64 61 74 65 41 76 61 69 6c 61 62 6c 65 28 29 20 26 26 20 24 73 74 65 70 4e 75 6d | r->updateAvailable().&&.$stepNum |
92460 | 62 65 72 20 3d 3d 3d 20 30 29 20 7b 0a 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e | ber.===.0).{....$output->writeln |
92480 | 28 27 4e 6f 74 68 69 6e 67 20 74 6f 20 64 6f 2e 27 29 3b 0a 09 09 09 72 65 74 75 72 6e 20 30 3b | ('Nothing.to.do.');....return.0; |
924a0 | 0a 09 09 7d 0a 0a 09 09 24 71 75 65 73 74 69 6f 6e 54 65 78 74 20 3d 20 27 53 74 61 72 74 20 75 | ...}....$questionText.=.'Start.u |
924c0 | 70 64 61 74 65 27 3b 0a 09 09 69 66 20 28 24 73 74 65 70 4e 75 6d 62 65 72 20 3e 20 30 29 20 7b | pdate';...if.($stepNumber.>.0).{ |
924e0 | 0a 09 09 09 24 71 75 65 73 74 69 6f 6e 54 65 78 74 20 3d 20 27 43 6f 6e 74 69 6e 75 65 20 75 70 | ....$questionText.=.'Continue.up |
92500 | 64 61 74 65 27 3b 0a 09 09 7d 0a 0a 09 09 69 66 20 28 24 69 6e 70 75 74 2d 3e 69 73 49 6e 74 65 | date';...}....if.($input->isInte |
92520 | 72 61 63 74 69 76 65 28 29 29 20 7b 0a 0a 09 09 09 24 74 68 69 73 2d 3e 73 68 6f 77 43 75 72 72 | ractive()).{.....$this->showCurr |
92540 | 65 6e 74 53 74 61 74 75 73 28 24 6f 75 74 70 75 74 2c 20 24 73 74 65 70 4e 75 6d 62 65 72 29 3b | entStatus($output,.$stepNumber); |
92560 | 0a 0a 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 27 27 29 3b 0a 0a 09 09 09 24 | .....$output->writeln('');.....$ |
92580 | 68 65 6c 70 65 72 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 48 65 6c 70 65 72 28 27 71 75 65 73 74 | helper.=.$this->getHelper('quest |
925a0 | 69 6f 6e 27 29 3b 0a 09 09 09 24 71 75 65 73 74 69 6f 6e 20 3d 20 6e 65 77 20 43 6f 6e 66 69 72 | ion');....$question.=.new.Confir |
925c0 | 6d 61 74 69 6f 6e 51 75 65 73 74 69 6f 6e 28 24 71 75 65 73 74 69 6f 6e 54 65 78 74 20 2e 20 27 | mationQuestion($questionText...' |
925e0 | 3f 20 5b 79 2f 4e 5d 20 27 2c 20 66 61 6c 73 65 29 3b 0a 0a 09 09 09 69 66 20 28 21 24 68 65 6c | ?.[y/N].',.false);.....if.(!$hel |
92600 | 70 65 72 2d 3e 61 73 6b 28 24 69 6e 70 75 74 2c 20 24 6f 75 74 70 75 74 2c 20 24 71 75 65 73 74 | per->ask($input,.$output,.$quest |
92620 | 69 6f 6e 29 29 20 7b 0a 09 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 27 55 70 | ion)).{.....$output->writeln('Up |
92640 | 64 61 74 65 72 20 73 74 6f 70 70 65 64 2e 27 29 3b 0a 09 09 09 09 24 74 68 69 73 2d 3e 75 70 64 | dater.stopped.');.....$this->upd |
92660 | 61 74 65 72 2d 3e 6c 6f 67 28 27 5b 69 6e 66 6f 5d 20 75 70 64 61 74 65 72 20 73 74 6f 70 70 65 | ater->log('[info].updater.stoppe |
92680 | 64 27 29 3b 0a 09 09 09 09 72 65 74 75 72 6e 20 30 3b 0a 09 09 09 7d 0a 09 09 7d 20 65 6c 73 65 | d');.....return.0;....}...}.else |
926a0 | 20 7b 0a 09 09 09 24 74 68 69 73 2d 3e 75 70 64 61 74 65 72 2d 3e 6c 6f 67 28 27 5b 69 6e 66 6f | .{....$this->updater->log('[info |
926c0 | 5d 20 75 70 64 61 74 65 72 20 72 75 6e 20 69 6e 20 6e 6f 6e 2d 69 6e 74 65 72 61 63 74 69 76 65 | ].updater.run.in.non-interactive |
926e0 | 20 6d 6f 64 65 27 29 3b 0a 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 27 55 70 | .mode');....$output->writeln('Up |
92700 | 64 61 74 65 72 20 72 75 6e 20 69 6e 20 6e 6f 6e 2d 69 6e 74 65 72 61 63 74 69 76 65 20 6d 6f 64 | dater.run.in.non-interactive.mod |
92720 | 65 2e 27 29 3b 0a 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 27 27 29 3b 0a 09 | e.');....$output->writeln('');.. |
92740 | 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 24 71 75 65 73 74 69 6f 6e 54 65 78 74 | ..$output->writeln($questionText |
92760 | 29 3b 0a 09 09 7d 0a 09 09 24 74 68 69 73 2d 3e 75 70 64 61 74 65 72 2d 3e 6c 6f 67 28 27 5b 69 | );...}...$this->updater->log('[i |
92780 | 6e 66 6f 5d 20 75 70 64 61 74 65 72 20 73 74 61 72 74 65 64 27 29 3b 0a 0a 09 09 24 6f 75 74 70 | nfo].updater.started');....$outp |
927a0 | 75 74 2d 3e 77 72 69 74 65 6c 6e 28 27 27 29 3b 0a 0a 09 09 69 66 28 66 75 6e 63 74 69 6f 6e 5f | ut->writeln('');....if(function_ |
927c0 | 65 78 69 73 74 73 28 27 70 63 6e 74 6c 5f 73 69 67 6e 61 6c 27 29 29 20 7b 0a 09 09 09 2f 2f 20 | exists('pcntl_signal')).{....//. |
927e0 | 62 65 69 6e 67 20 61 62 6c 65 20 74 6f 20 68 61 6e 64 6c 65 20 73 74 6f 70 2f 74 65 72 6d 69 6e | being.able.to.handle.stop/termin |
92800 | 61 74 65 20 63 6f 6d 6d 61 6e 64 20 28 43 74 72 6c 20 2d 20 43 29 0a 09 09 09 70 63 6e 74 6c 5f | ate.command.(Ctrl.-.C)....pcntl_ |
92820 | 73 69 67 6e 61 6c 28 53 49 47 54 45 52 4d 2c 20 5b 24 74 68 69 73 2c 20 27 73 74 6f 70 43 6f 6d | signal(SIGTERM,.[$this,.'stopCom |
92840 | 6d 61 6e 64 27 5d 29 3b 0a 09 09 09 70 63 6e 74 6c 5f 73 69 67 6e 61 6c 28 53 49 47 49 4e 54 2c | mand']);....pcntl_signal(SIGINT, |
92860 | 20 5b 24 74 68 69 73 2c 20 27 73 74 6f 70 43 6f 6d 6d 61 6e 64 27 5d 29 3b 0a 0a 09 09 09 24 6f | .[$this,.'stopCommand']);.....$o |
92880 | 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 27 49 6e 66 6f 3a 20 50 72 65 73 73 69 6e 67 20 43 | utput->writeln('Info:.Pressing.C |
928a0 | 74 72 6c 2d 43 20 77 69 6c 6c 20 66 69 6e 69 73 68 20 74 68 65 20 63 75 72 72 65 6e 74 6c 79 20 | trl-C.will.finish.the.currently. |
928c0 | 72 75 6e 6e 69 6e 67 20 73 74 65 70 20 61 6e 64 20 74 68 65 6e 20 73 74 6f 70 73 20 74 68 65 20 | running.step.and.then.stops.the. |
928e0 | 75 70 64 61 74 65 72 2e 27 29 3b 0a 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 | updater.');....$output->writeln( |
92900 | 27 27 29 3b 0a 09 09 7d 20 65 6c 73 65 20 7b 0a 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 | '');...}.else.{....$output->writ |
92920 | 65 6c 6e 28 27 49 6e 66 6f 3a 20 47 72 61 63 65 66 75 6c 6c 79 20 73 74 6f 70 70 69 6e 67 20 74 | eln('Info:.Gracefully.stopping.t |
92940 | 68 65 20 75 70 64 61 74 65 72 20 76 69 61 20 43 74 72 6c 2d 43 20 69 73 20 6e 6f 74 20 70 6f 73 | he.updater.via.Ctrl-C.is.not.pos |
92960 | 73 69 62 6c 65 20 2d 20 50 43 4e 54 4c 20 65 78 74 65 6e 73 69 6f 6e 20 69 73 20 6e 6f 74 20 6c | sible.-.PCNTL.extension.is.not.l |
92980 | 6f 61 64 65 64 2e 27 29 3b 0a 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 27 27 | oaded.');....$output->writeln('' |
929a0 | 29 3b 0a 09 09 7d 0a 0a 09 09 2f 2f 20 70 72 69 6e 74 20 61 6c 72 65 61 64 79 20 65 78 65 63 75 | );...}....//.print.already.execu |
929c0 | 74 65 64 20 73 74 65 70 73 0a 09 09 66 6f 72 28 24 69 20 3d 20 31 3b 20 24 69 20 3c 3d 20 24 73 | ted.steps...for($i.=.1;.$i.<=.$s |
929e0 | 74 65 70 4e 75 6d 62 65 72 3b 20 24 69 2b 2b 29 20 7b 0a 09 09 09 69 66 20 28 24 69 20 3d 3d 3d | tepNumber;.$i++).{....if.($i.=== |
92a00 | 20 31 31 29 20 7b 0a 09 09 09 09 2f 2f 20 6e 6f 20 6e 65 65 64 20 74 6f 20 61 73 6b 20 66 6f 72 | .11).{.....//.no.need.to.ask.for |
92a20 | 20 6d 61 69 6e 74 65 6e 61 6e 63 65 20 6d 6f 64 65 20 6f 6e 20 43 4c 49 20 2d 20 73 6b 69 70 20 | .maintenance.mode.on.CLI.-.skip. |
92a40 | 69 74 0a 09 09 09 09 63 6f 6e 74 69 6e 75 65 3b 0a 09 09 09 7d 0a 09 09 09 24 6f 75 74 70 75 74 | it.....continue;....}....$output |
92a60 | 2d 3e 77 72 69 74 65 6c 6e 28 27 3c 69 6e 66 6f 3e 5b e2 9c 94 5d 20 27 20 2e 20 24 74 68 69 73 | ->writeln('<info>[...].'...$this |
92a80 | 2d 3e 63 68 65 63 6b 54 65 78 74 73 5b 24 69 5d 20 2e 20 27 3c 2f 69 6e 66 6f 3e 27 29 3b 0a 09 | ->checkTexts[$i]...'</info>');.. |
92aa0 | 09 7d 0a 0a 09 09 24 69 20 3d 20 24 73 74 65 70 4e 75 6d 62 65 72 3b 0a 09 09 77 68 69 6c 65 20 | .}....$i.=.$stepNumber;...while. |
92ac0 | 28 24 69 20 3c 20 31 32 29 20 7b 0a 09 09 09 24 69 2b 2b 3b 0a 0a 09 09 09 69 66 20 28 24 69 20 | ($i.<.12).{....$i++;.....if.($i. |
92ae0 | 3d 3d 3d 20 31 31 29 20 7b 0a 09 09 09 09 2f 2f 20 6e 6f 20 6e 65 65 64 20 74 6f 20 61 73 6b 20 | ===.11).{.....//.no.need.to.ask. |
92b00 | 66 6f 72 20 6d 61 69 6e 74 65 6e 61 6e 63 65 20 6d 6f 64 65 20 6f 6e 20 43 4c 49 20 2d 20 73 6b | for.maintenance.mode.on.CLI.-.sk |
92b20 | 69 70 20 69 74 0a 09 09 09 09 63 6f 6e 74 69 6e 75 65 3b 0a 09 09 09 7d 0a 0a 09 09 09 69 66 20 | ip.it.....continue;....}.....if. |
92b40 | 28 66 75 6e 63 74 69 6f 6e 5f 65 78 69 73 74 73 28 27 70 63 6e 74 6c 5f 73 69 67 6e 61 6c 5f 64 | (function_exists('pcntl_signal_d |
92b60 | 69 73 70 61 74 63 68 27 29 29 20 7b 0a 09 09 09 09 70 63 6e 74 6c 5f 73 69 67 6e 61 6c 5f 64 69 | ispatch')).{.....pcntl_signal_di |
92b80 | 73 70 61 74 63 68 28 29 3b 0a 09 09 09 09 69 66 20 28 20 24 74 68 69 73 2d 3e 73 68 6f 75 6c 64 | spatch();.....if.(.$this->should |
92ba0 | 53 74 6f 70 20 29 20 7b 0a 09 09 09 09 09 62 72 65 61 6b 3b 0a 09 09 09 09 7d 0a 09 09 09 7d 0a | Stop.).{......break;.....}....}. |
92bc0 | 0a 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 28 27 5b 20 5d 20 27 20 2e 20 24 74 68 69 | ....$output->write('[.].'...$thi |
92be0 | 73 2d 3e 63 68 65 63 6b 54 65 78 74 73 5b 24 69 5d 20 2e 20 27 20 2e 2e 2e 27 29 3b 0a 0a 09 09 | s->checkTexts[$i]...'....');.... |
92c00 | 09 24 72 65 73 75 6c 74 20 3d 20 24 74 68 69 73 2d 3e 65 78 65 63 75 74 65 53 74 65 70 28 24 69 | .$result.=.$this->executeStep($i |
92c20 | 29 3b 0a 0a 09 09 09 2f 2f 20 4d 6f 76 65 20 74 68 65 20 63 75 72 73 6f 72 20 74 6f 20 74 68 65 | );.....//.Move.the.cursor.to.the |
92c40 | 20 62 65 67 69 6e 6e 69 6e 67 20 6f 66 20 74 68 65 20 6c 69 6e 65 0a 09 09 09 24 6f 75 74 70 75 | .beginning.of.the.line....$outpu |
92c60 | 74 2d 3e 77 72 69 74 65 28 22 5c 78 30 44 22 29 3b 0a 0a 09 09 09 2f 2f 20 45 72 61 73 65 20 74 | t->write("\x0D");.....//.Erase.t |
92c80 | 68 65 20 6c 69 6e 65 0a 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 28 22 5c 78 31 42 5b | he.line....$output->write("\x1B[ |
92ca0 | 32 4b 22 29 3b 0a 0a 09 09 09 69 66 20 28 24 72 65 73 75 6c 74 5b 27 70 72 6f 63 65 65 64 27 5d | 2K");.....if.($result['proceed'] |
92cc0 | 20 3d 3d 3d 20 74 72 75 65 29 20 7b 0a 09 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c | .===.true).{.....$output->writel |
92ce0 | 6e 28 27 3c 69 6e 66 6f 3e 5b e2 9c 94 5d 20 27 20 2e 20 24 74 68 69 73 2d 3e 63 68 65 63 6b 54 | n('<info>[...].'...$this->checkT |
92d00 | 65 78 74 73 5b 24 69 5d 20 2e 20 27 3c 2f 69 6e 66 6f 3e 27 29 3b 0a 09 09 09 7d 20 65 6c 73 65 | exts[$i]...'</info>');....}.else |
92d20 | 20 7b 0a 09 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 27 3c 65 72 72 6f 72 3e | .{.....$output->writeln('<error> |
92d40 | 5b e2 9c 98 5d 20 27 20 2e 20 24 74 68 69 73 2d 3e 63 68 65 63 6b 54 65 78 74 73 5b 24 69 5d 20 | [...].'...$this->checkTexts[$i]. |
92d60 | 2e 20 27 20 66 61 69 6c 65 64 3c 2f 65 72 72 6f 72 3e 27 29 3b 0a 0a 09 09 09 09 69 66 20 28 24 | ..'.failed</error>');......if.($ |
92d80 | 69 20 3d 3d 3d 20 31 29 20 7b 0a 09 09 09 09 09 69 66 28 69 73 5f 73 74 72 69 6e 67 28 24 72 65 | i.===.1).{......if(is_string($re |
92da0 | 73 75 6c 74 5b 27 72 65 73 70 6f 6e 73 65 27 5d 29 29 20 7b 0a 09 09 09 09 09 09 24 6f 75 74 70 | sult['response'])).{.......$outp |
92dc0 | 75 74 2d 3e 77 72 69 74 65 6c 6e 28 27 3c 65 72 72 6f 72 3e 27 20 2e 20 24 72 65 73 75 6c 74 5b | ut->writeln('<error>'...$result[ |
92de0 | 27 72 65 73 70 6f 6e 73 65 27 5d 20 2e 20 27 3c 2f 65 72 72 6f 72 3e 27 29 3b 0a 09 09 09 09 09 | 'response']...'</error>');...... |
92e00 | 7d 20 65 6c 73 65 20 7b 0a 09 09 09 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 | }.else.{.......$output->writeln( |
92e20 | 27 3c 65 72 72 6f 72 3e 54 68 65 20 66 6f 6c 6c 6f 77 69 6e 67 20 65 78 74 72 61 20 66 69 6c 65 | '<error>The.following.extra.file |
92e40 | 73 20 68 61 76 65 20 62 65 65 6e 20 66 6f 75 6e 64 3a 3c 2f 65 72 72 6f 72 3e 27 29 3b 0a 09 09 | s.have.been.found:</error>');... |
92e60 | 09 09 09 09 66 6f 72 65 61 63 68 20 28 24 72 65 73 75 6c 74 5b 27 72 65 73 70 6f 6e 73 65 27 5d | ....foreach.($result['response'] |
92e80 | 20 61 73 20 24 66 69 6c 65 29 20 7b 0a 09 09 09 09 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 | .as.$file).{........$output->wri |
92ea0 | 74 65 6c 6e 28 27 3c 65 72 72 6f 72 3e 20 20 20 20 27 20 2e 20 24 66 69 6c 65 20 2e 20 27 3c 2f | teln('<error>....'...$file...'</ |
92ec0 | 65 72 72 6f 72 3e 27 29 3b 0a 09 09 09 09 09 09 7d 0a 09 09 09 09 09 7d 0a 09 09 09 09 7d 20 65 | error>');.......}......}.....}.e |
92ee0 | 6c 73 65 69 66 20 28 24 69 20 3d 3d 3d 20 32 29 20 7b 0a 09 09 09 09 09 69 66 28 69 73 5f 73 74 | lseif.($i.===.2).{......if(is_st |
92f00 | 72 69 6e 67 28 24 72 65 73 75 6c 74 5b 27 72 65 73 70 6f 6e 73 65 27 5d 29 29 20 7b 0a 09 09 09 | ring($result['response'])).{.... |
92f20 | 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 27 3c 65 72 72 6f 72 3e 27 20 2e 20 | ...$output->writeln('<error>'... |
92f40 | 24 72 65 73 75 6c 74 5b 27 72 65 73 70 6f 6e 73 65 27 5d 20 2e 20 27 3c 2f 65 72 72 6f 72 3e 27 | $result['response']...'</error>' |
92f60 | 29 3b 0a 09 09 09 09 09 7d 20 65 6c 73 65 20 7b 0a 09 09 09 09 09 09 24 6f 75 74 70 75 74 2d 3e | );......}.else.{.......$output-> |
92f80 | 77 72 69 74 65 6c 6e 28 27 3c 65 72 72 6f 72 3e 54 68 65 20 66 6f 6c 6c 6f 77 69 6e 67 20 70 6c | writeln('<error>The.following.pl |
92fa0 | 61 63 65 73 20 63 61 6e 20 6e 6f 74 20 62 65 20 77 72 69 74 74 65 6e 20 74 6f 3a 3c 2f 65 72 72 | aces.can.not.be.written.to:</err |
92fc0 | 6f 72 3e 27 29 3b 0a 09 09 09 09 09 09 66 6f 72 65 61 63 68 20 28 24 72 65 73 75 6c 74 5b 27 72 | or>');.......foreach.($result['r |
92fe0 | 65 73 70 6f 6e 73 65 27 5d 20 61 73 20 24 66 69 6c 65 29 20 7b 0a 09 09 09 09 09 09 09 24 6f 75 | esponse'].as.$file).{........$ou |
93000 | 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 27 3c 65 72 72 6f 72 3e 20 20 20 20 27 20 2e 20 24 66 | tput->writeln('<error>....'...$f |
93020 | 69 6c 65 20 2e 20 27 3c 2f 65 72 72 6f 72 3e 27 29 3b 0a 09 09 09 09 09 09 7d 0a 09 09 09 09 09 | ile...'</error>');.......}...... |
93040 | 7d 0a 09 09 09 09 7d 20 65 6c 73 65 20 7b 0a 09 09 09 09 09 69 66 20 28 69 73 5f 73 74 72 69 6e | }.....}.else.{......if.(is_strin |
93060 | 67 28 24 72 65 73 75 6c 74 5b 27 72 65 73 70 6f 6e 73 65 27 5d 29 29 20 7b 0a 09 09 09 09 09 09 | g($result['response'])).{....... |
93080 | 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 27 3c 65 72 72 6f 72 3e 27 20 2e 20 24 72 65 | $output->writeln('<error>'...$re |
930a0 | 73 75 6c 74 5b 27 72 65 73 70 6f 6e 73 65 27 5d 20 2e 20 20 27 3c 2f 65 72 72 6f 72 3e 27 29 3b | sult['response']....'</error>'); |
930c0 | 0a 09 09 09 09 09 7d 20 65 6c 73 65 20 7b 0a 09 09 09 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 | ......}.else.{.......$output->wr |
930e0 | 69 74 65 6c 6e 28 27 3c 65 72 72 6f 72 3e 53 6f 6d 65 74 68 69 6e 67 20 68 61 73 20 67 6f 6e 65 | iteln('<error>Something.has.gone |
93100 | 20 77 72 6f 6e 67 2e 20 50 6c 65 61 73 65 20 63 68 65 63 6b 20 74 68 65 20 6c 6f 67 20 66 69 6c | .wrong..Please.check.the.log.fil |
93120 | 65 20 69 6e 20 74 68 65 20 64 61 74 61 20 64 69 72 2e 3c 2f 65 72 72 6f 72 3e 27 29 3b 0a 09 09 | e.in.the.data.dir.</error>');... |
93140 | 09 09 09 7d 0a 09 09 09 09 7d 0a 09 09 09 09 62 72 65 61 6b 3b 0a 09 09 09 7d 0a 09 09 7d 0a 0a | ...}.....}.....break;....}...}.. |
93160 | 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 27 27 29 3b 0a 09 09 69 66 20 28 24 69 | ..$output->writeln('');...if.($i |
93180 | 20 3d 3d 3d 20 31 32 29 20 7b 0a 09 09 09 24 74 68 69 73 2d 3e 75 70 64 61 74 65 72 2d 3e 6c 6f | .===.12).{....$this->updater->lo |
931a0 | 67 28 27 5b 69 6e 66 6f 5d 20 75 70 64 61 74 65 20 6f 66 20 63 6f 64 65 20 73 75 63 63 65 73 73 | g('[info].update.of.code.success |
931c0 | 66 75 6c 2e 27 29 3b 0a 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 27 55 70 64 | ful.');....$output->writeln('Upd |
931e0 | 61 74 65 20 6f 66 20 63 6f 64 65 20 73 75 63 63 65 73 73 66 75 6c 2e 27 29 3b 0a 0a 09 09 09 69 | ate.of.code.successful.');.....i |
93200 | 66 20 28 24 69 6e 70 75 74 2d 3e 69 73 49 6e 74 65 72 61 63 74 69 76 65 28 29 29 20 7b 0a 0a 09 | f.($input->isInteractive()).{... |
93220 | 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 27 27 29 3b 0a 0a 09 09 09 09 24 68 | ...$output->writeln('');......$h |
93240 | 65 6c 70 65 72 20 3d 20 24 74 68 69 73 2d 3e 67 65 74 48 65 6c 70 65 72 28 27 71 75 65 73 74 69 | elper.=.$this->getHelper('questi |
93260 | 6f 6e 27 29 3b 0a 09 09 09 09 24 71 75 65 73 74 69 6f 6e 20 3d 20 6e 65 77 20 43 6f 6e 66 69 72 | on');.....$question.=.new.Confir |
93280 | 6d 61 74 69 6f 6e 51 75 65 73 74 69 6f 6e 28 27 53 68 6f 75 6c 64 20 74 68 65 20 22 6f 63 63 20 | mationQuestion('Should.the."occ. |
932a0 | 75 70 67 72 61 64 65 22 20 63 6f 6d 6d 61 6e 64 20 62 65 20 65 78 65 63 75 74 65 64 3f 20 5b 59 | upgrade".command.be.executed?.[Y |
932c0 | 2f 6e 5d 20 27 2c 20 74 72 75 65 29 3b 0a 0a 09 09 09 09 69 66 20 28 21 24 68 65 6c 70 65 72 2d | /n].',.true);......if.(!$helper- |
932e0 | 3e 61 73 6b 28 24 69 6e 70 75 74 2c 20 24 6f 75 74 70 75 74 2c 20 24 71 75 65 73 74 69 6f 6e 29 | >ask($input,.$output,.$question) |
93300 | 29 20 7b 0a 09 09 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 27 50 6c 65 61 73 | ).{......$output->writeln('Pleas |
93320 | 65 20 6e 6f 77 20 65 78 65 63 75 74 65 20 22 2e 2f 6f 63 63 20 75 70 67 72 61 64 65 22 20 74 6f | e.now.execute."./occ.upgrade".to |
93340 | 20 66 69 6e 69 73 68 20 74 68 65 20 75 70 67 72 61 64 65 2e 27 29 3b 0a 09 09 09 09 09 24 74 68 | .finish.the.upgrade.');......$th |
93360 | 69 73 2d 3e 75 70 64 61 74 65 72 2d 3e 6c 6f 67 28 27 5b 69 6e 66 6f 5d 20 75 70 64 61 74 65 72 | is->updater->log('[info].updater |
93380 | 20 66 69 6e 69 73 68 65 64 27 29 3b 0a 09 09 09 09 09 72 65 74 75 72 6e 20 30 3b 0a 09 09 09 09 | .finished');......return.0;..... |
933a0 | 7d 0a 09 09 09 7d 20 65 6c 73 65 20 7b 0a 09 09 09 09 24 74 68 69 73 2d 3e 75 70 64 61 74 65 72 | }....}.else.{.....$this->updater |
933c0 | 2d 3e 6c 6f 67 28 27 5b 69 6e 66 6f 5d 20 75 70 64 61 74 65 72 20 72 75 6e 20 69 6e 20 6e 6f 6e | ->log('[info].updater.run.in.non |
933e0 | 2d 69 6e 74 65 72 61 63 74 69 76 65 20 6d 6f 64 65 20 2d 20 6f 63 63 20 75 70 67 72 61 64 65 20 | -interactive.mode.-.occ.upgrade. |
93400 | 69 73 20 73 74 61 72 74 65 64 27 29 3b 0a 09 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 | is.started');.....$output->write |
93420 | 6c 6e 28 27 55 70 64 61 74 65 72 20 72 75 6e 20 69 6e 20 6e 6f 6e 2d 69 6e 74 65 72 61 63 74 69 | ln('Updater.run.in.non-interacti |
93440 | 76 65 20 6d 6f 64 65 20 2d 20 77 69 6c 6c 20 73 74 61 72 74 20 22 6f 63 63 20 75 70 67 72 61 64 | ve.mode.-.will.start."occ.upgrad |
93460 | 65 22 20 6e 6f 77 2e 27 29 3b 0a 09 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 | e".now.');.....$output->writeln( |
93480 | 27 27 29 3b 0a 09 09 09 7d 0a 0a 09 09 09 63 68 64 69 72 28 24 70 61 74 68 20 2e 20 27 2f 2e 2e | '');....}.....chdir($path...'/.. |
934a0 | 27 29 3b 0a 09 09 09 63 68 6d 6f 64 28 27 6f 63 63 27 2c 20 30 37 35 35 29 3b 20 23 20 54 4f 44 | ');....chmod('occ',.0755);.#.TOD |
934c0 | 4f 20 64 6f 20 74 68 69 73 20 69 6e 20 74 68 65 20 75 70 64 61 74 65 72 0a 09 09 09 73 79 73 74 | O.do.this.in.the.updater....syst |
934e0 | 65 6d 28 50 48 50 5f 42 49 4e 41 52 59 20 2e 20 27 20 2e 2f 6f 63 63 20 75 70 67 72 61 64 65 20 | em(PHP_BINARY...'../occ.upgrade. |
93500 | 2d 76 27 2c 20 24 72 65 74 75 72 6e 56 61 6c 75 65 29 3b 0a 0a 09 09 09 24 6f 75 74 70 75 74 2d | -v',.$returnValue);.....$output- |
93520 | 3e 77 72 69 74 65 6c 6e 28 27 27 29 3b 0a 09 09 09 69 66 20 28 24 69 6e 70 75 74 2d 3e 69 73 49 | >writeln('');....if.($input->isI |
93540 | 6e 74 65 72 61 63 74 69 76 65 28 29 29 20 7b 0a 0a 09 09 09 09 24 68 65 6c 70 65 72 20 3d 20 24 | nteractive()).{......$helper.=.$ |
93560 | 74 68 69 73 2d 3e 67 65 74 48 65 6c 70 65 72 28 27 71 75 65 73 74 69 6f 6e 27 29 3b 0a 09 09 09 | this->getHelper('question');.... |
93580 | 09 24 71 75 65 73 74 69 6f 6e 20 3d 20 6e 65 77 20 43 6f 6e 66 69 72 6d 61 74 69 6f 6e 51 75 65 | .$question.=.new.ConfirmationQue |
935a0 | 73 74 69 6f 6e 28 24 74 68 69 73 2d 3e 63 68 65 63 6b 54 65 78 74 73 5b 31 31 5d 20 2e 20 27 20 | stion($this->checkTexts[11]...'. |
935c0 | 5b 79 2f 4e 5d 20 27 2c 20 66 61 6c 73 65 29 3b 0a 0a 09 09 09 09 69 66 20 28 24 68 65 6c 70 65 | [y/N].',.false);......if.($helpe |
935e0 | 72 2d 3e 61 73 6b 28 24 69 6e 70 75 74 2c 20 24 6f 75 74 70 75 74 2c 20 24 71 75 65 73 74 69 6f | r->ask($input,.$output,.$questio |
93600 | 6e 29 29 20 7b 0a 09 09 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 27 4d 61 69 | n)).{......$output->writeln('Mai |
93620 | 6e 74 65 6e 61 6e 63 65 20 6d 6f 64 65 20 6b 65 70 74 20 61 63 74 69 76 65 27 29 3b 0a 09 09 09 | ntenance.mode.kept.active');.... |
93640 | 09 09 24 74 68 69 73 2d 3e 75 70 64 61 74 65 72 2d 3e 6c 6f 67 28 27 5b 69 6e 66 6f 5d 20 75 70 | ..$this->updater->log('[info].up |
93660 | 64 61 74 65 72 20 66 69 6e 69 73 68 65 64 20 2d 20 6d 61 69 6e 74 65 6e 61 6e 63 65 20 6d 6f 64 | dater.finished.-.maintenance.mod |
93680 | 65 20 6b 65 70 74 20 61 63 74 69 76 65 27 29 3b 0a 09 09 09 09 09 72 65 74 75 72 6e 20 24 72 65 | e.kept.active');......return.$re |
936a0 | 74 75 72 6e 56 61 6c 75 65 3b 0a 09 09 09 09 7d 0a 09 09 09 7d 20 65 6c 73 65 20 7b 0a 09 09 09 | turnValue;.....}....}.else.{.... |
936c0 | 09 24 74 68 69 73 2d 3e 75 70 64 61 74 65 72 2d 3e 6c 6f 67 28 27 5b 69 6e 66 6f 5d 20 75 70 64 | .$this->updater->log('[info].upd |
936e0 | 61 74 65 72 20 72 75 6e 20 69 6e 20 6e 6f 6e 2d 69 6e 74 65 72 61 63 74 69 76 65 20 6d 6f 64 65 | ater.run.in.non-interactive.mode |
93700 | 20 2d 20 64 69 73 61 62 6c 69 6e 67 20 6d 61 69 6e 74 65 6e 61 6e 63 65 20 6d 6f 64 65 27 29 3b | .-.disabling.maintenance.mode'); |
93720 | 0a 09 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 27 55 70 64 61 74 65 72 20 72 | .....$output->writeln('Updater.r |
93740 | 75 6e 20 69 6e 20 6e 6f 6e 2d 69 6e 74 65 72 61 63 74 69 76 65 20 6d 6f 64 65 20 2d 20 77 69 6c | un.in.non-interactive.mode.-.wil |
93760 | 6c 20 64 69 73 61 62 6c 65 20 6d 61 69 6e 74 65 6e 61 6e 63 65 20 6d 6f 64 65 20 6e 6f 77 2e 27 | l.disable.maintenance.mode.now.' |
93780 | 29 3b 0a 09 09 09 7d 0a 0a 09 09 09 74 72 79 20 7b 0a 09 09 09 09 73 79 73 74 65 6d 28 50 48 50 | );....}.....try.{.....system(PHP |
937a0 | 5f 42 49 4e 41 52 59 20 2e 20 27 20 2e 2f 6f 63 63 20 6d 61 69 6e 74 65 6e 61 6e 63 65 3a 6d 6f | _BINARY...'../occ.maintenance:mo |
937c0 | 64 65 20 2d 2d 6f 66 66 27 2c 20 24 72 65 74 75 72 6e 56 61 6c 75 65 4d 61 69 6e 74 65 6e 61 6e | de.--off',.$returnValueMaintenan |
937e0 | 63 65 4d 6f 64 65 29 3b 0a 09 09 09 09 24 74 68 69 73 2d 3e 75 70 64 61 74 65 72 2d 3e 6c 6f 67 | ceMode);.....$this->updater->log |
93800 | 28 27 5b 69 6e 66 6f 5d 20 6d 61 69 6e 74 65 6e 61 6e 63 65 20 6d 6f 64 65 20 69 73 20 64 69 73 | ('[info].maintenance.mode.is.dis |
93820 | 61 62 6c 65 64 20 2d 20 72 65 74 75 72 6e 20 63 6f 64 65 3a 20 27 20 2e 20 24 72 65 74 75 72 6e | abled.-.return.code:.'...$return |
93840 | 56 61 6c 75 65 4d 61 69 6e 74 65 6e 61 6e 63 65 4d 6f 64 65 29 3b 0a 09 09 09 09 24 6f 75 74 70 | ValueMaintenanceMode);.....$outp |
93860 | 75 74 2d 3e 77 72 69 74 65 6c 6e 28 27 27 29 3b 0a 09 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 | ut->writeln('');.....$output->wr |
93880 | 69 74 65 6c 6e 28 27 4d 61 69 6e 74 65 6e 61 6e 63 65 20 6d 6f 64 65 20 69 73 20 64 69 73 61 62 | iteln('Maintenance.mode.is.disab |
938a0 | 6c 65 64 27 29 3b 0a 09 09 09 7d 20 63 61 74 63 68 20 28 5c 45 78 63 65 70 74 69 6f 6e 20 24 65 | led');....}.catch.(\Exception.$e |
938c0 | 29 20 7b 0a 09 09 09 09 24 74 68 69 73 2d 3e 75 70 64 61 74 65 72 2d 3e 6c 6f 67 28 27 5b 69 6e | ).{.....$this->updater->log('[in |
938e0 | 66 6f 5d 20 6d 61 69 6e 74 65 6e 61 6e 63 65 20 6d 6f 64 65 20 63 61 6e 20 6e 6f 74 20 62 65 20 | fo].maintenance.mode.can.not.be. |
93900 | 64 69 73 61 62 6c 65 64 27 29 3b 0a 09 09 09 09 24 74 68 69 73 2d 3e 75 70 64 61 74 65 72 2d 3e | disabled');.....$this->updater-> |
93920 | 6c 6f 67 45 78 63 65 70 74 69 6f 6e 28 24 65 29 3b 0a 09 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 | logException($e);.....$output->w |
93940 | 72 69 74 65 6c 6e 28 27 27 29 3b 0a 09 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e | riteln('');.....$output->writeln |
93960 | 28 27 4d 61 69 6e 74 65 6e 61 6e 63 65 20 6d 6f 64 65 20 63 61 6e 20 6e 6f 74 20 62 65 20 64 69 | ('Maintenance.mode.can.not.be.di |
93980 | 73 61 62 6c 65 64 27 29 3b 0a 09 09 09 7d 0a 0a 09 09 09 72 65 74 75 72 6e 20 24 72 65 74 75 72 | sabled');....}.....return.$retur |
939a0 | 6e 56 61 6c 75 65 3b 0a 09 09 7d 20 65 6c 73 65 20 7b 0a 09 09 09 69 66 20 28 24 74 68 69 73 2d | nValue;...}.else.{....if.($this- |
939c0 | 3e 73 68 6f 75 6c 64 53 74 6f 70 29 20 7b 0a 09 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 | >shouldStop).{.....$output->writ |
939e0 | 65 6c 6e 28 27 3c 65 72 72 6f 72 3e 55 70 64 61 74 65 20 73 74 6f 70 70 65 64 2e 20 54 6f 20 72 | eln('<error>Update.stopped..To.r |
93a00 | 65 73 75 6d 65 20 6f 72 20 72 65 74 72 79 20 6a 75 73 74 20 65 78 65 63 75 74 65 20 74 68 65 20 | esume.or.retry.just.execute.the. |
93a20 | 75 70 64 61 74 65 72 20 61 67 61 69 6e 2e 3c 2f 65 72 72 6f 72 3e 27 29 3b 0a 09 09 09 7d 20 65 | updater.again.</error>');....}.e |
93a40 | 6c 73 65 20 7b 0a 09 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e 28 27 3c 65 72 72 | lse.{.....$output->writeln('<err |
93a60 | 6f 72 3e 55 70 64 61 74 65 20 66 61 69 6c 65 64 2e 20 54 6f 20 72 65 73 75 6d 65 20 6f 72 20 72 | or>Update.failed..To.resume.or.r |
93a80 | 65 74 72 79 20 6a 75 73 74 20 65 78 65 63 75 74 65 20 74 68 65 20 75 70 64 61 74 65 72 20 61 67 | etry.just.execute.the.updater.ag |
93aa0 | 61 69 6e 2e 3c 2f 65 72 72 6f 72 3e 27 29 3b 0a 09 09 09 7d 0a 09 09 09 72 65 74 75 72 6e 20 2d | ain.</error>');....}....return.- |
93ac0 | 31 3b 0a 09 09 7d 0a 20 20 20 20 7d 0a 0a 09 2f 2a 2a 0a 09 20 2a 20 40 70 61 72 61 6d 20 24 73 | 1;...}.....}.../**...*.@param.$s |
93ae0 | 74 65 70 20 69 6e 74 65 67 65 72 0a 09 20 2a 20 40 72 65 74 75 72 6e 20 61 72 72 61 79 20 77 69 | tep.integer...*.@return.array.wi |
93b00 | 74 68 20 6f 70 74 69 6f 6e 73 20 27 70 72 6f 63 65 65 64 27 20 77 68 69 63 68 20 69 73 20 61 20 | th.options.'proceed'.which.is.a. |
93b20 | 62 6f 6f 6c 65 61 6e 20 61 6e 64 20 64 65 66 69 6e 65 73 20 69 66 20 74 68 65 20 73 74 65 70 20 | boolean.and.defines.if.the.step. |
93b40 | 73 75 63 63 65 65 64 65 64 20 61 6e 64 20 61 6e 20 6f 70 74 69 6f 6e 61 6c 20 27 72 65 73 70 6f | succeeded.and.an.optional.'respo |
93b60 | 6e 73 65 27 20 73 74 72 69 6e 67 0a 09 20 2a 2f 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 66 | nse'.string...*/.....protected.f |
93b80 | 75 6e 63 74 69 6f 6e 20 65 78 65 63 75 74 65 53 74 65 70 28 24 73 74 65 70 29 20 7b 0a 09 09 24 | unction.executeStep($step).{...$ |
93ba0 | 74 68 69 73 2d 3e 75 70 64 61 74 65 72 2d 3e 6c 6f 67 28 27 5b 69 6e 66 6f 5d 20 65 78 65 63 75 | this->updater->log('[info].execu |
93bc0 | 74 65 53 74 65 70 20 72 65 71 75 65 73 74 20 66 6f 72 20 73 74 65 70 20 22 27 20 2e 20 24 73 74 | teStep.request.for.step."'...$st |
93be0 | 65 70 20 2e 20 27 22 27 29 3b 0a 09 09 74 72 79 20 7b 0a 09 09 09 69 66 28 24 73 74 65 70 20 3e | ep...'"');...try.{....if($step.> |
93c00 | 20 31 32 20 7c 7c 20 24 73 74 65 70 20 3c 20 31 29 20 7b 0a 09 09 09 09 74 68 72 6f 77 20 6e 65 | .12.||.$step.<.1).{.....throw.ne |
93c20 | 77 20 5c 45 78 63 65 70 74 69 6f 6e 28 27 49 6e 76 61 6c 69 64 20 73 74 65 70 27 29 3b 0a 09 09 | w.\Exception('Invalid.step');... |
93c40 | 09 7d 0a 0a 09 09 09 24 74 68 69 73 2d 3e 75 70 64 61 74 65 72 2d 3e 73 74 61 72 74 53 74 65 70 | .}.....$this->updater->startStep |
93c60 | 28 24 73 74 65 70 29 3b 0a 09 09 09 73 77 69 74 63 68 20 28 24 73 74 65 70 29 20 7b 0a 09 09 09 | ($step);....switch.($step).{.... |
93c80 | 09 63 61 73 65 20 31 3a 0a 09 09 09 09 09 24 74 68 69 73 2d 3e 75 70 64 61 74 65 72 2d 3e 63 68 | .case.1:......$this->updater->ch |
93ca0 | 65 63 6b 46 6f 72 45 78 70 65 63 74 65 64 46 69 6c 65 73 41 6e 64 46 6f 6c 64 65 72 73 28 29 3b | eckForExpectedFilesAndFolders(); |
93cc0 | 0a 09 09 09 09 09 62 72 65 61 6b 3b 0a 09 09 09 09 63 61 73 65 20 32 3a 0a 09 09 09 09 09 24 74 | ......break;.....case.2:......$t |
93ce0 | 68 69 73 2d 3e 75 70 64 61 74 65 72 2d 3e 63 68 65 63 6b 57 72 69 74 65 50 65 72 6d 69 73 73 69 | his->updater->checkWritePermissi |
93d00 | 6f 6e 73 28 29 3b 0a 09 09 09 09 09 62 72 65 61 6b 3b 0a 09 09 09 09 63 61 73 65 20 33 3a 0a 09 | ons();......break;.....case.3:.. |
93d20 | 09 09 09 09 69 66 20 28 24 74 68 69 73 2d 3e 73 6b 69 70 42 61 63 6b 75 70 20 3d 3d 3d 20 66 61 | ....if.($this->skipBackup.===.fa |
93d40 | 6c 73 65 29 20 7b 0a 09 09 09 09 09 09 24 74 68 69 73 2d 3e 75 70 64 61 74 65 72 2d 3e 63 72 65 | lse).{.......$this->updater->cre |
93d60 | 61 74 65 42 61 63 6b 75 70 28 29 3b 0a 09 09 09 09 09 7d 0a 09 09 09 09 09 62 72 65 61 6b 3b 0a | ateBackup();......}......break;. |
93d80 | 09 09 09 09 63 61 73 65 20 34 3a 0a 09 09 09 09 09 24 74 68 69 73 2d 3e 75 70 64 61 74 65 72 2d | ....case.4:......$this->updater- |
93da0 | 3e 64 6f 77 6e 6c 6f 61 64 55 70 64 61 74 65 28 29 3b 0a 09 09 09 09 09 62 72 65 61 6b 3b 0a 09 | >downloadUpdate();......break;.. |
93dc0 | 09 09 09 63 61 73 65 20 35 3a 0a 09 09 09 09 09 24 74 68 69 73 2d 3e 75 70 64 61 74 65 72 2d 3e | ...case.5:......$this->updater-> |
93de0 | 76 65 72 69 66 79 49 6e 74 65 67 72 69 74 79 28 29 3b 0a 09 09 09 09 09 62 72 65 61 6b 3b 0a 09 | verifyIntegrity();......break;.. |
93e00 | 09 09 09 63 61 73 65 20 36 3a 0a 09 09 09 09 09 24 74 68 69 73 2d 3e 75 70 64 61 74 65 72 2d 3e | ...case.6:......$this->updater-> |
93e20 | 65 78 74 72 61 63 74 44 6f 77 6e 6c 6f 61 64 28 29 3b 0a 09 09 09 09 09 62 72 65 61 6b 3b 0a 09 | extractDownload();......break;.. |
93e40 | 09 09 09 63 61 73 65 20 37 3a 0a 09 09 09 09 09 24 74 68 69 73 2d 3e 75 70 64 61 74 65 72 2d 3e | ...case.7:......$this->updater-> |
93e60 | 73 65 74 4d 61 69 6e 74 65 6e 61 6e 63 65 4d 6f 64 65 28 74 72 75 65 29 3b 0a 09 09 09 09 09 62 | setMaintenanceMode(true);......b |
93e80 | 72 65 61 6b 3b 0a 09 09 09 09 63 61 73 65 20 38 3a 0a 09 09 09 09 09 24 74 68 69 73 2d 3e 75 70 | reak;.....case.8:......$this->up |
93ea0 | 64 61 74 65 72 2d 3e 72 65 70 6c 61 63 65 45 6e 74 72 79 50 6f 69 6e 74 73 28 29 3b 0a 09 09 09 | dater->replaceEntryPoints();.... |
93ec0 | 09 09 62 72 65 61 6b 3b 0a 09 09 09 09 63 61 73 65 20 39 3a 0a 09 09 09 09 09 24 74 68 69 73 2d | ..break;.....case.9:......$this- |
93ee0 | 3e 75 70 64 61 74 65 72 2d 3e 64 65 6c 65 74 65 4f 6c 64 46 69 6c 65 73 28 29 3b 0a 09 09 09 09 | >updater->deleteOldFiles();..... |
93f00 | 09 62 72 65 61 6b 3b 0a 09 09 09 09 63 61 73 65 20 31 30 3a 0a 09 09 09 09 09 24 74 68 69 73 2d | .break;.....case.10:......$this- |
93f20 | 3e 75 70 64 61 74 65 72 2d 3e 6d 6f 76 65 4e 65 77 56 65 72 73 69 6f 6e 49 6e 50 6c 61 63 65 28 | >updater->moveNewVersionInPlace( |
93f40 | 29 3b 0a 09 09 09 09 09 62 72 65 61 6b 3b 0a 09 09 09 09 63 61 73 65 20 31 31 3a 0a 09 09 09 09 | );......break;.....case.11:..... |
93f60 | 09 2f 2f 20 74 68 69 73 20 69 73 20 6e 6f 74 20 6e 65 65 64 65 64 20 69 6e 20 74 68 65 20 43 4c | .//.this.is.not.needed.in.the.CL |
93f80 | 49 20 75 70 64 61 74 65 72 0a 09 09 09 09 09 2f 2f 24 74 68 69 73 2d 3e 75 70 64 61 74 65 72 2d | I.updater......//$this->updater- |
93fa0 | 3e 73 65 74 4d 61 69 6e 74 65 6e 61 6e 63 65 4d 6f 64 65 28 66 61 6c 73 65 29 3b 0a 09 09 09 09 | >setMaintenanceMode(false);..... |
93fc0 | 09 62 72 65 61 6b 3b 0a 09 09 09 09 63 61 73 65 20 31 32 3a 0a 09 09 09 09 09 24 74 68 69 73 2d | .break;.....case.12:......$this- |
93fe0 | 3e 75 70 64 61 74 65 72 2d 3e 66 69 6e 61 6c 69 7a 65 28 29 3b 0a 09 09 09 09 09 62 72 65 61 6b | >updater->finalize();......break |
94000 | 3b 0a 09 09 09 7d 0a 09 09 09 24 74 68 69 73 2d 3e 75 70 64 61 74 65 72 2d 3e 65 6e 64 53 74 65 | ;....}....$this->updater->endSte |
94020 | 70 28 24 73 74 65 70 29 3b 0a 09 09 09 72 65 74 75 72 6e 20 5b 27 70 72 6f 63 65 65 64 27 20 3d | p($step);....return.['proceed'.= |
94040 | 3e 20 74 72 75 65 5d 3b 0a 09 09 7d 20 63 61 74 63 68 20 28 55 70 64 61 74 65 45 78 63 65 70 74 | >.true];...}.catch.(UpdateExcept |
94060 | 69 6f 6e 20 24 65 29 20 7b 0a 09 09 09 24 6d 65 73 73 61 67 65 20 3d 20 24 65 2d 3e 67 65 74 44 | ion.$e).{....$message.=.$e->getD |
94080 | 61 74 61 28 29 3b 0a 0a 09 09 09 74 72 79 20 7b 0a 09 09 09 09 24 74 68 69 73 2d 3e 75 70 64 61 | ata();.....try.{.....$this->upda |
940a0 | 74 65 72 2d 3e 6c 6f 67 28 27 5b 65 72 72 6f 72 5d 20 65 78 65 63 75 74 65 53 74 65 70 20 72 65 | ter->log('[error].executeStep.re |
940c0 | 71 75 65 73 74 20 66 61 69 6c 65 64 20 77 69 74 68 20 55 70 64 61 74 65 45 78 63 65 70 74 69 6f | quest.failed.with.UpdateExceptio |
940e0 | 6e 27 29 3b 0a 09 09 09 09 24 74 68 69 73 2d 3e 75 70 64 61 74 65 72 2d 3e 6c 6f 67 45 78 63 65 | n');.....$this->updater->logExce |
94100 | 70 74 69 6f 6e 28 24 65 29 3b 0a 09 09 09 7d 20 63 61 74 63 68 20 28 4c 6f 67 45 78 63 65 70 74 | ption($e);....}.catch.(LogExcept |
94120 | 69 6f 6e 20 24 6c 6f 67 45 29 20 7b 0a 09 09 09 09 24 6d 65 73 73 61 67 65 20 2e 3d 20 27 20 28 | ion.$logE).{.....$message..=.'.( |
94140 | 61 6e 64 20 77 72 69 74 69 6e 67 20 74 6f 20 6c 6f 67 20 66 61 69 6c 65 64 20 61 6c 73 6f 20 77 | and.writing.to.log.failed.also.w |
94160 | 69 74 68 3a 20 27 20 2e 20 24 6c 6f 67 45 2d 3e 67 65 74 4d 65 73 73 61 67 65 28 29 20 2e 20 27 | ith:.'...$logE->getMessage()...' |
94180 | 29 27 3b 0a 09 09 09 7d 0a 0a 09 09 09 24 74 68 69 73 2d 3e 75 70 64 61 74 65 72 2d 3e 72 6f 6c | )';....}.....$this->updater->rol |
941a0 | 6c 62 61 63 6b 43 68 61 6e 67 65 73 28 24 73 74 65 70 29 3b 0a 09 09 09 72 65 74 75 72 6e 20 5b | lbackChanges($step);....return.[ |
941c0 | 27 70 72 6f 63 65 65 64 27 20 3d 3e 20 66 61 6c 73 65 2c 20 27 72 65 73 70 6f 6e 73 65 27 20 3d | 'proceed'.=>.false,.'response'.= |
941e0 | 3e 20 24 6d 65 73 73 61 67 65 5d 3b 0a 09 09 7d 20 63 61 74 63 68 20 28 5c 45 78 63 65 70 74 69 | >.$message];...}.catch.(\Excepti |
94200 | 6f 6e 20 24 65 29 20 7b 0a 09 09 09 24 6d 65 73 73 61 67 65 20 3d 20 24 65 2d 3e 67 65 74 4d 65 | on.$e).{....$message.=.$e->getMe |
94220 | 73 73 61 67 65 28 29 3b 0a 0a 09 09 09 74 72 79 20 7b 0a 09 09 09 09 24 74 68 69 73 2d 3e 75 70 | ssage();.....try.{.....$this->up |
94240 | 64 61 74 65 72 2d 3e 6c 6f 67 28 27 5b 65 72 72 6f 72 5d 20 65 78 65 63 75 74 65 53 74 65 70 20 | dater->log('[error].executeStep. |
94260 | 72 65 71 75 65 73 74 20 66 61 69 6c 65 64 20 77 69 74 68 20 6f 74 68 65 72 20 65 78 63 65 70 74 | request.failed.with.other.except |
94280 | 69 6f 6e 27 29 3b 0a 09 09 09 09 24 74 68 69 73 2d 3e 75 70 64 61 74 65 72 2d 3e 6c 6f 67 45 78 | ion');.....$this->updater->logEx |
942a0 | 63 65 70 74 69 6f 6e 28 24 65 29 3b 0a 09 09 09 7d 20 63 61 74 63 68 20 28 4c 6f 67 45 78 63 65 | ception($e);....}.catch.(LogExce |
942c0 | 70 74 69 6f 6e 20 24 6c 6f 67 45 29 20 7b 0a 09 09 09 09 24 6d 65 73 73 61 67 65 20 2e 3d 20 27 | ption.$logE).{.....$message..=.' |
942e0 | 20 28 61 6e 64 20 77 72 69 74 69 6e 67 20 74 6f 20 6c 6f 67 20 66 61 69 6c 65 64 20 61 6c 73 6f | .(and.writing.to.log.failed.also |
94300 | 20 77 69 74 68 3a 20 27 20 2e 20 24 6c 6f 67 45 2d 3e 67 65 74 4d 65 73 73 61 67 65 28 29 20 2e | .with:.'...$logE->getMessage().. |
94320 | 20 27 29 27 3b 0a 09 09 09 7d 0a 0a 09 09 09 24 74 68 69 73 2d 3e 75 70 64 61 74 65 72 2d 3e 72 | .')';....}.....$this->updater->r |
94340 | 6f 6c 6c 62 61 63 6b 43 68 61 6e 67 65 73 28 24 73 74 65 70 29 3b 0a 09 09 09 72 65 74 75 72 6e | ollbackChanges($step);....return |
94360 | 20 5b 27 70 72 6f 63 65 65 64 27 20 3d 3e 20 66 61 6c 73 65 2c 20 27 72 65 73 70 6f 6e 73 65 27 | .['proceed'.=>.false,.'response' |
94380 | 20 3d 3e 20 24 6d 65 73 73 61 67 65 5d 3b 0a 09 09 7d 0a 09 7d 0a 0a 09 2f 2a 2a 0a 09 20 2a 20 | .=>.$message];...}..}.../**...*. |
943a0 | 40 70 61 72 61 6d 20 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 0a 09 | @param.OutputInterface.$output.. |
943c0 | 20 2a 20 40 70 61 72 61 6d 20 69 6e 74 65 67 65 72 20 24 73 74 65 70 4e 75 6d 62 65 72 0a 09 20 | .*.@param.integer.$stepNumber... |
943e0 | 2a 2f 0a 09 70 72 6f 74 65 63 74 65 64 20 66 75 6e 63 74 69 6f 6e 20 73 68 6f 77 43 75 72 72 65 | */..protected.function.showCurre |
94400 | 6e 74 53 74 61 74 75 73 28 4f 75 74 70 75 74 49 6e 74 65 72 66 61 63 65 20 24 6f 75 74 70 75 74 | ntStatus(OutputInterface.$output |
94420 | 2c 20 24 73 74 65 70 4e 75 6d 62 65 72 29 20 7b 0a 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 | ,.$stepNumber).{...$output->writ |
94440 | 65 6c 6e 28 27 53 74 65 70 73 20 74 68 61 74 20 77 69 6c 6c 20 62 65 20 65 78 65 63 75 74 65 64 | eln('Steps.that.will.be.executed |
94460 | 3a 27 29 3b 0a 09 09 66 6f 72 20 28 24 69 20 3d 20 31 3b 20 24 69 20 3c 20 73 69 7a 65 6f 66 28 | :');...for.($i.=.1;.$i.<.sizeof( |
94480 | 24 74 68 69 73 2d 3e 63 68 65 63 6b 54 65 78 74 73 29 3b 20 24 69 2b 2b 29 20 7b 0a 09 09 09 69 | $this->checkTexts);.$i++).{....i |
944a0 | 66 20 28 24 69 20 3d 3d 3d 20 31 31 29 20 7b 0a 09 09 09 09 2f 2f 20 6e 6f 20 6e 65 65 64 20 74 | f.($i.===.11).{.....//.no.need.t |
944c0 | 6f 20 61 73 6b 20 66 6f 72 20 6d 61 69 6e 74 65 6e 61 6e 63 65 20 6d 6f 64 65 20 6f 6e 20 43 4c | o.ask.for.maintenance.mode.on.CL |
944e0 | 49 20 2d 20 73 6b 69 70 20 69 74 0a 09 09 09 09 63 6f 6e 74 69 6e 75 65 3b 0a 09 09 09 7d 0a 09 | I.-.skip.it.....continue;....}.. |
94500 | 09 09 24 73 74 61 74 75 73 42 65 67 69 6e 20 3d 20 27 5b 20 5d 20 27 3b 0a 09 09 09 24 73 74 61 | ..$statusBegin.=.'[.].';....$sta |
94520 | 74 75 73 45 6e 64 20 3d 20 27 27 3b 0a 09 09 09 69 66 20 28 24 69 20 3c 3d 20 24 73 74 65 70 4e | tusEnd.=.'';....if.($i.<=.$stepN |
94540 | 75 6d 62 65 72 29 20 7b 0a 09 09 09 09 24 73 74 61 74 75 73 42 65 67 69 6e 20 3d 20 27 3c 69 6e | umber).{.....$statusBegin.=.'<in |
94560 | 66 6f 3e 5b e2 9c 94 5d 20 27 3b 0a 09 09 09 09 24 73 74 61 74 75 73 45 6e 64 20 3d 20 27 3c 2f | fo>[...].';.....$statusEnd.=.'</ |
94580 | 69 6e 66 6f 3e 27 3b 0a 09 09 09 7d 0a 09 09 09 24 6f 75 74 70 75 74 2d 3e 77 72 69 74 65 6c 6e | info>';....}....$output->writeln |
945a0 | 28 24 73 74 61 74 75 73 42 65 67 69 6e 20 2e 20 24 74 68 69 73 2d 3e 63 68 65 63 6b 54 65 78 74 | ($statusBegin...$this->checkText |
945c0 | 73 5b 24 69 5d 20 2e 20 24 73 74 61 74 75 73 45 6e 64 29 3b 0a 09 09 7d 0a 09 7d 0a 0a 09 2f 2a | s[$i]...$statusEnd);...}..}.../* |
945e0 | 2a 0a 09 20 2a 20 67 65 74 73 20 63 61 6c 6c 65 64 20 62 79 20 74 68 65 20 50 43 4e 54 4c 20 6c | *...*.gets.called.by.the.PCNTL.l |
94600 | 69 73 74 65 6e 65 72 20 6f 6e 63 65 20 74 68 65 20 73 74 6f 70 2f 74 65 72 6d 69 6e 61 74 65 20 | istener.once.the.stop/terminate. |
94620 | 73 69 67 6e 61 6c 0a 09 20 2a 2f 0a 09 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 74 6f | signal...*/..public.function.sto |
94640 | 70 43 6f 6d 6d 61 6e 64 28 29 20 7b 0a 09 09 24 74 68 69 73 2d 3e 73 68 6f 75 6c 64 53 74 6f 70 | pCommand().{...$this->shouldStop |
94660 | 20 3d 20 74 72 75 65 3b 0a 09 7d 0a 0a 0a 7d 0a 3c 3f 70 68 70 0a 0a 6e 61 6d 65 73 70 61 63 65 | .=.true;..}...}.<?php..namespace |
94680 | 20 4e 43 5c 55 70 64 61 74 65 72 3b 0a 0a 66 75 6e 63 74 69 6f 6e 20 67 65 74 55 70 64 61 74 65 | .NC\Updater;..function.getUpdate |
946a0 | 72 56 65 72 73 69 6f 6e 28 29 20 7b 0a 09 72 65 74 75 72 6e 20 27 30 2e 30 2e 31 2d 74 65 73 74 | rVersion().{..return.'0.0.1-test |
946c0 | 2d 34 2d 67 64 31 38 35 36 63 37 20 64 69 72 74 79 27 3b 0a 7d 0a 3c 3f 70 68 70 0a 0a 6e 61 6d | -4-gd1856c7.dirty';.}.<?php..nam |
946e0 | 65 73 70 61 63 65 20 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 | espace.HumbugBox3111\Composer\Se |
94700 | 6d 76 65 72 3b 0a 0a 75 73 65 20 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 | mver;..use.HumbugBox3111\Compose |
94720 | 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 49 6e | r\Semver\Constraint\ConstraintIn |
94740 | 74 65 72 66 61 63 65 3b 0a 75 73 65 20 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f | terface;.use.HumbugBox3111\Compo |
94760 | 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 4d 61 74 63 68 41 6c 6c 43 6f | ser\Semver\Constraint\MatchAllCo |
94780 | 6e 73 74 72 61 69 6e 74 3b 0a 75 73 65 20 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 | nstraint;.use.HumbugBox3111\Comp |
947a0 | 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 4d 75 6c 74 69 43 6f 6e 73 | oser\Semver\Constraint\MultiCons |
947c0 | 74 72 61 69 6e 74 3b 0a 75 73 65 20 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 | traint;.use.HumbugBox3111\Compos |
947e0 | 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 3b | er\Semver\Constraint\Constraint; |
94800 | 0a 63 6c 61 73 73 20 56 65 72 73 69 6f 6e 50 61 72 73 65 72 0a 7b 0a 20 20 20 20 70 72 69 76 61 | .class.VersionParser.{.....priva |
94820 | 74 65 20 73 74 61 74 69 63 20 24 6d 6f 64 69 66 69 65 72 52 65 67 65 78 20 3d 20 27 5b 2e 5f 2d | te.static.$modifierRegex.=.'[._- |
94840 | 5d 3f 28 3f 3a 28 73 74 61 62 6c 65 7c 62 65 74 61 7c 62 7c 52 43 7c 61 6c 70 68 61 7c 61 7c 70 | ]?(?:(stable|beta|b|RC|alpha|a|p |
94860 | 61 74 63 68 7c 70 6c 7c 70 29 28 28 3f 3a 5b 2e 2d 5d 3f 5c 5c 64 2b 29 2a 2b 29 3f 29 3f 28 5b | atch|pl|p)((?:[.-]?\\d+)*+)?)?([ |
94880 | 2e 2d 5d 3f 64 65 76 29 3f 27 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 24 | .-]?dev)?';.....private.static.$ |
948a0 | 73 74 61 62 69 6c 69 74 69 65 73 52 65 67 65 78 20 3d 20 27 73 74 61 62 6c 65 7c 52 43 7c 62 65 | stabilitiesRegex.=.'stable|RC|be |
948c0 | 74 61 7c 61 6c 70 68 61 7c 64 65 76 27 3b 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 | ta|alpha|dev';.....public.static |
948e0 | 20 66 75 6e 63 74 69 6f 6e 20 70 61 72 73 65 53 74 61 62 69 6c 69 74 79 28 24 76 65 72 73 69 6f | .function.parseStability($versio |
94900 | 6e 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 76 65 72 73 69 6f 6e 20 3d 20 5c 70 72 65 | n).....{.........$version.=.\pre |
94920 | 67 5f 72 65 70 6c 61 63 65 28 27 7b 23 2e 2b 24 7d 69 27 2c 20 27 27 2c 20 24 76 65 72 73 69 6f | g_replace('{#.+$}i',.'',.$versio |
94940 | 6e 29 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 5c 73 74 72 70 6f 73 28 24 76 65 72 73 69 6f 6e | n);.........if.(\strpos($version |
94960 | 2c 20 27 64 65 76 2d 27 29 20 3d 3d 3d 20 30 20 7c 7c 20 27 2d 64 65 76 27 20 3d 3d 3d 20 5c 73 | ,.'dev-').===.0.||.'-dev'.===.\s |
94980 | 75 62 73 74 72 28 24 76 65 72 73 69 6f 6e 2c 20 2d 34 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | ubstr($version,.-4)).{.......... |
949a0 | 20 20 20 72 65 74 75 72 6e 20 27 64 65 76 27 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 | ...return.'dev';.........}...... |
949c0 | 20 20 20 5c 70 72 65 67 5f 6d 61 74 63 68 28 27 7b 27 20 2e 20 73 65 6c 66 3a 3a 24 6d 6f 64 69 | ...\preg_match('{'...self::$modi |
949e0 | 66 69 65 72 52 65 67 65 78 20 2e 20 27 28 3f 3a 5c 5c 2b 2e 2a 29 3f 24 7d 69 27 2c 20 5c 73 74 | fierRegex...'(?:\\+.*)?$}i',.\st |
94a00 | 72 74 6f 6c 6f 77 65 72 28 24 76 65 72 73 69 6f 6e 29 2c 20 24 6d 61 74 63 68 29 3b 0a 20 20 20 | rtolower($version),.$match);.... |
94a20 | 20 20 20 20 20 69 66 20 28 21 65 6d 70 74 79 28 24 6d 61 74 63 68 5b 33 5d 29 29 20 7b 0a 20 20 | .....if.(!empty($match[3])).{... |
94a40 | 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 27 64 65 76 27 3b 0a 20 20 20 20 20 20 20 20 | ..........return.'dev';......... |
94a60 | 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 65 6d 70 74 79 28 24 6d 61 74 63 68 5b 31 5d 29 29 | }.........if.(!empty($match[1])) |
94a80 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 27 62 65 74 61 27 20 3d 3d 3d 20 24 6d | .{.............if.('beta'.===.$m |
94aa0 | 61 74 63 68 5b 31 5d 20 7c 7c 20 27 62 27 20 3d 3d 3d 20 24 6d 61 74 63 68 5b 31 5d 29 20 7b 0a | atch[1].||.'b'.===.$match[1]).{. |
94ac0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 27 62 65 74 61 27 3b 0a 20 | ................return.'beta';.. |
94ae0 | 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 27 61 6c | ...........}.............if.('al |
94b00 | 70 68 61 27 20 3d 3d 3d 20 24 6d 61 74 63 68 5b 31 5d 20 7c 7c 20 27 61 27 20 3d 3d 3d 20 24 6d | pha'.===.$match[1].||.'a'.===.$m |
94b20 | 61 74 63 68 5b 31 5d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 | atch[1]).{.................retur |
94b40 | 6e 20 27 61 6c 70 68 61 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 | n.'alpha';.............}........ |
94b60 | 20 20 20 20 20 69 66 20 28 27 72 63 27 20 3d 3d 3d 20 24 6d 61 74 63 68 5b 31 5d 29 20 7b 0a 20 | .....if.('rc'.===.$match[1]).{.. |
94b80 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 27 52 43 27 3b 0a 20 20 20 20 | ...............return.'RC';..... |
94ba0 | 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 72 65 74 75 | ........}.........}.........retu |
94bc0 | 72 6e 20 27 73 74 61 62 6c 65 27 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 | rn.'stable';.....}.....public.st |
94be0 | 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 6e 6f 72 6d 61 6c 69 7a 65 53 74 61 62 69 6c 69 74 79 | atic.function.normalizeStability |
94c00 | 28 24 73 74 61 62 69 6c 69 74 79 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 73 74 61 62 | ($stability).....{.........$stab |
94c20 | 69 6c 69 74 79 20 3d 20 5c 73 74 72 74 6f 6c 6f 77 65 72 28 24 73 74 61 62 69 6c 69 74 79 29 3b | ility.=.\strtolower($stability); |
94c40 | 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 73 74 61 62 69 6c 69 74 79 20 3d 3d 3d 20 27 | .........return.$stability.===.' |
94c60 | 72 63 27 20 3f 20 27 52 43 27 20 3a 20 24 73 74 61 62 69 6c 69 74 79 3b 0a 20 20 20 20 7d 0a 20 | rc'.?.'RC'.:.$stability;.....}.. |
94c80 | 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 6e 6f 72 6d 61 6c 69 7a 65 28 24 76 65 | ...public.function.normalize($ve |
94ca0 | 72 73 69 6f 6e 2c 20 24 66 75 6c 6c 56 65 72 73 69 6f 6e 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 | rsion,.$fullVersion.=.null)..... |
94cc0 | 7b 0a 20 20 20 20 20 20 20 20 24 76 65 72 73 69 6f 6e 20 3d 20 5c 74 72 69 6d 28 24 76 65 72 73 | {.........$version.=.\trim($vers |
94ce0 | 69 6f 6e 29 3b 0a 20 20 20 20 20 20 20 20 24 6f 72 69 67 56 65 72 73 69 6f 6e 20 3d 20 24 76 65 | ion);.........$origVersion.=.$ve |
94d00 | 72 73 69 6f 6e 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 66 75 6c | rsion;.........if.(null.===.$ful |
94d20 | 6c 56 65 72 73 69 6f 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 66 75 6c 6c 56 65 72 | lVersion).{.............$fullVer |
94d40 | 73 69 6f 6e 20 3d 20 24 76 65 72 73 69 6f 6e 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 | sion.=.$version;.........}...... |
94d60 | 20 20 20 69 66 20 28 5c 70 72 65 67 5f 6d 61 74 63 68 28 27 7b 5e 28 5b 5e 2c 5c 5c 73 5d 2b 2b | ...if.(\preg_match('{^([^,\\s]++ |
94d80 | 29 20 2b 2b 61 73 20 2b 2b 28 5b 5e 2c 5c 5c 73 5d 2b 2b 29 24 7d 27 2c 20 24 76 65 72 73 69 6f | ).++as.++([^,\\s]++)$}',.$versio |
94da0 | 6e 2c 20 24 6d 61 74 63 68 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 76 65 72 73 69 | n,.$match)).{.............$versi |
94dc0 | 6f 6e 20 3d 20 24 6d 61 74 63 68 5b 31 5d 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 | on.=.$match[1];.........}....... |
94de0 | 20 20 69 66 20 28 5c 70 72 65 67 5f 6d 61 74 63 68 28 27 7b 40 28 3f 3a 27 20 2e 20 73 65 6c 66 | ..if.(\preg_match('{@(?:'...self |
94e00 | 3a 3a 24 73 74 61 62 69 6c 69 74 69 65 73 52 65 67 65 78 20 2e 20 27 29 24 7d 69 27 2c 20 24 76 | ::$stabilitiesRegex...')$}i',.$v |
94e20 | 65 72 73 69 6f 6e 2c 20 24 6d 61 74 63 68 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 | ersion,.$match)).{.............$ |
94e40 | 76 65 72 73 69 6f 6e 20 3d 20 5c 73 75 62 73 74 72 28 24 76 65 72 73 69 6f 6e 2c 20 30 2c 20 5c | version.=.\substr($version,.0,.\ |
94e60 | 73 74 72 6c 65 6e 28 24 76 65 72 73 69 6f 6e 29 20 2d 20 5c 73 74 72 6c 65 6e 28 24 6d 61 74 63 | strlen($version).-.\strlen($matc |
94e80 | 68 5b 30 5d 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 5c 69 | h[0]));.........}.........if.(\i |
94ea0 | 6e 5f 61 72 72 61 79 28 24 76 65 72 73 69 6f 6e 2c 20 61 72 72 61 79 28 27 6d 61 73 74 65 72 27 | n_array($version,.array('master' |
94ec0 | 2c 20 27 74 72 75 6e 6b 27 2c 20 27 64 65 66 61 75 6c 74 27 29 2c 20 5c 74 72 75 65 29 29 20 7b | ,.'trunk',.'default'),.\true)).{ |
94ee0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 76 65 72 73 69 6f 6e 20 3d 20 27 64 65 76 2d 27 20 2e | .............$version.=.'dev-'.. |
94f00 | 20 24 76 65 72 73 69 6f 6e 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 | .$version;.........}.........if. |
94f20 | 28 5c 73 74 72 69 70 6f 73 28 24 76 65 72 73 69 6f 6e 2c 20 27 64 65 76 2d 27 29 20 3d 3d 3d 20 | (\stripos($version,.'dev-').===. |
94f40 | 30 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 27 64 65 76 2d 27 20 2e | 0).{.............return.'dev-'.. |
94f60 | 20 5c 73 75 62 73 74 72 28 24 76 65 72 73 69 6f 6e 2c 20 34 29 3b 0a 20 20 20 20 20 20 20 20 7d | .\substr($version,.4);.........} |
94f80 | 0a 20 20 20 20 20 20 20 20 69 66 20 28 5c 70 72 65 67 5f 6d 61 74 63 68 28 27 7b 5e 28 5b 5e 2c | .........if.(\preg_match('{^([^, |
94fa0 | 5c 5c 73 2b 5d 2b 2b 29 5c 5c 2b 5b 5e 5c 5c 73 5d 2b 2b 24 7d 27 2c 20 24 76 65 72 73 69 6f 6e | \\s+]++)\\+[^\\s]++$}',.$version |
94fc0 | 2c 20 24 6d 61 74 63 68 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 76 65 72 73 69 6f | ,.$match)).{.............$versio |
94fe0 | 6e 20 3d 20 24 6d 61 74 63 68 5b 31 5d 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 | n.=.$match[1];.........}........ |
95000 | 20 69 66 20 28 5c 70 72 65 67 5f 6d 61 74 63 68 28 27 7b 5e 76 3f 28 5c 5c 64 7b 31 2c 35 7d 29 | .if.(\preg_match('{^v?(\\d{1,5}) |
95020 | 28 5c 5c 2e 5c 5c 64 2b 2b 29 3f 28 5c 5c 2e 5c 5c 64 2b 2b 29 3f 28 5c 5c 2e 5c 5c 64 2b 2b 29 | (\\.\\d++)?(\\.\\d++)?(\\.\\d++) |
95040 | 3f 27 20 2e 20 73 65 6c 66 3a 3a 24 6d 6f 64 69 66 69 65 72 52 65 67 65 78 20 2e 20 27 24 7d 69 | ?'...self::$modifierRegex...'$}i |
95060 | 27 2c 20 24 76 65 72 73 69 6f 6e 2c 20 24 6d 61 74 63 68 65 73 29 29 20 7b 0a 20 20 20 20 20 20 | ',.$version,.$matches)).{....... |
95080 | 20 20 20 20 20 20 24 76 65 72 73 69 6f 6e 20 3d 20 24 6d 61 74 63 68 65 73 5b 31 5d 20 2e 20 28 | ......$version.=.$matches[1]...( |
950a0 | 21 65 6d 70 74 79 28 24 6d 61 74 63 68 65 73 5b 32 5d 29 20 3f 20 24 6d 61 74 63 68 65 73 5b 32 | !empty($matches[2]).?.$matches[2 |
950c0 | 5d 20 3a 20 27 2e 30 27 29 20 2e 20 28 21 65 6d 70 74 79 28 24 6d 61 74 63 68 65 73 5b 33 5d 29 | ].:.'.0')...(!empty($matches[3]) |
950e0 | 20 3f 20 24 6d 61 74 63 68 65 73 5b 33 5d 20 3a 20 27 2e 30 27 29 20 2e 20 28 21 65 6d 70 74 79 | .?.$matches[3].:.'.0')...(!empty |
95100 | 28 24 6d 61 74 63 68 65 73 5b 34 5d 29 20 3f 20 24 6d 61 74 63 68 65 73 5b 34 5d 20 3a 20 27 2e | ($matches[4]).?.$matches[4].:.'. |
95120 | 30 27 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 69 6e 64 65 78 20 3d 20 35 3b 0a 20 20 20 | 0');.............$index.=.5;.... |
95140 | 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 5c 70 72 65 67 5f 6d 61 74 63 68 28 27 7b 5e 76 3f | .....}.elseif.(\preg_match('{^v? |
95160 | 28 5c 5c 64 7b 34 7d 28 3f 3a 5b 2e 3a 2d 5d 3f 5c 5c 64 7b 32 7d 29 7b 31 2c 36 7d 28 3f 3a 5b | (\\d{4}(?:[.:-]?\\d{2}){1,6}(?:[ |
95180 | 2e 3a 2d 5d 3f 5c 5c 64 7b 31 2c 33 7d 29 3f 29 27 20 2e 20 73 65 6c 66 3a 3a 24 6d 6f 64 69 66 | .:-]?\\d{1,3})?)'...self::$modif |
951a0 | 69 65 72 52 65 67 65 78 20 2e 20 27 24 7d 69 27 2c 20 24 76 65 72 73 69 6f 6e 2c 20 24 6d 61 74 | ierRegex...'$}i',.$version,.$mat |
951c0 | 63 68 65 73 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 76 65 72 73 69 6f 6e 20 3d 20 | ches)).{.............$version.=. |
951e0 | 5c 70 72 65 67 5f 72 65 70 6c 61 63 65 28 27 7b 5c 5c 44 7d 27 2c 20 27 2e 27 2c 20 24 6d 61 74 | \preg_replace('{\\D}',.'.',.$mat |
95200 | 63 68 65 73 5b 31 5d 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 69 6e 64 65 78 20 3d 20 32 | ches[1]);.............$index.=.2 |
95220 | 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 69 73 73 65 74 28 24 69 | ;.........}.........if.(isset($i |
95240 | 6e 64 65 78 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 21 65 6d 70 74 79 28 | ndex)).{.............if.(!empty( |
95260 | 24 6d 61 74 63 68 65 73 5b 24 69 6e 64 65 78 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | $matches[$index])).{............ |
95280 | 20 20 20 20 20 69 66 20 28 27 73 74 61 62 6c 65 27 20 3d 3d 3d 20 24 6d 61 74 63 68 65 73 5b 24 | .....if.('stable'.===.$matches[$ |
952a0 | 69 6e 64 65 78 5d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 | index]).{.....................re |
952c0 | 74 75 72 6e 20 24 76 65 72 73 69 6f 6e 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d | turn.$version;.................} |
952e0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 76 65 72 73 69 6f 6e 20 2e 3d 20 27 2d 27 | .................$version..=.'-' |
95300 | 20 2e 20 24 74 68 69 73 2d 3e 65 78 70 61 6e 64 53 74 61 62 69 6c 69 74 79 28 24 6d 61 74 63 68 | ...$this->expandStability($match |
95320 | 65 73 5b 24 69 6e 64 65 78 5d 29 20 2e 20 28 21 65 6d 70 74 79 28 24 6d 61 74 63 68 65 73 5b 24 | es[$index])...(!empty($matches[$ |
95340 | 69 6e 64 65 78 20 2b 20 31 5d 29 20 3f 20 5c 6c 74 72 69 6d 28 24 6d 61 74 63 68 65 73 5b 24 69 | index.+.1]).?.\ltrim($matches[$i |
95360 | 6e 64 65 78 20 2b 20 31 5d 2c 20 27 2e 2d 27 29 20 3a 20 27 27 29 3b 0a 20 20 20 20 20 20 20 20 | ndex.+.1],.'.-').:.'');......... |
95380 | 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 21 65 6d 70 74 79 28 24 6d 61 | ....}.............if.(!empty($ma |
953a0 | 74 63 68 65 73 5b 24 69 6e 64 65 78 20 2b 20 32 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | tches[$index.+.2])).{........... |
953c0 | 20 20 20 20 20 20 24 76 65 72 73 69 6f 6e 20 2e 3d 20 27 2d 64 65 76 27 3b 0a 20 20 20 20 20 20 | ......$version..=.'-dev';....... |
953e0 | 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 76 65 72 73 | ......}.............return.$vers |
95400 | 69 6f 6e 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 5c 70 72 65 67 | ion;.........}.........if.(\preg |
95420 | 5f 6d 61 74 63 68 28 27 7b 28 2e 2a 3f 29 5b 2e 2d 5d 3f 64 65 76 24 7d 69 27 2c 20 24 76 65 72 | _match('{(.*?)[.-]?dev$}i',.$ver |
95440 | 73 69 6f 6e 2c 20 24 6d 61 74 63 68 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 72 79 | sion,.$match)).{.............try |
95460 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6e 6f 72 6d 61 6c 69 7a 65 64 20 3d | .{.................$normalized.= |
95480 | 20 24 74 68 69 73 2d 3e 6e 6f 72 6d 61 6c 69 7a 65 42 72 61 6e 63 68 28 24 6d 61 74 63 68 5b 31 | .$this->normalizeBranch($match[1 |
954a0 | 5d 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 5c 73 74 72 70 6f 73 28 | ]);.................if.(\strpos( |
954c0 | 24 6e 6f 72 6d 61 6c 69 7a 65 64 2c 20 27 64 65 76 2d 27 29 20 3d 3d 3d 20 5c 66 61 6c 73 65 29 | $normalized,.'dev-').===.\false) |
954e0 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 6e | .{.....................return.$n |
95500 | 6f 72 6d 61 6c 69 7a 65 64 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 | ormalized;.................}.... |
95520 | 20 20 20 20 20 20 20 20 20 7d 20 63 61 74 63 68 20 28 5c 45 78 63 65 70 74 69 6f 6e 20 24 65 29 | .........}.catch.(\Exception.$e) |
95540 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 | .{.............}.........}...... |
95560 | 20 20 20 24 65 78 74 72 61 4d 65 73 73 61 67 65 20 3d 20 27 27 3b 0a 20 20 20 20 20 20 20 20 69 | ...$extraMessage.=.'';.........i |
95580 | 66 20 28 5c 70 72 65 67 5f 6d 61 74 63 68 28 27 7b 20 2b 61 73 20 2b 27 20 2e 20 5c 70 72 65 67 | f.(\preg_match('{.+as.+'...\preg |
955a0 | 5f 71 75 6f 74 65 28 24 76 65 72 73 69 6f 6e 29 20 2e 20 27 28 3f 3a 40 28 3f 3a 27 20 2e 20 73 | _quote($version)...'(?:@(?:'...s |
955c0 | 65 6c 66 3a 3a 24 73 74 61 62 69 6c 69 74 69 65 73 52 65 67 65 78 20 2e 20 27 29 29 3f 24 7d 27 | elf::$stabilitiesRegex...'))?$}' |
955e0 | 2c 20 24 66 75 6c 6c 56 65 72 73 69 6f 6e 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 | ,.$fullVersion)).{.............$ |
95600 | 65 78 74 72 61 4d 65 73 73 61 67 65 20 3d 20 27 20 69 6e 20 22 27 20 2e 20 24 66 75 6c 6c 56 65 | extraMessage.=.'.in."'...$fullVe |
95620 | 72 73 69 6f 6e 20 2e 20 27 22 2c 20 74 68 65 20 61 6c 69 61 73 20 6d 75 73 74 20 62 65 20 61 6e | rsion...'",.the.alias.must.be.an |
95640 | 20 65 78 61 63 74 20 76 65 72 73 69 6f 6e 27 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 | .exact.version';.........}.elsei |
95660 | 66 20 28 5c 70 72 65 67 5f 6d 61 74 63 68 28 27 7b 5e 27 20 2e 20 5c 70 72 65 67 5f 71 75 6f 74 | f.(\preg_match('{^'...\preg_quot |
95680 | 65 28 24 76 65 72 73 69 6f 6e 29 20 2e 20 27 28 3f 3a 40 28 3f 3a 27 20 2e 20 73 65 6c 66 3a 3a | e($version)...'(?:@(?:'...self:: |
956a0 | 24 73 74 61 62 69 6c 69 74 69 65 73 52 65 67 65 78 20 2e 20 27 29 29 3f 20 2b 61 73 20 2b 7d 27 | $stabilitiesRegex...'))?.+as.+}' |
956c0 | 2c 20 24 66 75 6c 6c 56 65 72 73 69 6f 6e 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 | ,.$fullVersion)).{.............$ |
956e0 | 65 78 74 72 61 4d 65 73 73 61 67 65 20 3d 20 27 20 69 6e 20 22 27 20 2e 20 24 66 75 6c 6c 56 65 | extraMessage.=.'.in."'...$fullVe |
95700 | 72 73 69 6f 6e 20 2e 20 27 22 2c 20 74 68 65 20 61 6c 69 61 73 20 73 6f 75 72 63 65 20 6d 75 73 | rsion...'",.the.alias.source.mus |
95720 | 74 20 62 65 20 61 6e 20 65 78 61 63 74 20 76 65 72 73 69 6f 6e 2c 20 69 66 20 69 74 20 69 73 20 | t.be.an.exact.version,.if.it.is. |
95740 | 61 20 62 72 61 6e 63 68 20 6e 61 6d 65 20 79 6f 75 20 73 68 6f 75 6c 64 20 70 72 65 66 69 78 20 | a.branch.name.you.should.prefix. |
95760 | 69 74 20 77 69 74 68 20 64 65 76 2d 27 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 | it.with.dev-';.........}........ |
95780 | 20 74 68 72 6f 77 20 6e 65 77 20 5c 55 6e 65 78 70 65 63 74 65 64 56 61 6c 75 65 45 78 63 65 70 | .throw.new.\UnexpectedValueExcep |
957a0 | 74 69 6f 6e 28 27 49 6e 76 61 6c 69 64 20 76 65 72 73 69 6f 6e 20 73 74 72 69 6e 67 20 22 27 20 | tion('Invalid.version.string."'. |
957c0 | 2e 20 24 6f 72 69 67 56 65 72 73 69 6f 6e 20 2e 20 27 22 27 20 2e 20 24 65 78 74 72 61 4d 65 73 | ..$origVersion...'"'...$extraMes |
957e0 | 73 61 67 65 29 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e | sage);.....}.....public.function |
95800 | 20 70 61 72 73 65 4e 75 6d 65 72 69 63 41 6c 69 61 73 50 72 65 66 69 78 28 24 62 72 61 6e 63 68 | .parseNumericAliasPrefix($branch |
95820 | 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 5c 70 72 65 67 5f 6d 61 74 63 68 28 | ).....{.........if.(\preg_match( |
95840 | 27 7b 5e 28 3f 50 3c 76 65 72 73 69 6f 6e 3e 28 5c 5c 64 2b 2b 5c 5c 2e 29 2a 5c 5c 64 2b 2b 29 | '{^(?P<version>(\\d++\\.)*\\d++) |
95860 | 28 3f 3a 5c 5c 2e 78 29 3f 2d 64 65 76 24 7d 69 27 2c 20 24 62 72 61 6e 63 68 2c 20 24 6d 61 74 | (?:\\.x)?-dev$}i',.$branch,.$mat |
95880 | 63 68 65 73 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 6d 61 74 | ches)).{.............return.$mat |
958a0 | 63 68 65 73 5b 27 76 65 72 73 69 6f 6e 27 5d 20 2e 20 27 2e 27 3b 0a 20 20 20 20 20 20 20 20 7d | ches['version']...'.';.........} |
958c0 | 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 5c 66 61 6c 73 65 3b 0a 20 20 20 20 7d 0a 20 20 | .........return.\false;.....}... |
958e0 | 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 6e 6f 72 6d 61 6c 69 7a 65 42 72 61 6e 63 | ..public.function.normalizeBranc |
95900 | 68 28 24 6e 61 6d 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 6e 61 6d 65 20 3d 20 5c | h($name).....{.........$name.=.\ |
95920 | 74 72 69 6d 28 24 6e 61 6d 65 29 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 5c 70 72 65 67 5f 6d | trim($name);.........if.(\preg_m |
95940 | 61 74 63 68 28 27 7b 5e 76 3f 28 5c 5c 64 2b 2b 29 28 5c 5c 2e 28 3f 3a 5c 5c 64 2b 2b 7c 5b 78 | atch('{^v?(\\d++)(\\.(?:\\d++|[x |
95960 | 58 2a 5d 29 29 3f 28 5c 5c 2e 28 3f 3a 5c 5c 64 2b 2b 7c 5b 78 58 2a 5d 29 29 3f 28 5c 5c 2e 28 | X*]))?(\\.(?:\\d++|[xX*]))?(\\.( |
95980 | 3f 3a 5c 5c 64 2b 2b 7c 5b 78 58 2a 5d 29 29 3f 24 7d 69 27 2c 20 24 6e 61 6d 65 2c 20 24 6d 61 | ?:\\d++|[xX*]))?$}i',.$name,.$ma |
959a0 | 74 63 68 65 73 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 76 65 72 73 69 6f 6e 20 3d | tches)).{.............$version.= |
959c0 | 20 27 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 20 28 24 69 20 3d 20 31 3b 20 24 69 | .'';.............for.($i.=.1;.$i |
959e0 | 20 3c 20 35 3b 20 2b 2b 24 69 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 76 | .<.5;.++$i).{.................$v |
95a00 | 65 72 73 69 6f 6e 20 2e 3d 20 69 73 73 65 74 28 24 6d 61 74 63 68 65 73 5b 24 69 5d 29 20 3f 20 | ersion..=.isset($matches[$i]).?. |
95a20 | 5c 73 74 72 5f 72 65 70 6c 61 63 65 28 61 72 72 61 79 28 27 2a 27 2c 20 27 58 27 29 2c 20 27 78 | \str_replace(array('*',.'X'),.'x |
95a40 | 27 2c 20 24 6d 61 74 63 68 65 73 5b 24 69 5d 29 20 3a 20 27 2e 78 27 3b 0a 20 20 20 20 20 20 20 | ',.$matches[$i]).:.'.x';........ |
95a60 | 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 5c 73 74 72 5f 72 | .....}.............return.\str_r |
95a80 | 65 70 6c 61 63 65 28 27 78 27 2c 20 27 39 39 39 39 39 39 39 27 2c 20 24 76 65 72 73 69 6f 6e 29 | eplace('x',.'9999999',.$version) |
95aa0 | 20 2e 20 27 2d 64 65 76 27 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 72 65 74 | ...'-dev';.........}.........ret |
95ac0 | 75 72 6e 20 27 64 65 76 2d 27 20 2e 20 24 6e 61 6d 65 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 | urn.'dev-'...$name;.....}.....pu |
95ae0 | 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 6e 6f 72 6d 61 6c 69 7a 65 44 65 66 61 75 6c 74 42 72 | blic.function.normalizeDefaultBr |
95b00 | 61 6e 63 68 28 24 6e 61 6d 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 6e | anch($name).....{.........if.($n |
95b20 | 61 6d 65 20 3d 3d 3d 20 27 64 65 76 2d 6d 61 73 74 65 72 27 20 7c 7c 20 24 6e 61 6d 65 20 3d 3d | ame.===.'dev-master'.||.$name.== |
95b40 | 3d 20 27 64 65 76 2d 64 65 66 61 75 6c 74 27 20 7c 7c 20 24 6e 61 6d 65 20 3d 3d 3d 20 27 64 65 | =.'dev-default'.||.$name.===.'de |
95b60 | 76 2d 74 72 75 6e 6b 27 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 27 | v-trunk').{.............return.' |
95b80 | 39 39 39 39 39 39 39 2d 64 65 76 27 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 | 9999999-dev';.........}......... |
95ba0 | 72 65 74 75 72 6e 20 24 6e 61 6d 65 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 | return.$name;.....}.....public.f |
95bc0 | 75 6e 63 74 69 6f 6e 20 70 61 72 73 65 43 6f 6e 73 74 72 61 69 6e 74 73 28 24 63 6f 6e 73 74 72 | unction.parseConstraints($constr |
95be0 | 61 69 6e 74 73 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 70 72 65 74 74 79 43 6f 6e 73 | aints).....{.........$prettyCons |
95c00 | 74 72 61 69 6e 74 20 3d 20 24 63 6f 6e 73 74 72 61 69 6e 74 73 3b 0a 20 20 20 20 20 20 20 20 24 | traint.=.$constraints;.........$ |
95c20 | 6f 72 43 6f 6e 73 74 72 61 69 6e 74 73 20 3d 20 5c 70 72 65 67 5f 73 70 6c 69 74 28 27 7b 5c 5c | orConstraints.=.\preg_split('{\\ |
95c40 | 73 2a 5c 5c 7c 5c 5c 7c 3f 5c 5c 73 2a 7d 27 2c 20 5c 74 72 69 6d 28 24 63 6f 6e 73 74 72 61 69 | s*\\|\\|?\\s*}',.\trim($constrai |
95c60 | 6e 74 73 29 29 3b 0a 20 20 20 20 20 20 20 20 24 6f 72 47 72 6f 75 70 73 20 3d 20 61 72 72 61 79 | nts));.........$orGroups.=.array |
95c80 | 28 29 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 6f 72 43 6f 6e 73 74 72 61 69 | ();.........foreach.($orConstrai |
95ca0 | 6e 74 73 20 61 73 20 24 63 6f 6e 73 74 72 61 69 6e 74 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | nts.as.$constraints).{.......... |
95cc0 | 20 20 20 24 61 6e 64 43 6f 6e 73 74 72 61 69 6e 74 73 20 3d 20 5c 70 72 65 67 5f 73 70 6c 69 74 | ...$andConstraints.=.\preg_split |
95ce0 | 28 27 7b 28 3f 3c 21 5e 7c 61 73 7c 5b 3d 3e 3c 20 2c 5d 29 20 2a 28 3f 3c 21 2d 29 5b 2c 20 5d | ('{(?<!^|as|[=><.,]).*(?<!-)[,.] |
95d00 | 28 3f 21 2d 29 20 2a 28 3f 21 2c 7c 61 73 7c 24 29 7d 27 2c 20 24 63 6f 6e 73 74 72 61 69 6e 74 | (?!-).*(?!,|as|$)}',.$constraint |
95d20 | 73 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 5c 63 6f 75 6e 74 28 24 61 6e 64 43 | s);.............if.(\count($andC |
95d40 | 6f 6e 73 74 72 61 69 6e 74 73 29 20 3e 20 31 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | onstraints).>.1).{.............. |
95d60 | 20 20 20 24 63 6f 6e 73 74 72 61 69 6e 74 4f 62 6a 65 63 74 73 20 3d 20 61 72 72 61 79 28 29 3b | ...$constraintObjects.=.array(); |
95d80 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 61 6e 64 43 6f | .................foreach.($andCo |
95da0 | 6e 73 74 72 61 69 6e 74 73 20 61 73 20 24 63 6f 6e 73 74 72 61 69 6e 74 29 20 7b 0a 20 20 20 20 | nstraints.as.$constraint).{..... |
95dc0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 74 68 69 73 2d 3e | ................foreach.($this-> |
95de0 | 70 61 72 73 65 43 6f 6e 73 74 72 61 69 6e 74 28 24 63 6f 6e 73 74 72 61 69 6e 74 29 20 61 73 20 | parseConstraint($constraint).as. |
95e00 | 24 70 61 72 73 65 64 43 6f 6e 73 74 72 61 69 6e 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | $parsedConstraint).{............ |
95e20 | 20 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6f 6e 73 74 72 61 69 6e 74 4f 62 6a 65 63 74 73 5b | .............$constraintObjects[ |
95e40 | 5d 20 3d 20 24 70 61 72 73 65 64 43 6f 6e 73 74 72 61 69 6e 74 3b 0a 20 20 20 20 20 20 20 20 20 | ].=.$parsedConstraint;.......... |
95e60 | 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 | ...........}.................}.. |
95e80 | 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ...........}.else.{............. |
95ea0 | 20 20 20 20 24 63 6f 6e 73 74 72 61 69 6e 74 4f 62 6a 65 63 74 73 20 3d 20 24 74 68 69 73 2d 3e | ....$constraintObjects.=.$this-> |
95ec0 | 70 61 72 73 65 43 6f 6e 73 74 72 61 69 6e 74 28 24 61 6e 64 43 6f 6e 73 74 72 61 69 6e 74 73 5b | parseConstraint($andConstraints[ |
95ee0 | 30 5d 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 | 0]);.............}.............i |
95f00 | 66 20 28 31 20 3d 3d 3d 20 5c 63 6f 75 6e 74 28 24 63 6f 6e 73 74 72 61 69 6e 74 4f 62 6a 65 63 | f.(1.===.\count($constraintObjec |
95f20 | 74 73 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6f 6e 73 74 72 61 69 | ts)).{.................$constrai |
95f40 | 6e 74 20 3d 20 24 63 6f 6e 73 74 72 61 69 6e 74 4f 62 6a 65 63 74 73 5b 30 5d 3b 0a 20 20 20 20 | nt.=.$constraintObjects[0];..... |
95f60 | 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ........}.else.{................ |
95f80 | 20 24 63 6f 6e 73 74 72 61 69 6e 74 20 3d 20 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 | .$constraint.=.new.\HumbugBox311 |
95fa0 | 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 4d 75 6c | 1\Composer\Semver\Constraint\Mul |
95fc0 | 74 69 43 6f 6e 73 74 72 61 69 6e 74 28 24 63 6f 6e 73 74 72 61 69 6e 74 4f 62 6a 65 63 74 73 29 | tiConstraint($constraintObjects) |
95fe0 | 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 72 47 | ;.............}.............$orG |
96000 | 72 6f 75 70 73 5b 5d 20 3d 20 24 63 6f 6e 73 74 72 61 69 6e 74 3b 0a 20 20 20 20 20 20 20 20 7d | roups[].=.$constraint;.........} |
96020 | 0a 20 20 20 20 20 20 20 20 24 63 6f 6e 73 74 72 61 69 6e 74 20 3d 20 5c 48 75 6d 62 75 67 42 6f | .........$constraint.=.\HumbugBo |
96040 | 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 | x3111\Composer\Semver\Constraint |
96060 | 5c 4d 75 6c 74 69 43 6f 6e 73 74 72 61 69 6e 74 3a 3a 63 72 65 61 74 65 28 24 6f 72 47 72 6f 75 | \MultiConstraint::create($orGrou |
96080 | 70 73 2c 20 5c 66 61 6c 73 65 29 3b 0a 20 20 20 20 20 20 20 20 24 63 6f 6e 73 74 72 61 69 6e 74 | ps,.\false);.........$constraint |
960a0 | 2d 3e 73 65 74 50 72 65 74 74 79 53 74 72 69 6e 67 28 24 70 72 65 74 74 79 43 6f 6e 73 74 72 61 | ->setPrettyString($prettyConstra |
960c0 | 69 6e 74 29 3b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 63 6f 6e 73 74 72 61 69 6e 74 | int);.........return.$constraint |
960e0 | 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 70 61 72 | ;.....}.....private.function.par |
96100 | 73 65 43 6f 6e 73 74 72 61 69 6e 74 28 24 63 6f 6e 73 74 72 61 69 6e 74 29 0a 20 20 20 20 7b 0a | seConstraint($constraint).....{. |
96120 | 20 20 20 20 20 20 20 20 69 66 20 28 5c 70 72 65 67 5f 6d 61 74 63 68 28 27 7b 5e 28 5b 5e 2c 5c | ........if.(\preg_match('{^([^,\ |
96140 | 5c 73 5d 2b 2b 29 20 2b 2b 61 73 20 2b 2b 28 5b 5e 2c 5c 5c 73 5d 2b 2b 29 24 7d 27 2c 20 24 63 | \s]++).++as.++([^,\\s]++)$}',.$c |
96160 | 6f 6e 73 74 72 61 69 6e 74 2c 20 24 6d 61 74 63 68 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | onstraint,.$match)).{........... |
96180 | 20 20 24 63 6f 6e 73 74 72 61 69 6e 74 20 3d 20 24 6d 61 74 63 68 5b 31 5d 3b 0a 20 20 20 20 20 | ..$constraint.=.$match[1];...... |
961a0 | 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 5c 70 72 65 67 5f 6d 61 74 63 68 28 27 7b 5e | ...}.........if.(\preg_match('{^ |
961c0 | 28 5b 5e 2c 5c 5c 73 5d 2a 3f 29 40 28 27 20 2e 20 73 65 6c 66 3a 3a 24 73 74 61 62 69 6c 69 74 | ([^,\\s]*?)@('...self::$stabilit |
961e0 | 69 65 73 52 65 67 65 78 20 2e 20 27 29 24 7d 69 27 2c 20 24 63 6f 6e 73 74 72 61 69 6e 74 2c 20 | iesRegex...')$}i',.$constraint,. |
96200 | 24 6d 61 74 63 68 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6f 6e 73 74 72 61 69 | $match)).{.............$constrai |
96220 | 6e 74 20 3d 20 27 27 20 21 3d 3d 20 24 6d 61 74 63 68 5b 31 5d 20 3f 20 24 6d 61 74 63 68 5b 31 | nt.=.''.!==.$match[1].?.$match[1 |
96240 | 5d 20 3a 20 27 2a 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 6d 61 74 63 68 5b | ].:.'*';.............if.($match[ |
96260 | 32 5d 20 21 3d 3d 20 27 73 74 61 62 6c 65 27 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | 2].!==.'stable').{.............. |
96280 | 20 20 20 24 73 74 61 62 69 6c 69 74 79 4d 6f 64 69 66 69 65 72 20 3d 20 24 6d 61 74 63 68 5b 32 | ...$stabilityModifier.=.$match[2 |
962a0 | 5d 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 | ];.............}.........}...... |
962c0 | 20 20 20 69 66 20 28 5c 70 72 65 67 5f 6d 61 74 63 68 28 27 7b 5e 28 64 65 76 2d 5b 5e 2c 5c 5c | ...if.(\preg_match('{^(dev-[^,\\ |
962e0 | 73 40 5d 2b 3f 7c 5b 5e 2c 5c 5c 73 40 5d 2b 3f 5c 5c 2e 78 2d 64 65 76 29 23 2e 2b 24 7d 69 27 | s@]+?|[^,\\s@]+?\\.x-dev)#.+$}i' |
96300 | 2c 20 24 63 6f 6e 73 74 72 61 69 6e 74 2c 20 24 6d 61 74 63 68 29 29 20 7b 0a 20 20 20 20 20 20 | ,.$constraint,.$match)).{....... |
96320 | 20 20 20 20 20 20 24 63 6f 6e 73 74 72 61 69 6e 74 20 3d 20 24 6d 61 74 63 68 5b 31 5d 3b 0a 20 | ......$constraint.=.$match[1];.. |
96340 | 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 5c 70 72 65 67 5f 6d 61 74 63 68 | .......}.........if.(\preg_match |
96360 | 28 27 7b 5e 28 76 29 3f 5b 78 58 2a 5d 28 5c 5c 2e 5b 78 58 2a 5d 29 2a 24 7d 69 27 2c 20 24 63 | ('{^(v)?[xX*](\\.[xX*])*$}i',.$c |
96380 | 6f 6e 73 74 72 61 69 6e 74 2c 20 24 6d 61 74 63 68 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | onstraint,.$match)).{........... |
963a0 | 20 20 69 66 20 28 21 65 6d 70 74 79 28 24 6d 61 74 63 68 5b 31 5d 29 20 7c 7c 20 21 65 6d 70 74 | ..if.(!empty($match[1]).||.!empt |
963c0 | 79 28 24 6d 61 74 63 68 5b 32 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | y($match[2])).{................. |
963e0 | 72 65 74 75 72 6e 20 61 72 72 61 79 28 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c | return.array(new.\HumbugBox3111\ |
96400 | 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 | Composer\Semver\Constraint\Const |
96420 | 72 61 69 6e 74 28 27 3e 3d 27 2c 20 27 30 2e 30 2e 30 2e 30 2d 64 65 76 27 29 29 3b 0a 20 20 20 | raint('>=',.'0.0.0.0-dev'));.... |
96440 | 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 61 72 | .........}.............return.ar |
96460 | 72 61 79 28 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c | ray(new.\HumbugBox3111\Composer\ |
96480 | 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 4d 61 74 63 68 41 6c 6c 43 6f 6e 73 74 72 | Semver\Constraint\MatchAllConstr |
964a0 | 61 69 6e 74 28 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 24 76 65 72 73 | aint());.........}.........$vers |
964c0 | 69 6f 6e 52 65 67 65 78 20 3d 20 27 76 3f 28 5c 5c 64 2b 2b 29 28 3f 3a 5c 5c 2e 28 5c 5c 64 2b | ionRegex.=.'v?(\\d++)(?:\\.(\\d+ |
964e0 | 2b 7c 5b 78 58 2a 5d 29 29 3f 28 3f 3a 5c 5c 2e 28 5c 5c 64 2b 2b 7c 5b 78 58 2a 5d 29 29 3f 28 | +|[xX*]))?(?:\\.(\\d++|[xX*]))?( |
96500 | 3f 3a 5c 5c 2e 28 5c 5c 64 2b 2b 7c 5b 78 58 2a 5d 29 29 3f 27 20 2e 20 73 65 6c 66 3a 3a 24 6d | ?:\\.(\\d++|[xX*]))?'...self::$m |
96520 | 6f 64 69 66 69 65 72 52 65 67 65 78 20 2e 20 27 28 3f 3a 5c 5c 2b 5b 5e 5c 5c 73 5d 2b 29 3f 27 | odifierRegex...'(?:\\+[^\\s]+)?' |
96540 | 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 5c 70 72 65 67 5f 6d 61 74 63 68 28 27 7b 5e 7e 3e 3f | ;.........if.(\preg_match('{^~>? |
96560 | 27 20 2e 20 24 76 65 72 73 69 6f 6e 52 65 67 65 78 20 2e 20 27 24 7d 69 27 2c 20 24 63 6f 6e 73 | '...$versionRegex...'$}i',.$cons |
96580 | 74 72 61 69 6e 74 2c 20 24 6d 61 74 63 68 65 73 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | traint,.$matches)).{............ |
965a0 | 20 69 66 20 28 5c 73 74 72 70 6f 73 28 24 63 6f 6e 73 74 72 61 69 6e 74 2c 20 27 7e 3e 27 29 20 | .if.(\strpos($constraint,.'~>'). |
965c0 | 3d 3d 3d 20 30 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e | ===.0).{.................throw.n |
965e0 | 65 77 20 5c 55 6e 65 78 70 65 63 74 65 64 56 61 6c 75 65 45 78 63 65 70 74 69 6f 6e 28 27 43 6f | ew.\UnexpectedValueException('Co |
96600 | 75 6c 64 20 6e 6f 74 20 70 61 72 73 65 20 76 65 72 73 69 6f 6e 20 63 6f 6e 73 74 72 61 69 6e 74 | uld.not.parse.version.constraint |
96620 | 20 27 20 2e 20 24 63 6f 6e 73 74 72 61 69 6e 74 20 2e 20 27 3a 20 27 20 2e 20 27 49 6e 76 61 6c | .'...$constraint...':.'...'Inval |
96640 | 69 64 20 6f 70 65 72 61 74 6f 72 20 22 7e 3e 22 2c 20 79 6f 75 20 70 72 6f 62 61 62 6c 79 20 6d | id.operator."~>",.you.probably.m |
96660 | 65 61 6e 74 20 74 6f 20 75 73 65 20 74 68 65 20 22 7e 22 20 6f 70 65 72 61 74 6f 72 27 29 3b 0a | eant.to.use.the."~".operator');. |
96680 | 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 69 73 | ............}.............if.(is |
966a0 | 73 65 74 28 24 6d 61 74 63 68 65 73 5b 34 5d 29 20 26 26 20 27 27 20 21 3d 3d 20 24 6d 61 74 63 | set($matches[4]).&&.''.!==.$matc |
966c0 | 68 65 73 5b 34 5d 20 26 26 20 6e 75 6c 6c 20 21 3d 3d 20 24 6d 61 74 63 68 65 73 5b 34 5d 29 20 | hes[4].&&.null.!==.$matches[4]). |
966e0 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 70 6f 73 69 74 69 6f 6e 20 3d 20 34 3b | {.................$position.=.4; |
96700 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 69 73 73 65 74 28 24 6d 61 | .............}.elseif.(isset($ma |
96720 | 74 63 68 65 73 5b 33 5d 29 20 26 26 20 27 27 20 21 3d 3d 20 24 6d 61 74 63 68 65 73 5b 33 5d 20 | tches[3]).&&.''.!==.$matches[3]. |
96740 | 26 26 20 6e 75 6c 6c 20 21 3d 3d 20 24 6d 61 74 63 68 65 73 5b 33 5d 29 20 7b 0a 20 20 20 20 20 | &&.null.!==.$matches[3]).{...... |
96760 | 20 20 20 20 20 20 20 20 20 20 20 24 70 6f 73 69 74 69 6f 6e 20 3d 20 33 3b 0a 20 20 20 20 20 20 | ...........$position.=.3;....... |
96780 | 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 69 73 73 65 74 28 24 6d 61 74 63 68 65 73 5b 32 | ......}.elseif.(isset($matches[2 |
967a0 | 5d 29 20 26 26 20 27 27 20 21 3d 3d 20 24 6d 61 74 63 68 65 73 5b 32 5d 20 26 26 20 6e 75 6c 6c | ]).&&.''.!==.$matches[2].&&.null |
967c0 | 20 21 3d 3d 20 24 6d 61 74 63 68 65 73 5b 32 5d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | .!==.$matches[2]).{............. |
967e0 | 20 20 20 20 24 70 6f 73 69 74 69 6f 6e 20 3d 20 32 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d | ....$position.=.2;.............} |
96800 | 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 70 6f 73 69 74 69 6f | .else.{.................$positio |
96820 | 6e 20 3d 20 31 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 | n.=.1;.............}............ |
96840 | 20 66 6f 72 20 28 24 69 20 3d 20 24 70 6f 73 69 74 69 6f 6e 3b 20 24 69 20 3e 3d 20 30 3b 20 24 | .for.($i.=.$position;.$i.>=.0;.$ |
96860 | 69 2d 2d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 6d 61 74 63 | i--).{.................if.($matc |
96880 | 68 65 73 5b 24 69 5d 20 3d 3d 3d 20 27 78 27 20 7c 7c 20 24 6d 61 74 63 68 65 73 5b 24 69 5d 20 | hes[$i].===.'x'.||.$matches[$i]. |
968a0 | 3d 3d 3d 20 27 58 27 20 7c 7c 20 24 6d 61 74 63 68 65 73 5b 24 69 5d 20 3d 3d 3d 20 27 2a 27 29 | ===.'X'.||.$matches[$i].===.'*') |
968c0 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 61 74 63 68 65 73 5b | .{.....................$matches[ |
968e0 | 24 69 5d 20 3d 20 27 39 39 39 39 39 39 39 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | $i].=.'9999999';................ |
96900 | 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 73 74 | .}.............}.............$st |
96920 | 61 62 69 6c 69 74 79 53 75 66 66 69 78 20 3d 20 27 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | abilitySuffix.=.'';............. |
96940 | 69 66 20 28 65 6d 70 74 79 28 24 6d 61 74 63 68 65 73 5b 35 5d 29 20 26 26 20 65 6d 70 74 79 28 | if.(empty($matches[5]).&&.empty( |
96960 | 24 6d 61 74 63 68 65 73 5b 37 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | $matches[7])).{................. |
96980 | 24 73 74 61 62 69 6c 69 74 79 53 75 66 66 69 78 20 2e 3d 20 27 2d 64 65 76 27 3b 0a 20 20 20 20 | $stabilitySuffix..=.'-dev';..... |
969a0 | 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 6f 77 56 65 72 73 69 6f | ........}.............$lowVersio |
969c0 | 6e 20 3d 20 24 74 68 69 73 2d 3e 6e 6f 72 6d 61 6c 69 7a 65 28 5c 73 75 62 73 74 72 28 24 63 6f | n.=.$this->normalize(\substr($co |
969e0 | 6e 73 74 72 61 69 6e 74 20 2e 20 24 73 74 61 62 69 6c 69 74 79 53 75 66 66 69 78 2c 20 31 29 29 | nstraint...$stabilitySuffix,.1)) |
96a00 | 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 6f 77 65 72 42 6f 75 6e 64 20 3d 20 6e 65 77 20 | ;.............$lowerBound.=.new. |
96a20 | 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 | \HumbugBox3111\Composer\Semver\C |
96a40 | 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 28 27 3e 3d 27 2c 20 24 6c 6f 77 56 | onstraint\Constraint('>=',.$lowV |
96a60 | 65 72 73 69 6f 6e 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 68 69 67 68 50 6f 73 69 74 69 | ersion);.............$highPositi |
96a80 | 6f 6e 20 3d 20 5c 6d 61 78 28 31 2c 20 24 70 6f 73 69 74 69 6f 6e 20 2d 20 31 29 3b 0a 20 20 20 | on.=.\max(1,.$position.-.1);.... |
96aa0 | 20 20 20 20 20 20 20 20 20 24 68 69 67 68 56 65 72 73 69 6f 6e 20 3d 20 24 74 68 69 73 2d 3e 6d | .........$highVersion.=.$this->m |
96ac0 | 61 6e 69 70 75 6c 61 74 65 56 65 72 73 69 6f 6e 53 74 72 69 6e 67 28 24 6d 61 74 63 68 65 73 2c | anipulateVersionString($matches, |
96ae0 | 20 24 68 69 67 68 50 6f 73 69 74 69 6f 6e 2c 20 31 29 20 2e 20 27 2d 64 65 76 27 3b 0a 20 20 20 | .$highPosition,.1)...'-dev';.... |
96b00 | 20 20 20 20 20 20 20 20 20 24 75 70 70 65 72 42 6f 75 6e 64 20 3d 20 6e 65 77 20 5c 48 75 6d 62 | .........$upperBound.=.new.\Humb |
96b20 | 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 | ugBox3111\Composer\Semver\Constr |
96b40 | 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 28 27 3c 27 2c 20 24 68 69 67 68 56 65 72 73 69 6f | aint\Constraint('<',.$highVersio |
96b60 | 6e 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 61 72 72 61 79 28 24 6c 6f | n);.............return.array($lo |
96b80 | 77 65 72 42 6f 75 6e 64 2c 20 24 75 70 70 65 72 42 6f 75 6e 64 29 3b 0a 20 20 20 20 20 20 20 20 | werBound,.$upperBound);......... |
96ba0 | 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 5c 70 72 65 67 5f 6d 61 74 63 68 28 27 7b 5e 5c 5c 5e | }.........if.(\preg_match('{^\\^ |
96bc0 | 27 20 2e 20 24 76 65 72 73 69 6f 6e 52 65 67 65 78 20 2e 20 27 28 24 29 7d 69 27 2c 20 24 63 6f | '...$versionRegex...'($)}i',.$co |
96be0 | 6e 73 74 72 61 69 6e 74 2c 20 24 6d 61 74 63 68 65 73 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | nstraint,.$matches)).{.......... |
96c00 | 20 20 20 69 66 20 28 27 30 27 20 21 3d 3d 20 24 6d 61 74 63 68 65 73 5b 31 5d 20 7c 7c 20 27 27 | ...if.('0'.!==.$matches[1].||.'' |
96c20 | 20 3d 3d 3d 20 24 6d 61 74 63 68 65 73 5b 32 5d 20 7c 7c 20 6e 75 6c 6c 20 3d 3d 3d 20 24 6d 61 | .===.$matches[2].||.null.===.$ma |
96c40 | 74 63 68 65 73 5b 32 5d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 70 6f 73 | tches[2]).{.................$pos |
96c60 | 69 74 69 6f 6e 20 3d 20 31 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 | ition.=.1;.............}.elseif. |
96c80 | 28 27 30 27 20 21 3d 3d 20 24 6d 61 74 63 68 65 73 5b 32 5d 20 7c 7c 20 27 27 20 3d 3d 3d 20 24 | ('0'.!==.$matches[2].||.''.===.$ |
96ca0 | 6d 61 74 63 68 65 73 5b 33 5d 20 7c 7c 20 6e 75 6c 6c 20 3d 3d 3d 20 24 6d 61 74 63 68 65 73 5b | matches[3].||.null.===.$matches[ |
96cc0 | 33 5d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 70 6f 73 69 74 69 6f 6e 20 | 3]).{.................$position. |
96ce0 | 3d 20 32 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 | =.2;.............}.else.{....... |
96d00 | 20 20 20 20 20 20 20 20 20 20 24 70 6f 73 69 74 69 6f 6e 20 3d 20 33 3b 0a 20 20 20 20 20 20 20 | ..........$position.=.3;........ |
96d20 | 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 70 6f 73 69 74 69 6f 6e | .....}.............if.($position |
96d40 | 20 3d 3d 3d 20 32 20 26 26 20 28 24 6d 61 74 63 68 65 73 5b 32 5d 20 3d 3d 3d 20 27 78 27 20 7c | .===.2.&&.($matches[2].===.'x'.| |
96d60 | 7c 20 24 6d 61 74 63 68 65 73 5b 32 5d 20 3d 3d 3d 20 27 58 27 20 7c 7c 20 24 6d 61 74 63 68 65 | |.$matches[2].===.'X'.||.$matche |
96d80 | 73 5b 32 5d 20 3d 3d 3d 20 27 2a 27 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | s[2].===.'*')).{................ |
96da0 | 20 24 70 6f 73 69 74 69 6f 6e 20 3d 20 31 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 | .$position.=.1;.............}... |
96dc0 | 20 20 20 20 20 20 20 20 20 20 24 73 74 61 62 69 6c 69 74 79 53 75 66 66 69 78 20 3d 20 27 27 3b | ..........$stabilitySuffix.=.''; |
96de0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 65 6d 70 74 79 28 24 6d 61 74 63 68 65 73 5b | .............if.(empty($matches[ |
96e00 | 35 5d 29 20 26 26 20 65 6d 70 74 79 28 24 6d 61 74 63 68 65 73 5b 37 5d 29 29 20 7b 0a 20 20 20 | 5]).&&.empty($matches[7])).{.... |
96e20 | 20 20 20 20 20 20 20 20 20 20 20 20 20 24 73 74 61 62 69 6c 69 74 79 53 75 66 66 69 78 20 2e 3d | .............$stabilitySuffix..= |
96e40 | 20 27 2d 64 65 76 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 | .'-dev';.............}.......... |
96e60 | 20 20 20 24 6c 6f 77 56 65 72 73 69 6f 6e 20 3d 20 24 74 68 69 73 2d 3e 6e 6f 72 6d 61 6c 69 7a | ...$lowVersion.=.$this->normaliz |
96e80 | 65 28 5c 73 75 62 73 74 72 28 24 63 6f 6e 73 74 72 61 69 6e 74 20 2e 20 24 73 74 61 62 69 6c 69 | e(\substr($constraint...$stabili |
96ea0 | 74 79 53 75 66 66 69 78 2c 20 31 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 6f 77 65 | tySuffix,.1));.............$lowe |
96ec0 | 72 42 6f 75 6e 64 20 3d 20 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 | rBound.=.new.\HumbugBox3111\Comp |
96ee0 | 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e | oser\Semver\Constraint\Constrain |
96f00 | 74 28 27 3e 3d 27 2c 20 24 6c 6f 77 56 65 72 73 69 6f 6e 29 3b 0a 20 20 20 20 20 20 20 20 20 20 | t('>=',.$lowVersion);........... |
96f20 | 20 20 24 68 69 67 68 56 65 72 73 69 6f 6e 20 3d 20 24 74 68 69 73 2d 3e 6d 61 6e 69 70 75 6c 61 | ..$highVersion.=.$this->manipula |
96f40 | 74 65 56 65 72 73 69 6f 6e 53 74 72 69 6e 67 28 24 6d 61 74 63 68 65 73 2c 20 24 70 6f 73 69 74 | teVersionString($matches,.$posit |
96f60 | 69 6f 6e 2c 20 31 29 20 2e 20 27 2d 64 65 76 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 75 | ion,.1)...'-dev';.............$u |
96f80 | 70 70 65 72 42 6f 75 6e 64 20 3d 20 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 | pperBound.=.new.\HumbugBox3111\C |
96fa0 | 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 | omposer\Semver\Constraint\Constr |
96fc0 | 61 69 6e 74 28 27 3c 27 2c 20 24 68 69 67 68 56 65 72 73 69 6f 6e 29 3b 0a 20 20 20 20 20 20 20 | aint('<',.$highVersion);........ |
96fe0 | 20 20 20 20 20 72 65 74 75 72 6e 20 61 72 72 61 79 28 24 6c 6f 77 65 72 42 6f 75 6e 64 2c 20 24 | .....return.array($lowerBound,.$ |
97000 | 75 70 70 65 72 42 6f 75 6e 64 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 | upperBound);.........}.........i |
97020 | 66 20 28 5c 70 72 65 67 5f 6d 61 74 63 68 28 27 7b 5e 76 3f 28 5c 5c 64 2b 2b 29 28 3f 3a 5c 5c | f.(\preg_match('{^v?(\\d++)(?:\\ |
97040 | 2e 28 5c 5c 64 2b 2b 29 29 3f 28 3f 3a 5c 5c 2e 28 5c 5c 64 2b 2b 29 29 3f 28 3f 3a 5c 5c 2e 5b | .(\\d++))?(?:\\.(\\d++))?(?:\\.[ |
97060 | 78 58 2a 5d 29 2b 2b 24 7d 27 2c 20 24 63 6f 6e 73 74 72 61 69 6e 74 2c 20 24 6d 61 74 63 68 65 | xX*])++$}',.$constraint,.$matche |
97080 | 73 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 69 73 73 65 74 28 24 6d 61 74 | s)).{.............if.(isset($mat |
970a0 | 63 68 65 73 5b 33 5d 29 20 26 26 20 27 27 20 21 3d 3d 20 24 6d 61 74 63 68 65 73 5b 33 5d 20 26 | ches[3]).&&.''.!==.$matches[3].& |
970c0 | 26 20 6e 75 6c 6c 20 21 3d 3d 20 24 6d 61 74 63 68 65 73 5b 33 5d 29 20 7b 0a 20 20 20 20 20 20 | &.null.!==.$matches[3]).{....... |
970e0 | 20 20 20 20 20 20 20 20 20 20 24 70 6f 73 69 74 69 6f 6e 20 3d 20 33 3b 0a 20 20 20 20 20 20 20 | ..........$position.=.3;........ |
97100 | 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 69 73 73 65 74 28 24 6d 61 74 63 68 65 73 5b 32 5d | .....}.elseif.(isset($matches[2] |
97120 | 29 20 26 26 20 27 27 20 21 3d 3d 20 24 6d 61 74 63 68 65 73 5b 32 5d 20 26 26 20 6e 75 6c 6c 20 | ).&&.''.!==.$matches[2].&&.null. |
97140 | 21 3d 3d 20 24 6d 61 74 63 68 65 73 5b 32 5d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | !==.$matches[2]).{.............. |
97160 | 20 20 20 24 70 6f 73 69 74 69 6f 6e 20 3d 20 32 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 | ...$position.=.2;.............}. |
97180 | 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 70 6f 73 69 74 69 6f 6e | else.{.................$position |
971a0 | 20 3d 20 31 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 | .=.1;.............}............. |
971c0 | 24 6c 6f 77 56 65 72 73 69 6f 6e 20 3d 20 24 74 68 69 73 2d 3e 6d 61 6e 69 70 75 6c 61 74 65 56 | $lowVersion.=.$this->manipulateV |
971e0 | 65 72 73 69 6f 6e 53 74 72 69 6e 67 28 24 6d 61 74 63 68 65 73 2c 20 24 70 6f 73 69 74 69 6f 6e | ersionString($matches,.$position |
97200 | 29 20 2e 20 27 2d 64 65 76 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 68 69 67 68 56 65 72 | )...'-dev';.............$highVer |
97220 | 73 69 6f 6e 20 3d 20 24 74 68 69 73 2d 3e 6d 61 6e 69 70 75 6c 61 74 65 56 65 72 73 69 6f 6e 53 | sion.=.$this->manipulateVersionS |
97240 | 74 72 69 6e 67 28 24 6d 61 74 63 68 65 73 2c 20 24 70 6f 73 69 74 69 6f 6e 2c 20 31 29 20 2e 20 | tring($matches,.$position,.1)... |
97260 | 27 2d 64 65 76 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 6c 6f 77 56 65 72 73 | '-dev';.............if.($lowVers |
97280 | 69 6f 6e 20 3d 3d 3d 20 27 30 2e 30 2e 30 2e 30 2d 64 65 76 27 29 20 7b 0a 20 20 20 20 20 20 20 | ion.===.'0.0.0.0-dev').{........ |
972a0 | 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 61 72 72 61 79 28 6e 65 77 20 5c 48 75 6d 62 75 | .........return.array(new.\Humbu |
972c0 | 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 | gBox3111\Composer\Semver\Constra |
972e0 | 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 28 27 3c 27 2c 20 24 68 69 67 68 56 65 72 73 69 6f 6e | int\Constraint('<',.$highVersion |
97300 | 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 | ));.............}.............re |
97320 | 74 75 72 6e 20 61 72 72 61 79 28 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f | turn.array(new.\HumbugBox3111\Co |
97340 | 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 | mposer\Semver\Constraint\Constra |
97360 | 69 6e 74 28 27 3e 3d 27 2c 20 24 6c 6f 77 56 65 72 73 69 6f 6e 29 2c 20 6e 65 77 20 5c 48 75 6d | int('>=',.$lowVersion),.new.\Hum |
97380 | 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 | bugBox3111\Composer\Semver\Const |
973a0 | 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 28 27 3c 27 2c 20 24 68 69 67 68 56 65 72 73 69 | raint\Constraint('<',.$highVersi |
973c0 | 6f 6e 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 5c 70 72 65 | on));.........}.........if.(\pre |
973e0 | 67 5f 6d 61 74 63 68 28 27 7b 5e 28 3f 50 3c 66 72 6f 6d 3e 27 20 2e 20 24 76 65 72 73 69 6f 6e | g_match('{^(?P<from>'...$version |
97400 | 52 65 67 65 78 20 2e 20 27 29 20 2b 2d 20 2b 28 3f 50 3c 74 6f 3e 27 20 2e 20 24 76 65 72 73 69 | Regex...').+-.+(?P<to>'...$versi |
97420 | 6f 6e 52 65 67 65 78 20 2e 20 27 29 28 24 29 7d 69 27 2c 20 24 63 6f 6e 73 74 72 61 69 6e 74 2c | onRegex...')($)}i',.$constraint, |
97440 | 20 24 6d 61 74 63 68 65 73 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 6f 77 53 74 | .$matches)).{.............$lowSt |
97460 | 61 62 69 6c 69 74 79 53 75 66 66 69 78 20 3d 20 27 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | abilitySuffix.=.'';............. |
97480 | 69 66 20 28 65 6d 70 74 79 28 24 6d 61 74 63 68 65 73 5b 36 5d 29 20 26 26 20 65 6d 70 74 79 28 | if.(empty($matches[6]).&&.empty( |
974a0 | 24 6d 61 74 63 68 65 73 5b 38 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | $matches[8])).{................. |
974c0 | 24 6c 6f 77 53 74 61 62 69 6c 69 74 79 53 75 66 66 69 78 20 3d 20 27 2d 64 65 76 27 3b 0a 20 20 | $lowStabilitySuffix.=.'-dev';... |
974e0 | 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 6f 77 56 65 72 73 | ..........}.............$lowVers |
97500 | 69 6f 6e 20 3d 20 24 74 68 69 73 2d 3e 6e 6f 72 6d 61 6c 69 7a 65 28 24 6d 61 74 63 68 65 73 5b | ion.=.$this->normalize($matches[ |
97520 | 27 66 72 6f 6d 27 5d 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 6f 77 65 72 42 6f 75 6e | 'from']);.............$lowerBoun |
97540 | 64 20 3d 20 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c | d.=.new.\HumbugBox3111\Composer\ |
97560 | 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 28 27 3e 3d | Semver\Constraint\Constraint('>= |
97580 | 27 2c 20 24 6c 6f 77 56 65 72 73 69 6f 6e 20 2e 20 24 6c 6f 77 53 74 61 62 69 6c 69 74 79 53 75 | ',.$lowVersion...$lowStabilitySu |
975a0 | 66 66 69 78 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 65 6d 70 74 79 20 3d 20 66 75 6e 63 | ffix);.............$empty.=.func |
975c0 | 74 69 6f 6e 20 28 24 78 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 | tion.($x).{.................retu |
975e0 | 72 6e 20 24 78 20 3d 3d 3d 20 30 20 7c 7c 20 24 78 20 3d 3d 3d 20 27 30 27 20 3f 20 5c 66 61 6c | rn.$x.===.0.||.$x.===.'0'.?.\fal |
97600 | 73 65 20 3a 20 65 6d 70 74 79 28 24 78 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 3b 0a 20 | se.:.empty($x);.............};.. |
97620 | 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 21 24 65 6d 70 74 79 28 24 6d 61 74 63 68 65 73 5b | ...........if.(!$empty($matches[ |
97640 | 31 31 5d 29 20 26 26 20 21 24 65 6d 70 74 79 28 24 6d 61 74 63 68 65 73 5b 31 32 5d 29 20 7c 7c | 11]).&&.!$empty($matches[12]).|| |
97660 | 20 21 65 6d 70 74 79 28 24 6d 61 74 63 68 65 73 5b 31 34 5d 29 20 7c 7c 20 21 65 6d 70 74 79 28 | .!empty($matches[14]).||.!empty( |
97680 | 24 6d 61 74 63 68 65 73 5b 31 36 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | $matches[16])).{................ |
976a0 | 20 24 68 69 67 68 56 65 72 73 69 6f 6e 20 3d 20 24 74 68 69 73 2d 3e 6e 6f 72 6d 61 6c 69 7a 65 | .$highVersion.=.$this->normalize |
976c0 | 28 24 6d 61 74 63 68 65 73 5b 27 74 6f 27 5d 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ($matches['to']);............... |
976e0 | 20 20 24 75 70 70 65 72 42 6f 75 6e 64 20 3d 20 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 | ..$upperBound.=.new.\HumbugBox31 |
97700 | 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f | 11\Composer\Semver\Constraint\Co |
97720 | 6e 73 74 72 61 69 6e 74 28 27 3c 3d 27 2c 20 24 68 69 67 68 56 65 72 73 69 6f 6e 29 3b 0a 20 20 | nstraint('<=',.$highVersion);... |
97740 | 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | ..........}.else.{.............. |
97760 | 20 20 20 24 68 69 67 68 4d 61 74 63 68 20 3d 20 61 72 72 61 79 28 27 27 2c 20 24 6d 61 74 63 68 | ...$highMatch.=.array('',.$match |
97780 | 65 73 5b 31 30 5d 2c 20 24 6d 61 74 63 68 65 73 5b 31 31 5d 2c 20 24 6d 61 74 63 68 65 73 5b 31 | es[10],.$matches[11],.$matches[1 |
977a0 | 32 5d 2c 20 24 6d 61 74 63 68 65 73 5b 31 33 5d 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | 2],.$matches[13]);.............. |
977c0 | 20 20 20 24 74 68 69 73 2d 3e 6e 6f 72 6d 61 6c 69 7a 65 28 24 6d 61 74 63 68 65 73 5b 27 74 6f | ...$this->normalize($matches['to |
977e0 | 27 5d 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 68 69 67 68 56 65 72 73 69 6f | ']);.................$highVersio |
97800 | 6e 20 3d 20 24 74 68 69 73 2d 3e 6d 61 6e 69 70 75 6c 61 74 65 56 65 72 73 69 6f 6e 53 74 72 69 | n.=.$this->manipulateVersionStri |
97820 | 6e 67 28 24 68 69 67 68 4d 61 74 63 68 2c 20 24 65 6d 70 74 79 28 24 6d 61 74 63 68 65 73 5b 31 | ng($highMatch,.$empty($matches[1 |
97840 | 31 5d 29 20 3f 20 31 20 3a 20 32 2c 20 31 29 20 2e 20 27 2d 64 65 76 27 3b 0a 20 20 20 20 20 20 | 1]).?.1.:.2,.1)...'-dev';....... |
97860 | 20 20 20 20 20 20 20 20 20 20 24 75 70 70 65 72 42 6f 75 6e 64 20 3d 20 6e 65 77 20 5c 48 75 6d | ..........$upperBound.=.new.\Hum |
97880 | 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 | bugBox3111\Composer\Semver\Const |
978a0 | 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 28 27 3c 27 2c 20 24 68 69 67 68 56 65 72 73 69 | raint\Constraint('<',.$highVersi |
978c0 | 6f 6e 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 | on);.............}.............r |
978e0 | 65 74 75 72 6e 20 61 72 72 61 79 28 24 6c 6f 77 65 72 42 6f 75 6e 64 2c 20 24 75 70 70 65 72 42 | eturn.array($lowerBound,.$upperB |
97900 | 6f 75 6e 64 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 5c 70 72 | ound);.........}.........if.(\pr |
97920 | 65 67 5f 6d 61 74 63 68 28 27 7b 5e 28 3c 3e 7c 21 3d 7c 3e 3d 3f 7c 3c 3d 3f 7c 3d 3d 3f 29 3f | eg_match('{^(<>|!=|>=?|<=?|==?)? |
97940 | 5c 5c 73 2a 28 2e 2a 29 7d 27 2c 20 24 63 6f 6e 73 74 72 61 69 6e 74 2c 20 24 6d 61 74 63 68 65 | \\s*(.*)}',.$constraint,.$matche |
97960 | 73 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 72 79 20 7b 0a 20 20 20 20 20 20 20 20 | s)).{.............try.{......... |
97980 | 20 20 20 20 20 20 20 20 74 72 79 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ........try.{................... |
979a0 | 20 20 24 76 65 72 73 69 6f 6e 20 3d 20 24 74 68 69 73 2d 3e 6e 6f 72 6d 61 6c 69 7a 65 28 24 6d | ..$version.=.$this->normalize($m |
979c0 | 61 74 63 68 65 73 5b 32 5d 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 63 61 | atches[2]);.................}.ca |
979e0 | 74 63 68 20 28 5c 55 6e 65 78 70 65 63 74 65 64 56 61 6c 75 65 45 78 63 65 70 74 69 6f 6e 20 24 | tch.(\UnexpectedValueException.$ |
97a00 | 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 5c 73 75 | e).{.....................if.(\su |
97a20 | 62 73 74 72 28 24 6d 61 74 63 68 65 73 5b 32 5d 2c 20 2d 34 29 20 3d 3d 3d 20 27 2d 64 65 76 27 | bstr($matches[2],.-4).===.'-dev' |
97a40 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 76 65 72 | ).{.........................$ver |
97a60 | 73 69 6f 6e 20 3d 20 24 74 68 69 73 2d 3e 6e 6f 72 6d 61 6c 69 7a 65 28 27 64 65 76 2d 27 20 2e | sion.=.$this->normalize('dev-'.. |
97a80 | 20 5c 73 75 62 73 74 72 28 24 6d 61 74 63 68 65 73 5b 32 5d 2c 20 30 2c 20 2d 34 29 29 3b 0a 20 | .\substr($matches[2],.0,.-4));.. |
97aa0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 | ...................}.else.{..... |
97ac0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 24 65 3b 0a 20 20 | ....................throw.$e;... |
97ae0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ..................}............. |
97b00 | 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 70 20 3d 20 24 6d 61 74 | ....}.................$op.=.$mat |
97b20 | 63 68 65 73 5b 31 5d 20 3f 3a 20 27 3d 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ches[1].?:.'=';................. |
97b40 | 69 66 20 28 24 6f 70 20 21 3d 3d 20 27 3d 3d 27 20 26 26 20 24 6f 70 20 21 3d 3d 20 27 3d 27 20 | if.($op.!==.'=='.&&.$op.!==.'='. |
97b60 | 26 26 20 21 65 6d 70 74 79 28 24 73 74 61 62 69 6c 69 74 79 4d 6f 64 69 66 69 65 72 29 20 26 26 | &&.!empty($stabilityModifier).&& |
97b80 | 20 73 65 6c 66 3a 3a 70 61 72 73 65 53 74 61 62 69 6c 69 74 79 28 24 76 65 72 73 69 6f 6e 29 20 | .self::parseStability($version). |
97ba0 | 3d 3d 3d 20 27 73 74 61 62 6c 65 27 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ===.'stable').{................. |
97bc0 | 20 20 20 20 24 76 65 72 73 69 6f 6e 20 2e 3d 20 27 2d 27 20 2e 20 24 73 74 61 62 69 6c 69 74 79 | ....$version..=.'-'...$stability |
97be0 | 4d 6f 64 69 66 69 65 72 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 | Modifier;.................}.else |
97c00 | 69 66 20 28 27 3c 27 20 3d 3d 3d 20 24 6f 70 20 7c 7c 20 27 3e 3d 27 20 3d 3d 3d 20 24 6f 70 29 | if.('<'.===.$op.||.'>='.===.$op) |
97c20 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 21 5c 70 72 65 | .{.....................if.(!\pre |
97c40 | 67 5f 6d 61 74 63 68 28 27 2f 2d 27 20 2e 20 73 65 6c 66 3a 3a 24 6d 6f 64 69 66 69 65 72 52 65 | g_match('/-'...self::$modifierRe |
97c60 | 67 65 78 20 2e 20 27 24 2f 27 2c 20 5c 73 74 72 74 6f 6c 6f 77 65 72 28 24 6d 61 74 63 68 65 73 | gex...'$/',.\strtolower($matches |
97c80 | 5b 32 5d 29 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | [2]))).{........................ |
97ca0 | 20 69 66 20 28 5c 73 74 72 70 6f 73 28 24 6d 61 74 63 68 65 73 5b 32 5d 2c 20 27 64 65 76 2d 27 | .if.(\strpos($matches[2],.'dev-' |
97cc0 | 29 20 21 3d 3d 20 30 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ).!==.0).{...................... |
97ce0 | 20 20 20 20 20 20 20 24 76 65 72 73 69 6f 6e 20 2e 3d 20 27 2d 64 65 76 27 3b 0a 20 20 20 20 20 | .......$version..=.'-dev';...... |
97d00 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 | ...................}............ |
97d20 | 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 | .........}.................}.... |
97d40 | 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 61 72 72 61 79 28 6e 65 77 20 5c 48 | .............return.array(new.\H |
97d60 | 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e | umbugBox3111\Composer\Semver\Con |
97d80 | 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 28 24 6d 61 74 63 68 65 73 5b 31 5d 20 3f | straint\Constraint($matches[1].? |
97da0 | 3a 20 27 3d 27 2c 20 24 76 65 72 73 69 6f 6e 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d | :.'=',.$version));.............} |
97dc0 | 20 63 61 74 63 68 20 28 5c 45 78 63 65 70 74 69 6f 6e 20 24 65 29 20 7b 0a 20 20 20 20 20 20 20 | .catch.(\Exception.$e).{........ |
97de0 | 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 | .....}.........}.........$messag |
97e00 | 65 20 3d 20 27 43 6f 75 6c 64 20 6e 6f 74 20 70 61 72 73 65 20 76 65 72 73 69 6f 6e 20 63 6f 6e | e.=.'Could.not.parse.version.con |
97e20 | 73 74 72 61 69 6e 74 20 27 20 2e 20 24 63 6f 6e 73 74 72 61 69 6e 74 3b 0a 20 20 20 20 20 20 20 | straint.'...$constraint;........ |
97e40 | 20 69 66 20 28 69 73 73 65 74 28 24 65 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6d | .if.(isset($e)).{.............$m |
97e60 | 65 73 73 61 67 65 20 2e 3d 20 27 3a 20 27 20 2e 20 24 65 2d 3e 67 65 74 4d 65 73 73 61 67 65 28 | essage..=.':.'...$e->getMessage( |
97e80 | 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 5c | );.........}.........throw.new.\ |
97ea0 | 55 6e 65 78 70 65 63 74 65 64 56 61 6c 75 65 45 78 63 65 70 74 69 6f 6e 28 24 6d 65 73 73 61 67 | UnexpectedValueException($messag |
97ec0 | 65 29 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 6d | e);.....}.....private.function.m |
97ee0 | 61 6e 69 70 75 6c 61 74 65 56 65 72 73 69 6f 6e 53 74 72 69 6e 67 28 24 6d 61 74 63 68 65 73 2c | anipulateVersionString($matches, |
97f00 | 20 24 70 6f 73 69 74 69 6f 6e 2c 20 24 69 6e 63 72 65 6d 65 6e 74 20 3d 20 30 2c 20 24 70 61 64 | .$position,.$increment.=.0,.$pad |
97f20 | 20 3d 20 27 30 27 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 66 6f 72 20 28 24 69 20 3d 20 | .=.'0').....{.........for.($i.=. |
97f40 | 34 3b 20 24 69 20 3e 20 30 3b 20 2d 2d 24 69 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 | 4;.$i.>.0;.--$i).{.............i |
97f60 | 66 20 28 24 69 20 3e 20 24 70 6f 73 69 74 69 6f 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | f.($i.>.$position).{............ |
97f80 | 20 20 20 20 20 24 6d 61 74 63 68 65 73 5b 24 69 5d 20 3d 20 24 70 61 64 3b 0a 20 20 20 20 20 20 | .....$matches[$i].=.$pad;....... |
97fa0 | 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 24 69 20 3d 3d 3d 20 24 70 6f 73 69 74 69 6f 6e | ......}.elseif.($i.===.$position |
97fc0 | 20 26 26 20 24 69 6e 63 72 65 6d 65 6e 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | .&&.$increment).{............... |
97fe0 | 20 20 24 6d 61 74 63 68 65 73 5b 24 69 5d 20 2b 3d 20 24 69 6e 63 72 65 6d 65 6e 74 3b 0a 20 20 | ..$matches[$i].+=.$increment;... |
98000 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 6d 61 74 63 68 65 73 5b 24 69 5d 20 3c | ..............if.($matches[$i].< |
98020 | 20 30 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 61 74 63 68 | .0).{.....................$match |
98040 | 65 73 5b 24 69 5d 20 3d 20 24 70 61 64 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | es[$i].=.$pad;.................. |
98060 | 20 20 20 2d 2d 24 70 6f 73 69 74 69 6f 6e 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ...--$position;................. |
98080 | 20 20 20 20 69 66 20 28 24 69 20 3d 3d 3d 20 31 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ....if.($i.===.1).{............. |
980a0 | 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6e 75 6c 6c 3b 0a 20 20 20 20 20 20 20 | ............return.null;........ |
980c0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d | .............}.................} |
980e0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 | .............}.........}........ |
98100 | 20 72 65 74 75 72 6e 20 24 6d 61 74 63 68 65 73 5b 31 5d 20 2e 20 27 2e 27 20 2e 20 24 6d 61 74 | .return.$matches[1]...'.'...$mat |
98120 | 63 68 65 73 5b 32 5d 20 2e 20 27 2e 27 20 2e 20 24 6d 61 74 63 68 65 73 5b 33 5d 20 2e 20 27 2e | ches[2]...'.'...$matches[3]...'. |
98140 | 27 20 2e 20 24 6d 61 74 63 68 65 73 5b 34 5d 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 72 69 76 61 | '...$matches[4];.....}.....priva |
98160 | 74 65 20 66 75 6e 63 74 69 6f 6e 20 65 78 70 61 6e 64 53 74 61 62 69 6c 69 74 79 28 24 73 74 61 | te.function.expandStability($sta |
98180 | 62 69 6c 69 74 79 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 73 74 61 62 69 6c 69 74 79 | bility).....{.........$stability |
981a0 | 20 3d 20 5c 73 74 72 74 6f 6c 6f 77 65 72 28 24 73 74 61 62 69 6c 69 74 79 29 3b 0a 20 20 20 20 | .=.\strtolower($stability);..... |
981c0 | 20 20 20 20 73 77 69 74 63 68 20 28 24 73 74 61 62 69 6c 69 74 79 29 20 7b 0a 20 20 20 20 20 20 | ....switch.($stability).{....... |
981e0 | 20 20 20 20 20 20 63 61 73 65 20 27 61 27 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ......case.'a':................. |
98200 | 72 65 74 75 72 6e 20 27 61 6c 70 68 61 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 63 61 73 65 | return.'alpha';.............case |
98220 | 20 27 62 27 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 27 62 65 | .'b':.................return.'be |
98240 | 74 61 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 63 61 73 65 20 27 70 27 3a 0a 20 20 20 20 20 | ta';.............case.'p':...... |
98260 | 20 20 20 20 20 20 20 63 61 73 65 20 27 70 6c 27 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | .......case.'pl':............... |
98280 | 20 20 72 65 74 75 72 6e 20 27 70 61 74 63 68 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 63 61 | ..return.'patch';.............ca |
982a0 | 73 65 20 27 72 63 27 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 | se.'rc':.................return. |
982c0 | 27 52 43 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 64 65 66 61 75 6c 74 3a 0a 20 20 20 20 20 | 'RC';.............default:...... |
982e0 | 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 73 74 61 62 69 6c 69 74 79 3b 0a 20 20 | ...........return.$stability;... |
98300 | 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 6e 61 6d 65 73 70 61 63 65 | ......}.....}.}.<?php..namespace |
98320 | 20 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 3b 0a | .HumbugBox3111\Composer\Semver;. |
98340 | 0a 75 73 65 20 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 | .use.HumbugBox3111\Composer\Semv |
98360 | 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 3b 0a 63 6c 61 73 73 20 | er\Constraint\Constraint;.class. |
98380 | 53 65 6d 76 65 72 0a 7b 0a 20 20 20 20 63 6f 6e 73 74 20 53 4f 52 54 5f 41 53 43 20 3d 20 31 3b | Semver.{.....const.SORT_ASC.=.1; |
983a0 | 0a 20 20 20 20 63 6f 6e 73 74 20 53 4f 52 54 5f 44 45 53 43 20 3d 20 2d 31 3b 0a 20 20 20 20 70 | .....const.SORT_DESC.=.-1;.....p |
983c0 | 72 69 76 61 74 65 20 73 74 61 74 69 63 20 24 76 65 72 73 69 6f 6e 50 61 72 73 65 72 3b 0a 20 20 | rivate.static.$versionParser;... |
983e0 | 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 61 74 69 73 66 69 | ..public.static.function.satisfi |
98400 | 65 73 28 24 76 65 72 73 69 6f 6e 2c 20 24 63 6f 6e 73 74 72 61 69 6e 74 73 29 0a 20 20 20 20 7b | es($version,.$constraints).....{ |
98420 | 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 73 65 6c 66 3a 3a 24 76 65 72 | .........if.(null.===.self::$ver |
98440 | 73 69 6f 6e 50 61 72 73 65 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 73 65 6c 66 3a 3a | sionParser).{.............self:: |
98460 | 24 76 65 72 73 69 6f 6e 50 61 72 73 65 72 20 3d 20 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 | $versionParser.=.new.\HumbugBox3 |
98480 | 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 56 65 72 73 69 6f 6e 50 61 72 73 65 | 111\Composer\Semver\VersionParse |
984a0 | 72 28 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 24 76 65 72 73 69 6f 6e 50 | r();.........}.........$versionP |
984c0 | 61 72 73 65 72 20 3d 20 73 65 6c 66 3a 3a 24 76 65 72 73 69 6f 6e 50 61 72 73 65 72 3b 0a 20 20 | arser.=.self::$versionParser;... |
984e0 | 20 20 20 20 20 20 24 70 72 6f 76 69 64 65 72 20 3d 20 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 | ......$provider.=.new.\HumbugBox |
98500 | 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c | 3111\Composer\Semver\Constraint\ |
98520 | 43 6f 6e 73 74 72 61 69 6e 74 28 27 3d 3d 27 2c 20 24 76 65 72 73 69 6f 6e 50 61 72 73 65 72 2d | Constraint('==',.$versionParser- |
98540 | 3e 6e 6f 72 6d 61 6c 69 7a 65 28 24 76 65 72 73 69 6f 6e 29 29 3b 0a 20 20 20 20 20 20 20 20 24 | >normalize($version));.........$ |
98560 | 70 61 72 73 65 64 43 6f 6e 73 74 72 61 69 6e 74 73 20 3d 20 24 76 65 72 73 69 6f 6e 50 61 72 73 | parsedConstraints.=.$versionPars |
98580 | 65 72 2d 3e 70 61 72 73 65 43 6f 6e 73 74 72 61 69 6e 74 73 28 24 63 6f 6e 73 74 72 61 69 6e 74 | er->parseConstraints($constraint |
985a0 | 73 29 3b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 70 61 72 73 65 64 43 6f 6e 73 74 72 | s);.........return.$parsedConstr |
985c0 | 61 69 6e 74 73 2d 3e 6d 61 74 63 68 65 73 28 24 70 72 6f 76 69 64 65 72 29 3b 0a 20 20 20 20 7d | aints->matches($provider);.....} |
985e0 | 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 61 74 69 | .....public.static.function.sati |
98600 | 73 66 69 65 64 42 79 28 61 72 72 61 79 20 24 76 65 72 73 69 6f 6e 73 2c 20 24 63 6f 6e 73 74 72 | sfiedBy(array.$versions,.$constr |
98620 | 61 69 6e 74 73 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 76 65 72 73 69 6f 6e 73 20 3d | aints).....{.........$versions.= |
98640 | 20 5c 61 72 72 61 79 5f 66 69 6c 74 65 72 28 24 76 65 72 73 69 6f 6e 73 2c 20 66 75 6e 63 74 69 | .\array_filter($versions,.functi |
98660 | 6f 6e 20 28 24 76 65 72 73 69 6f 6e 29 20 75 73 65 28 24 63 6f 6e 73 74 72 61 69 6e 74 73 29 20 | on.($version).use($constraints). |
98680 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 5c 48 75 6d 62 75 67 42 6f 78 33 | {.............return.\HumbugBox3 |
986a0 | 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 53 65 6d 76 65 72 3a 3a 73 61 74 69 | 111\Composer\Semver\Semver::sati |
986c0 | 73 66 69 65 73 28 24 76 65 72 73 69 6f 6e 2c 20 24 63 6f 6e 73 74 72 61 69 6e 74 73 29 3b 0a 20 | sfies($version,.$constraints);.. |
986e0 | 20 20 20 20 20 20 20 7d 29 3b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 5c 61 72 72 61 79 | .......});.........return.\array |
98700 | 5f 76 61 6c 75 65 73 28 24 76 65 72 73 69 6f 6e 73 29 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 | _values($versions);.....}.....pu |
98720 | 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 6f 72 74 28 61 72 72 61 79 20 | blic.static.function.sort(array. |
98740 | 24 76 65 72 73 69 6f 6e 73 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 | $versions).....{.........return. |
98760 | 73 65 6c 66 3a 3a 75 73 6f 72 74 28 24 76 65 72 73 69 6f 6e 73 2c 20 73 65 6c 66 3a 3a 53 4f 52 | self::usort($versions,.self::SOR |
98780 | 54 5f 41 53 43 29 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 | T_ASC);.....}.....public.static. |
987a0 | 66 75 6e 63 74 69 6f 6e 20 72 73 6f 72 74 28 61 72 72 61 79 20 24 76 65 72 73 69 6f 6e 73 29 0a | function.rsort(array.$versions). |
987c0 | 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 3a 3a 75 73 6f 72 74 | ....{.........return.self::usort |
987e0 | 28 24 76 65 72 73 69 6f 6e 73 2c 20 73 65 6c 66 3a 3a 53 4f 52 54 5f 44 45 53 43 29 3b 0a 20 20 | ($versions,.self::SORT_DESC);... |
98800 | 20 20 7d 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 | ..}.....private.static.function. |
98820 | 75 73 6f 72 74 28 61 72 72 61 79 20 24 76 65 72 73 69 6f 6e 73 2c 20 24 64 69 72 65 63 74 69 6f | usort(array.$versions,.$directio |
98840 | 6e 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 73 65 | n).....{.........if.(null.===.se |
98860 | 6c 66 3a 3a 24 76 65 72 73 69 6f 6e 50 61 72 73 65 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | lf::$versionParser).{........... |
98880 | 20 20 73 65 6c 66 3a 3a 24 76 65 72 73 69 6f 6e 50 61 72 73 65 72 20 3d 20 6e 65 77 20 5c 48 75 | ..self::$versionParser.=.new.\Hu |
988a0 | 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 56 65 72 73 | mbugBox3111\Composer\Semver\Vers |
988c0 | 69 6f 6e 50 61 72 73 65 72 28 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 24 | ionParser();.........}.........$ |
988e0 | 76 65 72 73 69 6f 6e 50 61 72 73 65 72 20 3d 20 73 65 6c 66 3a 3a 24 76 65 72 73 69 6f 6e 50 61 | versionParser.=.self::$versionPa |
98900 | 72 73 65 72 3b 0a 20 20 20 20 20 20 20 20 24 6e 6f 72 6d 61 6c 69 7a 65 64 20 3d 20 61 72 72 61 | rser;.........$normalized.=.arra |
98920 | 79 28 29 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 76 65 72 73 69 6f 6e 73 20 | y();.........foreach.($versions. |
98940 | 61 73 20 24 6b 65 79 20 3d 3e 20 24 76 65 72 73 69 6f 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | as.$key.=>.$version).{.......... |
98960 | 20 20 20 24 6e 6f 72 6d 61 6c 69 7a 65 64 56 65 72 73 69 6f 6e 20 3d 20 24 76 65 72 73 69 6f 6e | ...$normalizedVersion.=.$version |
98980 | 50 61 72 73 65 72 2d 3e 6e 6f 72 6d 61 6c 69 7a 65 28 24 76 65 72 73 69 6f 6e 29 3b 0a 20 20 20 | Parser->normalize($version);.... |
989a0 | 20 20 20 20 20 20 20 20 20 24 6e 6f 72 6d 61 6c 69 7a 65 64 56 65 72 73 69 6f 6e 20 3d 20 24 76 | .........$normalizedVersion.=.$v |
989c0 | 65 72 73 69 6f 6e 50 61 72 73 65 72 2d 3e 6e 6f 72 6d 61 6c 69 7a 65 44 65 66 61 75 6c 74 42 72 | ersionParser->normalizeDefaultBr |
989e0 | 61 6e 63 68 28 24 6e 6f 72 6d 61 6c 69 7a 65 64 56 65 72 73 69 6f 6e 29 3b 0a 20 20 20 20 20 20 | anch($normalizedVersion);....... |
98a00 | 20 20 20 20 20 20 24 6e 6f 72 6d 61 6c 69 7a 65 64 5b 5d 20 3d 20 61 72 72 61 79 28 24 6e 6f 72 | ......$normalized[].=.array($nor |
98a20 | 6d 61 6c 69 7a 65 64 56 65 72 73 69 6f 6e 2c 20 24 6b 65 79 29 3b 0a 20 20 20 20 20 20 20 20 7d | malizedVersion,.$key);.........} |
98a40 | 0a 20 20 20 20 20 20 20 20 5c 75 73 6f 72 74 28 24 6e 6f 72 6d 61 6c 69 7a 65 64 2c 20 66 75 6e | .........\usort($normalized,.fun |
98a60 | 63 74 69 6f 6e 20 28 61 72 72 61 79 20 24 6c 65 66 74 2c 20 61 72 72 61 79 20 24 72 69 67 68 74 | ction.(array.$left,.array.$right |
98a80 | 29 20 75 73 65 28 24 64 69 72 65 63 74 69 6f 6e 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ).use($direction).{............. |
98aa0 | 69 66 20 28 24 6c 65 66 74 5b 30 5d 20 3d 3d 3d 20 24 72 69 67 68 74 5b 30 5d 29 20 7b 0a 20 20 | if.($left[0].===.$right[0]).{... |
98ac0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 30 3b 0a 20 20 20 20 20 20 20 20 | ..............return.0;......... |
98ae0 | 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 5c 48 75 6d 62 75 67 42 6f 78 | ....}.............if.(\HumbugBox |
98b00 | 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6d 70 61 72 61 74 6f 72 3a | 3111\Composer\Semver\Comparator: |
98b20 | 3a 6c 65 73 73 54 68 61 6e 28 24 6c 65 66 74 5b 30 5d 2c 20 24 72 69 67 68 74 5b 30 5d 29 29 20 | :lessThan($left[0],.$right[0])). |
98b40 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 2d 24 64 69 72 65 63 | {.................return.-$direc |
98b60 | 74 69 6f 6e 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 | tion;.............}............. |
98b80 | 72 65 74 75 72 6e 20 24 64 69 72 65 63 74 69 6f 6e 3b 0a 20 20 20 20 20 20 20 20 7d 29 3b 0a 20 | return.$direction;.........});.. |
98ba0 | 20 20 20 20 20 20 20 24 73 6f 72 74 65 64 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 | .......$sorted.=.array();....... |
98bc0 | 20 20 66 6f 72 65 61 63 68 20 28 24 6e 6f 72 6d 61 6c 69 7a 65 64 20 61 73 20 24 69 74 65 6d 29 | ..foreach.($normalized.as.$item) |
98be0 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 73 6f 72 74 65 64 5b 5d 20 3d 20 24 76 65 72 73 | .{.............$sorted[].=.$vers |
98c00 | 69 6f 6e 73 5b 24 69 74 65 6d 5b 31 5d 5d 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 | ions[$item[1]];.........}....... |
98c20 | 20 20 72 65 74 75 72 6e 20 24 73 6f 72 74 65 64 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a | ..return.$sorted;.....}.}.<?php. |
98c40 | 0a 6e 61 6d 65 73 70 61 63 65 20 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 | .namespace.HumbugBox3111\Compose |
98c60 | 72 5c 53 65 6d 76 65 72 3b 0a 0a 75 73 65 20 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d | r\Semver;..use.HumbugBox3111\Com |
98c80 | 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 | poser\Semver\Constraint\Constrai |
98ca0 | 6e 74 3b 0a 75 73 65 20 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 | nt;.use.HumbugBox3111\Composer\S |
98cc0 | 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 49 6e 74 65 72 | emver\Constraint\ConstraintInter |
98ce0 | 66 61 63 65 3b 0a 75 73 65 20 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 | face;.use.HumbugBox3111\Composer |
98d00 | 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 4d 61 74 63 68 41 6c 6c 43 6f 6e 73 74 | \Semver\Constraint\MatchAllConst |
98d20 | 72 61 69 6e 74 3b 0a 75 73 65 20 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 | raint;.use.HumbugBox3111\Compose |
98d40 | 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 4d 61 74 63 68 4e 6f 6e 65 43 6f 6e | r\Semver\Constraint\MatchNoneCon |
98d60 | 73 74 72 61 69 6e 74 3b 0a 75 73 65 20 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f | straint;.use.HumbugBox3111\Compo |
98d80 | 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 4d 75 6c 74 69 43 6f 6e 73 74 | ser\Semver\Constraint\MultiConst |
98da0 | 72 61 69 6e 74 3b 0a 63 6c 61 73 73 20 49 6e 74 65 72 76 61 6c 73 0a 7b 0a 20 20 20 20 2f 2a 2a | raint;.class.Intervals.{...../** |
98dc0 | 0a 20 20 20 20 40 70 68 70 73 74 61 6e 2d 76 61 72 0a 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 | .....@phpstan-var.....*/.....pri |
98de0 | 76 61 74 65 20 73 74 61 74 69 63 20 24 69 6e 74 65 72 76 61 6c 73 43 61 63 68 65 20 3d 20 61 72 | vate.static.$intervalsCache.=.ar |
98e00 | 72 61 79 28 29 3b 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 40 70 68 70 73 74 61 6e 2d 76 61 72 0a | ray();...../**.....@phpstan-var. |
98e20 | 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 24 6f 70 53 6f 72 | ....*/.....private.static.$opSor |
98e40 | 74 4f 72 64 65 72 20 3d 20 61 72 72 61 79 28 27 3e 3d 27 20 3d 3e 20 2d 33 2c 20 27 3c 27 20 3d | tOrder.=.array('>='.=>.-3,.'<'.= |
98e60 | 3e 20 2d 32 2c 20 27 3e 27 20 3d 3e 20 32 2c 20 27 3c 3d 27 20 3d 3e 20 33 29 3b 0a 20 20 20 20 | >.-2,.'>'.=>.2,.'<='.=>.3);..... |
98e80 | 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 63 6c 65 61 72 28 29 0a 20 | public.static.function.clear().. |
98ea0 | 20 20 20 7b 0a 20 20 20 20 20 20 20 20 73 65 6c 66 3a 3a 24 69 6e 74 65 72 76 61 6c 73 43 61 63 | ...{.........self::$intervalsCac |
98ec0 | 68 65 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 73 | he.=.array();.....}.....public.s |
98ee0 | 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 69 73 53 75 62 73 65 74 4f 66 28 5c 48 75 6d 62 75 | tatic.function.isSubsetOf(\Humbu |
98f00 | 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 | gBox3111\Composer\Semver\Constra |
98f20 | 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 49 6e 74 65 72 66 61 63 65 20 24 63 61 6e 64 69 64 61 | int\ConstraintInterface.$candida |
98f40 | 74 65 2c 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 | te,.\HumbugBox3111\Composer\Semv |
98f60 | 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 49 6e 74 65 72 66 61 63 | er\Constraint\ConstraintInterfac |
98f80 | 65 20 24 63 6f 6e 73 74 72 61 69 6e 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 | e.$constraint).....{.........if. |
98fa0 | 28 24 63 6f 6e 73 74 72 61 69 6e 74 20 69 6e 73 74 61 6e 63 65 6f 66 20 5c 48 75 6d 62 75 67 42 | ($constraint.instanceof.\HumbugB |
98fc0 | 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e | ox3111\Composer\Semver\Constrain |
98fe0 | 74 5c 4d 61 74 63 68 41 6c 6c 43 6f 6e 73 74 72 61 69 6e 74 29 20 7b 0a 20 20 20 20 20 20 20 20 | t\MatchAllConstraint).{......... |
99000 | 20 20 20 20 72 65 74 75 72 6e 20 5c 74 72 75 65 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 | ....return.\true;.........}..... |
99020 | 20 20 20 20 69 66 20 28 24 63 61 6e 64 69 64 61 74 65 20 69 6e 73 74 61 6e 63 65 6f 66 20 5c 48 | ....if.($candidate.instanceof.\H |
99040 | 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e | umbugBox3111\Composer\Semver\Con |
99060 | 73 74 72 61 69 6e 74 5c 4d 61 74 63 68 4e 6f 6e 65 43 6f 6e 73 74 72 61 69 6e 74 20 7c 7c 20 24 | straint\MatchNoneConstraint.||.$ |
99080 | 63 6f 6e 73 74 72 61 69 6e 74 20 69 6e 73 74 61 6e 63 65 6f 66 20 5c 48 75 6d 62 75 67 42 6f 78 | constraint.instanceof.\HumbugBox |
990a0 | 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c | 3111\Composer\Semver\Constraint\ |
990c0 | 4d 61 74 63 68 4e 6f 6e 65 43 6f 6e 73 74 72 61 69 6e 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | MatchNoneConstraint).{.......... |
990e0 | 20 20 20 72 65 74 75 72 6e 20 5c 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 | ...return.\false;.........}..... |
99100 | 20 20 20 20 24 69 6e 74 65 72 73 65 63 74 69 6f 6e 49 6e 74 65 72 76 61 6c 73 20 3d 20 73 65 6c | ....$intersectionIntervals.=.sel |
99120 | 66 3a 3a 67 65 74 28 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 | f::get(new.\HumbugBox3111\Compos |
99140 | 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 4d 75 6c 74 69 43 6f 6e 73 74 72 | er\Semver\Constraint\MultiConstr |
99160 | 61 69 6e 74 28 61 72 72 61 79 28 24 63 61 6e 64 69 64 61 74 65 2c 20 24 63 6f 6e 73 74 72 61 69 | aint(array($candidate,.$constrai |
99180 | 6e 74 29 2c 20 5c 74 72 75 65 29 29 3b 0a 20 20 20 20 20 20 20 20 24 63 61 6e 64 69 64 61 74 65 | nt),.\true));.........$candidate |
991a0 | 49 6e 74 65 72 76 61 6c 73 20 3d 20 73 65 6c 66 3a 3a 67 65 74 28 24 63 61 6e 64 69 64 61 74 65 | Intervals.=.self::get($candidate |
991c0 | 29 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 5c 63 6f 75 6e 74 28 24 69 6e 74 65 72 73 65 63 74 | );.........if.(\count($intersect |
991e0 | 69 6f 6e 49 6e 74 65 72 76 61 6c 73 5b 27 6e 75 6d 65 72 69 63 27 5d 29 20 21 3d 3d 20 5c 63 6f | ionIntervals['numeric']).!==.\co |
99200 | 75 6e 74 28 24 63 61 6e 64 69 64 61 74 65 49 6e 74 65 72 76 61 6c 73 5b 27 6e 75 6d 65 72 69 63 | unt($candidateIntervals['numeric |
99220 | 27 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 5c 66 61 6c 73 65 | '])).{.............return.\false |
99240 | 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 69 6e | ;.........}.........foreach.($in |
99260 | 74 65 72 73 65 63 74 69 6f 6e 49 6e 74 65 72 76 61 6c 73 5b 27 6e 75 6d 65 72 69 63 27 5d 20 61 | tersectionIntervals['numeric'].a |
99280 | 73 20 24 69 6e 64 65 78 20 3d 3e 20 24 69 6e 74 65 72 76 61 6c 29 20 7b 0a 20 20 20 20 20 20 20 | s.$index.=>.$interval).{........ |
992a0 | 20 20 20 20 20 69 66 20 28 21 69 73 73 65 74 28 24 63 61 6e 64 69 64 61 74 65 49 6e 74 65 72 76 | .....if.(!isset($candidateInterv |
992c0 | 61 6c 73 5b 27 6e 75 6d 65 72 69 63 27 5d 5b 24 69 6e 64 65 78 5d 29 29 20 7b 0a 20 20 20 20 20 | als['numeric'][$index])).{...... |
992e0 | 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 5c 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 | ...........return.\false;....... |
99300 | 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 28 73 74 72 69 6e 67 29 | ......}.............if.((string) |
99320 | 20 24 63 61 6e 64 69 64 61 74 65 49 6e 74 65 72 76 61 6c 73 5b 27 6e 75 6d 65 72 69 63 27 5d 5b | .$candidateIntervals['numeric'][ |
99340 | 24 69 6e 64 65 78 5d 2d 3e 67 65 74 53 74 61 72 74 28 29 20 21 3d 3d 20 28 73 74 72 69 6e 67 29 | $index]->getStart().!==.(string) |
99360 | 20 24 69 6e 74 65 72 76 61 6c 2d 3e 67 65 74 53 74 61 72 74 28 29 29 20 7b 0a 20 20 20 20 20 20 | .$interval->getStart()).{....... |
99380 | 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 5c 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 | ..........return.\false;........ |
993a0 | 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 28 73 74 72 69 6e 67 29 20 | .....}.............if.((string). |
993c0 | 24 63 61 6e 64 69 64 61 74 65 49 6e 74 65 72 76 61 6c 73 5b 27 6e 75 6d 65 72 69 63 27 5d 5b 24 | $candidateIntervals['numeric'][$ |
993e0 | 69 6e 64 65 78 5d 2d 3e 67 65 74 45 6e 64 28 29 20 21 3d 3d 20 28 73 74 72 69 6e 67 29 20 24 69 | index]->getEnd().!==.(string).$i |
99400 | 6e 74 65 72 76 61 6c 2d 3e 67 65 74 45 6e 64 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | nterval->getEnd()).{............ |
99420 | 20 20 20 20 20 72 65 74 75 72 6e 20 5c 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | .....return.\false;............. |
99440 | 7d 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 69 6e 74 65 72 73 65 | }.........}.........if.($interse |
99460 | 63 74 69 6f 6e 49 6e 74 65 72 76 61 6c 73 5b 27 62 72 61 6e 63 68 65 73 27 5d 5b 27 65 78 63 6c | ctionIntervals['branches']['excl |
99480 | 75 64 65 27 5d 20 21 3d 3d 20 24 63 61 6e 64 69 64 61 74 65 49 6e 74 65 72 76 61 6c 73 5b 27 62 | ude'].!==.$candidateIntervals['b |
994a0 | 72 61 6e 63 68 65 73 27 5d 5b 27 65 78 63 6c 75 64 65 27 5d 29 20 7b 0a 20 20 20 20 20 20 20 20 | ranches']['exclude']).{......... |
994c0 | 20 20 20 20 72 65 74 75 72 6e 20 5c 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 | ....return.\false;.........}.... |
994e0 | 20 20 20 20 20 69 66 20 28 5c 63 6f 75 6e 74 28 24 69 6e 74 65 72 73 65 63 74 69 6f 6e 49 6e 74 | .....if.(\count($intersectionInt |
99500 | 65 72 76 61 6c 73 5b 27 62 72 61 6e 63 68 65 73 27 5d 5b 27 6e 61 6d 65 73 27 5d 29 20 21 3d 3d | ervals['branches']['names']).!== |
99520 | 20 5c 63 6f 75 6e 74 28 24 63 61 6e 64 69 64 61 74 65 49 6e 74 65 72 76 61 6c 73 5b 27 62 72 61 | .\count($candidateIntervals['bra |
99540 | 6e 63 68 65 73 27 5d 5b 27 6e 61 6d 65 73 27 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | nches']['names'])).{............ |
99560 | 20 72 65 74 75 72 6e 20 5c 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 | .return.\false;.........}....... |
99580 | 20 20 66 6f 72 65 61 63 68 20 28 24 69 6e 74 65 72 73 65 63 74 69 6f 6e 49 6e 74 65 72 76 61 6c | ..foreach.($intersectionInterval |
995a0 | 73 5b 27 62 72 61 6e 63 68 65 73 27 5d 5b 27 6e 61 6d 65 73 27 5d 20 61 73 20 24 69 6e 64 65 78 | s['branches']['names'].as.$index |
995c0 | 20 3d 3e 20 24 6e 61 6d 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 6e 61 | .=>.$name).{.............if.($na |
995e0 | 6d 65 20 21 3d 3d 20 24 63 61 6e 64 69 64 61 74 65 49 6e 74 65 72 76 61 6c 73 5b 27 62 72 61 6e | me.!==.$candidateIntervals['bran |
99600 | 63 68 65 73 27 5d 5b 27 6e 61 6d 65 73 27 5d 5b 24 69 6e 64 65 78 5d 29 20 7b 0a 20 20 20 20 20 | ches']['names'][$index]).{...... |
99620 | 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 5c 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 | ...........return.\false;....... |
99640 | 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e | ......}.........}.........return |
99660 | 20 5c 74 72 75 65 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 | .\true;.....}.....public.static. |
99680 | 66 75 6e 63 74 69 6f 6e 20 68 61 76 65 49 6e 74 65 72 73 65 63 74 69 6f 6e 73 28 5c 48 75 6d 62 | function.haveIntersections(\Humb |
996a0 | 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 | ugBox3111\Composer\Semver\Constr |
996c0 | 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 49 6e 74 65 72 66 61 63 65 20 24 61 2c 20 5c 48 75 | aint\ConstraintInterface.$a,.\Hu |
996e0 | 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 | mbugBox3111\Composer\Semver\Cons |
99700 | 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 49 6e 74 65 72 66 61 63 65 20 24 62 29 0a 20 | traint\ConstraintInterface.$b).. |
99720 | 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 61 20 69 6e 73 74 61 6e 63 65 6f 66 20 5c | ...{.........if.($a.instanceof.\ |
99740 | 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f | HumbugBox3111\Composer\Semver\Co |
99760 | 6e 73 74 72 61 69 6e 74 5c 4d 61 74 63 68 41 6c 6c 43 6f 6e 73 74 72 61 69 6e 74 20 7c 7c 20 24 | nstraint\MatchAllConstraint.||.$ |
99780 | 62 20 69 6e 73 74 61 6e 63 65 6f 66 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 | b.instanceof.\HumbugBox3111\Comp |
997a0 | 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 4d 61 74 63 68 41 6c 6c 43 | oser\Semver\Constraint\MatchAllC |
997c0 | 6f 6e 73 74 72 61 69 6e 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 | onstraint).{.............return. |
997e0 | 5c 74 72 75 65 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 61 20 | \true;.........}.........if.($a. |
99800 | 69 6e 73 74 61 6e 63 65 6f 66 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 | instanceof.\HumbugBox3111\Compos |
99820 | 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 4d 61 74 63 68 4e 6f 6e 65 43 6f | er\Semver\Constraint\MatchNoneCo |
99840 | 6e 73 74 72 61 69 6e 74 20 7c 7c 20 24 62 20 69 6e 73 74 61 6e 63 65 6f 66 20 5c 48 75 6d 62 75 | nstraint.||.$b.instanceof.\Humbu |
99860 | 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 | gBox3111\Composer\Semver\Constra |
99880 | 69 6e 74 5c 4d 61 74 63 68 4e 6f 6e 65 43 6f 6e 73 74 72 61 69 6e 74 29 20 7b 0a 20 20 20 20 20 | int\MatchNoneConstraint).{...... |
998a0 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 5c 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 7d 0a | .......return.\false;.........}. |
998c0 | 20 20 20 20 20 20 20 20 24 69 6e 74 65 72 73 65 63 74 69 6f 6e 49 6e 74 65 72 76 61 6c 73 20 3d | ........$intersectionIntervals.= |
998e0 | 20 73 65 6c 66 3a 3a 67 65 6e 65 72 61 74 65 49 6e 74 65 72 76 61 6c 73 28 6e 65 77 20 5c 48 75 | .self::generateIntervals(new.\Hu |
99900 | 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 | mbugBox3111\Composer\Semver\Cons |
99920 | 74 72 61 69 6e 74 5c 4d 75 6c 74 69 43 6f 6e 73 74 72 61 69 6e 74 28 61 72 72 61 79 28 24 61 2c | traint\MultiConstraint(array($a, |
99940 | 20 24 62 29 2c 20 5c 74 72 75 65 29 2c 20 5c 74 72 75 65 29 3b 0a 20 20 20 20 20 20 20 20 72 65 | .$b),.\true),.\true);.........re |
99960 | 74 75 72 6e 20 5c 63 6f 75 6e 74 28 24 69 6e 74 65 72 73 65 63 74 69 6f 6e 49 6e 74 65 72 76 61 | turn.\count($intersectionInterva |
99980 | 6c 73 5b 27 6e 75 6d 65 72 69 63 27 5d 29 20 3e 20 30 20 7c 7c 20 24 69 6e 74 65 72 73 65 63 74 | ls['numeric']).>.0.||.$intersect |
999a0 | 69 6f 6e 49 6e 74 65 72 76 61 6c 73 5b 27 62 72 61 6e 63 68 65 73 27 5d 5b 27 65 78 63 6c 75 64 | ionIntervals['branches']['exclud |
999c0 | 65 27 5d 20 7c 7c 20 5c 63 6f 75 6e 74 28 24 69 6e 74 65 72 73 65 63 74 69 6f 6e 49 6e 74 65 72 | e'].||.\count($intersectionInter |
999e0 | 76 61 6c 73 5b 27 62 72 61 6e 63 68 65 73 27 5d 5b 27 6e 61 6d 65 73 27 5d 29 20 3e 20 30 3b 0a | vals['branches']['names']).>.0;. |
99a00 | 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e | ....}.....public.static.function |
99a20 | 20 63 6f 6d 70 61 63 74 43 6f 6e 73 74 72 61 69 6e 74 28 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 | .compactConstraint(\HumbugBox311 |
99a40 | 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e | 1\Composer\Semver\Constraint\Con |
99a60 | 73 74 72 61 69 6e 74 49 6e 74 65 72 66 61 63 65 20 24 63 6f 6e 73 74 72 61 69 6e 74 29 0a 20 20 | straintInterface.$constraint)... |
99a80 | 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 24 63 6f 6e 73 74 72 61 69 6e 74 20 69 6e 73 | ..{.........if.(!$constraint.ins |
99aa0 | 74 61 6e 63 65 6f 66 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c | tanceof.\HumbugBox3111\Composer\ |
99ac0 | 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 4d 75 6c 74 69 43 6f 6e 73 74 72 61 69 6e | Semver\Constraint\MultiConstrain |
99ae0 | 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 63 6f 6e 73 74 72 61 | t).{.............return.$constra |
99b00 | 69 6e 74 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 24 69 6e 74 65 72 76 61 6c | int;.........}.........$interval |
99b20 | 73 20 3d 20 73 65 6c 66 3a 3a 67 65 6e 65 72 61 74 65 49 6e 74 65 72 76 61 6c 73 28 24 63 6f 6e | s.=.self::generateIntervals($con |
99b40 | 73 74 72 61 69 6e 74 29 3b 0a 20 20 20 20 20 20 20 20 24 63 6f 6e 73 74 72 61 69 6e 74 73 20 3d | straint);.........$constraints.= |
99b60 | 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 24 68 61 73 4e 75 6d 65 72 69 63 4d 61 74 | .array();.........$hasNumericMat |
99b80 | 63 68 41 6c 6c 20 3d 20 5c 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 5c 63 6f 75 | chAll.=.\false;.........if.(\cou |
99ba0 | 6e 74 28 24 69 6e 74 65 72 76 61 6c 73 5b 27 6e 75 6d 65 72 69 63 27 5d 29 20 3d 3d 3d 20 31 20 | nt($intervals['numeric']).===.1. |
99bc0 | 26 26 20 28 73 74 72 69 6e 67 29 20 24 69 6e 74 65 72 76 61 6c 73 5b 27 6e 75 6d 65 72 69 63 27 | &&.(string).$intervals['numeric' |
99be0 | 5d 5b 30 5d 2d 3e 67 65 74 53 74 61 72 74 28 29 20 3d 3d 3d 20 28 73 74 72 69 6e 67 29 20 5c 48 | ][0]->getStart().===.(string).\H |
99c00 | 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 49 6e 74 | umbugBox3111\Composer\Semver\Int |
99c20 | 65 72 76 61 6c 3a 3a 66 72 6f 6d 5a 65 72 6f 28 29 20 26 26 20 28 73 74 72 69 6e 67 29 20 24 69 | erval::fromZero().&&.(string).$i |
99c40 | 6e 74 65 72 76 61 6c 73 5b 27 6e 75 6d 65 72 69 63 27 5d 5b 30 5d 2d 3e 67 65 74 45 6e 64 28 29 | ntervals['numeric'][0]->getEnd() |
99c60 | 20 3d 3d 3d 20 28 73 74 72 69 6e 67 29 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d | .===.(string).\HumbugBox3111\Com |
99c80 | 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 49 6e 74 65 72 76 61 6c 3a 3a 75 6e 74 69 6c 50 6f 73 69 | poser\Semver\Interval::untilPosi |
99ca0 | 74 69 76 65 49 6e 66 69 6e 69 74 79 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 63 | tiveInfinity()).{.............$c |
99cc0 | 6f 6e 73 74 72 61 69 6e 74 73 5b 5d 20 3d 20 24 69 6e 74 65 72 76 61 6c 73 5b 27 6e 75 6d 65 72 | onstraints[].=.$intervals['numer |
99ce0 | 69 63 27 5d 5b 30 5d 2d 3e 67 65 74 53 74 61 72 74 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 | ic'][0]->getStart();............ |
99d00 | 20 24 68 61 73 4e 75 6d 65 72 69 63 4d 61 74 63 68 41 6c 6c 20 3d 20 5c 74 72 75 65 3b 0a 20 20 | .$hasNumericMatchAll.=.\true;... |
99d20 | 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 75 6e 45 71 | ......}.else.{.............$unEq |
99d40 | 75 61 6c 43 6f 6e 73 74 72 61 69 6e 74 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 | ualConstraints.=.array();....... |
99d60 | 20 20 20 20 20 20 66 6f 72 20 28 24 69 20 3d 20 30 2c 20 24 63 6f 75 6e 74 20 3d 20 5c 63 6f 75 | ......for.($i.=.0,.$count.=.\cou |
99d80 | 6e 74 28 24 69 6e 74 65 72 76 61 6c 73 5b 27 6e 75 6d 65 72 69 63 27 5d 29 3b 20 24 69 20 3c 20 | nt($intervals['numeric']);.$i.<. |
99da0 | 24 63 6f 75 6e 74 3b 20 24 69 2b 2b 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | $count;.$i++).{................. |
99dc0 | 24 69 6e 74 65 72 76 61 6c 20 3d 20 24 69 6e 74 65 72 76 61 6c 73 5b 27 6e 75 6d 65 72 69 63 27 | $interval.=.$intervals['numeric' |
99de0 | 5d 5b 24 69 5d 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 69 6e 74 65 | ][$i];.................if.($inte |
99e00 | 72 76 61 6c 2d 3e 67 65 74 45 6e 64 28 29 2d 3e 67 65 74 4f 70 65 72 61 74 6f 72 28 29 20 3d 3d | rval->getEnd()->getOperator().== |
99e20 | 3d 20 27 3c 27 20 26 26 20 24 69 20 2b 20 31 20 3c 20 24 63 6f 75 6e 74 29 20 7b 0a 20 20 20 20 | =.'<'.&&.$i.+.1.<.$count).{..... |
99e40 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6e 65 78 74 49 6e 74 65 72 76 61 6c 20 3d 20 | ................$nextInterval.=. |
99e60 | 24 69 6e 74 65 72 76 61 6c 73 5b 27 6e 75 6d 65 72 69 63 27 5d 5b 24 69 20 2b 20 31 5d 3b 0a 20 | $intervals['numeric'][$i.+.1];.. |
99e80 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 69 6e 74 65 72 76 61 6c | ...................if.($interval |
99ea0 | 2d 3e 67 65 74 45 6e 64 28 29 2d 3e 67 65 74 56 65 72 73 69 6f 6e 28 29 20 3d 3d 3d 20 24 6e 65 | ->getEnd()->getVersion().===.$ne |
99ec0 | 78 74 49 6e 74 65 72 76 61 6c 2d 3e 67 65 74 53 74 61 72 74 28 29 2d 3e 67 65 74 56 65 72 73 69 | xtInterval->getStart()->getVersi |
99ee0 | 6f 6e 28 29 20 26 26 20 24 6e 65 78 74 49 6e 74 65 72 76 61 6c 2d 3e 67 65 74 53 74 61 72 74 28 | on().&&.$nextInterval->getStart( |
99f00 | 29 2d 3e 67 65 74 4f 70 65 72 61 74 6f 72 28 29 20 3d 3d 3d 20 27 3e 27 29 20 7b 0a 20 20 20 20 | )->getOperator().===.'>').{..... |
99f20 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 5c 63 6f 75 6e 74 28 24 | ....................if.(\count($ |
99f40 | 75 6e 45 71 75 61 6c 43 6f 6e 73 74 72 61 69 6e 74 73 29 20 3d 3d 3d 20 30 20 26 26 20 28 73 74 | unEqualConstraints).===.0.&&.(st |
99f60 | 72 69 6e 67 29 20 24 69 6e 74 65 72 76 61 6c 2d 3e 67 65 74 53 74 61 72 74 28 29 20 21 3d 3d 20 | ring).$interval->getStart().!==. |
99f80 | 28 73 74 72 69 6e 67 29 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 | (string).\HumbugBox3111\Composer |
99fa0 | 5c 53 65 6d 76 65 72 5c 49 6e 74 65 72 76 61 6c 3a 3a 66 72 6f 6d 5a 65 72 6f 28 29 29 20 7b 0a | \Semver\Interval::fromZero()).{. |
99fc0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 75 6e 45 | ............................$unE |
99fe0 | 71 75 61 6c 43 6f 6e 73 74 72 61 69 6e 74 73 5b 5d 20 3d 20 24 69 6e 74 65 72 76 61 6c 2d 3e 67 | qualConstraints[].=.$interval->g |
9a000 | 65 74 53 74 61 72 74 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | etStart();...................... |
9a020 | 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 75 6e | ...}.........................$un |
9a040 | 45 71 75 61 6c 43 6f 6e 73 74 72 61 69 6e 74 73 5b 5d 20 3d 20 6e 65 77 20 5c 48 75 6d 62 75 67 | EqualConstraints[].=.new.\Humbug |
9a060 | 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 | Box3111\Composer\Semver\Constrai |
9a080 | 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 28 27 21 3d 27 2c 20 24 69 6e 74 65 72 76 61 6c 2d 3e 67 | nt\Constraint('!=',.$interval->g |
9a0a0 | 65 74 45 6e 64 28 29 2d 3e 67 65 74 56 65 72 73 69 6f 6e 28 29 29 3b 0a 20 20 20 20 20 20 20 20 | etEnd()->getVersion());......... |
9a0c0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 63 6f 6e 74 69 6e 75 65 3b 0a 20 20 20 20 20 20 | ................continue;....... |
9a0e0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ..............}................. |
9a100 | 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 5c 63 6f 75 6e 74 28 24 75 6e | }.................if.(\count($un |
9a120 | 45 71 75 61 6c 43 6f 6e 73 74 72 61 69 6e 74 73 29 20 3e 20 30 29 20 7b 0a 20 20 20 20 20 20 20 | EqualConstraints).>.0).{........ |
9a140 | 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 28 73 74 72 69 6e 67 29 20 24 69 6e 74 65 72 | .............if.((string).$inter |
9a160 | 76 61 6c 2d 3e 67 65 74 45 6e 64 28 29 20 21 3d 3d 20 28 73 74 72 69 6e 67 29 20 5c 48 75 6d 62 | val->getEnd().!==.(string).\Humb |
9a180 | 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 49 6e 74 65 72 76 | ugBox3111\Composer\Semver\Interv |
9a1a0 | 61 6c 3a 3a 75 6e 74 69 6c 50 6f 73 69 74 69 76 65 49 6e 66 69 6e 69 74 79 28 29 29 20 7b 0a 20 | al::untilPositiveInfinity()).{.. |
9a1c0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 75 6e 45 71 75 61 6c 43 | .......................$unEqualC |
9a1e0 | 6f 6e 73 74 72 61 69 6e 74 73 5b 5d 20 3d 20 24 69 6e 74 65 72 76 61 6c 2d 3e 67 65 74 45 6e 64 | onstraints[].=.$interval->getEnd |
9a200 | 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 | ();.....................}....... |
9a220 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 5c 63 6f 75 6e 74 28 24 75 6e 45 71 75 61 | ..............if.(\count($unEqua |
9a240 | 6c 43 6f 6e 73 74 72 61 69 6e 74 73 29 20 3e 20 31 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | lConstraints).>.1).{............ |
9a260 | 20 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6f 6e 73 74 72 61 69 6e 74 73 5b 5d 20 3d 20 6e 65 | .............$constraints[].=.ne |
9a280 | 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 | w.\HumbugBox3111\Composer\Semver |
9a2a0 | 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 4d 75 6c 74 69 43 6f 6e 73 74 72 61 69 6e 74 28 24 75 6e 45 | \Constraint\MultiConstraint($unE |
9a2c0 | 71 75 61 6c 43 6f 6e 73 74 72 61 69 6e 74 73 2c 20 5c 74 72 75 65 29 3b 0a 20 20 20 20 20 20 20 | qualConstraints,.\true);........ |
9a2e0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | .............}.else.{........... |
9a300 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6f 6e 73 74 72 61 69 6e 74 73 5b 5d 20 3d 20 24 | ..............$constraints[].=.$ |
9a320 | 75 6e 45 71 75 61 6c 43 6f 6e 73 74 72 61 69 6e 74 73 5b 30 5d 3b 0a 20 20 20 20 20 20 20 20 20 | unEqualConstraints[0];.......... |
9a340 | 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ...........}.................... |
9a360 | 20 24 75 6e 45 71 75 61 6c 43 6f 6e 73 74 72 61 69 6e 74 73 20 3d 20 61 72 72 61 79 28 29 3b 0a | .$unEqualConstraints.=.array();. |
9a380 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 63 6f 6e 74 69 6e 75 65 3b 0a 20 20 | ....................continue;... |
9a3a0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ..............}................. |
9a3c0 | 69 66 20 28 24 69 6e 74 65 72 76 61 6c 2d 3e 67 65 74 53 74 61 72 74 28 29 2d 3e 67 65 74 56 65 | if.($interval->getStart()->getVe |
9a3e0 | 72 73 69 6f 6e 28 29 20 3d 3d 3d 20 24 69 6e 74 65 72 76 61 6c 2d 3e 67 65 74 45 6e 64 28 29 2d | rsion().===.$interval->getEnd()- |
9a400 | 3e 67 65 74 56 65 72 73 69 6f 6e 28 29 20 26 26 20 24 69 6e 74 65 72 76 61 6c 2d 3e 67 65 74 53 | >getVersion().&&.$interval->getS |
9a420 | 74 61 72 74 28 29 2d 3e 67 65 74 4f 70 65 72 61 74 6f 72 28 29 20 3d 3d 3d 20 27 3e 3d 27 20 26 | tart()->getOperator().===.'>='.& |
9a440 | 26 20 24 69 6e 74 65 72 76 61 6c 2d 3e 67 65 74 45 6e 64 28 29 2d 3e 67 65 74 4f 70 65 72 61 74 | &.$interval->getEnd()->getOperat |
9a460 | 6f 72 28 29 20 3d 3d 3d 20 27 3c 3d 27 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | or().===.'<=').{................ |
9a480 | 20 20 20 20 20 24 63 6f 6e 73 74 72 61 69 6e 74 73 5b 5d 20 3d 20 6e 65 77 20 5c 48 75 6d 62 75 | .....$constraints[].=.new.\Humbu |
9a4a0 | 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 | gBox3111\Composer\Semver\Constra |
9a4c0 | 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 28 27 3d 3d 27 2c 20 24 69 6e 74 65 72 76 61 6c 2d 3e | int\Constraint('==',.$interval-> |
9a4e0 | 67 65 74 53 74 61 72 74 28 29 2d 3e 67 65 74 56 65 72 73 69 6f 6e 28 29 29 3b 0a 20 20 20 20 20 | getStart()->getVersion());...... |
9a500 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 63 6f 6e 74 69 6e 75 65 3b 0a 20 20 20 20 20 20 20 | ...............continue;........ |
9a520 | 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 28 | .........}.................if.(( |
9a540 | 73 74 72 69 6e 67 29 20 24 69 6e 74 65 72 76 61 6c 2d 3e 67 65 74 53 74 61 72 74 28 29 20 3d 3d | string).$interval->getStart().== |
9a560 | 3d 20 28 73 74 72 69 6e 67 29 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 | =.(string).\HumbugBox3111\Compos |
9a580 | 65 72 5c 53 65 6d 76 65 72 5c 49 6e 74 65 72 76 61 6c 3a 3a 66 72 6f 6d 5a 65 72 6f 28 29 29 20 | er\Semver\Interval::fromZero()). |
9a5a0 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6f 6e 73 74 72 61 69 6e | {.....................$constrain |
9a5c0 | 74 73 5b 5d 20 3d 20 24 69 6e 74 65 72 76 61 6c 2d 3e 67 65 74 45 6e 64 28 29 3b 0a 20 20 20 20 | ts[].=.$interval->getEnd();..... |
9a5e0 | 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 28 73 74 72 69 6e 67 29 20 24 | ............}.elseif.((string).$ |
9a600 | 69 6e 74 65 72 76 61 6c 2d 3e 67 65 74 45 6e 64 28 29 20 3d 3d 3d 20 28 73 74 72 69 6e 67 29 20 | interval->getEnd().===.(string). |
9a620 | 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 49 | \HumbugBox3111\Composer\Semver\I |
9a640 | 6e 74 65 72 76 61 6c 3a 3a 75 6e 74 69 6c 50 6f 73 69 74 69 76 65 49 6e 66 69 6e 69 74 79 28 29 | nterval::untilPositiveInfinity() |
9a660 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6f 6e 73 74 72 61 | ).{.....................$constra |
9a680 | 69 6e 74 73 5b 5d 20 3d 20 24 69 6e 74 65 72 76 61 6c 2d 3e 67 65 74 53 74 61 72 74 28 29 3b 0a | ints[].=.$interval->getStart();. |
9a6a0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 | ................}.else.{........ |
9a6c0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6f 6e 73 74 72 61 69 6e 74 73 5b 5d 20 3d 20 6e 65 | .............$constraints[].=.ne |
9a6e0 | 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 | w.\HumbugBox3111\Composer\Semver |
9a700 | 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 4d 75 6c 74 69 43 6f 6e 73 74 72 61 69 6e 74 28 61 72 72 61 | \Constraint\MultiConstraint(arra |
9a720 | 79 28 24 69 6e 74 65 72 76 61 6c 2d 3e 67 65 74 53 74 61 72 74 28 29 2c 20 24 69 6e 74 65 72 76 | y($interval->getStart(),.$interv |
9a740 | 61 6c 2d 3e 67 65 74 45 6e 64 28 29 29 2c 20 5c 74 72 75 65 29 3b 0a 20 20 20 20 20 20 20 20 20 | al->getEnd()),.\true);.......... |
9a760 | 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d | .......}.............}.........} |
9a780 | 0a 20 20 20 20 20 20 20 20 24 64 65 76 43 6f 6e 73 74 72 61 69 6e 74 73 20 3d 20 61 72 72 61 79 | .........$devConstraints.=.array |
9a7a0 | 28 29 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 30 20 3d 3d 3d 20 5c 63 6f 75 6e 74 28 24 69 6e | ();.........if.(0.===.\count($in |
9a7c0 | 74 65 72 76 61 6c 73 5b 27 62 72 61 6e 63 68 65 73 27 5d 5b 27 6e 61 6d 65 73 27 5d 29 29 20 7b | tervals['branches']['names'])).{ |
9a7e0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 69 6e 74 65 72 76 61 6c 73 5b 27 62 72 61 | .............if.($intervals['bra |
9a800 | 6e 63 68 65 73 27 5d 5b 27 65 78 63 6c 75 64 65 27 5d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | nches']['exclude']).{........... |
9a820 | 20 20 20 20 20 20 69 66 20 28 24 68 61 73 4e 75 6d 65 72 69 63 4d 61 74 63 68 41 6c 6c 29 20 7b | ......if.($hasNumericMatchAll).{ |
9a840 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6e 65 77 20 | .....................return.new. |
9a860 | 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 | \HumbugBox3111\Composer\Semver\C |
9a880 | 6f 6e 73 74 72 61 69 6e 74 5c 4d 61 74 63 68 41 6c 6c 43 6f 6e 73 74 72 61 69 6e 74 28 29 3b 0a | onstraint\MatchAllConstraint();. |
9a8a0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a | ................}.............}. |
9a8c0 | 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 | ........}.else.{.............for |
9a8e0 | 65 61 63 68 20 28 24 69 6e 74 65 72 76 61 6c 73 5b 27 62 72 61 6e 63 68 65 73 27 5d 5b 27 6e 61 | each.($intervals['branches']['na |
9a900 | 6d 65 73 27 5d 20 61 73 20 24 62 72 61 6e 63 68 4e 61 6d 65 29 20 7b 0a 20 20 20 20 20 20 20 20 | mes'].as.$branchName).{......... |
9a920 | 20 20 20 20 20 20 20 20 69 66 20 28 24 69 6e 74 65 72 76 61 6c 73 5b 27 62 72 61 6e 63 68 65 73 | ........if.($intervals['branches |
9a940 | 27 5d 5b 27 65 78 63 6c 75 64 65 27 5d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ']['exclude']).{................ |
9a960 | 20 20 20 20 20 24 64 65 76 43 6f 6e 73 74 72 61 69 6e 74 73 5b 5d 20 3d 20 6e 65 77 20 5c 48 75 | .....$devConstraints[].=.new.\Hu |
9a980 | 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 | mbugBox3111\Composer\Semver\Cons |
9a9a0 | 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 28 27 21 3d 27 2c 20 24 62 72 61 6e 63 68 4e | traint\Constraint('!=',.$branchN |
9a9c0 | 61 6d 65 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 | ame);.................}.else.{.. |
9a9e0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 64 65 76 43 6f 6e 73 74 72 61 69 6e | ...................$devConstrain |
9aa00 | 74 73 5b 5d 20 3d 20 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 | ts[].=.new.\HumbugBox3111\Compos |
9aa20 | 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 28 | er\Semver\Constraint\Constraint( |
9aa40 | 27 3d 3d 27 2c 20 24 62 72 61 6e 63 68 4e 61 6d 65 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | '==',.$branchName);............. |
9aa60 | 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ....}.............}............. |
9aa80 | 69 66 20 28 24 69 6e 74 65 72 76 61 6c 73 5b 27 62 72 61 6e 63 68 65 73 27 5d 5b 27 65 78 63 6c | if.($intervals['branches']['excl |
9aaa0 | 75 64 65 27 5d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 5c 63 6f | ude']).{.................if.(\co |
9aac0 | 75 6e 74 28 24 63 6f 6e 73 74 72 61 69 6e 74 73 29 20 3e 20 31 29 20 7b 0a 20 20 20 20 20 20 20 | unt($constraints).>.1).{........ |
9aae0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6e 65 77 20 5c 48 75 6d 62 75 67 42 | .............return.new.\HumbugB |
9ab00 | 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e | ox3111\Composer\Semver\Constrain |
9ab20 | 74 5c 4d 75 6c 74 69 43 6f 6e 73 74 72 61 69 6e 74 28 5c 61 72 72 61 79 5f 6d 65 72 67 65 28 61 | t\MultiConstraint(\array_merge(a |
9ab40 | 72 72 61 79 28 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 | rray(new.\HumbugBox3111\Composer |
9ab60 | 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 4d 75 6c 74 69 43 6f 6e 73 74 72 61 69 | \Semver\Constraint\MultiConstrai |
9ab80 | 6e 74 28 24 63 6f 6e 73 74 72 61 69 6e 74 73 2c 20 5c 66 61 6c 73 65 29 29 2c 20 24 64 65 76 43 | nt($constraints,.\false)),.$devC |
9aba0 | 6f 6e 73 74 72 61 69 6e 74 73 29 2c 20 5c 74 72 75 65 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 | onstraints),.\true);............ |
9abc0 | 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 5c 63 6f 75 6e | .....}.................if.(\coun |
9abe0 | 74 28 24 63 6f 6e 73 74 72 61 69 6e 74 73 29 20 3d 3d 3d 20 31 20 26 26 20 28 73 74 72 69 6e 67 | t($constraints).===.1.&&.(string |
9ac00 | 29 20 24 63 6f 6e 73 74 72 61 69 6e 74 73 5b 30 5d 20 3d 3d 3d 20 28 73 74 72 69 6e 67 29 20 5c | ).$constraints[0].===.(string).\ |
9ac20 | 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 49 6e | HumbugBox3111\Composer\Semver\In |
9ac40 | 74 65 72 76 61 6c 3a 3a 66 72 6f 6d 5a 65 72 6f 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | terval::fromZero()).{........... |
9ac60 | 20 20 20 20 20 20 20 20 20 20 69 66 20 28 5c 63 6f 75 6e 74 28 24 64 65 76 43 6f 6e 73 74 72 61 | ..........if.(\count($devConstra |
9ac80 | 69 6e 74 73 29 20 3e 20 31 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ints).>.1).{.................... |
9aca0 | 20 20 20 20 20 72 65 74 75 72 6e 20 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 | .....return.new.\HumbugBox3111\C |
9acc0 | 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 4d 75 6c 74 69 43 | omposer\Semver\Constraint\MultiC |
9ace0 | 6f 6e 73 74 72 61 69 6e 74 28 24 64 65 76 43 6f 6e 73 74 72 61 69 6e 74 73 2c 20 5c 74 72 75 65 | onstraint($devConstraints,.\true |
9ad00 | 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 | );.....................}........ |
9ad20 | 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 64 65 76 43 6f 6e 73 74 72 61 69 | .............return.$devConstrai |
9ad40 | 6e 74 73 5b 30 5d 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 | nts[0];.................}....... |
9ad60 | 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 | ..........return.new.\HumbugBox3 |
9ad80 | 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 4d | 111\Composer\Semver\Constraint\M |
9ada0 | 75 6c 74 69 43 6f 6e 73 74 72 61 69 6e 74 28 5c 61 72 72 61 79 5f 6d 65 72 67 65 28 24 63 6f 6e | ultiConstraint(\array_merge($con |
9adc0 | 73 74 72 61 69 6e 74 73 2c 20 24 64 65 76 43 6f 6e 73 74 72 61 69 6e 74 73 29 2c 20 5c 74 72 75 | straints,.$devConstraints),.\tru |
9ade0 | 65 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 63 | e);.............}.............$c |
9ae00 | 6f 6e 73 74 72 61 69 6e 74 73 20 3d 20 5c 61 72 72 61 79 5f 6d 65 72 67 65 28 24 63 6f 6e 73 74 | onstraints.=.\array_merge($const |
9ae20 | 72 61 69 6e 74 73 2c 20 24 64 65 76 43 6f 6e 73 74 72 61 69 6e 74 73 29 3b 0a 20 20 20 20 20 20 | raints,.$devConstraints);....... |
9ae40 | 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 5c 63 6f 75 6e 74 28 24 63 6f 6e 73 74 72 61 69 | ..}.........if.(\count($constrai |
9ae60 | 6e 74 73 29 20 3e 20 31 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6e | nts).>.1).{.............return.n |
9ae80 | 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 | ew.\HumbugBox3111\Composer\Semve |
9aea0 | 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 4d 75 6c 74 69 43 6f 6e 73 74 72 61 69 6e 74 28 24 63 6f | r\Constraint\MultiConstraint($co |
9aec0 | 6e 73 74 72 61 69 6e 74 73 2c 20 5c 66 61 6c 73 65 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 | nstraints,.\false);.........}... |
9aee0 | 20 20 20 20 20 20 69 66 20 28 5c 63 6f 75 6e 74 28 24 63 6f 6e 73 74 72 61 69 6e 74 73 29 20 3d | ......if.(\count($constraints).= |
9af00 | 3d 3d 20 31 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 63 6f 6e 73 | ==.1).{.............return.$cons |
9af20 | 74 72 61 69 6e 74 73 5b 30 5d 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 72 65 | traints[0];.........}.........re |
9af40 | 74 75 72 6e 20 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 | turn.new.\HumbugBox3111\Composer |
9af60 | 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 4d 61 74 63 68 4e 6f 6e 65 43 6f 6e 73 | \Semver\Constraint\MatchNoneCons |
9af80 | 74 72 61 69 6e 74 28 29 3b 0a 20 20 20 20 7d 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 40 70 68 70 | traint();.....}...../**.....@php |
9afa0 | 73 74 61 6e 2d 72 65 74 75 72 6e 0a 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 | stan-return.....*/.....public.st |
9afc0 | 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 28 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 | atic.function.get(\HumbugBox3111 |
9afe0 | 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 | \Composer\Semver\Constraint\Cons |
9b000 | 74 72 61 69 6e 74 49 6e 74 65 72 66 61 63 65 20 24 63 6f 6e 73 74 72 61 69 6e 74 29 0a 20 20 20 | traintInterface.$constraint).... |
9b020 | 20 7b 0a 20 20 20 20 20 20 20 20 24 6b 65 79 20 3d 20 28 73 74 72 69 6e 67 29 20 24 63 6f 6e 73 | .{.........$key.=.(string).$cons |
9b040 | 74 72 61 69 6e 74 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 69 73 73 65 74 28 73 65 6c 66 3a | traint;.........if.(!isset(self: |
9b060 | 3a 24 69 6e 74 65 72 76 61 6c 73 43 61 63 68 65 5b 24 6b 65 79 5d 29 29 20 7b 0a 20 20 20 20 20 | :$intervalsCache[$key])).{...... |
9b080 | 20 20 20 20 20 20 20 73 65 6c 66 3a 3a 24 69 6e 74 65 72 76 61 6c 73 43 61 63 68 65 5b 24 6b 65 | .......self::$intervalsCache[$ke |
9b0a0 | 79 5d 20 3d 20 73 65 6c 66 3a 3a 67 65 6e 65 72 61 74 65 49 6e 74 65 72 76 61 6c 73 28 24 63 6f | y].=.self::generateIntervals($co |
9b0c0 | 6e 73 74 72 61 69 6e 74 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 72 65 74 | nstraint);.........}.........ret |
9b0e0 | 75 72 6e 20 73 65 6c 66 3a 3a 24 69 6e 74 65 72 76 61 6c 73 43 61 63 68 65 5b 24 6b 65 79 5d 3b | urn.self::$intervalsCache[$key]; |
9b100 | 0a 20 20 20 20 7d 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 40 70 68 70 73 74 61 6e 2d 72 65 74 75 | .....}...../**.....@phpstan-retu |
9b120 | 72 6e 0a 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 66 75 6e | rn.....*/.....private.static.fun |
9b140 | 63 74 69 6f 6e 20 67 65 6e 65 72 61 74 65 49 6e 74 65 72 76 61 6c 73 28 5c 48 75 6d 62 75 67 42 | ction.generateIntervals(\HumbugB |
9b160 | 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e | ox3111\Composer\Semver\Constrain |
9b180 | 74 5c 43 6f 6e 73 74 72 61 69 6e 74 49 6e 74 65 72 66 61 63 65 20 24 63 6f 6e 73 74 72 61 69 6e | t\ConstraintInterface.$constrain |
9b1a0 | 74 2c 20 24 73 74 6f 70 4f 6e 46 69 72 73 74 56 61 6c 69 64 49 6e 74 65 72 76 61 6c 20 3d 20 5c | t,.$stopOnFirstValidInterval.=.\ |
9b1c0 | 66 61 6c 73 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 63 6f 6e 73 74 72 | false).....{.........if.($constr |
9b1e0 | 61 69 6e 74 20 69 6e 73 74 61 6e 63 65 6f 66 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 | aint.instanceof.\HumbugBox3111\C |
9b200 | 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 4d 61 74 63 68 41 | omposer\Semver\Constraint\MatchA |
9b220 | 6c 6c 43 6f 6e 73 74 72 61 69 6e 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 | llConstraint).{.............retu |
9b240 | 72 6e 20 61 72 72 61 79 28 27 6e 75 6d 65 72 69 63 27 20 3d 3e 20 61 72 72 61 79 28 6e 65 77 20 | rn.array('numeric'.=>.array(new. |
9b260 | 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 49 | \HumbugBox3111\Composer\Semver\I |
9b280 | 6e 74 65 72 76 61 6c 28 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c | nterval(\HumbugBox3111\Composer\ |
9b2a0 | 53 65 6d 76 65 72 5c 49 6e 74 65 72 76 61 6c 3a 3a 66 72 6f 6d 5a 65 72 6f 28 29 2c 20 5c 48 75 | Semver\Interval::fromZero(),.\Hu |
9b2c0 | 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 49 6e 74 65 | mbugBox3111\Composer\Semver\Inte |
9b2e0 | 72 76 61 6c 3a 3a 75 6e 74 69 6c 50 6f 73 69 74 69 76 65 49 6e 66 69 6e 69 74 79 28 29 29 29 2c | rval::untilPositiveInfinity())), |
9b300 | 20 27 62 72 61 6e 63 68 65 73 27 20 3d 3e 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f | .'branches'.=>.\HumbugBox3111\Co |
9b320 | 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 49 6e 74 65 72 76 61 6c 3a 3a 61 6e 79 44 65 76 28 29 | mposer\Semver\Interval::anyDev() |
9b340 | 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 63 6f 6e 73 74 72 | );.........}.........if.($constr |
9b360 | 61 69 6e 74 20 69 6e 73 74 61 6e 63 65 6f 66 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 | aint.instanceof.\HumbugBox3111\C |
9b380 | 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 4d 61 74 63 68 4e | omposer\Semver\Constraint\MatchN |
9b3a0 | 6f 6e 65 43 6f 6e 73 74 72 61 69 6e 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 | oneConstraint).{.............ret |
9b3c0 | 75 72 6e 20 61 72 72 61 79 28 27 6e 75 6d 65 72 69 63 27 20 3d 3e 20 61 72 72 61 79 28 29 2c 20 | urn.array('numeric'.=>.array(),. |
9b3e0 | 27 62 72 61 6e 63 68 65 73 27 20 3d 3e 20 61 72 72 61 79 28 27 6e 61 6d 65 73 27 20 3d 3e 20 61 | 'branches'.=>.array('names'.=>.a |
9b400 | 72 72 61 79 28 29 2c 20 27 65 78 63 6c 75 64 65 27 20 3d 3e 20 5c 66 61 6c 73 65 29 29 3b 0a 20 | rray(),.'exclude'.=>.\false));.. |
9b420 | 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 63 6f 6e 73 74 72 61 69 6e 74 | .......}.........if.($constraint |
9b440 | 20 69 6e 73 74 61 6e 63 65 6f 66 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f | .instanceof.\HumbugBox3111\Compo |
9b460 | 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 | ser\Semver\Constraint\Constraint |
9b480 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 3a 3a 67 65 6e | ).{.............return.self::gen |
9b4a0 | 65 72 61 74 65 53 69 6e 67 6c 65 43 6f 6e 73 74 72 61 69 6e 74 49 6e 74 65 72 76 61 6c 73 28 24 | erateSingleConstraintIntervals($ |
9b4c0 | 63 6f 6e 73 74 72 61 69 6e 74 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 | constraint);.........}.........i |
9b4e0 | 66 20 28 21 24 63 6f 6e 73 74 72 61 69 6e 74 20 69 6e 73 74 61 6e 63 65 6f 66 20 5c 48 75 6d 62 | f.(!$constraint.instanceof.\Humb |
9b500 | 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 | ugBox3111\Composer\Semver\Constr |
9b520 | 61 69 6e 74 5c 4d 75 6c 74 69 43 6f 6e 73 74 72 61 69 6e 74 29 20 7b 0a 20 20 20 20 20 20 20 20 | aint\MultiConstraint).{......... |
9b540 | 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 5c 55 6e 65 78 70 65 63 74 65 64 56 61 6c 75 65 45 78 | ....throw.new.\UnexpectedValueEx |
9b560 | 63 65 70 74 69 6f 6e 28 27 54 68 65 20 63 6f 6e 73 74 72 61 69 6e 74 20 70 61 73 73 65 64 20 69 | ception('The.constraint.passed.i |
9b580 | 6e 20 73 68 6f 75 6c 64 20 62 65 20 61 6e 20 4d 61 74 63 68 41 6c 6c 43 6f 6e 73 74 72 61 69 6e | n.should.be.an.MatchAllConstrain |
9b5a0 | 74 2c 20 43 6f 6e 73 74 72 61 69 6e 74 20 6f 72 20 4d 75 6c 74 69 43 6f 6e 73 74 72 61 69 6e 74 | t,.Constraint.or.MultiConstraint |
9b5c0 | 20 69 6e 73 74 61 6e 63 65 2c 20 67 6f 74 20 27 20 2e 20 5c 67 65 74 5f 63 6c 61 73 73 28 24 63 | .instance,.got.'...\get_class($c |
9b5e0 | 6f 6e 73 74 72 61 69 6e 74 29 20 2e 20 27 2e 27 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 | onstraint)...'.');.........}.... |
9b600 | 20 20 20 20 20 24 63 6f 6e 73 74 72 61 69 6e 74 73 20 3d 20 24 63 6f 6e 73 74 72 61 69 6e 74 2d | .....$constraints.=.$constraint- |
9b620 | 3e 67 65 74 43 6f 6e 73 74 72 61 69 6e 74 73 28 29 3b 0a 20 20 20 20 20 20 20 20 24 6e 75 6d 65 | >getConstraints();.........$nume |
9b640 | 72 69 63 47 72 6f 75 70 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 24 63 6f | ricGroups.=.array();.........$co |
9b660 | 6e 73 74 72 61 69 6e 74 42 72 61 6e 63 68 65 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 | nstraintBranches.=.array();..... |
9b680 | 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 63 6f 6e 73 74 72 61 69 6e 74 73 20 61 73 20 24 63 29 | ....foreach.($constraints.as.$c) |
9b6a0 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 72 65 73 20 3d 20 73 65 6c 66 3a 3a 67 65 74 28 | .{.............$res.=.self::get( |
9b6c0 | 24 63 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6e 75 6d 65 72 69 63 47 72 6f 75 70 73 5b | $c);.............$numericGroups[ |
9b6e0 | 5d 20 3d 20 24 72 65 73 5b 27 6e 75 6d 65 72 69 63 27 5d 3b 0a 20 20 20 20 20 20 20 20 20 20 20 | ].=.$res['numeric'];............ |
9b700 | 20 24 63 6f 6e 73 74 72 61 69 6e 74 42 72 61 6e 63 68 65 73 5b 5d 20 3d 20 24 72 65 73 5b 27 62 | .$constraintBranches[].=.$res['b |
9b720 | 72 61 6e 63 68 65 73 27 5d 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 | ranches'];.........}.........if. |
9b740 | 28 24 63 6f 6e 73 74 72 61 69 6e 74 2d 3e 69 73 44 69 73 6a 75 6e 63 74 69 76 65 28 29 29 20 7b | ($constraint->isDisjunctive()).{ |
9b760 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 62 72 61 6e 63 68 65 73 20 3d 20 5c 48 75 6d 62 75 67 | .............$branches.=.\Humbug |
9b780 | 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 49 6e 74 65 72 76 61 6c | Box3111\Composer\Semver\Interval |
9b7a0 | 3a 3a 6e 6f 44 65 76 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 | ::noDev();.............foreach.( |
9b7c0 | 24 63 6f 6e 73 74 72 61 69 6e 74 42 72 61 6e 63 68 65 73 20 61 73 20 24 62 29 20 7b 0a 20 20 20 | $constraintBranches.as.$b).{.... |
9b7e0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 62 5b 27 65 78 63 6c 75 64 65 27 5d 29 20 | .............if.($b['exclude']). |
9b800 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 62 72 61 6e 63 | {.....................if.($branc |
9b820 | 68 65 73 5b 27 65 78 63 6c 75 64 65 27 5d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | hes['exclude']).{............... |
9b840 | 20 20 20 20 20 20 20 20 20 20 24 62 72 61 6e 63 68 65 73 5b 27 6e 61 6d 65 73 27 5d 20 3d 20 5c | ..........$branches['names'].=.\ |
9b860 | 61 72 72 61 79 5f 69 6e 74 65 72 73 65 63 74 28 24 62 72 61 6e 63 68 65 73 5b 27 6e 61 6d 65 73 | array_intersect($branches['names |
9b880 | 27 5d 2c 20 24 62 5b 27 6e 61 6d 65 73 27 5d 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | '],.$b['names']);............... |
9b8a0 | 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ......}.else.{.................. |
9b8c0 | 20 20 20 20 20 20 20 24 62 72 61 6e 63 68 65 73 5b 27 65 78 63 6c 75 64 65 27 5d 20 3d 20 5c 74 | .......$branches['exclude'].=.\t |
9b8e0 | 72 75 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 62 72 | rue;.........................$br |
9b900 | 61 6e 63 68 65 73 5b 27 6e 61 6d 65 73 27 5d 20 3d 20 5c 61 72 72 61 79 5f 64 69 66 66 28 24 62 | anches['names'].=.\array_diff($b |
9b920 | 5b 27 6e 61 6d 65 73 27 5d 2c 20 24 62 72 61 6e 63 68 65 73 5b 27 6e 61 6d 65 73 27 5d 29 3b 0a | ['names'],.$branches['names']);. |
9b940 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 | ....................}........... |
9b960 | 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ......}.else.{.................. |
9b980 | 20 20 20 69 66 20 28 24 62 72 61 6e 63 68 65 73 5b 27 65 78 63 6c 75 64 65 27 5d 29 20 7b 0a 20 | ...if.($branches['exclude']).{.. |
9b9a0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 62 72 61 6e 63 68 65 73 | .......................$branches |
9b9c0 | 5b 27 6e 61 6d 65 73 27 5d 20 3d 20 5c 61 72 72 61 79 5f 64 69 66 66 28 24 62 72 61 6e 63 68 65 | ['names'].=.\array_diff($branche |
9b9e0 | 73 5b 27 6e 61 6d 65 73 27 5d 2c 20 24 62 5b 27 6e 61 6d 65 73 27 5d 29 3b 0a 20 20 20 20 20 20 | s['names'],.$b['names']);....... |
9ba00 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 | ..............}.else.{.......... |
9ba20 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 62 72 61 6e 63 68 65 73 5b 27 6e 61 6d 65 73 27 | ...............$branches['names' |
9ba40 | 5d 20 3d 20 5c 61 72 72 61 79 5f 6d 65 72 67 65 28 24 62 72 61 6e 63 68 65 73 5b 27 6e 61 6d 65 | ].=.\array_merge($branches['name |
9ba60 | 73 27 5d 2c 20 24 62 5b 27 6e 61 6d 65 73 27 5d 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | s'],.$b['names']);.............. |
9ba80 | 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 | .......}.................}...... |
9baa0 | 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 | .......}.........}.else.{....... |
9bac0 | 20 20 20 20 20 20 24 62 72 61 6e 63 68 65 73 20 3d 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 | ......$branches.=.\HumbugBox3111 |
9bae0 | 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 49 6e 74 65 72 76 61 6c 3a 3a 61 6e 79 44 65 | \Composer\Semver\Interval::anyDe |
9bb00 | 76 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 63 6f 6e 73 74 | v();.............foreach.($const |
9bb20 | 72 61 69 6e 74 42 72 61 6e 63 68 65 73 20 61 73 20 24 62 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | raintBranches.as.$b).{.......... |
9bb40 | 20 20 20 20 20 20 20 69 66 20 28 24 62 5b 27 65 78 63 6c 75 64 65 27 5d 29 20 7b 0a 20 20 20 20 | .......if.($b['exclude']).{..... |
9bb60 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 62 72 61 6e 63 68 65 73 5b 27 65 | ................if.($branches['e |
9bb80 | 78 63 6c 75 64 65 27 5d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | xclude']).{..................... |
9bba0 | 20 20 20 20 24 62 72 61 6e 63 68 65 73 5b 27 6e 61 6d 65 73 27 5d 20 3d 20 5c 61 72 72 61 79 5f | ....$branches['names'].=.\array_ |
9bbc0 | 6d 65 72 67 65 28 24 62 72 61 6e 63 68 65 73 5b 27 6e 61 6d 65 73 27 5d 2c 20 24 62 5b 27 6e 61 | merge($branches['names'],.$b['na |
9bbe0 | 6d 65 73 27 5d 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c | mes']);.....................}.el |
9bc00 | 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 62 72 | se.{.........................$br |
9bc20 | 61 6e 63 68 65 73 5b 27 6e 61 6d 65 73 27 5d 20 3d 20 5c 61 72 72 61 79 5f 64 69 66 66 28 24 62 | anches['names'].=.\array_diff($b |
9bc40 | 72 61 6e 63 68 65 73 5b 27 6e 61 6d 65 73 27 5d 2c 20 24 62 5b 27 6e 61 6d 65 73 27 5d 29 3b 0a | ranches['names'],.$b['names']);. |
9bc60 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 | ....................}........... |
9bc80 | 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ......}.else.{.................. |
9bca0 | 20 20 20 69 66 20 28 24 62 72 61 6e 63 68 65 73 5b 27 65 78 63 6c 75 64 65 27 5d 29 20 7b 0a 20 | ...if.($branches['exclude']).{.. |
9bcc0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 62 72 61 6e 63 68 65 73 | .......................$branches |
9bce0 | 5b 27 6e 61 6d 65 73 27 5d 20 3d 20 5c 61 72 72 61 79 5f 64 69 66 66 28 24 62 5b 27 6e 61 6d 65 | ['names'].=.\array_diff($b['name |
9bd00 | 73 27 5d 2c 20 24 62 72 61 6e 63 68 65 73 5b 27 6e 61 6d 65 73 27 5d 29 3b 0a 20 20 20 20 20 20 | s'],.$branches['names']);....... |
9bd20 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 62 72 61 6e 63 68 65 73 5b 27 65 78 63 | ..................$branches['exc |
9bd40 | 6c 75 64 65 27 5d 20 3d 20 5c 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | lude'].=.\false;................ |
9bd60 | 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | .....}.else.{................... |
9bd80 | 20 20 20 20 20 20 24 62 72 61 6e 63 68 65 73 5b 27 6e 61 6d 65 73 27 5d 20 3d 20 5c 61 72 72 61 | ......$branches['names'].=.\arra |
9bda0 | 79 5f 69 6e 74 65 72 73 65 63 74 28 24 62 72 61 6e 63 68 65 73 5b 27 6e 61 6d 65 73 27 5d 2c 20 | y_intersect($branches['names'],. |
9bdc0 | 24 62 5b 27 6e 61 6d 65 73 27 5d 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | $b['names']);................... |
9bde0 | 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 | ..}.................}........... |
9be00 | 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 24 62 72 61 6e 63 68 65 73 5b | ..}.........}.........$branches[ |
9be20 | 27 6e 61 6d 65 73 27 5d 20 3d 20 5c 61 72 72 61 79 5f 75 6e 69 71 75 65 28 24 62 72 61 6e 63 68 | 'names'].=.\array_unique($branch |
9be40 | 65 73 5b 27 6e 61 6d 65 73 27 5d 29 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 5c 63 6f 75 6e 74 | es['names']);.........if.(\count |
9be60 | 28 24 6e 75 6d 65 72 69 63 47 72 6f 75 70 73 29 20 3d 3d 3d 20 31 29 20 7b 0a 20 20 20 20 20 20 | ($numericGroups).===.1).{....... |
9be80 | 20 20 20 20 20 20 72 65 74 75 72 6e 20 61 72 72 61 79 28 27 6e 75 6d 65 72 69 63 27 20 3d 3e 20 | ......return.array('numeric'.=>. |
9bea0 | 24 6e 75 6d 65 72 69 63 47 72 6f 75 70 73 5b 30 5d 2c 20 27 62 72 61 6e 63 68 65 73 27 20 3d 3e | $numericGroups[0],.'branches'.=> |
9bec0 | 20 24 62 72 61 6e 63 68 65 73 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 24 | .$branches);.........}.........$ |
9bee0 | 62 6f 72 64 65 72 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 | borders.=.array();.........forea |
9bf00 | 63 68 20 28 24 6e 75 6d 65 72 69 63 47 72 6f 75 70 73 20 61 73 20 24 67 72 6f 75 70 29 20 7b 0a | ch.($numericGroups.as.$group).{. |
9bf20 | 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 67 72 6f 75 70 20 61 73 20 24 | ............foreach.($group.as.$ |
9bf40 | 69 6e 74 65 72 76 61 6c 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 62 6f 72 | interval).{.................$bor |
9bf60 | 64 65 72 73 5b 5d 20 3d 20 61 72 72 61 79 28 27 76 65 72 73 69 6f 6e 27 20 3d 3e 20 24 69 6e 74 | ders[].=.array('version'.=>.$int |
9bf80 | 65 72 76 61 6c 2d 3e 67 65 74 53 74 61 72 74 28 29 2d 3e 67 65 74 56 65 72 73 69 6f 6e 28 29 2c | erval->getStart()->getVersion(), |
9bfa0 | 20 27 6f 70 65 72 61 74 6f 72 27 20 3d 3e 20 24 69 6e 74 65 72 76 61 6c 2d 3e 67 65 74 53 74 61 | .'operator'.=>.$interval->getSta |
9bfc0 | 72 74 28 29 2d 3e 67 65 74 4f 70 65 72 61 74 6f 72 28 29 2c 20 27 73 69 64 65 27 20 3d 3e 20 27 | rt()->getOperator(),.'side'.=>.' |
9bfe0 | 73 74 61 72 74 27 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 62 6f 72 64 65 72 | start');.................$border |
9c000 | 73 5b 5d 20 3d 20 61 72 72 61 79 28 27 76 65 72 73 69 6f 6e 27 20 3d 3e 20 24 69 6e 74 65 72 76 | s[].=.array('version'.=>.$interv |
9c020 | 61 6c 2d 3e 67 65 74 45 6e 64 28 29 2d 3e 67 65 74 56 65 72 73 69 6f 6e 28 29 2c 20 27 6f 70 65 | al->getEnd()->getVersion(),.'ope |
9c040 | 72 61 74 6f 72 27 20 3d 3e 20 24 69 6e 74 65 72 76 61 6c 2d 3e 67 65 74 45 6e 64 28 29 2d 3e 67 | rator'.=>.$interval->getEnd()->g |
9c060 | 65 74 4f 70 65 72 61 74 6f 72 28 29 2c 20 27 73 69 64 65 27 20 3d 3e 20 27 65 6e 64 27 29 3b 0a | etOperator(),.'side'.=>.'end');. |
9c080 | 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 | ............}.........}......... |
9c0a0 | 24 6f 70 53 6f 72 74 4f 72 64 65 72 20 3d 20 73 65 6c 66 3a 3a 24 6f 70 53 6f 72 74 4f 72 64 65 | $opSortOrder.=.self::$opSortOrde |
9c0c0 | 72 3b 0a 20 20 20 20 20 20 20 20 5c 75 73 6f 72 74 28 24 62 6f 72 64 65 72 73 2c 20 66 75 6e 63 | r;.........\usort($borders,.func |
9c0e0 | 74 69 6f 6e 20 28 24 61 2c 20 24 62 29 20 75 73 65 28 24 6f 70 53 6f 72 74 4f 72 64 65 72 29 20 | tion.($a,.$b).use($opSortOrder). |
9c100 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 72 64 65 72 20 3d 20 5c 76 65 72 73 69 6f 6e 5f | {.............$order.=.\version_ |
9c120 | 63 6f 6d 70 61 72 65 28 24 61 5b 27 76 65 72 73 69 6f 6e 27 5d 2c 20 24 62 5b 27 76 65 72 73 69 | compare($a['version'],.$b['versi |
9c140 | 6f 6e 27 5d 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 6f 72 64 65 72 20 3d 3d | on']);.............if.($order.== |
9c160 | 3d 20 30 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 6f | =.0).{.................return.$o |
9c180 | 70 53 6f 72 74 4f 72 64 65 72 5b 24 61 5b 27 6f 70 65 72 61 74 6f 72 27 5d 5d 20 2d 20 24 6f 70 | pSortOrder[$a['operator']].-.$op |
9c1a0 | 53 6f 72 74 4f 72 64 65 72 5b 24 62 5b 27 6f 70 65 72 61 74 6f 72 27 5d 5d 3b 0a 20 20 20 20 20 | SortOrder[$b['operator']];...... |
9c1c0 | 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 6f 72 64 | .......}.............return.$ord |
9c1e0 | 65 72 3b 0a 20 20 20 20 20 20 20 20 7d 29 3b 0a 20 20 20 20 20 20 20 20 24 61 63 74 69 76 65 49 | er;.........});.........$activeI |
9c200 | 6e 74 65 72 76 61 6c 73 20 3d 20 30 3b 0a 20 20 20 20 20 20 20 20 24 69 6e 74 65 72 76 61 6c 73 | ntervals.=.0;.........$intervals |
9c220 | 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 24 69 6e 64 65 78 20 3d 20 30 3b 0a | .=.array();.........$index.=.0;. |
9c240 | 20 20 20 20 20 20 20 20 24 61 63 74 69 76 61 74 69 6f 6e 54 68 72 65 73 68 6f 6c 64 20 3d 20 24 | ........$activationThreshold.=.$ |
9c260 | 63 6f 6e 73 74 72 61 69 6e 74 2d 3e 69 73 43 6f 6e 6a 75 6e 63 74 69 76 65 28 29 20 3f 20 5c 63 | constraint->isConjunctive().?.\c |
9c280 | 6f 75 6e 74 28 24 6e 75 6d 65 72 69 63 47 72 6f 75 70 73 29 20 3a 20 31 3b 0a 20 20 20 20 20 20 | ount($numericGroups).:.1;....... |
9c2a0 | 20 20 24 61 63 74 69 76 65 20 3d 20 5c 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 24 73 74 61 | ..$active.=.\false;.........$sta |
9c2c0 | 72 74 20 3d 20 6e 75 6c 6c 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 62 6f 72 | rt.=.null;.........foreach.($bor |
9c2e0 | 64 65 72 73 20 61 73 20 24 62 6f 72 64 65 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 | ders.as.$border).{.............i |
9c300 | 66 20 28 24 62 6f 72 64 65 72 5b 27 73 69 64 65 27 5d 20 3d 3d 3d 20 27 73 74 61 72 74 27 29 20 | f.($border['side'].===.'start'). |
9c320 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 61 63 74 69 76 65 49 6e 74 65 72 76 61 | {.................$activeInterva |
9c340 | 6c 73 2b 2b 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 | ls++;.............}.else.{...... |
9c360 | 20 20 20 20 20 20 20 20 20 20 20 24 61 63 74 69 76 65 49 6e 74 65 72 76 61 6c 73 2d 2d 3b 0a 20 | ...........$activeIntervals--;.. |
9c380 | 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 21 24 61 | ...........}.............if.(!$a |
9c3a0 | 63 74 69 76 65 20 26 26 20 24 61 63 74 69 76 65 49 6e 74 65 72 76 61 6c 73 20 3e 3d 20 24 61 63 | ctive.&&.$activeIntervals.>=.$ac |
9c3c0 | 74 69 76 61 74 69 6f 6e 54 68 72 65 73 68 6f 6c 64 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | tivationThreshold).{............ |
9c3e0 | 20 20 20 20 20 24 73 74 61 72 74 20 3d 20 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 | .....$start.=.new.\HumbugBox3111 |
9c400 | 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 | \Composer\Semver\Constraint\Cons |
9c420 | 74 72 61 69 6e 74 28 24 62 6f 72 64 65 72 5b 27 6f 70 65 72 61 74 6f 72 27 5d 2c 20 24 62 6f 72 | traint($border['operator'],.$bor |
9c440 | 64 65 72 5b 27 76 65 72 73 69 6f 6e 27 5d 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | der['version']);................ |
9c460 | 20 24 61 63 74 69 76 65 20 3d 20 5c 74 72 75 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a | .$active.=.\true;.............}. |
9c480 | 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 61 63 74 69 76 65 20 26 26 20 24 61 63 74 69 | ............if.($active.&&.$acti |
9c4a0 | 76 65 49 6e 74 65 72 76 61 6c 73 20 3c 20 24 61 63 74 69 76 61 74 69 6f 6e 54 68 72 65 73 68 6f | veIntervals.<.$activationThresho |
9c4c0 | 6c 64 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 61 63 74 69 76 65 20 3d 20 | ld).{.................$active.=. |
9c4e0 | 5c 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 5c 76 65 72 | \false;.................if.(\ver |
9c500 | 73 69 6f 6e 5f 63 6f 6d 70 61 72 65 28 24 73 74 61 72 74 2d 3e 67 65 74 56 65 72 73 69 6f 6e 28 | sion_compare($start->getVersion( |
9c520 | 29 2c 20 24 62 6f 72 64 65 72 5b 27 76 65 72 73 69 6f 6e 27 5d 2c 20 27 3d 27 29 20 26 26 20 28 | ),.$border['version'],.'=').&&.( |
9c540 | 24 73 74 61 72 74 2d 3e 67 65 74 4f 70 65 72 61 74 6f 72 28 29 20 3d 3d 3d 20 27 3e 27 20 26 26 | $start->getOperator().===.'>'.&& |
9c560 | 20 24 62 6f 72 64 65 72 5b 27 6f 70 65 72 61 74 6f 72 27 5d 20 3d 3d 3d 20 27 3c 3d 27 20 7c 7c | .$border['operator'].===.'<='.|| |
9c580 | 20 24 73 74 61 72 74 2d 3e 67 65 74 4f 70 65 72 61 74 6f 72 28 29 20 3d 3d 3d 20 27 3e 3d 27 20 | .$start->getOperator().===.'>='. |
9c5a0 | 26 26 20 24 62 6f 72 64 65 72 5b 27 6f 70 65 72 61 74 6f 72 27 5d 20 3d 3d 3d 20 27 3c 27 29 29 | &&.$border['operator'].===.'<')) |
9c5c0 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 75 6e 73 65 74 28 24 69 6e | .{.....................unset($in |
9c5e0 | 74 65 72 76 61 6c 73 5b 24 69 6e 64 65 78 5d 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | tervals[$index]);............... |
9c600 | 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 | ..}.else.{.....................$ |
9c620 | 69 6e 74 65 72 76 61 6c 73 5b 24 69 6e 64 65 78 5d 20 3d 20 6e 65 77 20 5c 48 75 6d 62 75 67 42 | intervals[$index].=.new.\HumbugB |
9c640 | 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 49 6e 74 65 72 76 61 6c 28 | ox3111\Composer\Semver\Interval( |
9c660 | 24 73 74 61 72 74 2c 20 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f | $start,.new.\HumbugBox3111\Compo |
9c680 | 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 | ser\Semver\Constraint\Constraint |
9c6a0 | 28 24 62 6f 72 64 65 72 5b 27 6f 70 65 72 61 74 6f 72 27 5d 2c 20 24 62 6f 72 64 65 72 5b 27 76 | ($border['operator'],.$border['v |
9c6c0 | 65 72 73 69 6f 6e 27 5d 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ersion']));..................... |
9c6e0 | 24 69 6e 64 65 78 2b 2b 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 | $index++;.....................if |
9c700 | 20 28 24 73 74 6f 70 4f 6e 46 69 72 73 74 56 61 6c 69 64 49 6e 74 65 72 76 61 6c 29 20 7b 0a 20 | .($stopOnFirstValidInterval).{.. |
9c720 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 62 72 65 61 6b 3b 0a 20 20 | .......................break;... |
9c740 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ..................}............. |
9c760 | 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 73 74 61 72 74 20 3d 20 6e | ....}.................$start.=.n |
9c780 | 75 6c 6c 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 | ull;.............}.........}.... |
9c7a0 | 20 20 20 20 20 72 65 74 75 72 6e 20 61 72 72 61 79 28 27 6e 75 6d 65 72 69 63 27 20 3d 3e 20 24 | .....return.array('numeric'.=>.$ |
9c7c0 | 69 6e 74 65 72 76 61 6c 73 2c 20 27 62 72 61 6e 63 68 65 73 27 20 3d 3e 20 24 62 72 61 6e 63 68 | intervals,.'branches'.=>.$branch |
9c7e0 | 65 73 29 3b 0a 20 20 20 20 7d 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 40 70 68 70 73 74 61 6e 2d | es);.....}...../**.....@phpstan- |
9c800 | 72 65 74 75 72 6e 0a 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 | return.....*/.....private.static |
9c820 | 20 66 75 6e 63 74 69 6f 6e 20 67 65 6e 65 72 61 74 65 53 69 6e 67 6c 65 43 6f 6e 73 74 72 61 69 | .function.generateSingleConstrai |
9c840 | 6e 74 49 6e 74 65 72 76 61 6c 73 28 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f | ntIntervals(\HumbugBox3111\Compo |
9c860 | 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 | ser\Semver\Constraint\Constraint |
9c880 | 20 24 63 6f 6e 73 74 72 61 69 6e 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 6f 70 20 | .$constraint).....{.........$op. |
9c8a0 | 3d 20 24 63 6f 6e 73 74 72 61 69 6e 74 2d 3e 67 65 74 4f 70 65 72 61 74 6f 72 28 29 3b 0a 20 20 | =.$constraint->getOperator();... |
9c8c0 | 20 20 20 20 20 20 69 66 20 28 5c 73 75 62 73 74 72 28 24 63 6f 6e 73 74 72 61 69 6e 74 2d 3e 67 | ......if.(\substr($constraint->g |
9c8e0 | 65 74 56 65 72 73 69 6f 6e 28 29 2c 20 30 2c 20 34 29 20 3d 3d 3d 20 27 64 65 76 2d 27 29 20 7b | etVersion(),.0,.4).===.'dev-').{ |
9c900 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 69 6e 74 65 72 76 61 6c 73 20 3d 20 61 72 72 61 79 28 | .............$intervals.=.array( |
9c920 | 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 62 72 61 6e 63 68 65 73 20 3d 20 61 72 72 61 79 | );.............$branches.=.array |
9c940 | 28 27 6e 61 6d 65 73 27 20 3d 3e 20 61 72 72 61 79 28 29 2c 20 27 65 78 63 6c 75 64 65 27 20 3d | ('names'.=>.array(),.'exclude'.= |
9c960 | 3e 20 5c 66 61 6c 73 65 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 6f 70 20 3d | >.\false);.............if.($op.= |
9c980 | 3d 3d 20 27 21 3d 27 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 69 6e 74 65 | ==.'!=').{.................$inte |
9c9a0 | 72 76 61 6c 73 5b 5d 20 3d 20 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d | rvals[].=.new.\HumbugBox3111\Com |
9c9c0 | 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 49 6e 74 65 72 76 61 6c 28 5c 48 75 6d 62 75 67 42 6f 78 | poser\Semver\Interval(\HumbugBox |
9c9e0 | 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 49 6e 74 65 72 76 61 6c 3a 3a 66 | 3111\Composer\Semver\Interval::f |
9ca00 | 72 6f 6d 5a 65 72 6f 28 29 2c 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 | romZero(),.\HumbugBox3111\Compos |
9ca20 | 65 72 5c 53 65 6d 76 65 72 5c 49 6e 74 65 72 76 61 6c 3a 3a 75 6e 74 69 6c 50 6f 73 69 74 69 76 | er\Semver\Interval::untilPositiv |
9ca40 | 65 49 6e 66 69 6e 69 74 79 28 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 62 | eInfinity());.................$b |
9ca60 | 72 61 6e 63 68 65 73 20 3d 20 61 72 72 61 79 28 27 6e 61 6d 65 73 27 20 3d 3e 20 61 72 72 61 79 | ranches.=.array('names'.=>.array |
9ca80 | 28 24 63 6f 6e 73 74 72 61 69 6e 74 2d 3e 67 65 74 56 65 72 73 69 6f 6e 28 29 29 2c 20 27 65 78 | ($constraint->getVersion()),.'ex |
9caa0 | 63 6c 75 64 65 27 20 3d 3e 20 5c 74 72 75 65 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 | clude'.=>.\true);.............}. |
9cac0 | 65 6c 73 65 69 66 20 28 24 6f 70 20 3d 3d 3d 20 27 3d 3d 27 29 20 7b 0a 20 20 20 20 20 20 20 20 | elseif.($op.===.'==').{......... |
9cae0 | 20 20 20 20 20 20 20 20 24 62 72 61 6e 63 68 65 73 5b 27 6e 61 6d 65 73 27 5d 5b 5d 20 3d 20 24 | ........$branches['names'][].=.$ |
9cb00 | 63 6f 6e 73 74 72 61 69 6e 74 2d 3e 67 65 74 56 65 72 73 69 6f 6e 28 29 3b 0a 20 20 20 20 20 20 | constraint->getVersion();....... |
9cb20 | 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 61 72 72 61 79 | ......}.............return.array |
9cb40 | 28 27 6e 75 6d 65 72 69 63 27 20 3d 3e 20 24 69 6e 74 65 72 76 61 6c 73 2c 20 27 62 72 61 6e 63 | ('numeric'.=>.$intervals,.'branc |
9cb60 | 68 65 73 27 20 3d 3e 20 24 62 72 61 6e 63 68 65 73 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 | hes'.=>.$branches);.........}... |
9cb80 | 20 20 20 20 20 20 69 66 20 28 24 6f 70 5b 30 5d 20 3d 3d 3d 20 27 3e 27 29 20 7b 0a 20 20 20 20 | ......if.($op[0].===.'>').{..... |
9cba0 | 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 61 72 72 61 79 28 27 6e 75 6d 65 72 69 63 27 20 3d | ........return.array('numeric'.= |
9cbc0 | 3e 20 61 72 72 61 79 28 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f | >.array(new.\HumbugBox3111\Compo |
9cbe0 | 73 65 72 5c 53 65 6d 76 65 72 5c 49 6e 74 65 72 76 61 6c 28 24 63 6f 6e 73 74 72 61 69 6e 74 2c | ser\Semver\Interval($constraint, |
9cc00 | 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c | .\HumbugBox3111\Composer\Semver\ |
9cc20 | 49 6e 74 65 72 76 61 6c 3a 3a 75 6e 74 69 6c 50 6f 73 69 74 69 76 65 49 6e 66 69 6e 69 74 79 28 | Interval::untilPositiveInfinity( |
9cc40 | 29 29 29 2c 20 27 62 72 61 6e 63 68 65 73 27 20 3d 3e 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 | ))),.'branches'.=>.\HumbugBox311 |
9cc60 | 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 49 6e 74 65 72 76 61 6c 3a 3a 6e 6f 44 65 | 1\Composer\Semver\Interval::noDe |
9cc80 | 76 28 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 6f 70 5b | v());.........}.........if.($op[ |
9cca0 | 30 5d 20 3d 3d 3d 20 27 3c 27 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e | 0].===.'<').{.............return |
9ccc0 | 20 61 72 72 61 79 28 27 6e 75 6d 65 72 69 63 27 20 3d 3e 20 61 72 72 61 79 28 6e 65 77 20 5c 48 | .array('numeric'.=>.array(new.\H |
9cce0 | 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 49 6e 74 | umbugBox3111\Composer\Semver\Int |
9cd00 | 65 72 76 61 6c 28 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 | erval(\HumbugBox3111\Composer\Se |
9cd20 | 6d 76 65 72 5c 49 6e 74 65 72 76 61 6c 3a 3a 66 72 6f 6d 5a 65 72 6f 28 29 2c 20 24 63 6f 6e 73 | mver\Interval::fromZero(),.$cons |
9cd40 | 74 72 61 69 6e 74 29 29 2c 20 27 62 72 61 6e 63 68 65 73 27 20 3d 3e 20 5c 48 75 6d 62 75 67 42 | traint)),.'branches'.=>.\HumbugB |
9cd60 | 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 49 6e 74 65 72 76 61 6c 3a | ox3111\Composer\Semver\Interval: |
9cd80 | 3a 6e 6f 44 65 76 28 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 | :noDev());.........}.........if. |
9cda0 | 28 24 6f 70 20 3d 3d 3d 20 27 21 3d 27 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 | ($op.===.'!=').{.............ret |
9cdc0 | 75 72 6e 20 61 72 72 61 79 28 27 6e 75 6d 65 72 69 63 27 20 3d 3e 20 61 72 72 61 79 28 6e 65 77 | urn.array('numeric'.=>.array(new |
9cde0 | 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c | .\HumbugBox3111\Composer\Semver\ |
9ce00 | 49 6e 74 65 72 76 61 6c 28 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 | Interval(\HumbugBox3111\Composer |
9ce20 | 5c 53 65 6d 76 65 72 5c 49 6e 74 65 72 76 61 6c 3a 3a 66 72 6f 6d 5a 65 72 6f 28 29 2c 20 6e 65 | \Semver\Interval::fromZero(),.ne |
9ce40 | 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 | w.\HumbugBox3111\Composer\Semver |
9ce60 | 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 28 27 3c 27 2c 20 24 63 6f 6e | \Constraint\Constraint('<',.$con |
9ce80 | 73 74 72 61 69 6e 74 2d 3e 67 65 74 56 65 72 73 69 6f 6e 28 29 29 29 2c 20 6e 65 77 20 5c 48 75 | straint->getVersion())),.new.\Hu |
9cea0 | 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 49 6e 74 65 | mbugBox3111\Composer\Semver\Inte |
9cec0 | 72 76 61 6c 28 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 | rval(new.\HumbugBox3111\Composer |
9cee0 | 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 28 27 3e | \Semver\Constraint\Constraint('> |
9cf00 | 27 2c 20 24 63 6f 6e 73 74 72 61 69 6e 74 2d 3e 67 65 74 56 65 72 73 69 6f 6e 28 29 29 2c 20 5c | ',.$constraint->getVersion()),.\ |
9cf20 | 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 49 6e | HumbugBox3111\Composer\Semver\In |
9cf40 | 74 65 72 76 61 6c 3a 3a 75 6e 74 69 6c 50 6f 73 69 74 69 76 65 49 6e 66 69 6e 69 74 79 28 29 29 | terval::untilPositiveInfinity()) |
9cf60 | 29 2c 20 27 62 72 61 6e 63 68 65 73 27 20 3d 3e 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c | ),.'branches'.=>.\HumbugBox3111\ |
9cf80 | 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 49 6e 74 65 72 76 61 6c 3a 3a 61 6e 79 44 65 76 | Composer\Semver\Interval::anyDev |
9cfa0 | 28 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 61 72 | ());.........}.........return.ar |
9cfc0 | 72 61 79 28 27 6e 75 6d 65 72 69 63 27 20 3d 3e 20 61 72 72 61 79 28 6e 65 77 20 5c 48 75 6d 62 | ray('numeric'.=>.array(new.\Humb |
9cfe0 | 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 49 6e 74 65 72 76 | ugBox3111\Composer\Semver\Interv |
9d000 | 61 6c 28 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 | al(new.\HumbugBox3111\Composer\S |
9d020 | 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 28 27 3e 3d 27 | emver\Constraint\Constraint('>=' |
9d040 | 2c 20 24 63 6f 6e 73 74 72 61 69 6e 74 2d 3e 67 65 74 56 65 72 73 69 6f 6e 28 29 29 2c 20 6e 65 | ,.$constraint->getVersion()),.ne |
9d060 | 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 | w.\HumbugBox3111\Composer\Semver |
9d080 | 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 28 27 3c 3d 27 2c 20 24 63 6f | \Constraint\Constraint('<=',.$co |
9d0a0 | 6e 73 74 72 61 69 6e 74 2d 3e 67 65 74 56 65 72 73 69 6f 6e 28 29 29 29 29 2c 20 27 62 72 61 6e | nstraint->getVersion()))),.'bran |
9d0c0 | 63 68 65 73 27 20 3d 3e 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 | ches'.=>.\HumbugBox3111\Composer |
9d0e0 | 5c 53 65 6d 76 65 72 5c 49 6e 74 65 72 76 61 6c 3a 3a 6e 6f 44 65 76 28 29 29 3b 0a 20 20 20 20 | \Semver\Interval::noDev());..... |
9d100 | 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 6e 61 6d 65 73 70 61 63 65 20 48 75 6d 62 75 67 42 6f 78 33 31 | }.}.<?php..namespace.HumbugBox31 |
9d120 | 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 3b 0a 0a 75 73 65 20 48 75 6d 62 75 67 42 | 11\Composer\Semver;..use.HumbugB |
9d140 | 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e | ox3111\Composer\Semver\Constrain |
9d160 | 74 5c 43 6f 6e 73 74 72 61 69 6e 74 3b 0a 63 6c 61 73 73 20 49 6e 74 65 72 76 61 6c 0a 7b 0a 20 | t\Constraint;.class.Interval.{.. |
9d180 | 20 20 20 70 72 69 76 61 74 65 20 24 73 74 61 72 74 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 | ...private.$start;.....private.$ |
9d1a0 | 65 6e 64 3b 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 63 6f 6e 73 74 | end;.....public.function.__const |
9d1c0 | 72 75 63 74 28 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d | ruct(\HumbugBox3111\Composer\Sem |
9d1e0 | 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 20 24 73 74 61 72 74 | ver\Constraint\Constraint.$start |
9d200 | 2c 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 | ,.\HumbugBox3111\Composer\Semver |
9d220 | 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 20 24 65 6e 64 29 0a 20 20 20 | \Constraint\Constraint.$end).... |
9d240 | 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 74 61 72 74 20 3d 20 24 73 74 61 72 74 | .{.........$this->start.=.$start |
9d260 | 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 65 6e 64 20 3d 20 24 65 6e 64 3b 0a 20 20 20 | ;.........$this->end.=.$end;.... |
9d280 | 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 53 74 61 72 74 28 | .}.....public.function.getStart( |
9d2a0 | 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 73 74 | ).....{.........return.$this->st |
9d2c0 | 61 72 74 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 | art;.....}.....public.function.g |
9d2e0 | 65 74 45 6e 64 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 | etEnd().....{.........return.$th |
9d300 | 69 73 2d 3e 65 6e 64 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 | is->end;.....}.....public.static |
9d320 | 20 66 75 6e 63 74 69 6f 6e 20 66 72 6f 6d 5a 65 72 6f 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 | .function.fromZero().....{...... |
9d340 | 20 20 20 73 74 61 74 69 63 20 24 7a 65 72 6f 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c | ...static.$zero;.........if.(nul |
9d360 | 6c 20 3d 3d 3d 20 24 7a 65 72 6f 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 7a 65 72 6f | l.===.$zero).{.............$zero |
9d380 | 20 3d 20 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 | .=.new.\HumbugBox3111\Composer\S |
9d3a0 | 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 28 27 3e 3d 27 | emver\Constraint\Constraint('>=' |
9d3c0 | 2c 20 27 30 2e 30 2e 30 2e 30 2d 64 65 76 27 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 | ,.'0.0.0.0-dev');.........}..... |
9d3e0 | 20 20 20 20 72 65 74 75 72 6e 20 24 7a 65 72 6f 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c | ....return.$zero;.....}.....publ |
9d400 | 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 75 6e 74 69 6c 50 6f 73 69 74 69 76 65 | ic.static.function.untilPositive |
9d420 | 49 6e 66 69 6e 69 74 79 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 73 74 61 74 69 63 20 | Infinity().....{.........static. |
9d440 | 24 70 6f 73 69 74 69 76 65 49 6e 66 69 6e 69 74 79 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e | $positiveInfinity;.........if.(n |
9d460 | 75 6c 6c 20 3d 3d 3d 20 24 70 6f 73 69 74 69 76 65 49 6e 66 69 6e 69 74 79 29 20 7b 0a 20 20 20 | ull.===.$positiveInfinity).{.... |
9d480 | 20 20 20 20 20 20 20 20 20 24 70 6f 73 69 74 69 76 65 49 6e 66 69 6e 69 74 79 20 3d 20 6e 65 77 | .........$positiveInfinity.=.new |
9d4a0 | 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c | .\HumbugBox3111\Composer\Semver\ |
9d4c0 | 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 28 27 3c 27 2c 20 5c 50 48 50 5f | Constraint\Constraint('<',.\PHP_ |
9d4e0 | 49 4e 54 5f 4d 41 58 20 2e 20 27 2e 30 2e 30 2e 30 27 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 | INT_MAX...'.0.0.0');.........}.. |
9d500 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 70 6f 73 69 74 69 76 65 49 6e 66 69 6e 69 74 79 3b | .......return.$positiveInfinity; |
9d520 | 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f | .....}.....public.static.functio |
9d540 | 6e 20 61 6e 79 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6e 65 77 | n.any().....{.........return.new |
9d560 | 20 73 65 6c 66 28 73 65 6c 66 3a 3a 66 72 6f 6d 5a 65 72 6f 28 29 2c 20 73 65 6c 66 3a 3a 75 6e | .self(self::fromZero(),.self::un |
9d580 | 74 69 6c 50 6f 73 69 74 69 76 65 49 6e 66 69 6e 69 74 79 28 29 29 3b 0a 20 20 20 20 7d 0a 20 20 | tilPositiveInfinity());.....}... |
9d5a0 | 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 61 6e 79 44 65 76 28 | ..public.static.function.anyDev( |
9d5c0 | 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 61 72 72 61 79 28 27 6e 61 | ).....{.........return.array('na |
9d5e0 | 6d 65 73 27 20 3d 3e 20 61 72 72 61 79 28 29 2c 20 27 65 78 63 6c 75 64 65 27 20 3d 3e 20 5c 74 | mes'.=>.array(),.'exclude'.=>.\t |
9d600 | 72 75 65 29 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 | rue);.....}.....public.static.fu |
9d620 | 6e 63 74 69 6f 6e 20 6e 6f 44 65 76 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 | nction.noDev().....{.........ret |
9d640 | 75 72 6e 20 61 72 72 61 79 28 27 6e 61 6d 65 73 27 20 3d 3e 20 61 72 72 61 79 28 29 2c 20 27 65 | urn.array('names'.=>.array(),.'e |
9d660 | 78 63 6c 75 64 65 27 20 3d 3e 20 5c 66 61 6c 73 65 29 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 | xclude'.=>.\false);.....}.}.<?ph |
9d680 | 70 0a 0a 6e 61 6d 65 73 70 61 63 65 20 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f | p..namespace.HumbugBox3111\Compo |
9d6a0 | 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 3b 0a 0a 63 6c 61 73 73 20 4d 75 | ser\Semver\Constraint;..class.Mu |
9d6c0 | 6c 74 69 43 6f 6e 73 74 72 61 69 6e 74 20 69 6d 70 6c 65 6d 65 6e 74 73 20 5c 48 75 6d 62 75 67 | ltiConstraint.implements.\Humbug |
9d6e0 | 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 | Box3111\Composer\Semver\Constrai |
9d700 | 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 49 6e 74 65 72 66 61 63 65 0a 7b 0a 20 20 20 20 70 72 6f | nt\ConstraintInterface.{.....pro |
9d720 | 74 65 63 74 65 64 20 24 63 6f 6e 73 74 72 61 69 6e 74 73 3b 0a 20 20 20 20 70 72 6f 74 65 63 74 | tected.$constraints;.....protect |
9d740 | 65 64 20 24 70 72 65 74 74 79 53 74 72 69 6e 67 3b 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 | ed.$prettyString;.....protected. |
9d760 | 24 73 74 72 69 6e 67 3b 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 24 63 6f 6e 6a 75 6e 63 74 | $string;.....protected.$conjunct |
9d780 | 69 76 65 3b 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 24 6c 6f 77 65 72 42 6f 75 6e 64 3b 0a | ive;.....protected.$lowerBound;. |
9d7a0 | 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 24 75 70 70 65 72 42 6f 75 6e 64 3b 0a 20 20 20 20 70 | ....protected.$upperBound;.....p |
9d7c0 | 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 74 28 61 72 72 61 79 | ublic.function.__construct(array |
9d7e0 | 20 24 63 6f 6e 73 74 72 61 69 6e 74 73 2c 20 24 63 6f 6e 6a 75 6e 63 74 69 76 65 20 3d 20 5c 74 | .$constraints,.$conjunctive.=.\t |
9d800 | 72 75 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 5c 63 6f 75 6e 74 28 24 63 | rue).....{.........if.(\count($c |
9d820 | 6f 6e 73 74 72 61 69 6e 74 73 29 20 3c 20 32 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 | onstraints).<.2).{.............t |
9d840 | 68 72 6f 77 20 6e 65 77 20 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 | hrow.new.\InvalidArgumentExcepti |
9d860 | 6f 6e 28 27 4d 75 73 74 20 70 72 6f 76 69 64 65 20 61 74 20 6c 65 61 73 74 20 74 77 6f 20 63 6f | on('Must.provide.at.least.two.co |
9d880 | 6e 73 74 72 61 69 6e 74 73 20 66 6f 72 20 61 20 4d 75 6c 74 69 43 6f 6e 73 74 72 61 69 6e 74 2e | nstraints.for.a.MultiConstraint. |
9d8a0 | 20 55 73 65 20 27 20 2e 20 27 74 68 65 20 72 65 67 75 6c 61 72 20 43 6f 6e 73 74 72 61 69 6e 74 | .Use.'...'the.regular.Constraint |
9d8c0 | 20 63 6c 61 73 73 20 66 6f 72 20 6f 6e 65 20 63 6f 6e 73 74 72 61 69 6e 74 20 6f 6e 6c 79 20 6f | .class.for.one.constraint.only.o |
9d8e0 | 72 20 4d 61 74 63 68 41 6c 6c 43 6f 6e 73 74 72 61 69 6e 74 20 66 6f 72 20 6e 6f 6e 65 2e 20 59 | r.MatchAllConstraint.for.none..Y |
9d900 | 6f 75 20 6d 61 79 20 75 73 65 20 27 20 2e 20 27 4d 75 6c 74 69 43 6f 6e 73 74 72 61 69 6e 74 3a | ou.may.use.'...'MultiConstraint: |
9d920 | 3a 63 72 65 61 74 65 28 29 20 77 68 69 63 68 20 6f 70 74 69 6d 69 7a 65 73 20 61 6e 64 20 68 61 | :create().which.optimizes.and.ha |
9d940 | 6e 64 6c 65 73 20 74 68 6f 73 65 20 63 61 73 65 73 20 61 75 74 6f 6d 61 74 69 63 61 6c 6c 79 2e | ndles.those.cases.automatically. |
9d960 | 27 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 63 6f 6e | ');.........}.........$this->con |
9d980 | 73 74 72 61 69 6e 74 73 20 3d 20 24 63 6f 6e 73 74 72 61 69 6e 74 73 3b 0a 20 20 20 20 20 20 20 | straints.=.$constraints;........ |
9d9a0 | 20 24 74 68 69 73 2d 3e 63 6f 6e 6a 75 6e 63 74 69 76 65 20 3d 20 24 63 6f 6e 6a 75 6e 63 74 69 | .$this->conjunctive.=.$conjuncti |
9d9c0 | 76 65 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 | ve;.....}.....public.function.ge |
9d9e0 | 74 43 6f 6e 73 74 72 61 69 6e 74 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 | tConstraints().....{.........ret |
9da00 | 75 72 6e 20 24 74 68 69 73 2d 3e 63 6f 6e 73 74 72 61 69 6e 74 73 3b 0a 20 20 20 20 7d 0a 20 20 | urn.$this->constraints;.....}... |
9da20 | 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 69 73 43 6f 6e 6a 75 6e 63 74 69 76 65 28 | ..public.function.isConjunctive( |
9da40 | 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 63 6f | ).....{.........return.$this->co |
9da60 | 6e 6a 75 6e 63 74 69 76 65 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 | njunctive;.....}.....public.func |
9da80 | 74 69 6f 6e 20 69 73 44 69 73 6a 75 6e 63 74 69 76 65 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 | tion.isDisjunctive().....{...... |
9daa0 | 20 20 20 72 65 74 75 72 6e 20 21 24 74 68 69 73 2d 3e 63 6f 6e 6a 75 6e 63 74 69 76 65 3b 0a 20 | ...return.!$this->conjunctive;.. |
9dac0 | 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 63 6f 6d 70 69 6c 65 | ...}.....public.function.compile |
9dae0 | 28 24 6f 74 68 65 72 4f 70 65 72 61 74 6f 72 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 | ($otherOperator).....{.........$ |
9db00 | 70 61 72 74 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 | parts.=.array();.........foreach |
9db20 | 20 28 24 74 68 69 73 2d 3e 63 6f 6e 73 74 72 61 69 6e 74 73 20 61 73 20 24 63 6f 6e 73 74 72 61 | .($this->constraints.as.$constra |
9db40 | 69 6e 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6f 64 65 20 3d 20 24 63 6f 6e 73 | int).{.............$code.=.$cons |
9db60 | 74 72 61 69 6e 74 2d 3e 63 6f 6d 70 69 6c 65 28 24 6f 74 68 65 72 4f 70 65 72 61 74 6f 72 29 3b | traint->compile($otherOperator); |
9db80 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 63 6f 64 65 20 3d 3d 3d 20 27 74 72 75 65 | .............if.($code.===.'true |
9dba0 | 27 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 21 24 74 68 69 73 2d | ').{.................if.(!$this- |
9dbc0 | 3e 63 6f 6e 6a 75 6e 63 74 69 76 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | >conjunctive).{................. |
9dbe0 | 20 20 20 20 72 65 74 75 72 6e 20 27 74 72 75 65 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | ....return.'true';.............. |
9dc00 | 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 24 63 6f 64 65 | ...}.............}.elseif.($code |
9dc20 | 20 3d 3d 3d 20 27 66 61 6c 73 65 27 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | .===.'false').{................. |
9dc40 | 69 66 20 28 24 74 68 69 73 2d 3e 63 6f 6e 6a 75 6e 63 74 69 76 65 29 20 7b 0a 20 20 20 20 20 20 | if.($this->conjunctive).{....... |
9dc60 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 27 66 61 6c 73 65 27 3b 0a 20 20 | ..............return.'false';... |
9dc80 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c | ..............}.............}.el |
9dca0 | 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 70 61 72 74 73 5b 5d 20 3d 20 | se.{.................$parts[].=. |
9dcc0 | 27 28 27 20 2e 20 24 63 6f 64 65 20 2e 20 27 29 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d | '('...$code...')';.............} |
9dce0 | 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 24 70 61 72 74 73 29 20 | .........}.........if.(!$parts). |
9dd00 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 63 6f 6e 6a | {.............return.$this->conj |
9dd20 | 75 6e 63 74 69 76 65 20 3f 20 27 74 72 75 65 27 20 3a 20 27 66 61 6c 73 65 27 3b 0a 20 20 20 20 | unctive.?.'true'.:.'false';..... |
9dd40 | 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 63 6f 6e 6a | ....}.........return.$this->conj |
9dd60 | 75 6e 63 74 69 76 65 20 3f 20 5c 69 6d 70 6c 6f 64 65 28 27 26 26 27 2c 20 24 70 61 72 74 73 29 | unctive.?.\implode('&&',.$parts) |
9dd80 | 20 3a 20 5c 69 6d 70 6c 6f 64 65 28 27 7c 7c 27 2c 20 24 70 61 72 74 73 29 3b 0a 20 20 20 20 7d | .:.\implode('||',.$parts);.....} |
9dda0 | 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 6d 61 74 63 68 65 73 28 5c 48 75 | .....public.function.matches(\Hu |
9ddc0 | 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 | mbugBox3111\Composer\Semver\Cons |
9dde0 | 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 49 6e 74 65 72 66 61 63 65 20 24 70 72 6f 76 | traint\ConstraintInterface.$prov |
9de00 | 69 64 65 72 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 5c 66 61 6c 73 65 20 3d | ider).....{.........if.(\false.= |
9de20 | 3d 3d 20 24 74 68 69 73 2d 3e 63 6f 6e 6a 75 6e 63 74 69 76 65 29 20 7b 0a 20 20 20 20 20 20 20 | ==.$this->conjunctive).{........ |
9de40 | 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 74 68 69 73 2d 3e 63 6f 6e 73 74 72 61 69 6e 74 73 | .....foreach.($this->constraints |
9de60 | 20 61 73 20 24 63 6f 6e 73 74 72 61 69 6e 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | .as.$constraint).{.............. |
9de80 | 20 20 20 69 66 20 28 24 70 72 6f 76 69 64 65 72 2d 3e 6d 61 74 63 68 65 73 28 24 63 6f 6e 73 74 | ...if.($provider->matches($const |
9dea0 | 72 61 69 6e 74 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 | raint)).{.....................re |
9dec0 | 74 75 72 6e 20 5c 74 72 75 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 | turn.\true;.................}... |
9dee0 | 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 5c | ..........}.............return.\ |
9df00 | 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 | false;.........}.........foreach |
9df20 | 20 28 24 74 68 69 73 2d 3e 63 6f 6e 73 74 72 61 69 6e 74 73 20 61 73 20 24 63 6f 6e 73 74 72 61 | .($this->constraints.as.$constra |
9df40 | 69 6e 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 21 24 70 72 6f 76 69 64 65 | int).{.............if.(!$provide |
9df60 | 72 2d 3e 6d 61 74 63 68 65 73 28 24 63 6f 6e 73 74 72 61 69 6e 74 29 29 20 7b 0a 20 20 20 20 20 | r->matches($constraint)).{...... |
9df80 | 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 5c 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 | ...........return.\false;....... |
9dfa0 | 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e | ......}.........}.........return |
9dfc0 | 20 5c 74 72 75 65 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f | .\true;.....}.....public.functio |
9dfe0 | 6e 20 73 65 74 50 72 65 74 74 79 53 74 72 69 6e 67 28 24 70 72 65 74 74 79 53 74 72 69 6e 67 29 | n.setPrettyString($prettyString) |
9e000 | 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 70 72 65 74 74 79 53 74 72 69 | .....{.........$this->prettyStri |
9e020 | 6e 67 20 3d 20 24 70 72 65 74 74 79 53 74 72 69 6e 67 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 | ng.=.$prettyString;.....}.....pu |
9e040 | 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 50 72 65 74 74 79 53 74 72 69 6e 67 28 29 0a | blic.function.getPrettyString(). |
9e060 | 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 74 68 69 73 2d 3e 70 72 65 74 74 79 53 | ....{.........if.($this->prettyS |
9e080 | 74 72 69 6e 67 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 | tring).{.............return.$thi |
9e0a0 | 73 2d 3e 70 72 65 74 74 79 53 74 72 69 6e 67 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 | s->prettyString;.........}...... |
9e0c0 | 20 20 20 72 65 74 75 72 6e 20 28 73 74 72 69 6e 67 29 20 24 74 68 69 73 3b 0a 20 20 20 20 7d 0a | ...return.(string).$this;.....}. |
9e0e0 | 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 74 6f 53 74 72 69 6e 67 28 29 | ....public.function.__toString() |
9e100 | 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 74 68 69 73 2d 3e 73 74 72 69 6e 67 | .....{.........if.($this->string |
9e120 | 20 21 3d 3d 20 6e 75 6c 6c 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 | .!==.null).{.............return. |
9e140 | 24 74 68 69 73 2d 3e 73 74 72 69 6e 67 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 | $this->string;.........}........ |
9e160 | 20 24 63 6f 6e 73 74 72 61 69 6e 74 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 | .$constraints.=.array();........ |
9e180 | 20 66 6f 72 65 61 63 68 20 28 24 74 68 69 73 2d 3e 63 6f 6e 73 74 72 61 69 6e 74 73 20 61 73 20 | .foreach.($this->constraints.as. |
9e1a0 | 24 63 6f 6e 73 74 72 61 69 6e 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6f 6e 73 | $constraint).{.............$cons |
9e1c0 | 74 72 61 69 6e 74 73 5b 5d 20 3d 20 28 73 74 72 69 6e 67 29 20 24 63 6f 6e 73 74 72 61 69 6e 74 | traints[].=.(string).$constraint |
9e1e0 | 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 | ;.........}.........return.$this |
9e200 | 2d 3e 73 74 72 69 6e 67 20 3d 20 27 5b 27 20 2e 20 5c 69 6d 70 6c 6f 64 65 28 24 74 68 69 73 2d | ->string.=.'['...\implode($this- |
9e220 | 3e 63 6f 6e 6a 75 6e 63 74 69 76 65 20 3f 20 27 20 27 20 3a 20 27 20 7c 7c 20 27 2c 20 24 63 6f | >conjunctive.?.'.'.:.'.||.',.$co |
9e240 | 6e 73 74 72 61 69 6e 74 73 29 20 2e 20 27 5d 27 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c | nstraints)...']';.....}.....publ |
9e260 | 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 4c 6f 77 65 72 42 6f 75 6e 64 28 29 0a 20 20 20 20 | ic.function.getLowerBound()..... |
9e280 | 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 65 78 74 72 61 63 74 42 6f 75 6e 64 73 28 29 | {.........$this->extractBounds() |
9e2a0 | 3b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 6c 6f 77 65 72 42 6f 75 | ;.........return.$this->lowerBou |
9e2c0 | 6e 64 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 | nd;.....}.....public.function.ge |
9e2e0 | 74 55 70 70 65 72 42 6f 75 6e 64 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 | tUpperBound().....{.........$thi |
9e300 | 73 2d 3e 65 78 74 72 61 63 74 42 6f 75 6e 64 73 28 29 3b 0a 20 20 20 20 20 20 20 20 72 65 74 75 | s->extractBounds();.........retu |
9e320 | 72 6e 20 24 74 68 69 73 2d 3e 75 70 70 65 72 42 6f 75 6e 64 3b 0a 20 20 20 20 7d 0a 20 20 20 20 | rn.$this->upperBound;.....}..... |
9e340 | 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 63 72 65 61 74 65 28 61 72 | public.static.function.create(ar |
9e360 | 72 61 79 20 24 63 6f 6e 73 74 72 61 69 6e 74 73 2c 20 24 63 6f 6e 6a 75 6e 63 74 69 76 65 20 3d | ray.$constraints,.$conjunctive.= |
9e380 | 20 5c 74 72 75 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 30 20 3d 3d 3d 20 | .\true).....{.........if.(0.===. |
9e3a0 | 5c 63 6f 75 6e 74 28 24 63 6f 6e 73 74 72 61 69 6e 74 73 29 29 20 7b 0a 20 20 20 20 20 20 20 20 | \count($constraints)).{......... |
9e3c0 | 20 20 20 20 72 65 74 75 72 6e 20 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f | ....return.new.\HumbugBox3111\Co |
9e3e0 | 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 4d 61 74 63 68 41 6c | mposer\Semver\Constraint\MatchAl |
9e400 | 6c 43 6f 6e 73 74 72 61 69 6e 74 28 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 | lConstraint();.........}........ |
9e420 | 20 69 66 20 28 31 20 3d 3d 3d 20 5c 63 6f 75 6e 74 28 24 63 6f 6e 73 74 72 61 69 6e 74 73 29 29 | .if.(1.===.\count($constraints)) |
9e440 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 63 6f 6e 73 74 72 61 69 6e | .{.............return.$constrain |
9e460 | 74 73 5b 30 5d 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 24 6f 70 74 69 6d 69 | ts[0];.........}.........$optimi |
9e480 | 7a 65 64 20 3d 20 73 65 6c 66 3a 3a 6f 70 74 69 6d 69 7a 65 43 6f 6e 73 74 72 61 69 6e 74 73 28 | zed.=.self::optimizeConstraints( |
9e4a0 | 24 63 6f 6e 73 74 72 61 69 6e 74 73 2c 20 24 63 6f 6e 6a 75 6e 63 74 69 76 65 29 3b 0a 20 20 20 | $constraints,.$conjunctive);.... |
9e4c0 | 20 20 20 20 20 69 66 20 28 24 6f 70 74 69 6d 69 7a 65 64 20 21 3d 3d 20 6e 75 6c 6c 29 20 7b 0a | .....if.($optimized.!==.null).{. |
9e4e0 | 20 20 20 20 20 20 20 20 20 20 20 20 6c 69 73 74 28 24 63 6f 6e 73 74 72 61 69 6e 74 73 2c 20 24 | ............list($constraints,.$ |
9e500 | 63 6f 6e 6a 75 6e 63 74 69 76 65 29 20 3d 20 24 6f 70 74 69 6d 69 7a 65 64 3b 0a 20 20 20 20 20 | conjunctive).=.$optimized;...... |
9e520 | 20 20 20 20 20 20 20 69 66 20 28 5c 63 6f 75 6e 74 28 24 63 6f 6e 73 74 72 61 69 6e 74 73 29 20 | .......if.(\count($constraints). |
9e540 | 3d 3d 3d 20 31 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 | ===.1).{.................return. |
9e560 | 24 63 6f 6e 73 74 72 61 69 6e 74 73 5b 30 5d 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 | $constraints[0];.............}.. |
9e580 | 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6e 65 77 20 73 65 6c 66 | .......}.........return.new.self |
9e5a0 | 28 24 63 6f 6e 73 74 72 61 69 6e 74 73 2c 20 24 63 6f 6e 6a 75 6e 63 74 69 76 65 29 3b 0a 20 20 | ($constraints,.$conjunctive);... |
9e5c0 | 20 20 7d 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 | ..}.....private.static.function. |
9e5e0 | 6f 70 74 69 6d 69 7a 65 43 6f 6e 73 74 72 61 69 6e 74 73 28 61 72 72 61 79 20 24 63 6f 6e 73 74 | optimizeConstraints(array.$const |
9e600 | 72 61 69 6e 74 73 2c 20 24 63 6f 6e 6a 75 6e 63 74 69 76 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 | raints,.$conjunctive).....{..... |
9e620 | 20 20 20 20 69 66 20 28 21 24 63 6f 6e 6a 75 6e 63 74 69 76 65 29 20 7b 0a 20 20 20 20 20 20 20 | ....if.(!$conjunctive).{........ |
9e640 | 20 20 20 20 20 24 6c 65 66 74 20 3d 20 24 63 6f 6e 73 74 72 61 69 6e 74 73 5b 30 5d 3b 0a 20 20 | .....$left.=.$constraints[0];... |
9e660 | 20 20 20 20 20 20 20 20 20 20 24 6d 65 72 67 65 64 43 6f 6e 73 74 72 61 69 6e 74 73 20 3d 20 61 | ..........$mergedConstraints.=.a |
9e680 | 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 70 74 69 6d 69 7a 65 64 20 3d | rray();.............$optimized.= |
9e6a0 | 20 5c 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 20 28 24 69 20 3d 20 31 | .\false;.............for.($i.=.1 |
9e6c0 | 2c 20 24 6c 20 3d 20 5c 63 6f 75 6e 74 28 24 63 6f 6e 73 74 72 61 69 6e 74 73 29 3b 20 24 69 20 | ,.$l.=.\count($constraints);.$i. |
9e6e0 | 3c 20 24 6c 3b 20 24 69 2b 2b 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 72 | <.$l;.$i++).{.................$r |
9e700 | 69 67 68 74 20 3d 20 24 63 6f 6e 73 74 72 61 69 6e 74 73 5b 24 69 5d 3b 0a 20 20 20 20 20 20 20 | ight.=.$constraints[$i];........ |
9e720 | 20 20 20 20 20 20 20 20 20 69 66 20 28 24 6c 65 66 74 20 69 6e 73 74 61 6e 63 65 6f 66 20 5c 48 | .........if.($left.instanceof.\H |
9e740 | 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e | umbugBox3111\Composer\Semver\Con |
9e760 | 73 74 72 61 69 6e 74 5c 4d 75 6c 74 69 43 6f 6e 73 74 72 61 69 6e 74 20 26 26 20 24 6c 65 66 74 | straint\MultiConstraint.&&.$left |
9e780 | 2d 3e 63 6f 6e 6a 75 6e 63 74 69 76 65 20 26 26 20 24 72 69 67 68 74 20 69 6e 73 74 61 6e 63 65 | ->conjunctive.&&.$right.instance |
9e7a0 | 6f 66 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 | of.\HumbugBox3111\Composer\Semve |
9e7c0 | 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 4d 75 6c 74 69 43 6f 6e 73 74 72 61 69 6e 74 20 26 26 20 | r\Constraint\MultiConstraint.&&. |
9e7e0 | 24 72 69 67 68 74 2d 3e 63 6f 6e 6a 75 6e 63 74 69 76 65 20 26 26 20 28 24 6c 65 66 74 30 20 3d | $right->conjunctive.&&.($left0.= |
9e800 | 20 28 73 74 72 69 6e 67 29 20 24 6c 65 66 74 2d 3e 63 6f 6e 73 74 72 61 69 6e 74 73 5b 30 5d 29 | .(string).$left->constraints[0]) |
9e820 | 20 26 26 20 24 6c 65 66 74 30 5b 30 5d 20 3d 3d 3d 20 27 3e 27 20 26 26 20 24 6c 65 66 74 30 5b | .&&.$left0[0].===.'>'.&&.$left0[ |
9e840 | 31 5d 20 3d 3d 3d 20 27 3d 27 20 26 26 20 28 24 6c 65 66 74 31 20 3d 20 28 73 74 72 69 6e 67 29 | 1].===.'='.&&.($left1.=.(string) |
9e860 | 20 24 6c 65 66 74 2d 3e 63 6f 6e 73 74 72 61 69 6e 74 73 5b 31 5d 29 20 26 26 20 24 6c 65 66 74 | .$left->constraints[1]).&&.$left |
9e880 | 31 5b 30 5d 20 3d 3d 3d 20 27 3c 27 20 26 26 20 28 24 72 69 67 68 74 30 20 3d 20 28 73 74 72 69 | 1[0].===.'<'.&&.($right0.=.(stri |
9e8a0 | 6e 67 29 20 24 72 69 67 68 74 2d 3e 63 6f 6e 73 74 72 61 69 6e 74 73 5b 30 5d 29 20 26 26 20 24 | ng).$right->constraints[0]).&&.$ |
9e8c0 | 72 69 67 68 74 30 5b 30 5d 20 3d 3d 3d 20 27 3e 27 20 26 26 20 24 72 69 67 68 74 30 5b 31 5d 20 | right0[0].===.'>'.&&.$right0[1]. |
9e8e0 | 3d 3d 3d 20 27 3d 27 20 26 26 20 28 24 72 69 67 68 74 31 20 3d 20 28 73 74 72 69 6e 67 29 20 24 | ===.'='.&&.($right1.=.(string).$ |
9e900 | 72 69 67 68 74 2d 3e 63 6f 6e 73 74 72 61 69 6e 74 73 5b 31 5d 29 20 26 26 20 24 72 69 67 68 74 | right->constraints[1]).&&.$right |
9e920 | 31 5b 30 5d 20 3d 3d 3d 20 27 3c 27 20 26 26 20 5c 73 75 62 73 74 72 28 24 6c 65 66 74 31 2c 20 | 1[0].===.'<'.&&.\substr($left1,. |
9e940 | 32 29 20 3d 3d 3d 20 5c 73 75 62 73 74 72 28 24 72 69 67 68 74 30 2c 20 33 29 29 20 7b 0a 20 20 | 2).===.\substr($right0,.3)).{... |
9e960 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6f 70 74 69 6d 69 7a 65 64 20 3d 20 5c | ..................$optimized.=.\ |
9e980 | 74 72 75 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 65 66 74 20 | true;.....................$left. |
9e9a0 | 3d 20 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 | =.new.\HumbugBox3111\Composer\Se |
9e9c0 | 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 4d 75 6c 74 69 43 6f 6e 73 74 72 61 69 6e 74 28 | mver\Constraint\MultiConstraint( |
9e9e0 | 5c 61 72 72 61 79 5f 6d 65 72 67 65 28 61 72 72 61 79 28 24 6c 65 66 74 2d 3e 63 6f 6e 73 74 72 | \array_merge(array($left->constr |
9ea00 | 61 69 6e 74 73 5b 30 5d 2c 20 24 72 69 67 68 74 2d 3e 63 6f 6e 73 74 72 61 69 6e 74 73 5b 31 5d | aints[0],.$right->constraints[1] |
9ea20 | 29 2c 20 5c 61 72 72 61 79 5f 73 6c 69 63 65 28 24 6c 65 66 74 2d 3e 63 6f 6e 73 74 72 61 69 6e | ),.\array_slice($left->constrain |
9ea40 | 74 73 2c 20 32 29 2c 20 5c 61 72 72 61 79 5f 73 6c 69 63 65 28 24 72 69 67 68 74 2d 3e 63 6f 6e | ts,.2),.\array_slice($right->con |
9ea60 | 73 74 72 61 69 6e 74 73 2c 20 32 29 29 2c 20 5c 74 72 75 65 29 3b 0a 20 20 20 20 20 20 20 20 20 | straints,.2)),.\true);.......... |
9ea80 | 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | .......}.else.{................. |
9eaa0 | 20 20 20 20 24 6d 65 72 67 65 64 43 6f 6e 73 74 72 61 69 6e 74 73 5b 5d 20 3d 20 24 6c 65 66 74 | ....$mergedConstraints[].=.$left |
9eac0 | 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 65 66 74 20 3d 20 24 72 | ;.....................$left.=.$r |
9eae0 | 69 67 68 74 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 | ight;.................}......... |
9eb00 | 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 6f 70 74 69 6d 69 7a 65 64 | ....}.............if.($optimized |
9eb20 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6d 65 72 67 65 64 43 6f 6e 73 74 | ).{.................$mergedConst |
9eb40 | 72 61 69 6e 74 73 5b 5d 20 3d 20 24 6c 65 66 74 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | raints[].=.$left;............... |
9eb60 | 20 20 72 65 74 75 72 6e 20 61 72 72 61 79 28 24 6d 65 72 67 65 64 43 6f 6e 73 74 72 61 69 6e 74 | ..return.array($mergedConstraint |
9eb80 | 73 2c 20 5c 66 61 6c 73 65 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 | s,.\false);.............}....... |
9eba0 | 20 20 7d 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6e 75 6c 6c 3b 0a 20 20 20 20 7d 0a 20 | ..}.........return.null;.....}.. |
9ebc0 | 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 65 78 74 72 61 63 74 42 6f 75 6e 64 | ...private.function.extractBound |
9ebe0 | 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 21 3d 3d 20 24 | s().....{.........if.(null.!==.$ |
9ec00 | 74 68 69 73 2d 3e 6c 6f 77 65 72 42 6f 75 6e 64 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | this->lowerBound).{............. |
9ec20 | 72 65 74 75 72 6e 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 | return;.........}.........foreac |
9ec40 | 68 20 28 24 74 68 69 73 2d 3e 63 6f 6e 73 74 72 61 69 6e 74 73 20 61 73 20 24 63 6f 6e 73 74 72 | h.($this->constraints.as.$constr |
9ec60 | 61 69 6e 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d | aint).{.............if.(null.=== |
9ec80 | 20 24 74 68 69 73 2d 3e 6c 6f 77 65 72 42 6f 75 6e 64 20 26 26 20 6e 75 6c 6c 20 3d 3d 3d 20 24 | .$this->lowerBound.&&.null.===.$ |
9eca0 | 74 68 69 73 2d 3e 75 70 70 65 72 42 6f 75 6e 64 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | this->upperBound).{............. |
9ecc0 | 20 20 20 20 24 74 68 69 73 2d 3e 6c 6f 77 65 72 42 6f 75 6e 64 20 3d 20 24 63 6f 6e 73 74 72 61 | ....$this->lowerBound.=.$constra |
9ece0 | 69 6e 74 2d 3e 67 65 74 4c 6f 77 65 72 42 6f 75 6e 64 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 | int->getLowerBound();........... |
9ed00 | 20 20 20 20 20 20 24 74 68 69 73 2d 3e 75 70 70 65 72 42 6f 75 6e 64 20 3d 20 24 63 6f 6e 73 74 | ......$this->upperBound.=.$const |
9ed20 | 72 61 69 6e 74 2d 3e 67 65 74 55 70 70 65 72 42 6f 75 6e 64 28 29 3b 0a 20 20 20 20 20 20 20 20 | raint->getUpperBound();......... |
9ed40 | 20 20 20 20 20 20 20 20 63 6f 6e 74 69 6e 75 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a | ........continue;.............}. |
9ed60 | 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 63 6f 6e 73 74 72 61 69 6e 74 2d 3e 67 65 74 | ............if.($constraint->get |
9ed80 | 4c 6f 77 65 72 42 6f 75 6e 64 28 29 2d 3e 63 6f 6d 70 61 72 65 54 6f 28 24 74 68 69 73 2d 3e 6c | LowerBound()->compareTo($this->l |
9eda0 | 6f 77 65 72 42 6f 75 6e 64 2c 20 24 74 68 69 73 2d 3e 69 73 43 6f 6e 6a 75 6e 63 74 69 76 65 28 | owerBound,.$this->isConjunctive( |
9edc0 | 29 20 3f 20 27 3e 27 20 3a 20 27 3c 27 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ).?.'>'.:.'<')).{............... |
9ede0 | 20 20 24 74 68 69 73 2d 3e 6c 6f 77 65 72 42 6f 75 6e 64 20 3d 20 24 63 6f 6e 73 74 72 61 69 6e | ..$this->lowerBound.=.$constrain |
9ee00 | 74 2d 3e 67 65 74 4c 6f 77 65 72 42 6f 75 6e 64 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | t->getLowerBound();............. |
9ee20 | 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 63 6f 6e 73 74 72 61 69 6e 74 2d 3e 67 | }.............if.($constraint->g |
9ee40 | 65 74 55 70 70 65 72 42 6f 75 6e 64 28 29 2d 3e 63 6f 6d 70 61 72 65 54 6f 28 24 74 68 69 73 2d | etUpperBound()->compareTo($this- |
9ee60 | 3e 75 70 70 65 72 42 6f 75 6e 64 2c 20 24 74 68 69 73 2d 3e 69 73 43 6f 6e 6a 75 6e 63 74 69 76 | >upperBound,.$this->isConjunctiv |
9ee80 | 65 28 29 20 3f 20 27 3c 27 20 3a 20 27 3e 27 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | e().?.'<'.:.'>')).{............. |
9eea0 | 20 20 20 20 24 74 68 69 73 2d 3e 75 70 70 65 72 42 6f 75 6e 64 20 3d 20 24 63 6f 6e 73 74 72 61 | ....$this->upperBound.=.$constra |
9eec0 | 69 6e 74 2d 3e 67 65 74 55 70 70 65 72 42 6f 75 6e 64 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 | int->getUpperBound();........... |
9eee0 | 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 6e 61 6d | ..}.........}.....}.}.<?php..nam |
9ef00 | 65 73 70 61 63 65 20 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 | espace.HumbugBox3111\Composer\Se |
9ef20 | 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 3b 0a 0a 63 6c 61 73 73 20 4d 61 74 63 68 4e 6f 6e | mver\Constraint;..class.MatchNon |
9ef40 | 65 43 6f 6e 73 74 72 61 69 6e 74 20 69 6d 70 6c 65 6d 65 6e 74 73 20 5c 48 75 6d 62 75 67 42 6f | eConstraint.implements.\HumbugBo |
9ef60 | 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 | x3111\Composer\Semver\Constraint |
9ef80 | 5c 43 6f 6e 73 74 72 61 69 6e 74 49 6e 74 65 72 66 61 63 65 0a 7b 0a 20 20 20 20 70 72 6f 74 65 | \ConstraintInterface.{.....prote |
9efa0 | 63 74 65 64 20 24 70 72 65 74 74 79 53 74 72 69 6e 67 3b 0a 20 20 20 20 70 75 62 6c 69 63 20 66 | cted.$prettyString;.....public.f |
9efc0 | 75 6e 63 74 69 6f 6e 20 6d 61 74 63 68 65 73 28 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 | unction.matches(\HumbugBox3111\C |
9efe0 | 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 | omposer\Semver\Constraint\Constr |
9f000 | 61 69 6e 74 49 6e 74 65 72 66 61 63 65 20 24 70 72 6f 76 69 64 65 72 29 0a 20 20 20 20 7b 0a 20 | aintInterface.$provider).....{.. |
9f020 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 5c 66 61 6c 73 65 3b 0a 20 20 20 20 7d 0a 20 20 20 20 | .......return.\false;.....}..... |
9f040 | 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 63 6f 6d 70 69 6c 65 28 24 6f 70 65 72 61 74 6f | public.function.compile($operato |
9f060 | 72 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 27 66 61 6c 73 65 27 3b | r).....{.........return.'false'; |
9f080 | 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 50 72 | .....}.....public.function.setPr |
9f0a0 | 65 74 74 79 53 74 72 69 6e 67 28 24 70 72 65 74 74 79 53 74 72 69 6e 67 29 0a 20 20 20 20 7b 0a | ettyString($prettyString).....{. |
9f0c0 | 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 70 72 65 74 74 79 53 74 72 69 6e 67 20 3d 20 24 70 | ........$this->prettyString.=.$p |
9f0e0 | 72 65 74 74 79 53 74 72 69 6e 67 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 | rettyString;.....}.....public.fu |
9f100 | 6e 63 74 69 6f 6e 20 67 65 74 50 72 65 74 74 79 53 74 72 69 6e 67 28 29 0a 20 20 20 20 7b 0a 20 | nction.getPrettyString().....{.. |
9f120 | 20 20 20 20 20 20 20 69 66 20 28 24 74 68 69 73 2d 3e 70 72 65 74 74 79 53 74 72 69 6e 67 29 20 | .......if.($this->prettyString). |
9f140 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 70 72 65 74 | {.............return.$this->pret |
9f160 | 74 79 53 74 72 69 6e 67 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 72 65 74 75 | tyString;.........}.........retu |
9f180 | 72 6e 20 28 73 74 72 69 6e 67 29 20 24 74 68 69 73 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 | rn.(string).$this;.....}.....pub |
9f1a0 | 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 74 6f 53 74 72 69 6e 67 28 29 0a 20 20 20 20 7b 0a | lic.function.__toString().....{. |
9f1c0 | 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 27 5b 5d 27 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 | ........return.'[]';.....}.....p |
9f1e0 | 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 55 70 70 65 72 42 6f 75 6e 64 28 29 0a 20 | ublic.function.getUpperBound().. |
9f200 | 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6e 65 77 20 5c 48 75 6d 62 75 67 42 | ...{.........return.new.\HumbugB |
9f220 | 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e | ox3111\Composer\Semver\Constrain |
9f240 | 74 5c 42 6f 75 6e 64 28 27 30 2e 30 2e 30 2e 30 2d 64 65 76 27 2c 20 5c 66 61 6c 73 65 29 3b 0a | t\Bound('0.0.0.0-dev',.\false);. |
9f260 | 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 4c 6f 77 | ....}.....public.function.getLow |
9f280 | 65 72 42 6f 75 6e 64 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6e | erBound().....{.........return.n |
9f2a0 | 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 | ew.\HumbugBox3111\Composer\Semve |
9f2c0 | 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 42 6f 75 6e 64 28 27 30 2e 30 2e 30 2e 30 2d 64 65 76 27 | r\Constraint\Bound('0.0.0.0-dev' |
9f2e0 | 2c 20 5c 66 61 6c 73 65 29 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 6e 61 6d 65 73 70 | ,.\false);.....}.}.<?php..namesp |
9f300 | 61 63 65 20 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 | ace.HumbugBox3111\Composer\Semve |
9f320 | 72 5c 43 6f 6e 73 74 72 61 69 6e 74 3b 0a 0a 63 6c 61 73 73 20 4d 61 74 63 68 41 6c 6c 43 6f 6e | r\Constraint;..class.MatchAllCon |
9f340 | 73 74 72 61 69 6e 74 20 69 6d 70 6c 65 6d 65 6e 74 73 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 | straint.implements.\HumbugBox311 |
9f360 | 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e | 1\Composer\Semver\Constraint\Con |
9f380 | 73 74 72 61 69 6e 74 49 6e 74 65 72 66 61 63 65 0a 7b 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 | straintInterface.{.....protected |
9f3a0 | 20 24 70 72 65 74 74 79 53 74 72 69 6e 67 3b 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 | .$prettyString;.....public.funct |
9f3c0 | 69 6f 6e 20 6d 61 74 63 68 65 73 28 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f | ion.matches(\HumbugBox3111\Compo |
9f3e0 | 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 | ser\Semver\Constraint\Constraint |
9f400 | 49 6e 74 65 72 66 61 63 65 20 24 70 72 6f 76 69 64 65 72 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 | Interface.$provider).....{...... |
9f420 | 20 20 20 72 65 74 75 72 6e 20 5c 74 72 75 65 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 | ...return.\true;.....}.....publi |
9f440 | 63 20 66 75 6e 63 74 69 6f 6e 20 63 6f 6d 70 69 6c 65 28 24 6f 70 65 72 61 74 6f 72 29 0a 20 20 | c.function.compile($operator)... |
9f460 | 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 27 74 72 75 65 27 3b 0a 20 20 20 20 7d | ..{.........return.'true';.....} |
9f480 | 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 50 72 65 74 74 79 53 74 | .....public.function.setPrettySt |
9f4a0 | 72 69 6e 67 28 24 70 72 65 74 74 79 53 74 72 69 6e 67 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 | ring($prettyString).....{....... |
9f4c0 | 20 20 24 74 68 69 73 2d 3e 70 72 65 74 74 79 53 74 72 69 6e 67 20 3d 20 24 70 72 65 74 74 79 53 | ..$this->prettyString.=.$prettyS |
9f4e0 | 74 72 69 6e 67 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e | tring;.....}.....public.function |
9f500 | 20 67 65 74 50 72 65 74 74 79 53 74 72 69 6e 67 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 | .getPrettyString().....{........ |
9f520 | 20 69 66 20 28 24 74 68 69 73 2d 3e 70 72 65 74 74 79 53 74 72 69 6e 67 29 20 7b 0a 20 20 20 20 | .if.($this->prettyString).{..... |
9f540 | 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 70 72 65 74 74 79 53 74 72 69 | ........return.$this->prettyStri |
9f560 | 6e 67 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 28 73 74 | ng;.........}.........return.(st |
9f580 | 72 69 6e 67 29 20 24 74 68 69 73 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 | ring).$this;.....}.....public.fu |
9f5a0 | 6e 63 74 69 6f 6e 20 5f 5f 74 6f 53 74 72 69 6e 67 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 | nction.__toString().....{....... |
9f5c0 | 20 20 72 65 74 75 72 6e 20 27 2a 27 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 | ..return.'*';.....}.....public.f |
9f5e0 | 75 6e 63 74 69 6f 6e 20 67 65 74 55 70 70 65 72 42 6f 75 6e 64 28 29 0a 20 20 20 20 7b 0a 20 20 | unction.getUpperBound().....{... |
9f600 | 20 20 20 20 20 20 72 65 74 75 72 6e 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 | ......return.\HumbugBox3111\Comp |
9f620 | 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 42 6f 75 6e 64 3a 3a 70 6f | oser\Semver\Constraint\Bound::po |
9f640 | 73 69 74 69 76 65 49 6e 66 69 6e 69 74 79 28 29 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c | sitiveInfinity();.....}.....publ |
9f660 | 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 4c 6f 77 65 72 42 6f 75 6e 64 28 29 0a 20 20 20 20 | ic.function.getLowerBound()..... |
9f680 | 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c | {.........return.\HumbugBox3111\ |
9f6a0 | 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 42 6f 75 6e 64 | Composer\Semver\Constraint\Bound |
9f6c0 | 3a 3a 7a 65 72 6f 28 29 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 6e 61 6d 65 73 70 61 | ::zero();.....}.}.<?php..namespa |
9f6e0 | 63 65 20 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 | ce.HumbugBox3111\Composer\Semver |
9f700 | 5c 43 6f 6e 73 74 72 61 69 6e 74 3b 0a 0a 69 6e 74 65 72 66 61 63 65 20 43 6f 6e 73 74 72 61 69 | \Constraint;..interface.Constrai |
9f720 | 6e 74 49 6e 74 65 72 66 61 63 65 0a 7b 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f | ntInterface.{.....public.functio |
9f740 | 6e 20 6d 61 74 63 68 65 73 28 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 | n.matches(\HumbugBox3111\Compose |
9f760 | 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 49 6e | r\Semver\Constraint\ConstraintIn |
9f780 | 74 65 72 66 61 63 65 20 24 70 72 6f 76 69 64 65 72 29 3b 0a 20 20 20 20 70 75 62 6c 69 63 20 66 | terface.$provider);.....public.f |
9f7a0 | 75 6e 63 74 69 6f 6e 20 63 6f 6d 70 69 6c 65 28 24 6f 70 65 72 61 74 6f 72 29 3b 0a 20 20 20 20 | unction.compile($operator);..... |
9f7c0 | 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 55 70 70 65 72 42 6f 75 6e 64 28 29 3b | public.function.getUpperBound(); |
9f7e0 | 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 4c 6f 77 65 72 42 6f 75 | .....public.function.getLowerBou |
9f800 | 6e 64 28 29 3b 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 50 72 65 | nd();.....public.function.getPre |
9f820 | 74 74 79 53 74 72 69 6e 67 28 29 3b 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e | ttyString();.....public.function |
9f840 | 20 73 65 74 50 72 65 74 74 79 53 74 72 69 6e 67 28 24 70 72 65 74 74 79 53 74 72 69 6e 67 29 3b | .setPrettyString($prettyString); |
9f860 | 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 74 6f 53 74 72 69 6e 67 28 | .....public.function.__toString( |
9f880 | 29 3b 0a 7d 0a 3c 3f 70 68 70 0a 0a 6e 61 6d 65 73 70 61 63 65 20 48 75 6d 62 75 67 42 6f 78 33 | );.}.<?php..namespace.HumbugBox3 |
9f8a0 | 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 3b 0a | 111\Composer\Semver\Constraint;. |
9f8c0 | 0a 63 6c 61 73 73 20 43 6f 6e 73 74 72 61 69 6e 74 20 69 6d 70 6c 65 6d 65 6e 74 73 20 5c 48 75 | .class.Constraint.implements.\Hu |
9f8e0 | 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 | mbugBox3111\Composer\Semver\Cons |
9f900 | 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 49 6e 74 65 72 66 61 63 65 0a 7b 0a 20 20 20 | traint\ConstraintInterface.{.... |
9f920 | 20 63 6f 6e 73 74 20 4f 50 5f 45 51 20 3d 20 30 3b 0a 20 20 20 20 63 6f 6e 73 74 20 4f 50 5f 4c | .const.OP_EQ.=.0;.....const.OP_L |
9f940 | 54 20 3d 20 31 3b 0a 20 20 20 20 63 6f 6e 73 74 20 4f 50 5f 4c 45 20 3d 20 32 3b 0a 20 20 20 20 | T.=.1;.....const.OP_LE.=.2;..... |
9f960 | 63 6f 6e 73 74 20 4f 50 5f 47 54 20 3d 20 33 3b 0a 20 20 20 20 63 6f 6e 73 74 20 4f 50 5f 47 45 | const.OP_GT.=.3;.....const.OP_GE |
9f980 | 20 3d 20 34 3b 0a 20 20 20 20 63 6f 6e 73 74 20 4f 50 5f 4e 45 20 3d 20 35 3b 0a 20 20 20 20 2f | .=.4;.....const.OP_NE.=.5;...../ |
9f9a0 | 2a 2a 0a 20 20 20 20 40 70 68 70 73 74 61 6e 2d 76 61 72 0a 20 20 20 20 2a 2f 0a 20 20 20 20 70 | **.....@phpstan-var.....*/.....p |
9f9c0 | 72 69 76 61 74 65 20 73 74 61 74 69 63 20 24 74 72 61 6e 73 4f 70 53 74 72 20 3d 20 61 72 72 61 | rivate.static.$transOpStr.=.arra |
9f9e0 | 79 28 27 3d 27 20 3d 3e 20 73 65 6c 66 3a 3a 4f 50 5f 45 51 2c 20 27 3d 3d 27 20 3d 3e 20 73 65 | y('='.=>.self::OP_EQ,.'=='.=>.se |
9fa00 | 6c 66 3a 3a 4f 50 5f 45 51 2c 20 27 3c 27 20 3d 3e 20 73 65 6c 66 3a 3a 4f 50 5f 4c 54 2c 20 27 | lf::OP_EQ,.'<'.=>.self::OP_LT,.' |
9fa20 | 3c 3d 27 20 3d 3e 20 73 65 6c 66 3a 3a 4f 50 5f 4c 45 2c 20 27 3e 27 20 3d 3e 20 73 65 6c 66 3a | <='.=>.self::OP_LE,.'>'.=>.self: |
9fa40 | 3a 4f 50 5f 47 54 2c 20 27 3e 3d 27 20 3d 3e 20 73 65 6c 66 3a 3a 4f 50 5f 47 45 2c 20 27 3c 3e | :OP_GT,.'>='.=>.self::OP_GE,.'<> |
9fa60 | 27 20 3d 3e 20 73 65 6c 66 3a 3a 4f 50 5f 4e 45 2c 20 27 21 3d 27 20 3d 3e 20 73 65 6c 66 3a 3a | '.=>.self::OP_NE,.'!='.=>.self:: |
9fa80 | 4f 50 5f 4e 45 29 3b 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 40 70 68 70 73 74 61 6e 2d 76 61 72 | OP_NE);...../**.....@phpstan-var |
9faa0 | 0a 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 24 74 72 61 6e | .....*/.....private.static.$tran |
9fac0 | 73 4f 70 49 6e 74 20 3d 20 61 72 72 61 79 28 73 65 6c 66 3a 3a 4f 50 5f 45 51 20 3d 3e 20 27 3d | sOpInt.=.array(self::OP_EQ.=>.'= |
9fae0 | 3d 27 2c 20 73 65 6c 66 3a 3a 4f 50 5f 4c 54 20 3d 3e 20 27 3c 27 2c 20 73 65 6c 66 3a 3a 4f 50 | =',.self::OP_LT.=>.'<',.self::OP |
9fb00 | 5f 4c 45 20 3d 3e 20 27 3c 3d 27 2c 20 73 65 6c 66 3a 3a 4f 50 5f 47 54 20 3d 3e 20 27 3e 27 2c | _LE.=>.'<=',.self::OP_GT.=>.'>', |
9fb20 | 20 73 65 6c 66 3a 3a 4f 50 5f 47 45 20 3d 3e 20 27 3e 3d 27 2c 20 73 65 6c 66 3a 3a 4f 50 5f 4e | .self::OP_GE.=>.'>=',.self::OP_N |
9fb40 | 45 20 3d 3e 20 27 21 3d 27 29 3b 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 40 70 68 70 73 74 61 6e | E.=>.'!=');...../**.....@phpstan |
9fb60 | 2d 76 61 72 0a 20 20 20 20 2a 2f 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 24 6f 70 65 72 61 | -var.....*/.....protected.$opera |
9fb80 | 74 6f 72 3b 0a 20 20 20 20 70 72 6f 74 65 63 74 65 64 20 24 76 65 72 73 69 6f 6e 3b 0a 20 20 20 | tor;.....protected.$version;.... |
9fba0 | 20 70 72 6f 74 65 63 74 65 64 20 24 70 72 65 74 74 79 53 74 72 69 6e 67 3b 0a 20 20 20 20 70 72 | .protected.$prettyString;.....pr |
9fbc0 | 6f 74 65 63 74 65 64 20 24 6c 6f 77 65 72 42 6f 75 6e 64 3b 0a 20 20 20 20 70 72 6f 74 65 63 74 | otected.$lowerBound;.....protect |
9fbe0 | 65 64 20 24 75 70 70 65 72 42 6f 75 6e 64 3b 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 | ed.$upperBound;.....public.funct |
9fc00 | 69 6f 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 74 28 24 6f 70 65 72 61 74 6f 72 2c 20 24 76 65 72 73 | ion.__construct($operator,.$vers |
9fc20 | 69 6f 6e 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 69 73 73 65 74 28 73 65 | ion).....{.........if.(!isset(se |
9fc40 | 6c 66 3a 3a 24 74 72 61 6e 73 4f 70 53 74 72 5b 24 6f 70 65 72 61 74 6f 72 5d 29 29 20 7b 0a 20 | lf::$transOpStr[$operator])).{.. |
9fc60 | 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 5c 49 6e 76 61 6c 69 64 41 72 67 | ...........throw.new.\InvalidArg |
9fc80 | 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 5c 73 70 72 69 6e 74 66 28 27 49 6e 76 61 6c 69 64 | umentException(\sprintf('Invalid |
9fca0 | 20 6f 70 65 72 61 74 6f 72 20 22 25 73 22 20 67 69 76 65 6e 2c 20 65 78 70 65 63 74 65 64 20 6f | .operator."%s".given,.expected.o |
9fcc0 | 6e 65 20 6f 66 3a 20 25 73 27 2c 20 24 6f 70 65 72 61 74 6f 72 2c 20 5c 69 6d 70 6c 6f 64 65 28 | ne.of:.%s',.$operator,.\implode( |
9fce0 | 27 2c 20 27 2c 20 73 65 6c 66 3a 3a 67 65 74 53 75 70 70 6f 72 74 65 64 4f 70 65 72 61 74 6f 72 | ',.',.self::getSupportedOperator |
9fd00 | 73 28 29 29 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d | s())));.........}.........$this- |
9fd20 | 3e 6f 70 65 72 61 74 6f 72 20 3d 20 73 65 6c 66 3a 3a 24 74 72 61 6e 73 4f 70 53 74 72 5b 24 6f | >operator.=.self::$transOpStr[$o |
9fd40 | 70 65 72 61 74 6f 72 5d 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 76 65 72 73 69 6f 6e | perator];.........$this->version |
9fd60 | 20 3d 20 24 76 65 72 73 69 6f 6e 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 | .=.$version;.....}.....public.fu |
9fd80 | 6e 63 74 69 6f 6e 20 67 65 74 56 65 72 73 69 6f 6e 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 | nction.getVersion().....{....... |
9fda0 | 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 76 65 72 73 69 6f 6e 3b 0a 20 20 20 20 7d 0a 20 | ..return.$this->version;.....}.. |
9fdc0 | 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 4f 70 65 72 61 74 6f 72 28 29 | ...public.function.getOperator() |
9fde0 | 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 3a 3a 24 74 72 61 | .....{.........return.self::$tra |
9fe00 | 6e 73 4f 70 49 6e 74 5b 24 74 68 69 73 2d 3e 6f 70 65 72 61 74 6f 72 5d 3b 0a 20 20 20 20 7d 0a | nsOpInt[$this->operator];.....}. |
9fe20 | 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 6d 61 74 63 68 65 73 28 5c 48 75 6d | ....public.function.matches(\Hum |
9fe40 | 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 | bugBox3111\Composer\Semver\Const |
9fe60 | 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 49 6e 74 65 72 66 61 63 65 20 24 70 72 6f 76 69 | raint\ConstraintInterface.$provi |
9fe80 | 64 65 72 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 70 72 6f 76 69 64 65 72 | der).....{.........if.($provider |
9fea0 | 20 69 6e 73 74 61 6e 63 65 6f 66 20 73 65 6c 66 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | .instanceof.self).{............. |
9fec0 | 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 6d 61 74 63 68 53 70 65 63 69 66 69 63 28 24 70 72 6f | return.$this->matchSpecific($pro |
9fee0 | 76 69 64 65 72 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e | vider);.........}.........return |
9ff00 | 20 24 70 72 6f 76 69 64 65 72 2d 3e 6d 61 74 63 68 65 73 28 24 74 68 69 73 29 3b 0a 20 20 20 20 | .$provider->matches($this);..... |
9ff20 | 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 50 72 65 74 74 79 53 | }.....public.function.setPrettyS |
9ff40 | 74 72 69 6e 67 28 24 70 72 65 74 74 79 53 74 72 69 6e 67 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 | tring($prettyString).....{...... |
9ff60 | 20 20 20 24 74 68 69 73 2d 3e 70 72 65 74 74 79 53 74 72 69 6e 67 20 3d 20 24 70 72 65 74 74 79 | ...$this->prettyString.=.$pretty |
9ff80 | 53 74 72 69 6e 67 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f | String;.....}.....public.functio |
9ffa0 | 6e 20 67 65 74 50 72 65 74 74 79 53 74 72 69 6e 67 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 | n.getPrettyString().....{....... |
9ffc0 | 20 20 69 66 20 28 24 74 68 69 73 2d 3e 70 72 65 74 74 79 53 74 72 69 6e 67 29 20 7b 0a 20 20 20 | ..if.($this->prettyString).{.... |
9ffe0 | 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 70 72 65 74 74 79 53 74 72 | .........return.$this->prettyStr |
a0000 | 69 6e 67 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 | ing;.........}.........return.$t |
a0020 | 68 69 73 2d 3e 5f 5f 74 6f 53 74 72 69 6e 67 28 29 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 | his->__toString();.....}.....pub |
a0040 | 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 53 75 70 70 6f 72 74 65 64 | lic.static.function.getSupported |
a0060 | 4f 70 65 72 61 74 6f 72 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e | Operators().....{.........return |
a0080 | 20 5c 61 72 72 61 79 5f 6b 65 79 73 28 73 65 6c 66 3a 3a 24 74 72 61 6e 73 4f 70 53 74 72 29 3b | .\array_keys(self::$transOpStr); |
a00a0 | 0a 20 20 20 20 7d 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 40 70 68 70 73 74 61 6e 2d 72 65 74 75 | .....}...../**.....@phpstan-retu |
a00c0 | 72 6e 0a 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 | rn.....*/.....public.static.func |
a00e0 | 74 69 6f 6e 20 67 65 74 4f 70 65 72 61 74 6f 72 43 6f 6e 73 74 61 6e 74 28 24 6f 70 65 72 61 74 | tion.getOperatorConstant($operat |
a0100 | 6f 72 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 3a 3a 24 | or).....{.........return.self::$ |
a0120 | 74 72 61 6e 73 4f 70 53 74 72 5b 24 6f 70 65 72 61 74 6f 72 5d 3b 0a 20 20 20 20 7d 0a 20 20 20 | transOpStr[$operator];.....}.... |
a0140 | 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 76 65 72 73 69 6f 6e 43 6f 6d 70 61 72 65 28 | .public.function.versionCompare( |
a0160 | 24 61 2c 20 24 62 2c 20 24 6f 70 65 72 61 74 6f 72 2c 20 24 63 6f 6d 70 61 72 65 42 72 61 6e 63 | $a,.$b,.$operator,.$compareBranc |
a0180 | 68 65 73 20 3d 20 5c 66 61 6c 73 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 | hes.=.\false).....{.........if.( |
a01a0 | 21 69 73 73 65 74 28 73 65 6c 66 3a 3a 24 74 72 61 6e 73 4f 70 53 74 72 5b 24 6f 70 65 72 61 74 | !isset(self::$transOpStr[$operat |
a01c0 | 6f 72 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 5c 49 | or])).{.............throw.new.\I |
a01e0 | 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 5c 73 70 72 69 6e 74 66 | nvalidArgumentException(\sprintf |
a0200 | 28 27 49 6e 76 61 6c 69 64 20 6f 70 65 72 61 74 6f 72 20 22 25 73 22 20 67 69 76 65 6e 2c 20 65 | ('Invalid.operator."%s".given,.e |
a0220 | 78 70 65 63 74 65 64 20 6f 6e 65 20 6f 66 3a 20 25 73 27 2c 20 24 6f 70 65 72 61 74 6f 72 2c 20 | xpected.one.of:.%s',.$operator,. |
a0240 | 5c 69 6d 70 6c 6f 64 65 28 27 2c 20 27 2c 20 73 65 6c 66 3a 3a 67 65 74 53 75 70 70 6f 72 74 65 | \implode(',.',.self::getSupporte |
a0260 | 64 4f 70 65 72 61 74 6f 72 73 28 29 29 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 | dOperators())));.........}...... |
a0280 | 20 20 20 24 61 49 73 42 72 61 6e 63 68 20 3d 20 27 64 65 76 2d 27 20 3d 3d 3d 20 5c 73 75 62 73 | ...$aIsBranch.=.'dev-'.===.\subs |
a02a0 | 74 72 28 24 61 2c 20 30 2c 20 34 29 3b 0a 20 20 20 20 20 20 20 20 24 62 49 73 42 72 61 6e 63 68 | tr($a,.0,.4);.........$bIsBranch |
a02c0 | 20 3d 20 27 64 65 76 2d 27 20 3d 3d 3d 20 5c 73 75 62 73 74 72 28 24 62 2c 20 30 2c 20 34 29 3b | .=.'dev-'.===.\substr($b,.0,.4); |
a02e0 | 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 6f 70 65 72 61 74 6f 72 20 3d 3d 3d 20 27 21 3d 27 20 | .........if.($operator.===.'!='. |
a0300 | 26 26 20 28 24 61 49 73 42 72 61 6e 63 68 20 7c 7c 20 24 62 49 73 42 72 61 6e 63 68 29 29 20 7b | &&.($aIsBranch.||.$bIsBranch)).{ |
a0320 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 61 20 21 3d 3d 20 24 62 3b 0a 20 | .............return.$a.!==.$b;.. |
a0340 | 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 61 49 73 42 72 61 6e 63 68 20 | .......}.........if.($aIsBranch. |
a0360 | 26 26 20 24 62 49 73 42 72 61 6e 63 68 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 | &&.$bIsBranch).{.............ret |
a0380 | 75 72 6e 20 24 6f 70 65 72 61 74 6f 72 20 3d 3d 3d 20 27 3d 3d 27 20 26 26 20 24 61 20 3d 3d 3d | urn.$operator.===.'=='.&&.$a.=== |
a03a0 | 20 24 62 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 24 63 6f 6d | .$b;.........}.........if.(!$com |
a03c0 | 70 61 72 65 42 72 61 6e 63 68 65 73 20 26 26 20 28 24 61 49 73 42 72 61 6e 63 68 20 7c 7c 20 24 | pareBranches.&&.($aIsBranch.||.$ |
a03e0 | 62 49 73 42 72 61 6e 63 68 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e | bIsBranch)).{.............return |
a0400 | 20 5c 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 | .\false;.........}.........retur |
a0420 | 6e 20 5c 76 65 72 73 69 6f 6e 5f 63 6f 6d 70 61 72 65 28 24 61 2c 20 24 62 2c 20 24 6f 70 65 72 | n.\version_compare($a,.$b,.$oper |
a0440 | 61 74 6f 72 29 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e | ator);.....}.....public.function |
a0460 | 20 63 6f 6d 70 69 6c 65 28 24 6f 74 68 65 72 4f 70 65 72 61 74 6f 72 29 0a 20 20 20 20 7b 0a 20 | .compile($otherOperator).....{.. |
a0480 | 20 20 20 20 20 20 20 69 66 20 28 24 74 68 69 73 2d 3e 76 65 72 73 69 6f 6e 5b 30 5d 20 3d 3d 3d | .......if.($this->version[0].=== |
a04a0 | 20 27 64 27 20 26 26 20 27 64 65 76 2d 27 20 3d 3d 3d 20 5c 73 75 62 73 74 72 28 24 74 68 69 73 | .'d'.&&.'dev-'.===.\substr($this |
a04c0 | 2d 3e 76 65 72 73 69 6f 6e 2c 20 30 2c 20 34 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ->version,.0,.4)).{............. |
a04e0 | 69 66 20 28 73 65 6c 66 3a 3a 4f 50 5f 45 51 20 3d 3d 3d 20 24 74 68 69 73 2d 3e 6f 70 65 72 61 | if.(self::OP_EQ.===.$this->opera |
a0500 | 74 6f 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 73 65 6c 66 3a | tor).{.................if.(self: |
a0520 | 3a 4f 50 5f 45 51 20 3d 3d 3d 20 24 6f 74 68 65 72 4f 70 65 72 61 74 6f 72 29 20 7b 0a 20 20 20 | :OP_EQ.===.$otherOperator).{.... |
a0540 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 5c 73 70 72 69 6e 74 66 | .................return.\sprintf |
a0560 | 28 27 24 62 20 26 26 20 24 76 20 3d 3d 3d 20 25 73 27 2c 20 5c 76 61 72 5f 65 78 70 6f 72 74 28 | ('$b.&&.$v.===.%s',.\var_export( |
a0580 | 24 74 68 69 73 2d 3e 76 65 72 73 69 6f 6e 2c 20 5c 74 72 75 65 29 29 3b 0a 20 20 20 20 20 20 20 | $this->version,.\true));........ |
a05a0 | 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 73 | .........}.................if.(s |
a05c0 | 65 6c 66 3a 3a 4f 50 5f 4e 45 20 3d 3d 3d 20 24 6f 74 68 65 72 4f 70 65 72 61 74 6f 72 29 20 7b | elf::OP_NE.===.$otherOperator).{ |
a05e0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 5c 73 70 72 | .....................return.\spr |
a0600 | 69 6e 74 66 28 27 21 24 62 20 7c 7c 20 24 76 20 21 3d 3d 20 25 73 27 2c 20 5c 76 61 72 5f 65 78 | intf('!$b.||.$v.!==.%s',.\var_ex |
a0620 | 70 6f 72 74 28 24 74 68 69 73 2d 3e 76 65 72 73 69 6f 6e 2c 20 5c 74 72 75 65 29 29 3b 0a 20 20 | port($this->version,.\true));... |
a0640 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ..............}................. |
a0660 | 72 65 74 75 72 6e 20 27 66 61 6c 73 65 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 | return.'false';.............}... |
a0680 | 20 20 20 20 20 20 20 20 20 20 69 66 20 28 73 65 6c 66 3a 3a 4f 50 5f 4e 45 20 3d 3d 3d 20 24 74 | ..........if.(self::OP_NE.===.$t |
a06a0 | 68 69 73 2d 3e 6f 70 65 72 61 74 6f 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | his->operator).{................ |
a06c0 | 20 69 66 20 28 73 65 6c 66 3a 3a 4f 50 5f 45 51 20 3d 3d 3d 20 24 6f 74 68 65 72 4f 70 65 72 61 | .if.(self::OP_EQ.===.$otherOpera |
a06e0 | 74 6f 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 | tor).{.....................retur |
a0700 | 6e 20 5c 73 70 72 69 6e 74 66 28 27 21 24 62 20 7c 7c 20 24 76 20 21 3d 3d 20 25 73 27 2c 20 5c | n.\sprintf('!$b.||.$v.!==.%s',.\ |
a0720 | 76 61 72 5f 65 78 70 6f 72 74 28 24 74 68 69 73 2d 3e 76 65 72 73 69 6f 6e 2c 20 5c 74 72 75 65 | var_export($this->version,.\true |
a0740 | 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 | ));.................}........... |
a0760 | 20 20 20 20 20 20 69 66 20 28 73 65 6c 66 3a 3a 4f 50 5f 4e 45 20 3d 3d 3d 20 24 6f 74 68 65 72 | ......if.(self::OP_NE.===.$other |
a0780 | 4f 70 65 72 61 74 6f 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | Operator).{..................... |
a07a0 | 72 65 74 75 72 6e 20 27 74 72 75 65 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d | return.'true';.................} |
a07c0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 27 21 24 62 27 3b 0a 20 | .................return.'!$b';.. |
a07e0 | 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 | ...........}.............return. |
a0800 | 27 66 61 6c 73 65 27 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 73 | 'false';.........}.........if.(s |
a0820 | 65 6c 66 3a 3a 4f 50 5f 45 51 20 3d 3d 3d 20 24 74 68 69 73 2d 3e 6f 70 65 72 61 74 6f 72 29 20 | elf::OP_EQ.===.$this->operator). |
a0840 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 73 65 6c 66 3a 3a 4f 50 5f 45 51 20 3d 3d | {.............if.(self::OP_EQ.== |
a0860 | 3d 20 24 6f 74 68 65 72 4f 70 65 72 61 74 6f 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | =.$otherOperator).{............. |
a0880 | 20 20 20 20 72 65 74 75 72 6e 20 5c 73 70 72 69 6e 74 66 28 27 5c 5c 76 65 72 73 69 6f 6e 5f 63 | ....return.\sprintf('\\version_c |
a08a0 | 6f 6d 70 61 72 65 28 24 76 2c 20 25 73 2c 20 5c 27 3d 3d 5c 27 29 27 2c 20 5c 76 61 72 5f 65 78 | ompare($v,.%s,.\'==\')',.\var_ex |
a08c0 | 70 6f 72 74 28 24 74 68 69 73 2d 3e 76 65 72 73 69 6f 6e 2c 20 5c 74 72 75 65 29 29 3b 0a 20 20 | port($this->version,.\true));... |
a08e0 | 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 73 65 6c 66 | ..........}.............if.(self |
a0900 | 3a 3a 4f 50 5f 4e 45 20 3d 3d 3d 20 24 6f 74 68 65 72 4f 70 65 72 61 74 6f 72 29 20 7b 0a 20 20 | ::OP_NE.===.$otherOperator).{... |
a0920 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 5c 73 70 72 69 6e 74 66 28 27 24 | ..............return.\sprintf('$ |
a0940 | 62 20 7c 7c 20 5c 5c 76 65 72 73 69 6f 6e 5f 63 6f 6d 70 61 72 65 28 24 76 2c 20 25 73 2c 20 5c | b.||.\\version_compare($v,.%s,.\ |
a0960 | 27 21 3d 5c 27 29 27 2c 20 5c 76 61 72 5f 65 78 70 6f 72 74 28 24 74 68 69 73 2d 3e 76 65 72 73 | '!=\')',.\var_export($this->vers |
a0980 | 69 6f 6e 2c 20 5c 74 72 75 65 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 | ion,.\true));.............}..... |
a09a0 | 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 5c 73 70 72 69 6e 74 66 28 27 21 24 62 20 26 26 20 | ........return.\sprintf('!$b.&&. |
a09c0 | 5c 5c 76 65 72 73 69 6f 6e 5f 63 6f 6d 70 61 72 65 28 25 73 2c 20 24 76 2c 20 5c 27 25 73 5c 27 | \\version_compare(%s,.$v,.\'%s\' |
a09e0 | 29 27 2c 20 5c 76 61 72 5f 65 78 70 6f 72 74 28 24 74 68 69 73 2d 3e 76 65 72 73 69 6f 6e 2c 20 | )',.\var_export($this->version,. |
a0a00 | 5c 74 72 75 65 29 2c 20 73 65 6c 66 3a 3a 24 74 72 61 6e 73 4f 70 49 6e 74 5b 24 6f 74 68 65 72 | \true),.self::$transOpInt[$other |
a0a20 | 4f 70 65 72 61 74 6f 72 5d 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 | Operator]);.........}.........if |
a0a40 | 20 28 73 65 6c 66 3a 3a 4f 50 5f 4e 45 20 3d 3d 3d 20 24 74 68 69 73 2d 3e 6f 70 65 72 61 74 6f | .(self::OP_NE.===.$this->operato |
a0a60 | 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 73 65 6c 66 3a 3a 4f 50 5f 45 51 | r).{.............if.(self::OP_EQ |
a0a80 | 20 3d 3d 3d 20 24 6f 74 68 65 72 4f 70 65 72 61 74 6f 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | .===.$otherOperator).{.......... |
a0aa0 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 5c 73 70 72 69 6e 74 66 28 27 24 62 20 7c 7c 20 28 21 | .......return.\sprintf('$b.||.(! |
a0ac0 | 24 62 20 26 26 20 5c 5c 76 65 72 73 69 6f 6e 5f 63 6f 6d 70 61 72 65 28 24 76 2c 20 25 73 2c 20 | $b.&&.\\version_compare($v,.%s,. |
a0ae0 | 5c 27 21 3d 5c 27 29 29 27 2c 20 5c 76 61 72 5f 65 78 70 6f 72 74 28 24 74 68 69 73 2d 3e 76 65 | \'!=\'))',.\var_export($this->ve |
a0b00 | 72 73 69 6f 6e 2c 20 5c 74 72 75 65 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 | rsion,.\true));.............}... |
a0b20 | 20 20 20 20 20 20 20 20 20 20 69 66 20 28 73 65 6c 66 3a 3a 4f 50 5f 4e 45 20 3d 3d 3d 20 24 6f | ..........if.(self::OP_NE.===.$o |
a0b40 | 74 68 65 72 4f 70 65 72 61 74 6f 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | therOperator).{................. |
a0b60 | 72 65 74 75 72 6e 20 27 74 72 75 65 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 | return.'true';.............}.... |
a0b80 | 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 27 21 24 62 27 3b 0a 20 20 20 20 20 20 20 20 7d | .........return.'!$b';.........} |
a0ba0 | 0a 20 20 20 20 20 20 20 20 69 66 20 28 73 65 6c 66 3a 3a 4f 50 5f 4c 54 20 3d 3d 3d 20 24 74 68 | .........if.(self::OP_LT.===.$th |
a0bc0 | 69 73 2d 3e 6f 70 65 72 61 74 6f 72 20 7c 7c 20 73 65 6c 66 3a 3a 4f 50 5f 4c 45 20 3d 3d 3d 20 | is->operator.||.self::OP_LE.===. |
a0be0 | 24 74 68 69 73 2d 3e 6f 70 65 72 61 74 6f 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 | $this->operator).{.............i |
a0c00 | 66 20 28 73 65 6c 66 3a 3a 4f 50 5f 4c 54 20 3d 3d 3d 20 24 6f 74 68 65 72 4f 70 65 72 61 74 6f | f.(self::OP_LT.===.$otherOperato |
a0c20 | 72 20 7c 7c 20 73 65 6c 66 3a 3a 4f 50 5f 4c 45 20 3d 3d 3d 20 24 6f 74 68 65 72 4f 70 65 72 61 | r.||.self::OP_LE.===.$otherOpera |
a0c40 | 74 6f 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 27 21 | tor).{.................return.'! |
a0c60 | 24 62 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 | $b';.............}.........}.els |
a0c80 | 65 69 66 20 28 73 65 6c 66 3a 3a 4f 50 5f 47 54 20 3d 3d 3d 20 24 74 68 69 73 2d 3e 6f 70 65 72 | eif.(self::OP_GT.===.$this->oper |
a0ca0 | 61 74 6f 72 20 7c 7c 20 73 65 6c 66 3a 3a 4f 50 5f 47 45 20 3d 3d 3d 20 24 74 68 69 73 2d 3e 6f | ator.||.self::OP_GE.===.$this->o |
a0cc0 | 70 65 72 61 74 6f 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 73 65 6c 66 3a | perator).{.............if.(self: |
a0ce0 | 3a 4f 50 5f 47 54 20 3d 3d 3d 20 24 6f 74 68 65 72 4f 70 65 72 61 74 6f 72 20 7c 7c 20 73 65 6c | :OP_GT.===.$otherOperator.||.sel |
a0d00 | 66 3a 3a 4f 50 5f 47 45 20 3d 3d 3d 20 24 6f 74 68 65 72 4f 70 65 72 61 74 6f 72 29 20 7b 0a 20 | f::OP_GE.===.$otherOperator).{.. |
a0d20 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 27 21 24 62 27 3b 0a 20 20 20 | ...............return.'!$b';.... |
a0d40 | 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 | .........}.........}.........if. |
a0d60 | 28 73 65 6c 66 3a 3a 4f 50 5f 4e 45 20 3d 3d 3d 20 24 6f 74 68 65 72 4f 70 65 72 61 74 6f 72 29 | (self::OP_NE.===.$otherOperator) |
a0d80 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 27 74 72 75 65 27 3b 0a 20 20 | .{.............return.'true';... |
a0da0 | 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 24 63 6f 64 65 43 6f 6d 70 61 72 69 73 6f 6e 20 | ......}.........$codeComparison. |
a0dc0 | 3d 20 5c 73 70 72 69 6e 74 66 28 27 5c 5c 76 65 72 73 69 6f 6e 5f 63 6f 6d 70 61 72 65 28 24 76 | =.\sprintf('\\version_compare($v |
a0de0 | 2c 20 25 73 2c 20 5c 27 25 73 5c 27 29 27 2c 20 5c 76 61 72 5f 65 78 70 6f 72 74 28 24 74 68 69 | ,.%s,.\'%s\')',.\var_export($thi |
a0e00 | 73 2d 3e 76 65 72 73 69 6f 6e 2c 20 5c 74 72 75 65 29 2c 20 73 65 6c 66 3a 3a 24 74 72 61 6e 73 | s->version,.\true),.self::$trans |
a0e20 | 4f 70 49 6e 74 5b 24 74 68 69 73 2d 3e 6f 70 65 72 61 74 6f 72 5d 29 3b 0a 20 20 20 20 20 20 20 | OpInt[$this->operator]);........ |
a0e40 | 20 69 66 20 28 24 74 68 69 73 2d 3e 6f 70 65 72 61 74 6f 72 20 3d 3d 3d 20 73 65 6c 66 3a 3a 4f | .if.($this->operator.===.self::O |
a0e60 | 50 5f 4c 45 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 6f 74 68 65 72 4f 70 | P_LE).{.............if.($otherOp |
a0e80 | 65 72 61 74 6f 72 20 3d 3d 3d 20 73 65 6c 66 3a 3a 4f 50 5f 47 54 29 20 7b 0a 20 20 20 20 20 20 | erator.===.self::OP_GT).{....... |
a0ea0 | 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 5c 73 70 72 69 6e 74 66 28 27 21 24 62 20 26 | ..........return.\sprintf('!$b.& |
a0ec0 | 26 20 5c 5c 76 65 72 73 69 6f 6e 5f 63 6f 6d 70 61 72 65 28 24 76 2c 20 25 73 2c 20 5c 27 21 3d | &.\\version_compare($v,.%s,.\'!= |
a0ee0 | 5c 27 29 20 26 26 20 27 2c 20 5c 76 61 72 5f 65 78 70 6f 72 74 28 24 74 68 69 73 2d 3e 76 65 72 | \').&&.',.\var_export($this->ver |
a0f00 | 73 69 6f 6e 2c 20 5c 74 72 75 65 29 29 20 2e 20 24 63 6f 64 65 43 6f 6d 70 61 72 69 73 6f 6e 3b | sion,.\true))...$codeComparison; |
a0f20 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 | .............}.........}.elseif. |
a0f40 | 28 24 74 68 69 73 2d 3e 6f 70 65 72 61 74 6f 72 20 3d 3d 3d 20 73 65 6c 66 3a 3a 4f 50 5f 47 45 | ($this->operator.===.self::OP_GE |
a0f60 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 6f 74 68 65 72 4f 70 65 72 61 74 | ).{.............if.($otherOperat |
a0f80 | 6f 72 20 3d 3d 3d 20 73 65 6c 66 3a 3a 4f 50 5f 4c 54 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | or.===.self::OP_LT).{........... |
a0fa0 | 20 20 20 20 20 20 72 65 74 75 72 6e 20 5c 73 70 72 69 6e 74 66 28 27 21 24 62 20 26 26 20 5c 5c | ......return.\sprintf('!$b.&&.\\ |
a0fc0 | 76 65 72 73 69 6f 6e 5f 63 6f 6d 70 61 72 65 28 24 76 2c 20 25 73 2c 20 5c 27 21 3d 5c 27 29 20 | version_compare($v,.%s,.\'!=\'). |
a0fe0 | 26 26 20 27 2c 20 5c 76 61 72 5f 65 78 70 6f 72 74 28 24 74 68 69 73 2d 3e 76 65 72 73 69 6f 6e | &&.',.\var_export($this->version |
a1000 | 2c 20 5c 74 72 75 65 29 29 20 2e 20 24 63 6f 64 65 43 6f 6d 70 61 72 69 73 6f 6e 3b 0a 20 20 20 | ,.\true))...$codeComparison;.... |
a1020 | 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 72 65 74 | .........}.........}.........ret |
a1040 | 75 72 6e 20 5c 73 70 72 69 6e 74 66 28 27 21 24 62 20 26 26 20 25 73 27 2c 20 24 63 6f 64 65 43 | urn.\sprintf('!$b.&&.%s',.$codeC |
a1060 | 6f 6d 70 61 72 69 73 6f 6e 29 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e | omparison);.....}.....public.fun |
a1080 | 63 74 69 6f 6e 20 6d 61 74 63 68 53 70 65 63 69 66 69 63 28 5c 48 75 6d 62 75 67 42 6f 78 33 31 | ction.matchSpecific(\HumbugBox31 |
a10a0 | 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f | 11\Composer\Semver\Constraint\Co |
a10c0 | 6e 73 74 72 61 69 6e 74 20 24 70 72 6f 76 69 64 65 72 2c 20 24 63 6f 6d 70 61 72 65 42 72 61 6e | nstraint.$provider,.$compareBran |
a10e0 | 63 68 65 73 20 3d 20 5c 66 61 6c 73 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 6e 6f | ches.=.\false).....{.........$no |
a1100 | 45 71 75 61 6c 4f 70 20 3d 20 5c 73 74 72 5f 72 65 70 6c 61 63 65 28 27 3d 27 2c 20 27 27 2c 20 | EqualOp.=.\str_replace('=',.'',. |
a1120 | 73 65 6c 66 3a 3a 24 74 72 61 6e 73 4f 70 49 6e 74 5b 24 74 68 69 73 2d 3e 6f 70 65 72 61 74 6f | self::$transOpInt[$this->operato |
a1140 | 72 5d 29 3b 0a 20 20 20 20 20 20 20 20 24 70 72 6f 76 69 64 65 72 4e 6f 45 71 75 61 6c 4f 70 20 | r]);.........$providerNoEqualOp. |
a1160 | 3d 20 5c 73 74 72 5f 72 65 70 6c 61 63 65 28 27 3d 27 2c 20 27 27 2c 20 73 65 6c 66 3a 3a 24 74 | =.\str_replace('=',.'',.self::$t |
a1180 | 72 61 6e 73 4f 70 49 6e 74 5b 24 70 72 6f 76 69 64 65 72 2d 3e 6f 70 65 72 61 74 6f 72 5d 29 3b | ransOpInt[$provider->operator]); |
a11a0 | 0a 20 20 20 20 20 20 20 20 24 69 73 45 71 75 61 6c 4f 70 20 3d 20 73 65 6c 66 3a 3a 4f 50 5f 45 | .........$isEqualOp.=.self::OP_E |
a11c0 | 51 20 3d 3d 3d 20 24 74 68 69 73 2d 3e 6f 70 65 72 61 74 6f 72 3b 0a 20 20 20 20 20 20 20 20 24 | Q.===.$this->operator;.........$ |
a11e0 | 69 73 4e 6f 6e 45 71 75 61 6c 4f 70 20 3d 20 73 65 6c 66 3a 3a 4f 50 5f 4e 45 20 3d 3d 3d 20 24 | isNonEqualOp.=.self::OP_NE.===.$ |
a1200 | 74 68 69 73 2d 3e 6f 70 65 72 61 74 6f 72 3b 0a 20 20 20 20 20 20 20 20 24 69 73 50 72 6f 76 69 | this->operator;.........$isProvi |
a1220 | 64 65 72 45 71 75 61 6c 4f 70 20 3d 20 73 65 6c 66 3a 3a 4f 50 5f 45 51 20 3d 3d 3d 20 24 70 72 | derEqualOp.=.self::OP_EQ.===.$pr |
a1240 | 6f 76 69 64 65 72 2d 3e 6f 70 65 72 61 74 6f 72 3b 0a 20 20 20 20 20 20 20 20 24 69 73 50 72 6f | ovider->operator;.........$isPro |
a1260 | 76 69 64 65 72 4e 6f 6e 45 71 75 61 6c 4f 70 20 3d 20 73 65 6c 66 3a 3a 4f 50 5f 4e 45 20 3d 3d | viderNonEqualOp.=.self::OP_NE.== |
a1280 | 3d 20 24 70 72 6f 76 69 64 65 72 2d 3e 6f 70 65 72 61 74 6f 72 3b 0a 20 20 20 20 20 20 20 20 69 | =.$provider->operator;.........i |
a12a0 | 66 20 28 24 69 73 4e 6f 6e 45 71 75 61 6c 4f 70 20 7c 7c 20 24 69 73 50 72 6f 76 69 64 65 72 4e | f.($isNonEqualOp.||.$isProviderN |
a12c0 | 6f 6e 45 71 75 61 6c 4f 70 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 69 73 | onEqualOp).{.............if.($is |
a12e0 | 4e 6f 6e 45 71 75 61 6c 4f 70 20 26 26 20 21 24 69 73 50 72 6f 76 69 64 65 72 4e 6f 6e 45 71 75 | NonEqualOp.&&.!$isProviderNonEqu |
a1300 | 61 6c 4f 70 20 26 26 20 21 24 69 73 50 72 6f 76 69 64 65 72 45 71 75 61 6c 4f 70 20 26 26 20 27 | alOp.&&.!$isProviderEqualOp.&&.' |
a1320 | 64 65 76 2d 27 20 3d 3d 3d 20 5c 73 75 62 73 74 72 28 24 70 72 6f 76 69 64 65 72 2d 3e 76 65 72 | dev-'.===.\substr($provider->ver |
a1340 | 73 69 6f 6e 2c 20 30 2c 20 34 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 | sion,.0,.4)).{.................r |
a1360 | 65 74 75 72 6e 20 5c 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 | eturn.\false;.............}..... |
a1380 | 20 20 20 20 20 20 20 20 69 66 20 28 24 69 73 50 72 6f 76 69 64 65 72 4e 6f 6e 45 71 75 61 6c 4f | ........if.($isProviderNonEqualO |
a13a0 | 70 20 26 26 20 21 24 69 73 4e 6f 6e 45 71 75 61 6c 4f 70 20 26 26 20 21 24 69 73 45 71 75 61 6c | p.&&.!$isNonEqualOp.&&.!$isEqual |
a13c0 | 4f 70 20 26 26 20 27 64 65 76 2d 27 20 3d 3d 3d 20 5c 73 75 62 73 74 72 28 24 74 68 69 73 2d 3e | Op.&&.'dev-'.===.\substr($this-> |
a13e0 | 76 65 72 73 69 6f 6e 2c 20 30 2c 20 34 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | version,.0,.4)).{............... |
a1400 | 20 20 72 65 74 75 72 6e 20 5c 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 | ..return.\false;.............}.. |
a1420 | 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 21 24 69 73 45 71 75 61 6c 4f 70 20 26 26 20 21 24 | ...........if.(!$isEqualOp.&&.!$ |
a1440 | 69 73 50 72 6f 76 69 64 65 72 45 71 75 61 6c 4f 70 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | isProviderEqualOp).{............ |
a1460 | 20 20 20 20 20 72 65 74 75 72 6e 20 5c 74 72 75 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d | .....return.\true;.............} |
a1480 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 76 65 72 73 69 | .............return.$this->versi |
a14a0 | 6f 6e 43 6f 6d 70 61 72 65 28 24 70 72 6f 76 69 64 65 72 2d 3e 76 65 72 73 69 6f 6e 2c 20 24 74 | onCompare($provider->version,.$t |
a14c0 | 68 69 73 2d 3e 76 65 72 73 69 6f 6e 2c 20 27 21 3d 27 2c 20 24 63 6f 6d 70 61 72 65 42 72 61 6e | his->version,.'!=',.$compareBran |
a14e0 | 63 68 65 73 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 74 68 | ches);.........}.........if.($th |
a1500 | 69 73 2d 3e 6f 70 65 72 61 74 6f 72 20 21 3d 3d 20 73 65 6c 66 3a 3a 4f 50 5f 45 51 20 26 26 20 | is->operator.!==.self::OP_EQ.&&. |
a1520 | 24 6e 6f 45 71 75 61 6c 4f 70 20 3d 3d 3d 20 24 70 72 6f 76 69 64 65 72 4e 6f 45 71 75 61 6c 4f | $noEqualOp.===.$providerNoEqualO |
a1540 | 70 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 27 64 65 76 2d 27 20 3d 3d 3d 20 | p).{.............if.('dev-'.===. |
a1560 | 5c 73 75 62 73 74 72 28 24 74 68 69 73 2d 3e 76 65 72 73 69 6f 6e 2c 20 30 2c 20 34 29 20 7c 7c | \substr($this->version,.0,.4).|| |
a1580 | 20 27 64 65 76 2d 27 20 3d 3d 3d 20 5c 73 75 62 73 74 72 28 24 70 72 6f 76 69 64 65 72 2d 3e 76 | .'dev-'.===.\substr($provider->v |
a15a0 | 65 72 73 69 6f 6e 2c 20 30 2c 20 34 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ersion,.0,.4)).{................ |
a15c0 | 20 72 65 74 75 72 6e 20 5c 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 | .return.\false;.............}... |
a15e0 | 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 5c 74 72 75 65 3b 0a 20 20 20 20 20 20 20 20 | ..........return.\true;......... |
a1600 | 7d 0a 20 20 20 20 20 20 20 20 24 76 65 72 73 69 6f 6e 31 20 3d 20 24 69 73 45 71 75 61 6c 4f 70 | }.........$version1.=.$isEqualOp |
a1620 | 20 3f 20 24 74 68 69 73 2d 3e 76 65 72 73 69 6f 6e 20 3a 20 24 70 72 6f 76 69 64 65 72 2d 3e 76 | .?.$this->version.:.$provider->v |
a1640 | 65 72 73 69 6f 6e 3b 0a 20 20 20 20 20 20 20 20 24 76 65 72 73 69 6f 6e 32 20 3d 20 24 69 73 45 | ersion;.........$version2.=.$isE |
a1660 | 71 75 61 6c 4f 70 20 3f 20 24 70 72 6f 76 69 64 65 72 2d 3e 76 65 72 73 69 6f 6e 20 3a 20 24 74 | qualOp.?.$provider->version.:.$t |
a1680 | 68 69 73 2d 3e 76 65 72 73 69 6f 6e 3b 0a 20 20 20 20 20 20 20 20 24 6f 70 65 72 61 74 6f 72 20 | his->version;.........$operator. |
a16a0 | 3d 20 24 69 73 45 71 75 61 6c 4f 70 20 3f 20 24 70 72 6f 76 69 64 65 72 2d 3e 6f 70 65 72 61 74 | =.$isEqualOp.?.$provider->operat |
a16c0 | 6f 72 20 3a 20 24 74 68 69 73 2d 3e 6f 70 65 72 61 74 6f 72 3b 0a 20 20 20 20 20 20 20 20 69 66 | or.:.$this->operator;.........if |
a16e0 | 20 28 24 74 68 69 73 2d 3e 76 65 72 73 69 6f 6e 43 6f 6d 70 61 72 65 28 24 76 65 72 73 69 6f 6e | .($this->versionCompare($version |
a1700 | 31 2c 20 24 76 65 72 73 69 6f 6e 32 2c 20 73 65 6c 66 3a 3a 24 74 72 61 6e 73 4f 70 49 6e 74 5b | 1,.$version2,.self::$transOpInt[ |
a1720 | 24 6f 70 65 72 61 74 6f 72 5d 2c 20 24 63 6f 6d 70 61 72 65 42 72 61 6e 63 68 65 73 29 29 20 7b | $operator],.$compareBranches)).{ |
a1740 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 21 28 73 65 6c 66 3a 3a 24 74 72 61 | .............return.!(self::$tra |
a1760 | 6e 73 4f 70 49 6e 74 5b 24 70 72 6f 76 69 64 65 72 2d 3e 6f 70 65 72 61 74 6f 72 5d 20 3d 3d 3d | nsOpInt[$provider->operator].=== |
a1780 | 20 24 70 72 6f 76 69 64 65 72 4e 6f 45 71 75 61 6c 4f 70 20 26 26 20 73 65 6c 66 3a 3a 24 74 72 | .$providerNoEqualOp.&&.self::$tr |
a17a0 | 61 6e 73 4f 70 49 6e 74 5b 24 74 68 69 73 2d 3e 6f 70 65 72 61 74 6f 72 5d 20 21 3d 3d 20 24 6e | ansOpInt[$this->operator].!==.$n |
a17c0 | 6f 45 71 75 61 6c 4f 70 20 26 26 20 5c 76 65 72 73 69 6f 6e 5f 63 6f 6d 70 61 72 65 28 24 70 72 | oEqualOp.&&.\version_compare($pr |
a17e0 | 6f 76 69 64 65 72 2d 3e 76 65 72 73 69 6f 6e 2c 20 24 74 68 69 73 2d 3e 76 65 72 73 69 6f 6e 2c | ovider->version,.$this->version, |
a1800 | 20 27 3d 3d 27 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 | .'=='));.........}.........retur |
a1820 | 6e 20 5c 66 61 6c 73 65 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 | n.\false;.....}.....public.funct |
a1840 | 69 6f 6e 20 5f 5f 74 6f 53 74 72 69 6e 67 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 | ion.__toString().....{.........r |
a1860 | 65 74 75 72 6e 20 73 65 6c 66 3a 3a 24 74 72 61 6e 73 4f 70 49 6e 74 5b 24 74 68 69 73 2d 3e 6f | eturn.self::$transOpInt[$this->o |
a1880 | 70 65 72 61 74 6f 72 5d 20 2e 20 27 20 27 20 2e 20 24 74 68 69 73 2d 3e 76 65 72 73 69 6f 6e 3b | perator]...'.'...$this->version; |
a18a0 | 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 4c 6f | .....}.....public.function.getLo |
a18c0 | 77 65 72 42 6f 75 6e 64 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e | werBound().....{.........$this-> |
a18e0 | 65 78 74 72 61 63 74 42 6f 75 6e 64 73 28 29 3b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 | extractBounds();.........return. |
a1900 | 24 74 68 69 73 2d 3e 6c 6f 77 65 72 42 6f 75 6e 64 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 | $this->lowerBound;.....}.....pub |
a1920 | 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 55 70 70 65 72 42 6f 75 6e 64 28 29 0a 20 20 20 | lic.function.getUpperBound().... |
a1940 | 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 65 78 74 72 61 63 74 42 6f 75 6e 64 73 28 | .{.........$this->extractBounds( |
a1960 | 29 3b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 75 70 70 65 72 42 6f | );.........return.$this->upperBo |
a1980 | 75 6e 64 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 | und;.....}.....private.function. |
a19a0 | 65 78 74 72 61 63 74 42 6f 75 6e 64 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 | extractBounds().....{.........if |
a19c0 | 20 28 6e 75 6c 6c 20 21 3d 3d 20 24 74 68 69 73 2d 3e 6c 6f 77 65 72 42 6f 75 6e 64 29 20 7b 0a | .(null.!==.$this->lowerBound).{. |
a19e0 | 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 | ............return;.........}... |
a1a00 | 20 20 20 20 20 20 69 66 20 28 5c 73 74 72 70 6f 73 28 24 74 68 69 73 2d 3e 76 65 72 73 69 6f 6e | ......if.(\strpos($this->version |
a1a20 | 2c 20 27 64 65 76 2d 27 29 20 3d 3d 3d 20 30 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 | ,.'dev-').===.0).{.............$ |
a1a40 | 74 68 69 73 2d 3e 6c 6f 77 65 72 42 6f 75 6e 64 20 3d 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 | this->lowerBound.=.\HumbugBox311 |
a1a60 | 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 42 6f 75 | 1\Composer\Semver\Constraint\Bou |
a1a80 | 6e 64 3a 3a 7a 65 72 6f 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 75 | nd::zero();.............$this->u |
a1aa0 | 70 70 65 72 42 6f 75 6e 64 20 3d 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f | pperBound.=.\HumbugBox3111\Compo |
a1ac0 | 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 42 6f 75 6e 64 3a 3a 70 6f 73 | ser\Semver\Constraint\Bound::pos |
a1ae0 | 69 74 69 76 65 49 6e 66 69 6e 69 74 79 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 | itiveInfinity();.............ret |
a1b00 | 75 72 6e 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 73 77 69 74 63 68 20 28 24 | urn;.........}.........switch.($ |
a1b20 | 74 68 69 73 2d 3e 6f 70 65 72 61 74 6f 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 63 61 | this->operator).{.............ca |
a1b40 | 73 65 20 73 65 6c 66 3a 3a 4f 50 5f 45 51 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | se.self::OP_EQ:................. |
a1b60 | 24 74 68 69 73 2d 3e 6c 6f 77 65 72 42 6f 75 6e 64 20 3d 20 6e 65 77 20 5c 48 75 6d 62 75 67 42 | $this->lowerBound.=.new.\HumbugB |
a1b80 | 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e | ox3111\Composer\Semver\Constrain |
a1ba0 | 74 5c 42 6f 75 6e 64 28 24 74 68 69 73 2d 3e 76 65 72 73 69 6f 6e 2c 20 5c 74 72 75 65 29 3b 0a | t\Bound($this->version,.\true);. |
a1bc0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 75 70 70 65 72 42 6f 75 6e | ................$this->upperBoun |
a1be0 | 64 20 3d 20 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c | d.=.new.\HumbugBox3111\Composer\ |
a1c00 | 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 42 6f 75 6e 64 28 24 74 68 69 73 2d 3e 76 | Semver\Constraint\Bound($this->v |
a1c20 | 65 72 73 69 6f 6e 2c 20 5c 74 72 75 65 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ersion,.\true);................. |
a1c40 | 62 72 65 61 6b 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 63 61 73 65 20 73 65 6c 66 3a 3a 4f 50 | break;.............case.self::OP |
a1c60 | 5f 4c 54 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6c 6f 77 65 | _LT:.................$this->lowe |
a1c80 | 72 42 6f 75 6e 64 20 3d 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 | rBound.=.\HumbugBox3111\Composer |
a1ca0 | 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 42 6f 75 6e 64 3a 3a 7a 65 72 6f 28 29 | \Semver\Constraint\Bound::zero() |
a1cc0 | 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 75 70 70 65 72 42 6f | ;.................$this->upperBo |
a1ce0 | 75 6e 64 20 3d 20 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 | und.=.new.\HumbugBox3111\Compose |
a1d00 | 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 42 6f 75 6e 64 28 24 74 68 69 73 2d | r\Semver\Constraint\Bound($this- |
a1d20 | 3e 76 65 72 73 69 6f 6e 2c 20 5c 66 61 6c 73 65 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | >version,.\false);.............. |
a1d40 | 20 20 20 62 72 65 61 6b 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 63 61 73 65 20 73 65 6c 66 3a | ...break;.............case.self: |
a1d60 | 3a 4f 50 5f 4c 45 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6c | :OP_LE:.................$this->l |
a1d80 | 6f 77 65 72 42 6f 75 6e 64 20 3d 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f | owerBound.=.\HumbugBox3111\Compo |
a1da0 | 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 42 6f 75 6e 64 3a 3a 7a 65 72 | ser\Semver\Constraint\Bound::zer |
a1dc0 | 6f 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 75 70 70 65 | o();.................$this->uppe |
a1de0 | 72 42 6f 75 6e 64 20 3d 20 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 | rBound.=.new.\HumbugBox3111\Comp |
a1e00 | 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 42 6f 75 6e 64 28 24 74 68 | oser\Semver\Constraint\Bound($th |
a1e20 | 69 73 2d 3e 76 65 72 73 69 6f 6e 2c 20 5c 74 72 75 65 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 | is->version,.\true);............ |
a1e40 | 20 20 20 20 20 62 72 65 61 6b 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 63 61 73 65 20 73 65 6c | .....break;.............case.sel |
a1e60 | 66 3a 3a 4f 50 5f 47 54 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d | f::OP_GT:.................$this- |
a1e80 | 3e 6c 6f 77 65 72 42 6f 75 6e 64 20 3d 20 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 | >lowerBound.=.new.\HumbugBox3111 |
a1ea0 | 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 42 6f 75 6e | \Composer\Semver\Constraint\Boun |
a1ec0 | 64 28 24 74 68 69 73 2d 3e 76 65 72 73 69 6f 6e 2c 20 5c 66 61 6c 73 65 29 3b 0a 20 20 20 20 20 | d($this->version,.\false);...... |
a1ee0 | 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 75 70 70 65 72 42 6f 75 6e 64 20 3d 20 5c | ...........$this->upperBound.=.\ |
a1f00 | 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f | HumbugBox3111\Composer\Semver\Co |
a1f20 | 6e 73 74 72 61 69 6e 74 5c 42 6f 75 6e 64 3a 3a 70 6f 73 69 74 69 76 65 49 6e 66 69 6e 69 74 79 | nstraint\Bound::positiveInfinity |
a1f40 | 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 62 72 65 61 6b 3b 0a 20 20 20 20 20 | ();.................break;...... |
a1f60 | 20 20 20 20 20 20 20 63 61 73 65 20 73 65 6c 66 3a 3a 4f 50 5f 47 45 3a 0a 20 20 20 20 20 20 20 | .......case.self::OP_GE:........ |
a1f80 | 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6c 6f 77 65 72 42 6f 75 6e 64 20 3d 20 6e 65 77 | .........$this->lowerBound.=.new |
a1fa0 | 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c | .\HumbugBox3111\Composer\Semver\ |
a1fc0 | 43 6f 6e 73 74 72 61 69 6e 74 5c 42 6f 75 6e 64 28 24 74 68 69 73 2d 3e 76 65 72 73 69 6f 6e 2c | Constraint\Bound($this->version, |
a1fe0 | 20 5c 74 72 75 65 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e | .\true);.................$this-> |
a2000 | 75 70 70 65 72 42 6f 75 6e 64 20 3d 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 | upperBound.=.\HumbugBox3111\Comp |
a2020 | 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 42 6f 75 6e 64 3a 3a 70 6f | oser\Semver\Constraint\Bound::po |
a2040 | 73 69 74 69 76 65 49 6e 66 69 6e 69 74 79 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | sitiveInfinity();............... |
a2060 | 20 20 62 72 65 61 6b 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 63 61 73 65 20 73 65 6c 66 3a 3a | ..break;.............case.self:: |
a2080 | 4f 50 5f 4e 45 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 6c 6f | OP_NE:.................$this->lo |
a20a0 | 77 65 72 42 6f 75 6e 64 20 3d 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 | werBound.=.\HumbugBox3111\Compos |
a20c0 | 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 42 6f 75 6e 64 3a 3a 7a 65 72 6f | er\Semver\Constraint\Bound::zero |
a20e0 | 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 75 70 70 65 72 | ();.................$this->upper |
a2100 | 42 6f 75 6e 64 20 3d 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c | Bound.=.\HumbugBox3111\Composer\ |
a2120 | 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 42 6f 75 6e 64 3a 3a 70 6f 73 69 74 69 76 | Semver\Constraint\Bound::positiv |
a2140 | 65 49 6e 66 69 6e 69 74 79 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 62 72 65 | eInfinity();.................bre |
a2160 | 61 6b 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 6e 61 6d | ak;.........}.....}.}.<?php..nam |
a2180 | 65 73 70 61 63 65 20 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 | espace.HumbugBox3111\Composer\Se |
a21a0 | 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 3b 0a 0a 63 6c 61 73 73 20 42 6f 75 6e 64 0a 7b 0a | mver\Constraint;..class.Bound.{. |
a21c0 | 20 20 20 20 70 72 69 76 61 74 65 20 24 76 65 72 73 69 6f 6e 3b 0a 20 20 20 20 70 72 69 76 61 74 | ....private.$version;.....privat |
a21e0 | 65 20 24 69 73 49 6e 63 6c 75 73 69 76 65 3b 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 | e.$isInclusive;.....public.funct |
a2200 | 69 6f 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 74 28 24 76 65 72 73 69 6f 6e 2c 20 24 69 73 49 6e 63 | ion.__construct($version,.$isInc |
a2220 | 6c 75 73 69 76 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 76 65 72 | lusive).....{.........$this->ver |
a2240 | 73 69 6f 6e 20 3d 20 24 76 65 72 73 69 6f 6e 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e | sion.=.$version;.........$this-> |
a2260 | 69 73 49 6e 63 6c 75 73 69 76 65 20 3d 20 24 69 73 49 6e 63 6c 75 73 69 76 65 3b 0a 20 20 20 20 | isInclusive.=.$isInclusive;..... |
a2280 | 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 56 65 72 73 69 6f 6e | }.....public.function.getVersion |
a22a0 | 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 76 | ().....{.........return.$this->v |
a22c0 | 65 72 73 69 6f 6e 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f | ersion;.....}.....public.functio |
a22e0 | 6e 20 69 73 49 6e 63 6c 75 73 69 76 65 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 | n.isInclusive().....{.........re |
a2300 | 74 75 72 6e 20 24 74 68 69 73 2d 3e 69 73 49 6e 63 6c 75 73 69 76 65 3b 0a 20 20 20 20 7d 0a 20 | turn.$this->isInclusive;.....}.. |
a2320 | 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 69 73 5a 65 72 6f 28 29 0a 20 20 20 20 | ...public.function.isZero()..... |
a2340 | 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 67 65 74 56 65 72 73 69 | {.........return.$this->getVersi |
a2360 | 6f 6e 28 29 20 3d 3d 3d 20 27 30 2e 30 2e 30 2e 30 2d 64 65 76 27 20 26 26 20 24 74 68 69 73 2d | on().===.'0.0.0.0-dev'.&&.$this- |
a2380 | 3e 69 73 49 6e 63 6c 75 73 69 76 65 28 29 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 | >isInclusive();.....}.....public |
a23a0 | 20 66 75 6e 63 74 69 6f 6e 20 69 73 50 6f 73 69 74 69 76 65 49 6e 66 69 6e 69 74 79 28 29 0a 20 | .function.isPositiveInfinity().. |
a23c0 | 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 67 65 74 56 65 | ...{.........return.$this->getVe |
a23e0 | 72 73 69 6f 6e 28 29 20 3d 3d 3d 20 5c 50 48 50 5f 49 4e 54 5f 4d 41 58 20 2e 20 27 2e 30 2e 30 | rsion().===.\PHP_INT_MAX...'.0.0 |
a2400 | 2e 30 27 20 26 26 20 21 24 74 68 69 73 2d 3e 69 73 49 6e 63 6c 75 73 69 76 65 28 29 3b 0a 20 20 | .0'.&&.!$this->isInclusive();... |
a2420 | 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 63 6f 6d 70 61 72 65 54 | ..}.....public.function.compareT |
a2440 | 6f 28 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 | o(\HumbugBox3111\Composer\Semver |
a2460 | 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 42 6f 75 6e 64 20 24 6f 74 68 65 72 2c 20 24 6f 70 65 72 61 | \Constraint\Bound.$other,.$opera |
a2480 | 74 6f 72 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 5c 69 6e 5f 61 72 72 61 | tor).....{.........if.(!\in_arra |
a24a0 | 79 28 24 6f 70 65 72 61 74 6f 72 2c 20 61 72 72 61 79 28 27 3c 27 2c 20 27 3e 27 29 2c 20 5c 74 | y($operator,.array('<',.'>'),.\t |
a24c0 | 72 75 65 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 5c 49 | rue)).{.............throw.new.\I |
a24e0 | 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 27 44 6f 65 73 20 6e 6f | nvalidArgumentException('Does.no |
a2500 | 74 20 73 75 70 70 6f 72 74 20 61 6e 79 20 6f 74 68 65 72 20 6f 70 65 72 61 74 6f 72 20 6f 74 68 | t.support.any.other.operator.oth |
a2520 | 65 72 20 74 68 61 6e 20 3e 20 6f 72 20 3c 2e 27 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 | er.than.>.or.<.');.........}.... |
a2540 | 20 20 20 20 20 69 66 20 28 24 74 68 69 73 20 3d 3d 20 24 6f 74 68 65 72 29 20 7b 0a 20 20 20 20 | .....if.($this.==.$other).{..... |
a2560 | 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 5c 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 7d | ........return.\false;.........} |
a2580 | 0a 20 20 20 20 20 20 20 20 24 63 6f 6d 70 61 72 65 52 65 73 75 6c 74 20 3d 20 5c 76 65 72 73 69 | .........$compareResult.=.\versi |
a25a0 | 6f 6e 5f 63 6f 6d 70 61 72 65 28 24 74 68 69 73 2d 3e 67 65 74 56 65 72 73 69 6f 6e 28 29 2c 20 | on_compare($this->getVersion(),. |
a25c0 | 24 6f 74 68 65 72 2d 3e 67 65 74 56 65 72 73 69 6f 6e 28 29 29 3b 0a 20 20 20 20 20 20 20 20 69 | $other->getVersion());.........i |
a25e0 | 66 20 28 30 20 21 3d 3d 20 24 63 6f 6d 70 61 72 65 52 65 73 75 6c 74 29 20 7b 0a 20 20 20 20 20 | f.(0.!==.$compareResult).{...... |
a2600 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 28 27 3e 27 20 3d 3d 3d 20 24 6f 70 65 72 61 74 6f 72 | .......return.('>'.===.$operator |
a2620 | 20 3f 20 31 20 3a 20 2d 31 29 20 3d 3d 3d 20 24 63 6f 6d 70 61 72 65 52 65 73 75 6c 74 3b 0a 20 | .?.1.:.-1).===.$compareResult;.. |
a2640 | 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 27 3e 27 20 3d 3d 3d 20 | .......}.........return.'>'.===. |
a2660 | 24 6f 70 65 72 61 74 6f 72 20 3f 20 24 6f 74 68 65 72 2d 3e 69 73 49 6e 63 6c 75 73 69 76 65 28 | $operator.?.$other->isInclusive( |
a2680 | 29 20 3a 20 21 24 6f 74 68 65 72 2d 3e 69 73 49 6e 63 6c 75 73 69 76 65 28 29 3b 0a 20 20 20 20 | ).:.!$other->isInclusive();..... |
a26a0 | 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 74 6f 53 74 72 69 6e 67 | }.....public.function.__toString |
a26c0 | 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 5c 73 70 72 69 6e 74 66 | ().....{.........return.\sprintf |
a26e0 | 28 27 25 73 20 5b 25 73 5d 27 2c 20 24 74 68 69 73 2d 3e 67 65 74 56 65 72 73 69 6f 6e 28 29 2c | ('%s.[%s]',.$this->getVersion(), |
a2700 | 20 24 74 68 69 73 2d 3e 69 73 49 6e 63 6c 75 73 69 76 65 28 29 20 3f 20 27 69 6e 63 6c 75 73 69 | .$this->isInclusive().?.'inclusi |
a2720 | 76 65 27 20 3a 20 27 65 78 63 6c 75 73 69 76 65 27 29 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 | ve'.:.'exclusive');.....}.....pu |
a2740 | 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 7a 65 72 6f 28 29 0a 20 20 20 20 | blic.static.function.zero()..... |
a2760 | 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 | {.........return.new.\HumbugBox3 |
a2780 | 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 42 | 111\Composer\Semver\Constraint\B |
a27a0 | 6f 75 6e 64 28 27 30 2e 30 2e 30 2e 30 2d 64 65 76 27 2c 20 5c 74 72 75 65 29 3b 0a 20 20 20 20 | ound('0.0.0.0-dev',.\true);..... |
a27c0 | 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 70 6f 73 | }.....public.static.function.pos |
a27e0 | 69 74 69 76 65 49 6e 66 69 6e 69 74 79 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 | itiveInfinity().....{.........re |
a2800 | 74 75 72 6e 20 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 | turn.new.\HumbugBox3111\Composer |
a2820 | 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 42 6f 75 6e 64 28 5c 50 48 50 5f 49 4e | \Semver\Constraint\Bound(\PHP_IN |
a2840 | 54 5f 4d 41 58 20 2e 20 27 2e 30 2e 30 2e 30 27 2c 20 5c 66 61 6c 73 65 29 3b 0a 20 20 20 20 7d | T_MAX...'.0.0.0',.\false);.....} |
a2860 | 0a 7d 0a 3c 3f 70 68 70 0a 0a 6e 61 6d 65 73 70 61 63 65 20 48 75 6d 62 75 67 42 6f 78 33 31 31 | .}.<?php..namespace.HumbugBox311 |
a2880 | 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 3b 0a 0a 75 73 65 20 48 75 6d 62 75 67 42 6f | 1\Composer\Semver;..use.HumbugBo |
a28a0 | 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 | x3111\Composer\Semver\Constraint |
a28c0 | 5c 43 6f 6e 73 74 72 61 69 6e 74 3b 0a 75 73 65 20 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 | \Constraint;.use.HumbugBox3111\C |
a28e0 | 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 | omposer\Semver\Constraint\Constr |
a2900 | 61 69 6e 74 49 6e 74 65 72 66 61 63 65 3b 0a 63 6c 61 73 73 20 43 6f 6d 70 69 6c 69 6e 67 4d 61 | aintInterface;.class.CompilingMa |
a2920 | 74 63 68 65 72 0a 7b 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 24 63 6f 6d 70 | tcher.{.....private.static.$comp |
a2940 | 69 6c 65 64 43 68 65 63 6b 65 72 43 61 63 68 65 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 | iledCheckerCache.=.array();..... |
a2960 | 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 24 65 6e 61 62 6c 65 64 20 3d 20 6e 75 6c 6c 3b 0a | private.static.$enabled.=.null;. |
a2980 | 20 20 20 20 2f 2a 2a 0a 20 20 20 20 40 70 68 70 73 74 61 6e 2d 76 61 72 0a 20 20 20 20 2a 2f 0a | ..../**.....@phpstan-var.....*/. |
a29a0 | 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 24 74 72 61 6e 73 4f 70 49 6e 74 20 3d | ....private.static.$transOpInt.= |
a29c0 | 20 61 72 72 61 79 28 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 | .array(\HumbugBox3111\Composer\S |
a29e0 | 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 3a 3a 4f 50 5f | emver\Constraint\Constraint::OP_ |
a2a00 | 45 51 20 3d 3e 20 27 3d 3d 27 2c 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f | EQ.=>.'==',.\HumbugBox3111\Compo |
a2a20 | 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 | ser\Semver\Constraint\Constraint |
a2a40 | 3a 3a 4f 50 5f 4c 54 20 3d 3e 20 27 3c 27 2c 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 | ::OP_LT.=>.'<',.\HumbugBox3111\C |
a2a60 | 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 | omposer\Semver\Constraint\Constr |
a2a80 | 61 69 6e 74 3a 3a 4f 50 5f 4c 45 20 3d 3e 20 27 3c 3d 27 2c 20 5c 48 75 6d 62 75 67 42 6f 78 33 | aint::OP_LE.=>.'<=',.\HumbugBox3 |
a2aa0 | 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 | 111\Composer\Semver\Constraint\C |
a2ac0 | 6f 6e 73 74 72 61 69 6e 74 3a 3a 4f 50 5f 47 54 20 3d 3e 20 27 3e 27 2c 20 5c 48 75 6d 62 75 67 | onstraint::OP_GT.=>.'>',.\Humbug |
a2ae0 | 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 | Box3111\Composer\Semver\Constrai |
a2b00 | 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 3a 3a 4f 50 5f 47 45 20 3d 3e 20 27 3e 3d 27 2c 20 5c 48 | nt\Constraint::OP_GE.=>.'>=',.\H |
a2b20 | 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e | umbugBox3111\Composer\Semver\Con |
a2b40 | 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 3a 3a 4f 50 5f 4e 45 20 3d 3e 20 27 21 3d | straint\Constraint::OP_NE.=>.'!= |
a2b60 | 27 29 3b 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 40 70 68 70 73 74 61 6e 2d 70 61 72 61 6d 0a 20 | ');...../**.....@phpstan-param.. |
a2b80 | 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e | ...*/.....public.static.function |
a2ba0 | 20 6d 61 74 63 68 28 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 | .match(\HumbugBox3111\Composer\S |
a2bc0 | 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 49 6e 74 65 72 | emver\Constraint\ConstraintInter |
a2be0 | 66 61 63 65 20 24 63 6f 6e 73 74 72 61 69 6e 74 2c 20 24 6f 70 65 72 61 74 6f 72 2c 20 24 76 65 | face.$constraint,.$operator,.$ve |
a2c00 | 72 73 69 6f 6e 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 73 65 6c 66 3a 3a 24 | rsion).....{.........if.(self::$ |
a2c20 | 65 6e 61 62 6c 65 64 20 3d 3d 3d 20 6e 75 6c 6c 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | enabled.===.null).{............. |
a2c40 | 73 65 6c 66 3a 3a 24 65 6e 61 62 6c 65 64 20 3d 20 21 5c 69 6e 5f 61 72 72 61 79 28 27 65 76 61 | self::$enabled.=.!\in_array('eva |
a2c60 | 6c 27 2c 20 5c 65 78 70 6c 6f 64 65 28 27 2c 27 2c 20 5c 69 6e 69 5f 67 65 74 28 27 64 69 73 61 | l',.\explode(',',.\ini_get('disa |
a2c80 | 62 6c 65 5f 66 75 6e 63 74 69 6f 6e 73 27 29 29 2c 20 5c 74 72 75 65 29 3b 0a 20 20 20 20 20 20 | ble_functions')),.\true);....... |
a2ca0 | 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 73 65 6c 66 3a 3a 24 65 6e 61 62 6c 65 64 29 | ..}.........if.(!self::$enabled) |
a2cc0 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 63 6f 6e 73 74 72 61 69 6e | .{.............return.$constrain |
a2ce0 | 74 2d 3e 6d 61 74 63 68 65 73 28 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f | t->matches(new.\HumbugBox3111\Co |
a2d00 | 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 | mposer\Semver\Constraint\Constra |
a2d20 | 69 6e 74 28 73 65 6c 66 3a 3a 24 74 72 61 6e 73 4f 70 49 6e 74 5b 24 6f 70 65 72 61 74 6f 72 5d | int(self::$transOpInt[$operator] |
a2d40 | 2c 20 24 76 65 72 73 69 6f 6e 29 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 | ,.$version));.........}......... |
a2d60 | 24 63 61 63 68 65 4b 65 79 20 3d 20 24 6f 70 65 72 61 74 6f 72 20 2e 20 24 63 6f 6e 73 74 72 61 | $cacheKey.=.$operator...$constra |
a2d80 | 69 6e 74 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 69 73 73 65 74 28 73 65 6c 66 3a 3a 24 63 | int;.........if.(!isset(self::$c |
a2da0 | 6f 6d 70 69 6c 65 64 43 68 65 63 6b 65 72 43 61 63 68 65 5b 24 63 61 63 68 65 4b 65 79 5d 29 29 | ompiledCheckerCache[$cacheKey])) |
a2dc0 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6f 64 65 20 3d 20 24 63 6f 6e 73 74 72 61 69 | .{.............$code.=.$constrai |
a2de0 | 6e 74 2d 3e 63 6f 6d 70 69 6c 65 28 24 6f 70 65 72 61 74 6f 72 29 3b 0a 20 20 20 20 20 20 20 20 | nt->compile($operator);......... |
a2e00 | 20 20 20 20 73 65 6c 66 3a 3a 24 63 6f 6d 70 69 6c 65 64 43 68 65 63 6b 65 72 43 61 63 68 65 5b | ....self::$compiledCheckerCache[ |
a2e20 | 24 63 61 63 68 65 4b 65 79 5d 20 3d 20 24 66 75 6e 63 74 69 6f 6e 20 3d 20 65 76 61 6c 28 27 72 | $cacheKey].=.$function.=.eval('r |
a2e40 | 65 74 75 72 6e 20 66 75 6e 63 74 69 6f 6e 28 24 76 2c 20 24 62 29 7b 72 65 74 75 72 6e 20 27 20 | eturn.function($v,.$b){return.'. |
a2e60 | 2e 20 24 63 6f 64 65 20 2e 20 27 3b 7d 3b 27 29 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 | ..$code...';};');.........}.else |
a2e80 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 66 75 6e 63 74 69 6f 6e 20 3d 20 73 65 6c 66 3a | .{.............$function.=.self: |
a2ea0 | 3a 24 63 6f 6d 70 69 6c 65 64 43 68 65 63 6b 65 72 43 61 63 68 65 5b 24 63 61 63 68 65 4b 65 79 | :$compiledCheckerCache[$cacheKey |
a2ec0 | 5d 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 66 75 6e | ];.........}.........return.$fun |
a2ee0 | 63 74 69 6f 6e 28 24 76 65 72 73 69 6f 6e 2c 20 24 76 65 72 73 69 6f 6e 5b 30 5d 20 3d 3d 3d 20 | ction($version,.$version[0].===. |
a2f00 | 27 64 27 20 26 26 20 27 64 65 76 2d 27 20 3d 3d 3d 20 5c 73 75 62 73 74 72 28 24 76 65 72 73 69 | 'd'.&&.'dev-'.===.\substr($versi |
a2f20 | 6f 6e 2c 20 30 2c 20 34 29 29 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 6e 61 6d 65 73 | on,.0,.4));.....}.}.<?php..names |
a2f40 | 70 61 63 65 20 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 | pace.HumbugBox3111\Composer\Semv |
a2f60 | 65 72 3b 0a 0a 75 73 65 20 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c | er;..use.HumbugBox3111\Composer\ |
a2f80 | 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 3b 0a 63 6c | Semver\Constraint\Constraint;.cl |
a2fa0 | 61 73 73 20 43 6f 6d 70 61 72 61 74 6f 72 0a 7b 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 | ass.Comparator.{.....public.stat |
a2fc0 | 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 72 65 61 74 65 72 54 68 61 6e 28 24 76 65 72 73 69 6f 6e | ic.function.greaterThan($version |
a2fe0 | 31 2c 20 24 76 65 72 73 69 6f 6e 32 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 | 1,.$version2).....{.........retu |
a3000 | 72 6e 20 73 65 6c 66 3a 3a 63 6f 6d 70 61 72 65 28 24 76 65 72 73 69 6f 6e 31 2c 20 27 3e 27 2c | rn.self::compare($version1,.'>', |
a3020 | 20 24 76 65 72 73 69 6f 6e 32 29 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 | .$version2);.....}.....public.st |
a3040 | 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 72 65 61 74 65 72 54 68 61 6e 4f 72 45 71 75 61 6c | atic.function.greaterThanOrEqual |
a3060 | 54 6f 28 24 76 65 72 73 69 6f 6e 31 2c 20 24 76 65 72 73 69 6f 6e 32 29 0a 20 20 20 20 7b 0a 20 | To($version1,.$version2).....{.. |
a3080 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 3a 3a 63 6f 6d 70 61 72 65 28 24 76 65 72 | .......return.self::compare($ver |
a30a0 | 73 69 6f 6e 31 2c 20 27 3e 3d 27 2c 20 24 76 65 72 73 69 6f 6e 32 29 3b 0a 20 20 20 20 7d 0a 20 | sion1,.'>=',.$version2);.....}.. |
a30c0 | 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 6c 65 73 73 54 68 | ...public.static.function.lessTh |
a30e0 | 61 6e 28 24 76 65 72 73 69 6f 6e 31 2c 20 24 76 65 72 73 69 6f 6e 32 29 0a 20 20 20 20 7b 0a 20 | an($version1,.$version2).....{.. |
a3100 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 3a 3a 63 6f 6d 70 61 72 65 28 24 76 65 72 | .......return.self::compare($ver |
a3120 | 73 69 6f 6e 31 2c 20 27 3c 27 2c 20 24 76 65 72 73 69 6f 6e 32 29 3b 0a 20 20 20 20 7d 0a 20 20 | sion1,.'<',.$version2);.....}... |
a3140 | 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 6c 65 73 73 54 68 61 | ..public.static.function.lessTha |
a3160 | 6e 4f 72 45 71 75 61 6c 54 6f 28 24 76 65 72 73 69 6f 6e 31 2c 20 24 76 65 72 73 69 6f 6e 32 29 | nOrEqualTo($version1,.$version2) |
a3180 | 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 3a 3a 63 6f 6d 70 | .....{.........return.self::comp |
a31a0 | 61 72 65 28 24 76 65 72 73 69 6f 6e 31 2c 20 27 3c 3d 27 2c 20 24 76 65 72 73 69 6f 6e 32 29 3b | are($version1,.'<=',.$version2); |
a31c0 | 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f | .....}.....public.static.functio |
a31e0 | 6e 20 65 71 75 61 6c 54 6f 28 24 76 65 72 73 69 6f 6e 31 2c 20 24 76 65 72 73 69 6f 6e 32 29 0a | n.equalTo($version1,.$version2). |
a3200 | 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 3a 3a 63 6f 6d 70 61 | ....{.........return.self::compa |
a3220 | 72 65 28 24 76 65 72 73 69 6f 6e 31 2c 20 27 3d 3d 27 2c 20 24 76 65 72 73 69 6f 6e 32 29 3b 0a | re($version1,.'==',.$version2);. |
a3240 | 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e | ....}.....public.static.function |
a3260 | 20 6e 6f 74 45 71 75 61 6c 54 6f 28 24 76 65 72 73 69 6f 6e 31 2c 20 24 76 65 72 73 69 6f 6e 32 | .notEqualTo($version1,.$version2 |
a3280 | 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 3a 3a 63 6f 6d | ).....{.........return.self::com |
a32a0 | 70 61 72 65 28 24 76 65 72 73 69 6f 6e 31 2c 20 27 21 3d 27 2c 20 24 76 65 72 73 69 6f 6e 32 29 | pare($version1,.'!=',.$version2) |
a32c0 | 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 | ;.....}.....public.static.functi |
a32e0 | 6f 6e 20 63 6f 6d 70 61 72 65 28 24 76 65 72 73 69 6f 6e 31 2c 20 24 6f 70 65 72 61 74 6f 72 2c | on.compare($version1,.$operator, |
a3300 | 20 24 76 65 72 73 69 6f 6e 32 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 63 6f 6e 73 74 | .$version2).....{.........$const |
a3320 | 72 61 69 6e 74 20 3d 20 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f | raint.=.new.\HumbugBox3111\Compo |
a3340 | 73 65 72 5c 53 65 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 | ser\Semver\Constraint\Constraint |
a3360 | 28 24 6f 70 65 72 61 74 6f 72 2c 20 24 76 65 72 73 69 6f 6e 32 29 3b 0a 20 20 20 20 20 20 20 20 | ($operator,.$version2);......... |
a3380 | 72 65 74 75 72 6e 20 24 63 6f 6e 73 74 72 61 69 6e 74 2d 3e 6d 61 74 63 68 53 70 65 63 69 66 69 | return.$constraint->matchSpecifi |
a33a0 | 63 28 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 | c(new.\HumbugBox3111\Composer\Se |
a33c0 | 6d 76 65 72 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 43 6f 6e 73 74 72 61 69 6e 74 28 27 3d 3d 27 2c | mver\Constraint\Constraint('==', |
a33e0 | 20 24 76 65 72 73 69 6f 6e 31 29 2c 20 5c 74 72 75 65 29 3b 0a 20 20 20 20 7d 0a 7d 0a 43 6f 70 | .$version1),.\true);.....}.}.Cop |
a3400 | 79 72 69 67 68 74 20 28 43 29 20 32 30 31 35 20 43 6f 6d 70 6f 73 65 72 0a 0a 50 65 72 6d 69 73 | yright.(C).2015.Composer..Permis |
a3420 | 73 69 6f 6e 20 69 73 20 68 65 72 65 62 79 20 67 72 61 6e 74 65 64 2c 20 66 72 65 65 20 6f 66 20 | sion.is.hereby.granted,.free.of. |
a3440 | 63 68 61 72 67 65 2c 20 74 6f 20 61 6e 79 20 70 65 72 73 6f 6e 20 6f 62 74 61 69 6e 69 6e 67 20 | charge,.to.any.person.obtaining. |
a3460 | 61 20 63 6f 70 79 20 6f 66 0a 74 68 69 73 20 73 6f 66 74 77 61 72 65 20 61 6e 64 20 61 73 73 6f | a.copy.of.this.software.and.asso |
a3480 | 63 69 61 74 65 64 20 64 6f 63 75 6d 65 6e 74 61 74 69 6f 6e 20 66 69 6c 65 73 20 28 74 68 65 20 | ciated.documentation.files.(the. |
a34a0 | 22 53 6f 66 74 77 61 72 65 22 29 2c 20 74 6f 20 64 65 61 6c 20 69 6e 0a 74 68 65 20 53 6f 66 74 | "Software"),.to.deal.in.the.Soft |
a34c0 | 77 61 72 65 20 77 69 74 68 6f 75 74 20 72 65 73 74 72 69 63 74 69 6f 6e 2c 20 69 6e 63 6c 75 64 | ware.without.restriction,.includ |
a34e0 | 69 6e 67 20 77 69 74 68 6f 75 74 20 6c 69 6d 69 74 61 74 69 6f 6e 20 74 68 65 20 72 69 67 68 74 | ing.without.limitation.the.right |
a3500 | 73 20 74 6f 0a 75 73 65 2c 20 63 6f 70 79 2c 20 6d 6f 64 69 66 79 2c 20 6d 65 72 67 65 2c 20 70 | s.to.use,.copy,.modify,.merge,.p |
a3520 | 75 62 6c 69 73 68 2c 20 64 69 73 74 72 69 62 75 74 65 2c 20 73 75 62 6c 69 63 65 6e 73 65 2c 20 | ublish,.distribute,.sublicense,. |
a3540 | 61 6e 64 2f 6f 72 20 73 65 6c 6c 20 63 6f 70 69 65 73 0a 6f 66 20 74 68 65 20 53 6f 66 74 77 61 | and/or.sell.copies.of.the.Softwa |
a3560 | 72 65 2c 20 61 6e 64 20 74 6f 20 70 65 72 6d 69 74 20 70 65 72 73 6f 6e 73 20 74 6f 20 77 68 6f | re,.and.to.permit.persons.to.who |
a3580 | 6d 20 74 68 65 20 53 6f 66 74 77 61 72 65 20 69 73 20 66 75 72 6e 69 73 68 65 64 20 74 6f 20 64 | m.the.Software.is.furnished.to.d |
a35a0 | 6f 0a 73 6f 2c 20 73 75 62 6a 65 63 74 20 74 6f 20 74 68 65 20 66 6f 6c 6c 6f 77 69 6e 67 20 63 | o.so,.subject.to.the.following.c |
a35c0 | 6f 6e 64 69 74 69 6f 6e 73 3a 0a 0a 54 68 65 20 61 62 6f 76 65 20 63 6f 70 79 72 69 67 68 74 20 | onditions:..The.above.copyright. |
a35e0 | 6e 6f 74 69 63 65 20 61 6e 64 20 74 68 69 73 20 70 65 72 6d 69 73 73 69 6f 6e 20 6e 6f 74 69 63 | notice.and.this.permission.notic |
a3600 | 65 20 73 68 61 6c 6c 20 62 65 20 69 6e 63 6c 75 64 65 64 20 69 6e 20 61 6c 6c 0a 63 6f 70 69 65 | e.shall.be.included.in.all.copie |
a3620 | 73 20 6f 72 20 73 75 62 73 74 61 6e 74 69 61 6c 20 70 6f 72 74 69 6f 6e 73 20 6f 66 20 74 68 65 | s.or.substantial.portions.of.the |
a3640 | 20 53 6f 66 74 77 61 72 65 2e 0a 0a 54 48 45 20 53 4f 46 54 57 41 52 45 20 49 53 20 50 52 4f 56 | .Software...THE.SOFTWARE.IS.PROV |
a3660 | 49 44 45 44 20 22 41 53 20 49 53 22 2c 20 57 49 54 48 4f 55 54 20 57 41 52 52 41 4e 54 59 20 4f | IDED."AS.IS",.WITHOUT.WARRANTY.O |
a3680 | 46 20 41 4e 59 20 4b 49 4e 44 2c 20 45 58 50 52 45 53 53 20 4f 52 0a 49 4d 50 4c 49 45 44 2c 20 | F.ANY.KIND,.EXPRESS.OR.IMPLIED,. |
a36a0 | 49 4e 43 4c 55 44 49 4e 47 20 42 55 54 20 4e 4f 54 20 4c 49 4d 49 54 45 44 20 54 4f 20 54 48 45 | INCLUDING.BUT.NOT.LIMITED.TO.THE |
a36c0 | 20 57 41 52 52 41 4e 54 49 45 53 20 4f 46 20 4d 45 52 43 48 41 4e 54 41 42 49 4c 49 54 59 2c 0a | .WARRANTIES.OF.MERCHANTABILITY,. |
a36e0 | 46 49 54 4e 45 53 53 20 46 4f 52 20 41 20 50 41 52 54 49 43 55 4c 41 52 20 50 55 52 50 4f 53 45 | FITNESS.FOR.A.PARTICULAR.PURPOSE |
a3700 | 20 41 4e 44 20 4e 4f 4e 49 4e 46 52 49 4e 47 45 4d 45 4e 54 2e 20 49 4e 20 4e 4f 20 45 56 45 4e | .AND.NONINFRINGEMENT..IN.NO.EVEN |
a3720 | 54 20 53 48 41 4c 4c 20 54 48 45 0a 41 55 54 48 4f 52 53 20 4f 52 20 43 4f 50 59 52 49 47 48 54 | T.SHALL.THE.AUTHORS.OR.COPYRIGHT |
a3740 | 20 48 4f 4c 44 45 52 53 20 42 45 20 4c 49 41 42 4c 45 20 46 4f 52 20 41 4e 59 20 43 4c 41 49 4d | .HOLDERS.BE.LIABLE.FOR.ANY.CLAIM |
a3760 | 2c 20 44 41 4d 41 47 45 53 20 4f 52 20 4f 54 48 45 52 0a 4c 49 41 42 49 4c 49 54 59 2c 20 57 48 | ,.DAMAGES.OR.OTHER.LIABILITY,.WH |
a3780 | 45 54 48 45 52 20 49 4e 20 41 4e 20 41 43 54 49 4f 4e 20 4f 46 20 43 4f 4e 54 52 41 43 54 2c 20 | ETHER.IN.AN.ACTION.OF.CONTRACT,. |
a37a0 | 54 4f 52 54 20 4f 52 20 4f 54 48 45 52 57 49 53 45 2c 20 41 52 49 53 49 4e 47 20 46 52 4f 4d 2c | TORT.OR.OTHERWISE,.ARISING.FROM, |
a37c0 | 0a 4f 55 54 20 4f 46 20 4f 52 20 49 4e 20 43 4f 4e 4e 45 43 54 49 4f 4e 20 57 49 54 48 20 54 48 | .OUT.OF.OR.IN.CONNECTION.WITH.TH |
a37e0 | 45 20 53 4f 46 54 57 41 52 45 20 4f 52 20 54 48 45 20 55 53 45 20 4f 52 20 4f 54 48 45 52 20 44 | E.SOFTWARE.OR.THE.USE.OR.OTHER.D |
a3800 | 45 41 4c 49 4e 47 53 20 49 4e 20 54 48 45 0a 53 4f 46 54 57 41 52 45 2e 0a 3c 3f 70 68 70 0a 0a | EALINGS.IN.THE.SOFTWARE..<?php.. |
a3820 | 2f 2f 20 61 75 74 6f 6c 6f 61 64 5f 73 74 61 74 69 63 2e 70 68 70 20 40 67 65 6e 65 72 61 74 65 | //.autoload_static.php.@generate |
a3840 | 64 20 62 79 20 43 6f 6d 70 6f 73 65 72 0a 0a 6e 61 6d 65 73 70 61 63 65 20 43 6f 6d 70 6f 73 65 | d.by.Composer..namespace.Compose |
a3860 | 72 5c 41 75 74 6f 6c 6f 61 64 3b 0a 0a 63 6c 61 73 73 20 43 6f 6d 70 6f 73 65 72 53 74 61 74 69 | r\Autoload;..class.ComposerStati |
a3880 | 63 49 6e 69 74 35 30 37 37 34 64 31 33 33 33 30 34 63 35 37 66 36 34 63 64 32 30 39 65 32 34 36 | cInit50774d133304c57f64cd209e246 |
a38a0 | 61 66 33 31 61 0a 7b 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 24 70 72 65 66 69 | af31a.{.....public.static.$prefi |
a38c0 | 78 4c 65 6e 67 74 68 73 50 73 72 34 20 3d 20 61 72 72 61 79 20 28 0a 20 20 20 20 20 20 20 20 27 | xLengthsPsr4.=.array.(.........' |
a38e0 | 48 27 20 3d 3e 20 0a 20 20 20 20 20 20 20 20 61 72 72 61 79 20 28 0a 20 20 20 20 20 20 20 20 20 | H'.=>..........array.(.......... |
a3900 | 20 20 20 27 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 5c 4b 65 76 69 6e 47 48 5c 5c 52 65 71 75 | ...'HumbugBox3111\\KevinGH\\Requ |
a3920 | 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 5c 5c 27 20 3d 3e 20 34 31 2c 0a 20 20 20 20 20 20 20 | irementChecker\\'.=>.41,........ |
a3940 | 20 20 20 20 20 27 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 5c 43 6f 6d 70 6f 73 65 72 5c 5c 53 | .....'HumbugBox3111\\Composer\\S |
a3960 | 65 6d 76 65 72 5c 5c 27 20 3d 3e 20 33 30 2c 0a 20 20 20 20 20 20 20 20 29 2c 0a 20 20 20 20 29 | emver\\'.=>.30,.........),.....) |
a3980 | 3b 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 24 70 72 65 66 69 78 44 69 72 73 | ;......public.static.$prefixDirs |
a39a0 | 50 73 72 34 20 3d 20 61 72 72 61 79 20 28 0a 20 20 20 20 20 20 20 20 27 48 75 6d 62 75 67 42 6f | Psr4.=.array.(.........'HumbugBo |
a39c0 | 78 33 31 31 31 5c 5c 4b 65 76 69 6e 47 48 5c 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b | x3111\\KevinGH\\RequirementCheck |
a39e0 | 65 72 5c 5c 27 20 3d 3e 20 0a 20 20 20 20 20 20 20 20 61 72 72 61 79 20 28 0a 20 20 20 20 20 20 | er\\'.=>..........array.(....... |
a3a00 | 20 20 20 20 20 20 30 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 2f 2e 2e 27 20 2e 20 | ......0.=>.__DIR__...'/../..'... |
a3a20 | 27 2f 73 72 63 27 2c 0a 20 20 20 20 20 20 20 20 29 2c 0a 20 20 20 20 20 20 20 20 27 48 75 6d 62 | '/src',.........),.........'Humb |
a3a40 | 75 67 42 6f 78 33 31 31 31 5c 5c 43 6f 6d 70 6f 73 65 72 5c 5c 53 65 6d 76 65 72 5c 5c 27 20 3d | ugBox3111\\Composer\\Semver\\'.= |
a3a60 | 3e 20 0a 20 20 20 20 20 20 20 20 61 72 72 61 79 20 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 30 | >..........array.(.............0 |
a3a80 | 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 63 6f 6d 70 6f 73 65 72 | .=>.__DIR__...'/..'...'/composer |
a3aa0 | 2f 73 65 6d 76 65 72 2f 73 72 63 27 2c 0a 20 20 20 20 20 20 20 20 29 2c 0a 20 20 20 20 29 3b 0a | /semver/src',.........),.....);. |
a3ac0 | 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 24 63 6c 61 73 73 4d 61 70 20 3d 20 61 | .....public.static.$classMap.=.a |
a3ae0 | 72 72 61 79 20 28 0a 20 20 20 20 20 20 20 20 27 43 6f 6d 70 6f 73 65 72 5c 5c 49 6e 73 74 61 6c | rray.(.........'Composer\\Instal |
a3b00 | 6c 65 64 56 65 72 73 69 6f 6e 73 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 | ledVersions'.=>.__DIR__...'/..'. |
a3b20 | 2e 20 27 2f 63 6f 6d 70 6f 73 65 72 2f 49 6e 73 74 61 6c 6c 65 64 56 65 72 73 69 6f 6e 73 2e 70 | ..'/composer/InstalledVersions.p |
a3b40 | 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 5c 43 6f 6d | hp',.........'HumbugBox3111\\Com |
a3b60 | 70 6f 73 65 72 5c 5c 53 65 6d 76 65 72 5c 5c 43 6f 6d 70 61 72 61 74 6f 72 27 20 3d 3e 20 5f 5f | poser\\Semver\\Comparator'.=>.__ |
a3b80 | 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 63 6f 6d 70 6f 73 65 72 2f 73 65 6d 76 65 | DIR__...'/..'...'/composer/semve |
a3ba0 | 72 2f 73 72 63 2f 43 6f 6d 70 61 72 61 74 6f 72 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 | r/src/Comparator.php',.........' |
a3bc0 | 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 5c 43 6f 6d 70 6f 73 65 72 5c 5c 53 65 6d 76 65 72 5c | HumbugBox3111\\Composer\\Semver\ |
a3be0 | 5c 43 6f 6d 70 69 6c 69 6e 67 4d 61 74 63 68 65 72 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 | \CompilingMatcher'.=>.__DIR__... |
a3c00 | 27 2f 2e 2e 27 20 2e 20 27 2f 63 6f 6d 70 6f 73 65 72 2f 73 65 6d 76 65 72 2f 73 72 63 2f 43 6f | '/..'...'/composer/semver/src/Co |
a3c20 | 6d 70 69 6c 69 6e 67 4d 61 74 63 68 65 72 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 48 75 | mpilingMatcher.php',.........'Hu |
a3c40 | 6d 62 75 67 42 6f 78 33 31 31 31 5c 5c 43 6f 6d 70 6f 73 65 72 5c 5c 53 65 6d 76 65 72 5c 5c 43 | mbugBox3111\\Composer\\Semver\\C |
a3c60 | 6f 6e 73 74 72 61 69 6e 74 5c 5c 42 6f 75 6e 64 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 | onstraint\\Bound'.=>.__DIR__...' |
a3c80 | 2f 2e 2e 27 20 2e 20 27 2f 63 6f 6d 70 6f 73 65 72 2f 73 65 6d 76 65 72 2f 73 72 63 2f 43 6f 6e | /..'...'/composer/semver/src/Con |
a3ca0 | 73 74 72 61 69 6e 74 2f 42 6f 75 6e 64 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 48 75 6d | straint/Bound.php',.........'Hum |
a3cc0 | 62 75 67 42 6f 78 33 31 31 31 5c 5c 43 6f 6d 70 6f 73 65 72 5c 5c 53 65 6d 76 65 72 5c 5c 43 6f | bugBox3111\\Composer\\Semver\\Co |
a3ce0 | 6e 73 74 72 61 69 6e 74 5c 5c 43 6f 6e 73 74 72 61 69 6e 74 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f | nstraint\\Constraint'.=>.__DIR__ |
a3d00 | 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 63 6f 6d 70 6f 73 65 72 2f 73 65 6d 76 65 72 2f 73 72 63 | ...'/..'...'/composer/semver/src |
a3d20 | 2f 43 6f 6e 73 74 72 61 69 6e 74 2f 43 6f 6e 73 74 72 61 69 6e 74 2e 70 68 70 27 2c 0a 20 20 20 | /Constraint/Constraint.php',.... |
a3d40 | 20 20 20 20 20 27 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 5c 43 6f 6d 70 6f 73 65 72 5c 5c 53 | .....'HumbugBox3111\\Composer\\S |
a3d60 | 65 6d 76 65 72 5c 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 5c 43 6f 6e 73 74 72 61 69 6e 74 49 6e 74 | emver\\Constraint\\ConstraintInt |
a3d80 | 65 72 66 61 63 65 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 63 | erface'.=>.__DIR__...'/..'...'/c |
a3da0 | 6f 6d 70 6f 73 65 72 2f 73 65 6d 76 65 72 2f 73 72 63 2f 43 6f 6e 73 74 72 61 69 6e 74 2f 43 6f | omposer/semver/src/Constraint/Co |
a3dc0 | 6e 73 74 72 61 69 6e 74 49 6e 74 65 72 66 61 63 65 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 | nstraintInterface.php',......... |
a3de0 | 27 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 5c 43 6f 6d 70 6f 73 65 72 5c 5c 53 65 6d 76 65 72 | 'HumbugBox3111\\Composer\\Semver |
a3e00 | 5c 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 5c 4d 61 74 63 68 41 6c 6c 43 6f 6e 73 74 72 61 69 6e 74 | \\Constraint\\MatchAllConstraint |
a3e20 | 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 63 6f 6d 70 6f 73 65 | '.=>.__DIR__...'/..'...'/compose |
a3e40 | 72 2f 73 65 6d 76 65 72 2f 73 72 63 2f 43 6f 6e 73 74 72 61 69 6e 74 2f 4d 61 74 63 68 41 6c 6c | r/semver/src/Constraint/MatchAll |
a3e60 | 43 6f 6e 73 74 72 61 69 6e 74 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 48 75 6d 62 75 67 | Constraint.php',.........'Humbug |
a3e80 | 42 6f 78 33 31 31 31 5c 5c 43 6f 6d 70 6f 73 65 72 5c 5c 53 65 6d 76 65 72 5c 5c 43 6f 6e 73 74 | Box3111\\Composer\\Semver\\Const |
a3ea0 | 72 61 69 6e 74 5c 5c 4d 61 74 63 68 4e 6f 6e 65 43 6f 6e 73 74 72 61 69 6e 74 27 20 3d 3e 20 5f | raint\\MatchNoneConstraint'.=>._ |
a3ec0 | 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 63 6f 6d 70 6f 73 65 72 2f 73 65 6d 76 | _DIR__...'/..'...'/composer/semv |
a3ee0 | 65 72 2f 73 72 63 2f 43 6f 6e 73 74 72 61 69 6e 74 2f 4d 61 74 63 68 4e 6f 6e 65 43 6f 6e 73 74 | er/src/Constraint/MatchNoneConst |
a3f00 | 72 61 69 6e 74 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 48 75 6d 62 75 67 42 6f 78 33 31 | raint.php',.........'HumbugBox31 |
a3f20 | 31 31 5c 5c 43 6f 6d 70 6f 73 65 72 5c 5c 53 65 6d 76 65 72 5c 5c 43 6f 6e 73 74 72 61 69 6e 74 | 11\\Composer\\Semver\\Constraint |
a3f40 | 5c 5c 4d 75 6c 74 69 43 6f 6e 73 74 72 61 69 6e 74 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 | \\MultiConstraint'.=>.__DIR__... |
a3f60 | 27 2f 2e 2e 27 20 2e 20 27 2f 63 6f 6d 70 6f 73 65 72 2f 73 65 6d 76 65 72 2f 73 72 63 2f 43 6f | '/..'...'/composer/semver/src/Co |
a3f80 | 6e 73 74 72 61 69 6e 74 2f 4d 75 6c 74 69 43 6f 6e 73 74 72 61 69 6e 74 2e 70 68 70 27 2c 0a 20 | nstraint/MultiConstraint.php',.. |
a3fa0 | 20 20 20 20 20 20 20 27 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 5c 43 6f 6d 70 6f 73 65 72 5c | .......'HumbugBox3111\\Composer\ |
a3fc0 | 5c 53 65 6d 76 65 72 5c 5c 49 6e 74 65 72 76 61 6c 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 | \Semver\\Interval'.=>.__DIR__... |
a3fe0 | 27 2f 2e 2e 27 20 2e 20 27 2f 63 6f 6d 70 6f 73 65 72 2f 73 65 6d 76 65 72 2f 73 72 63 2f 49 6e | '/..'...'/composer/semver/src/In |
a4000 | 74 65 72 76 61 6c 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 48 75 6d 62 75 67 42 6f 78 33 | terval.php',.........'HumbugBox3 |
a4020 | 31 31 31 5c 5c 43 6f 6d 70 6f 73 65 72 5c 5c 53 65 6d 76 65 72 5c 5c 49 6e 74 65 72 76 61 6c 73 | 111\\Composer\\Semver\\Intervals |
a4040 | 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 63 6f 6d 70 6f 73 65 | '.=>.__DIR__...'/..'...'/compose |
a4060 | 72 2f 73 65 6d 76 65 72 2f 73 72 63 2f 49 6e 74 65 72 76 61 6c 73 2e 70 68 70 27 2c 0a 20 20 20 | r/semver/src/Intervals.php',.... |
a4080 | 20 20 20 20 20 27 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 5c 43 6f 6d 70 6f 73 65 72 5c 5c 53 | .....'HumbugBox3111\\Composer\\S |
a40a0 | 65 6d 76 65 72 5c 5c 53 65 6d 76 65 72 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e | emver\\Semver'.=>.__DIR__...'/.. |
a40c0 | 27 20 2e 20 27 2f 63 6f 6d 70 6f 73 65 72 2f 73 65 6d 76 65 72 2f 73 72 63 2f 53 65 6d 76 65 72 | '...'/composer/semver/src/Semver |
a40e0 | 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 5c 43 | .php',.........'HumbugBox3111\\C |
a4100 | 6f 6d 70 6f 73 65 72 5c 5c 53 65 6d 76 65 72 5c 5c 56 65 72 73 69 6f 6e 50 61 72 73 65 72 27 20 | omposer\\Semver\\VersionParser'. |
a4120 | 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 27 20 2e 20 27 2f 63 6f 6d 70 6f 73 65 72 2f | =>.__DIR__...'/..'...'/composer/ |
a4140 | 73 65 6d 76 65 72 2f 73 72 63 2f 56 65 72 73 69 6f 6e 50 61 72 73 65 72 2e 70 68 70 27 2c 0a 20 | semver/src/VersionParser.php',.. |
a4160 | 20 20 20 20 20 20 20 27 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 5c 4b 65 76 69 6e 47 48 5c 5c | .......'HumbugBox3111\\KevinGH\\ |
a4180 | 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 5c 5c 43 68 65 63 6b 65 72 27 20 3d 3e 20 | RequirementChecker\\Checker'.=>. |
a41a0 | 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 2f 2e 2e 27 20 2e 20 27 2f 73 72 63 2f 43 68 65 63 6b | __DIR__...'/../..'...'/src/Check |
a41c0 | 65 72 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c | er.php',.........'HumbugBox3111\ |
a41e0 | 5c 4b 65 76 69 6e 47 48 5c 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 5c 5c 49 4f | \KevinGH\\RequirementChecker\\IO |
a4200 | 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 2f 2e 2e 27 20 2e 20 27 2f 73 72 63 2f | '.=>.__DIR__...'/../..'...'/src/ |
a4220 | 49 4f 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c | IO.php',.........'HumbugBox3111\ |
a4240 | 5c 4b 65 76 69 6e 47 48 5c 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 5c 5c 49 73 | \KevinGH\\RequirementChecker\\Is |
a4260 | 45 78 74 65 6e 73 69 6f 6e 46 75 6c 66 69 6c 6c 65 64 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e | ExtensionFulfilled'.=>.__DIR__.. |
a4280 | 20 27 2f 2e 2e 2f 2e 2e 27 20 2e 20 27 2f 73 72 63 2f 49 73 45 78 74 65 6e 73 69 6f 6e 46 75 6c | .'/../..'...'/src/IsExtensionFul |
a42a0 | 66 69 6c 6c 65 64 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 48 75 6d 62 75 67 42 6f 78 33 | filled.php',.........'HumbugBox3 |
a42c0 | 31 31 31 5c 5c 4b 65 76 69 6e 47 48 5c 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 | 111\\KevinGH\\RequirementChecker |
a42e0 | 5c 5c 49 73 46 75 6c 66 69 6c 6c 65 64 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e | \\IsFulfilled'.=>.__DIR__...'/.. |
a4300 | 2f 2e 2e 27 20 2e 20 27 2f 73 72 63 2f 49 73 46 75 6c 66 69 6c 6c 65 64 2e 70 68 70 27 2c 0a 20 | /..'...'/src/IsFulfilled.php',.. |
a4320 | 20 20 20 20 20 20 20 27 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 5c 4b 65 76 69 6e 47 48 5c 5c | .......'HumbugBox3111\\KevinGH\\ |
a4340 | 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 5c 5c 49 73 50 68 70 56 65 72 73 69 6f 6e | RequirementChecker\\IsPhpVersion |
a4360 | 46 75 6c 66 69 6c 6c 65 64 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 2f 2e 2e 27 | Fulfilled'.=>.__DIR__...'/../..' |
a4380 | 20 2e 20 27 2f 73 72 63 2f 49 73 50 68 70 56 65 72 73 69 6f 6e 46 75 6c 66 69 6c 6c 65 64 2e 70 | ...'/src/IsPhpVersionFulfilled.p |
a43a0 | 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 5c 4b 65 76 | hp',.........'HumbugBox3111\\Kev |
a43c0 | 69 6e 47 48 5c 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 5c 5c 50 72 69 6e 74 65 | inGH\\RequirementChecker\\Printe |
a43e0 | 72 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 2f 2e 2e 27 20 2e 20 27 2f 73 72 63 | r'.=>.__DIR__...'/../..'...'/src |
a4400 | 2f 50 72 69 6e 74 65 72 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 48 75 6d 62 75 67 42 6f | /Printer.php',.........'HumbugBo |
a4420 | 78 33 31 31 31 5c 5c 4b 65 76 69 6e 47 48 5c 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b | x3111\\KevinGH\\RequirementCheck |
a4440 | 65 72 5c 5c 52 65 71 75 69 72 65 6d 65 6e 74 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f | er\\Requirement'.=>.__DIR__...'/ |
a4460 | 2e 2e 2f 2e 2e 27 20 2e 20 27 2f 73 72 63 2f 52 65 71 75 69 72 65 6d 65 6e 74 2e 70 68 70 27 2c | ../..'...'/src/Requirement.php', |
a4480 | 0a 20 20 20 20 20 20 20 20 27 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 5c 4b 65 76 69 6e 47 48 | .........'HumbugBox3111\\KevinGH |
a44a0 | 5c 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 5c 5c 52 65 71 75 69 72 65 6d 65 6e | \\RequirementChecker\\Requiremen |
a44c0 | 74 43 6f 6c 6c 65 63 74 69 6f 6e 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 2f 2e | tCollection'.=>.__DIR__...'/../. |
a44e0 | 2e 27 20 2e 20 27 2f 73 72 63 2f 52 65 71 75 69 72 65 6d 65 6e 74 43 6f 6c 6c 65 63 74 69 6f 6e | .'...'/src/RequirementCollection |
a4500 | 2e 70 68 70 27 2c 0a 20 20 20 20 20 20 20 20 27 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 5c 4b | .php',.........'HumbugBox3111\\K |
a4520 | 65 76 69 6e 47 48 5c 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 5c 5c 54 65 72 6d | evinGH\\RequirementChecker\\Term |
a4540 | 69 6e 61 6c 27 20 3d 3e 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 2f 2e 2e 27 20 2e 20 27 2f | inal'.=>.__DIR__...'/../..'...'/ |
a4560 | 73 72 63 2f 54 65 72 6d 69 6e 61 6c 2e 70 68 70 27 2c 0a 20 20 20 20 29 3b 0a 0a 20 20 20 20 70 | src/Terminal.php',.....);......p |
a4580 | 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 49 6e 69 74 69 61 6c | ublic.static.function.getInitial |
a45a0 | 69 7a 65 72 28 43 6c 61 73 73 4c 6f 61 64 65 72 20 24 6c 6f 61 64 65 72 29 0a 20 20 20 20 7b 0a | izer(ClassLoader.$loader).....{. |
a45c0 | 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 5c 43 6c 6f 73 75 72 65 3a 3a 62 69 6e 64 28 66 75 | ........return.\Closure::bind(fu |
a45e0 | 6e 63 74 69 6f 6e 20 28 29 20 75 73 65 20 28 24 6c 6f 61 64 65 72 29 20 7b 0a 20 20 20 20 20 20 | nction.().use.($loader).{....... |
a4600 | 20 20 20 20 20 20 24 6c 6f 61 64 65 72 2d 3e 70 72 65 66 69 78 4c 65 6e 67 74 68 73 50 73 72 34 | ......$loader->prefixLengthsPsr4 |
a4620 | 20 3d 20 43 6f 6d 70 6f 73 65 72 53 74 61 74 69 63 49 6e 69 74 35 30 37 37 34 64 31 33 33 33 30 | .=.ComposerStaticInit50774d13330 |
a4640 | 34 63 35 37 66 36 34 63 64 32 30 39 65 32 34 36 61 66 33 31 61 3a 3a 24 70 72 65 66 69 78 4c 65 | 4c57f64cd209e246af31a::$prefixLe |
a4660 | 6e 67 74 68 73 50 73 72 34 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 6f 61 64 65 72 2d 3e | ngthsPsr4;.............$loader-> |
a4680 | 70 72 65 66 69 78 44 69 72 73 50 73 72 34 20 3d 20 43 6f 6d 70 6f 73 65 72 53 74 61 74 69 63 49 | prefixDirsPsr4.=.ComposerStaticI |
a46a0 | 6e 69 74 35 30 37 37 34 64 31 33 33 33 30 34 63 35 37 66 36 34 63 64 32 30 39 65 32 34 36 61 66 | nit50774d133304c57f64cd209e246af |
a46c0 | 33 31 61 3a 3a 24 70 72 65 66 69 78 44 69 72 73 50 73 72 34 3b 0a 20 20 20 20 20 20 20 20 20 20 | 31a::$prefixDirsPsr4;........... |
a46e0 | 20 20 24 6c 6f 61 64 65 72 2d 3e 63 6c 61 73 73 4d 61 70 20 3d 20 43 6f 6d 70 6f 73 65 72 53 74 | ..$loader->classMap.=.ComposerSt |
a4700 | 61 74 69 63 49 6e 69 74 35 30 37 37 34 64 31 33 33 33 30 34 63 35 37 66 36 34 63 64 32 30 39 65 | aticInit50774d133304c57f64cd209e |
a4720 | 32 34 36 61 66 33 31 61 3a 3a 24 63 6c 61 73 73 4d 61 70 3b 0a 0a 20 20 20 20 20 20 20 20 7d 2c | 246af31a::$classMap;..........}, |
a4740 | 20 6e 75 6c 6c 2c 20 43 6c 61 73 73 4c 6f 61 64 65 72 3a 3a 63 6c 61 73 73 29 3b 0a 20 20 20 20 | .null,.ClassLoader::class);..... |
a4760 | 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2f 20 61 75 74 6f 6c 6f 61 64 5f 72 65 61 6c 2e 70 68 70 20 | }.}.<?php..//.autoload_real.php. |
a4780 | 40 67 65 6e 65 72 61 74 65 64 20 62 79 20 43 6f 6d 70 6f 73 65 72 0a 0a 63 6c 61 73 73 20 43 6f | @generated.by.Composer..class.Co |
a47a0 | 6d 70 6f 73 65 72 41 75 74 6f 6c 6f 61 64 65 72 49 6e 69 74 35 30 37 37 34 64 31 33 33 33 30 34 | mposerAutoloaderInit50774d133304 |
a47c0 | 63 35 37 66 36 34 63 64 32 30 39 65 32 34 36 61 66 33 31 61 0a 7b 0a 20 20 20 20 70 72 69 76 61 | c57f64cd209e246af31a.{.....priva |
a47e0 | 74 65 20 73 74 61 74 69 63 20 24 6c 6f 61 64 65 72 3b 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 73 | te.static.$loader;......public.s |
a4800 | 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 6c 6f 61 64 43 6c 61 73 73 4c 6f 61 64 65 72 28 24 | tatic.function.loadClassLoader($ |
a4820 | 63 6c 61 73 73 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 27 43 6f 6d 70 6f 73 | class).....{.........if.('Compos |
a4840 | 65 72 5c 41 75 74 6f 6c 6f 61 64 5c 43 6c 61 73 73 4c 6f 61 64 65 72 27 20 3d 3d 3d 20 24 63 6c | er\Autoload\ClassLoader'.===.$cl |
a4860 | 61 73 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 71 75 69 72 65 20 5f 5f 44 49 52 | ass).{.............require.__DIR |
a4880 | 5f 5f 20 2e 20 27 2f 43 6c 61 73 73 4c 6f 61 64 65 72 2e 70 68 70 27 3b 0a 20 20 20 20 20 20 20 | __...'/ClassLoader.php';........ |
a48a0 | 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e | .}.....}....../**......*.@return |
a48c0 | 20 5c 43 6f 6d 70 6f 73 65 72 5c 41 75 74 6f 6c 6f 61 64 5c 43 6c 61 73 73 4c 6f 61 64 65 72 0a | .\Composer\Autoload\ClassLoader. |
a48e0 | 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 | .....*/.....public.static.functi |
a4900 | 6f 6e 20 67 65 74 4c 6f 61 64 65 72 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 | on.getLoader().....{.........if. |
a4920 | 28 6e 75 6c 6c 20 21 3d 3d 20 73 65 6c 66 3a 3a 24 6c 6f 61 64 65 72 29 20 7b 0a 20 20 20 20 20 | (null.!==.self::$loader).{...... |
a4940 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 3a 3a 24 6c 6f 61 64 65 72 3b 0a 20 20 20 | .......return.self::$loader;.... |
a4960 | 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 73 70 6c 5f 61 75 74 6f 6c 6f 61 64 5f 72 65 67 | .....}..........spl_autoload_reg |
a4980 | 69 73 74 65 72 28 61 72 72 61 79 28 27 43 6f 6d 70 6f 73 65 72 41 75 74 6f 6c 6f 61 64 65 72 49 | ister(array('ComposerAutoloaderI |
a49a0 | 6e 69 74 35 30 37 37 34 64 31 33 33 33 30 34 63 35 37 66 36 34 63 64 32 30 39 65 32 34 36 61 66 | nit50774d133304c57f64cd209e246af |
a49c0 | 33 31 61 27 2c 20 27 6c 6f 61 64 43 6c 61 73 73 4c 6f 61 64 65 72 27 29 2c 20 74 72 75 65 2c 20 | 31a',.'loadClassLoader'),.true,. |
a49e0 | 74 72 75 65 29 3b 0a 20 20 20 20 20 20 20 20 73 65 6c 66 3a 3a 24 6c 6f 61 64 65 72 20 3d 20 24 | true);.........self::$loader.=.$ |
a4a00 | 6c 6f 61 64 65 72 20 3d 20 6e 65 77 20 5c 43 6f 6d 70 6f 73 65 72 5c 41 75 74 6f 6c 6f 61 64 5c | loader.=.new.\Composer\Autoload\ |
a4a20 | 43 6c 61 73 73 4c 6f 61 64 65 72 28 29 3b 0a 20 20 20 20 20 20 20 20 73 70 6c 5f 61 75 74 6f 6c | ClassLoader();.........spl_autol |
a4a40 | 6f 61 64 5f 75 6e 72 65 67 69 73 74 65 72 28 61 72 72 61 79 28 27 43 6f 6d 70 6f 73 65 72 41 75 | oad_unregister(array('ComposerAu |
a4a60 | 74 6f 6c 6f 61 64 65 72 49 6e 69 74 35 30 37 37 34 64 31 33 33 33 30 34 63 35 37 66 36 34 63 64 | toloaderInit50774d133304c57f64cd |
a4a80 | 32 30 39 65 32 34 36 61 66 33 31 61 27 2c 20 27 6c 6f 61 64 43 6c 61 73 73 4c 6f 61 64 65 72 27 | 209e246af31a',.'loadClassLoader' |
a4aa0 | 29 29 3b 0a 0a 20 20 20 20 20 20 20 20 24 75 73 65 53 74 61 74 69 63 4c 6f 61 64 65 72 20 3d 20 | ));..........$useStaticLoader.=. |
a4ac0 | 50 48 50 5f 56 45 52 53 49 4f 4e 5f 49 44 20 3e 3d 20 35 30 36 30 30 20 26 26 20 21 64 65 66 69 | PHP_VERSION_ID.>=.50600.&&.!defi |
a4ae0 | 6e 65 64 28 27 48 48 56 4d 5f 56 45 52 53 49 4f 4e 27 29 20 26 26 20 28 21 66 75 6e 63 74 69 6f | ned('HHVM_VERSION').&&.(!functio |
a4b00 | 6e 5f 65 78 69 73 74 73 28 27 7a 65 6e 64 5f 6c 6f 61 64 65 72 5f 66 69 6c 65 5f 65 6e 63 6f 64 | n_exists('zend_loader_file_encod |
a4b20 | 65 64 27 29 20 7c 7c 20 21 7a 65 6e 64 5f 6c 6f 61 64 65 72 5f 66 69 6c 65 5f 65 6e 63 6f 64 65 | ed').||.!zend_loader_file_encode |
a4b40 | 64 28 29 29 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 75 73 65 53 74 61 74 69 63 4c 6f 61 64 | d());.........if.($useStaticLoad |
a4b60 | 65 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 71 75 69 72 65 20 5f 5f 44 49 52 5f | er).{.............require.__DIR_ |
a4b80 | 5f 20 2e 20 27 2f 61 75 74 6f 6c 6f 61 64 5f 73 74 61 74 69 63 2e 70 68 70 27 3b 0a 0a 20 20 20 | _...'/autoload_static.php';..... |
a4ba0 | 20 20 20 20 20 20 20 20 20 63 61 6c 6c 5f 75 73 65 72 5f 66 75 6e 63 28 5c 43 6f 6d 70 6f 73 65 | .........call_user_func(\Compose |
a4bc0 | 72 5c 41 75 74 6f 6c 6f 61 64 5c 43 6f 6d 70 6f 73 65 72 53 74 61 74 69 63 49 6e 69 74 35 30 37 | r\Autoload\ComposerStaticInit507 |
a4be0 | 37 34 64 31 33 33 33 30 34 63 35 37 66 36 34 63 64 32 30 39 65 32 34 36 61 66 33 31 61 3a 3a 67 | 74d133304c57f64cd209e246af31a::g |
a4c00 | 65 74 49 6e 69 74 69 61 6c 69 7a 65 72 28 24 6c 6f 61 64 65 72 29 29 3b 0a 20 20 20 20 20 20 20 | etInitializer($loader));........ |
a4c20 | 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 63 6c 61 73 73 4d 61 70 20 | .}.else.{.............$classMap. |
a4c40 | 3d 20 72 65 71 75 69 72 65 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 61 75 74 6f 6c 6f 61 64 5f 63 | =.require.__DIR__...'/autoload_c |
a4c60 | 6c 61 73 73 6d 61 70 2e 70 68 70 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 63 | lassmap.php';.............if.($c |
a4c80 | 6c 61 73 73 4d 61 70 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 6f 61 64 | lassMap).{.................$load |
a4ca0 | 65 72 2d 3e 61 64 64 43 6c 61 73 73 4d 61 70 28 24 63 6c 61 73 73 4d 61 70 29 3b 0a 20 20 20 20 | er->addClassMap($classMap);..... |
a4cc0 | 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 6c 6f | ........}.........}..........$lo |
a4ce0 | 61 64 65 72 2d 3e 73 65 74 43 6c 61 73 73 4d 61 70 41 75 74 68 6f 72 69 74 61 74 69 76 65 28 74 | ader->setClassMapAuthoritative(t |
a4d00 | 72 75 65 29 3b 0a 20 20 20 20 20 20 20 20 24 6c 6f 61 64 65 72 2d 3e 72 65 67 69 73 74 65 72 28 | rue);.........$loader->register( |
a4d20 | 74 72 75 65 29 3b 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 6c 6f 61 64 65 72 3b 0a | true);..........return.$loader;. |
a4d40 | 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2f 20 61 75 74 6f 6c 6f 61 64 5f 70 73 72 34 2e | ....}.}.<?php..//.autoload_psr4. |
a4d60 | 70 68 70 20 40 67 65 6e 65 72 61 74 65 64 20 62 79 20 43 6f 6d 70 6f 73 65 72 0a 0a 24 76 65 6e | php.@generated.by.Composer..$ven |
a4d80 | 64 6f 72 44 69 72 20 3d 20 64 69 72 6e 61 6d 65 28 64 69 72 6e 61 6d 65 28 5f 5f 46 49 4c 45 5f | dorDir.=.dirname(dirname(__FILE_ |
a4da0 | 5f 29 29 3b 0a 24 62 61 73 65 44 69 72 20 3d 20 64 69 72 6e 61 6d 65 28 24 76 65 6e 64 6f 72 44 | _));.$baseDir.=.dirname($vendorD |
a4dc0 | 69 72 29 3b 0a 0a 72 65 74 75 72 6e 20 61 72 72 61 79 28 0a 20 20 20 20 27 48 75 6d 62 75 67 42 | ir);..return.array(.....'HumbugB |
a4de0 | 6f 78 33 31 31 31 5c 5c 4b 65 76 69 6e 47 48 5c 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 | ox3111\\KevinGH\\RequirementChec |
a4e00 | 6b 65 72 5c 5c 27 20 3d 3e 20 61 72 72 61 79 28 24 62 61 73 65 44 69 72 20 2e 20 27 2f 73 72 63 | ker\\'.=>.array($baseDir...'/src |
a4e20 | 27 29 2c 0a 20 20 20 20 27 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 5c 43 6f 6d 70 6f 73 65 72 | '),.....'HumbugBox3111\\Composer |
a4e40 | 5c 5c 53 65 6d 76 65 72 5c 5c 27 20 3d 3e 20 61 72 72 61 79 28 24 76 65 6e 64 6f 72 44 69 72 20 | \\Semver\\'.=>.array($vendorDir. |
a4e60 | 2e 20 27 2f 63 6f 6d 70 6f 73 65 72 2f 73 65 6d 76 65 72 2f 73 72 63 27 29 2c 0a 29 3b 0a 3c 3f | ..'/composer/semver/src'),.);.<? |
a4e80 | 70 68 70 0a 0a 2f 2f 20 61 75 74 6f 6c 6f 61 64 5f 6e 61 6d 65 73 70 61 63 65 73 2e 70 68 70 20 | php..//.autoload_namespaces.php. |
a4ea0 | 40 67 65 6e 65 72 61 74 65 64 20 62 79 20 43 6f 6d 70 6f 73 65 72 0a 0a 24 76 65 6e 64 6f 72 44 | @generated.by.Composer..$vendorD |
a4ec0 | 69 72 20 3d 20 64 69 72 6e 61 6d 65 28 64 69 72 6e 61 6d 65 28 5f 5f 46 49 4c 45 5f 5f 29 29 3b | ir.=.dirname(dirname(__FILE__)); |
a4ee0 | 0a 24 62 61 73 65 44 69 72 20 3d 20 64 69 72 6e 61 6d 65 28 24 76 65 6e 64 6f 72 44 69 72 29 3b | .$baseDir.=.dirname($vendorDir); |
a4f00 | 0a 0a 72 65 74 75 72 6e 20 61 72 72 61 79 28 0a 29 3b 0a 3c 3f 70 68 70 0a 0a 2f 2f 20 61 75 74 | ..return.array(.);.<?php..//.aut |
a4f20 | 6f 6c 6f 61 64 5f 63 6c 61 73 73 6d 61 70 2e 70 68 70 20 40 67 65 6e 65 72 61 74 65 64 20 62 79 | oload_classmap.php.@generated.by |
a4f40 | 20 43 6f 6d 70 6f 73 65 72 0a 0a 24 76 65 6e 64 6f 72 44 69 72 20 3d 20 64 69 72 6e 61 6d 65 28 | .Composer..$vendorDir.=.dirname( |
a4f60 | 64 69 72 6e 61 6d 65 28 5f 5f 46 49 4c 45 5f 5f 29 29 3b 0a 24 62 61 73 65 44 69 72 20 3d 20 64 | dirname(__FILE__));.$baseDir.=.d |
a4f80 | 69 72 6e 61 6d 65 28 24 76 65 6e 64 6f 72 44 69 72 29 3b 0a 0a 72 65 74 75 72 6e 20 61 72 72 61 | irname($vendorDir);..return.arra |
a4fa0 | 79 28 0a 20 20 20 20 27 43 6f 6d 70 6f 73 65 72 5c 5c 49 6e 73 74 61 6c 6c 65 64 56 65 72 73 69 | y(.....'Composer\\InstalledVersi |
a4fc0 | 6f 6e 73 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 63 6f 6d 70 6f 73 65 72 2f | ons'.=>.$vendorDir...'/composer/ |
a4fe0 | 49 6e 73 74 61 6c 6c 65 64 56 65 72 73 69 6f 6e 73 2e 70 68 70 27 2c 0a 20 20 20 20 27 48 75 6d | InstalledVersions.php',.....'Hum |
a5000 | 62 75 67 42 6f 78 33 31 31 31 5c 5c 43 6f 6d 70 6f 73 65 72 5c 5c 53 65 6d 76 65 72 5c 5c 43 6f | bugBox3111\\Composer\\Semver\\Co |
a5020 | 6d 70 61 72 61 74 6f 72 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 63 6f 6d 70 | mparator'.=>.$vendorDir...'/comp |
a5040 | 6f 73 65 72 2f 73 65 6d 76 65 72 2f 73 72 63 2f 43 6f 6d 70 61 72 61 74 6f 72 2e 70 68 70 27 2c | oser/semver/src/Comparator.php', |
a5060 | 0a 20 20 20 20 27 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 5c 43 6f 6d 70 6f 73 65 72 5c 5c 53 | .....'HumbugBox3111\\Composer\\S |
a5080 | 65 6d 76 65 72 5c 5c 43 6f 6d 70 69 6c 69 6e 67 4d 61 74 63 68 65 72 27 20 3d 3e 20 24 76 65 6e | emver\\CompilingMatcher'.=>.$ven |
a50a0 | 64 6f 72 44 69 72 20 2e 20 27 2f 63 6f 6d 70 6f 73 65 72 2f 73 65 6d 76 65 72 2f 73 72 63 2f 43 | dorDir...'/composer/semver/src/C |
a50c0 | 6f 6d 70 69 6c 69 6e 67 4d 61 74 63 68 65 72 2e 70 68 70 27 2c 0a 20 20 20 20 27 48 75 6d 62 75 | ompilingMatcher.php',.....'Humbu |
a50e0 | 67 42 6f 78 33 31 31 31 5c 5c 43 6f 6d 70 6f 73 65 72 5c 5c 53 65 6d 76 65 72 5c 5c 43 6f 6e 73 | gBox3111\\Composer\\Semver\\Cons |
a5100 | 74 72 61 69 6e 74 5c 5c 42 6f 75 6e 64 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 | traint\\Bound'.=>.$vendorDir...' |
a5120 | 2f 63 6f 6d 70 6f 73 65 72 2f 73 65 6d 76 65 72 2f 73 72 63 2f 43 6f 6e 73 74 72 61 69 6e 74 2f | /composer/semver/src/Constraint/ |
a5140 | 42 6f 75 6e 64 2e 70 68 70 27 2c 0a 20 20 20 20 27 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 5c | Bound.php',.....'HumbugBox3111\\ |
a5160 | 43 6f 6d 70 6f 73 65 72 5c 5c 53 65 6d 76 65 72 5c 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 5c 43 6f | Composer\\Semver\\Constraint\\Co |
a5180 | 6e 73 74 72 61 69 6e 74 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 63 6f 6d 70 | nstraint'.=>.$vendorDir...'/comp |
a51a0 | 6f 73 65 72 2f 73 65 6d 76 65 72 2f 73 72 63 2f 43 6f 6e 73 74 72 61 69 6e 74 2f 43 6f 6e 73 74 | oser/semver/src/Constraint/Const |
a51c0 | 72 61 69 6e 74 2e 70 68 70 27 2c 0a 20 20 20 20 27 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 5c | raint.php',.....'HumbugBox3111\\ |
a51e0 | 43 6f 6d 70 6f 73 65 72 5c 5c 53 65 6d 76 65 72 5c 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 5c 43 6f | Composer\\Semver\\Constraint\\Co |
a5200 | 6e 73 74 72 61 69 6e 74 49 6e 74 65 72 66 61 63 65 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 | nstraintInterface'.=>.$vendorDir |
a5220 | 20 2e 20 27 2f 63 6f 6d 70 6f 73 65 72 2f 73 65 6d 76 65 72 2f 73 72 63 2f 43 6f 6e 73 74 72 61 | ...'/composer/semver/src/Constra |
a5240 | 69 6e 74 2f 43 6f 6e 73 74 72 61 69 6e 74 49 6e 74 65 72 66 61 63 65 2e 70 68 70 27 2c 0a 20 20 | int/ConstraintInterface.php',... |
a5260 | 20 20 27 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 5c 43 6f 6d 70 6f 73 65 72 5c 5c 53 65 6d 76 | ..'HumbugBox3111\\Composer\\Semv |
a5280 | 65 72 5c 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 5c 4d 61 74 63 68 41 6c 6c 43 6f 6e 73 74 72 61 69 | er\\Constraint\\MatchAllConstrai |
a52a0 | 6e 74 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 63 6f 6d 70 6f 73 65 72 2f 73 | nt'.=>.$vendorDir...'/composer/s |
a52c0 | 65 6d 76 65 72 2f 73 72 63 2f 43 6f 6e 73 74 72 61 69 6e 74 2f 4d 61 74 63 68 41 6c 6c 43 6f 6e | emver/src/Constraint/MatchAllCon |
a52e0 | 73 74 72 61 69 6e 74 2e 70 68 70 27 2c 0a 20 20 20 20 27 48 75 6d 62 75 67 42 6f 78 33 31 31 31 | straint.php',.....'HumbugBox3111 |
a5300 | 5c 5c 43 6f 6d 70 6f 73 65 72 5c 5c 53 65 6d 76 65 72 5c 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 5c | \\Composer\\Semver\\Constraint\\ |
a5320 | 4d 61 74 63 68 4e 6f 6e 65 43 6f 6e 73 74 72 61 69 6e 74 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 | MatchNoneConstraint'.=>.$vendorD |
a5340 | 69 72 20 2e 20 27 2f 63 6f 6d 70 6f 73 65 72 2f 73 65 6d 76 65 72 2f 73 72 63 2f 43 6f 6e 73 74 | ir...'/composer/semver/src/Const |
a5360 | 72 61 69 6e 74 2f 4d 61 74 63 68 4e 6f 6e 65 43 6f 6e 73 74 72 61 69 6e 74 2e 70 68 70 27 2c 0a | raint/MatchNoneConstraint.php',. |
a5380 | 20 20 20 20 27 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 5c 43 6f 6d 70 6f 73 65 72 5c 5c 53 65 | ....'HumbugBox3111\\Composer\\Se |
a53a0 | 6d 76 65 72 5c 5c 43 6f 6e 73 74 72 61 69 6e 74 5c 5c 4d 75 6c 74 69 43 6f 6e 73 74 72 61 69 6e | mver\\Constraint\\MultiConstrain |
a53c0 | 74 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 63 6f 6d 70 6f 73 65 72 2f 73 65 | t'.=>.$vendorDir...'/composer/se |
a53e0 | 6d 76 65 72 2f 73 72 63 2f 43 6f 6e 73 74 72 61 69 6e 74 2f 4d 75 6c 74 69 43 6f 6e 73 74 72 61 | mver/src/Constraint/MultiConstra |
a5400 | 69 6e 74 2e 70 68 70 27 2c 0a 20 20 20 20 27 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 5c 43 6f | int.php',.....'HumbugBox3111\\Co |
a5420 | 6d 70 6f 73 65 72 5c 5c 53 65 6d 76 65 72 5c 5c 49 6e 74 65 72 76 61 6c 27 20 3d 3e 20 24 76 65 | mposer\\Semver\\Interval'.=>.$ve |
a5440 | 6e 64 6f 72 44 69 72 20 2e 20 27 2f 63 6f 6d 70 6f 73 65 72 2f 73 65 6d 76 65 72 2f 73 72 63 2f | ndorDir...'/composer/semver/src/ |
a5460 | 49 6e 74 65 72 76 61 6c 2e 70 68 70 27 2c 0a 20 20 20 20 27 48 75 6d 62 75 67 42 6f 78 33 31 31 | Interval.php',.....'HumbugBox311 |
a5480 | 31 5c 5c 43 6f 6d 70 6f 73 65 72 5c 5c 53 65 6d 76 65 72 5c 5c 49 6e 74 65 72 76 61 6c 73 27 20 | 1\\Composer\\Semver\\Intervals'. |
a54a0 | 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 63 6f 6d 70 6f 73 65 72 2f 73 65 6d 76 65 | =>.$vendorDir...'/composer/semve |
a54c0 | 72 2f 73 72 63 2f 49 6e 74 65 72 76 61 6c 73 2e 70 68 70 27 2c 0a 20 20 20 20 27 48 75 6d 62 75 | r/src/Intervals.php',.....'Humbu |
a54e0 | 67 42 6f 78 33 31 31 31 5c 5c 43 6f 6d 70 6f 73 65 72 5c 5c 53 65 6d 76 65 72 5c 5c 53 65 6d 76 | gBox3111\\Composer\\Semver\\Semv |
a5500 | 65 72 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 63 6f 6d 70 6f 73 65 72 2f 73 | er'.=>.$vendorDir...'/composer/s |
a5520 | 65 6d 76 65 72 2f 73 72 63 2f 53 65 6d 76 65 72 2e 70 68 70 27 2c 0a 20 20 20 20 27 48 75 6d 62 | emver/src/Semver.php',.....'Humb |
a5540 | 75 67 42 6f 78 33 31 31 31 5c 5c 43 6f 6d 70 6f 73 65 72 5c 5c 53 65 6d 76 65 72 5c 5c 56 65 72 | ugBox3111\\Composer\\Semver\\Ver |
a5560 | 73 69 6f 6e 50 61 72 73 65 72 27 20 3d 3e 20 24 76 65 6e 64 6f 72 44 69 72 20 2e 20 27 2f 63 6f | sionParser'.=>.$vendorDir...'/co |
a5580 | 6d 70 6f 73 65 72 2f 73 65 6d 76 65 72 2f 73 72 63 2f 56 65 72 73 69 6f 6e 50 61 72 73 65 72 2e | mposer/semver/src/VersionParser. |
a55a0 | 70 68 70 27 2c 0a 20 20 20 20 27 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 5c 4b 65 76 69 6e 47 | php',.....'HumbugBox3111\\KevinG |
a55c0 | 48 5c 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 5c 5c 43 68 65 63 6b 65 72 27 20 | H\\RequirementChecker\\Checker'. |
a55e0 | 3d 3e 20 24 62 61 73 65 44 69 72 20 2e 20 27 2f 73 72 63 2f 43 68 65 63 6b 65 72 2e 70 68 70 27 | =>.$baseDir...'/src/Checker.php' |
a5600 | 2c 0a 20 20 20 20 27 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 5c 4b 65 76 69 6e 47 48 5c 5c 52 | ,.....'HumbugBox3111\\KevinGH\\R |
a5620 | 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 5c 5c 49 4f 27 20 3d 3e 20 24 62 61 73 65 44 | equirementChecker\\IO'.=>.$baseD |
a5640 | 69 72 20 2e 20 27 2f 73 72 63 2f 49 4f 2e 70 68 70 27 2c 0a 20 20 20 20 27 48 75 6d 62 75 67 42 | ir...'/src/IO.php',.....'HumbugB |
a5660 | 6f 78 33 31 31 31 5c 5c 4b 65 76 69 6e 47 48 5c 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 | ox3111\\KevinGH\\RequirementChec |
a5680 | 6b 65 72 5c 5c 49 73 45 78 74 65 6e 73 69 6f 6e 46 75 6c 66 69 6c 6c 65 64 27 20 3d 3e 20 24 62 | ker\\IsExtensionFulfilled'.=>.$b |
a56a0 | 61 73 65 44 69 72 20 2e 20 27 2f 73 72 63 2f 49 73 45 78 74 65 6e 73 69 6f 6e 46 75 6c 66 69 6c | aseDir...'/src/IsExtensionFulfil |
a56c0 | 6c 65 64 2e 70 68 70 27 2c 0a 20 20 20 20 27 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 5c 4b 65 | led.php',.....'HumbugBox3111\\Ke |
a56e0 | 76 69 6e 47 48 5c 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 5c 5c 49 73 46 75 6c | vinGH\\RequirementChecker\\IsFul |
a5700 | 66 69 6c 6c 65 64 27 20 3d 3e 20 24 62 61 73 65 44 69 72 20 2e 20 27 2f 73 72 63 2f 49 73 46 75 | filled'.=>.$baseDir...'/src/IsFu |
a5720 | 6c 66 69 6c 6c 65 64 2e 70 68 70 27 2c 0a 20 20 20 20 27 48 75 6d 62 75 67 42 6f 78 33 31 31 31 | lfilled.php',.....'HumbugBox3111 |
a5740 | 5c 5c 4b 65 76 69 6e 47 48 5c 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 5c 5c 49 | \\KevinGH\\RequirementChecker\\I |
a5760 | 73 50 68 70 56 65 72 73 69 6f 6e 46 75 6c 66 69 6c 6c 65 64 27 20 3d 3e 20 24 62 61 73 65 44 69 | sPhpVersionFulfilled'.=>.$baseDi |
a5780 | 72 20 2e 20 27 2f 73 72 63 2f 49 73 50 68 70 56 65 72 73 69 6f 6e 46 75 6c 66 69 6c 6c 65 64 2e | r...'/src/IsPhpVersionFulfilled. |
a57a0 | 70 68 70 27 2c 0a 20 20 20 20 27 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 5c 4b 65 76 69 6e 47 | php',.....'HumbugBox3111\\KevinG |
a57c0 | 48 5c 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 5c 5c 50 72 69 6e 74 65 72 27 20 | H\\RequirementChecker\\Printer'. |
a57e0 | 3d 3e 20 24 62 61 73 65 44 69 72 20 2e 20 27 2f 73 72 63 2f 50 72 69 6e 74 65 72 2e 70 68 70 27 | =>.$baseDir...'/src/Printer.php' |
a5800 | 2c 0a 20 20 20 20 27 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 5c 4b 65 76 69 6e 47 48 5c 5c 52 | ,.....'HumbugBox3111\\KevinGH\\R |
a5820 | 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 5c 5c 52 65 71 75 69 72 65 6d 65 6e 74 27 20 | equirementChecker\\Requirement'. |
a5840 | 3d 3e 20 24 62 61 73 65 44 69 72 20 2e 20 27 2f 73 72 63 2f 52 65 71 75 69 72 65 6d 65 6e 74 2e | =>.$baseDir...'/src/Requirement. |
a5860 | 70 68 70 27 2c 0a 20 20 20 20 27 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 5c 4b 65 76 69 6e 47 | php',.....'HumbugBox3111\\KevinG |
a5880 | 48 5c 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 5c 5c 52 65 71 75 69 72 65 6d 65 | H\\RequirementChecker\\Requireme |
a58a0 | 6e 74 43 6f 6c 6c 65 63 74 69 6f 6e 27 20 3d 3e 20 24 62 61 73 65 44 69 72 20 2e 20 27 2f 73 72 | ntCollection'.=>.$baseDir...'/sr |
a58c0 | 63 2f 52 65 71 75 69 72 65 6d 65 6e 74 43 6f 6c 6c 65 63 74 69 6f 6e 2e 70 68 70 27 2c 0a 20 20 | c/RequirementCollection.php',... |
a58e0 | 20 20 27 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 5c 4b 65 76 69 6e 47 48 5c 5c 52 65 71 75 69 | ..'HumbugBox3111\\KevinGH\\Requi |
a5900 | 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 5c 5c 54 65 72 6d 69 6e 61 6c 27 20 3d 3e 20 24 62 61 73 | rementChecker\\Terminal'.=>.$bas |
a5920 | 65 44 69 72 20 2e 20 27 2f 73 72 63 2f 54 65 72 6d 69 6e 61 6c 2e 70 68 70 27 2c 0a 29 3b 0a 0a | eDir...'/src/Terminal.php',.);.. |
a5940 | 43 6f 70 79 72 69 67 68 74 20 28 63 29 20 4e 69 6c 73 20 41 64 65 72 6d 61 6e 6e 2c 20 4a 6f 72 | Copyright.(c).Nils.Adermann,.Jor |
a5960 | 64 69 20 42 6f 67 67 69 61 6e 6f 0a 0a 50 65 72 6d 69 73 73 69 6f 6e 20 69 73 20 68 65 72 65 62 | di.Boggiano..Permission.is.hereb |
a5980 | 79 20 67 72 61 6e 74 65 64 2c 20 66 72 65 65 20 6f 66 20 63 68 61 72 67 65 2c 20 74 6f 20 61 6e | y.granted,.free.of.charge,.to.an |
a59a0 | 79 20 70 65 72 73 6f 6e 20 6f 62 74 61 69 6e 69 6e 67 20 61 20 63 6f 70 79 0a 6f 66 20 74 68 69 | y.person.obtaining.a.copy.of.thi |
a59c0 | 73 20 73 6f 66 74 77 61 72 65 20 61 6e 64 20 61 73 73 6f 63 69 61 74 65 64 20 64 6f 63 75 6d 65 | s.software.and.associated.docume |
a59e0 | 6e 74 61 74 69 6f 6e 20 66 69 6c 65 73 20 28 74 68 65 20 22 53 6f 66 74 77 61 72 65 22 29 2c 20 | ntation.files.(the."Software"),. |
a5a00 | 74 6f 20 64 65 61 6c 0a 69 6e 20 74 68 65 20 53 6f 66 74 77 61 72 65 20 77 69 74 68 6f 75 74 20 | to.deal.in.the.Software.without. |
a5a20 | 72 65 73 74 72 69 63 74 69 6f 6e 2c 20 69 6e 63 6c 75 64 69 6e 67 20 77 69 74 68 6f 75 74 20 6c | restriction,.including.without.l |
a5a40 | 69 6d 69 74 61 74 69 6f 6e 20 74 68 65 20 72 69 67 68 74 73 0a 74 6f 20 75 73 65 2c 20 63 6f 70 | imitation.the.rights.to.use,.cop |
a5a60 | 79 2c 20 6d 6f 64 69 66 79 2c 20 6d 65 72 67 65 2c 20 70 75 62 6c 69 73 68 2c 20 64 69 73 74 72 | y,.modify,.merge,.publish,.distr |
a5a80 | 69 62 75 74 65 2c 20 73 75 62 6c 69 63 65 6e 73 65 2c 20 61 6e 64 2f 6f 72 20 73 65 6c 6c 0a 63 | ibute,.sublicense,.and/or.sell.c |
a5aa0 | 6f 70 69 65 73 20 6f 66 20 74 68 65 20 53 6f 66 74 77 61 72 65 2c 20 61 6e 64 20 74 6f 20 70 65 | opies.of.the.Software,.and.to.pe |
a5ac0 | 72 6d 69 74 20 70 65 72 73 6f 6e 73 20 74 6f 20 77 68 6f 6d 20 74 68 65 20 53 6f 66 74 77 61 72 | rmit.persons.to.whom.the.Softwar |
a5ae0 | 65 20 69 73 20 66 75 72 6e 69 73 68 65 64 0a 74 6f 20 64 6f 20 73 6f 2c 20 73 75 62 6a 65 63 74 | e.is.furnished.to.do.so,.subject |
a5b00 | 20 74 6f 20 74 68 65 20 66 6f 6c 6c 6f 77 69 6e 67 20 63 6f 6e 64 69 74 69 6f 6e 73 3a 0a 0a 54 | .to.the.following.conditions:..T |
a5b20 | 68 65 20 61 62 6f 76 65 20 63 6f 70 79 72 69 67 68 74 20 6e 6f 74 69 63 65 20 61 6e 64 20 74 68 | he.above.copyright.notice.and.th |
a5b40 | 69 73 20 70 65 72 6d 69 73 73 69 6f 6e 20 6e 6f 74 69 63 65 20 73 68 61 6c 6c 20 62 65 20 69 6e | is.permission.notice.shall.be.in |
a5b60 | 63 6c 75 64 65 64 20 69 6e 20 61 6c 6c 0a 63 6f 70 69 65 73 20 6f 72 20 73 75 62 73 74 61 6e 74 | cluded.in.all.copies.or.substant |
a5b80 | 69 61 6c 20 70 6f 72 74 69 6f 6e 73 20 6f 66 20 74 68 65 20 53 6f 66 74 77 61 72 65 2e 0a 0a 54 | ial.portions.of.the.Software...T |
a5ba0 | 48 45 20 53 4f 46 54 57 41 52 45 20 49 53 20 50 52 4f 56 49 44 45 44 20 22 41 53 20 49 53 22 2c | HE.SOFTWARE.IS.PROVIDED."AS.IS", |
a5bc0 | 20 57 49 54 48 4f 55 54 20 57 41 52 52 41 4e 54 59 20 4f 46 20 41 4e 59 20 4b 49 4e 44 2c 20 45 | .WITHOUT.WARRANTY.OF.ANY.KIND,.E |
a5be0 | 58 50 52 45 53 53 20 4f 52 0a 49 4d 50 4c 49 45 44 2c 20 49 4e 43 4c 55 44 49 4e 47 20 42 55 54 | XPRESS.OR.IMPLIED,.INCLUDING.BUT |
a5c00 | 20 4e 4f 54 20 4c 49 4d 49 54 45 44 20 54 4f 20 54 48 45 20 57 41 52 52 41 4e 54 49 45 53 20 4f | .NOT.LIMITED.TO.THE.WARRANTIES.O |
a5c20 | 46 20 4d 45 52 43 48 41 4e 54 41 42 49 4c 49 54 59 2c 0a 46 49 54 4e 45 53 53 20 46 4f 52 20 41 | F.MERCHANTABILITY,.FITNESS.FOR.A |
a5c40 | 20 50 41 52 54 49 43 55 4c 41 52 20 50 55 52 50 4f 53 45 20 41 4e 44 20 4e 4f 4e 49 4e 46 52 49 | .PARTICULAR.PURPOSE.AND.NONINFRI |
a5c60 | 4e 47 45 4d 45 4e 54 2e 20 49 4e 20 4e 4f 20 45 56 45 4e 54 20 53 48 41 4c 4c 20 54 48 45 0a 41 | NGEMENT..IN.NO.EVENT.SHALL.THE.A |
a5c80 | 55 54 48 4f 52 53 20 4f 52 20 43 4f 50 59 52 49 47 48 54 20 48 4f 4c 44 45 52 53 20 42 45 20 4c | UTHORS.OR.COPYRIGHT.HOLDERS.BE.L |
a5ca0 | 49 41 42 4c 45 20 46 4f 52 20 41 4e 59 20 43 4c 41 49 4d 2c 20 44 41 4d 41 47 45 53 20 4f 52 20 | IABLE.FOR.ANY.CLAIM,.DAMAGES.OR. |
a5cc0 | 4f 54 48 45 52 0a 4c 49 41 42 49 4c 49 54 59 2c 20 57 48 45 54 48 45 52 20 49 4e 20 41 4e 20 41 | OTHER.LIABILITY,.WHETHER.IN.AN.A |
a5ce0 | 43 54 49 4f 4e 20 4f 46 20 43 4f 4e 54 52 41 43 54 2c 20 54 4f 52 54 20 4f 52 20 4f 54 48 45 52 | CTION.OF.CONTRACT,.TORT.OR.OTHER |
a5d00 | 57 49 53 45 2c 20 41 52 49 53 49 4e 47 20 46 52 4f 4d 2c 0a 4f 55 54 20 4f 46 20 4f 52 20 49 4e | WISE,.ARISING.FROM,.OUT.OF.OR.IN |
a5d20 | 20 43 4f 4e 4e 45 43 54 49 4f 4e 20 57 49 54 48 20 54 48 45 20 53 4f 46 54 57 41 52 45 20 4f 52 | .CONNECTION.WITH.THE.SOFTWARE.OR |
a5d40 | 20 54 48 45 20 55 53 45 20 4f 52 20 4f 54 48 45 52 20 44 45 41 4c 49 4e 47 53 20 49 4e 0a 54 48 | .THE.USE.OR.OTHER.DEALINGS.IN.TH |
a5d60 | 45 20 53 4f 46 54 57 41 52 45 2e 0a 0a 3c 3f 70 68 70 0a 0a 6e 61 6d 65 73 70 61 63 65 20 48 75 | E.SOFTWARE...<?php..namespace.Hu |
a5d80 | 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 3b 0a 0a 75 73 65 20 48 75 6d 62 75 | mbugBox3111\Composer;..use.Humbu |
a5da0 | 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 56 65 72 73 69 6f 6e | gBox3111\Composer\Semver\Version |
a5dc0 | 50 61 72 73 65 72 3b 0a 63 6c 61 73 73 20 49 6e 73 74 61 6c 6c 65 64 56 65 72 73 69 6f 6e 73 0a | Parser;.class.InstalledVersions. |
a5de0 | 7b 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 24 69 6e 73 74 61 6c 6c 65 64 20 | {.....private.static.$installed. |
a5e00 | 3d 20 61 72 72 61 79 28 27 72 6f 6f 74 27 20 3d 3e 20 61 72 72 61 79 28 27 70 72 65 74 74 79 5f | =.array('root'.=>.array('pretty_ |
a5e20 | 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 33 2e 31 31 2e 31 27 2c 20 27 76 65 72 73 69 6f 6e 27 20 | version'.=>.'3.11.1',.'version'. |
a5e40 | 3d 3e 20 27 33 2e 31 31 2e 31 2e 30 27 2c 20 27 61 6c 69 61 73 65 73 27 20 3d 3e 20 61 72 72 61 | =>.'3.11.1.0',.'aliases'.=>.arra |
a5e60 | 79 28 29 2c 20 27 72 65 66 65 72 65 6e 63 65 27 20 3d 3e 20 27 38 33 35 36 37 63 34 36 38 35 32 | y(),.'reference'.=>.'83567c46852 |
a5e80 | 35 62 37 39 38 38 36 32 30 39 62 30 63 38 62 31 36 38 35 37 64 32 63 33 32 33 61 33 37 27 2c 20 | 5b79886209b0c8b16857d2c323a37',. |
a5ea0 | 27 6e 61 6d 65 27 20 3d 3e 20 27 68 75 6d 62 75 67 2f 72 65 71 75 69 72 65 6d 65 6e 74 2d 63 68 | 'name'.=>.'humbug/requirement-ch |
a5ec0 | 65 63 6b 65 72 27 29 2c 20 27 76 65 72 73 69 6f 6e 73 27 20 3d 3e 20 61 72 72 61 79 28 27 63 6f | ecker'),.'versions'.=>.array('co |
a5ee0 | 6d 70 6f 73 65 72 2f 73 65 6d 76 65 72 27 20 3d 3e 20 61 72 72 61 79 28 27 70 72 65 74 74 79 5f | mposer/semver'.=>.array('pretty_ |
a5f00 | 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 33 2e 32 2e 30 27 2c 20 27 76 65 72 73 69 6f 6e 27 20 3d | version'.=>.'3.2.0',.'version'.= |
a5f20 | 3e 20 27 33 2e 32 2e 30 2e 30 27 2c 20 27 61 6c 69 61 73 65 73 27 20 3d 3e 20 61 72 72 61 79 28 | >.'3.2.0.0',.'aliases'.=>.array( |
a5f40 | 29 2c 20 27 72 65 66 65 72 65 6e 63 65 27 20 3d 3e 20 27 64 61 37 63 65 36 36 31 34 33 31 62 31 | ),.'reference'.=>.'da7ce661431b1 |
a5f60 | 37 61 37 31 32 37 31 63 64 66 37 66 35 34 33 37 64 63 37 32 32 31 33 33 31 32 33 27 29 2c 20 27 | 7a71271cdf7f5437dc722133123'),.' |
a5f80 | 64 6f 63 74 72 69 6e 65 2f 69 6e 73 74 61 6e 74 69 61 74 6f 72 27 20 3d 3e 20 61 72 72 61 79 28 | doctrine/instantiator'.=>.array( |
a5fa0 | 27 70 72 65 74 74 79 5f 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 31 2e 34 2e 30 27 2c 20 27 76 65 | 'pretty_version'.=>.'1.4.0',.'ve |
a5fc0 | 72 73 69 6f 6e 27 20 3d 3e 20 27 31 2e 34 2e 30 2e 30 27 2c 20 27 61 6c 69 61 73 65 73 27 20 3d | rsion'.=>.'1.4.0.0',.'aliases'.= |
a5fe0 | 3e 20 61 72 72 61 79 28 29 2c 20 27 72 65 66 65 72 65 6e 63 65 27 20 3d 3e 20 27 64 35 36 62 66 | >.array(),.'reference'.=>.'d56bf |
a6000 | 36 31 30 32 39 31 35 64 65 35 37 30 32 37 37 38 66 65 32 30 66 32 64 65 33 62 32 66 65 35 37 30 | 6102915de5702778fe20f2de3b2fe570 |
a6020 | 62 35 62 27 29 2c 20 27 68 75 6d 62 75 67 2f 72 65 71 75 69 72 65 6d 65 6e 74 2d 63 68 65 63 6b | b5b'),.'humbug/requirement-check |
a6040 | 65 72 27 20 3d 3e 20 61 72 72 61 79 28 27 70 72 65 74 74 79 5f 76 65 72 73 69 6f 6e 27 20 3d 3e | er'.=>.array('pretty_version'.=> |
a6060 | 20 27 33 2e 31 31 2e 31 27 2c 20 27 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 33 2e 31 31 2e 31 2e | .'3.11.1',.'version'.=>.'3.11.1. |
a6080 | 30 27 2c 20 27 61 6c 69 61 73 65 73 27 20 3d 3e 20 61 72 72 61 79 28 29 2c 20 27 72 65 66 65 72 | 0',.'aliases'.=>.array(),.'refer |
a60a0 | 65 6e 63 65 27 20 3d 3e 20 27 38 33 35 36 37 63 34 36 38 35 32 35 62 37 39 38 38 36 32 30 39 62 | ence'.=>.'83567c468525b79886209b |
a60c0 | 30 63 38 62 31 36 38 35 37 64 32 63 33 32 33 61 33 37 27 29 2c 20 27 6d 79 63 6c 61 62 73 2f 64 | 0c8b16857d2c323a37'),.'myclabs/d |
a60e0 | 65 65 70 2d 63 6f 70 79 27 20 3d 3e 20 61 72 72 61 79 28 27 70 72 65 74 74 79 5f 76 65 72 73 69 | eep-copy'.=>.array('pretty_versi |
a6100 | 6f 6e 27 20 3d 3e 20 27 31 2e 31 30 2e 32 27 2c 20 27 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 31 | on'.=>.'1.10.2',.'version'.=>.'1 |
a6120 | 2e 31 30 2e 32 2e 30 27 2c 20 27 61 6c 69 61 73 65 73 27 20 3d 3e 20 61 72 72 61 79 28 29 2c 20 | .10.2.0',.'aliases'.=>.array(),. |
a6140 | 27 72 65 66 65 72 65 6e 63 65 27 20 3d 3e 20 27 37 37 36 66 38 33 31 31 32 34 65 39 63 36 32 65 | 'reference'.=>.'776f831124e9c62e |
a6160 | 31 61 32 63 36 30 31 65 63 63 35 32 65 37 37 36 64 38 62 62 37 32 32 30 27 2c 20 27 72 65 70 6c | 1a2c601ecc52e776d8bb7220',.'repl |
a6180 | 61 63 65 64 27 20 3d 3e 20 61 72 72 61 79 28 30 20 3d 3e 20 27 31 2e 31 30 2e 32 27 29 29 2c 20 | aced'.=>.array(0.=>.'1.10.2')),. |
a61a0 | 27 6e 69 6b 69 63 2f 70 68 70 2d 70 61 72 73 65 72 27 20 3d 3e 20 61 72 72 61 79 28 27 70 72 65 | 'nikic/php-parser'.=>.array('pre |
a61c0 | 74 74 79 5f 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 76 34 2e 31 30 2e 33 27 2c 20 27 76 65 72 73 | tty_version'.=>.'v4.10.3',.'vers |
a61e0 | 69 6f 6e 27 20 3d 3e 20 27 34 2e 31 30 2e 33 2e 30 27 2c 20 27 61 6c 69 61 73 65 73 27 20 3d 3e | ion'.=>.'4.10.3.0',.'aliases'.=> |
a6200 | 20 61 72 72 61 79 28 29 2c 20 27 72 65 66 65 72 65 6e 63 65 27 20 3d 3e 20 27 64 62 65 35 36 64 | .array(),.'reference'.=>.'dbe56d |
a6220 | 32 33 64 65 38 66 63 62 31 35 37 62 62 63 30 63 66 62 33 61 64 37 63 37 64 65 30 63 66 62 30 39 | 23de8fcb157bbc0cfb3ad7c7de0cfb09 |
a6240 | 38 34 27 29 2c 20 27 70 68 61 72 2d 69 6f 2f 6d 61 6e 69 66 65 73 74 27 20 3d 3e 20 61 72 72 61 | 84'),.'phar-io/manifest'.=>.arra |
a6260 | 79 28 27 70 72 65 74 74 79 5f 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 32 2e 30 2e 31 27 2c 20 27 | y('pretty_version'.=>.'2.0.1',.' |
a6280 | 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 32 2e 30 2e 31 2e 30 27 2c 20 27 61 6c 69 61 73 65 73 27 | version'.=>.'2.0.1.0',.'aliases' |
a62a0 | 20 3d 3e 20 61 72 72 61 79 28 29 2c 20 27 72 65 66 65 72 65 6e 63 65 27 20 3d 3e 20 27 38 35 32 | .=>.array(),.'reference'.=>.'852 |
a62c0 | 36 35 65 66 64 33 61 66 37 62 61 33 63 61 34 62 32 61 32 63 33 34 64 62 66 63 35 37 38 38 64 64 | 65efd3af7ba3ca4b2a2c34dbfc5788dd |
a62e0 | 32 39 31 33 33 27 29 2c 20 27 70 68 61 72 2d 69 6f 2f 76 65 72 73 69 6f 6e 27 20 3d 3e 20 61 72 | 29133'),.'phar-io/version'.=>.ar |
a6300 | 72 61 79 28 27 70 72 65 74 74 79 5f 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 33 2e 30 2e 33 27 2c | ray('pretty_version'.=>.'3.0.3', |
a6320 | 20 27 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 33 2e 30 2e 33 2e 30 27 2c 20 27 61 6c 69 61 73 65 | .'version'.=>.'3.0.3.0',.'aliase |
a6340 | 73 27 20 3d 3e 20 61 72 72 61 79 28 29 2c 20 27 72 65 66 65 72 65 6e 63 65 27 20 3d 3e 20 27 37 | s'.=>.array(),.'reference'.=>.'7 |
a6360 | 32 36 63 30 32 36 38 31 35 31 34 32 65 34 66 38 36 37 37 62 37 63 62 37 66 32 32 34 39 63 39 66 | 26c026815142e4f8677b7cb7f2249c9f |
a6380 | 66 62 37 65 63 61 65 27 29 2c 20 27 70 68 70 64 6f 63 75 6d 65 6e 74 6f 72 2f 72 65 66 6c 65 63 | fb7ecae'),.'phpdocumentor/reflec |
a63a0 | 74 69 6f 6e 2d 63 6f 6d 6d 6f 6e 27 20 3d 3e 20 61 72 72 61 79 28 27 70 72 65 74 74 79 5f 76 65 | tion-common'.=>.array('pretty_ve |
a63c0 | 72 73 69 6f 6e 27 20 3d 3e 20 27 32 2e 32 2e 30 27 2c 20 27 76 65 72 73 69 6f 6e 27 20 3d 3e 20 | rsion'.=>.'2.2.0',.'version'.=>. |
a63e0 | 27 32 2e 32 2e 30 2e 30 27 2c 20 27 61 6c 69 61 73 65 73 27 20 3d 3e 20 61 72 72 61 79 28 29 2c | '2.2.0.0',.'aliases'.=>.array(), |
a6400 | 20 27 72 65 66 65 72 65 6e 63 65 27 20 3d 3e 20 27 31 64 30 31 63 34 39 64 34 65 64 36 32 66 32 | .'reference'.=>.'1d01c49d4ed62f2 |
a6420 | 35 61 61 38 34 61 37 34 37 61 64 33 35 64 35 61 31 36 39 32 34 36 36 32 62 27 29 2c 20 27 70 68 | 5aa84a747ad35d5a16924662b'),.'ph |
a6440 | 70 64 6f 63 75 6d 65 6e 74 6f 72 2f 72 65 66 6c 65 63 74 69 6f 6e 2d 64 6f 63 62 6c 6f 63 6b 27 | pdocumentor/reflection-docblock' |
a6460 | 20 3d 3e 20 61 72 72 61 79 28 27 70 72 65 74 74 79 5f 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 35 | .=>.array('pretty_version'.=>.'5 |
a6480 | 2e 32 2e 32 27 2c 20 27 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 35 2e 32 2e 32 2e 30 27 2c 20 27 | .2.2',.'version'.=>.'5.2.2.0',.' |
a64a0 | 61 6c 69 61 73 65 73 27 20 3d 3e 20 61 72 72 61 79 28 29 2c 20 27 72 65 66 65 72 65 6e 63 65 27 | aliases'.=>.array(),.'reference' |
a64c0 | 20 3d 3e 20 27 30 36 39 61 37 38 35 62 32 31 34 31 66 35 62 63 66 34 39 66 33 65 33 35 33 35 34 | .=>.'069a785b2141f5bcf49f3e35354 |
a64e0 | 38 64 63 31 63 63 65 36 64 66 35 35 36 27 29 2c 20 27 70 68 70 64 6f 63 75 6d 65 6e 74 6f 72 2f | 8dc1cce6df556'),.'phpdocumentor/ |
a6500 | 74 79 70 65 2d 72 65 73 6f 6c 76 65 72 27 20 3d 3e 20 61 72 72 61 79 28 27 70 72 65 74 74 79 5f | type-resolver'.=>.array('pretty_ |
a6520 | 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 31 2e 34 2e 30 27 2c 20 27 76 65 72 73 69 6f 6e 27 20 3d | version'.=>.'1.4.0',.'version'.= |
a6540 | 3e 20 27 31 2e 34 2e 30 2e 30 27 2c 20 27 61 6c 69 61 73 65 73 27 20 3d 3e 20 61 72 72 61 79 28 | >.'1.4.0.0',.'aliases'.=>.array( |
a6560 | 29 2c 20 27 72 65 66 65 72 65 6e 63 65 27 20 3d 3e 20 27 36 61 34 36 37 62 38 39 38 39 33 32 32 | ),.'reference'.=>.'6a467b8989322 |
a6580 | 64 39 32 61 61 31 63 38 62 66 32 62 65 62 63 63 36 65 35 63 32 62 61 35 35 63 30 27 29 2c 20 27 | d92aa1c8bf2bebcc6e5c2ba55c0'),.' |
a65a0 | 70 68 70 73 70 65 63 2f 70 72 6f 70 68 65 63 79 27 20 3d 3e 20 61 72 72 61 79 28 27 70 72 65 74 | phpspec/prophecy'.=>.array('pret |
a65c0 | 74 79 5f 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 31 2e 31 32 2e 31 27 2c 20 27 76 65 72 73 69 6f | ty_version'.=>.'1.12.1',.'versio |
a65e0 | 6e 27 20 3d 3e 20 27 31 2e 31 32 2e 31 2e 30 27 2c 20 27 61 6c 69 61 73 65 73 27 20 3d 3e 20 61 | n'.=>.'1.12.1.0',.'aliases'.=>.a |
a6600 | 72 72 61 79 28 29 2c 20 27 72 65 66 65 72 65 6e 63 65 27 20 3d 3e 20 27 38 63 65 38 37 35 31 36 | rray(),.'reference'.=>.'8ce87516 |
a6620 | 62 65 37 31 61 61 65 39 62 39 35 36 66 38 31 39 30 36 61 61 66 30 33 33 38 65 30 64 38 61 32 64 | be71aae9b956f81906aaf0338e0d8a2d |
a6640 | 27 29 2c 20 27 70 68 70 75 6e 69 74 2f 70 68 70 2d 63 6f 64 65 2d 63 6f 76 65 72 61 67 65 27 20 | '),.'phpunit/php-code-coverage'. |
a6660 | 3d 3e 20 61 72 72 61 79 28 27 70 72 65 74 74 79 5f 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 39 2e | =>.array('pretty_version'.=>.'9. |
a6680 | 32 2e 35 27 2c 20 27 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 39 2e 32 2e 35 2e 30 27 2c 20 27 61 | 2.5',.'version'.=>.'9.2.5.0',.'a |
a66a0 | 6c 69 61 73 65 73 27 20 3d 3e 20 61 72 72 61 79 28 29 2c 20 27 72 65 66 65 72 65 6e 63 65 27 20 | liases'.=>.array(),.'reference'. |
a66c0 | 3d 3e 20 27 66 33 65 30 32 36 36 34 31 63 63 39 31 39 30 39 64 34 32 31 38 30 32 64 64 33 61 63 | =>.'f3e026641cc91909d421802dd3ac |
a66e0 | 37 38 32 37 65 62 66 64 39 37 65 31 27 29 2c 20 27 70 68 70 75 6e 69 74 2f 70 68 70 2d 66 69 6c | 7827ebfd97e1'),.'phpunit/php-fil |
a6700 | 65 2d 69 74 65 72 61 74 6f 72 27 20 3d 3e 20 61 72 72 61 79 28 27 70 72 65 74 74 79 5f 76 65 72 | e-iterator'.=>.array('pretty_ver |
a6720 | 73 69 6f 6e 27 20 3d 3e 20 27 33 2e 30 2e 35 27 2c 20 27 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 | sion'.=>.'3.0.5',.'version'.=>.' |
a6740 | 33 2e 30 2e 35 2e 30 27 2c 20 27 61 6c 69 61 73 65 73 27 20 3d 3e 20 61 72 72 61 79 28 29 2c 20 | 3.0.5.0',.'aliases'.=>.array(),. |
a6760 | 27 72 65 66 65 72 65 6e 63 65 27 20 3d 3e 20 27 61 61 34 62 65 38 35 37 35 66 32 36 30 37 30 62 | 'reference'.=>.'aa4be8575f26070b |
a6780 | 31 30 30 66 63 63 62 36 37 66 61 61 62 62 32 38 66 32 31 66 36 36 66 38 27 29 2c 20 27 70 68 70 | 100fccb67faabb28f21f66f8'),.'php |
a67a0 | 75 6e 69 74 2f 70 68 70 2d 69 6e 76 6f 6b 65 72 27 20 3d 3e 20 61 72 72 61 79 28 27 70 72 65 74 | unit/php-invoker'.=>.array('pret |
a67c0 | 74 79 5f 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 33 2e 31 2e 31 27 2c 20 27 76 65 72 73 69 6f 6e | ty_version'.=>.'3.1.1',.'version |
a67e0 | 27 20 3d 3e 20 27 33 2e 31 2e 31 2e 30 27 2c 20 27 61 6c 69 61 73 65 73 27 20 3d 3e 20 61 72 72 | '.=>.'3.1.1.0',.'aliases'.=>.arr |
a6800 | 61 79 28 29 2c 20 27 72 65 66 65 72 65 6e 63 65 27 20 3d 3e 20 27 35 61 31 30 31 34 37 64 30 61 | ay(),.'reference'.=>.'5a10147d0a |
a6820 | 61 66 36 35 62 35 38 39 34 30 61 30 62 37 32 66 37 31 63 39 61 63 30 34 32 33 63 63 36 37 27 29 | af65b58940a0b72f71c9ac0423cc67') |
a6840 | 2c 20 27 70 68 70 75 6e 69 74 2f 70 68 70 2d 74 65 78 74 2d 74 65 6d 70 6c 61 74 65 27 20 3d 3e | ,.'phpunit/php-text-template'.=> |
a6860 | 20 61 72 72 61 79 28 27 70 72 65 74 74 79 5f 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 32 2e 30 2e | .array('pretty_version'.=>.'2.0. |
a6880 | 34 27 2c 20 27 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 32 2e 30 2e 34 2e 30 27 2c 20 27 61 6c 69 | 4',.'version'.=>.'2.0.4.0',.'ali |
a68a0 | 61 73 65 73 27 20 3d 3e 20 61 72 72 61 79 28 29 2c 20 27 72 65 66 65 72 65 6e 63 65 27 20 3d 3e | ases'.=>.array(),.'reference'.=> |
a68c0 | 20 27 35 64 61 35 66 36 37 66 63 39 35 36 32 31 64 66 39 66 66 34 63 34 65 35 61 38 34 64 36 61 | .'5da5f67fc95621df9ff4c4e5a84d6a |
a68e0 | 38 61 32 61 63 66 37 63 32 38 27 29 2c 20 27 70 68 70 75 6e 69 74 2f 70 68 70 2d 74 69 6d 65 72 | 8a2acf7c28'),.'phpunit/php-timer |
a6900 | 27 20 3d 3e 20 61 72 72 61 79 28 27 70 72 65 74 74 79 5f 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 | '.=>.array('pretty_version'.=>.' |
a6920 | 35 2e 30 2e 33 27 2c 20 27 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 35 2e 30 2e 33 2e 30 27 2c 20 | 5.0.3',.'version'.=>.'5.0.3.0',. |
a6940 | 27 61 6c 69 61 73 65 73 27 20 3d 3e 20 61 72 72 61 79 28 29 2c 20 27 72 65 66 65 72 65 6e 63 65 | 'aliases'.=>.array(),.'reference |
a6960 | 27 20 3d 3e 20 27 35 61 36 33 63 65 32 30 65 64 31 62 35 62 66 35 37 37 38 35 30 65 32 63 34 65 | '.=>.'5a63ce20ed1b5bf577850e2c4e |
a6980 | 38 37 66 34 61 61 39 30 32 61 66 62 64 32 27 29 2c 20 27 70 68 70 75 6e 69 74 2f 70 68 70 75 6e | 87f4aa902afbd2'),.'phpunit/phpun |
a69a0 | 69 74 27 20 3d 3e 20 61 72 72 61 79 28 27 70 72 65 74 74 79 5f 76 65 72 73 69 6f 6e 27 20 3d 3e | it'.=>.array('pretty_version'.=> |
a69c0 | 20 27 39 2e 35 2e 30 27 2c 20 27 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 39 2e 35 2e 30 2e 30 27 | .'9.5.0',.'version'.=>.'9.5.0.0' |
a69e0 | 2c 20 27 61 6c 69 61 73 65 73 27 20 3d 3e 20 61 72 72 61 79 28 29 2c 20 27 72 65 66 65 72 65 6e | ,.'aliases'.=>.array(),.'referen |
a6a00 | 63 65 27 20 3d 3e 20 27 38 65 31 36 63 32 32 35 64 35 37 63 33 64 36 38 30 38 30 31 34 64 66 36 | ce'.=>.'8e16c225d57c3d6808014df6 |
a6a20 | 62 31 64 64 37 35 39 38 64 30 61 35 62 62 62 65 27 29 2c 20 27 73 65 62 61 73 74 69 61 6e 2f 63 | b1dd7598d0a5bbbe'),.'sebastian/c |
a6a40 | 6c 69 2d 70 61 72 73 65 72 27 20 3d 3e 20 61 72 72 61 79 28 27 70 72 65 74 74 79 5f 76 65 72 73 | li-parser'.=>.array('pretty_vers |
a6a60 | 69 6f 6e 27 20 3d 3e 20 27 31 2e 30 2e 31 27 2c 20 27 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 31 | ion'.=>.'1.0.1',.'version'.=>.'1 |
a6a80 | 2e 30 2e 31 2e 30 27 2c 20 27 61 6c 69 61 73 65 73 27 20 3d 3e 20 61 72 72 61 79 28 29 2c 20 27 | .0.1.0',.'aliases'.=>.array(),.' |
a6aa0 | 72 65 66 65 72 65 6e 63 65 27 20 3d 3e 20 27 34 34 32 65 37 63 37 65 36 38 37 65 34 32 61 64 63 | reference'.=>.'442e7c7e687e42adc |
a6ac0 | 30 33 34 37 30 63 37 62 36 36 38 62 63 34 62 32 34 30 32 63 30 62 32 27 29 2c 20 27 73 65 62 61 | 03470c7b668bc4b2402c0b2'),.'seba |
a6ae0 | 73 74 69 61 6e 2f 63 6f 64 65 2d 75 6e 69 74 27 20 3d 3e 20 61 72 72 61 79 28 27 70 72 65 74 74 | stian/code-unit'.=>.array('prett |
a6b00 | 79 5f 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 31 2e 30 2e 38 27 2c 20 27 76 65 72 73 69 6f 6e 27 | y_version'.=>.'1.0.8',.'version' |
a6b20 | 20 3d 3e 20 27 31 2e 30 2e 38 2e 30 27 2c 20 27 61 6c 69 61 73 65 73 27 20 3d 3e 20 61 72 72 61 | .=>.'1.0.8.0',.'aliases'.=>.arra |
a6b40 | 79 28 29 2c 20 27 72 65 66 65 72 65 6e 63 65 27 20 3d 3e 20 27 31 66 63 39 66 36 34 63 30 39 32 | y(),.'reference'.=>.'1fc9f64c092 |
a6b60 | 37 36 32 37 65 66 37 38 62 61 34 33 36 63 39 62 31 37 64 39 36 37 65 36 38 65 31 32 30 27 29 2c | 7627ef78ba436c9b17d967e68e120'), |
a6b80 | 20 27 73 65 62 61 73 74 69 61 6e 2f 63 6f 64 65 2d 75 6e 69 74 2d 72 65 76 65 72 73 65 2d 6c 6f | .'sebastian/code-unit-reverse-lo |
a6ba0 | 6f 6b 75 70 27 20 3d 3e 20 61 72 72 61 79 28 27 70 72 65 74 74 79 5f 76 65 72 73 69 6f 6e 27 20 | okup'.=>.array('pretty_version'. |
a6bc0 | 3d 3e 20 27 32 2e 30 2e 33 27 2c 20 27 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 32 2e 30 2e 33 2e | =>.'2.0.3',.'version'.=>.'2.0.3. |
a6be0 | 30 27 2c 20 27 61 6c 69 61 73 65 73 27 20 3d 3e 20 61 72 72 61 79 28 29 2c 20 27 72 65 66 65 72 | 0',.'aliases'.=>.array(),.'refer |
a6c00 | 65 6e 63 65 27 20 3d 3e 20 27 61 63 39 31 66 30 31 63 63 65 63 34 39 66 62 37 37 62 64 63 36 66 | ence'.=>.'ac91f01ccec49fb77bdc6f |
a6c20 | 64 31 65 35 34 38 62 63 37 30 66 37 66 61 61 33 65 35 27 29 2c 20 27 73 65 62 61 73 74 69 61 6e | d1e548bc70f7faa3e5'),.'sebastian |
a6c40 | 2f 63 6f 6d 70 61 72 61 74 6f 72 27 20 3d 3e 20 61 72 72 61 79 28 27 70 72 65 74 74 79 5f 76 65 | /comparator'.=>.array('pretty_ve |
a6c60 | 72 73 69 6f 6e 27 20 3d 3e 20 27 34 2e 30 2e 36 27 2c 20 27 76 65 72 73 69 6f 6e 27 20 3d 3e 20 | rsion'.=>.'4.0.6',.'version'.=>. |
a6c80 | 27 34 2e 30 2e 36 2e 30 27 2c 20 27 61 6c 69 61 73 65 73 27 20 3d 3e 20 61 72 72 61 79 28 29 2c | '4.0.6.0',.'aliases'.=>.array(), |
a6ca0 | 20 27 72 65 66 65 72 65 6e 63 65 27 20 3d 3e 20 27 35 35 66 34 32 36 31 39 38 39 65 35 34 36 64 | .'reference'.=>.'55f4261989e546d |
a6cc0 | 63 31 31 32 32 35 38 63 37 61 37 35 39 33 35 61 38 31 61 37 63 65 33 38 32 27 29 2c 20 27 73 65 | c112258c7a75935a81a7ce382'),.'se |
a6ce0 | 62 61 73 74 69 61 6e 2f 63 6f 6d 70 6c 65 78 69 74 79 27 20 3d 3e 20 61 72 72 61 79 28 27 70 72 | bastian/complexity'.=>.array('pr |
a6d00 | 65 74 74 79 5f 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 32 2e 30 2e 32 27 2c 20 27 76 65 72 73 69 | etty_version'.=>.'2.0.2',.'versi |
a6d20 | 6f 6e 27 20 3d 3e 20 27 32 2e 30 2e 32 2e 30 27 2c 20 27 61 6c 69 61 73 65 73 27 20 3d 3e 20 61 | on'.=>.'2.0.2.0',.'aliases'.=>.a |
a6d40 | 72 72 61 79 28 29 2c 20 27 72 65 66 65 72 65 6e 63 65 27 20 3d 3e 20 27 37 33 39 62 33 35 65 35 | rray(),.'reference'.=>.'739b35e5 |
a6d60 | 33 33 37 39 39 30 30 63 63 39 61 63 33 32 37 62 32 31 34 37 38 36 37 62 38 62 36 65 66 64 38 38 | 3379900cc9ac327b2147867b8b6efd88 |
a6d80 | 27 29 2c 20 27 73 65 62 61 73 74 69 61 6e 2f 64 69 66 66 27 20 3d 3e 20 61 72 72 61 79 28 27 70 | '),.'sebastian/diff'.=>.array('p |
a6da0 | 72 65 74 74 79 5f 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 34 2e 30 2e 34 27 2c 20 27 76 65 72 73 | retty_version'.=>.'4.0.4',.'vers |
a6dc0 | 69 6f 6e 27 20 3d 3e 20 27 34 2e 30 2e 34 2e 30 27 2c 20 27 61 6c 69 61 73 65 73 27 20 3d 3e 20 | ion'.=>.'4.0.4.0',.'aliases'.=>. |
a6de0 | 61 72 72 61 79 28 29 2c 20 27 72 65 66 65 72 65 6e 63 65 27 20 3d 3e 20 27 33 34 36 31 65 33 66 | array(),.'reference'.=>.'3461e3f |
a6e00 | 63 63 63 37 63 66 64 66 63 32 37 32 30 62 65 39 31 30 64 33 62 64 37 33 63 36 39 62 65 35 39 30 | ccc7cfdfc2720be910d3bd73c69be590 |
a6e20 | 64 27 29 2c 20 27 73 65 62 61 73 74 69 61 6e 2f 65 6e 76 69 72 6f 6e 6d 65 6e 74 27 20 3d 3e 20 | d'),.'sebastian/environment'.=>. |
a6e40 | 61 72 72 61 79 28 27 70 72 65 74 74 79 5f 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 35 2e 31 2e 33 | array('pretty_version'.=>.'5.1.3 |
a6e60 | 27 2c 20 27 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 35 2e 31 2e 33 2e 30 27 2c 20 27 61 6c 69 61 | ',.'version'.=>.'5.1.3.0',.'alia |
a6e80 | 73 65 73 27 20 3d 3e 20 61 72 72 61 79 28 29 2c 20 27 72 65 66 65 72 65 6e 63 65 27 20 3d 3e 20 | ses'.=>.array(),.'reference'.=>. |
a6ea0 | 27 33 38 38 62 36 63 65 64 31 36 63 61 61 37 35 31 30 33 30 66 36 61 36 39 65 35 38 38 32 39 39 | '388b6ced16caa751030f6a69e588299 |
a6ec0 | 66 61 30 39 32 30 30 61 63 27 29 2c 20 27 73 65 62 61 73 74 69 61 6e 2f 65 78 70 6f 72 74 65 72 | fa09200ac'),.'sebastian/exporter |
a6ee0 | 27 20 3d 3e 20 61 72 72 61 79 28 27 70 72 65 74 74 79 5f 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 | '.=>.array('pretty_version'.=>.' |
a6f00 | 34 2e 30 2e 33 27 2c 20 27 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 34 2e 30 2e 33 2e 30 27 2c 20 | 4.0.3',.'version'.=>.'4.0.3.0',. |
a6f20 | 27 61 6c 69 61 73 65 73 27 20 3d 3e 20 61 72 72 61 79 28 29 2c 20 27 72 65 66 65 72 65 6e 63 65 | 'aliases'.=>.array(),.'reference |
a6f40 | 27 20 3d 3e 20 27 64 38 39 63 63 39 38 37 36 31 62 38 63 62 35 61 31 61 32 33 35 61 36 62 37 30 | '.=>.'d89cc98761b8cb5a1a235a6b70 |
a6f60 | 33 61 65 35 30 64 33 34 30 38 30 65 36 35 27 29 2c 20 27 73 65 62 61 73 74 69 61 6e 2f 67 6c 6f | 3ae50d34080e65'),.'sebastian/glo |
a6f80 | 62 61 6c 2d 73 74 61 74 65 27 20 3d 3e 20 61 72 72 61 79 28 27 70 72 65 74 74 79 5f 76 65 72 73 | bal-state'.=>.array('pretty_vers |
a6fa0 | 69 6f 6e 27 20 3d 3e 20 27 35 2e 30 2e 32 27 2c 20 27 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 35 | ion'.=>.'5.0.2',.'version'.=>.'5 |
a6fc0 | 2e 30 2e 32 2e 30 27 2c 20 27 61 6c 69 61 73 65 73 27 20 3d 3e 20 61 72 72 61 79 28 29 2c 20 27 | .0.2.0',.'aliases'.=>.array(),.' |
a6fe0 | 72 65 66 65 72 65 6e 63 65 27 20 3d 3e 20 27 61 39 30 63 63 62 64 64 66 66 61 30 36 37 62 35 31 | reference'.=>.'a90ccbddffa067b51 |
a7000 | 66 35 37 34 64 65 61 36 65 62 32 35 64 35 36 38 30 38 33 39 34 35 35 27 29 2c 20 27 73 65 62 61 | f574dea6eb25d5680839455'),.'seba |
a7020 | 73 74 69 61 6e 2f 6c 69 6e 65 73 2d 6f 66 2d 63 6f 64 65 27 20 3d 3e 20 61 72 72 61 79 28 27 70 | stian/lines-of-code'.=>.array('p |
a7040 | 72 65 74 74 79 5f 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 31 2e 30 2e 33 27 2c 20 27 76 65 72 73 | retty_version'.=>.'1.0.3',.'vers |
a7060 | 69 6f 6e 27 20 3d 3e 20 27 31 2e 30 2e 33 2e 30 27 2c 20 27 61 6c 69 61 73 65 73 27 20 3d 3e 20 | ion'.=>.'1.0.3.0',.'aliases'.=>. |
a7080 | 61 72 72 61 79 28 29 2c 20 27 72 65 66 65 72 65 6e 63 65 27 20 3d 3e 20 27 63 31 63 32 65 39 39 | array(),.'reference'.=>.'c1c2e99 |
a70a0 | 37 61 61 33 31 34 36 39 38 33 65 64 38 38 38 61 64 30 38 62 31 35 34 37 30 61 32 65 32 32 65 63 | 7aa3146983ed888ad08b15470a2e22ec |
a70c0 | 63 27 29 2c 20 27 73 65 62 61 73 74 69 61 6e 2f 6f 62 6a 65 63 74 2d 65 6e 75 6d 65 72 61 74 6f | c'),.'sebastian/object-enumerato |
a70e0 | 72 27 20 3d 3e 20 61 72 72 61 79 28 27 70 72 65 74 74 79 5f 76 65 72 73 69 6f 6e 27 20 3d 3e 20 | r'.=>.array('pretty_version'.=>. |
a7100 | 27 34 2e 30 2e 34 27 2c 20 27 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 34 2e 30 2e 34 2e 30 27 2c | '4.0.4',.'version'.=>.'4.0.4.0', |
a7120 | 20 27 61 6c 69 61 73 65 73 27 20 3d 3e 20 61 72 72 61 79 28 29 2c 20 27 72 65 66 65 72 65 6e 63 | .'aliases'.=>.array(),.'referenc |
a7140 | 65 27 20 3d 3e 20 27 35 63 39 65 65 61 63 34 31 62 32 39 30 61 33 37 31 32 64 38 38 38 35 31 35 | e'.=>.'5c9eeac41b290a3712d888515 |
a7160 | 31 38 38 32 35 61 64 37 38 66 34 35 63 37 31 27 29 2c 20 27 73 65 62 61 73 74 69 61 6e 2f 6f 62 | 18825ad78f45c71'),.'sebastian/ob |
a7180 | 6a 65 63 74 2d 72 65 66 6c 65 63 74 6f 72 27 20 3d 3e 20 61 72 72 61 79 28 27 70 72 65 74 74 79 | ject-reflector'.=>.array('pretty |
a71a0 | 5f 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 32 2e 30 2e 34 27 2c 20 27 76 65 72 73 69 6f 6e 27 20 | _version'.=>.'2.0.4',.'version'. |
a71c0 | 3d 3e 20 27 32 2e 30 2e 34 2e 30 27 2c 20 27 61 6c 69 61 73 65 73 27 20 3d 3e 20 61 72 72 61 79 | =>.'2.0.4.0',.'aliases'.=>.array |
a71e0 | 28 29 2c 20 27 72 65 66 65 72 65 6e 63 65 27 20 3d 3e 20 27 62 34 66 34 37 39 65 62 64 62 66 36 | (),.'reference'.=>.'b4f479ebdbf6 |
a7200 | 33 61 63 36 30 35 64 31 38 33 65 63 65 31 37 64 38 64 37 66 65 34 39 63 31 35 63 37 27 29 2c 20 | 3ac605d183ece17d8d7fe49c15c7'),. |
a7220 | 27 73 65 62 61 73 74 69 61 6e 2f 72 65 63 75 72 73 69 6f 6e 2d 63 6f 6e 74 65 78 74 27 20 3d 3e | 'sebastian/recursion-context'.=> |
a7240 | 20 61 72 72 61 79 28 27 70 72 65 74 74 79 5f 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 34 2e 30 2e | .array('pretty_version'.=>.'4.0. |
a7260 | 34 27 2c 20 27 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 34 2e 30 2e 34 2e 30 27 2c 20 27 61 6c 69 | 4',.'version'.=>.'4.0.4.0',.'ali |
a7280 | 61 73 65 73 27 20 3d 3e 20 61 72 72 61 79 28 29 2c 20 27 72 65 66 65 72 65 6e 63 65 27 20 3d 3e | ases'.=>.array(),.'reference'.=> |
a72a0 | 20 27 63 64 39 64 38 63 66 33 63 35 38 30 34 64 65 34 33 34 31 63 32 38 33 65 64 37 38 37 66 30 | .'cd9d8cf3c5804de4341c283ed787f0 |
a72c0 | 39 39 66 35 35 30 36 31 37 32 27 29 2c 20 27 73 65 62 61 73 74 69 61 6e 2f 72 65 73 6f 75 72 63 | 99f5506172'),.'sebastian/resourc |
a72e0 | 65 2d 6f 70 65 72 61 74 69 6f 6e 73 27 20 3d 3e 20 61 72 72 61 79 28 27 70 72 65 74 74 79 5f 76 | e-operations'.=>.array('pretty_v |
a7300 | 65 72 73 69 6f 6e 27 20 3d 3e 20 27 33 2e 30 2e 33 27 2c 20 27 76 65 72 73 69 6f 6e 27 20 3d 3e | ersion'.=>.'3.0.3',.'version'.=> |
a7320 | 20 27 33 2e 30 2e 33 2e 30 27 2c 20 27 61 6c 69 61 73 65 73 27 20 3d 3e 20 61 72 72 61 79 28 29 | .'3.0.3.0',.'aliases'.=>.array() |
a7340 | 2c 20 27 72 65 66 65 72 65 6e 63 65 27 20 3d 3e 20 27 30 66 34 34 34 33 63 62 33 61 31 64 39 32 | ,.'reference'.=>.'0f4443cb3a1d92 |
a7360 | 63 65 38 30 39 38 39 39 37 35 33 62 63 30 64 35 64 35 61 38 64 64 31 39 61 38 27 29 2c 20 27 73 | ce809899753bc0d5d5a8dd19a8'),.'s |
a7380 | 65 62 61 73 74 69 61 6e 2f 74 79 70 65 27 20 3d 3e 20 61 72 72 61 79 28 27 70 72 65 74 74 79 5f | ebastian/type'.=>.array('pretty_ |
a73a0 | 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 32 2e 33 2e 31 27 2c 20 27 76 65 72 73 69 6f 6e 27 20 3d | version'.=>.'2.3.1',.'version'.= |
a73c0 | 3e 20 27 32 2e 33 2e 31 2e 30 27 2c 20 27 61 6c 69 61 73 65 73 27 20 3d 3e 20 61 72 72 61 79 28 | >.'2.3.1.0',.'aliases'.=>.array( |
a73e0 | 29 2c 20 27 72 65 66 65 72 65 6e 63 65 27 20 3d 3e 20 27 38 31 63 64 36 31 61 62 37 62 62 66 32 | ),.'reference'.=>.'81cd61ab7bbf2 |
a7400 | 64 65 37 34 34 61 62 61 30 65 61 36 31 66 61 65 33 32 66 37 32 31 64 66 33 64 32 27 29 2c 20 27 | de744aba0ea61fae32f721df3d2'),.' |
a7420 | 73 65 62 61 73 74 69 61 6e 2f 76 65 72 73 69 6f 6e 27 20 3d 3e 20 61 72 72 61 79 28 27 70 72 65 | sebastian/version'.=>.array('pre |
a7440 | 74 74 79 5f 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 33 2e 30 2e 32 27 2c 20 27 76 65 72 73 69 6f | tty_version'.=>.'3.0.2',.'versio |
a7460 | 6e 27 20 3d 3e 20 27 33 2e 30 2e 32 2e 30 27 2c 20 27 61 6c 69 61 73 65 73 27 20 3d 3e 20 61 72 | n'.=>.'3.0.2.0',.'aliases'.=>.ar |
a7480 | 72 61 79 28 29 2c 20 27 72 65 66 65 72 65 6e 63 65 27 20 3d 3e 20 27 63 36 63 31 30 32 32 33 35 | ray(),.'reference'.=>.'c6c102235 |
a74a0 | 31 61 39 30 31 35 31 32 31 37 30 31 31 38 34 33 36 63 37 36 34 65 34 37 33 66 36 64 65 38 63 27 | 1a901512170118436c764e473f6de8c' |
a74c0 | 29 2c 20 27 73 79 6d 66 6f 6e 79 2f 70 6f 6c 79 66 69 6c 6c 2d 63 74 79 70 65 27 20 3d 3e 20 61 | ),.'symfony/polyfill-ctype'.=>.a |
a74e0 | 72 72 61 79 28 27 70 72 65 74 74 79 5f 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 76 31 2e 32 30 2e | rray('pretty_version'.=>.'v1.20. |
a7500 | 30 27 2c 20 27 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 31 2e 32 30 2e 30 2e 30 27 2c 20 27 61 6c | 0',.'version'.=>.'1.20.0.0',.'al |
a7520 | 69 61 73 65 73 27 20 3d 3e 20 61 72 72 61 79 28 29 2c 20 27 72 65 66 65 72 65 6e 63 65 27 20 3d | iases'.=>.array(),.'reference'.= |
a7540 | 3e 20 27 66 34 62 61 30 38 39 61 35 62 36 33 36 36 65 34 35 33 39 37 31 64 33 61 61 64 35 66 65 | >.'f4ba089a5b6366e453971d3aad5fe |
a7560 | 38 65 38 39 37 62 33 37 66 34 31 27 29 2c 20 27 74 68 65 73 65 65 72 2f 74 6f 6b 65 6e 69 7a 65 | 8e897b37f41'),.'theseer/tokenize |
a7580 | 72 27 20 3d 3e 20 61 72 72 61 79 28 27 70 72 65 74 74 79 5f 76 65 72 73 69 6f 6e 27 20 3d 3e 20 | r'.=>.array('pretty_version'.=>. |
a75a0 | 27 31 2e 32 2e 30 27 2c 20 27 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 31 2e 32 2e 30 2e 30 27 2c | '1.2.0',.'version'.=>.'1.2.0.0', |
a75c0 | 20 27 61 6c 69 61 73 65 73 27 20 3d 3e 20 61 72 72 61 79 28 29 2c 20 27 72 65 66 65 72 65 6e 63 | .'aliases'.=>.array(),.'referenc |
a75e0 | 65 27 20 3d 3e 20 27 37 35 61 36 33 63 33 33 61 38 35 37 37 36 30 38 34 34 34 32 34 36 30 37 35 | e'.=>.'75a63c33a8577608444246075 |
a7600 | 65 61 30 61 66 30 64 30 35 32 65 34 35 32 61 27 29 2c 20 27 77 65 62 6d 6f 7a 61 72 74 2f 61 73 | ea0af0d052e452a'),.'webmozart/as |
a7620 | 73 65 72 74 27 20 3d 3e 20 61 72 72 61 79 28 27 70 72 65 74 74 79 5f 76 65 72 73 69 6f 6e 27 20 | sert'.=>.array('pretty_version'. |
a7640 | 3d 3e 20 27 31 2e 39 2e 31 27 2c 20 27 76 65 72 73 69 6f 6e 27 20 3d 3e 20 27 31 2e 39 2e 31 2e | =>.'1.9.1',.'version'.=>.'1.9.1. |
a7660 | 30 27 2c 20 27 61 6c 69 61 73 65 73 27 20 3d 3e 20 61 72 72 61 79 28 29 2c 20 27 72 65 66 65 72 | 0',.'aliases'.=>.array(),.'refer |
a7680 | 65 6e 63 65 27 20 3d 3e 20 27 62 61 66 63 36 39 63 61 65 62 34 64 34 39 63 33 39 66 64 30 37 37 | ence'.=>.'bafc69caeb4d49c39fd077 |
a76a0 | 39 30 38 36 63 30 33 61 33 37 33 38 63 62 62 33 38 39 27 29 29 29 3b 0a 20 20 20 20 70 75 62 6c | 9086c03a3738cbb389')));.....publ |
a76c0 | 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 49 6e 73 74 61 6c 6c 65 64 50 | ic.static.function.getInstalledP |
a76e0 | 61 63 6b 61 67 65 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 5c | ackages().....{.........return.\ |
a7700 | 61 72 72 61 79 5f 6b 65 79 73 28 73 65 6c 66 3a 3a 24 69 6e 73 74 61 6c 6c 65 64 5b 27 76 65 72 | array_keys(self::$installed['ver |
a7720 | 73 69 6f 6e 73 27 5d 29 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 | sions']);.....}.....public.stati |
a7740 | 63 20 66 75 6e 63 74 69 6f 6e 20 69 73 49 6e 73 74 61 6c 6c 65 64 28 24 70 61 63 6b 61 67 65 4e | c.function.isInstalled($packageN |
a7760 | 61 6d 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 69 73 73 65 74 28 | ame).....{.........return.isset( |
a7780 | 73 65 6c 66 3a 3a 24 69 6e 73 74 61 6c 6c 65 64 5b 27 76 65 72 73 69 6f 6e 73 27 5d 5b 24 70 61 | self::$installed['versions'][$pa |
a77a0 | 63 6b 61 67 65 4e 61 6d 65 5d 29 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 | ckageName]);.....}.....public.st |
a77c0 | 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 61 74 69 73 66 69 65 73 28 5c 48 75 6d 62 75 67 42 | atic.function.satisfies(\HumbugB |
a77e0 | 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 56 65 72 73 69 6f 6e 50 61 | ox3111\Composer\Semver\VersionPa |
a7800 | 72 73 65 72 20 24 70 61 72 73 65 72 2c 20 24 70 61 63 6b 61 67 65 4e 61 6d 65 2c 20 24 63 6f 6e | rser.$parser,.$packageName,.$con |
a7820 | 73 74 72 61 69 6e 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 63 6f 6e 73 74 72 61 69 | straint).....{.........$constrai |
a7840 | 6e 74 20 3d 20 24 70 61 72 73 65 72 2d 3e 70 61 72 73 65 43 6f 6e 73 74 72 61 69 6e 74 73 28 24 | nt.=.$parser->parseConstraints($ |
a7860 | 63 6f 6e 73 74 72 61 69 6e 74 29 3b 0a 20 20 20 20 20 20 20 20 24 70 72 6f 76 69 64 65 64 20 3d | constraint);.........$provided.= |
a7880 | 20 24 70 61 72 73 65 72 2d 3e 70 61 72 73 65 43 6f 6e 73 74 72 61 69 6e 74 73 28 73 65 6c 66 3a | .$parser->parseConstraints(self: |
a78a0 | 3a 67 65 74 56 65 72 73 69 6f 6e 52 61 6e 67 65 73 28 24 70 61 63 6b 61 67 65 4e 61 6d 65 29 29 | :getVersionRanges($packageName)) |
a78c0 | 3b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 70 72 6f 76 69 64 65 64 2d 3e 6d 61 74 63 | ;.........return.$provided->matc |
a78e0 | 68 65 73 28 24 63 6f 6e 73 74 72 61 69 6e 74 29 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c | hes($constraint);.....}.....publ |
a7900 | 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 56 65 72 73 69 6f 6e 52 61 6e | ic.static.function.getVersionRan |
a7920 | 67 65 73 28 24 70 61 63 6b 61 67 65 4e 61 6d 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | ges($packageName).....{......... |
a7940 | 69 66 20 28 21 69 73 73 65 74 28 73 65 6c 66 3a 3a 24 69 6e 73 74 61 6c 6c 65 64 5b 27 76 65 72 | if.(!isset(self::$installed['ver |
a7960 | 73 69 6f 6e 73 27 5d 5b 24 70 61 63 6b 61 67 65 4e 61 6d 65 5d 29 29 20 7b 0a 20 20 20 20 20 20 | sions'][$packageName])).{....... |
a7980 | 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 5c 4f 75 74 4f 66 42 6f 75 6e 64 73 45 78 63 65 | ......throw.new.\OutOfBoundsExce |
a79a0 | 70 74 69 6f 6e 28 27 50 61 63 6b 61 67 65 20 22 27 20 2e 20 24 70 61 63 6b 61 67 65 4e 61 6d 65 | ption('Package."'...$packageName |
a79c0 | 20 2e 20 27 22 20 69 73 20 6e 6f 74 20 69 6e 73 74 61 6c 6c 65 64 27 29 3b 0a 20 20 20 20 20 20 | ...'".is.not.installed');....... |
a79e0 | 20 20 7d 0a 20 20 20 20 20 20 20 20 24 72 61 6e 67 65 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 | ..}.........$ranges.=.array();.. |
a7a00 | 20 20 20 20 20 20 20 69 66 20 28 69 73 73 65 74 28 73 65 6c 66 3a 3a 24 69 6e 73 74 61 6c 6c 65 | .......if.(isset(self::$installe |
a7a20 | 64 5b 27 76 65 72 73 69 6f 6e 73 27 5d 5b 24 70 61 63 6b 61 67 65 4e 61 6d 65 5d 5b 27 70 72 65 | d['versions'][$packageName]['pre |
a7a40 | 74 74 79 5f 76 65 72 73 69 6f 6e 27 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 72 | tty_version'])).{.............$r |
a7a60 | 61 6e 67 65 73 5b 5d 20 3d 20 73 65 6c 66 3a 3a 24 69 6e 73 74 61 6c 6c 65 64 5b 27 76 65 72 73 | anges[].=.self::$installed['vers |
a7a80 | 69 6f 6e 73 27 5d 5b 24 70 61 63 6b 61 67 65 4e 61 6d 65 5d 5b 27 70 72 65 74 74 79 5f 76 65 72 | ions'][$packageName]['pretty_ver |
a7aa0 | 73 69 6f 6e 27 5d 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 5c 61 | sion'];.........}.........if.(\a |
a7ac0 | 72 72 61 79 5f 6b 65 79 5f 65 78 69 73 74 73 28 27 61 6c 69 61 73 65 73 27 2c 20 73 65 6c 66 3a | rray_key_exists('aliases',.self: |
a7ae0 | 3a 24 69 6e 73 74 61 6c 6c 65 64 5b 27 76 65 72 73 69 6f 6e 73 27 5d 5b 24 70 61 63 6b 61 67 65 | :$installed['versions'][$package |
a7b00 | 4e 61 6d 65 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 72 61 6e 67 65 73 20 3d 20 | Name])).{.............$ranges.=. |
a7b20 | 5c 61 72 72 61 79 5f 6d 65 72 67 65 28 24 72 61 6e 67 65 73 2c 20 73 65 6c 66 3a 3a 24 69 6e 73 | \array_merge($ranges,.self::$ins |
a7b40 | 74 61 6c 6c 65 64 5b 27 76 65 72 73 69 6f 6e 73 27 5d 5b 24 70 61 63 6b 61 67 65 4e 61 6d 65 5d | talled['versions'][$packageName] |
a7b60 | 5b 27 61 6c 69 61 73 65 73 27 5d 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 | ['aliases']);.........}......... |
a7b80 | 69 66 20 28 5c 61 72 72 61 79 5f 6b 65 79 5f 65 78 69 73 74 73 28 27 72 65 70 6c 61 63 65 64 27 | if.(\array_key_exists('replaced' |
a7ba0 | 2c 20 73 65 6c 66 3a 3a 24 69 6e 73 74 61 6c 6c 65 64 5b 27 76 65 72 73 69 6f 6e 73 27 5d 5b 24 | ,.self::$installed['versions'][$ |
a7bc0 | 70 61 63 6b 61 67 65 4e 61 6d 65 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 72 61 | packageName])).{.............$ra |
a7be0 | 6e 67 65 73 20 3d 20 5c 61 72 72 61 79 5f 6d 65 72 67 65 28 24 72 61 6e 67 65 73 2c 20 73 65 6c | nges.=.\array_merge($ranges,.sel |
a7c00 | 66 3a 3a 24 69 6e 73 74 61 6c 6c 65 64 5b 27 76 65 72 73 69 6f 6e 73 27 5d 5b 24 70 61 63 6b 61 | f::$installed['versions'][$packa |
a7c20 | 67 65 4e 61 6d 65 5d 5b 27 72 65 70 6c 61 63 65 64 27 5d 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a | geName]['replaced']);.........}. |
a7c40 | 20 20 20 20 20 20 20 20 69 66 20 28 5c 61 72 72 61 79 5f 6b 65 79 5f 65 78 69 73 74 73 28 27 70 | ........if.(\array_key_exists('p |
a7c60 | 72 6f 76 69 64 65 64 27 2c 20 73 65 6c 66 3a 3a 24 69 6e 73 74 61 6c 6c 65 64 5b 27 76 65 72 73 | rovided',.self::$installed['vers |
a7c80 | 69 6f 6e 73 27 5d 5b 24 70 61 63 6b 61 67 65 4e 61 6d 65 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 | ions'][$packageName])).{........ |
a7ca0 | 20 20 20 20 20 24 72 61 6e 67 65 73 20 3d 20 5c 61 72 72 61 79 5f 6d 65 72 67 65 28 24 72 61 6e | .....$ranges.=.\array_merge($ran |
a7cc0 | 67 65 73 2c 20 73 65 6c 66 3a 3a 24 69 6e 73 74 61 6c 6c 65 64 5b 27 76 65 72 73 69 6f 6e 73 27 | ges,.self::$installed['versions' |
a7ce0 | 5d 5b 24 70 61 63 6b 61 67 65 4e 61 6d 65 5d 5b 27 70 72 6f 76 69 64 65 64 27 5d 29 3b 0a 20 20 | ][$packageName]['provided']);... |
a7d00 | 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 5c 69 6d 70 6c 6f 64 65 28 | ......}.........return.\implode( |
a7d20 | 27 20 7c 7c 20 27 2c 20 24 72 61 6e 67 65 73 29 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c | '.||.',.$ranges);.....}.....publ |
a7d40 | 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 56 65 72 73 69 6f 6e 28 24 70 | ic.static.function.getVersion($p |
a7d60 | 61 63 6b 61 67 65 4e 61 6d 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 69 | ackageName).....{.........if.(!i |
a7d80 | 73 73 65 74 28 73 65 6c 66 3a 3a 24 69 6e 73 74 61 6c 6c 65 64 5b 27 76 65 72 73 69 6f 6e 73 27 | sset(self::$installed['versions' |
a7da0 | 5d 5b 24 70 61 63 6b 61 67 65 4e 61 6d 65 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ][$packageName])).{............. |
a7dc0 | 74 68 72 6f 77 20 6e 65 77 20 5c 4f 75 74 4f 66 42 6f 75 6e 64 73 45 78 63 65 70 74 69 6f 6e 28 | throw.new.\OutOfBoundsException( |
a7de0 | 27 50 61 63 6b 61 67 65 20 22 27 20 2e 20 24 70 61 63 6b 61 67 65 4e 61 6d 65 20 2e 20 27 22 20 | 'Package."'...$packageName...'". |
a7e00 | 69 73 20 6e 6f 74 20 69 6e 73 74 61 6c 6c 65 64 27 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 | is.not.installed');.........}... |
a7e20 | 20 20 20 20 20 20 69 66 20 28 21 69 73 73 65 74 28 73 65 6c 66 3a 3a 24 69 6e 73 74 61 6c 6c 65 | ......if.(!isset(self::$installe |
a7e40 | 64 5b 27 76 65 72 73 69 6f 6e 73 27 5d 5b 24 70 61 63 6b 61 67 65 4e 61 6d 65 5d 5b 27 76 65 72 | d['versions'][$packageName]['ver |
a7e60 | 73 69 6f 6e 27 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6e 75 | sion'])).{.............return.nu |
a7e80 | 6c 6c 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 65 6c | ll;.........}.........return.sel |
a7ea0 | 66 3a 3a 24 69 6e 73 74 61 6c 6c 65 64 5b 27 76 65 72 73 69 6f 6e 73 27 5d 5b 24 70 61 63 6b 61 | f::$installed['versions'][$packa |
a7ec0 | 67 65 4e 61 6d 65 5d 5b 27 76 65 72 73 69 6f 6e 27 5d 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 | geName]['version'];.....}.....pu |
a7ee0 | 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 50 72 65 74 74 79 56 65 | blic.static.function.getPrettyVe |
a7f00 | 72 73 69 6f 6e 28 24 70 61 63 6b 61 67 65 4e 61 6d 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 | rsion($packageName).....{....... |
a7f20 | 20 20 69 66 20 28 21 69 73 73 65 74 28 73 65 6c 66 3a 3a 24 69 6e 73 74 61 6c 6c 65 64 5b 27 76 | ..if.(!isset(self::$installed['v |
a7f40 | 65 72 73 69 6f 6e 73 27 5d 5b 24 70 61 63 6b 61 67 65 4e 61 6d 65 5d 29 29 20 7b 0a 20 20 20 20 | ersions'][$packageName])).{..... |
a7f60 | 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 5c 4f 75 74 4f 66 42 6f 75 6e 64 73 45 78 | ........throw.new.\OutOfBoundsEx |
a7f80 | 63 65 70 74 69 6f 6e 28 27 50 61 63 6b 61 67 65 20 22 27 20 2e 20 24 70 61 63 6b 61 67 65 4e 61 | ception('Package."'...$packageNa |
a7fa0 | 6d 65 20 2e 20 27 22 20 69 73 20 6e 6f 74 20 69 6e 73 74 61 6c 6c 65 64 27 29 3b 0a 20 20 20 20 | me...'".is.not.installed');..... |
a7fc0 | 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 69 73 73 65 74 28 73 65 6c 66 3a 3a 24 | ....}.........if.(!isset(self::$ |
a7fe0 | 69 6e 73 74 61 6c 6c 65 64 5b 27 76 65 72 73 69 6f 6e 73 27 5d 5b 24 70 61 63 6b 61 67 65 4e 61 | installed['versions'][$packageNa |
a8000 | 6d 65 5d 5b 27 70 72 65 74 74 79 5f 76 65 72 73 69 6f 6e 27 5d 29 29 20 7b 0a 20 20 20 20 20 20 | me]['pretty_version'])).{....... |
a8020 | 20 20 20 20 20 20 72 65 74 75 72 6e 20 6e 75 6c 6c 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 | ......return.null;.........}.... |
a8040 | 20 20 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 3a 3a 24 69 6e 73 74 61 6c 6c 65 64 5b 27 76 65 | .....return.self::$installed['ve |
a8060 | 72 73 69 6f 6e 73 27 5d 5b 24 70 61 63 6b 61 67 65 4e 61 6d 65 5d 5b 27 70 72 65 74 74 79 5f 76 | rsions'][$packageName]['pretty_v |
a8080 | 65 72 73 69 6f 6e 27 5d 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 | ersion'];.....}.....public.stati |
a80a0 | 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 52 65 66 65 72 65 6e 63 65 28 24 70 61 63 6b 61 67 65 | c.function.getReference($package |
a80c0 | 4e 61 6d 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 69 73 73 65 74 28 73 | Name).....{.........if.(!isset(s |
a80e0 | 65 6c 66 3a 3a 24 69 6e 73 74 61 6c 6c 65 64 5b 27 76 65 72 73 69 6f 6e 73 27 5d 5b 24 70 61 63 | elf::$installed['versions'][$pac |
a8100 | 6b 61 67 65 4e 61 6d 65 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 | kageName])).{.............throw. |
a8120 | 6e 65 77 20 5c 4f 75 74 4f 66 42 6f 75 6e 64 73 45 78 63 65 70 74 69 6f 6e 28 27 50 61 63 6b 61 | new.\OutOfBoundsException('Packa |
a8140 | 67 65 20 22 27 20 2e 20 24 70 61 63 6b 61 67 65 4e 61 6d 65 20 2e 20 27 22 20 69 73 20 6e 6f 74 | ge."'...$packageName...'".is.not |
a8160 | 20 69 6e 73 74 61 6c 6c 65 64 27 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 | .installed');.........}......... |
a8180 | 69 66 20 28 21 69 73 73 65 74 28 73 65 6c 66 3a 3a 24 69 6e 73 74 61 6c 6c 65 64 5b 27 76 65 72 | if.(!isset(self::$installed['ver |
a81a0 | 73 69 6f 6e 73 27 5d 5b 24 70 61 63 6b 61 67 65 4e 61 6d 65 5d 5b 27 72 65 66 65 72 65 6e 63 65 | sions'][$packageName]['reference |
a81c0 | 27 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6e 75 6c 6c 3b 0a | '])).{.............return.null;. |
a81e0 | 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 3a 3a 24 | ........}.........return.self::$ |
a8200 | 69 6e 73 74 61 6c 6c 65 64 5b 27 76 65 72 73 69 6f 6e 73 27 5d 5b 24 70 61 63 6b 61 67 65 4e 61 | installed['versions'][$packageNa |
a8220 | 6d 65 5d 5b 27 72 65 66 65 72 65 6e 63 65 27 5d 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c | me]['reference'];.....}.....publ |
a8240 | 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 52 6f 6f 74 50 61 63 6b 61 67 | ic.static.function.getRootPackag |
a8260 | 65 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 3a 3a 24 | e().....{.........return.self::$ |
a8280 | 69 6e 73 74 61 6c 6c 65 64 5b 27 72 6f 6f 74 27 5d 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 | installed['root'];.....}.....pub |
a82a0 | 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 52 61 77 44 61 74 61 28 29 | lic.static.function.getRawData() |
a82c0 | 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 3a 3a 24 69 6e 73 | .....{.........return.self::$ins |
a82e0 | 74 61 6c 6c 65 64 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 | talled;.....}.....public.static. |
a8300 | 66 75 6e 63 74 69 6f 6e 20 72 65 6c 6f 61 64 28 24 64 61 74 61 29 0a 20 20 20 20 7b 0a 20 20 20 | function.reload($data).....{.... |
a8320 | 20 20 20 20 20 73 65 6c 66 3a 3a 24 69 6e 73 74 61 6c 6c 65 64 20 3d 20 24 64 61 74 61 3b 0a 20 | .....self::$installed.=.$data;.. |
a8340 | 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2a 0a 20 2a 20 54 68 69 73 20 66 69 6c 65 20 69 73 | ...}.}.<?php../*..*.This.file.is |
a8360 | 20 70 61 72 74 20 6f 66 20 43 6f 6d 70 6f 73 65 72 2e 0a 20 2a 0a 20 2a 20 28 63 29 20 4e 69 6c | .part.of.Composer...*..*.(c).Nil |
a8380 | 73 20 41 64 65 72 6d 61 6e 6e 20 3c 6e 61 64 65 72 6d 61 6e 40 6e 61 64 65 72 6d 61 6e 2e 64 65 | s.Adermann.<naderman@naderman.de |
a83a0 | 3e 0a 20 2a 20 20 20 20 20 4a 6f 72 64 69 20 42 6f 67 67 69 61 6e 6f 20 3c 6a 2e 62 6f 67 67 69 | >..*.....Jordi.Boggiano.<j.boggi |
a83c0 | 61 6e 6f 40 73 65 6c 64 2e 62 65 3e 0a 20 2a 0a 20 2a 20 46 6f 72 20 74 68 65 20 66 75 6c 6c 20 | ano@seld.be>..*..*.For.the.full. |
a83e0 | 63 6f 70 79 72 69 67 68 74 20 61 6e 64 20 6c 69 63 65 6e 73 65 20 69 6e 66 6f 72 6d 61 74 69 6f | copyright.and.license.informatio |
a8400 | 6e 2c 20 70 6c 65 61 73 65 20 76 69 65 77 20 74 68 65 20 4c 49 43 45 4e 53 45 0a 20 2a 20 66 69 | n,.please.view.the.LICENSE..*.fi |
a8420 | 6c 65 20 74 68 61 74 20 77 61 73 20 64 69 73 74 72 69 62 75 74 65 64 20 77 69 74 68 20 74 68 69 | le.that.was.distributed.with.thi |
a8440 | 73 20 73 6f 75 72 63 65 20 63 6f 64 65 2e 0a 20 2a 2f 0a 0a 6e 61 6d 65 73 70 61 63 65 20 43 6f | s.source.code...*/..namespace.Co |
a8460 | 6d 70 6f 73 65 72 5c 41 75 74 6f 6c 6f 61 64 3b 0a 0a 2f 2a 2a 0a 20 2a 20 43 6c 61 73 73 4c 6f | mposer\Autoload;../**..*.ClassLo |
a8480 | 61 64 65 72 20 69 6d 70 6c 65 6d 65 6e 74 73 20 61 20 50 53 52 2d 30 2c 20 50 53 52 2d 34 20 61 | ader.implements.a.PSR-0,.PSR-4.a |
a84a0 | 6e 64 20 63 6c 61 73 73 6d 61 70 20 63 6c 61 73 73 20 6c 6f 61 64 65 72 2e 0a 20 2a 0a 20 2a 20 | nd.classmap.class.loader...*..*. |
a84c0 | 20 20 20 20 24 6c 6f 61 64 65 72 20 3d 20 6e 65 77 20 5c 43 6f 6d 70 6f 73 65 72 5c 41 75 74 6f | ....$loader.=.new.\Composer\Auto |
a84e0 | 6c 6f 61 64 5c 43 6c 61 73 73 4c 6f 61 64 65 72 28 29 3b 0a 20 2a 0a 20 2a 20 20 20 20 20 2f 2f | load\ClassLoader();..*..*.....// |
a8500 | 20 72 65 67 69 73 74 65 72 20 63 6c 61 73 73 65 73 20 77 69 74 68 20 6e 61 6d 65 73 70 61 63 65 | .register.classes.with.namespace |
a8520 | 73 0a 20 2a 20 20 20 20 20 24 6c 6f 61 64 65 72 2d 3e 61 64 64 28 27 53 79 6d 66 6f 6e 79 5c 43 | s..*.....$loader->add('Symfony\C |
a8540 | 6f 6d 70 6f 6e 65 6e 74 27 2c 20 5f 5f 44 49 52 5f 5f 2e 27 2f 63 6f 6d 70 6f 6e 65 6e 74 27 29 | omponent',.__DIR__.'/component') |
a8560 | 3b 0a 20 2a 20 20 20 20 20 24 6c 6f 61 64 65 72 2d 3e 61 64 64 28 27 53 79 6d 66 6f 6e 79 27 2c | ;..*.....$loader->add('Symfony', |
a8580 | 20 20 20 20 20 20 20 20 20 20 20 5f 5f 44 49 52 5f 5f 2e 27 2f 66 72 61 6d 65 77 6f 72 6b 27 29 | ...........__DIR__.'/framework') |
a85a0 | 3b 0a 20 2a 0a 20 2a 20 20 20 20 20 2f 2f 20 61 63 74 69 76 61 74 65 20 74 68 65 20 61 75 74 6f | ;..*..*.....//.activate.the.auto |
a85c0 | 6c 6f 61 64 65 72 0a 20 2a 20 20 20 20 20 24 6c 6f 61 64 65 72 2d 3e 72 65 67 69 73 74 65 72 28 | loader..*.....$loader->register( |
a85e0 | 29 3b 0a 20 2a 0a 20 2a 20 20 20 20 20 2f 2f 20 74 6f 20 65 6e 61 62 6c 65 20 73 65 61 72 63 68 | );..*..*.....//.to.enable.search |
a8600 | 69 6e 67 20 74 68 65 20 69 6e 63 6c 75 64 65 20 70 61 74 68 20 28 65 67 2e 20 66 6f 72 20 50 45 | ing.the.include.path.(eg..for.PE |
a8620 | 41 52 20 70 61 63 6b 61 67 65 73 29 0a 20 2a 20 20 20 20 20 24 6c 6f 61 64 65 72 2d 3e 73 65 74 | AR.packages)..*.....$loader->set |
a8640 | 55 73 65 49 6e 63 6c 75 64 65 50 61 74 68 28 74 72 75 65 29 3b 0a 20 2a 0a 20 2a 20 49 6e 20 74 | UseIncludePath(true);..*..*.In.t |
a8660 | 68 69 73 20 65 78 61 6d 70 6c 65 2c 20 69 66 20 79 6f 75 20 74 72 79 20 74 6f 20 75 73 65 20 61 | his.example,.if.you.try.to.use.a |
a8680 | 20 63 6c 61 73 73 20 69 6e 20 74 68 65 20 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 0a | .class.in.the.Symfony\Component. |
a86a0 | 20 2a 20 6e 61 6d 65 73 70 61 63 65 20 6f 72 20 6f 6e 65 20 6f 66 20 69 74 73 20 63 68 69 6c 64 | .*.namespace.or.one.of.its.child |
a86c0 | 72 65 6e 20 28 53 79 6d 66 6f 6e 79 5c 43 6f 6d 70 6f 6e 65 6e 74 5c 43 6f 6e 73 6f 6c 65 20 66 | ren.(Symfony\Component\Console.f |
a86e0 | 6f 72 20 69 6e 73 74 61 6e 63 65 29 2c 0a 20 2a 20 74 68 65 20 61 75 74 6f 6c 6f 61 64 65 72 20 | or.instance),..*.the.autoloader. |
a8700 | 77 69 6c 6c 20 66 69 72 73 74 20 6c 6f 6f 6b 20 66 6f 72 20 74 68 65 20 63 6c 61 73 73 20 75 6e | will.first.look.for.the.class.un |
a8720 | 64 65 72 20 74 68 65 20 63 6f 6d 70 6f 6e 65 6e 74 2f 0a 20 2a 20 64 69 72 65 63 74 6f 72 79 2c | der.the.component/..*.directory, |
a8740 | 20 61 6e 64 20 69 74 20 77 69 6c 6c 20 74 68 65 6e 20 66 61 6c 6c 62 61 63 6b 20 74 6f 20 74 68 | .and.it.will.then.fallback.to.th |
a8760 | 65 20 66 72 61 6d 65 77 6f 72 6b 2f 20 64 69 72 65 63 74 6f 72 79 20 69 66 20 6e 6f 74 0a 20 2a | e.framework/.directory.if.not..* |
a8780 | 20 66 6f 75 6e 64 20 62 65 66 6f 72 65 20 67 69 76 69 6e 67 20 75 70 2e 0a 20 2a 0a 20 2a 20 54 | .found.before.giving.up...*..*.T |
a87a0 | 68 69 73 20 63 6c 61 73 73 20 69 73 20 6c 6f 6f 73 65 6c 79 20 62 61 73 65 64 20 6f 6e 20 74 68 | his.class.is.loosely.based.on.th |
a87c0 | 65 20 53 79 6d 66 6f 6e 79 20 55 6e 69 76 65 72 73 61 6c 43 6c 61 73 73 4c 6f 61 64 65 72 2e 0a | e.Symfony.UniversalClassLoader.. |
a87e0 | 20 2a 0a 20 2a 20 40 61 75 74 68 6f 72 20 46 61 62 69 65 6e 20 50 6f 74 65 6e 63 69 65 72 20 3c | .*..*.@author.Fabien.Potencier.< |
a8800 | 66 61 62 69 65 6e 40 73 79 6d 66 6f 6e 79 2e 63 6f 6d 3e 0a 20 2a 20 40 61 75 74 68 6f 72 20 4a | fabien@symfony.com>..*.@author.J |
a8820 | 6f 72 64 69 20 42 6f 67 67 69 61 6e 6f 20 3c 6a 2e 62 6f 67 67 69 61 6e 6f 40 73 65 6c 64 2e 62 | ordi.Boggiano.<j.boggiano@seld.b |
a8840 | 65 3e 0a 20 2a 20 40 73 65 65 20 20 20 20 68 74 74 70 73 3a 2f 2f 77 77 77 2e 70 68 70 2d 66 69 | e>..*.@see....https://www.php-fi |
a8860 | 67 2e 6f 72 67 2f 70 73 72 2f 70 73 72 2d 30 2f 0a 20 2a 20 40 73 65 65 20 20 20 20 68 74 74 70 | g.org/psr/psr-0/..*.@see....http |
a8880 | 73 3a 2f 2f 77 77 77 2e 70 68 70 2d 66 69 67 2e 6f 72 67 2f 70 73 72 2f 70 73 72 2d 34 2f 0a 20 | s://www.php-fig.org/psr/psr-4/.. |
a88a0 | 2a 2f 0a 63 6c 61 73 73 20 43 6c 61 73 73 4c 6f 61 64 65 72 0a 7b 0a 20 20 20 20 2f 2f 20 50 53 | */.class.ClassLoader.{.....//.PS |
a88c0 | 52 2d 34 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 70 72 65 66 69 78 4c 65 6e 67 74 68 73 50 73 | R-4.....private.$prefixLengthsPs |
a88e0 | 72 34 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 70 72 65 66 69 | r4.=.array();.....private.$prefi |
a8900 | 78 44 69 72 73 50 73 72 34 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 70 72 69 76 61 74 65 | xDirsPsr4.=.array();.....private |
a8920 | 20 24 66 61 6c 6c 62 61 63 6b 44 69 72 73 50 73 72 34 20 3d 20 61 72 72 61 79 28 29 3b 0a 0a 20 | .$fallbackDirsPsr4.=.array();... |
a8940 | 20 20 20 2f 2f 20 50 53 52 2d 30 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 70 72 65 66 69 78 65 | ...//.PSR-0.....private.$prefixe |
a8960 | 73 50 73 72 30 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 66 61 | sPsr0.=.array();.....private.$fa |
a8980 | 6c 6c 62 61 63 6b 44 69 72 73 50 73 72 30 20 3d 20 61 72 72 61 79 28 29 3b 0a 0a 20 20 20 20 70 | llbackDirsPsr0.=.array();......p |
a89a0 | 72 69 76 61 74 65 20 24 75 73 65 49 6e 63 6c 75 64 65 50 61 74 68 20 3d 20 66 61 6c 73 65 3b 0a | rivate.$useIncludePath.=.false;. |
a89c0 | 20 20 20 20 70 72 69 76 61 74 65 20 24 63 6c 61 73 73 4d 61 70 20 3d 20 61 72 72 61 79 28 29 3b | ....private.$classMap.=.array(); |
a89e0 | 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 63 6c 61 73 73 4d 61 70 41 75 74 68 6f 72 69 74 61 74 | .....private.$classMapAuthoritat |
a8a00 | 69 76 65 20 3d 20 66 61 6c 73 65 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 6d 69 73 73 69 6e | ive.=.false;.....private.$missin |
a8a20 | 67 43 6c 61 73 73 65 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 | gClasses.=.array();.....private. |
a8a40 | 24 61 70 63 75 50 72 65 66 69 78 3b 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f | $apcuPrefix;......public.functio |
a8a60 | 6e 20 67 65 74 50 72 65 66 69 78 65 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 | n.getPrefixes().....{.........if |
a8a80 | 20 28 21 65 6d 70 74 79 28 24 74 68 69 73 2d 3e 70 72 65 66 69 78 65 73 50 73 72 30 29 29 20 7b | .(!empty($this->prefixesPsr0)).{ |
a8aa0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 63 61 6c 6c 5f 75 73 65 72 5f 66 75 | .............return.call_user_fu |
a8ac0 | 6e 63 5f 61 72 72 61 79 28 27 61 72 72 61 79 5f 6d 65 72 67 65 27 2c 20 61 72 72 61 79 5f 76 61 | nc_array('array_merge',.array_va |
a8ae0 | 6c 75 65 73 28 24 74 68 69 73 2d 3e 70 72 65 66 69 78 65 73 50 73 72 30 29 29 3b 0a 20 20 20 20 | lues($this->prefixesPsr0));..... |
a8b00 | 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 61 72 72 61 79 28 29 3b 0a 20 | ....}..........return.array();.. |
a8b20 | 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 50 72 65 | ...}......public.function.getPre |
a8b40 | 66 69 78 65 73 50 73 72 34 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e | fixesPsr4().....{.........return |
a8b60 | 20 24 74 68 69 73 2d 3e 70 72 65 66 69 78 44 69 72 73 50 73 72 34 3b 0a 20 20 20 20 7d 0a 0a 20 | .$this->prefixDirsPsr4;.....}... |
a8b80 | 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 46 61 6c 6c 62 61 63 6b 44 69 | ...public.function.getFallbackDi |
a8ba0 | 72 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d | rs().....{.........return.$this- |
a8bc0 | 3e 66 61 6c 6c 62 61 63 6b 44 69 72 73 50 73 72 30 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 | >fallbackDirsPsr0;.....}......pu |
a8be0 | 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 46 61 6c 6c 62 61 63 6b 44 69 72 73 50 73 72 | blic.function.getFallbackDirsPsr |
a8c00 | 34 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e | 4().....{.........return.$this-> |
a8c20 | 66 61 6c 6c 62 61 63 6b 44 69 72 73 50 73 72 34 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 75 62 | fallbackDirsPsr4;.....}......pub |
a8c40 | 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 43 6c 61 73 73 4d 61 70 28 29 0a 20 20 20 20 7b | lic.function.getClassMap().....{ |
a8c60 | 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 63 6c 61 73 73 4d 61 70 3b | .........return.$this->classMap; |
a8c80 | 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 | .....}....../**......*.@param.ar |
a8ca0 | 72 61 79 20 24 63 6c 61 73 73 4d 61 70 20 43 6c 61 73 73 20 74 6f 20 66 69 6c 65 6e 61 6d 65 20 | ray.$classMap.Class.to.filename. |
a8cc0 | 6d 61 70 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 | map......*/.....public.function. |
a8ce0 | 61 64 64 43 6c 61 73 73 4d 61 70 28 61 72 72 61 79 20 24 63 6c 61 73 73 4d 61 70 29 0a 20 20 20 | addClassMap(array.$classMap).... |
a8d00 | 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 74 68 69 73 2d 3e 63 6c 61 73 73 4d 61 70 29 20 | .{.........if.($this->classMap). |
a8d20 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 63 6c 61 73 73 4d 61 70 20 3d 20 | {.............$this->classMap.=. |
a8d40 | 61 72 72 61 79 5f 6d 65 72 67 65 28 24 74 68 69 73 2d 3e 63 6c 61 73 73 4d 61 70 2c 20 24 63 6c | array_merge($this->classMap,.$cl |
a8d60 | 61 73 73 4d 61 70 29 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 | assMap);.........}.else.{....... |
a8d80 | 20 20 20 20 20 20 24 74 68 69 73 2d 3e 63 6c 61 73 73 4d 61 70 20 3d 20 24 63 6c 61 73 73 4d 61 | ......$this->classMap.=.$classMa |
a8da0 | 70 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 | p;.........}.....}....../**..... |
a8dc0 | 20 2a 20 52 65 67 69 73 74 65 72 73 20 61 20 73 65 74 20 6f 66 20 50 53 52 2d 30 20 64 69 72 65 | .*.Registers.a.set.of.PSR-0.dire |
a8de0 | 63 74 6f 72 69 65 73 20 66 6f 72 20 61 20 67 69 76 65 6e 20 70 72 65 66 69 78 2c 20 65 69 74 68 | ctories.for.a.given.prefix,.eith |
a8e00 | 65 72 0a 20 20 20 20 20 2a 20 61 70 70 65 6e 64 69 6e 67 20 6f 72 20 70 72 65 70 65 6e 64 69 6e | er......*.appending.or.prependin |
a8e20 | 67 20 74 6f 20 74 68 65 20 6f 6e 65 73 20 70 72 65 76 69 6f 75 73 6c 79 20 73 65 74 20 66 6f 72 | g.to.the.ones.previously.set.for |
a8e40 | 20 74 68 69 73 20 70 72 65 66 69 78 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 | .this.prefix.......*......*.@par |
a8e60 | 61 6d 20 73 74 72 69 6e 67 20 20 20 20 20 20 20 24 70 72 65 66 69 78 20 20 54 68 65 20 70 72 65 | am.string.......$prefix..The.pre |
a8e80 | 66 69 78 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 7c 73 74 72 69 6e 67 20 24 | fix......*.@param.array|string.$ |
a8ea0 | 70 61 74 68 73 20 20 20 54 68 65 20 50 53 52 2d 30 20 72 6f 6f 74 20 64 69 72 65 63 74 6f 72 69 | paths...The.PSR-0.root.directori |
a8ec0 | 65 73 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 62 6f 6f 6c 20 20 20 20 20 20 20 20 20 24 70 | es......*.@param.bool.........$p |
a8ee0 | 72 65 70 65 6e 64 20 57 68 65 74 68 65 72 20 74 6f 20 70 72 65 70 65 6e 64 20 74 68 65 20 64 69 | repend.Whether.to.prepend.the.di |
a8f00 | 72 65 63 74 6f 72 69 65 73 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e | rectories......*/.....public.fun |
a8f20 | 63 74 69 6f 6e 20 61 64 64 28 24 70 72 65 66 69 78 2c 20 24 70 61 74 68 73 2c 20 24 70 72 65 70 | ction.add($prefix,.$paths,.$prep |
a8f40 | 65 6e 64 20 3d 20 66 61 6c 73 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 | end.=.false).....{.........if.(! |
a8f60 | 24 70 72 65 66 69 78 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 70 72 65 70 | $prefix).{.............if.($prep |
a8f80 | 65 6e 64 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 66 61 | end).{.................$this->fa |
a8fa0 | 6c 6c 62 61 63 6b 44 69 72 73 50 73 72 30 20 3d 20 61 72 72 61 79 5f 6d 65 72 67 65 28 0a 20 20 | llbackDirsPsr0.=.array_merge(... |
a8fc0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 28 61 72 72 61 79 29 20 24 70 61 74 68 73 | ..................(array).$paths |
a8fe0 | 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 66 61 6c | ,.....................$this->fal |
a9000 | 6c 62 61 63 6b 44 69 72 73 50 73 72 30 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 29 3b | lbackDirsPsr0.................); |
a9020 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | .............}.else.{........... |
a9040 | 20 20 20 20 20 20 24 74 68 69 73 2d 3e 66 61 6c 6c 62 61 63 6b 44 69 72 73 50 73 72 30 20 3d 20 | ......$this->fallbackDirsPsr0.=. |
a9060 | 61 72 72 61 79 5f 6d 65 72 67 65 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | array_merge(.................... |
a9080 | 20 24 74 68 69 73 2d 3e 66 61 6c 6c 62 61 63 6b 44 69 72 73 50 73 72 30 2c 0a 20 20 20 20 20 20 | .$this->fallbackDirsPsr0,....... |
a90a0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 28 61 72 72 61 79 29 20 24 70 61 74 68 73 0a 20 20 20 | ..............(array).$paths.... |
a90c0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 0a 20 | .............);.............}... |
a90e0 | 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 | ...........return;.........}.... |
a9100 | 20 20 20 20 20 20 24 66 69 72 73 74 20 3d 20 24 70 72 65 66 69 78 5b 30 5d 3b 0a 20 20 20 20 20 | ......$first.=.$prefix[0];...... |
a9120 | 20 20 20 69 66 20 28 21 69 73 73 65 74 28 24 74 68 69 73 2d 3e 70 72 65 66 69 78 65 73 50 73 72 | ...if.(!isset($this->prefixesPsr |
a9140 | 30 5b 24 66 69 72 73 74 5d 5b 24 70 72 65 66 69 78 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | 0[$first][$prefix])).{.......... |
a9160 | 20 20 20 24 74 68 69 73 2d 3e 70 72 65 66 69 78 65 73 50 73 72 30 5b 24 66 69 72 73 74 5d 5b 24 | ...$this->prefixesPsr0[$first][$ |
a9180 | 70 72 65 66 69 78 5d 20 3d 20 28 61 72 72 61 79 29 20 24 70 61 74 68 73 3b 0a 0a 20 20 20 20 20 | prefix].=.(array).$paths;....... |
a91a0 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 | .......return;.........}........ |
a91c0 | 20 69 66 20 28 24 70 72 65 70 65 6e 64 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 | .if.($prepend).{.............$th |
a91e0 | 69 73 2d 3e 70 72 65 66 69 78 65 73 50 73 72 30 5b 24 66 69 72 73 74 5d 5b 24 70 72 65 66 69 78 | is->prefixesPsr0[$first][$prefix |
a9200 | 5d 20 3d 20 61 72 72 61 79 5f 6d 65 72 67 65 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ].=.array_merge(................ |
a9220 | 20 28 61 72 72 61 79 29 20 24 70 61 74 68 73 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | .(array).$paths,................ |
a9240 | 20 24 74 68 69 73 2d 3e 70 72 65 66 69 78 65 73 50 73 72 30 5b 24 66 69 72 73 74 5d 5b 24 70 72 | .$this->prefixesPsr0[$first][$pr |
a9260 | 65 66 69 78 5d 0a 20 20 20 20 20 20 20 20 20 20 20 20 29 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 | efix].............);.........}.e |
a9280 | 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 70 72 65 66 69 78 65 | lse.{.............$this->prefixe |
a92a0 | 73 50 73 72 30 5b 24 66 69 72 73 74 5d 5b 24 70 72 65 66 69 78 5d 20 3d 20 61 72 72 61 79 5f 6d | sPsr0[$first][$prefix].=.array_m |
a92c0 | 65 72 67 65 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 70 72 65 | erge(.................$this->pre |
a92e0 | 66 69 78 65 73 50 73 72 30 5b 24 66 69 72 73 74 5d 5b 24 70 72 65 66 69 78 5d 2c 0a 20 20 20 20 | fixesPsr0[$first][$prefix],..... |
a9300 | 20 20 20 20 20 20 20 20 20 20 20 20 28 61 72 72 61 79 29 20 24 70 61 74 68 73 0a 20 20 20 20 20 | ............(array).$paths...... |
a9320 | 20 20 20 20 20 20 20 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f | .......);.........}.....}....../ |
a9340 | 2a 2a 0a 20 20 20 20 20 2a 20 52 65 67 69 73 74 65 72 73 20 61 20 73 65 74 20 6f 66 20 50 53 52 | **......*.Registers.a.set.of.PSR |
a9360 | 2d 34 20 64 69 72 65 63 74 6f 72 69 65 73 20 66 6f 72 20 61 20 67 69 76 65 6e 20 6e 61 6d 65 73 | -4.directories.for.a.given.names |
a9380 | 70 61 63 65 2c 20 65 69 74 68 65 72 0a 20 20 20 20 20 2a 20 61 70 70 65 6e 64 69 6e 67 20 6f 72 | pace,.either......*.appending.or |
a93a0 | 20 70 72 65 70 65 6e 64 69 6e 67 20 74 6f 20 74 68 65 20 6f 6e 65 73 20 70 72 65 76 69 6f 75 73 | .prepending.to.the.ones.previous |
a93c0 | 6c 79 20 73 65 74 20 66 6f 72 20 74 68 69 73 20 6e 61 6d 65 73 70 61 63 65 2e 0a 20 20 20 20 20 | ly.set.for.this.namespace....... |
a93e0 | 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 20 20 20 20 20 20 24 70 72 | *......*.@param.string.......$pr |
a9400 | 65 66 69 78 20 20 54 68 65 20 70 72 65 66 69 78 2f 6e 61 6d 65 73 70 61 63 65 2c 20 77 69 74 68 | efix..The.prefix/namespace,.with |
a9420 | 20 74 72 61 69 6c 69 6e 67 20 27 5c 5c 27 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 | .trailing.'\\'......*.@param.arr |
a9440 | 61 79 7c 73 74 72 69 6e 67 20 24 70 61 74 68 73 20 20 20 54 68 65 20 50 53 52 2d 34 20 62 61 73 | ay|string.$paths...The.PSR-4.bas |
a9460 | 65 20 64 69 72 65 63 74 6f 72 69 65 73 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 62 6f 6f 6c | e.directories......*.@param.bool |
a9480 | 20 20 20 20 20 20 20 20 20 24 70 72 65 70 65 6e 64 20 57 68 65 74 68 65 72 20 74 6f 20 70 72 65 | .........$prepend.Whether.to.pre |
a94a0 | 70 65 6e 64 20 74 68 65 20 64 69 72 65 63 74 6f 72 69 65 73 0a 20 20 20 20 20 2a 0a 20 20 20 20 | pend.the.directories......*..... |
a94c0 | 20 2a 20 40 74 68 72 6f 77 73 20 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 | .*.@throws.\InvalidArgumentExcep |
a94e0 | 74 69 6f 6e 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e | tion......*/.....public.function |
a9500 | 20 61 64 64 50 73 72 34 28 24 70 72 65 66 69 78 2c 20 24 70 61 74 68 73 2c 20 24 70 72 65 70 65 | .addPsr4($prefix,.$paths,.$prepe |
a9520 | 6e 64 20 3d 20 66 61 6c 73 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 24 | nd.=.false).....{.........if.(!$ |
a9540 | 70 72 65 66 69 78 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 52 65 67 69 73 74 65 | prefix).{.............//.Registe |
a9560 | 72 20 64 69 72 65 63 74 6f 72 69 65 73 20 66 6f 72 20 74 68 65 20 72 6f 6f 74 20 6e 61 6d 65 73 | r.directories.for.the.root.names |
a9580 | 70 61 63 65 2e 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 70 72 65 70 65 6e 64 29 20 | pace..............if.($prepend). |
a95a0 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 66 61 6c 6c 62 61 63 | {.................$this->fallbac |
a95c0 | 6b 44 69 72 73 50 73 72 34 20 3d 20 61 72 72 61 79 5f 6d 65 72 67 65 28 0a 20 20 20 20 20 20 20 | kDirsPsr4.=.array_merge(........ |
a95e0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 28 61 72 72 61 79 29 20 24 70 61 74 68 73 2c 0a 20 20 20 | .............(array).$paths,.... |
a9600 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 66 61 6c 6c 62 61 63 6b | .................$this->fallback |
a9620 | 44 69 72 73 50 73 72 34 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 29 3b 0a 20 20 20 20 | DirsPsr4.................);..... |
a9640 | 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ........}.else.{................ |
a9660 | 20 24 74 68 69 73 2d 3e 66 61 6c 6c 62 61 63 6b 44 69 72 73 50 73 72 34 20 3d 20 61 72 72 61 79 | .$this->fallbackDirsPsr4.=.array |
a9680 | 5f 6d 65 72 67 65 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 | _merge(.....................$thi |
a96a0 | 73 2d 3e 66 61 6c 6c 62 61 63 6b 44 69 72 73 50 73 72 34 2c 0a 20 20 20 20 20 20 20 20 20 20 20 | s->fallbackDirsPsr4,............ |
a96c0 | 20 20 20 20 20 20 20 20 20 28 61 72 72 61 79 29 20 24 70 61 74 68 73 0a 20 20 20 20 20 20 20 20 | .........(array).$paths......... |
a96e0 | 20 20 20 20 20 20 20 20 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 | ........);.............}........ |
a9700 | 20 7d 20 65 6c 73 65 69 66 20 28 21 69 73 73 65 74 28 24 74 68 69 73 2d 3e 70 72 65 66 69 78 44 | .}.elseif.(!isset($this->prefixD |
a9720 | 69 72 73 50 73 72 34 5b 24 70 72 65 66 69 78 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | irsPsr4[$prefix])).{............ |
a9740 | 20 2f 2f 20 52 65 67 69 73 74 65 72 20 64 69 72 65 63 74 6f 72 69 65 73 20 66 6f 72 20 61 20 6e | .//.Register.directories.for.a.n |
a9760 | 65 77 20 6e 61 6d 65 73 70 61 63 65 2e 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 65 6e 67 74 | ew.namespace..............$lengt |
a9780 | 68 20 3d 20 73 74 72 6c 65 6e 28 24 70 72 65 66 69 78 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 | h.=.strlen($prefix);............ |
a97a0 | 20 69 66 20 28 27 5c 5c 27 20 21 3d 3d 20 24 70 72 65 66 69 78 5b 24 6c 65 6e 67 74 68 20 2d 20 | .if.('\\'.!==.$prefix[$length.-. |
a97c0 | 31 5d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 | 1]).{.................throw.new. |
a97e0 | 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 22 41 20 6e 6f 6e | \InvalidArgumentException("A.non |
a9800 | 2d 65 6d 70 74 79 20 50 53 52 2d 34 20 70 72 65 66 69 78 20 6d 75 73 74 20 65 6e 64 20 77 69 74 | -empty.PSR-4.prefix.must.end.wit |
a9820 | 68 20 61 20 6e 61 6d 65 73 70 61 63 65 20 73 65 70 61 72 61 74 6f 72 2e 22 29 3b 0a 20 20 20 20 | h.a.namespace.separator.");..... |
a9840 | 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 70 72 65 | ........}.............$this->pre |
a9860 | 66 69 78 4c 65 6e 67 74 68 73 50 73 72 34 5b 24 70 72 65 66 69 78 5b 30 5d 5d 5b 24 70 72 65 66 | fixLengthsPsr4[$prefix[0]][$pref |
a9880 | 69 78 5d 20 3d 20 24 6c 65 6e 67 74 68 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 | ix].=.$length;.............$this |
a98a0 | 2d 3e 70 72 65 66 69 78 44 69 72 73 50 73 72 34 5b 24 70 72 65 66 69 78 5d 20 3d 20 28 61 72 72 | ->prefixDirsPsr4[$prefix].=.(arr |
a98c0 | 61 79 29 20 24 70 61 74 68 73 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 24 70 | ay).$paths;.........}.elseif.($p |
a98e0 | 72 65 70 65 6e 64 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 50 72 65 70 65 6e 64 | repend).{.............//.Prepend |
a9900 | 20 64 69 72 65 63 74 6f 72 69 65 73 20 66 6f 72 20 61 6e 20 61 6c 72 65 61 64 79 20 72 65 67 69 | .directories.for.an.already.regi |
a9920 | 73 74 65 72 65 64 20 6e 61 6d 65 73 70 61 63 65 2e 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 | stered.namespace..............$t |
a9940 | 68 69 73 2d 3e 70 72 65 66 69 78 44 69 72 73 50 73 72 34 5b 24 70 72 65 66 69 78 5d 20 3d 20 61 | his->prefixDirsPsr4[$prefix].=.a |
a9960 | 72 72 61 79 5f 6d 65 72 67 65 28 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 28 61 72 72 | rray_merge(.................(arr |
a9980 | 61 79 29 20 24 70 61 74 68 73 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 | ay).$paths,.................$thi |
a99a0 | 73 2d 3e 70 72 65 66 69 78 44 69 72 73 50 73 72 34 5b 24 70 72 65 66 69 78 5d 0a 20 20 20 20 20 | s->prefixDirsPsr4[$prefix]...... |
a99c0 | 20 20 20 20 20 20 20 29 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 | .......);.........}.else.{...... |
a99e0 | 20 20 20 20 20 20 20 2f 2f 20 41 70 70 65 6e 64 20 64 69 72 65 63 74 6f 72 69 65 73 20 66 6f 72 | .......//.Append.directories.for |
a9a00 | 20 61 6e 20 61 6c 72 65 61 64 79 20 72 65 67 69 73 74 65 72 65 64 20 6e 61 6d 65 73 70 61 63 65 | .an.already.registered.namespace |
a9a20 | 2e 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 70 72 65 66 69 78 44 69 72 73 50 | ..............$this->prefixDirsP |
a9a40 | 73 72 34 5b 24 70 72 65 66 69 78 5d 20 3d 20 61 72 72 61 79 5f 6d 65 72 67 65 28 0a 20 20 20 20 | sr4[$prefix].=.array_merge(..... |
a9a60 | 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 70 72 65 66 69 78 44 69 72 73 50 73 72 | ............$this->prefixDirsPsr |
a9a80 | 34 5b 24 70 72 65 66 69 78 5d 2c 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 28 61 72 72 | 4[$prefix],.................(arr |
a9aa0 | 61 79 29 20 24 70 61 74 68 73 0a 20 20 20 20 20 20 20 20 20 20 20 20 29 3b 0a 20 20 20 20 20 20 | ay).$paths.............);....... |
a9ac0 | 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 65 67 69 73 74 | ..}.....}....../**......*.Regist |
a9ae0 | 65 72 73 20 61 20 73 65 74 20 6f 66 20 50 53 52 2d 30 20 64 69 72 65 63 74 6f 72 69 65 73 20 66 | ers.a.set.of.PSR-0.directories.f |
a9b00 | 6f 72 20 61 20 67 69 76 65 6e 20 70 72 65 66 69 78 2c 0a 20 20 20 20 20 2a 20 72 65 70 6c 61 63 | or.a.given.prefix,......*.replac |
a9b20 | 69 6e 67 20 61 6e 79 20 6f 74 68 65 72 73 20 70 72 65 76 69 6f 75 73 6c 79 20 73 65 74 20 66 6f | ing.any.others.previously.set.fo |
a9b40 | 72 20 74 68 69 73 20 70 72 65 66 69 78 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 | r.this.prefix.......*......*.@pa |
a9b60 | 72 61 6d 20 73 74 72 69 6e 67 20 20 20 20 20 20 20 24 70 72 65 66 69 78 20 54 68 65 20 70 72 65 | ram.string.......$prefix.The.pre |
a9b80 | 66 69 78 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 7c 73 74 72 69 6e 67 20 24 | fix......*.@param.array|string.$ |
a9ba0 | 70 61 74 68 73 20 20 54 68 65 20 50 53 52 2d 30 20 62 61 73 65 20 64 69 72 65 63 74 6f 72 69 65 | paths..The.PSR-0.base.directorie |
a9bc0 | 73 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 | s......*/.....public.function.se |
a9be0 | 74 28 24 70 72 65 66 69 78 2c 20 24 70 61 74 68 73 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 | t($prefix,.$paths).....{........ |
a9c00 | 20 69 66 20 28 21 24 70 72 65 66 69 78 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 | .if.(!$prefix).{.............$th |
a9c20 | 69 73 2d 3e 66 61 6c 6c 62 61 63 6b 44 69 72 73 50 73 72 30 20 3d 20 28 61 72 72 61 79 29 20 24 | is->fallbackDirsPsr0.=.(array).$ |
a9c40 | 70 61 74 68 73 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 | paths;.........}.else.{......... |
a9c60 | 20 20 20 20 24 74 68 69 73 2d 3e 70 72 65 66 69 78 65 73 50 73 72 30 5b 24 70 72 65 66 69 78 5b | ....$this->prefixesPsr0[$prefix[ |
a9c80 | 30 5d 5d 5b 24 70 72 65 66 69 78 5d 20 3d 20 28 61 72 72 61 79 29 20 24 70 61 74 68 73 3b 0a 20 | 0]][$prefix].=.(array).$paths;.. |
a9ca0 | 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 52 | .......}.....}....../**......*.R |
a9cc0 | 65 67 69 73 74 65 72 73 20 61 20 73 65 74 20 6f 66 20 50 53 52 2d 34 20 64 69 72 65 63 74 6f 72 | egisters.a.set.of.PSR-4.director |
a9ce0 | 69 65 73 20 66 6f 72 20 61 20 67 69 76 65 6e 20 6e 61 6d 65 73 70 61 63 65 2c 0a 20 20 20 20 20 | ies.for.a.given.namespace,...... |
a9d00 | 2a 20 72 65 70 6c 61 63 69 6e 67 20 61 6e 79 20 6f 74 68 65 72 73 20 70 72 65 76 69 6f 75 73 6c | *.replacing.any.others.previousl |
a9d20 | 79 20 73 65 74 20 66 6f 72 20 74 68 69 73 20 6e 61 6d 65 73 70 61 63 65 2e 0a 20 20 20 20 20 2a | y.set.for.this.namespace.......* |
a9d40 | 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 6e 67 20 20 20 20 20 20 20 24 70 72 65 | ......*.@param.string.......$pre |
a9d60 | 66 69 78 20 54 68 65 20 70 72 65 66 69 78 2f 6e 61 6d 65 73 70 61 63 65 2c 20 77 69 74 68 20 74 | fix.The.prefix/namespace,.with.t |
a9d80 | 72 61 69 6c 69 6e 67 20 27 5c 5c 27 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 61 72 72 61 79 | railing.'\\'......*.@param.array |
a9da0 | 7c 73 74 72 69 6e 67 20 24 70 61 74 68 73 20 20 54 68 65 20 50 53 52 2d 34 20 62 61 73 65 20 64 | |string.$paths..The.PSR-4.base.d |
a9dc0 | 69 72 65 63 74 6f 72 69 65 73 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 74 68 72 6f 77 73 | irectories......*......*.@throws |
a9de0 | 20 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 0a 20 20 20 20 20 | .\InvalidArgumentException...... |
a9e00 | 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 50 73 72 34 28 24 | */.....public.function.setPsr4($ |
a9e20 | 70 72 65 66 69 78 2c 20 24 70 61 74 68 73 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 | prefix,.$paths).....{.........if |
a9e40 | 20 28 21 24 70 72 65 66 69 78 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d | .(!$prefix).{.............$this- |
a9e60 | 3e 66 61 6c 6c 62 61 63 6b 44 69 72 73 50 73 72 34 20 3d 20 28 61 72 72 61 79 29 20 24 70 61 74 | >fallbackDirsPsr4.=.(array).$pat |
a9e80 | 68 73 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | hs;.........}.else.{............ |
a9ea0 | 20 24 6c 65 6e 67 74 68 20 3d 20 73 74 72 6c 65 6e 28 24 70 72 65 66 69 78 29 3b 0a 20 20 20 20 | .$length.=.strlen($prefix);..... |
a9ec0 | 20 20 20 20 20 20 20 20 69 66 20 28 27 5c 5c 27 20 21 3d 3d 20 24 70 72 65 66 69 78 5b 24 6c 65 | ........if.('\\'.!==.$prefix[$le |
a9ee0 | 6e 67 74 68 20 2d 20 31 5d 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 | ngth.-.1]).{.................thr |
a9f00 | 6f 77 20 6e 65 77 20 5c 49 6e 76 61 6c 69 64 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e | ow.new.\InvalidArgumentException |
a9f20 | 28 22 41 20 6e 6f 6e 2d 65 6d 70 74 79 20 50 53 52 2d 34 20 70 72 65 66 69 78 20 6d 75 73 74 20 | ("A.non-empty.PSR-4.prefix.must. |
a9f40 | 65 6e 64 20 77 69 74 68 20 61 20 6e 61 6d 65 73 70 61 63 65 20 73 65 70 61 72 61 74 6f 72 2e 22 | end.with.a.namespace.separator." |
a9f60 | 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 | );.............}.............$th |
a9f80 | 69 73 2d 3e 70 72 65 66 69 78 4c 65 6e 67 74 68 73 50 73 72 34 5b 24 70 72 65 66 69 78 5b 30 5d | is->prefixLengthsPsr4[$prefix[0] |
a9fa0 | 5d 5b 24 70 72 65 66 69 78 5d 20 3d 20 24 6c 65 6e 67 74 68 3b 0a 20 20 20 20 20 20 20 20 20 20 | ][$prefix].=.$length;........... |
a9fc0 | 20 20 24 74 68 69 73 2d 3e 70 72 65 66 69 78 44 69 72 73 50 73 72 34 5b 24 70 72 65 66 69 78 5d | ..$this->prefixDirsPsr4[$prefix] |
a9fe0 | 20 3d 20 28 61 72 72 61 79 29 20 24 70 61 74 68 73 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 | .=.(array).$paths;.........}.... |
aa000 | 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 54 75 72 6e 73 20 6f 6e 20 73 65 61 72 | .}....../**......*.Turns.on.sear |
aa020 | 63 68 69 6e 67 20 74 68 65 20 69 6e 63 6c 75 64 65 20 70 61 74 68 20 66 6f 72 20 63 6c 61 73 73 | ching.the.include.path.for.class |
aa040 | 20 66 69 6c 65 73 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 62 6f 6f | .files.......*......*.@param.boo |
aa060 | 6c 20 24 75 73 65 49 6e 63 6c 75 64 65 50 61 74 68 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 | l.$useIncludePath......*/.....pu |
aa080 | 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 55 73 65 49 6e 63 6c 75 64 65 50 61 74 68 28 | blic.function.setUseIncludePath( |
aa0a0 | 24 75 73 65 49 6e 63 6c 75 64 65 50 61 74 68 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 | $useIncludePath).....{.........$ |
aa0c0 | 74 68 69 73 2d 3e 75 73 65 49 6e 63 6c 75 64 65 50 61 74 68 20 3d 20 24 75 73 65 49 6e 63 6c 75 | this->useIncludePath.=.$useInclu |
aa0e0 | 64 65 50 61 74 68 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 43 61 | dePath;.....}....../**......*.Ca |
aa100 | 6e 20 62 65 20 75 73 65 64 20 74 6f 20 63 68 65 63 6b 20 69 66 20 74 68 65 20 61 75 74 6f 6c 6f | n.be.used.to.check.if.the.autolo |
aa120 | 61 64 65 72 20 75 73 65 73 20 74 68 65 20 69 6e 63 6c 75 64 65 20 70 61 74 68 20 74 6f 20 63 68 | ader.uses.the.include.path.to.ch |
aa140 | 65 63 6b 0a 20 20 20 20 20 2a 20 66 6f 72 20 63 6c 61 73 73 65 73 2e 0a 20 20 20 20 20 2a 0a 20 | eck......*.for.classes.......*.. |
aa160 | 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 62 6f 6f 6c 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 | ....*.@return.bool......*/.....p |
aa180 | 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 55 73 65 49 6e 63 6c 75 64 65 50 61 74 68 | ublic.function.getUseIncludePath |
aa1a0 | 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 75 | ().....{.........return.$this->u |
aa1c0 | 73 65 49 6e 63 6c 75 64 65 50 61 74 68 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 | seIncludePath;.....}....../**... |
aa1e0 | 20 20 20 2a 20 54 75 72 6e 73 20 6f 66 66 20 73 65 61 72 63 68 69 6e 67 20 74 68 65 20 70 72 65 | ...*.Turns.off.searching.the.pre |
aa200 | 66 69 78 20 61 6e 64 20 66 61 6c 6c 62 61 63 6b 20 64 69 72 65 63 74 6f 72 69 65 73 20 66 6f 72 | fix.and.fallback.directories.for |
aa220 | 20 63 6c 61 73 73 65 73 0a 20 20 20 20 20 2a 20 74 68 61 74 20 68 61 76 65 20 6e 6f 74 20 62 65 | .classes......*.that.have.not.be |
aa240 | 65 6e 20 72 65 67 69 73 74 65 72 65 64 20 77 69 74 68 20 74 68 65 20 63 6c 61 73 73 20 6d 61 70 | en.registered.with.the.class.map |
aa260 | 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 62 6f 6f 6c 20 24 63 6c 61 | .......*......*.@param.bool.$cla |
aa280 | 73 73 4d 61 70 41 75 74 68 6f 72 69 74 61 74 69 76 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 | ssMapAuthoritative......*/.....p |
aa2a0 | 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 43 6c 61 73 73 4d 61 70 41 75 74 68 6f 72 | ublic.function.setClassMapAuthor |
aa2c0 | 69 74 61 74 69 76 65 28 24 63 6c 61 73 73 4d 61 70 41 75 74 68 6f 72 69 74 61 74 69 76 65 29 0a | itative($classMapAuthoritative). |
aa2e0 | 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 63 6c 61 73 73 4d 61 70 41 75 74 | ....{.........$this->classMapAut |
aa300 | 68 6f 72 69 74 61 74 69 76 65 20 3d 20 24 63 6c 61 73 73 4d 61 70 41 75 74 68 6f 72 69 74 61 74 | horitative.=.$classMapAuthoritat |
aa320 | 69 76 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 53 68 6f 75 6c | ive;.....}....../**......*.Shoul |
aa340 | 64 20 63 6c 61 73 73 20 6c 6f 6f 6b 75 70 20 66 61 69 6c 20 69 66 20 6e 6f 74 20 66 6f 75 6e 64 | d.class.lookup.fail.if.not.found |
aa360 | 20 69 6e 20 74 68 65 20 63 75 72 72 65 6e 74 20 63 6c 61 73 73 20 6d 61 70 3f 0a 20 20 20 20 20 | .in.the.current.class.map?...... |
aa380 | 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 62 6f 6f 6c 0a 20 20 20 20 20 2a 2f 0a 20 20 | *......*.@return.bool......*/... |
aa3a0 | 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 69 73 43 6c 61 73 73 4d 61 70 41 75 74 68 | ..public.function.isClassMapAuth |
aa3c0 | 6f 72 69 74 61 74 69 76 65 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e | oritative().....{.........return |
aa3e0 | 20 24 74 68 69 73 2d 3e 63 6c 61 73 73 4d 61 70 41 75 74 68 6f 72 69 74 61 74 69 76 65 3b 0a 20 | .$this->classMapAuthoritative;.. |
aa400 | 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 41 50 43 75 20 70 72 65 66 69 78 | ...}....../**......*.APCu.prefix |
aa420 | 20 74 6f 20 75 73 65 20 74 6f 20 63 61 63 68 65 20 66 6f 75 6e 64 2f 6e 6f 74 2d 66 6f 75 6e 64 | .to.use.to.cache.found/not-found |
aa440 | 20 63 6c 61 73 73 65 73 2c 20 69 66 20 74 68 65 20 65 78 74 65 6e 73 69 6f 6e 20 69 73 20 65 6e | .classes,.if.the.extension.is.en |
aa460 | 61 62 6c 65 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 73 74 72 69 | abled.......*......*.@param.stri |
aa480 | 6e 67 7c 6e 75 6c 6c 20 24 61 70 63 75 50 72 65 66 69 78 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 | ng|null.$apcuPrefix......*/..... |
aa4a0 | 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 73 65 74 41 70 63 75 50 72 65 66 69 78 28 24 61 | public.function.setApcuPrefix($a |
aa4c0 | 70 63 75 50 72 65 66 69 78 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e | pcuPrefix).....{.........$this-> |
aa4e0 | 61 70 63 75 50 72 65 66 69 78 20 3d 20 66 75 6e 63 74 69 6f 6e 5f 65 78 69 73 74 73 28 27 61 70 | apcuPrefix.=.function_exists('ap |
aa500 | 63 75 5f 66 65 74 63 68 27 29 20 26 26 20 66 69 6c 74 65 72 5f 76 61 72 28 69 6e 69 5f 67 65 74 | cu_fetch').&&.filter_var(ini_get |
aa520 | 28 27 61 70 63 2e 65 6e 61 62 6c 65 64 27 29 2c 20 46 49 4c 54 45 52 5f 56 41 4c 49 44 41 54 45 | ('apc.enabled'),.FILTER_VALIDATE |
aa540 | 5f 42 4f 4f 4c 45 41 4e 29 20 3f 20 24 61 70 63 75 50 72 65 66 69 78 20 3a 20 6e 75 6c 6c 3b 0a | _BOOLEAN).?.$apcuPrefix.:.null;. |
aa560 | 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 54 68 65 20 41 50 43 75 20 70 | ....}....../**......*.The.APCu.p |
aa580 | 72 65 66 69 78 20 69 6e 20 75 73 65 2c 20 6f 72 20 6e 75 6c 6c 20 69 66 20 41 50 43 75 20 63 61 | refix.in.use,.or.null.if.APCu.ca |
aa5a0 | 63 68 69 6e 67 20 69 73 20 6e 6f 74 20 65 6e 61 62 6c 65 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 | ching.is.not.enabled.......*.... |
aa5c0 | 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 72 69 6e 67 7c 6e 75 6c 6c 0a 20 20 20 20 20 2a 2f 0a | ..*.@return.string|null......*/. |
aa5e0 | 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 41 70 63 75 50 72 65 66 69 | ....public.function.getApcuPrefi |
aa600 | 78 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e | x().....{.........return.$this-> |
aa620 | 61 70 63 75 50 72 65 66 69 78 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 | apcuPrefix;.....}....../**...... |
aa640 | 2a 20 52 65 67 69 73 74 65 72 73 20 74 68 69 73 20 69 6e 73 74 61 6e 63 65 20 61 73 20 61 6e 20 | *.Registers.this.instance.as.an. |
aa660 | 61 75 74 6f 6c 6f 61 64 65 72 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d | autoloader.......*......*.@param |
aa680 | 20 62 6f 6f 6c 20 24 70 72 65 70 65 6e 64 20 57 68 65 74 68 65 72 20 74 6f 20 70 72 65 70 65 6e | .bool.$prepend.Whether.to.prepen |
aa6a0 | 64 20 74 68 65 20 61 75 74 6f 6c 6f 61 64 65 72 20 6f 72 20 6e 6f 74 0a 20 20 20 20 20 2a 2f 0a | d.the.autoloader.or.not......*/. |
aa6c0 | 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 72 65 67 69 73 74 65 72 28 24 70 72 | ....public.function.register($pr |
aa6e0 | 65 70 65 6e 64 20 3d 20 66 61 6c 73 65 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 73 70 6c | epend.=.false).....{.........spl |
aa700 | 5f 61 75 74 6f 6c 6f 61 64 5f 72 65 67 69 73 74 65 72 28 61 72 72 61 79 28 24 74 68 69 73 2c 20 | _autoload_register(array($this,. |
aa720 | 27 6c 6f 61 64 43 6c 61 73 73 27 29 2c 20 74 72 75 65 2c 20 24 70 72 65 70 65 6e 64 29 3b 0a 20 | 'loadClass'),.true,.$prepend);.. |
aa740 | 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 55 6e 72 65 67 69 73 74 65 72 73 | ...}....../**......*.Unregisters |
aa760 | 20 74 68 69 73 20 69 6e 73 74 61 6e 63 65 20 61 73 20 61 6e 20 61 75 74 6f 6c 6f 61 64 65 72 2e | .this.instance.as.an.autoloader. |
aa780 | 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 75 6e 72 | ......*/.....public.function.unr |
aa7a0 | 65 67 69 73 74 65 72 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 73 70 6c 5f 61 75 74 6f | egister().....{.........spl_auto |
aa7c0 | 6c 6f 61 64 5f 75 6e 72 65 67 69 73 74 65 72 28 61 72 72 61 79 28 24 74 68 69 73 2c 20 27 6c 6f | load_unregister(array($this,.'lo |
aa7e0 | 61 64 43 6c 61 73 73 27 29 29 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 | adClass'));.....}....../**...... |
aa800 | 2a 20 4c 6f 61 64 73 20 74 68 65 20 67 69 76 65 6e 20 63 6c 61 73 73 20 6f 72 20 69 6e 74 65 72 | *.Loads.the.given.class.or.inter |
aa820 | 66 61 63 65 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 72 61 6d 20 20 73 74 72 69 | face.......*......*.@param..stri |
aa840 | 6e 67 20 20 20 20 24 63 6c 61 73 73 20 54 68 65 20 6e 61 6d 65 20 6f 66 20 74 68 65 20 63 6c 61 | ng....$class.The.name.of.the.cla |
aa860 | 73 73 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 62 6f 6f 6c 7c 6e 75 6c 6c 20 54 72 75 65 | ss......*.@return.bool|null.True |
aa880 | 20 69 66 20 6c 6f 61 64 65 64 2c 20 6e 75 6c 6c 20 6f 74 68 65 72 77 69 73 65 0a 20 20 20 20 20 | .if.loaded,.null.otherwise...... |
aa8a0 | 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 6c 6f 61 64 43 6c 61 73 73 | */.....public.function.loadClass |
aa8c0 | 28 24 63 6c 61 73 73 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 66 69 6c 65 | ($class).....{.........if.($file |
aa8e0 | 20 3d 20 24 74 68 69 73 2d 3e 66 69 6e 64 46 69 6c 65 28 24 63 6c 61 73 73 29 29 20 7b 0a 20 20 | .=.$this->findFile($class)).{... |
aa900 | 20 20 20 20 20 20 20 20 20 20 69 6e 63 6c 75 64 65 46 69 6c 65 28 24 66 69 6c 65 29 3b 0a 0a 20 | ..........includeFile($file);... |
aa920 | 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 74 72 75 65 3b 0a 20 20 20 20 20 20 20 20 | ...........return.true;......... |
aa940 | 7d 0a 20 20 20 20 7d 0a 0a 20 20 20 20 2f 2a 2a 0a 20 20 20 20 20 2a 20 46 69 6e 64 73 20 74 68 | }.....}....../**......*.Finds.th |
aa960 | 65 20 70 61 74 68 20 74 6f 20 74 68 65 20 66 69 6c 65 20 77 68 65 72 65 20 74 68 65 20 63 6c 61 | e.path.to.the.file.where.the.cla |
aa980 | 73 73 20 69 73 20 64 65 66 69 6e 65 64 2e 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 70 61 | ss.is.defined.......*......*.@pa |
aa9a0 | 72 61 6d 20 73 74 72 69 6e 67 20 24 63 6c 61 73 73 20 54 68 65 20 6e 61 6d 65 20 6f 66 20 74 68 | ram.string.$class.The.name.of.th |
aa9c0 | 65 20 63 6c 61 73 73 0a 20 20 20 20 20 2a 0a 20 20 20 20 20 2a 20 40 72 65 74 75 72 6e 20 73 74 | e.class......*......*.@return.st |
aa9e0 | 72 69 6e 67 7c 66 61 6c 73 65 20 54 68 65 20 70 61 74 68 20 69 66 20 66 6f 75 6e 64 2c 20 66 61 | ring|false.The.path.if.found,.fa |
aaa00 | 6c 73 65 20 6f 74 68 65 72 77 69 73 65 0a 20 20 20 20 20 2a 2f 0a 20 20 20 20 70 75 62 6c 69 63 | lse.otherwise......*/.....public |
aaa20 | 20 66 75 6e 63 74 69 6f 6e 20 66 69 6e 64 46 69 6c 65 28 24 63 6c 61 73 73 29 0a 20 20 20 20 7b | .function.findFile($class).....{ |
aaa40 | 0a 20 20 20 20 20 20 20 20 2f 2f 20 63 6c 61 73 73 20 6d 61 70 20 6c 6f 6f 6b 75 70 0a 20 20 20 | .........//.class.map.lookup.... |
aaa60 | 20 20 20 20 20 69 66 20 28 69 73 73 65 74 28 24 74 68 69 73 2d 3e 63 6c 61 73 73 4d 61 70 5b 24 | .....if.(isset($this->classMap[$ |
aaa80 | 63 6c 61 73 73 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 | class])).{.............return.$t |
aaaa0 | 68 69 73 2d 3e 63 6c 61 73 73 4d 61 70 5b 24 63 6c 61 73 73 5d 3b 0a 20 20 20 20 20 20 20 20 7d | his->classMap[$class];.........} |
aaac0 | 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 74 68 69 73 2d 3e 63 6c 61 73 73 4d 61 70 41 75 74 68 | .........if.($this->classMapAuth |
aaae0 | 6f 72 69 74 61 74 69 76 65 20 7c 7c 20 69 73 73 65 74 28 24 74 68 69 73 2d 3e 6d 69 73 73 69 6e | oritative.||.isset($this->missin |
aab00 | 67 43 6c 61 73 73 65 73 5b 24 63 6c 61 73 73 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | gClasses[$class])).{............ |
aab20 | 20 72 65 74 75 72 6e 20 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 | .return.false;.........}........ |
aab40 | 20 69 66 20 28 6e 75 6c 6c 20 21 3d 3d 20 24 74 68 69 73 2d 3e 61 70 63 75 50 72 65 66 69 78 29 | .if.(null.!==.$this->apcuPrefix) |
aab60 | 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 66 69 6c 65 20 3d 20 61 70 63 75 5f 66 65 74 63 | .{.............$file.=.apcu_fetc |
aab80 | 68 28 24 74 68 69 73 2d 3e 61 70 63 75 50 72 65 66 69 78 2e 24 63 6c 61 73 73 2c 20 24 68 69 74 | h($this->apcuPrefix.$class,.$hit |
aaba0 | 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 68 69 74 29 20 7b 0a 20 20 20 20 20 | );.............if.($hit).{...... |
aabc0 | 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 66 69 6c 65 3b 0a 20 20 20 20 20 20 20 | ...........return.$file;........ |
aabe0 | 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 24 66 69 6c 65 20 | .....}.........}..........$file. |
aac00 | 3d 20 24 74 68 69 73 2d 3e 66 69 6e 64 46 69 6c 65 57 69 74 68 45 78 74 65 6e 73 69 6f 6e 28 24 | =.$this->findFileWithExtension($ |
aac20 | 63 6c 61 73 73 2c 20 27 2e 70 68 70 27 29 3b 0a 0a 20 20 20 20 20 20 20 20 2f 2f 20 53 65 61 72 | class,.'.php');..........//.Sear |
aac40 | 63 68 20 66 6f 72 20 48 61 63 6b 20 66 69 6c 65 73 20 69 66 20 77 65 20 61 72 65 20 72 75 6e 6e | ch.for.Hack.files.if.we.are.runn |
aac60 | 69 6e 67 20 6f 6e 20 48 48 56 4d 0a 20 20 20 20 20 20 20 20 69 66 20 28 66 61 6c 73 65 20 3d 3d | ing.on.HHVM.........if.(false.== |
aac80 | 3d 20 24 66 69 6c 65 20 26 26 20 64 65 66 69 6e 65 64 28 27 48 48 56 4d 5f 56 45 52 53 49 4f 4e | =.$file.&&.defined('HHVM_VERSION |
aaca0 | 27 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 66 69 6c 65 20 3d 20 24 74 68 69 73 2d | ')).{.............$file.=.$this- |
aacc0 | 3e 66 69 6e 64 46 69 6c 65 57 69 74 68 45 78 74 65 6e 73 69 6f 6e 28 24 63 6c 61 73 73 2c 20 27 | >findFileWithExtension($class,.' |
aace0 | 2e 68 68 27 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 | .hh');.........}..........if.(nu |
aad00 | 6c 6c 20 21 3d 3d 20 24 74 68 69 73 2d 3e 61 70 63 75 50 72 65 66 69 78 29 20 7b 0a 20 20 20 20 | ll.!==.$this->apcuPrefix).{..... |
aad20 | 20 20 20 20 20 20 20 20 61 70 63 75 5f 61 64 64 28 24 74 68 69 73 2d 3e 61 70 63 75 50 72 65 66 | ........apcu_add($this->apcuPref |
aad40 | 69 78 2e 24 63 6c 61 73 73 2c 20 24 66 69 6c 65 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 | ix.$class,.$file);.........}.... |
aad60 | 20 20 20 20 20 20 69 66 20 28 66 61 6c 73 65 20 3d 3d 3d 20 24 66 69 6c 65 29 20 7b 0a 20 20 20 | ......if.(false.===.$file).{.... |
aad80 | 20 20 20 20 20 20 20 20 20 2f 2f 20 52 65 6d 65 6d 62 65 72 20 74 68 61 74 20 74 68 69 73 20 63 | .........//.Remember.that.this.c |
aada0 | 6c 61 73 73 20 64 6f 65 73 20 6e 6f 74 20 65 78 69 73 74 2e 0a 20 20 20 20 20 20 20 20 20 20 20 | lass.does.not.exist............. |
aadc0 | 20 24 74 68 69 73 2d 3e 6d 69 73 73 69 6e 67 43 6c 61 73 73 65 73 5b 24 63 6c 61 73 73 5d 20 3d | .$this->missingClasses[$class].= |
aade0 | 20 74 72 75 65 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e | .true;.........}..........return |
aae00 | 20 24 66 69 6c 65 3b 0a 20 20 20 20 7d 0a 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 | .$file;.....}......private.funct |
aae20 | 69 6f 6e 20 66 69 6e 64 46 69 6c 65 57 69 74 68 45 78 74 65 6e 73 69 6f 6e 28 24 63 6c 61 73 73 | ion.findFileWithExtension($class |
aae40 | 2c 20 24 65 78 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 2f 2f 20 50 53 52 2d 34 20 6c | ,.$ext).....{.........//.PSR-4.l |
aae60 | 6f 6f 6b 75 70 0a 20 20 20 20 20 20 20 20 24 6c 6f 67 69 63 61 6c 50 61 74 68 50 73 72 34 20 3d | ookup.........$logicalPathPsr4.= |
aae80 | 20 73 74 72 74 72 28 24 63 6c 61 73 73 2c 20 27 5c 5c 27 2c 20 44 49 52 45 43 54 4f 52 59 5f 53 | .strtr($class,.'\\',.DIRECTORY_S |
aaea0 | 45 50 41 52 41 54 4f 52 29 20 2e 20 24 65 78 74 3b 0a 0a 20 20 20 20 20 20 20 20 24 66 69 72 73 | EPARATOR)...$ext;..........$firs |
aaec0 | 74 20 3d 20 24 63 6c 61 73 73 5b 30 5d 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 69 73 73 65 74 | t.=.$class[0];.........if.(isset |
aaee0 | 28 24 74 68 69 73 2d 3e 70 72 65 66 69 78 4c 65 6e 67 74 68 73 50 73 72 34 5b 24 66 69 72 73 74 | ($this->prefixLengthsPsr4[$first |
aaf00 | 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 73 75 62 50 61 74 68 20 3d 20 24 63 6c | ])).{.............$subPath.=.$cl |
aaf20 | 61 73 73 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 77 68 69 6c 65 20 28 66 61 6c 73 65 20 21 3d | ass;.............while.(false.!= |
aaf40 | 3d 20 24 6c 61 73 74 50 6f 73 20 3d 20 73 74 72 72 70 6f 73 28 24 73 75 62 50 61 74 68 2c 20 27 | =.$lastPos.=.strrpos($subPath,.' |
aaf60 | 5c 5c 27 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 73 75 62 50 61 74 68 | \\')).{.................$subPath |
aaf80 | 20 3d 20 73 75 62 73 74 72 28 24 73 75 62 50 61 74 68 2c 20 30 2c 20 24 6c 61 73 74 50 6f 73 29 | .=.substr($subPath,.0,.$lastPos) |
aafa0 | 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 73 65 61 72 63 68 20 3d 20 24 73 75 62 | ;.................$search.=.$sub |
aafc0 | 50 61 74 68 20 2e 20 27 5c 5c 27 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 | Path...'\\';.................if. |
aafe0 | 28 69 73 73 65 74 28 24 74 68 69 73 2d 3e 70 72 65 66 69 78 44 69 72 73 50 73 72 34 5b 24 73 65 | (isset($this->prefixDirsPsr4[$se |
ab000 | 61 72 63 68 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 70 | arch])).{.....................$p |
ab020 | 61 74 68 45 6e 64 20 3d 20 44 49 52 45 43 54 4f 52 59 5f 53 45 50 41 52 41 54 4f 52 20 2e 20 73 | athEnd.=.DIRECTORY_SEPARATOR...s |
ab040 | 75 62 73 74 72 28 24 6c 6f 67 69 63 61 6c 50 61 74 68 50 73 72 34 2c 20 24 6c 61 73 74 50 6f 73 | ubstr($logicalPathPsr4,.$lastPos |
ab060 | 20 2b 20 31 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 | .+.1);.....................forea |
ab080 | 63 68 20 28 24 74 68 69 73 2d 3e 70 72 65 66 69 78 44 69 72 73 50 73 72 34 5b 24 73 65 61 72 63 | ch.($this->prefixDirsPsr4[$searc |
ab0a0 | 68 5d 20 61 73 20 24 64 69 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | h].as.$dir).{................... |
ab0c0 | 20 20 20 20 20 20 69 66 20 28 66 69 6c 65 5f 65 78 69 73 74 73 28 24 66 69 6c 65 20 3d 20 24 64 | ......if.(file_exists($file.=.$d |
ab0e0 | 69 72 20 2e 20 24 70 61 74 68 45 6e 64 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ir...$pathEnd)).{............... |
ab100 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 66 69 6c 65 3b 0a 20 20 20 20 | ..............return.$file;..... |
ab120 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 | ....................}........... |
ab140 | 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 | ..........}.................}... |
ab160 | 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 2f | ..........}.........}........../ |
ab180 | 2f 20 50 53 52 2d 34 20 66 61 6c 6c 62 61 63 6b 20 64 69 72 73 0a 20 20 20 20 20 20 20 20 66 6f | /.PSR-4.fallback.dirs.........fo |
ab1a0 | 72 65 61 63 68 20 28 24 74 68 69 73 2d 3e 66 61 6c 6c 62 61 63 6b 44 69 72 73 50 73 72 34 20 61 | reach.($this->fallbackDirsPsr4.a |
ab1c0 | 73 20 24 64 69 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 66 69 6c 65 5f 65 | s.$dir).{.............if.(file_e |
ab1e0 | 78 69 73 74 73 28 24 66 69 6c 65 20 3d 20 24 64 69 72 20 2e 20 44 49 52 45 43 54 4f 52 59 5f 53 | xists($file.=.$dir...DIRECTORY_S |
ab200 | 45 50 41 52 41 54 4f 52 20 2e 20 24 6c 6f 67 69 63 61 6c 50 61 74 68 50 73 72 34 29 29 20 7b 0a | EPARATOR...$logicalPathPsr4)).{. |
ab220 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 66 69 6c 65 3b 0a 20 20 | ................return.$file;... |
ab240 | 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 2f | ..........}.........}........../ |
ab260 | 2f 20 50 53 52 2d 30 20 6c 6f 6f 6b 75 70 0a 20 20 20 20 20 20 20 20 69 66 20 28 66 61 6c 73 65 | /.PSR-0.lookup.........if.(false |
ab280 | 20 21 3d 3d 20 24 70 6f 73 20 3d 20 73 74 72 72 70 6f 73 28 24 63 6c 61 73 73 2c 20 27 5c 5c 27 | .!==.$pos.=.strrpos($class,.'\\' |
ab2a0 | 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 6e 61 6d 65 73 70 61 63 65 64 20 63 | )).{.............//.namespaced.c |
ab2c0 | 6c 61 73 73 20 6e 61 6d 65 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 6f 67 69 63 61 6c 50 61 | lass.name.............$logicalPa |
ab2e0 | 74 68 50 73 72 30 20 3d 20 73 75 62 73 74 72 28 24 6c 6f 67 69 63 61 6c 50 61 74 68 50 73 72 34 | thPsr0.=.substr($logicalPathPsr4 |
ab300 | 2c 20 30 2c 20 24 70 6f 73 20 2b 20 31 29 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2e | ,.0,.$pos.+.1).................. |
ab320 | 20 73 74 72 74 72 28 73 75 62 73 74 72 28 24 6c 6f 67 69 63 61 6c 50 61 74 68 50 73 72 34 2c 20 | .strtr(substr($logicalPathPsr4,. |
ab340 | 24 70 6f 73 20 2b 20 31 29 2c 20 27 5f 27 2c 20 44 49 52 45 43 54 4f 52 59 5f 53 45 50 41 52 41 | $pos.+.1),.'_',.DIRECTORY_SEPARA |
ab360 | 54 4f 52 29 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 | TOR);.........}.else.{.......... |
ab380 | 20 20 20 2f 2f 20 50 45 41 52 2d 6c 69 6b 65 20 63 6c 61 73 73 20 6e 61 6d 65 0a 20 20 20 20 20 | ...//.PEAR-like.class.name...... |
ab3a0 | 20 20 20 20 20 20 20 24 6c 6f 67 69 63 61 6c 50 61 74 68 50 73 72 30 20 3d 20 73 74 72 74 72 28 | .......$logicalPathPsr0.=.strtr( |
ab3c0 | 24 63 6c 61 73 73 2c 20 27 5f 27 2c 20 44 49 52 45 43 54 4f 52 59 5f 53 45 50 41 52 41 54 4f 52 | $class,.'_',.DIRECTORY_SEPARATOR |
ab3e0 | 29 20 2e 20 24 65 78 74 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 20 69 66 20 | )...$ext;.........}..........if. |
ab400 | 28 69 73 73 65 74 28 24 74 68 69 73 2d 3e 70 72 65 66 69 78 65 73 50 73 72 30 5b 24 66 69 72 73 | (isset($this->prefixesPsr0[$firs |
ab420 | 74 5d 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 74 68 69 | t])).{.............foreach.($thi |
ab440 | 73 2d 3e 70 72 65 66 69 78 65 73 50 73 72 30 5b 24 66 69 72 73 74 5d 20 61 73 20 24 70 72 65 66 | s->prefixesPsr0[$first].as.$pref |
ab460 | 69 78 20 3d 3e 20 24 64 69 72 73 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 | ix.=>.$dirs).{.................i |
ab480 | 66 20 28 30 20 3d 3d 3d 20 73 74 72 70 6f 73 28 24 63 6c 61 73 73 2c 20 24 70 72 65 66 69 78 29 | f.(0.===.strpos($class,.$prefix) |
ab4a0 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 | ).{.....................foreach. |
ab4c0 | 28 24 64 69 72 73 20 61 73 20 24 64 69 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ($dirs.as.$dir).{............... |
ab4e0 | 20 20 20 20 20 20 20 20 20 20 69 66 20 28 66 69 6c 65 5f 65 78 69 73 74 73 28 24 66 69 6c 65 20 | ..........if.(file_exists($file. |
ab500 | 3d 20 24 64 69 72 20 2e 20 44 49 52 45 43 54 4f 52 59 5f 53 45 50 41 52 41 54 4f 52 20 2e 20 24 | =.$dir...DIRECTORY_SEPARATOR...$ |
ab520 | 6c 6f 67 69 63 61 6c 50 61 74 68 50 73 72 30 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | logicalPathPsr0)).{............. |
ab540 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 66 69 6c 65 3b 0a 20 20 | ................return.$file;... |
ab560 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 | ......................}......... |
ab580 | 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a | ............}.................}. |
ab5a0 | 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 | ............}.........}......... |
ab5c0 | 20 2f 2f 20 50 53 52 2d 30 20 66 61 6c 6c 62 61 63 6b 20 64 69 72 73 0a 20 20 20 20 20 20 20 20 | .//.PSR-0.fallback.dirs......... |
ab5e0 | 66 6f 72 65 61 63 68 20 28 24 74 68 69 73 2d 3e 66 61 6c 6c 62 61 63 6b 44 69 72 73 50 73 72 30 | foreach.($this->fallbackDirsPsr0 |
ab600 | 20 61 73 20 24 64 69 72 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 66 69 6c 65 | .as.$dir).{.............if.(file |
ab620 | 5f 65 78 69 73 74 73 28 24 66 69 6c 65 20 3d 20 24 64 69 72 20 2e 20 44 49 52 45 43 54 4f 52 59 | _exists($file.=.$dir...DIRECTORY |
ab640 | 5f 53 45 50 41 52 41 54 4f 52 20 2e 20 24 6c 6f 67 69 63 61 6c 50 61 74 68 50 73 72 30 29 29 20 | _SEPARATOR...$logicalPathPsr0)). |
ab660 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 66 69 6c 65 3b 0a | {.................return.$file;. |
ab680 | 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 20 20 20 | ............}.........}......... |
ab6a0 | 20 2f 2f 20 50 53 52 2d 30 20 69 6e 63 6c 75 64 65 20 70 61 74 68 73 2e 0a 20 20 20 20 20 20 20 | .//.PSR-0.include.paths......... |
ab6c0 | 20 69 66 20 28 24 74 68 69 73 2d 3e 75 73 65 49 6e 63 6c 75 64 65 50 61 74 68 20 26 26 20 24 66 | .if.($this->useIncludePath.&&.$f |
ab6e0 | 69 6c 65 20 3d 20 73 74 72 65 61 6d 5f 72 65 73 6f 6c 76 65 5f 69 6e 63 6c 75 64 65 5f 70 61 74 | ile.=.stream_resolve_include_pat |
ab700 | 68 28 24 6c 6f 67 69 63 61 6c 50 61 74 68 50 73 72 30 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | h($logicalPathPsr0)).{.......... |
ab720 | 20 20 20 72 65 74 75 72 6e 20 24 66 69 6c 65 3b 0a 20 20 20 20 20 20 20 20 7d 0a 0a 20 20 20 20 | ...return.$file;.........}...... |
ab740 | 20 20 20 20 72 65 74 75 72 6e 20 66 61 6c 73 65 3b 0a 20 20 20 20 7d 0a 7d 0a 0a 2f 2a 2a 0a 20 | ....return.false;.....}.}../**.. |
ab760 | 2a 20 53 63 6f 70 65 20 69 73 6f 6c 61 74 65 64 20 69 6e 63 6c 75 64 65 2e 0a 20 2a 0a 20 2a 20 | *.Scope.isolated.include...*..*. |
ab780 | 50 72 65 76 65 6e 74 73 20 61 63 63 65 73 73 20 74 6f 20 24 74 68 69 73 2f 73 65 6c 66 20 66 72 | Prevents.access.to.$this/self.fr |
ab7a0 | 6f 6d 20 69 6e 63 6c 75 64 65 64 20 66 69 6c 65 73 2e 0a 20 2a 2f 0a 66 75 6e 63 74 69 6f 6e 20 | om.included.files...*/.function. |
ab7c0 | 69 6e 63 6c 75 64 65 46 69 6c 65 28 24 66 69 6c 65 29 0a 7b 0a 20 20 20 20 69 6e 63 6c 75 64 65 | includeFile($file).{.....include |
ab7e0 | 20 24 66 69 6c 65 3b 0a 7d 0a 3c 3f 70 68 70 0a 0a 2f 2f 20 61 75 74 6f 6c 6f 61 64 2e 70 68 70 | .$file;.}.<?php..//.autoload.php |
ab800 | 20 40 67 65 6e 65 72 61 74 65 64 20 62 79 20 43 6f 6d 70 6f 73 65 72 0a 0a 72 65 71 75 69 72 65 | .@generated.by.Composer..require |
ab820 | 5f 6f 6e 63 65 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 63 6f 6d 70 6f 73 65 72 2f 61 75 74 6f 6c | _once.__DIR__...'/composer/autol |
ab840 | 6f 61 64 5f 72 65 61 6c 2e 70 68 70 27 3b 0a 0a 72 65 74 75 72 6e 20 43 6f 6d 70 6f 73 65 72 41 | oad_real.php';..return.ComposerA |
ab860 | 75 74 6f 6c 6f 61 64 65 72 49 6e 69 74 35 30 37 37 34 64 31 33 33 33 30 34 63 35 37 66 36 34 63 | utoloaderInit50774d133304c57f64c |
ab880 | 64 32 30 39 65 32 34 36 61 66 33 31 61 3a 3a 67 65 74 4c 6f 61 64 65 72 28 29 3b 0a 3c 3f 70 68 | d209e246af31a::getLoader();.<?ph |
ab8a0 | 70 0a 0a 6e 61 6d 65 73 70 61 63 65 20 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 4b 65 76 69 6e | p..namespace.HumbugBox3111\Kevin |
ab8c0 | 47 48 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 3b 0a 0a 63 6c 61 73 73 20 54 65 | GH\RequirementChecker;..class.Te |
ab8e0 | 72 6d 69 6e 61 6c 0a 7b 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 24 77 69 64 | rminal.{.....private.static.$wid |
ab900 | 74 68 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 24 68 65 69 67 68 74 3b 0a | th;.....private.static.$height;. |
ab920 | 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 24 73 74 74 79 3b 0a 20 20 20 20 70 75 | ....private.static.$stty;.....pu |
ab940 | 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 57 69 64 74 68 28 29 0a 20 20 20 20 7b 0a 20 | blic.function.getWidth().....{.. |
ab960 | 20 20 20 20 20 20 20 24 77 69 64 74 68 20 3d 20 5c 67 65 74 65 6e 76 28 27 43 4f 4c 55 4d 4e 53 | .......$width.=.\getenv('COLUMNS |
ab980 | 27 29 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 5c 66 61 6c 73 65 20 21 3d 3d 20 24 77 69 64 74 | ');.........if.(\false.!==.$widt |
ab9a0 | 68 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 28 69 6e 74 29 20 5c 74 | h).{.............return.(int).\t |
ab9c0 | 72 69 6d 28 24 77 69 64 74 68 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 | rim($width);.........}.........i |
ab9e0 | 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 73 65 6c 66 3a 3a 24 77 69 64 74 68 29 20 7b 0a 20 20 20 20 | f.(null.===.self::$width).{..... |
aba00 | 20 20 20 20 20 20 20 20 73 65 6c 66 3a 3a 69 6e 69 74 44 69 6d 65 6e 73 69 6f 6e 73 28 29 3b 0a | ........self::initDimensions();. |
aba20 | 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 3a 3a 24 | ........}.........return.self::$ |
aba40 | 77 69 64 74 68 20 3f 3a 20 38 30 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 | width.?:.80;.....}.....public.fu |
aba60 | 6e 63 74 69 6f 6e 20 67 65 74 48 65 69 67 68 74 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 | nction.getHeight().....{........ |
aba80 | 20 24 68 65 69 67 68 74 20 3d 20 5c 67 65 74 65 6e 76 28 27 4c 49 4e 45 53 27 29 3b 0a 20 20 20 | .$height.=.\getenv('LINES');.... |
abaa0 | 20 20 20 20 20 69 66 20 28 5c 66 61 6c 73 65 20 21 3d 3d 20 24 68 65 69 67 68 74 29 20 7b 0a 20 | .....if.(\false.!==.$height).{.. |
abac0 | 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 28 69 6e 74 29 20 5c 74 72 69 6d 28 24 68 | ...........return.(int).\trim($h |
abae0 | 65 69 67 68 74 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 | eight);.........}.........if.(nu |
abb00 | 6c 6c 20 3d 3d 3d 20 73 65 6c 66 3a 3a 24 68 65 69 67 68 74 29 20 7b 0a 20 20 20 20 20 20 20 20 | ll.===.self::$height).{......... |
abb20 | 20 20 20 20 73 65 6c 66 3a 3a 69 6e 69 74 44 69 6d 65 6e 73 69 6f 6e 73 28 29 3b 0a 20 20 20 20 | ....self::initDimensions();..... |
abb40 | 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 3a 3a 24 68 65 69 67 | ....}.........return.self::$heig |
abb60 | 68 74 20 3f 3a 20 35 30 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 | ht.?:.50;.....}.....public.stati |
abb80 | 63 20 66 75 6e 63 74 69 6f 6e 20 68 61 73 53 74 74 79 41 76 61 69 6c 61 62 6c 65 28 29 0a 20 20 | c.function.hasSttyAvailable()... |
abba0 | 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 21 3d 3d 20 73 65 6c 66 3a 3a 24 | ..{.........if.(null.!==.self::$ |
abbc0 | 73 74 74 79 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 3a | stty).{.............return.self: |
abbe0 | 3a 24 73 74 74 79 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 5c | :$stty;.........}.........if.(!\ |
abc00 | 66 75 6e 63 74 69 6f 6e 5f 65 78 69 73 74 73 28 27 65 78 65 63 27 29 29 20 7b 0a 20 20 20 20 20 | function_exists('exec')).{...... |
abc20 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 5c 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 7d 0a | .......return.\false;.........}. |
abc40 | 20 20 20 20 20 20 20 20 5c 65 78 65 63 28 27 73 74 74 79 20 32 3e 26 31 27 2c 20 24 6f 75 74 70 | ........\exec('stty.2>&1',.$outp |
abc60 | 75 74 2c 20 24 65 78 69 74 63 6f 64 65 29 3b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 | ut,.$exitcode);.........return.s |
abc80 | 65 6c 66 3a 3a 24 73 74 74 79 20 3d 20 30 20 3d 3d 3d 20 24 65 78 69 74 63 6f 64 65 3b 0a 20 20 | elf::$stty.=.0.===.$exitcode;... |
abca0 | 20 20 7d 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 | ..}.....private.static.function. |
abcc0 | 69 6e 69 74 44 69 6d 65 6e 73 69 6f 6e 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 | initDimensions().....{.........i |
abce0 | 66 20 28 27 5c 5c 27 20 3d 3d 3d 20 5c 44 49 52 45 43 54 4f 52 59 5f 53 45 50 41 52 41 54 4f 52 | f.('\\'.===.\DIRECTORY_SEPARATOR |
abd00 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 5c 70 72 65 67 5f 6d 61 74 63 68 28 | ).{.............if.(\preg_match( |
abd20 | 27 2f 5e 28 5c 5c 64 2b 29 78 28 5c 5c 64 2b 29 28 3f 3a 20 5c 5c 28 28 5c 5c 64 2b 29 78 28 5c | '/^(\\d+)x(\\d+)(?:.\\((\\d+)x(\ |
abd40 | 5c 64 2b 29 5c 5c 29 29 3f 24 2f 27 2c 20 5c 74 72 69 6d 28 5c 67 65 74 65 6e 76 28 27 41 4e 53 | \d+)\\))?$/',.\trim(\getenv('ANS |
abd60 | 49 43 4f 4e 27 29 29 2c 20 24 6d 61 74 63 68 65 73 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | ICON')),.$matches)).{........... |
abd80 | 20 20 20 20 20 20 73 65 6c 66 3a 3a 24 77 69 64 74 68 20 3d 20 28 69 6e 74 29 20 24 6d 61 74 63 | ......self::$width.=.(int).$matc |
abda0 | 68 65 73 5b 31 5d 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 73 65 6c 66 3a 3a 24 68 | hes[1];.................self::$h |
abdc0 | 65 69 67 68 74 20 3d 20 69 73 73 65 74 28 24 6d 61 74 63 68 65 73 5b 34 5d 29 20 3f 20 28 69 6e | eight.=.isset($matches[4]).?.(in |
abde0 | 74 29 20 24 6d 61 74 63 68 65 73 5b 34 5d 20 3a 20 28 69 6e 74 29 20 24 6d 61 74 63 68 65 73 5b | t).$matches[4].:.(int).$matches[ |
abe00 | 32 5d 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 21 73 65 6c 66 3a | 2];.............}.elseif.(!self: |
abe20 | 3a 68 61 73 56 74 31 30 30 53 75 70 70 6f 72 74 28 29 20 26 26 20 73 65 6c 66 3a 3a 68 61 73 53 | :hasVt100Support().&&.self::hasS |
abe40 | 74 74 79 41 76 61 69 6c 61 62 6c 65 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ttyAvailable()).{............... |
abe60 | 20 20 73 65 6c 66 3a 3a 69 6e 69 74 44 69 6d 65 6e 73 69 6f 6e 73 55 73 69 6e 67 53 74 74 79 28 | ..self::initDimensionsUsingStty( |
abe80 | 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 6e 75 6c 6c 20 21 3d | );.............}.elseif.(null.!= |
abea0 | 3d 20 28 24 64 69 6d 65 6e 73 69 6f 6e 73 20 3d 20 73 65 6c 66 3a 3a 67 65 74 43 6f 6e 73 6f 6c | =.($dimensions.=.self::getConsol |
abec0 | 65 4d 6f 64 65 28 29 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 73 65 6c 66 | eMode())).{.................self |
abee0 | 3a 3a 24 77 69 64 74 68 20 3d 20 28 69 6e 74 29 20 24 64 69 6d 65 6e 73 69 6f 6e 73 5b 30 5d 3b | ::$width.=.(int).$dimensions[0]; |
abf00 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 73 65 6c 66 3a 3a 24 68 65 69 67 68 74 20 3d | .................self::$height.= |
abf20 | 20 28 69 6e 74 29 20 24 64 69 6d 65 6e 73 69 6f 6e 73 5b 31 5d 3b 0a 20 20 20 20 20 20 20 20 20 | .(int).$dimensions[1];.......... |
abf40 | 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | ...}.........}.else.{........... |
abf60 | 20 20 73 65 6c 66 3a 3a 69 6e 69 74 44 69 6d 65 6e 73 69 6f 6e 73 55 73 69 6e 67 53 74 74 79 28 | ..self::initDimensionsUsingStty( |
abf80 | 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 | );.........}.....}.....private.s |
abfa0 | 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 68 61 73 56 74 31 30 30 53 75 70 70 6f 72 74 28 29 | tatic.function.hasVt100Support() |
abfc0 | 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 5c 66 75 6e 63 74 69 6f 6e 5f | .....{.........return.\function_ |
abfe0 | 65 78 69 73 74 73 28 27 73 61 70 69 5f 77 69 6e 64 6f 77 73 5f 76 74 31 30 30 5f 73 75 70 70 6f | exists('sapi_windows_vt100_suppo |
ac000 | 72 74 27 29 20 26 26 20 5c 73 61 70 69 5f 77 69 6e 64 6f 77 73 5f 76 74 31 30 30 5f 73 75 70 70 | rt').&&.\sapi_windows_vt100_supp |
ac020 | 6f 72 74 28 5c 66 6f 70 65 6e 28 27 70 68 70 3a 2f 2f 73 74 64 6f 75 74 27 2c 20 27 77 62 27 29 | ort(\fopen('php://stdout',.'wb') |
ac040 | 29 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 66 75 6e 63 | );.....}.....private.static.func |
ac060 | 74 69 6f 6e 20 69 6e 69 74 44 69 6d 65 6e 73 69 6f 6e 73 55 73 69 6e 67 53 74 74 79 28 29 0a 20 | tion.initDimensionsUsingStty().. |
ac080 | 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 73 74 74 79 53 74 72 69 6e 67 20 3d 20 73 | ...{.........if.($sttyString.=.s |
ac0a0 | 65 6c 66 3a 3a 67 65 74 53 74 74 79 43 6f 6c 75 6d 6e 73 28 29 29 20 7b 0a 20 20 20 20 20 20 20 | elf::getSttyColumns()).{........ |
ac0c0 | 20 20 20 20 20 69 66 20 28 5c 70 72 65 67 5f 6d 61 74 63 68 28 27 2f 72 6f 77 73 2e 28 5c 5c 64 | .....if.(\preg_match('/rows.(\\d |
ac0e0 | 2b 29 3b 2e 63 6f 6c 75 6d 6e 73 2e 28 5c 5c 64 2b 29 3b 2f 69 27 2c 20 24 73 74 74 79 53 74 72 | +);.columns.(\\d+);/i',.$sttyStr |
ac100 | 69 6e 67 2c 20 24 6d 61 74 63 68 65 73 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | ing,.$matches)).{............... |
ac120 | 20 20 73 65 6c 66 3a 3a 24 77 69 64 74 68 20 3d 20 28 69 6e 74 29 20 24 6d 61 74 63 68 65 73 5b | ..self::$width.=.(int).$matches[ |
ac140 | 32 5d 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 73 65 6c 66 3a 3a 24 68 65 69 67 68 | 2];.................self::$heigh |
ac160 | 74 20 3d 20 28 69 6e 74 29 20 24 6d 61 74 63 68 65 73 5b 31 5d 3b 0a 20 20 20 20 20 20 20 20 20 | t.=.(int).$matches[1];.......... |
ac180 | 20 20 20 7d 20 65 6c 73 65 69 66 20 28 5c 70 72 65 67 5f 6d 61 74 63 68 28 27 2f 3b 2e 28 5c 5c | ...}.elseif.(\preg_match('/;.(\\ |
ac1a0 | 64 2b 29 2e 72 6f 77 73 3b 2e 28 5c 5c 64 2b 29 2e 63 6f 6c 75 6d 6e 73 2f 69 27 2c 20 24 73 74 | d+).rows;.(\\d+).columns/i',.$st |
ac1c0 | 74 79 53 74 72 69 6e 67 2c 20 24 6d 61 74 63 68 65 73 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | tyString,.$matches)).{.......... |
ac1e0 | 20 20 20 20 20 20 20 73 65 6c 66 3a 3a 24 77 69 64 74 68 20 3d 20 28 69 6e 74 29 20 24 6d 61 74 | .......self::$width.=.(int).$mat |
ac200 | 63 68 65 73 5b 32 5d 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 73 65 6c 66 3a 3a 24 | ches[2];.................self::$ |
ac220 | 68 65 69 67 68 74 20 3d 20 28 69 6e 74 29 20 24 6d 61 74 63 68 65 73 5b 31 5d 3b 0a 20 20 20 20 | height.=.(int).$matches[1];..... |
ac240 | 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 7d 0a 20 20 20 20 70 72 | ........}.........}.....}.....pr |
ac260 | 69 76 61 74 65 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 43 6f 6e 73 6f 6c 65 | ivate.static.function.getConsole |
ac280 | 4d 6f 64 65 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 69 6e 66 6f 20 3d 20 73 65 6c | Mode().....{.........$info.=.sel |
ac2a0 | 66 3a 3a 72 65 61 64 46 72 6f 6d 50 72 6f 63 65 73 73 28 27 6d 6f 64 65 20 43 4f 4e 27 29 3b 0a | f::readFromProcess('mode.CON');. |
ac2c0 | 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 69 6e 66 6f 20 7c 7c 20 21 5c | ........if.(null.===.$info.||.!\ |
ac2e0 | 70 72 65 67 5f 6d 61 74 63 68 28 27 2f 2d 2d 2d 2d 2d 2d 2d 2d 2b 5c 5c 72 3f 5c 5c 6e 2e 2b 3f | preg_match('/--------+\\r?\\n.+? |
ac300 | 28 5c 5c 64 2b 29 5c 5c 72 3f 5c 5c 6e 2e 2b 3f 28 5c 5c 64 2b 29 5c 5c 72 3f 5c 5c 6e 2f 27 2c | (\\d+)\\r?\\n.+?(\\d+)\\r?\\n/', |
ac320 | 20 24 69 6e 66 6f 2c 20 24 6d 61 74 63 68 65 73 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | .$info,.$matches)).{............ |
ac340 | 20 72 65 74 75 72 6e 20 6e 75 6c 6c 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 | .return.null;.........}......... |
ac360 | 72 65 74 75 72 6e 20 61 72 72 61 79 28 28 69 6e 74 29 20 24 6d 61 74 63 68 65 73 5b 32 5d 2c 20 | return.array((int).$matches[2],. |
ac380 | 28 69 6e 74 29 20 24 6d 61 74 63 68 65 73 5b 31 5d 29 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 72 | (int).$matches[1]);.....}.....pr |
ac3a0 | 69 76 61 74 65 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 53 74 74 79 43 6f 6c | ivate.static.function.getSttyCol |
ac3c0 | 75 6d 6e 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 73 65 6c 66 | umns().....{.........return.self |
ac3e0 | 3a 3a 72 65 61 64 46 72 6f 6d 50 72 6f 63 65 73 73 28 27 73 74 74 79 20 2d 61 20 7c 20 67 72 65 | ::readFromProcess('stty.-a.|.gre |
ac400 | 70 20 63 6f 6c 75 6d 6e 73 27 29 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 | p.columns');.....}.....private.s |
ac420 | 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 72 65 61 64 46 72 6f 6d 50 72 6f 63 65 73 73 28 24 | tatic.function.readFromProcess($ |
ac440 | 63 6f 6d 6d 61 6e 64 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 5c 66 75 6e | command).....{.........if.(!\fun |
ac460 | 63 74 69 6f 6e 5f 65 78 69 73 74 73 28 27 70 72 6f 63 5f 6f 70 65 6e 27 29 29 20 7b 0a 20 20 20 | ction_exists('proc_open')).{.... |
ac480 | 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6e 75 6c 6c 3b 0a 20 20 20 20 20 20 20 20 7d 0a | .........return.null;.........}. |
ac4a0 | 20 20 20 20 20 20 20 20 24 64 65 73 63 72 69 70 74 6f 72 73 70 65 63 20 3d 20 61 72 72 61 79 28 | ........$descriptorspec.=.array( |
ac4c0 | 31 20 3d 3e 20 61 72 72 61 79 28 27 70 69 70 65 27 2c 20 27 77 27 29 2c 20 32 20 3d 3e 20 61 72 | 1.=>.array('pipe',.'w'),.2.=>.ar |
ac4e0 | 72 61 79 28 27 70 69 70 65 27 2c 20 27 77 27 29 29 3b 0a 20 20 20 20 20 20 20 20 24 70 72 6f 63 | ray('pipe',.'w'));.........$proc |
ac500 | 65 73 73 20 3d 20 5c 70 72 6f 63 5f 6f 70 65 6e 28 24 63 6f 6d 6d 61 6e 64 2c 20 24 64 65 73 63 | ess.=.\proc_open($command,.$desc |
ac520 | 72 69 70 74 6f 72 73 70 65 63 2c 20 24 70 69 70 65 73 2c 20 6e 75 6c 6c 2c 20 6e 75 6c 6c 2c 20 | riptorspec,.$pipes,.null,.null,. |
ac540 | 61 72 72 61 79 28 27 73 75 70 70 72 65 73 73 5f 65 72 72 6f 72 73 27 20 3d 3e 20 5c 74 72 75 65 | array('suppress_errors'.=>.\true |
ac560 | 29 29 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 21 5c 69 73 5f 72 65 73 6f 75 72 63 65 28 24 70 | ));.........if.(!\is_resource($p |
ac580 | 72 6f 63 65 73 73 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6e 75 | rocess)).{.............return.nu |
ac5a0 | 6c 6c 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 24 69 6e 66 6f 20 3d 20 5c 73 | ll;.........}.........$info.=.\s |
ac5c0 | 74 72 65 61 6d 5f 67 65 74 5f 63 6f 6e 74 65 6e 74 73 28 24 70 69 70 65 73 5b 31 5d 29 3b 0a 20 | tream_get_contents($pipes[1]);.. |
ac5e0 | 20 20 20 20 20 20 20 5c 66 63 6c 6f 73 65 28 24 70 69 70 65 73 5b 31 5d 29 3b 0a 20 20 20 20 20 | .......\fclose($pipes[1]);...... |
ac600 | 20 20 20 5c 66 63 6c 6f 73 65 28 24 70 69 70 65 73 5b 32 5d 29 3b 0a 20 20 20 20 20 20 20 20 5c | ...\fclose($pipes[2]);.........\ |
ac620 | 70 72 6f 63 5f 63 6c 6f 73 65 28 24 70 72 6f 63 65 73 73 29 3b 0a 20 20 20 20 20 20 20 20 72 65 | proc_close($process);.........re |
ac640 | 74 75 72 6e 20 24 69 6e 66 6f 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 6e 61 6d 65 73 | turn.$info;.....}.}.<?php..names |
ac660 | 70 61 63 65 20 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 4b 65 76 69 6e 47 48 5c 52 65 71 75 69 | pace.HumbugBox3111\KevinGH\Requi |
ac680 | 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 3b 0a 0a 75 73 65 20 41 72 72 61 79 49 74 65 72 61 74 6f | rementChecker;..use.ArrayIterato |
ac6a0 | 72 3b 0a 75 73 65 20 43 6f 75 6e 74 61 62 6c 65 3b 0a 75 73 65 20 49 74 65 72 61 74 6f 72 41 67 | r;.use.Countable;.use.IteratorAg |
ac6c0 | 67 72 65 67 61 74 65 3b 0a 75 73 65 20 54 72 61 76 65 72 73 61 62 6c 65 3b 0a 66 69 6e 61 6c 20 | gregate;.use.Traversable;.final. |
ac6e0 | 63 6c 61 73 73 20 52 65 71 75 69 72 65 6d 65 6e 74 43 6f 6c 6c 65 63 74 69 6f 6e 20 69 6d 70 6c | class.RequirementCollection.impl |
ac700 | 65 6d 65 6e 74 73 20 5c 49 74 65 72 61 74 6f 72 41 67 67 72 65 67 61 74 65 2c 20 5c 43 6f 75 6e | ements.\IteratorAggregate,.\Coun |
ac720 | 74 61 62 6c 65 0a 7b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 72 65 71 75 69 72 65 6d 65 6e 74 | table.{.....private.$requirement |
ac740 | 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e | s.=.array();.....public.function |
ac760 | 20 67 65 74 49 74 65 72 61 74 6f 72 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 | .getIterator().....{.........ret |
ac780 | 75 72 6e 20 6e 65 77 20 5c 41 72 72 61 79 49 74 65 72 61 74 6f 72 28 24 74 68 69 73 2d 3e 72 65 | urn.new.\ArrayIterator($this->re |
ac7a0 | 71 75 69 72 65 6d 65 6e 74 73 29 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 | quirements);.....}.....public.fu |
ac7c0 | 6e 63 74 69 6f 6e 20 63 6f 75 6e 74 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 | nction.count().....{.........ret |
ac7e0 | 75 72 6e 20 5c 63 6f 75 6e 74 28 24 74 68 69 73 2d 3e 72 65 71 75 69 72 65 6d 65 6e 74 73 29 3b | urn.\count($this->requirements); |
ac800 | 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 61 64 64 28 5c | .....}.....public.function.add(\ |
ac820 | 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 4b 65 76 69 6e 47 48 5c 52 65 71 75 69 72 65 6d 65 6e | HumbugBox3111\KevinGH\Requiremen |
ac840 | 74 43 68 65 63 6b 65 72 5c 52 65 71 75 69 72 65 6d 65 6e 74 20 24 72 65 71 75 69 72 65 6d 65 6e | tChecker\Requirement.$requiremen |
ac860 | 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 72 65 71 75 69 72 65 6d | t).....{.........$this->requirem |
ac880 | 65 6e 74 73 5b 5d 20 3d 20 24 72 65 71 75 69 72 65 6d 65 6e 74 3b 0a 20 20 20 20 7d 0a 20 20 20 | ents[].=.$requirement;.....}.... |
ac8a0 | 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 61 64 64 52 65 71 75 69 72 65 6d 65 6e 74 28 | .public.function.addRequirement( |
ac8c0 | 24 63 68 65 63 6b 49 73 46 75 6c 66 69 6c 6c 65 64 2c 20 24 74 65 73 74 4d 65 73 73 61 67 65 2c | $checkIsFulfilled,.$testMessage, |
ac8e0 | 20 24 68 65 6c 70 54 65 78 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d | .$helpText).....{.........$this- |
ac900 | 3e 61 64 64 28 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 4b 65 76 69 6e 47 48 5c | >add(new.\HumbugBox3111\KevinGH\ |
ac920 | 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 5c 52 65 71 75 69 72 65 6d 65 6e 74 28 24 | RequirementChecker\Requirement($ |
ac940 | 63 68 65 63 6b 49 73 46 75 6c 66 69 6c 6c 65 64 2c 20 24 74 65 73 74 4d 65 73 73 61 67 65 2c 20 | checkIsFulfilled,.$testMessage,. |
ac960 | 24 68 65 6c 70 54 65 78 74 29 29 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 | $helpText));.....}.....public.fu |
ac980 | 6e 63 74 69 6f 6e 20 67 65 74 52 65 71 75 69 72 65 6d 65 6e 74 73 28 29 0a 20 20 20 20 7b 0a 20 | nction.getRequirements().....{.. |
ac9a0 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 72 65 71 75 69 72 65 6d 65 6e 74 | .......return.$this->requirement |
ac9c0 | 73 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 | s;.....}.....public.function.get |
ac9e0 | 50 68 70 49 6e 69 50 61 74 68 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 | PhpIniPath().....{.........retur |
aca00 | 6e 20 5c 67 65 74 5f 63 66 67 5f 76 61 72 28 27 63 66 67 5f 66 69 6c 65 5f 70 61 74 68 27 29 3b | n.\get_cfg_var('cfg_file_path'); |
aca20 | 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 65 76 61 6c 75 | .....}.....public.function.evalu |
aca40 | 61 74 65 52 65 71 75 69 72 65 6d 65 6e 74 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | ateRequirements().....{......... |
aca60 | 72 65 74 75 72 6e 20 5c 61 72 72 61 79 5f 72 65 64 75 63 65 28 24 74 68 69 73 2d 3e 72 65 71 75 | return.\array_reduce($this->requ |
aca80 | 69 72 65 6d 65 6e 74 73 2c 20 66 75 6e 63 74 69 6f 6e 20 28 24 63 68 65 63 6b 50 61 73 73 65 64 | irements,.function.($checkPassed |
acaa0 | 2c 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 4b 65 76 69 6e 47 48 5c 52 65 71 75 69 72 65 | ,.\HumbugBox3111\KevinGH\Require |
acac0 | 6d 65 6e 74 43 68 65 63 6b 65 72 5c 52 65 71 75 69 72 65 6d 65 6e 74 20 24 72 65 71 75 69 72 65 | mentChecker\Requirement.$require |
acae0 | 6d 65 6e 74 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 63 68 65 63 | ment).{.............return.$chec |
acb00 | 6b 50 61 73 73 65 64 20 26 26 20 24 72 65 71 75 69 72 65 6d 65 6e 74 2d 3e 69 73 46 75 6c 66 69 | kPassed.&&.$requirement->isFulfi |
acb20 | 6c 6c 65 64 28 29 3b 0a 20 20 20 20 20 20 20 20 7d 2c 20 5c 74 72 75 65 29 3b 0a 20 20 20 20 7d | lled();.........},.\true);.....} |
acb40 | 0a 7d 0a 3c 3f 70 68 70 0a 0a 6e 61 6d 65 73 70 61 63 65 20 48 75 6d 62 75 67 42 6f 78 33 31 31 | .}.<?php..namespace.HumbugBox311 |
acb60 | 31 5c 4b 65 76 69 6e 47 48 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 3b 0a 0a 66 | 1\KevinGH\RequirementChecker;..f |
acb80 | 69 6e 61 6c 20 63 6c 61 73 73 20 52 65 71 75 69 72 65 6d 65 6e 74 0a 7b 0a 20 20 20 20 70 72 69 | inal.class.Requirement.{.....pri |
acba0 | 76 61 74 65 20 24 63 68 65 63 6b 49 73 46 75 6c 66 69 6c 6c 65 64 3b 0a 20 20 20 20 70 72 69 76 | vate.$checkIsFulfilled;.....priv |
acbc0 | 61 74 65 20 24 66 75 6c 66 69 6c 6c 65 64 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 74 65 73 | ate.$fulfilled;.....private.$tes |
acbe0 | 74 4d 65 73 73 61 67 65 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 68 65 6c 70 54 65 78 74 3b | tMessage;.....private.$helpText; |
acc00 | 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 74 | .....public.function.__construct |
acc20 | 28 24 63 68 65 63 6b 49 73 46 75 6c 66 69 6c 6c 65 64 2c 20 24 74 65 73 74 4d 65 73 73 61 67 65 | ($checkIsFulfilled,.$testMessage |
acc40 | 2c 20 24 68 65 6c 70 54 65 78 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 | ,.$helpText).....{.........$this |
acc60 | 2d 3e 63 68 65 63 6b 49 73 46 75 6c 66 69 6c 6c 65 64 20 3d 20 24 63 68 65 63 6b 49 73 46 75 6c | ->checkIsFulfilled.=.$checkIsFul |
acc80 | 66 69 6c 6c 65 64 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 74 65 73 74 4d 65 73 73 61 | filled;.........$this->testMessa |
acca0 | 67 65 20 3d 20 24 74 65 73 74 4d 65 73 73 61 67 65 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 | ge.=.$testMessage;.........$this |
accc0 | 2d 3e 68 65 6c 70 54 65 78 74 20 3d 20 24 68 65 6c 70 54 65 78 74 3b 0a 20 20 20 20 7d 0a 20 20 | ->helpText.=.$helpText;.....}... |
acce0 | 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 69 73 46 75 6c 66 69 6c 6c 65 64 28 29 0a | ..public.function.isFulfilled(). |
acd00 | 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 74 68 69 73 | ....{.........if.(null.===.$this |
acd20 | 2d 3e 66 75 6c 66 69 6c 6c 65 64 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 | ->fulfilled).{.............$this |
acd40 | 2d 3e 66 75 6c 66 69 6c 6c 65 64 20 3d 20 24 74 68 69 73 2d 3e 63 68 65 63 6b 49 73 46 75 6c 66 | ->fulfilled.=.$this->checkIsFulf |
acd60 | 69 6c 6c 65 64 2d 3e 5f 5f 69 6e 76 6f 6b 65 28 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 | illed->__invoke();.........}.... |
acd80 | 20 20 20 20 20 72 65 74 75 72 6e 20 28 62 6f 6f 6c 29 20 24 74 68 69 73 2d 3e 66 75 6c 66 69 6c | .....return.(bool).$this->fulfil |
acda0 | 6c 65 64 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 | led;.....}.....public.function.g |
acdc0 | 65 74 49 73 46 75 6c 6c 66 69 6c 6c 65 64 43 68 65 63 6b 65 72 28 29 0a 20 20 20 20 7b 0a 20 20 | etIsFullfilledChecker().....{... |
acde0 | 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 63 68 65 63 6b 49 73 46 75 6c 66 69 | ......return.$this->checkIsFulfi |
ace00 | 6c 6c 65 64 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 | lled;.....}.....public.function. |
ace20 | 67 65 74 54 65 73 74 4d 65 73 73 61 67 65 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 | getTestMessage().....{.........r |
ace40 | 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 74 65 73 74 4d 65 73 73 61 67 65 3b 0a 20 20 20 20 7d 0a | eturn.$this->testMessage;.....}. |
ace60 | 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 48 65 6c 70 54 65 78 74 28 | ....public.function.getHelpText( |
ace80 | 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 68 65 | ).....{.........return.$this->he |
acea0 | 6c 70 54 65 78 74 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 6e 61 6d 65 73 70 61 63 65 | lpText;.....}.}.<?php..namespace |
acec0 | 20 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 4b 65 76 69 6e 47 48 5c 52 65 71 75 69 72 65 6d 65 | .HumbugBox3111\KevinGH\Requireme |
acee0 | 6e 74 43 68 65 63 6b 65 72 3b 0a 0a 66 69 6e 61 6c 20 63 6c 61 73 73 20 50 72 69 6e 74 65 72 0a | ntChecker;..final.class.Printer. |
acf00 | 7b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 73 74 79 6c 65 73 20 3d 20 61 72 72 61 79 28 27 72 | {.....private.$styles.=.array('r |
acf20 | 65 73 65 74 27 20 3d 3e 20 22 5c 33 33 5b 30 6d 22 2c 20 27 72 65 64 27 20 3d 3e 20 22 5c 33 33 | eset'.=>."\33[0m",.'red'.=>."\33 |
acf40 | 5b 33 31 6d 22 2c 20 27 67 72 65 65 6e 27 20 3d 3e 20 22 5c 33 33 5b 33 32 6d 22 2c 20 27 79 65 | [31m",.'green'.=>."\33[32m",.'ye |
acf60 | 6c 6c 6f 77 27 20 3d 3e 20 22 5c 33 33 5b 33 33 6d 22 2c 20 27 74 69 74 6c 65 27 20 3d 3e 20 22 | llow'.=>."\33[33m",.'title'.=>." |
acf80 | 5c 33 33 5b 33 33 6d 22 2c 20 27 65 72 72 6f 72 27 20 3d 3e 20 22 5c 33 33 5b 33 37 3b 34 31 6d | \33[33m",.'error'.=>."\33[37;41m |
acfa0 | 22 2c 20 27 73 75 63 63 65 73 73 27 20 3d 3e 20 22 5c 33 33 5b 33 30 3b 34 32 6d 22 29 3b 0a 20 | ",.'success'.=>."\33[30;42m");.. |
acfc0 | 20 20 20 70 72 69 76 61 74 65 20 24 76 65 72 62 6f 73 69 74 79 3b 0a 20 20 20 20 70 72 69 76 61 | ...private.$verbosity;.....priva |
acfe0 | 74 65 20 24 73 75 70 70 6f 72 74 43 6f 6c 6f 72 73 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 | te.$supportColors;.....private.$ |
ad000 | 77 69 64 74 68 3b 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 63 6f 6e | width;.....public.function.__con |
ad020 | 73 74 72 75 63 74 28 24 76 65 72 62 6f 73 69 74 79 2c 20 24 73 75 70 70 6f 72 74 43 6f 6c 6f 72 | struct($verbosity,.$supportColor |
ad040 | 73 2c 20 24 77 69 64 74 68 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | s,.$width.=.null).....{......... |
ad060 | 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 24 77 69 64 74 68 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | if.(null.===.$width).{.......... |
ad080 | 20 20 20 24 74 65 72 6d 69 6e 61 6c 20 3d 20 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 | ...$terminal.=.new.\HumbugBox311 |
ad0a0 | 31 5c 4b 65 76 69 6e 47 48 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 5c 54 65 72 | 1\KevinGH\RequirementChecker\Ter |
ad0c0 | 6d 69 6e 61 6c 28 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 77 69 64 74 68 20 3d 20 24 74 | minal();.............$width.=.$t |
ad0e0 | 65 72 6d 69 6e 61 6c 2d 3e 67 65 74 57 69 64 74 68 28 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 | erminal->getWidth();.........}.. |
ad100 | 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 76 65 72 62 6f 73 69 74 79 20 3d 20 24 76 65 72 62 6f | .......$this->verbosity.=.$verbo |
ad120 | 73 69 74 79 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 73 75 70 70 6f 72 74 43 6f 6c 6f | sity;.........$this->supportColo |
ad140 | 72 73 20 3d 20 24 73 75 70 70 6f 72 74 43 6f 6c 6f 72 73 3b 0a 20 20 20 20 20 20 20 20 24 74 68 | rs.=.$supportColors;.........$th |
ad160 | 69 73 2d 3e 77 69 64 74 68 20 3d 20 24 77 69 64 74 68 20 3f 3a 20 38 30 3b 0a 20 20 20 20 7d 0a | is->width.=.$width.?:.80;.....}. |
ad180 | 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 56 65 72 62 6f 73 69 74 79 | ....public.function.getVerbosity |
ad1a0 | 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 76 | ().....{.........return.$this->v |
ad1c0 | 65 72 62 6f 73 69 74 79 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 | erbosity;.....}.....public.funct |
ad1e0 | 69 6f 6e 20 73 65 74 56 65 72 62 6f 73 69 74 79 28 24 76 65 72 62 6f 73 69 74 79 29 0a 20 20 20 | ion.setVerbosity($verbosity).... |
ad200 | 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 76 65 72 62 6f 73 69 74 79 20 3d 20 24 76 | .{.........$this->verbosity.=.$v |
ad220 | 65 72 62 6f 73 69 74 79 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 | erbosity;.....}.....public.funct |
ad240 | 69 6f 6e 20 74 69 74 6c 65 28 24 74 69 74 6c 65 2c 20 24 76 65 72 62 6f 73 69 74 79 2c 20 24 73 | ion.title($title,.$verbosity,.$s |
ad260 | 74 79 6c 65 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 6e | tyle.=.null).....{.........if.(n |
ad280 | 75 6c 6c 20 3d 3d 3d 20 24 73 74 79 6c 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 73 | ull.===.$style).{.............$s |
ad2a0 | 74 79 6c 65 20 3d 20 27 74 69 74 6c 65 27 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 | tyle.=.'title';.........}....... |
ad2c0 | 20 20 24 74 68 69 73 2d 3e 70 72 69 6e 74 76 6c 6e 28 27 27 2c 20 24 76 65 72 62 6f 73 69 74 79 | ..$this->printvln('',.$verbosity |
ad2e0 | 2c 20 24 73 74 79 6c 65 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 70 72 69 6e 74 76 | ,.$style);.........$this->printv |
ad300 | 6c 6e 28 24 74 69 74 6c 65 2c 20 24 76 65 72 62 6f 73 69 74 79 2c 20 24 73 74 79 6c 65 29 3b 0a | ln($title,.$verbosity,.$style);. |
ad320 | 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 70 72 69 6e 74 76 6c 6e 28 5c 73 74 72 5f 72 65 70 | ........$this->printvln(\str_rep |
ad340 | 65 61 74 28 27 3d 27 2c 20 5c 6d 69 6e 28 5c 73 74 72 6c 65 6e 28 24 74 69 74 6c 65 29 2c 20 24 | eat('=',.\min(\strlen($title),.$ |
ad360 | 74 68 69 73 2d 3e 77 69 64 74 68 29 29 2c 20 24 76 65 72 62 6f 73 69 74 79 2c 20 24 73 74 79 6c | this->width)),.$verbosity,.$styl |
ad380 | 65 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 70 72 69 6e 74 76 6c 6e 28 27 27 2c 20 | e);.........$this->printvln('',. |
ad3a0 | 24 76 65 72 62 6f 73 69 74 79 2c 20 24 73 74 79 6c 65 29 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 | $verbosity,.$style);.....}.....p |
ad3c0 | 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 52 65 71 75 69 72 65 6d 65 6e 74 45 72 72 | ublic.function.getRequirementErr |
ad3e0 | 6f 72 4d 65 73 73 61 67 65 28 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 4b 65 76 69 6e 47 48 | orMessage(\HumbugBox3111\KevinGH |
ad400 | 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 5c 52 65 71 75 69 72 65 6d 65 6e 74 20 | \RequirementChecker\Requirement. |
ad420 | 24 72 65 71 75 69 72 65 6d 65 6e 74 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 | $requirement).....{.........if.( |
ad440 | 24 72 65 71 75 69 72 65 6d 65 6e 74 2d 3e 69 73 46 75 6c 66 69 6c 6c 65 64 28 29 29 20 7b 0a 20 | $requirement->isFulfilled()).{.. |
ad460 | 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6e 75 6c 6c 3b 0a 20 20 20 20 20 20 20 20 | ...........return.null;......... |
ad480 | 7d 0a 20 20 20 20 20 20 20 20 24 65 72 72 6f 72 4d 65 73 73 61 67 65 20 3d 20 5c 77 6f 72 64 77 | }.........$errorMessage.=.\wordw |
ad4a0 | 72 61 70 28 24 72 65 71 75 69 72 65 6d 65 6e 74 2d 3e 67 65 74 54 65 73 74 4d 65 73 73 61 67 65 | rap($requirement->getTestMessage |
ad4c0 | 28 29 2c 20 24 74 68 69 73 2d 3e 77 69 64 74 68 20 2d 20 33 2c 20 5c 50 48 50 5f 45 4f 4c 20 2e | (),.$this->width.-.3,.\PHP_EOL.. |
ad4e0 | 20 27 20 20 20 27 29 20 2e 20 5c 50 48 50 5f 45 4f 4c 3b 0a 20 20 20 20 20 20 20 20 72 65 74 75 | .'...')...\PHP_EOL;.........retu |
ad500 | 72 6e 20 24 65 72 72 6f 72 4d 65 73 73 61 67 65 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c | rn.$errorMessage;.....}.....publ |
ad520 | 69 63 20 66 75 6e 63 74 69 6f 6e 20 62 6c 6f 63 6b 28 24 74 69 74 6c 65 2c 20 24 6d 65 73 73 61 | ic.function.block($title,.$messa |
ad540 | 67 65 2c 20 24 76 65 72 62 6f 73 69 74 79 2c 20 24 73 74 79 6c 65 20 3d 20 6e 75 6c 6c 29 0a 20 | ge,.$verbosity,.$style.=.null).. |
ad560 | 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 70 72 65 66 69 78 20 3d 20 27 20 5b 27 20 2e 20 24 74 | ...{.........$prefix.=.'.['...$t |
ad580 | 69 74 6c 65 20 2e 20 27 5d 20 27 3b 0a 20 20 20 20 20 20 20 20 24 6c 69 6e 65 4c 65 6e 67 74 68 | itle...'].';.........$lineLength |
ad5a0 | 20 3d 20 24 74 68 69 73 2d 3e 77 69 64 74 68 20 2d 20 5c 73 74 72 6c 65 6e 28 24 70 72 65 66 69 | .=.$this->width.-.\strlen($prefi |
ad5c0 | 78 29 20 2d 20 31 3b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 6c 69 6e 65 4c 65 6e 67 74 68 20 | x).-.1;.........if.($lineLength. |
ad5e0 | 3c 20 30 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 69 6e 65 4c 65 6e 67 74 68 20 3d | <.0).{.............$lineLength.= |
ad600 | 20 30 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 20 3d | .0;.........}.........$message.= |
ad620 | 20 24 70 72 65 66 69 78 20 2e 20 5c 74 72 69 6d 28 24 6d 65 73 73 61 67 65 29 3b 0a 20 20 20 20 | .$prefix...\trim($message);..... |
ad640 | 20 20 20 20 24 6c 69 6e 65 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 20 20 20 20 20 20 20 24 72 | ....$lines.=.array();.........$r |
ad660 | 65 6d 61 69 6e 69 6e 67 4d 65 73 73 61 67 65 20 3d 20 24 6d 65 73 73 61 67 65 3b 0a 20 20 20 20 | emainingMessage.=.$message;..... |
ad680 | 20 20 20 20 24 77 72 61 70 70 65 64 20 3d 20 5c 77 6f 72 64 77 72 61 70 28 24 72 65 6d 61 69 6e | ....$wrapped.=.\wordwrap($remain |
ad6a0 | 69 6e 67 4d 65 73 73 61 67 65 2c 20 24 6c 69 6e 65 4c 65 6e 67 74 68 2c 20 27 c2 ac 27 29 3b 0a | ingMessage,.$lineLength,.'..');. |
ad6c0 | 20 20 20 20 20 20 20 20 24 77 72 61 70 70 65 64 20 3d 20 5c 65 78 70 6c 6f 64 65 28 27 c2 ac 27 | ........$wrapped.=.\explode('..' |
ad6e0 | 2c 20 24 77 72 61 70 70 65 64 29 3b 0a 20 20 20 20 20 20 20 20 64 6f 20 7b 0a 20 20 20 20 20 20 | ,.$wrapped);.........do.{....... |
ad700 | 20 20 20 20 20 20 24 6c 69 6e 65 20 3d 20 5c 61 72 72 61 79 5f 73 68 69 66 74 28 24 77 72 61 70 | ......$line.=.\array_shift($wrap |
ad720 | 70 65 64 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 6c 69 6e 65 73 20 26 26 20 | ped);.............if.($lines.&&. |
ad740 | 24 6c 69 6e 65 4c 65 6e 67 74 68 20 3e 20 30 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 | $lineLength.>.0).{.............. |
ad760 | 20 20 20 24 6c 69 6e 65 20 3d 20 5c 73 74 72 5f 72 65 70 65 61 74 28 27 20 27 2c 20 5c 73 74 72 | ...$line.=.\str_repeat('.',.\str |
ad780 | 6c 65 6e 28 24 70 72 65 66 69 78 29 29 20 2e 20 5c 6c 74 72 69 6d 28 24 6c 69 6e 65 29 3b 0a 20 | len($prefix))...\ltrim($line);.. |
ad7a0 | 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 6c 69 6e 65 73 5b | ...........}.............$lines[ |
ad7c0 | 5d 20 3d 20 5c 73 74 72 5f 70 61 64 28 24 6c 69 6e 65 2c 20 24 74 68 69 73 2d 3e 77 69 64 74 68 | ].=.\str_pad($line,.$this->width |
ad7e0 | 2c 20 27 20 27 2c 20 5c 53 54 52 5f 50 41 44 5f 52 49 47 48 54 29 3b 0a 20 20 20 20 20 20 20 20 | ,.'.',.\STR_PAD_RIGHT);......... |
ad800 | 7d 20 77 68 69 6c 65 20 28 5c 63 6f 75 6e 74 28 24 77 72 61 70 70 65 64 29 29 3b 0a 20 20 20 20 | }.while.(\count($wrapped));..... |
ad820 | 20 20 20 20 24 74 68 69 73 2d 3e 70 72 69 6e 74 76 6c 6e 28 27 27 2c 20 24 76 65 72 62 6f 73 69 | ....$this->printvln('',.$verbosi |
ad840 | 74 79 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 70 72 69 6e 74 76 6c 6e 28 5c 73 74 | ty);.........$this->printvln(\st |
ad860 | 72 5f 72 65 70 65 61 74 28 27 20 27 2c 20 24 74 68 69 73 2d 3e 77 69 64 74 68 29 2c 20 24 76 65 | r_repeat('.',.$this->width),.$ve |
ad880 | 72 62 6f 73 69 74 79 2c 20 24 73 74 79 6c 65 29 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 | rbosity,.$style);.........foreac |
ad8a0 | 68 20 28 24 6c 69 6e 65 73 20 61 73 20 24 6c 69 6e 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 | h.($lines.as.$line).{........... |
ad8c0 | 20 20 24 74 68 69 73 2d 3e 70 72 69 6e 74 76 6c 6e 28 24 6c 69 6e 65 2c 20 24 76 65 72 62 6f 73 | ..$this->printvln($line,.$verbos |
ad8e0 | 69 74 79 2c 20 24 73 74 79 6c 65 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 | ity,.$style);.........}......... |
ad900 | 24 74 68 69 73 2d 3e 70 72 69 6e 74 76 28 5c 73 74 72 5f 72 65 70 65 61 74 28 27 20 27 2c 20 24 | $this->printv(\str_repeat('.',.$ |
ad920 | 74 68 69 73 2d 3e 77 69 64 74 68 29 2c 20 24 76 65 72 62 6f 73 69 74 79 2c 20 24 73 74 79 6c 65 | this->width),.$verbosity,.$style |
ad940 | 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 70 72 69 6e 74 76 6c 6e 28 27 27 2c 20 24 | );.........$this->printvln('',.$ |
ad960 | 76 65 72 62 6f 73 69 74 79 29 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e | verbosity);.....}.....public.fun |
ad980 | 63 74 69 6f 6e 20 70 72 69 6e 74 76 6c 6e 28 24 6d 65 73 73 61 67 65 2c 20 24 76 65 72 62 6f 73 | ction.printvln($message,.$verbos |
ad9a0 | 69 74 79 2c 20 24 73 74 79 6c 65 20 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 | ity,.$style.=.null).....{....... |
ad9c0 | 20 20 24 74 68 69 73 2d 3e 70 72 69 6e 74 76 28 24 6d 65 73 73 61 67 65 2c 20 24 76 65 72 62 6f | ..$this->printv($message,.$verbo |
ad9e0 | 73 69 74 79 2c 20 24 73 74 79 6c 65 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 70 72 | sity,.$style);.........$this->pr |
ada00 | 69 6e 74 76 28 5c 50 48 50 5f 45 4f 4c 2c 20 24 76 65 72 62 6f 73 69 74 79 2c 20 6e 75 6c 6c 29 | intv(\PHP_EOL,.$verbosity,.null) |
ada20 | 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 70 72 69 6e | ;.....}.....public.function.prin |
ada40 | 74 76 28 24 6d 65 73 73 61 67 65 2c 20 24 76 65 72 62 6f 73 69 74 79 2c 20 24 73 74 79 6c 65 20 | tv($message,.$verbosity,.$style. |
ada60 | 3d 20 6e 75 6c 6c 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 76 65 72 62 6f | =.null).....{.........if.($verbo |
ada80 | 73 69 74 79 20 3e 20 24 74 68 69 73 2d 3e 76 65 72 62 6f 73 69 74 79 29 20 7b 0a 20 20 20 20 20 | sity.>.$this->verbosity).{...... |
adaa0 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 | .......return;.........}........ |
adac0 | 20 24 6d 65 73 73 61 67 65 20 3d 20 5c 77 6f 72 64 77 72 61 70 28 24 6d 65 73 73 61 67 65 2c 20 | .$message.=.\wordwrap($message,. |
adae0 | 24 74 68 69 73 2d 3e 77 69 64 74 68 29 3b 0a 20 20 20 20 20 20 20 20 24 6d 65 73 73 61 67 65 20 | $this->width);.........$message. |
adb00 | 3d 20 5c 73 70 72 69 6e 74 66 28 27 25 73 25 73 25 73 27 2c 20 24 74 68 69 73 2d 3e 73 75 70 70 | =.\sprintf('%s%s%s',.$this->supp |
adb20 | 6f 72 74 43 6f 6c 6f 72 73 20 26 26 20 69 73 73 65 74 28 24 74 68 69 73 2d 3e 73 74 79 6c 65 73 | ortColors.&&.isset($this->styles |
adb40 | 5b 24 73 74 79 6c 65 5d 29 20 3f 20 24 74 68 69 73 2d 3e 73 74 79 6c 65 73 5b 24 73 74 79 6c 65 | [$style]).?.$this->styles[$style |
adb60 | 5d 20 3a 20 27 27 2c 20 24 6d 65 73 73 61 67 65 2c 20 24 74 68 69 73 2d 3e 73 75 70 70 6f 72 74 | ].:.'',.$message,.$this->support |
adb80 | 43 6f 6c 6f 72 73 20 3f 20 24 74 68 69 73 2d 3e 73 74 79 6c 65 73 5b 27 72 65 73 65 74 27 5d 20 | Colors.?.$this->styles['reset']. |
adba0 | 3a 20 27 27 29 3b 0a 20 20 20 20 20 20 20 20 65 63 68 6f 20 24 6d 65 73 73 61 67 65 3b 0a 20 20 | :.'');.........echo.$message;... |
adbc0 | 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 6e 61 6d 65 73 70 61 63 65 20 48 75 6d 62 75 67 42 6f 78 | ..}.}.<?php..namespace.HumbugBox |
adbe0 | 33 31 31 31 5c 4b 65 76 69 6e 47 48 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 3b | 3111\KevinGH\RequirementChecker; |
adc00 | 0a 0a 75 73 65 20 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d | ..use.HumbugBox3111\Composer\Sem |
adc20 | 76 65 72 5c 53 65 6d 76 65 72 3b 0a 66 69 6e 61 6c 20 63 6c 61 73 73 20 49 73 50 68 70 56 65 72 | ver\Semver;.final.class.IsPhpVer |
adc40 | 73 69 6f 6e 46 75 6c 66 69 6c 6c 65 64 20 69 6d 70 6c 65 6d 65 6e 74 73 20 5c 48 75 6d 62 75 67 | sionFulfilled.implements.\Humbug |
adc60 | 42 6f 78 33 31 31 31 5c 4b 65 76 69 6e 47 48 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b | Box3111\KevinGH\RequirementCheck |
adc80 | 65 72 5c 49 73 46 75 6c 66 69 6c 6c 65 64 0a 7b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 72 65 | er\IsFulfilled.{.....private.$re |
adca0 | 71 75 69 72 65 64 50 68 70 56 65 72 73 69 6f 6e 3b 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e | quiredPhpVersion;.....public.fun |
adcc0 | 63 74 69 6f 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 74 28 24 72 65 71 75 69 72 65 64 50 68 70 56 65 | ction.__construct($requiredPhpVe |
adce0 | 72 73 69 6f 6e 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 72 65 71 75 | rsion).....{.........$this->requ |
add00 | 69 72 65 64 50 68 70 56 65 72 73 69 6f 6e 20 3d 20 24 72 65 71 75 69 72 65 64 50 68 70 56 65 72 | iredPhpVersion.=.$requiredPhpVer |
add20 | 73 69 6f 6e 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 | sion;.....}.....public.function. |
add40 | 5f 5f 69 6e 76 6f 6b 65 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 | __invoke().....{.........return. |
add60 | 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 43 6f 6d 70 6f 73 65 72 5c 53 65 6d 76 65 72 5c 53 | \HumbugBox3111\Composer\Semver\S |
add80 | 65 6d 76 65 72 3a 3a 73 61 74 69 73 66 69 65 73 28 5c 73 70 72 69 6e 74 66 28 27 25 64 2e 25 64 | emver::satisfies(\sprintf('%d.%d |
adda0 | 2e 25 64 27 2c 20 5c 50 48 50 5f 4d 41 4a 4f 52 5f 56 45 52 53 49 4f 4e 2c 20 5c 50 48 50 5f 4d | .%d',.\PHP_MAJOR_VERSION,.\PHP_M |
addc0 | 49 4e 4f 52 5f 56 45 52 53 49 4f 4e 2c 20 5c 50 48 50 5f 52 45 4c 45 41 53 45 5f 56 45 52 53 49 | INOR_VERSION,.\PHP_RELEASE_VERSI |
adde0 | 4f 4e 29 2c 20 24 74 68 69 73 2d 3e 72 65 71 75 69 72 65 64 50 68 70 56 65 72 73 69 6f 6e 29 3b | ON),.$this->requiredPhpVersion); |
ade00 | 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 6e 61 6d 65 73 70 61 63 65 20 48 75 6d 62 75 67 | .....}.}.<?php..namespace.Humbug |
ade20 | 42 6f 78 33 31 31 31 5c 4b 65 76 69 6e 47 48 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b | Box3111\KevinGH\RequirementCheck |
ade40 | 65 72 3b 0a 0a 69 6e 74 65 72 66 61 63 65 20 49 73 46 75 6c 66 69 6c 6c 65 64 0a 7b 0a 20 20 20 | er;..interface.IsFulfilled.{.... |
ade60 | 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 69 6e 76 6f 6b 65 28 29 3b 0a 7d 0a 3c | .public.function.__invoke();.}.< |
ade80 | 3f 70 68 70 0a 0a 6e 61 6d 65 73 70 61 63 65 20 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 4b 65 | ?php..namespace.HumbugBox3111\Ke |
adea0 | 76 69 6e 47 48 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 3b 0a 0a 66 69 6e 61 6c | vinGH\RequirementChecker;..final |
adec0 | 20 63 6c 61 73 73 20 49 73 45 78 74 65 6e 73 69 6f 6e 46 75 6c 66 69 6c 6c 65 64 20 69 6d 70 6c | .class.IsExtensionFulfilled.impl |
adee0 | 65 6d 65 6e 74 73 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 4b 65 76 69 6e 47 48 5c 52 65 | ements.\HumbugBox3111\KevinGH\Re |
adf00 | 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 5c 49 73 46 75 6c 66 69 6c 6c 65 64 0a 7b 0a 20 | quirementChecker\IsFulfilled.{.. |
adf20 | 20 20 20 70 72 69 76 61 74 65 20 24 72 65 71 75 69 72 65 64 45 78 74 65 6e 73 69 6f 6e 3b 0a 20 | ...private.$requiredExtension;.. |
adf40 | 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 74 28 24 | ...public.function.__construct($ |
adf60 | 72 65 71 75 69 72 65 64 45 78 74 65 6e 73 69 6f 6e 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 | requiredExtension).....{........ |
adf80 | 20 24 74 68 69 73 2d 3e 72 65 71 75 69 72 65 64 45 78 74 65 6e 73 69 6f 6e 20 3d 20 24 72 65 71 | .$this->requiredExtension.=.$req |
adfa0 | 75 69 72 65 64 45 78 74 65 6e 73 69 6f 6e 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 | uiredExtension;.....}.....public |
adfc0 | 20 66 75 6e 63 74 69 6f 6e 20 5f 5f 69 6e 76 6f 6b 65 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 | .function.__invoke().....{...... |
adfe0 | 20 20 20 72 65 74 75 72 6e 20 5c 65 78 74 65 6e 73 69 6f 6e 5f 6c 6f 61 64 65 64 28 24 74 68 69 | ...return.\extension_loaded($thi |
ae000 | 73 2d 3e 72 65 71 75 69 72 65 64 45 78 74 65 6e 73 69 6f 6e 29 3b 0a 20 20 20 20 7d 0a 7d 0a 3c | s->requiredExtension);.....}.}.< |
ae020 | 3f 70 68 70 0a 0a 6e 61 6d 65 73 70 61 63 65 20 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 4b 65 | ?php..namespace.HumbugBox3111\Ke |
ae040 | 76 69 6e 47 48 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 3b 0a 0a 66 69 6e 61 6c | vinGH\RequirementChecker;..final |
ae060 | 20 63 6c 61 73 73 20 49 4f 0a 7b 0a 20 20 20 20 63 6f 6e 73 74 20 56 45 52 42 4f 53 49 54 59 5f | .class.IO.{.....const.VERBOSITY_ |
ae080 | 51 55 49 45 54 20 3d 20 31 36 3b 0a 20 20 20 20 63 6f 6e 73 74 20 56 45 52 42 4f 53 49 54 59 5f | QUIET.=.16;.....const.VERBOSITY_ |
ae0a0 | 4e 4f 52 4d 41 4c 20 3d 20 33 32 3b 0a 20 20 20 20 63 6f 6e 73 74 20 56 45 52 42 4f 53 49 54 59 | NORMAL.=.32;.....const.VERBOSITY |
ae0c0 | 5f 56 45 52 42 4f 53 45 20 3d 20 36 34 3b 0a 20 20 20 20 63 6f 6e 73 74 20 56 45 52 42 4f 53 49 | _VERBOSE.=.64;.....const.VERBOSI |
ae0e0 | 54 59 5f 56 45 52 59 5f 56 45 52 42 4f 53 45 20 3d 20 31 32 38 3b 0a 20 20 20 20 63 6f 6e 73 74 | TY_VERY_VERBOSE.=.128;.....const |
ae100 | 20 56 45 52 42 4f 53 49 54 59 5f 44 45 42 55 47 20 3d 20 32 35 36 3b 0a 20 20 20 20 70 72 69 76 | .VERBOSITY_DEBUG.=.256;.....priv |
ae120 | 61 74 65 20 24 69 6e 74 65 72 61 63 74 69 76 65 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 76 | ate.$interactive;.....private.$v |
ae140 | 65 72 62 6f 73 69 74 79 20 3d 20 73 65 6c 66 3a 3a 56 45 52 42 4f 53 49 54 59 5f 4e 4f 52 4d 41 | erbosity.=.self::VERBOSITY_NORMA |
ae160 | 4c 3b 0a 20 20 20 20 70 72 69 76 61 74 65 20 24 63 6f 6c 6f 72 53 75 70 70 6f 72 74 3b 0a 20 20 | L;.....private.$colorSupport;... |
ae180 | 20 20 70 72 69 76 61 74 65 20 24 6f 70 74 69 6f 6e 73 3b 0a 20 20 20 20 70 75 62 6c 69 63 20 66 | ..private.$options;.....public.f |
ae1a0 | 75 6e 63 74 69 6f 6e 20 5f 5f 63 6f 6e 73 74 72 75 63 74 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 | unction.__construct().....{..... |
ae1c0 | 20 20 20 20 24 74 68 69 73 2d 3e 6f 70 74 69 6f 6e 73 20 3d 20 5c 69 6d 70 6c 6f 64 65 28 27 20 | ....$this->options.=.\implode('. |
ae1e0 | 27 2c 20 24 5f 53 45 52 56 45 52 5b 27 61 72 67 76 27 5d 29 3b 0a 20 20 20 20 20 20 20 20 24 73 | ',.$_SERVER['argv']);.........$s |
ae200 | 68 65 6c 6c 56 65 72 62 6f 73 69 74 79 20 3d 20 24 74 68 69 73 2d 3e 63 6f 6e 66 69 67 75 72 65 | hellVerbosity.=.$this->configure |
ae220 | 56 65 72 62 6f 73 69 74 79 28 29 3b 0a 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 69 6e 74 65 | Verbosity();.........$this->inte |
ae240 | 72 61 63 74 69 76 65 20 3d 20 24 74 68 69 73 2d 3e 63 68 65 63 6b 49 6e 74 65 72 61 63 74 69 76 | ractive.=.$this->checkInteractiv |
ae260 | 69 74 79 28 24 73 68 65 6c 6c 56 65 72 62 6f 73 69 74 79 29 3b 0a 20 20 20 20 20 20 20 20 24 74 | ity($shellVerbosity);.........$t |
ae280 | 68 69 73 2d 3e 63 6f 6c 6f 72 53 75 70 70 6f 72 74 20 3d 20 24 74 68 69 73 2d 3e 63 68 65 63 6b | his->colorSupport.=.$this->check |
ae2a0 | 43 6f 6c 6f 72 53 75 70 70 6f 72 74 28 29 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 | ColorSupport();.....}.....public |
ae2c0 | 20 66 75 6e 63 74 69 6f 6e 20 69 73 49 6e 74 65 72 61 63 74 69 76 65 28 29 0a 20 20 20 20 7b 0a | .function.isInteractive().....{. |
ae2e0 | 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 69 6e 74 65 72 61 63 74 69 76 | ........return.$this->interactiv |
ae300 | 65 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 67 65 74 | e;.....}.....public.function.get |
ae320 | 56 65 72 62 6f 73 69 74 79 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e | Verbosity().....{.........return |
ae340 | 20 24 74 68 69 73 2d 3e 76 65 72 62 6f 73 69 74 79 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 | .$this->verbosity;.....}.....pub |
ae360 | 6c 69 63 20 66 75 6e 63 74 69 6f 6e 20 68 61 73 43 6f 6c 6f 72 53 75 70 70 6f 72 74 28 29 0a 20 | lic.function.hasColorSupport().. |
ae380 | 20 20 20 7b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 74 68 69 73 2d 3e 63 6f 6c 6f 72 | ...{.........return.$this->color |
ae3a0 | 53 75 70 70 6f 72 74 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 66 75 6e 63 74 69 | Support;.....}.....public.functi |
ae3c0 | 6f 6e 20 68 61 73 50 61 72 61 6d 65 74 65 72 28 24 76 61 6c 75 65 73 29 0a 20 20 20 20 7b 0a 20 | on.hasParameter($values).....{.. |
ae3e0 | 20 20 20 20 20 20 20 24 76 61 6c 75 65 73 20 3d 20 28 61 72 72 61 79 29 20 24 76 61 6c 75 65 73 | .......$values.=.(array).$values |
ae400 | 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 76 61 6c 75 65 73 20 61 73 20 24 76 | ;.........foreach.($values.as.$v |
ae420 | 61 6c 75 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 72 65 67 65 78 70 20 3d 20 5c 73 | alue).{.............$regexp.=.\s |
ae440 | 70 72 69 6e 74 66 28 27 2f 5c 5c 73 25 73 5c 5c 62 2f 27 2c 20 5c 73 74 72 5f 72 65 70 6c 61 63 | printf('/\\s%s\\b/',.\str_replac |
ae460 | 65 28 27 20 27 2c 20 27 5c 5c 73 2b 27 2c 20 5c 70 72 65 67 5f 71 75 6f 74 65 28 24 76 61 6c 75 | e('.',.'\\s+',.\preg_quote($valu |
ae480 | 65 2c 20 27 2f 27 29 29 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 31 20 3d 3d 3d | e,.'/')));.............if.(1.=== |
ae4a0 | 20 5c 70 72 65 67 5f 6d 61 74 63 68 28 24 72 65 67 65 78 70 2c 20 24 74 68 69 73 2d 3e 6f 70 74 | .\preg_match($regexp,.$this->opt |
ae4c0 | 69 6f 6e 73 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 | ions)).{.................return. |
ae4e0 | 5c 74 72 75 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 20 | \true;.............}.........}.. |
ae500 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 5c 66 61 6c 73 65 3b 0a 20 20 20 20 7d 0a 20 20 20 20 | .......return.\false;.....}..... |
ae520 | 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 63 68 65 63 6b 49 6e 74 65 72 61 63 74 69 76 | private.function.checkInteractiv |
ae540 | 69 74 79 28 24 73 68 65 6c 6c 56 65 72 62 6f 73 69 74 79 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 | ity($shellVerbosity).....{...... |
ae560 | 20 20 20 69 66 20 28 2d 31 20 3d 3d 3d 20 24 73 68 65 6c 6c 56 65 72 62 6f 73 69 74 79 29 20 7b | ...if.(-1.===.$shellVerbosity).{ |
ae580 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 5c 66 61 6c 73 65 3b 0a 20 20 20 20 | .............return.\false;..... |
ae5a0 | 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 5c 74 72 75 65 20 3d 3d 3d 20 24 74 68 69 | ....}.........if.(\true.===.$thi |
ae5c0 | 73 2d 3e 68 61 73 50 61 72 61 6d 65 74 65 72 28 61 72 72 61 79 28 27 2d 2d 6e 6f 2d 69 6e 74 65 | s->hasParameter(array('--no-inte |
ae5e0 | 72 61 63 74 69 6f 6e 27 2c 20 27 2d 6e 27 29 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | raction',.'-n'))).{............. |
ae600 | 72 65 74 75 72 6e 20 5c 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 | return.\false;.........}........ |
ae620 | 20 69 66 20 28 5c 66 75 6e 63 74 69 6f 6e 5f 65 78 69 73 74 73 28 27 70 6f 73 69 78 5f 69 73 61 | .if.(\function_exists('posix_isa |
ae640 | 74 74 79 27 29 20 26 26 20 21 40 5c 70 6f 73 69 78 5f 69 73 61 74 74 79 28 5c 53 54 44 4f 55 54 | tty').&&.!@\posix_isatty(\STDOUT |
ae660 | 29 20 26 26 20 5c 66 61 6c 73 65 20 3d 3d 3d 20 5c 67 65 74 65 6e 76 28 27 53 48 45 4c 4c 5f 49 | ).&&.\false.===.\getenv('SHELL_I |
ae680 | 4e 54 45 52 41 43 54 49 56 45 27 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 | NTERACTIVE')).{.............retu |
ae6a0 | 72 6e 20 5c 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 72 65 74 | rn.\false;.........}.........ret |
ae6c0 | 75 72 6e 20 5c 74 72 75 65 3b 0a 20 20 20 20 7d 0a 20 20 20 20 70 72 69 76 61 74 65 20 66 75 6e | urn.\true;.....}.....private.fun |
ae6e0 | 63 74 69 6f 6e 20 63 6f 6e 66 69 67 75 72 65 56 65 72 62 6f 73 69 74 79 28 29 0a 20 20 20 20 7b | ction.configureVerbosity().....{ |
ae700 | 0a 20 20 20 20 20 20 20 20 73 77 69 74 63 68 20 28 24 73 68 65 6c 6c 56 65 72 62 6f 73 69 74 79 | .........switch.($shellVerbosity |
ae720 | 20 3d 20 28 69 6e 74 29 20 5c 67 65 74 65 6e 76 28 27 53 48 45 4c 4c 5f 56 45 52 42 4f 53 49 54 | .=.(int).\getenv('SHELL_VERBOSIT |
ae740 | 59 27 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 63 61 73 65 20 2d 31 3a 0a 20 20 20 20 | Y')).{.............case.-1:..... |
ae760 | 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 76 65 72 62 6f 73 69 74 79 20 3d 20 73 | ............$this->verbosity.=.s |
ae780 | 65 6c 66 3a 3a 56 45 52 42 4f 53 49 54 59 5f 51 55 49 45 54 3b 0a 20 20 20 20 20 20 20 20 20 20 | elf::VERBOSITY_QUIET;........... |
ae7a0 | 20 20 20 20 20 20 62 72 65 61 6b 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 63 61 73 65 20 31 3a | ......break;.............case.1: |
ae7c0 | 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 76 65 72 62 6f 73 69 74 | .................$this->verbosit |
ae7e0 | 79 20 3d 20 73 65 6c 66 3a 3a 56 45 52 42 4f 53 49 54 59 5f 56 45 52 42 4f 53 45 3b 0a 20 20 20 | y.=.self::VERBOSITY_VERBOSE;.... |
ae800 | 20 20 20 20 20 20 20 20 20 20 20 20 20 62 72 65 61 6b 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | .............break;............. |
ae820 | 63 61 73 65 20 32 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 76 | case.2:.................$this->v |
ae840 | 65 72 62 6f 73 69 74 79 20 3d 20 73 65 6c 66 3a 3a 56 45 52 42 4f 53 49 54 59 5f 56 45 52 59 5f | erbosity.=.self::VERBOSITY_VERY_ |
ae860 | 56 45 52 42 4f 53 45 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 62 72 65 61 6b 3b 0a | VERBOSE;.................break;. |
ae880 | 20 20 20 20 20 20 20 20 20 20 20 20 63 61 73 65 20 33 3a 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ............case.3:............. |
ae8a0 | 20 20 20 20 24 74 68 69 73 2d 3e 76 65 72 62 6f 73 69 74 79 20 3d 20 73 65 6c 66 3a 3a 56 45 52 | ....$this->verbosity.=.self::VER |
ae8c0 | 42 4f 53 49 54 59 5f 44 45 42 55 47 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 62 72 | BOSITY_DEBUG;.................br |
ae8e0 | 65 61 6b 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 64 65 66 61 75 6c 74 3a 0a 20 20 20 20 20 20 | eak;.............default:....... |
ae900 | 20 20 20 20 20 20 20 20 20 20 24 73 68 65 6c 6c 56 65 72 62 6f 73 69 74 79 20 3d 20 30 3b 0a 20 | ..........$shellVerbosity.=.0;.. |
ae920 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 62 72 65 61 6b 3b 0a 20 20 20 20 20 20 20 20 7d 0a | ...............break;.........}. |
ae940 | 20 20 20 20 20 20 20 20 69 66 20 28 24 74 68 69 73 2d 3e 68 61 73 50 61 72 61 6d 65 74 65 72 28 | ........if.($this->hasParameter( |
ae960 | 61 72 72 61 79 28 27 2d 2d 71 75 69 65 74 27 2c 20 27 2d 71 27 29 29 29 20 7b 0a 20 20 20 20 20 | array('--quiet',.'-q'))).{...... |
ae980 | 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 76 65 72 62 6f 73 69 74 79 20 3d 20 73 65 6c 66 3a 3a | .......$this->verbosity.=.self:: |
ae9a0 | 56 45 52 42 4f 53 49 54 59 5f 51 55 49 45 54 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 73 68 | VERBOSITY_QUIET;.............$sh |
ae9c0 | 65 6c 6c 56 65 72 62 6f 73 69 74 79 20 3d 20 2d 31 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 | ellVerbosity.=.-1;.........}.els |
ae9e0 | 65 69 66 20 28 24 74 68 69 73 2d 3e 68 61 73 50 61 72 61 6d 65 74 65 72 28 61 72 72 61 79 28 27 | eif.($this->hasParameter(array(' |
aea00 | 2d 76 76 76 27 2c 20 27 2d 2d 76 65 72 62 6f 73 65 3d 33 27 2c 20 27 2d 2d 76 65 72 62 6f 73 65 | -vvv',.'--verbose=3',.'--verbose |
aea20 | 20 33 27 29 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 74 68 69 73 2d 3e 76 65 72 62 | .3'))).{.............$this->verb |
aea40 | 6f 73 69 74 79 20 3d 20 73 65 6c 66 3a 3a 56 45 52 42 4f 53 49 54 59 5f 44 45 42 55 47 3b 0a 20 | osity.=.self::VERBOSITY_DEBUG;.. |
aea60 | 20 20 20 20 20 20 20 20 20 20 20 24 73 68 65 6c 6c 56 65 72 62 6f 73 69 74 79 20 3d 20 33 3b 0a | ...........$shellVerbosity.=.3;. |
aea80 | 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 69 66 20 28 24 74 68 69 73 2d 3e 68 61 73 50 61 72 61 | ........}.elseif.($this->hasPara |
aeaa0 | 6d 65 74 65 72 28 61 72 72 61 79 28 27 2d 76 76 27 2c 20 27 2d 2d 76 65 72 62 6f 73 65 3d 32 27 | meter(array('-vv',.'--verbose=2' |
aeac0 | 2c 20 27 2d 2d 76 65 72 62 6f 73 65 20 32 27 29 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | ,.'--verbose.2'))).{............ |
aeae0 | 20 24 74 68 69 73 2d 3e 76 65 72 62 6f 73 69 74 79 20 3d 20 73 65 6c 66 3a 3a 56 45 52 42 4f 53 | .$this->verbosity.=.self::VERBOS |
aeb00 | 49 54 59 5f 56 45 52 59 5f 56 45 52 42 4f 53 45 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 73 | ITY_VERY_VERBOSE;.............$s |
aeb20 | 68 65 6c 6c 56 65 72 62 6f 73 69 74 79 20 3d 20 32 3b 0a 20 20 20 20 20 20 20 20 7d 20 65 6c 73 | hellVerbosity.=.2;.........}.els |
aeb40 | 65 69 66 20 28 24 74 68 69 73 2d 3e 68 61 73 50 61 72 61 6d 65 74 65 72 28 61 72 72 61 79 28 27 | eif.($this->hasParameter(array(' |
aeb60 | 2d 76 27 2c 20 27 2d 2d 76 65 72 62 6f 73 65 3d 31 27 2c 20 27 2d 2d 76 65 72 62 6f 73 65 20 31 | -v',.'--verbose=1',.'--verbose.1 |
aeb80 | 27 2c 20 27 2d 2d 76 65 72 62 6f 73 65 27 29 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 | ',.'--verbose'))).{............. |
aeba0 | 24 74 68 69 73 2d 3e 76 65 72 62 6f 73 69 74 79 20 3d 20 73 65 6c 66 3a 3a 56 45 52 42 4f 53 49 | $this->verbosity.=.self::VERBOSI |
aebc0 | 54 59 5f 56 45 52 42 4f 53 45 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 73 68 65 6c 6c 56 65 | TY_VERBOSE;.............$shellVe |
aebe0 | 72 62 6f 73 69 74 79 20 3d 20 31 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 72 | rbosity.=.1;.........}.........r |
aec00 | 65 74 75 72 6e 20 24 73 68 65 6c 6c 56 65 72 62 6f 73 69 74 79 3b 0a 20 20 20 20 7d 0a 20 20 20 | eturn.$shellVerbosity;.....}.... |
aec20 | 20 70 72 69 76 61 74 65 20 66 75 6e 63 74 69 6f 6e 20 63 68 65 63 6b 43 6f 6c 6f 72 53 75 70 70 | .private.function.checkColorSupp |
aec40 | 6f 72 74 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 74 68 69 73 2d 3e 68 | ort().....{.........if.($this->h |
aec60 | 61 73 50 61 72 61 6d 65 74 65 72 28 61 72 72 61 79 28 27 2d 2d 61 6e 73 69 27 29 29 29 20 7b 0a | asParameter(array('--ansi'))).{. |
aec80 | 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 5c 74 72 75 65 3b 0a 20 20 20 20 20 20 | ............return.\true;....... |
aeca0 | 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 24 74 68 69 73 2d 3e 68 61 73 50 61 72 61 6d 65 | ..}.........if.($this->hasParame |
aecc0 | 74 65 72 28 61 72 72 61 79 28 27 2d 2d 6e 6f 2d 61 6e 73 69 27 29 29 29 20 7b 0a 20 20 20 20 20 | ter(array('--no-ansi'))).{...... |
aece0 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 5c 66 61 6c 73 65 3b 0a 20 20 20 20 20 20 20 20 7d 0a | .......return.\false;.........}. |
aed00 | 20 20 20 20 20 20 20 20 69 66 20 28 5c 44 49 52 45 43 54 4f 52 59 5f 53 45 50 41 52 41 54 4f 52 | ........if.(\DIRECTORY_SEPARATOR |
aed20 | 20 3d 3d 3d 20 27 5c 5c 27 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 | .===.'\\').{.............return. |
aed40 | 5c 66 75 6e 63 74 69 6f 6e 5f 65 78 69 73 74 73 28 27 73 61 70 69 5f 77 69 6e 64 6f 77 73 5f 76 | \function_exists('sapi_windows_v |
aed60 | 74 31 30 30 5f 73 75 70 70 6f 72 74 27 29 20 26 26 20 5c 73 61 70 69 5f 77 69 6e 64 6f 77 73 5f | t100_support').&&.\sapi_windows_ |
aed80 | 76 74 31 30 30 5f 73 75 70 70 6f 72 74 28 5c 53 54 44 4f 55 54 29 20 7c 7c 20 5c 66 61 6c 73 65 | vt100_support(\STDOUT).||.\false |
aeda0 | 20 21 3d 3d 20 5c 67 65 74 65 6e 76 28 27 41 4e 53 49 43 4f 4e 27 29 20 7c 7c 20 27 4f 4e 27 20 | .!==.\getenv('ANSICON').||.'ON'. |
aedc0 | 3d 3d 3d 20 5c 67 65 74 65 6e 76 28 27 43 6f 6e 45 6d 75 41 4e 53 49 27 29 20 7c 7c 20 27 78 74 | ===.\getenv('ConEmuANSI').||.'xt |
aede0 | 65 72 6d 27 20 3d 3d 3d 20 5c 67 65 74 65 6e 76 28 27 54 45 52 4d 27 29 3b 0a 20 20 20 20 20 20 | erm'.===.\getenv('TERM');....... |
aee00 | 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 5c 66 75 6e 63 74 69 6f 6e 5f 65 78 69 73 74 73 | ..}.........if.(\function_exists |
aee20 | 28 27 73 74 72 65 61 6d 5f 69 73 61 74 74 79 27 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 | ('stream_isatty')).{............ |
aee40 | 20 72 65 74 75 72 6e 20 5c 73 74 72 65 61 6d 5f 69 73 61 74 74 79 28 5c 53 54 44 4f 55 54 29 3b | .return.\stream_isatty(\STDOUT); |
aee60 | 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 69 66 20 28 5c 66 75 6e 63 74 69 6f 6e | .........}.........if.(\function |
aee80 | 5f 65 78 69 73 74 73 28 27 70 6f 73 69 78 5f 69 73 61 74 74 79 27 29 29 20 7b 0a 20 20 20 20 20 | _exists('posix_isatty')).{...... |
aeea0 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 5c 70 6f 73 69 78 5f 69 73 61 74 74 79 28 5c 53 54 44 | .......return.\posix_isatty(\STD |
aeec0 | 4f 55 54 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 24 73 74 61 74 20 3d 20 | OUT);.........}.........$stat.=. |
aeee0 | 5c 66 73 74 61 74 28 5c 53 54 44 4f 55 54 29 3b 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 | \fstat(\STDOUT);.........return. |
aef00 | 24 73 74 61 74 20 3f 20 30 32 30 30 30 30 20 3d 3d 3d 20 28 24 73 74 61 74 5b 27 6d 6f 64 65 27 | $stat.?.020000.===.($stat['mode' |
aef20 | 5d 20 26 20 30 31 37 30 30 30 30 29 20 3a 20 5c 66 61 6c 73 65 3b 0a 20 20 20 20 7d 0a 7d 0a 3c | ].&.0170000).:.\false;.....}.}.< |
aef40 | 3f 70 68 70 0a 0a 6e 61 6d 65 73 70 61 63 65 20 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 4b 65 | ?php..namespace.HumbugBox3111\Ke |
aef60 | 76 69 6e 47 48 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 3b 0a 0a 66 69 6e 61 6c | vinGH\RequirementChecker;..final |
aef80 | 20 63 6c 61 73 73 20 43 68 65 63 6b 65 72 0a 7b 0a 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 | .class.Checker.{.....private.sta |
aefa0 | 74 69 63 20 24 72 65 71 75 69 72 65 6d 65 6e 74 73 43 6f 6e 66 69 67 3b 0a 20 20 20 20 70 75 62 | tic.$requirementsConfig;.....pub |
aefc0 | 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 63 68 65 63 6b 52 65 71 75 69 72 65 | lic.static.function.checkRequire |
aefe0 | 6d 65 6e 74 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 24 72 65 71 75 69 72 65 6d 65 | ments().....{.........$requireme |
af000 | 6e 74 73 20 3d 20 73 65 6c 66 3a 3a 72 65 74 72 69 65 76 65 52 65 71 75 69 72 65 6d 65 6e 74 73 | nts.=.self::retrieveRequirements |
af020 | 28 29 3b 0a 20 20 20 20 20 20 20 20 24 63 68 65 63 6b 50 61 73 73 65 64 20 3d 20 24 72 65 71 75 | ();.........$checkPassed.=.$requ |
af040 | 69 72 65 6d 65 6e 74 73 2d 3e 65 76 61 6c 75 61 74 65 52 65 71 75 69 72 65 6d 65 6e 74 73 28 29 | irements->evaluateRequirements() |
af060 | 3b 0a 20 20 20 20 20 20 20 20 24 69 6f 20 3d 20 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 | ;.........$io.=.new.\HumbugBox31 |
af080 | 31 31 5c 4b 65 76 69 6e 47 48 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 5c 49 4f | 11\KevinGH\RequirementChecker\IO |
af0a0 | 28 29 3b 0a 20 20 20 20 20 20 20 20 73 65 6c 66 3a 3a 70 72 69 6e 74 43 68 65 63 6b 28 24 63 68 | ();.........self::printCheck($ch |
af0c0 | 65 63 6b 50 61 73 73 65 64 2c 20 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 4b 65 | eckPassed,.new.\HumbugBox3111\Ke |
af0e0 | 76 69 6e 47 48 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 5c 50 72 69 6e 74 65 72 | vinGH\RequirementChecker\Printer |
af100 | 28 24 69 6f 2d 3e 67 65 74 56 65 72 62 6f 73 69 74 79 28 29 2c 20 24 69 6f 2d 3e 68 61 73 43 6f | ($io->getVerbosity(),.$io->hasCo |
af120 | 6c 6f 72 53 75 70 70 6f 72 74 28 29 29 2c 20 24 72 65 71 75 69 72 65 6d 65 6e 74 73 29 3b 0a 20 | lorSupport()),.$requirements);.. |
af140 | 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 63 68 65 63 6b 50 61 73 73 65 64 3b 0a 20 20 20 20 | .......return.$checkPassed;..... |
af160 | 7d 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 70 72 69 | }.....public.static.function.pri |
af180 | 6e 74 43 68 65 63 6b 28 24 63 68 65 63 6b 50 61 73 73 65 64 2c 20 5c 48 75 6d 62 75 67 42 6f 78 | ntCheck($checkPassed,.\HumbugBox |
af1a0 | 33 31 31 31 5c 4b 65 76 69 6e 47 48 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 5c | 3111\KevinGH\RequirementChecker\ |
af1c0 | 50 72 69 6e 74 65 72 20 24 70 72 69 6e 74 65 72 2c 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 | Printer.$printer,.\HumbugBox3111 |
af1e0 | 5c 4b 65 76 69 6e 47 48 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 5c 52 65 71 75 | \KevinGH\RequirementChecker\Requ |
af200 | 69 72 65 6d 65 6e 74 43 6f 6c 6c 65 63 74 69 6f 6e 20 24 72 65 71 75 69 72 65 6d 65 6e 74 73 29 | irementCollection.$requirements) |
af220 | 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 69 66 20 28 5c 66 61 6c 73 65 20 3d 3d 3d 20 24 63 | .....{.........if.(\false.===.$c |
af240 | 68 65 63 6b 50 61 73 73 65 64 20 26 26 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 4b 65 76 | heckPassed.&&.\HumbugBox3111\Kev |
af260 | 69 6e 47 48 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 5c 49 4f 3a 3a 56 45 52 42 | inGH\RequirementChecker\IO::VERB |
af280 | 4f 53 49 54 59 5f 56 45 52 59 5f 56 45 52 42 4f 53 45 20 3e 20 24 70 72 69 6e 74 65 72 2d 3e 67 | OSITY_VERY_VERBOSE.>.$printer->g |
af2a0 | 65 74 56 65 72 62 6f 73 69 74 79 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 70 72 | etVerbosity()).{.............$pr |
af2c0 | 69 6e 74 65 72 2d 3e 73 65 74 56 65 72 62 6f 73 69 74 79 28 5c 48 75 6d 62 75 67 42 6f 78 33 31 | inter->setVerbosity(\HumbugBox31 |
af2e0 | 31 31 5c 4b 65 76 69 6e 47 48 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 5c 49 4f | 11\KevinGH\RequirementChecker\IO |
af300 | 3a 3a 56 45 52 42 4f 53 49 54 59 5f 56 45 52 59 5f 56 45 52 42 4f 53 45 29 3b 0a 20 20 20 20 20 | ::VERBOSITY_VERY_VERBOSE);...... |
af320 | 20 20 20 7d 0a 20 20 20 20 20 20 20 20 24 76 65 72 62 6f 73 69 74 79 20 3d 20 5c 48 75 6d 62 75 | ...}.........$verbosity.=.\Humbu |
af340 | 67 42 6f 78 33 31 31 31 5c 4b 65 76 69 6e 47 48 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 | gBox3111\KevinGH\RequirementChec |
af360 | 6b 65 72 5c 49 4f 3a 3a 56 45 52 42 4f 53 49 54 59 5f 56 45 52 59 5f 56 45 52 42 4f 53 45 3b 0a | ker\IO::VERBOSITY_VERY_VERBOSE;. |
af380 | 20 20 20 20 20 20 20 20 24 69 6e 69 50 61 74 68 20 3d 20 24 72 65 71 75 69 72 65 6d 65 6e 74 73 | ........$iniPath.=.$requirements |
af3a0 | 2d 3e 67 65 74 50 68 70 49 6e 69 50 61 74 68 28 29 3b 0a 20 20 20 20 20 20 20 20 24 70 72 69 6e | ->getPhpIniPath();.........$prin |
af3c0 | 74 65 72 2d 3e 74 69 74 6c 65 28 27 42 6f 78 20 52 65 71 75 69 72 65 6d 65 6e 74 73 20 43 68 65 | ter->title('Box.Requirements.Che |
af3e0 | 63 6b 65 72 27 2c 20 24 76 65 72 62 6f 73 69 74 79 29 3b 0a 20 20 20 20 20 20 20 20 24 70 72 69 | cker',.$verbosity);.........$pri |
af400 | 6e 74 65 72 2d 3e 70 72 69 6e 74 76 28 27 3e 20 55 73 69 6e 67 20 50 48 50 20 27 2c 20 24 76 65 | nter->printv('>.Using.PHP.',.$ve |
af420 | 72 62 6f 73 69 74 79 29 3b 0a 20 20 20 20 20 20 20 20 24 70 72 69 6e 74 65 72 2d 3e 70 72 69 6e | rbosity);.........$printer->prin |
af440 | 74 76 6c 6e 28 5c 50 48 50 5f 56 45 52 53 49 4f 4e 2c 20 24 76 65 72 62 6f 73 69 74 79 2c 20 27 | tvln(\PHP_VERSION,.$verbosity,.' |
af460 | 67 72 65 65 6e 27 29 3b 0a 20 20 20 20 20 20 20 20 24 70 72 69 6e 74 65 72 2d 3e 70 72 69 6e 74 | green');.........$printer->print |
af480 | 76 6c 6e 28 27 3e 20 50 48 50 20 69 73 20 75 73 69 6e 67 20 74 68 65 20 66 6f 6c 6c 6f 77 69 6e | vln('>.PHP.is.using.the.followin |
af4a0 | 67 20 70 68 70 2e 69 6e 69 20 66 69 6c 65 3a 27 2c 20 24 76 65 72 62 6f 73 69 74 79 29 3b 0a 20 | g.php.ini.file:',.$verbosity);.. |
af4c0 | 20 20 20 20 20 20 20 69 66 20 28 24 69 6e 69 50 61 74 68 29 20 7b 0a 20 20 20 20 20 20 20 20 20 | .......if.($iniPath).{.......... |
af4e0 | 20 20 20 24 70 72 69 6e 74 65 72 2d 3e 70 72 69 6e 74 76 6c 6e 28 27 20 20 27 20 2e 20 24 69 6e | ...$printer->printvln('..'...$in |
af500 | 69 50 61 74 68 2c 20 24 76 65 72 62 6f 73 69 74 79 2c 20 27 67 72 65 65 6e 27 29 3b 0a 20 20 20 | iPath,.$verbosity,.'green');.... |
af520 | 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 70 72 69 6e 74 | .....}.else.{.............$print |
af540 | 65 72 2d 3e 70 72 69 6e 74 76 6c 6e 28 27 20 20 57 41 52 4e 49 4e 47 3a 20 4e 6f 20 63 6f 6e 66 | er->printvln('..WARNING:.No.conf |
af560 | 69 67 75 72 61 74 69 6f 6e 20 66 69 6c 65 20 28 70 68 70 2e 69 6e 69 29 20 75 73 65 64 20 62 79 | iguration.file.(php.ini).used.by |
af580 | 20 50 48 50 21 27 2c 20 24 76 65 72 62 6f 73 69 74 79 2c 20 27 79 65 6c 6c 6f 77 27 29 3b 0a 20 | .PHP!',.$verbosity,.'yellow');.. |
af5a0 | 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 24 70 72 69 6e 74 65 72 2d 3e 70 72 69 6e 74 | .......}.........$printer->print |
af5c0 | 76 6c 6e 28 27 27 2c 20 24 76 65 72 62 6f 73 69 74 79 29 3b 0a 20 20 20 20 20 20 20 20 69 66 20 | vln('',.$verbosity);.........if. |
af5e0 | 28 5c 63 6f 75 6e 74 28 24 72 65 71 75 69 72 65 6d 65 6e 74 73 29 20 3e 20 30 29 20 7b 0a 20 20 | (\count($requirements).>.0).{... |
af600 | 20 20 20 20 20 20 20 20 20 20 24 70 72 69 6e 74 65 72 2d 3e 70 72 69 6e 74 76 6c 6e 28 27 3e 20 | ..........$printer->printvln('>. |
af620 | 43 68 65 63 6b 69 6e 67 20 42 6f 78 20 72 65 71 75 69 72 65 6d 65 6e 74 73 3a 27 2c 20 24 76 65 | Checking.Box.requirements:',.$ve |
af640 | 72 62 6f 73 69 74 79 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 70 72 69 6e 74 65 72 2d 3e | rbosity);.............$printer-> |
af660 | 70 72 69 6e 74 76 28 27 20 20 27 2c 20 24 76 65 72 62 6f 73 69 74 79 29 3b 0a 20 20 20 20 20 20 | printv('..',.$verbosity);....... |
af680 | 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 70 72 69 6e 74 65 72 2d | ..}.else.{.............$printer- |
af6a0 | 3e 70 72 69 6e 74 76 6c 6e 28 27 3e 20 4e 6f 20 72 65 71 75 69 72 65 6d 65 6e 74 73 20 66 6f 75 | >printvln('>.No.requirements.fou |
af6c0 | 6e 64 2e 27 2c 20 24 76 65 72 62 6f 73 69 74 79 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 | nd.',.$verbosity);.........}.... |
af6e0 | 20 20 20 20 20 24 65 72 72 6f 72 4d 65 73 73 61 67 65 73 20 3d 20 61 72 72 61 79 28 29 3b 0a 20 | .....$errorMessages.=.array();.. |
af700 | 20 20 20 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 72 65 71 75 69 72 65 6d 65 6e 74 73 2d 3e 67 | .......foreach.($requirements->g |
af720 | 65 74 52 65 71 75 69 72 65 6d 65 6e 74 73 28 29 20 61 73 20 24 72 65 71 75 69 72 65 6d 65 6e 74 | etRequirements().as.$requirement |
af740 | 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 24 65 72 72 6f 72 4d 65 73 73 61 67 | ).{.............if.($errorMessag |
af760 | 65 20 3d 20 24 70 72 69 6e 74 65 72 2d 3e 67 65 74 52 65 71 75 69 72 65 6d 65 6e 74 45 72 72 6f | e.=.$printer->getRequirementErro |
af780 | 72 4d 65 73 73 61 67 65 28 24 72 65 71 75 69 72 65 6d 65 6e 74 29 29 20 7b 0a 20 20 20 20 20 20 | rMessage($requirement)).{....... |
af7a0 | 20 20 20 20 20 20 20 20 20 20 69 66 20 28 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 4b 65 76 | ..........if.(\HumbugBox3111\Kev |
af7c0 | 69 6e 47 48 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 5c 49 4f 3a 3a 56 45 52 42 | inGH\RequirementChecker\IO::VERB |
af7e0 | 4f 53 49 54 59 5f 44 45 42 55 47 20 3d 3d 3d 20 24 70 72 69 6e 74 65 72 2d 3e 67 65 74 56 65 72 | OSITY_DEBUG.===.$printer->getVer |
af800 | 62 6f 73 69 74 79 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | bosity()).{..................... |
af820 | 24 70 72 69 6e 74 65 72 2d 3e 70 72 69 6e 74 76 6c 6e 28 27 e2 9c 98 20 27 20 2e 20 24 72 65 71 | $printer->printvln('....'...$req |
af840 | 75 69 72 65 6d 65 6e 74 2d 3e 67 65 74 54 65 73 74 4d 65 73 73 61 67 65 28 29 2c 20 5c 48 75 6d | uirement->getTestMessage(),.\Hum |
af860 | 62 75 67 42 6f 78 33 31 31 31 5c 4b 65 76 69 6e 47 48 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 | bugBox3111\KevinGH\RequirementCh |
af880 | 65 63 6b 65 72 5c 49 4f 3a 3a 56 45 52 42 4f 53 49 54 59 5f 44 45 42 55 47 2c 20 27 72 65 64 27 | ecker\IO::VERBOSITY_DEBUG,.'red' |
af8a0 | 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 70 72 69 6e 74 65 72 2d | );.....................$printer- |
af8c0 | 3e 70 72 69 6e 74 76 28 27 20 20 27 2c 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 4b 65 76 | >printv('..',.\HumbugBox3111\Kev |
af8e0 | 69 6e 47 48 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 5c 49 4f 3a 3a 56 45 52 42 | inGH\RequirementChecker\IO::VERB |
af900 | 4f 53 49 54 59 5f 44 45 42 55 47 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | OSITY_DEBUG);................... |
af920 | 20 20 24 65 72 72 6f 72 4d 65 73 73 61 67 65 73 5b 5d 20 3d 20 24 65 72 72 6f 72 4d 65 73 73 61 | ..$errorMessages[].=.$errorMessa |
af940 | 67 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 | ge;.................}.else.{.... |
af960 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 70 72 69 6e 74 65 72 2d 3e 70 72 69 6e 74 | .................$printer->print |
af980 | 76 28 27 45 27 2c 20 24 76 65 72 62 6f 73 69 74 79 2c 20 27 72 65 64 27 29 3b 0a 20 20 20 20 20 | v('E',.$verbosity,.'red');...... |
af9a0 | 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 65 72 72 6f 72 4d 65 73 73 61 67 65 73 5b 5d 20 | ...............$errorMessages[]. |
af9c0 | 3d 20 24 65 72 72 6f 72 4d 65 73 73 61 67 65 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | =.$errorMessage;................ |
af9e0 | 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 63 6f 6e 74 69 6e 75 65 3b 0a 20 20 20 | .}.................continue;.... |
afa00 | 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 5c 48 75 6d 62 | .........}.............if.(\Humb |
afa20 | 75 67 42 6f 78 33 31 31 31 5c 4b 65 76 69 6e 47 48 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 | ugBox3111\KevinGH\RequirementChe |
afa40 | 63 6b 65 72 5c 49 4f 3a 3a 56 45 52 42 4f 53 49 54 59 5f 44 45 42 55 47 20 3d 3d 3d 20 24 70 72 | cker\IO::VERBOSITY_DEBUG.===.$pr |
afa60 | 69 6e 74 65 72 2d 3e 67 65 74 56 65 72 62 6f 73 69 74 79 28 29 29 20 7b 0a 20 20 20 20 20 20 20 | inter->getVerbosity()).{........ |
afa80 | 20 20 20 20 20 20 20 20 20 24 70 72 69 6e 74 65 72 2d 3e 70 72 69 6e 74 76 6c 6e 28 27 e2 9c 94 | .........$printer->printvln('... |
afaa0 | 20 27 20 2e 20 24 72 65 71 75 69 72 65 6d 65 6e 74 2d 3e 67 65 74 48 65 6c 70 54 65 78 74 28 29 | .'...$requirement->getHelpText() |
afac0 | 2c 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 4b 65 76 69 6e 47 48 5c 52 65 71 75 69 72 65 | ,.\HumbugBox3111\KevinGH\Require |
afae0 | 6d 65 6e 74 43 68 65 63 6b 65 72 5c 49 4f 3a 3a 56 45 52 42 4f 53 49 54 59 5f 44 45 42 55 47 2c | mentChecker\IO::VERBOSITY_DEBUG, |
afb00 | 20 27 67 72 65 65 6e 27 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 70 72 69 6e | .'green');.................$prin |
afb20 | 74 65 72 2d 3e 70 72 69 6e 74 76 28 27 20 20 27 2c 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 | ter->printv('..',.\HumbugBox3111 |
afb40 | 5c 4b 65 76 69 6e 47 48 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 5c 49 4f 3a 3a | \KevinGH\RequirementChecker\IO:: |
afb60 | 56 45 52 42 4f 53 49 54 59 5f 44 45 42 55 47 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 20 | VERBOSITY_DEBUG);.............}. |
afb80 | 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 70 72 69 6e 74 65 72 2d | else.{.................$printer- |
afba0 | 3e 70 72 69 6e 74 76 28 27 2e 27 2c 20 24 76 65 72 62 6f 73 69 74 79 2c 20 27 67 72 65 65 6e 27 | >printv('.',.$verbosity,.'green' |
afbc0 | 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 | );.............}.........}...... |
afbe0 | 20 20 20 69 66 20 28 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 4b 65 76 69 6e 47 48 5c 52 65 | ...if.(\HumbugBox3111\KevinGH\Re |
afc00 | 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 5c 49 4f 3a 3a 56 45 52 42 4f 53 49 54 59 5f 44 | quirementChecker\IO::VERBOSITY_D |
afc20 | 45 42 55 47 20 21 3d 3d 20 24 70 72 69 6e 74 65 72 2d 3e 67 65 74 56 65 72 62 6f 73 69 74 79 28 | EBUG.!==.$printer->getVerbosity( |
afc40 | 29 20 26 26 20 5c 63 6f 75 6e 74 28 24 72 65 71 75 69 72 65 6d 65 6e 74 73 29 20 3e 20 30 29 20 | ).&&.\count($requirements).>.0). |
afc60 | 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 70 72 69 6e 74 65 72 2d 3e 70 72 69 6e 74 76 6c 6e | {.............$printer->printvln |
afc80 | 28 27 27 2c 20 24 76 65 72 62 6f 73 69 74 79 29 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 | ('',.$verbosity);.........}..... |
afca0 | 20 20 20 20 69 66 20 28 24 72 65 71 75 69 72 65 6d 65 6e 74 73 2d 3e 65 76 61 6c 75 61 74 65 52 | ....if.($requirements->evaluateR |
afcc0 | 65 71 75 69 72 65 6d 65 6e 74 73 28 29 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 70 72 | equirements()).{.............$pr |
afce0 | 69 6e 74 65 72 2d 3e 62 6c 6f 63 6b 28 27 4f 4b 27 2c 20 27 59 6f 75 72 20 73 79 73 74 65 6d 20 | inter->block('OK',.'Your.system. |
afd00 | 69 73 20 72 65 61 64 79 20 74 6f 20 72 75 6e 20 74 68 65 20 61 70 70 6c 69 63 61 74 69 6f 6e 2e | is.ready.to.run.the.application. |
afd20 | 27 2c 20 24 76 65 72 62 6f 73 69 74 79 2c 20 27 73 75 63 63 65 73 73 27 29 3b 0a 20 20 20 20 20 | ',.$verbosity,.'success');...... |
afd40 | 20 20 20 7d 20 65 6c 73 65 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 24 70 72 69 6e 74 65 72 | ...}.else.{.............$printer |
afd60 | 2d 3e 62 6c 6f 63 6b 28 27 45 52 52 4f 52 27 2c 20 27 59 6f 75 72 20 73 79 73 74 65 6d 20 69 73 | ->block('ERROR',.'Your.system.is |
afd80 | 20 6e 6f 74 20 72 65 61 64 79 20 74 6f 20 72 75 6e 20 74 68 65 20 61 70 70 6c 69 63 61 74 69 6f | .not.ready.to.run.the.applicatio |
afda0 | 6e 2e 27 2c 20 24 76 65 72 62 6f 73 69 74 79 2c 20 27 65 72 72 6f 72 27 29 3b 0a 20 20 20 20 20 | n.',.$verbosity,.'error');...... |
afdc0 | 20 20 20 20 20 20 20 24 70 72 69 6e 74 65 72 2d 3e 74 69 74 6c 65 28 27 46 69 78 20 74 68 65 20 | .......$printer->title('Fix.the. |
afde0 | 66 6f 6c 6c 6f 77 69 6e 67 20 6d 61 6e 64 61 74 6f 72 79 20 72 65 71 75 69 72 65 6d 65 6e 74 73 | following.mandatory.requirements |
afe00 | 3a 27 2c 20 24 76 65 72 62 6f 73 69 74 79 2c 20 27 72 65 64 27 29 3b 0a 20 20 20 20 20 20 20 20 | :',.$verbosity,.'red');......... |
afe20 | 20 20 20 20 66 6f 72 65 61 63 68 20 28 24 65 72 72 6f 72 4d 65 73 73 61 67 65 73 20 61 73 20 24 | ....foreach.($errorMessages.as.$ |
afe40 | 65 72 72 6f 72 4d 65 73 73 61 67 65 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | errorMessage).{................. |
afe60 | 24 70 72 69 6e 74 65 72 2d 3e 70 72 69 6e 74 76 28 27 20 2a 20 27 20 2e 20 24 65 72 72 6f 72 4d | $printer->printv('.*.'...$errorM |
afe80 | 65 73 73 61 67 65 2c 20 24 76 65 72 62 6f 73 69 74 79 29 3b 0a 20 20 20 20 20 20 20 20 20 20 20 | essage,.$verbosity);............ |
afea0 | 20 7d 0a 20 20 20 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 24 70 72 69 6e 74 65 72 2d 3e 70 | .}.........}.........$printer->p |
afec0 | 72 69 6e 74 76 6c 6e 28 27 27 2c 20 24 76 65 72 62 6f 73 69 74 79 29 3b 0a 20 20 20 20 7d 0a 20 | rintvln('',.$verbosity);.....}.. |
afee0 | 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 66 75 6e 63 74 69 6f 6e 20 72 65 74 72 69 | ...private.static.function.retri |
aff00 | 65 76 65 52 65 71 75 69 72 65 6d 65 6e 74 73 28 29 0a 20 20 20 20 7b 0a 20 20 20 20 20 20 20 20 | eveRequirements().....{......... |
aff20 | 69 66 20 28 6e 75 6c 6c 20 3d 3d 3d 20 73 65 6c 66 3a 3a 24 72 65 71 75 69 72 65 6d 65 6e 74 73 | if.(null.===.self::$requirements |
aff40 | 43 6f 6e 66 69 67 29 20 7b 0a 20 20 20 20 20 20 20 20 20 20 20 20 73 65 6c 66 3a 3a 24 72 65 71 | Config).{.............self::$req |
aff60 | 75 69 72 65 6d 65 6e 74 73 43 6f 6e 66 69 67 20 3d 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e | uirementsConfig.=.__DIR__...'/.. |
aff80 | 2f 2e 72 65 71 75 69 72 65 6d 65 6e 74 73 2e 70 68 70 27 3b 0a 20 20 20 20 20 20 20 20 7d 0a 20 | /.requirements.php';.........}.. |
affa0 | 20 20 20 20 20 20 20 24 63 6f 6e 66 69 67 20 3d 20 28 72 65 71 75 69 72 65 20 73 65 6c 66 3a 3a | .......$config.=.(require.self:: |
affc0 | 24 72 65 71 75 69 72 65 6d 65 6e 74 73 43 6f 6e 66 69 67 29 3b 0a 20 20 20 20 20 20 20 20 24 72 | $requirementsConfig);.........$r |
affe0 | 65 71 75 69 72 65 6d 65 6e 74 73 20 3d 20 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 | equirements.=.new.\HumbugBox3111 |
b0000 | 5c 4b 65 76 69 6e 47 48 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 5c 52 65 71 75 | \KevinGH\RequirementChecker\Requ |
b0020 | 69 72 65 6d 65 6e 74 43 6f 6c 6c 65 63 74 69 6f 6e 28 29 3b 0a 20 20 20 20 20 20 20 20 66 6f 72 | irementCollection();.........for |
b0040 | 65 61 63 68 20 28 24 63 6f 6e 66 69 67 20 61 73 20 24 63 6f 6e 73 74 72 61 69 6e 74 29 20 7b 0a | each.($config.as.$constraint).{. |
b0060 | 20 20 20 20 20 20 20 20 20 20 20 20 24 72 65 71 75 69 72 65 6d 65 6e 74 73 2d 3e 61 64 64 52 65 | ............$requirements->addRe |
b0080 | 71 75 69 72 65 6d 65 6e 74 28 27 70 68 70 27 20 3d 3d 3d 20 24 63 6f 6e 73 74 72 61 69 6e 74 5b | quirement('php'.===.$constraint[ |
b00a0 | 27 74 79 70 65 27 5d 20 3f 20 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 4b 65 76 | 'type'].?.new.\HumbugBox3111\Kev |
b00c0 | 69 6e 47 48 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 5c 49 73 50 68 70 56 65 72 | inGH\RequirementChecker\IsPhpVer |
b00e0 | 73 69 6f 6e 46 75 6c 66 69 6c 6c 65 64 28 24 63 6f 6e 73 74 72 61 69 6e 74 5b 27 63 6f 6e 64 69 | sionFulfilled($constraint['condi |
b0100 | 74 69 6f 6e 27 5d 29 20 3a 20 6e 65 77 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 4b 65 76 | tion']).:.new.\HumbugBox3111\Kev |
b0120 | 69 6e 47 48 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 5c 49 73 45 78 74 65 6e 73 | inGH\RequirementChecker\IsExtens |
b0140 | 69 6f 6e 46 75 6c 66 69 6c 6c 65 64 28 24 63 6f 6e 73 74 72 61 69 6e 74 5b 27 63 6f 6e 64 69 74 | ionFulfilled($constraint['condit |
b0160 | 69 6f 6e 27 5d 29 2c 20 24 63 6f 6e 73 74 72 61 69 6e 74 5b 27 6d 65 73 73 61 67 65 27 5d 2c 20 | ion']),.$constraint['message'],. |
b0180 | 24 63 6f 6e 73 74 72 61 69 6e 74 5b 27 68 65 6c 70 4d 65 73 73 61 67 65 27 5d 29 3b 0a 20 20 20 | $constraint['helpMessage']);.... |
b01a0 | 20 20 20 20 20 7d 0a 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 24 72 65 71 75 69 72 65 6d 65 | .....}.........return.$requireme |
b01c0 | 6e 74 73 3b 0a 20 20 20 20 7d 0a 7d 0a 3c 3f 70 68 70 0a 0a 6e 61 6d 65 73 70 61 63 65 20 48 75 | nts;.....}.}.<?php..namespace.Hu |
b01e0 | 6d 62 75 67 42 6f 78 33 31 31 31 5c 4b 65 76 69 6e 47 48 5c 52 65 71 75 69 72 65 6d 65 6e 74 43 | mbugBox3111\KevinGH\RequirementC |
b0200 | 68 65 63 6b 65 72 3b 0a 0a 72 65 71 75 69 72 65 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 2e 2e 2f | hecker;..require.__DIR__...'/../ |
b0220 | 76 65 6e 64 6f 72 2f 61 75 74 6f 6c 6f 61 64 2e 70 68 70 27 3b 0a 69 66 20 28 5c 66 61 6c 73 65 | vendor/autoload.php';.if.(\false |
b0240 | 20 3d 3d 3d 20 5c 69 6e 5f 61 72 72 61 79 28 5c 50 48 50 5f 53 41 50 49 2c 20 61 72 72 61 79 28 | .===.\in_array(\PHP_SAPI,.array( |
b0260 | 27 63 6c 69 27 2c 20 27 70 68 70 64 62 67 27 2c 20 27 65 6d 62 65 64 27 29 2c 20 5c 74 72 75 65 | 'cli',.'phpdbg',.'embed'),.\true |
b0280 | 29 29 20 7b 0a 20 20 20 20 65 63 68 6f 20 5c 50 48 50 5f 45 4f 4c 20 2e 20 27 54 68 65 20 61 70 | )).{.....echo.\PHP_EOL...'The.ap |
b02a0 | 70 6c 69 63 61 74 69 6f 6e 20 6d 61 79 20 6f 6e 6c 79 20 62 65 20 69 6e 76 6f 6b 65 64 20 66 72 | plication.may.only.be.invoked.fr |
b02c0 | 6f 6d 20 61 20 63 6f 6d 6d 61 6e 64 20 6c 69 6e 65 2c 20 67 6f 74 20 22 27 20 2e 20 5c 50 48 50 | om.a.command.line,.got."'...\PHP |
b02e0 | 5f 53 41 50 49 20 2e 20 27 22 27 20 2e 20 5c 50 48 50 5f 45 4f 4c 3b 0a 20 20 20 20 65 78 69 74 | _SAPI...'"'...\PHP_EOL;.....exit |
b0300 | 28 31 29 3b 0a 7d 0a 69 66 20 28 28 5c 66 61 6c 73 65 20 3d 3d 3d 20 69 73 73 65 74 28 24 5f 53 | (1);.}.if.((\false.===.isset($_S |
b0320 | 45 52 56 45 52 5b 27 42 4f 58 5f 52 45 51 55 49 52 45 4d 45 4e 54 5f 43 48 45 43 4b 45 52 27 5d | ERVER['BOX_REQUIREMENT_CHECKER'] |
b0340 | 29 20 7c 7c 20 5c 74 72 75 65 20 3d 3d 3d 20 28 62 6f 6f 6c 29 20 24 5f 53 45 52 56 45 52 5b 27 | ).||.\true.===.(bool).$_SERVER[' |
b0360 | 42 4f 58 5f 52 45 51 55 49 52 45 4d 45 4e 54 5f 43 48 45 43 4b 45 52 27 5d 29 20 26 26 20 5c 66 | BOX_REQUIREMENT_CHECKER']).&&.\f |
b0380 | 61 6c 73 65 20 3d 3d 3d 20 5c 48 75 6d 62 75 67 42 6f 78 33 31 31 31 5c 4b 65 76 69 6e 47 48 5c | alse.===.\HumbugBox3111\KevinGH\ |
b03a0 | 52 65 71 75 69 72 65 6d 65 6e 74 43 68 65 63 6b 65 72 5c 43 68 65 63 6b 65 72 3a 3a 63 68 65 63 | RequirementChecker\Checker::chec |
b03c0 | 6b 52 65 71 75 69 72 65 6d 65 6e 74 73 28 29 29 20 7b 0a 20 20 20 20 65 78 69 74 28 31 29 3b 0a | kRequirements()).{.....exit(1);. |
b03e0 | 7d 0a 3c 3f 70 68 70 0a 0a 6e 61 6d 65 73 70 61 63 65 20 5f 48 75 6d 62 75 67 42 6f 78 64 63 65 | }.<?php..namespace._HumbugBoxdce |
b0400 | 34 63 38 36 62 63 61 39 34 3b 0a 0a 72 65 74 75 72 6e 20 61 72 72 61 79 20 28 0a 20 20 30 20 3d | 4c86bca94;..return.array.(...0.= |
b0420 | 3e 20 0a 20 20 61 72 72 61 79 20 28 0a 20 20 20 20 27 74 79 70 65 27 20 3d 3e 20 27 70 68 70 27 | >....array.(.....'type'.=>.'php' |
b0440 | 2c 0a 20 20 20 20 27 63 6f 6e 64 69 74 69 6f 6e 27 20 3d 3e 20 27 3e 3d 35 2e 33 2e 30 27 2c 0a | ,.....'condition'.=>.'>=5.3.0',. |
b0460 | 20 20 20 20 27 6d 65 73 73 61 67 65 27 20 3d 3e 20 27 54 68 65 20 70 61 63 6b 61 67 65 20 22 70 | ....'message'.=>.'The.package."p |
b0480 | 73 72 2f 6c 6f 67 22 20 72 65 71 75 69 72 65 73 20 74 68 65 20 76 65 72 73 69 6f 6e 20 22 3e 3d | sr/log".requires.the.version.">= |
b04a0 | 35 2e 33 2e 30 22 20 6f 72 20 67 72 65 61 74 65 72 2e 27 2c 0a 20 20 20 20 27 68 65 6c 70 4d 65 | 5.3.0".or.greater.',.....'helpMe |
b04c0 | 73 73 61 67 65 27 20 3d 3e 20 27 54 68 65 20 70 61 63 6b 61 67 65 20 22 70 73 72 2f 6c 6f 67 22 | ssage'.=>.'The.package."psr/log" |
b04e0 | 20 72 65 71 75 69 72 65 73 20 74 68 65 20 76 65 72 73 69 6f 6e 20 22 3e 3d 35 2e 33 2e 30 22 20 | .requires.the.version.">=5.3.0". |
b0500 | 6f 72 20 67 72 65 61 74 65 72 2e 27 2c 0a 20 20 29 2c 0a 20 20 31 20 3d 3e 20 0a 20 20 61 72 72 | or.greater.',...),...1.=>....arr |
b0520 | 61 79 20 28 0a 20 20 20 20 27 74 79 70 65 27 20 3d 3e 20 27 70 68 70 27 2c 0a 20 20 20 20 27 63 | ay.(.....'type'.=>.'php',.....'c |
b0540 | 6f 6e 64 69 74 69 6f 6e 27 20 3d 3e 20 27 3e 3d 35 2e 35 2e 39 27 2c 0a 20 20 20 20 27 6d 65 73 | ondition'.=>.'>=5.5.9',.....'mes |
b0560 | 73 61 67 65 27 20 3d 3e 20 27 54 68 65 20 70 61 63 6b 61 67 65 20 22 73 79 6d 66 6f 6e 79 2f 63 | sage'.=>.'The.package."symfony/c |
b0580 | 6f 6e 73 6f 6c 65 22 20 72 65 71 75 69 72 65 73 20 74 68 65 20 76 65 72 73 69 6f 6e 20 22 3e 3d | onsole".requires.the.version.">= |
b05a0 | 35 2e 35 2e 39 22 20 6f 72 20 67 72 65 61 74 65 72 2e 27 2c 0a 20 20 20 20 27 68 65 6c 70 4d 65 | 5.5.9".or.greater.',.....'helpMe |
b05c0 | 73 73 61 67 65 27 20 3d 3e 20 27 54 68 65 20 70 61 63 6b 61 67 65 20 22 73 79 6d 66 6f 6e 79 2f | ssage'.=>.'The.package."symfony/ |
b05e0 | 63 6f 6e 73 6f 6c 65 22 20 72 65 71 75 69 72 65 73 20 74 68 65 20 76 65 72 73 69 6f 6e 20 22 3e | console".requires.the.version."> |
b0600 | 3d 35 2e 35 2e 39 22 20 6f 72 20 67 72 65 61 74 65 72 2e 27 2c 0a 20 20 29 2c 0a 20 20 32 20 3d | =5.5.9".or.greater.',...),...2.= |
b0620 | 3e 20 0a 20 20 61 72 72 61 79 20 28 0a 20 20 20 20 27 74 79 70 65 27 20 3d 3e 20 27 70 68 70 27 | >....array.(.....'type'.=>.'php' |
b0640 | 2c 0a 20 20 20 20 27 63 6f 6e 64 69 74 69 6f 6e 27 20 3d 3e 20 27 3e 3d 35 2e 35 2e 39 27 2c 0a | ,.....'condition'.=>.'>=5.5.9',. |
b0660 | 20 20 20 20 27 6d 65 73 73 61 67 65 27 20 3d 3e 20 27 54 68 65 20 70 61 63 6b 61 67 65 20 22 73 | ....'message'.=>.'The.package."s |
b0680 | 79 6d 66 6f 6e 79 2f 64 65 62 75 67 22 20 72 65 71 75 69 72 65 73 20 74 68 65 20 76 65 72 73 69 | ymfony/debug".requires.the.versi |
b06a0 | 6f 6e 20 22 3e 3d 35 2e 35 2e 39 22 20 6f 72 20 67 72 65 61 74 65 72 2e 27 2c 0a 20 20 20 20 27 | on.">=5.5.9".or.greater.',.....' |
b06c0 | 68 65 6c 70 4d 65 73 73 61 67 65 27 20 3d 3e 20 27 54 68 65 20 70 61 63 6b 61 67 65 20 22 73 79 | helpMessage'.=>.'The.package."sy |
b06e0 | 6d 66 6f 6e 79 2f 64 65 62 75 67 22 20 72 65 71 75 69 72 65 73 20 74 68 65 20 76 65 72 73 69 6f | mfony/debug".requires.the.versio |
b0700 | 6e 20 22 3e 3d 35 2e 35 2e 39 22 20 6f 72 20 67 72 65 61 74 65 72 2e 27 2c 0a 20 20 29 2c 0a 20 | n.">=5.5.9".or.greater.',...),.. |
b0720 | 20 33 20 3d 3e 20 0a 20 20 61 72 72 61 79 20 28 0a 20 20 20 20 27 74 79 70 65 27 20 3d 3e 20 27 | .3.=>....array.(.....'type'.=>.' |
b0740 | 70 68 70 27 2c 0a 20 20 20 20 27 63 6f 6e 64 69 74 69 6f 6e 27 20 3d 3e 20 27 3e 3d 35 2e 33 2e | php',.....'condition'.=>.'>=5.3. |
b0760 | 33 27 2c 0a 20 20 20 20 27 6d 65 73 73 61 67 65 27 20 3d 3e 20 27 54 68 65 20 70 61 63 6b 61 67 | 3',.....'message'.=>.'The.packag |
b0780 | 65 20 22 73 79 6d 66 6f 6e 79 2f 70 6f 6c 79 66 69 6c 6c 2d 6d 62 73 74 72 69 6e 67 22 20 72 65 | e."symfony/polyfill-mbstring".re |
b07a0 | 71 75 69 72 65 73 20 74 68 65 20 76 65 72 73 69 6f 6e 20 22 3e 3d 35 2e 33 2e 33 22 20 6f 72 20 | quires.the.version.">=5.3.3".or. |
b07c0 | 67 72 65 61 74 65 72 2e 27 2c 0a 20 20 20 20 27 68 65 6c 70 4d 65 73 73 61 67 65 27 20 3d 3e 20 | greater.',.....'helpMessage'.=>. |
b07e0 | 27 54 68 65 20 70 61 63 6b 61 67 65 20 22 73 79 6d 66 6f 6e 79 2f 70 6f 6c 79 66 69 6c 6c 2d 6d | 'The.package."symfony/polyfill-m |
b0800 | 62 73 74 72 69 6e 67 22 20 72 65 71 75 69 72 65 73 20 74 68 65 20 76 65 72 73 69 6f 6e 20 22 3e | bstring".requires.the.version."> |
b0820 | 3d 35 2e 33 2e 33 22 20 6f 72 20 67 72 65 61 74 65 72 2e 27 2c 0a 20 20 29 2c 0a 29 3b 3c 3f 70 | =5.3.3".or.greater.',...),.);<?p |
b0840 | 68 70 0a 0a 72 65 71 75 69 72 65 20 5f 5f 44 49 52 5f 5f 20 2e 20 27 2f 76 65 6e 64 6f 72 2f 61 | hp..require.__DIR__...'/vendor/a |
b0860 | 75 74 6f 6c 6f 61 64 2e 70 68 70 27 3b 0a 0a 69 6e 69 5f 73 65 74 28 27 64 69 73 70 6c 61 79 5f | utoload.php';..ini_set('display_ |
b0880 | 65 72 72 6f 72 73 27 2c 20 27 30 27 29 3b 0a 69 6e 69 5f 73 65 74 28 27 6c 6f 67 5f 65 72 72 6f | errors',.'0');.ini_set('log_erro |
b08a0 | 72 73 27 2c 20 27 31 27 29 3b 0a 64 61 74 65 5f 64 65 66 61 75 6c 74 5f 74 69 6d 65 7a 6f 6e 65 | rs',.'1');.date_default_timezone |
b08c0 | 5f 73 65 74 28 27 55 54 43 27 29 3b 0a 0a 24 61 70 70 6c 69 63 61 74 69 6f 6e 20 3d 20 6e 65 77 | _set('UTC');..$application.=.new |
b08e0 | 20 4e 43 5c 55 70 64 61 74 65 72 5c 43 6f 6d 6d 61 6e 64 41 70 70 6c 69 63 61 74 69 6f 6e 28 29 | .NC\Updater\CommandApplication() |
b0900 | 3b 0a 24 61 70 70 6c 69 63 61 74 69 6f 6e 2d 3e 72 75 6e 28 29 3b 69 45 b2 31 05 a2 87 c6 2e 58 | ;.$application->run();iE.1.....X |
b0920 | 64 59 78 6e ca 40 f5 0b 8b e9 02 00 00 00 47 42 4d 42 | dYxn.@........GBMB |