AcmeDemo
├── src/
│ ├── Book.php
│ ├── BookRepository.php
│ └── BookLookupController.php
├── vendor/
├── app.php
├── composer.json
└── composer.lock
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
query { | |
organization(login: "reactphp") { | |
repositories(ownerAffiliations: OWNER, privacy: PUBLIC, first: 100) { | |
nodes { | |
nameWithOwner | |
defaultBranchRef { | |
name | |
} | |
refs(refPrefix: "refs/heads/", first: 10) { | |
nodes { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT | |
users.name, | |
groups.name AS `group` | |
FROM | |
URL('https://gist.github.com/clue/dde9700e9be30db2abd3c763833aa631/raw/962e5d6a337a9bf14e1816f548ea996358c235f8/users.json') AS users, | |
URL('https://gist.github.com/clue/dde9700e9be30db2abd3c763833aa631/raw/962e5d6a337a9bf14e1816f548ea996358c235f8/groups.json') AS groups | |
WHERE users.`group` = groups.id | |
ORDER BY `group` DESC |
AcmeDemo
├── src/
│ ├── Book.php
│ ├── BookRepository.php
│ └── BookLookupController.php
├── vendor/
├── app.php
├── composer.json
AcmeDemo
├── src/
│ ├── Book.php
│ ├── BookRepository.php
│ └── BookLookupController.php
├── vendor/
├── app.php
├── composer.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
use app\clFilesystem; | |
use React\MySQL\Factory; | |
require __DIR__ . '/vendor/autoload.php'; | |
$loop = React\EventLoop\Factory::create(); | |
$filesystem = \React\Filesystem\Filesystem::create($loop); | |
$file = "teste.txt"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function main(): PromiseInterface { | |
return $this->query(1); | |
} | |
function query(page): PromiseInterface { | |
return $this | |
->makeAQuery(page) | |
->then($result) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$promise = new React\Promise\FulfilledPromise(1); | |
$transformer = new ThroughStream(function ($data) { | |
return array('id' => $data['id'], 'stocknummer' => $data['id'], 'dealer_id' => $data['id'], '_vnr' => 1, '_checksum' => sha1(json_encode($data)), '_timestamp' => date('Y-m-d h:i:s')); | |
}); | |
//try to change in Client class add _vnr, _checksum and _timestamp | |
$source->pipe($transformer)->pipe($stream); | |
//$source->pipe($stream); |
NewerOlder