<?php

namespace AppBundle\Controller;

use Symfony\Bundle\FrameworkBundle\Templating\EngineInterface;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\HttpFoundation\Request;
use Symfony\Component\HttpFoundation\RedirectResponse;
use Symfony\Bundle\FrameworkBundle\Routing\Router;
use Symfony\Component\Security\Http\Authentication\AuthenticationUtils;

/**
 * SecurityController -
 *
 * @author Kendra Kohler
 */

class SecurityController
{
    private $templating;
    private $router;
    private $securityUtils;


    public function __construct(EngineInterface $templating, Router $router, AuthenticationUtils $securityUtils)
    {
        $this->templating = $templating;
        $this->router = $router;
        $this->securityUtils = $securityUtils;
    }

    /**
     * displayLogin - Displayes the login page
     * @param type $request - get params, posts
     */
    public function displayLogin(Request $request)
    {
        return $this->templating->renderResponse('default/login.html.twig');
    }

    public function loginCheckAction()
    {
        // this controller will not be executed,
        // as the route is handled by the Security system
    }

    public function logoutAction()
    {
        // this controller will not be executed,
        // as the route is handled by the Security system
    }
}