Completed
Pull Request — master (#1984)
by Maciej
19:41
created

HydratorException   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 17
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 1

Test Coverage

Coverage 0%

Importance

Changes 0
Metric Value
wmc 3
lcom 1
cbo 1
dl 0
loc 17
ccs 0
cts 12
cp 0
rs 10
c 0
b 0
f 0

3 Methods

Rating   Name   Duplication   Size   Complexity  
A hydratorDirectoryNotWritable() 0 4 1
A hydratorDirectoryRequired() 0 4 1
A hydratorNamespaceRequired() 0 4 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace Doctrine\ODM\MongoDB\Hydrator;
6
7
use Doctrine\ODM\MongoDB\MongoDBException;
8
9
/**
10
 * MongoDB ODM Hydrator Exception
11
 */
12
final class HydratorException extends MongoDBException
13
{
14
    public static function hydratorDirectoryNotWritable() : self
15
    {
16
        return new self('Your hydrator directory must be writable.');
17
    }
18
19
    public static function hydratorDirectoryRequired() : self
20
    {
21
        return new self('You must configure a hydrator directory. See docs for details.');
22
    }
23
24
    public static function hydratorNamespaceRequired() : self
25
    {
26
        return new self('You must configure a hydrator namespace. See docs for details');
27
    }
28
}
29