- dumb async http server
- dumb forking http server
- dumb forking https server
- dumb http server
- dumb jsonrpc server
- dumb smtp server
- dumb soap server
- dumb syslog server
- dumb xmlrpc server
- fork with shared
- get http head
- ipc queues
- nshttpd
- persistent forking xmlrpc server
- shared obj
- simple chat server
- time server
- timer test
Click on the filename to view the highlighted source code.
persistent_forking_xmlrpc_server.php
<?php
require "nanoserv/handlers/HTTP/XML_RPC/Persistent_Server.php";
class dumb_xmlrpc {
public $bar;
public function getFoo($bar) {
return array("foo" => "foo{$bar}", "bar" => $this->bar++);
}
}
$o = new dumb_xmlrpc();
$l = \Nanoserv\Core::New_Listener("tcp://0.0.0.0:800", '\Nanoserv\HTTP\XML_RPC\Persistent_Server', \Nanoserv\Core::New_Shared_Object($o));
$l->Set_Forking();
$l->Activate();
$o->bar = 100;
\Nanoserv\Core::Run();
?>