1
0
mirror of https://github.com/danog/parallel.git synced 2024-12-11 08:39:48 +01:00
parallel/tests/Worker/TestTask.php

20 lines
361 B
PHP
Raw Normal View History

2015-08-29 03:55:30 +02:00
<?php
namespace Icicle\Tests\Concurrent\Worker;
2016-01-23 07:00:56 +01:00
use Icicle\Concurrent\Worker\{Environment, Task};
2015-08-29 03:55:30 +02:00
2015-12-05 06:50:32 +01:00
class TestTask implements Task
2015-08-29 03:55:30 +02:00
{
private $returnValue;
public function __construct($returnValue)
{
$this->returnValue = $returnValue;
}
2016-01-25 06:04:29 +01:00
public function run(Environment $environment)
2015-08-29 03:55:30 +02:00
{
2016-01-25 06:04:29 +01:00
return $this->returnValue;
2015-08-29 03:55:30 +02:00
}
}