@@ -1,12 +1,12 @@ |
||
1 | 1 | <?php |
2 | 2 | /** |
3 | - * Async sockets |
|
4 | - * |
|
5 | - * @copyright Copyright (c) 2016, Efimov Evgenij <[email protected]> |
|
6 | - * |
|
7 | - * This source file is subject to the MIT license that is bundled |
|
8 | - * with this source code in the file LICENSE. |
|
9 | - */ |
|
3 | + * Async sockets |
|
4 | + * |
|
5 | + * @copyright Copyright (c) 2016, Efimov Evgenij <[email protected]> |
|
6 | + * |
|
7 | + * This source file is subject to the MIT license that is bundled |
|
8 | + * with this source code in the file LICENSE. |
|
9 | + */ |
|
10 | 10 | namespace AsyncSockets\Operation; |
11 | 11 | |
12 | 12 | /** |
@@ -1,12 +1,12 @@ |
||
1 | 1 | <?php |
2 | 2 | /** |
3 | - * Async sockets |
|
4 | - * |
|
5 | - * @copyright Copyright (c) 2016, Efimov Evgenij <[email protected]> |
|
6 | - * |
|
7 | - * This source file is subject to the MIT license that is bundled |
|
8 | - * with this source code in the file LICENSE. |
|
9 | - */ |
|
3 | + * Async sockets |
|
4 | + * |
|
5 | + * @copyright Copyright (c) 2016, Efimov Evgenij <[email protected]> |
|
6 | + * |
|
7 | + * This source file is subject to the MIT license that is bundled |
|
8 | + * with this source code in the file LICENSE. |
|
9 | + */ |
|
10 | 10 | namespace AsyncSockets\Operation; |
11 | 11 | |
12 | 12 | /** |
@@ -1,12 +1,12 @@ |
||
1 | 1 | <?php |
2 | 2 | /** |
3 | - * Async sockets |
|
4 | - * |
|
5 | - * @copyright Copyright (c) 2016, Efimov Evgenij <[email protected]> |
|
6 | - * |
|
7 | - * This source file is subject to the MIT license that is bundled |
|
8 | - * with this source code in the file LICENSE. |
|
9 | - */ |
|
3 | + * Async sockets |
|
4 | + * |
|
5 | + * @copyright Copyright (c) 2016, Efimov Evgenij <[email protected]> |
|
6 | + * |
|
7 | + * This source file is subject to the MIT license that is bundled |
|
8 | + * with this source code in the file LICENSE. |
|
9 | + */ |
|
10 | 10 | namespace AsyncSockets\Operation; |
11 | 11 | |
12 | 12 | /** |
@@ -239,8 +239,8 @@ discard block |
||
239 | 239 | */ |
240 | 240 | public function removeAllSocketOperations(StreamResourceInterface $streamResource) |
241 | 241 | { |
242 | - $opList = [ OperationInterface::OPERATION_READ, |
|
243 | - OperationInterface::OPERATION_WRITE ]; |
|
242 | + $opList = [OperationInterface::OPERATION_READ, |
|
243 | + OperationInterface::OPERATION_WRITE]; |
|
244 | 244 | |
245 | 245 | foreach ($opList as $op) { |
246 | 246 | $this->removeSocketOperation($streamResource, $op); |
@@ -281,8 +281,7 @@ discard block |
||
281 | 281 | */ |
282 | 282 | private function calculateAttemptsCount($seconds, $usec) |
283 | 283 | { |
284 | - return $seconds !== null ? ceil(($seconds * 1E6 + $usec) / self::ATTEMPT_DELAY) : |
|
285 | - self::ATTEMPT_COUNT_FOR_INFINITE_TIMEOUT; |
|
284 | + return $seconds !== null ? ceil(($seconds * 1E6 + $usec) / self::ATTEMPT_DELAY) : self::ATTEMPT_COUNT_FOR_INFINITE_TIMEOUT; |
|
286 | 285 | } |
287 | 286 | |
288 | 287 | /** |
@@ -1,12 +1,12 @@ discard block |
||
1 | 1 | <?php |
2 | 2 | /** |
3 | - * Async sockets |
|
4 | - * |
|
5 | - * @copyright Copyright (c) 2016, Efimov Evgenij <[email protected]> |
|
6 | - * |
|
7 | - * This source file is subject to the MIT license that is bundled |
|
8 | - * with this source code in the file LICENSE. |
|
9 | - */ |
|
3 | + * Async sockets |
|
4 | + * |
|
5 | + * @copyright Copyright (c) 2016, Efimov Evgenij <[email protected]> |
|
6 | + * |
|
7 | + * This source file is subject to the MIT license that is bundled |
|
8 | + * with this source code in the file LICENSE. |
|
9 | + */ |
|
10 | 10 | namespace AsyncSockets\RequestExecutor\Pipeline; |
11 | 11 | |
12 | 12 | use AsyncSockets\Event\DataAlertEvent; |
@@ -125,9 +125,9 @@ discard block |
||
125 | 125 | $operation = $descriptor->getOperation(); |
126 | 126 | return ($operation instanceof NullOperation) || |
127 | 127 | ( |
128 | - $operation instanceof ReadOperation && |
|
128 | + $operation instanceof ReadOperation && |
|
129 | 129 | $operation->getFramePicker() instanceof EmptyFramePicker |
130 | - ); |
|
130 | + ); |
|
131 | 131 | } |
132 | 132 | |
133 | 133 | /** |
@@ -104,7 +104,7 @@ |
||
104 | 104 | return new Event( |
105 | 105 | $this->executor, |
106 | 106 | $operation->getSocket(), |
107 | - $meta[ RequestExecutorInterface::META_USER_CONTEXT ], |
|
107 | + $meta[RequestExecutorInterface::META_USER_CONTEXT], |
|
108 | 108 | $eventName |
109 | 109 | ); |
110 | 110 | } |
@@ -36,7 +36,7 @@ |
||
36 | 36 | $result = []; |
37 | 37 | foreach ($operations as $key => $item) { |
38 | 38 | $meta = $item->getMetadata(); |
39 | - $isActive = !$meta[ RequestExecutorInterface::META_REQUEST_COMPLETE ] && |
|
39 | + $isActive = !$meta[RequestExecutorInterface::META_REQUEST_COMPLETE] && |
|
40 | 40 | $item->isRunning() && |
41 | 41 | !$item->isPostponed(); |
42 | 42 |
@@ -1,12 +1,12 @@ |
||
1 | 1 | <?php |
2 | 2 | /** |
3 | - * Async sockets |
|
4 | - * |
|
5 | - * @copyright Copyright (c) 2016, Efimov Evgenij <[email protected]> |
|
6 | - * |
|
7 | - * This source file is subject to the MIT license that is bundled |
|
8 | - * with this source code in the file LICENSE. |
|
9 | - */ |
|
3 | + * Async sockets |
|
4 | + * |
|
5 | + * @copyright Copyright (c) 2016, Efimov Evgenij <[email protected]> |
|
6 | + * |
|
7 | + * This source file is subject to the MIT license that is bundled |
|
8 | + * with this source code in the file LICENSE. |
|
9 | + */ |
|
10 | 10 | namespace AsyncSockets\Operation; |
11 | 11 | |
12 | 12 | /** |
@@ -1,12 +1,12 @@ |
||
1 | 1 | <?php |
2 | 2 | /** |
3 | - * Async sockets |
|
4 | - * |
|
5 | - * @copyright Copyright (c) 2016, Efimov Evgenij <[email protected]> |
|
6 | - * |
|
7 | - * This source file is subject to the MIT license that is bundled |
|
8 | - * with this source code in the file LICENSE. |
|
9 | - */ |
|
3 | + * Async sockets |
|
4 | + * |
|
5 | + * @copyright Copyright (c) 2016, Efimov Evgenij <[email protected]> |
|
6 | + * |
|
7 | + * This source file is subject to the MIT license that is bundled |
|
8 | + * with this source code in the file LICENSE. |
|
9 | + */ |
|
10 | 10 | namespace AsyncSockets\Operation; |
11 | 11 | |
12 | 12 | /** |