PHP: what is pcntl_signal used for?
<p>I found a chunk of code that I haven't seen before:</p>

<pre><code>declare(ticks = 1);
pcntl_signal(SIGINT, array($this, "catchSignal"));
pcntl_signal(SIGTERM, array($this, "catchSignal"));
</code></pre>

<p>I looked up the function in the PHP documentation, but I still don't understand what this is used for. Please help me understand what this is used for and some examples of where this should be implemented.</p>
