1 | <?php |
||
14 | class BinariesController extends CommonController |
||
15 | { |
||
16 | use \hiqdev\yii2\collection\ManagerTrait; |
||
17 | |||
18 | public $defaultClass = 'hidev\base\BinaryPhp'; |
||
19 | |||
20 | public function actionMake() |
||
31 | |||
32 | /** |
||
33 | * Prepares item config. |
||
34 | */ |
||
35 | public function getItemConfig($name = null, array $config = []) |
||
42 | |||
43 | /** |
||
44 | * Prepares and runs with passthru. Returns exit code. |
||
45 | * @param string $name binary |
||
46 | * @param string $args |
||
47 | * @return int exit code |
||
48 | */ |
||
49 | public function passthruBinary($name, $args = []) |
||
53 | |||
54 | /** |
||
55 | * Prepares and runs with exec. Returns stdout string. |
||
56 | * @param string $name binary |
||
57 | * @param string $args |
||
58 | * @return array stdout |
||
59 | */ |
||
60 | public function execBinary($name, $args = '', $returnExitCode = false) |
||
64 | } |
||
65 |