Subversion-Projekte lars-tiefland.laravel_shop

Revision

Details | Letzte Änderung | Log anzeigen | RSS feed

Revision Autor Zeilennr. Zeile
148 lars 1
<?php
2
 
3
namespace Illuminate\Auth;
4
 
5
use Exception;
6
 
7
class AuthenticationException extends Exception
8
{
9
    /**
10
     * All of the guards that were checked.
11
     *
12
     * @var array
13
     */
14
    protected $guards;
15
 
16
    /**
17
     * The path the user should be redirected to.
18
     *
19
     * @var string|null
20
     */
21
    protected $redirectTo;
22
 
23
    /**
24
     * Create a new authentication exception.
25
     *
26
     * @param  string  $message
27
     * @param  array  $guards
28
     * @param  string|null  $redirectTo
29
     * @return void
30
     */
31
    public function __construct($message = 'Unauthenticated.', array $guards = [], $redirectTo = null)
32
    {
33
        parent::__construct($message);
34
 
35
        $this->guards = $guards;
36
        $this->redirectTo = $redirectTo;
37
    }
38
 
39
    /**
40
     * Get the guards that were checked.
41
     *
42
     * @return array
43
     */
44
    public function guards()
45
    {
46
        return $this->guards;
47
    }
48
 
49
    /**
50
     * Get the path the user should be redirected to.
51
     *
52
     * @return string|null
53
     */
54
    public function redirectTo()
55
    {
56
        return $this->redirectTo;
57
    }
58
}