Init Repo

This commit is contained in:
root
2019-09-06 23:53:10 +08:00
commit f0ef89dfbb
7905 changed files with 914138 additions and 0 deletions

12
vendor/swoole/examples/async/write.php vendored Executable file
View File

@ -0,0 +1,12 @@
<?php
function write_callback($file, $writen)
{
echo "write $file [$writen]\n";
//return true: write contine. return false: close the file.
return true;
}
for ($i = 0; $i < 10; $i++)
{
swoole_async_write("data.txt", str_repeat('A', 10) . "\n", -1, "write_callback");
}