PHP Class FOF30\Factory\SwitchFactory

The Dispatcher and Toolbar will be created from default objects if specialised classes are not found in your application.
Inheritance: extends BasicFactory, implements FOF30\Factory\FactoryInterface
Datei anzeigen Open project: akeeba/fof Class Usage Examples

Public Methods

Method Description
__construct ( Container $container )
controller ( string $viewName, array $config = [] ) : Controller Create a new Controller object
dispatcher ( array $config = [] ) : Dispatcher Creates a new Dispatcher
model ( string $viewName, array $config = [] ) : Model Create a new Model object
toolbar ( array $config = [] ) : Toolbar Creates a new Toolbar
transparentAuthentication ( array $config = [] ) : TransparentAuthentication Creates a new TransparentAuthentication
view ( string $viewName, string $viewType = 'html', array $config = [] ) : View Create a new View object
viewFinder ( View $view, array $config = [] ) : mixed Creates a view template finder object for a specific View.

Method Details

__construct() public method

public __construct ( Container $container )
$container FOF30\Container\Container

controller() public method

Create a new Controller object
public controller ( string $viewName, array $config = [] ) : Controller
$viewName string The name of the view we're getting a Controller for.
$config array Optional MVC configuration values for the Controller object.
return FOF30\Controller\Controller

dispatcher() public method

Creates a new Dispatcher
public dispatcher ( array $config = [] ) : Dispatcher
$config array The configuration values for the Dispatcher object
return FOF30\Dispatcher\Dispatcher

model() public method

Create a new Model object
public model ( string $viewName, array $config = [] ) : Model
$viewName string The name of the view we're getting a Model for.
$config array Optional MVC configuration values for the Model object.
return FOF30\Model\Model

toolbar() public method

Creates a new Toolbar
public toolbar ( array $config = [] ) : Toolbar
$config array The configuration values for the Toolbar object
return FOF30\Toolbar\Toolbar

transparentAuthentication() public method

Creates a new TransparentAuthentication
public transparentAuthentication ( array $config = [] ) : TransparentAuthentication
$config array The configuration values for the TransparentAuthentication object
return FOF30\TransparentAuthentication\TransparentAuthentication

view() public method

Create a new View object
public view ( string $viewName, string $viewType = 'html', array $config = [] ) : View
$viewName string The name of the view we're getting a View object for.
$viewType string The type of the View object. By default it's "html".
$config array Optional MVC configuration values for the View object.
return FOF30\View\View

viewFinder() public method

The default configuration is: Look for .php, .blade.php files; default layout "default"; no default subtemplate; look for both pluralised and singular views; fall back to the default layout without subtemplate; look for templates in both site and admin
public viewFinder ( View $view, array $config = [] ) : mixed
$view FOF30\View\View The view this view template finder will be attached to
$config array Configuration variables for the object
return mixed