PHP code example of swoft / swoole-ide-helper

1. Go to this page and download the library: Download swoft/swoole-ide-helper library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

swoft / swoole-ide-helper example snippets


/**
 * @param $fd
 * @param $data
 * @param $opcode
 * @param $finish
 * @return mixed
 */
public function push($fd, $data, $opcode = null, $finish = null){}

/**
 * @param int $fd
 * @param mixed $data
 * @param int $opcode
 * @param bool $finish
 * @return mixed
 */
public function push(int $fd, $data, int $opcode = null, bool $finish = null){}
bash
cd /path/to/swoole-ide-helper
php dump.php
bash
docker run -ti --rm -v /path/to/swoole-ide-helper:/var/www/swoft swoft/swoft bash
php dump.php