Disambiguate::validate()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 1
nc 1
nop 2
dl 0
loc 3
rs 10
c 0
b 0
f 0
1
<?php
2
declare(strict_types=1);
3
/*
4
 * citeproc-php
5
 *
6
 * @link        http://github.com/seboettg/citeproc-php for the source repository
7
 * @copyright   Copyright (c) 2016 Sebastian Böttger.
8
 * @license     https://opensource.org/licenses/MIT
9
 */
10
11
namespace Seboettg\CiteProc\Constraint;
12
13
use stdClass;
14
15
/**
16
 * Class Disambiguate
17
 * When set to “true” (the only allowed value), the element content is only rendered if it disambiguates two otherwise
18
 * identical citations. This attempt at disambiguation is only made when all other disambiguation methods have failed
19
 * to uniquely identify the target source.
20
 */
21
class Disambiguate implements Constraint
22
{
23
    /**
24
     * @param stdClass $data
25
     * @param int|null $citationNumber
26
     * @return bool
27
     */
28
    public function validate(stdClass $data, $citationNumber = null): bool
29
    {
30
        return false;
31
    }
32
}
33