PHP_Fork
[ class tree: PHP_Fork ] [ index: PHP_Fork ] [ all elements ]

File: passing_vars.php

Source Location: /PHP_Fork-0.3.2/examples/passing_vars.php

Classes:

PHP_Fork class. Wrapper around the pcntl_fork() stuff with a API set like Java language.

Page Details:

Includes:

require_once("PHP/Fork.php") [line 24]
PHP_Fork class usage examples ================================================================================== NOTE: In real world you surely want to keep each class into a separate file, then include() it into your application.

For this examples is more useful to keep all_code_into_one_file, so that each example shows a unique feature of the PHP_Fork framework. ================================================================================== passing_vars.php

This example shows variable exchange between the parent process and started pseudo-threads. This was not possible in previous releases because parent and child processes lives into different memory spaces, they are separate processes with their own PID and not separate instances living into the same JVM; this is just forking, not real threading... This framework offers a workaround based Shared Memory usage.

==================================================================================


Documentation generated on Mon, 11 Mar 2019 15:41:28 -0400 by phpDocumentor 1.4.4. PEAR Logo Copyright © PHP Group 2004.