mirror of
https://github.com/flextype/flextype.git
synced 2025-08-12 16:14:16 +02:00
Using Flextype Components
This commit is contained in:
@@ -12,7 +12,6 @@
|
||||
|
||||
namespace Flextype;
|
||||
|
||||
use Symfony\Component\{Filesystem\Filesystem, Finder\Finder};
|
||||
use Flextype\Component\{Http\Http, Session\Session};
|
||||
|
||||
class Flextype
|
||||
@@ -25,22 +24,6 @@ class Flextype
|
||||
*/
|
||||
protected static $instance = null;
|
||||
|
||||
/**
|
||||
* Filesystem object
|
||||
*
|
||||
* @var Filesystem
|
||||
* @access public
|
||||
*/
|
||||
public static $filesystem = null;
|
||||
|
||||
/**
|
||||
* Finder object
|
||||
*
|
||||
* @var Finder
|
||||
* @access public
|
||||
*/
|
||||
public static $finder = null;
|
||||
|
||||
/**
|
||||
* Protected clone method to enforce singleton behavior.
|
||||
*
|
||||
@@ -75,12 +58,6 @@ class Flextype
|
||||
*/
|
||||
protected static function app() : void
|
||||
{
|
||||
// Create Finder Instance
|
||||
static::$finder = new Finder();
|
||||
|
||||
// Create Filesystem Instance
|
||||
static::$filesystem = new Filesystem();
|
||||
|
||||
// Create Cache Instance
|
||||
Config::instance();
|
||||
|
||||
@@ -134,28 +111,6 @@ class Flextype
|
||||
ob_end_flush();
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns filesystem object
|
||||
*
|
||||
* @access public
|
||||
* @return Filesystem
|
||||
*/
|
||||
public static function filesystem() : Filesystem
|
||||
{
|
||||
return static::$filesystem;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns finder object
|
||||
*
|
||||
* @access public
|
||||
* @return Finder
|
||||
*/
|
||||
public static function finder() : Finder
|
||||
{
|
||||
return static::$finder;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return the Flextype instance.
|
||||
* Create it if it's not already created.
|
||||
|
Reference in New Issue
Block a user