ThreadedFactory::getInstance PHP 메소드

getInstance() 공개 정적인 메소드

public static getInstance ( ) : ThreadedFactory
리턴 ThreadedFactory
    public static function getInstance()
    {
        if (self::$instance === null) {
            global $threadedFactoryInstance;
            if ($threadedFactoryInstance instanceof ThreadedFactory) {
                self::$instance = $threadedFactoryInstance;
            } else {
                new ThreadedFactory();
            }
        }
        return self::$instance;
    }