Completed
Push — master ( f04f52...152406 )
by Anton
03:17
created

ProxyFactoryException   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 11
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Importance

Changes 0
Metric Value
wmc 1
lcom 0
cbo 0
dl 0
loc 11
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A wrap() 0 4 1
1
<?php
2
/**
3
 * Spiral Framework.
4
 *
5
 * @license MIT
6
 * @author  Valentin V (Vvval)
7
 */
8
declare(strict_types=1);
9
10
namespace Cycle\ORM\Promise\Exception;
11
12
class ProxyFactoryException extends \Exception
13
{
14
    /**
15
     * @param \Throwable $e
16
     * @return ProxyFactoryException
17
     */
18
    public static function wrap(\Throwable $e): self
19
    {
20
        return new self($e->getMessage(), $e->getCode(), $e);
21
    }
22
}