Subversion-Projekte lars-tiefland.laravel_shop

Revision

Details | Letzte Änderung | Log anzeigen | RSS feed

Revision Autor Zeilennr. Zeile
148 lars 1
<?php
2
 
3
/**
4
 * This file is part of the Carbon package.
5
 *
6
 * (c) Brian Nesbitt <brian@nesbot.com>
7
 *
8
 * For the full copyright and license information, please view the LICENSE
9
 * file that was distributed with this source code.
10
 */
11
 
12
namespace Carbon\Exceptions;
13
 
14
use BadMethodCallException as BaseBadMethodCallException;
15
use Throwable;
16
 
17
class UnknownMethodException extends BaseBadMethodCallException implements BadMethodCallException
18
{
19
    /**
20
     * The method.
21
     *
22
     * @var string
23
     */
24
    protected $method;
25
 
26
    /**
27
     * Constructor.
28
     *
29
     * @param string         $method
30
     * @param int            $code
31
     * @param Throwable|null $previous
32
     */
33
    public function __construct($method, $code = 0, Throwable $previous = null)
34
    {
35
        $this->method = $method;
36
 
37
        parent::__construct("Method $method does not exist.", $code, $previous);
38
    }
39
 
40
    /**
41
     * Get the method.
42
     *
43
     * @return string
44
     */
45
    public function getMethod(): string
46
    {
47
        return $this->method;
48
    }
49
}