Go to file
2018-10-28 10:18:24 -05:00
docs Update shared documentation files 2018-05-16 16:16:25 +02:00
examples Fix code style 2017-12-28 15:13:09 +01:00
src Allow any serializable callable 2018-10-28 10:18:24 -05:00
test Allow any serializable callable 2018-10-28 10:18:24 -05:00
.editorconfig Add php-cs-fixer and fix code style 2017-12-13 23:48:03 +01:00
.gitignore Add php-cs-fixer and fix code style 2017-12-13 23:48:03 +01:00
.gitmodules Add docs 2017-12-14 00:30:25 +01:00
.php_cs.dist Add php-cs-fixer and fix code style 2017-12-13 23:48:03 +01:00
.travis.yml Make use of composer scripts and add a further test 2017-12-16 10:35:40 +01:00
composer.json Allow amphp/parallel v1.0 2018-10-28 09:47:32 -05:00
LICENSE Initial commit 2017-12-13 22:58:26 +01:00
phpunit.xml.dist Initial commit 2017-12-13 22:58:26 +01:00
README.md Fix example 2017-12-16 17:46:04 +01:00

parallel-functions

Build Status License

Installation

This package can be installed as a Composer dependency.

composer require amphp/parallel-functions

Requirements

  • PHP 7.0+

Documentation

Documentation can be found on amphp.org as well as in the ./docs directory.

Example

<?php

use function Amp\ParallelFunctions\parallelMap;
use function Amp\Promise\wait;

$responses = wait(parallelMap([
    'https://google.com/',
    'https://github.com/',
    'https://stackoverflow.com/',
], function ($url) {
    return file_get_contents($url);
}));

Further examples can be found in the ./examples directory.

Versioning

amphp/parallel-functions follows the semver semantic versioning specification like all other amphp packages.

Security

If you discover any security related issues, please email me@kelunik.com instead of using the issue tracker.

License

The MIT License (MIT). Please see LICENSE for more information.