Code Coverage |
||||||||||
Lines |
Functions and Methods |
Classes and Traits |
||||||||
Total | |
100.00% |
5 / 5 |
|
100.00% |
5 / 5 |
CRAP | |
100.00% |
1 / 1 |
NullSenseId | |
100.00% |
5 / 5 |
|
100.00% |
5 / 5 |
5 | |
100.00% |
1 / 1 |
__construct | |
100.00% |
1 / 1 |
|
100.00% |
1 / 1 |
1 | |||
getLexemeId | |
100.00% |
1 / 1 |
|
100.00% |
1 / 1 |
1 | |||
__serialize | |
100.00% |
1 / 1 |
|
100.00% |
1 / 1 |
1 | |||
__unserialize | |
100.00% |
1 / 1 |
|
100.00% |
1 / 1 |
1 | |||
equals | |
100.00% |
1 / 1 |
|
100.00% |
1 / 1 |
1 |
1 | <?php |
2 | |
3 | namespace Wikibase\Lexeme\Domain\DummyObjects; |
4 | |
5 | use LogicException; |
6 | use Wikibase\Lexeme\Domain\Model\SenseId; |
7 | |
8 | /** |
9 | * An ID for a BlankSense which has not yet been associated with any lexeme. |
10 | * |
11 | * @license GPL-2.0-or-later |
12 | * @phan-file-suppress PhanPluginNeverReturnMethod |
13 | */ |
14 | class NullSenseId extends SenseId { |
15 | |
16 | public function __construct() { |
17 | $this->serialization = ''; |
18 | } |
19 | |
20 | public function getLexemeId() { |
21 | throw new LogicException( 'Shall never be called' ); |
22 | } |
23 | |
24 | public function __serialize(): array { |
25 | throw new LogicException( 'Shall never be called' ); |
26 | } |
27 | |
28 | public function __unserialize( array $data ): void { |
29 | throw new LogicException( 'Shall never be called' ); |
30 | } |
31 | |
32 | public function equals( $target ) { |
33 | return true; |
34 | } |
35 | |
36 | } |