Threads

HostCheck.class.php


<?php
  
require('CheckThread.class.php');
  
  class 
HostCheck {
    
public
      $threads  
= array();
    
    
public function check($host$port) {
      
$this->addCheck(new CheckThread($host$port))->start();
    }

    
private function addCheck($check) {
      
$this->threads[]= $check;
      return 
$check;
    }
  }
?>