<?php

class Cls1 {
    protected function 
writeLine($line){
        echo 
$line;
    }

    public function 
quit($msg){
        if (isset(
$this)){
            
$this->writeLine('QUIT :'.$msg);
        }
        else {
            echo 
'QUIT :'.$msg;
        }
    }
}


class 
Cls2 {
    public function 
execute(){
        
Cls1::quit('blah');
    }
}

$c1 = new Cls1();
$c2 = new Cls2();

echo 
'$c1->quit("blah") == ';
$c1->quit("blah");

echo 
"\n\n\$c2->execute() == ";
$c2->execute();

?>