Beispiel #1
0
 public static function singleton()
 {
     if (!isset(self::$instance)) {
         $c = __CLASS__;
         self::$instance = new $c();
     }
     return self::$instance;
 }
Beispiel #2
0
 function __construct($argv)
 {
     if (!isset($argv[2])) {
         $argv[2] = "";
     }
     $this->args = $argv;
     $this->keyword = @$argv[3];
     $this->job = $argv[2];
     $this->name = $argv[1];
     $this->results = array();
     $this->output = OutputRobot::singleton();
     echo '[Selected Robot] ' . $argv[2] . " @ " . strtoupper($argv[1]) . PHP_EOL;
     echo '==---------------------------------------------------------------==' . PHP_EOL;
 }