Added first draft Homepage

This commit is contained in:
Kevin Frantz
2018-07-14 17:48:24 +02:00
parent d1a29b6d70
commit 2cefb4187c
14 changed files with 113 additions and 10 deletions

View File

@@ -2,6 +2,7 @@
namespace router;
use core\CoreInterface;
use controller\standart\Standart;
/**
*
@@ -10,19 +11,58 @@ use core\CoreInterface;
*/
final class Router implements RouterInterface
{
public function route()
/**
* @var CoreInterface
*/
private $core;
/**
*
* @var array
*/
private $get;
/**
*
* @var array
*/
private $post;
public function route():void
{
echo "Hello World!";
if($this->post['route']){
$this->postRouting();
}
if($this->get['router']){
$this->getRouting();
}else{
$standart = new Standart($this->core);
$standart->homepage();
}
}
private function postRouting():void{
}
private function getRouting():void{
}
public function setGet(array $get)
{}
public function setGet(array $get):void
{
$this->get = $get;
}
public function setCore(CoreInterface $core)
{}
public function setCore(CoreInterface $core):void
{
$this->core = $core;
}
public function setPost(array $post): void
{}
{
$this->post = $post;
}
}