All pastes #623461 Raw Edit

Anonymous

public text v1 · immutable
·published 2007-07-17 16:50 UTC
rendered paste body
// this implements the 'singleton' design pattern.
	public static function getInstance () {
  		if (is_null(self::$instance)) {
      		echo "nueva instancia";
      		$class_name = __CLASS__;
      		self::$instance = new $class_name;
    	}
    	return self::$instance;
	}