[App] Reverted API API changes - back to v0.3.1 version

This commit is contained in:
Chris Boden 2014-06-07 11:06:57 -04:00
parent a0db6e6727
commit 989235132e
2 changed files with 3 additions and 26 deletions

View File

@ -1,7 +1,5 @@
<?php <?php
namespace Ratchet; namespace Ratchet;
use React\EventLoop\LoopInterface; use React\EventLoop\LoopInterface;
use React\EventLoop\Factory as LoopFactory; use React\EventLoop\Factory as LoopFactory;
use React\Socket\Server as Reactor; use React\Socket\Server as Reactor;
@ -77,7 +75,7 @@ class App {
$this->routes = new RouteCollection; $this->routes = new RouteCollection;
$this->_server = new IoServer(new HttpServer(new Router(new UrlMatcher($this->routes, new RequestContext))), $socket, $loop); $this->_server = new IoServer(new HttpServer(new Router(new UrlMatcher($this->routes, new RequestContext))), $socket, $loop);
$policy = new FlashPolicy(); $policy = new FlashPolicy;
$policy->addAllowedAccess($httpHost, 80); $policy->addAllowedAccess($httpHost, 80);
$policy->addAllowedAccess($httpHost, $port); $policy->addAllowedAccess($httpHost, $port);
$flashSock = new Reactor($loop); $flashSock = new Reactor($loop);
@ -90,24 +88,6 @@ class App {
} }
} }
/**
* Returns the FlashPolicy running in the flash server. Modifications of this object take effect immediately!
*
* @return FlashPolicy
*/
public function getFlashPolicy() {
return $this->flashServer->app;
}
/**
* Returns the FlashSocket of the flash server.
*
* @return \React\Socket\ServerInterface
*/
public function getFlashSocket() {
return $this->flashServer->socket;
}
/** /**
* Add an endpiont/application to the server * Add an endpiont/application to the server
* @param string $path The URI the client will connect to * @param string $path The URI the client will connect to
@ -151,4 +131,3 @@ class App {
$this->_server->run(); $this->_server->run();
} }
} }

View File

@ -1,7 +1,5 @@
<?php <?php
namespace Ratchet\Server; namespace Ratchet\Server;
use Ratchet\MessageComponentInterface; use Ratchet\MessageComponentInterface;
use React\EventLoop\LoopInterface; use React\EventLoop\LoopInterface;
use React\Socket\ServerInterface; use React\Socket\ServerInterface;