Class Summary Net_Server

Class Summary Net_Server – PHP socket server base class

PHP socket server base class

This class must only be used to create a new server using the static method 'create()'.

To handle the events that happen while the server is running you have to create a new class that handles all events.

1     require_once 'myHandler.php';
2      require_once 'Net/Server.php';
3
4      $server = &
Net_Server
::
create
('fork', 'localhost', 9090);
5
6      $handler = &new myHandler;
7
8      $server->setCallbackObject($handler);
9
10     $server->start();

See Server/Handler.php for a baseclass that you can use to implement new handlers.

Class Trees for Net_Server

  • Net_Server

using Net_Server (Previous) create a new server (Next)
Last updated: Sat, 16 Feb 2019 — Download Documentation
Do you think that something on this page is wrong? Please file a bug report.
View this page in:
  • English

User Notes:

There are no user contributed notes for this page.