This file contains hidden or 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
extern crate futures; | |
extern crate tokio_core; | |
extern crate tokio_line; | |
use futures::future::{self, Future, Loop}; | |
use futures::{Stream}; | |
use std::{io, str}; | |
use tokio_core::io::{Io}; | |
use tokio_core::net::{TcpStream}; | |
use tokio_core::reactor::{Core, Handle}; |
This file contains hidden or 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
extern crate futures; | |
extern crate tokio_core; | |
use futures::{Async, AsyncSink, StartSend, Poll, Sink, IntoFuture, Future, future}; | |
use futures::sync::mpsc::{SendError}; | |
use futures::Async::{NotReady, Ready}; | |
use futures::sync::mpsc::UnboundedReceiver; | |
use futures::sync::mpsc; | |
use futures::task::{self, Task}; | |
use tokio_core::reactor::{Core, Timeout}; |
This file contains hidden or 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 | |
include 'vendor/autoload.php'; | |
use Monolog\Logger; | |
use Monolog\Handler\SocketHandler; | |
// create a log channel | |
$log = new Logger('name'); | |
$socketHandler = new SocketHandler('localhost:1234', Logger::WARNING); | |
/* $socketHandler->setWritingTimeout(5); */ |
This file contains hidden or 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
-module(fizzbuzz). | |
-export([evaluateV1/1]). | |
-export([evaluateV2/1]). | |
-export([evaluateV3/1]). | |
-export([evaluateV4/1]). | |
-include_lib("eunit/include/eunit.hrl"). | |
divisorToWordMap() -> | |
#{ |
This file contains hidden or 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 | |
namespace KbizeCli\Http\Exception; | |
class ServerErrorResponseException | |
{ | |
public static function fromRaw($raw) | |
{ | |
$e = new self($raw->getMessage(), $raw->getCode(), $raw->getPrevious()); | |
return $e; |