Get an instance of the global singleton
@return XBRL_Global
427122
public static function getInstance()
	{
		if ( is_null( self::$instance ) )
		{
			self::$instance = new self();
			self::$instance->types = XBRL_Types::getInstance();
		}
		return self::$instance;
	}
979136
public static function instance() {
        global $CFG;
        if (is_null(self::$singletoninstance)) {
            if (!empty($CFG->perfdebug) and $CFG->perfdebug > 7) {
                self::$singletoninstance = new performance_measuring_filter_manager();
            } else {
                self::$singletoninstance = new self();
            }
        }
        return self::$singletoninstance;
    }
864796
public static function getInstance() {
        if( is_null(self::$_oInstance) ) {
            $c = __CLASS__;
            self::$_oInstance = new $c;
        }
        return self::$_oInstance;
    }
851170
public static function createFromGlobal()
    {
        $instance = new self('');

        //~ Set scheme
        if (isset($_SERVER['HTTPS'])) {
            $instance->setScheme($_SERVER['HTTPS'] == 'on' ? 'https' : 'http');
        }

        //~ Set host
        if (isset($_SERVER['HTTP_HOST'])) {
            $instance->setHost($_SERVER['HTTP_HOST']);
        } elseif (isset($_SERVER['SERVER_NAME'])) {
            $instance->setHost($_SERVER['SERVER_NAME']);
        }

        //~ Set port
        if (isset($_SERVER['SERVER_PORT'])) {
            $instance->setPort($_SERVER['SERVER_PORT']);
        }

        //~ Set path
        if (isset($_SERVER['REQUEST_URI'])) {
            $instance->setPath(current(explode('?', $_SERVER['REQUEST_URI'])));
        }

        //~ Set query string
        if (isset($_SERVER['QUERY_STRING'])) {
            $instance->setQuery($_SERVER['QUERY_STRING']);
        }

        return $instance;
    }
377780
public static function instance() {
		if (empty(self::$_generalMessageQueueProxy)) {
			self::$_generalMessageQueueProxy = new TransportProxy(Configure::read('RatchetCommands.Queue.configuration'));
		}

		return self::$_generalMessageQueueProxy;
	}
835451
public static function getInstance()
  {
    if (!isset(self::$instance)) {
      self::$instance = new self;
    }
    self::$instance->startSession();
    return self::$instance;
  }
1198172
public static function getInstance() : ISOCurrencyProvider
    {
        if (self::$instance === null) {
            self::$instance = new ISOCurrencyProvider();
        }

        return self::$instance;
    }
957872
public static function getInstance() {
		if (!isset(self::$_instance) || (self::$_instance === NULL)) {
			self::$_instance = new PHPExcel_ReferenceHelper();
		}

		return self::$_instance;
	}
663322
public static function getInstance()
    {
        if (self::$_instance === null) {
            self::$_instance = oxNew(__CLASS__);
        }

        return self::$_instance;
    }
688068
public static function singleton()
    {
        if (!isset(self::$_instance)) {
            $c = __CLASS__;
            self::$_instance = new $c;
        }

        return self::$_instance;
    }
476544
public static function getInstance()
    {
        if (!static::$instance instanceof self) {
            static::$instance = $session = new self();
            if (!$session->isStarted()) {
                $session->start();
            }
        }

        return static::$instance;
    }
918665
public static function instance()
    {
        if (empty(static::$_modmgr)) {
            $module = Yii::$app->getModule(static::$modulesManagerModuleUid);
            if (!empty($module) && $module instanceof UniModule) {
                static::$_modmgr = $module->getDataModel(static::$modulesManagerModelAlias);
            } else {
                static::$_modmgr = new static;
            }
        }
        return static::$_modmgr;
    }
515967
static public function singleton()
    {
        if (! self::$_singleton) {
            global $CA_CONFIG;
            self::$_singleton = self::probe($CA_CONFIG ? $CA_CONFIG : array());
        }
        return self::$_singleton;
    }
700259
public static function getInstanceAndStart() {
		if (!is_object(self::$instance)) {
			self::$instance = new BUsersSession();
		}
		if (!self::$instance->Start()) {
			return NULL;
		} else {
			return self::$instance;
		}
	}
882762
public static function singleton() {
        $returnValue = null;

        
        $serviceName = get_called_class();
        if (!isset(self::$instances[$serviceName])) {
            self::$instances[$serviceName] = new $serviceName();
        }

        $returnValue = self::$instances[$serviceName];
        

        return $returnValue;
    }
812653
private static function getInstance()
	{
		$accessor = static::getContainerAccessor();

		if (!isset(static::$instances[$accessor])) {
			$container = static::getContainer();
			static::$instances[$accessor] = $container[$accessor];
		}

		return static::$instances[$accessor];
	}
1240630
final public static function instance() {
        $c = get_called_class();
       
        if( ! isset( self::$instances[$c] ) )
        {
            self::$instances[$c] = new $c;
        }
       
        return self::$instances[$c];
    }