Passed
Pull Request — master (#2809)
by
unknown
34:29
created

UnifiedConfigurationEvent   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 23
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 2
eloc 4
c 1
b 0
f 0
dl 0
loc 23
rs 10

2 Methods

Rating   Name   Duplication   Size   Complexity  
A getUnifiedConfiguration() 0 3 1
A __construct() 0 3 1
1
<?php
2
3
declare(strict_types=1);
4
5
/*
6
 * This file is part of the TYPO3 CMS project.
7
 *
8
 * It is free software; you can redistribute it and/or modify it under
9
 * the terms of the GNU General Public License, either version 2
10
 * of the License, or any later version.
11
 *
12
 * For the full copyright and license information, please read the
13
 * LICENSE.txt file that was distributed with this source code.
14
 *
15
 * The TYPO3 project - inspiring people to share!
16
 */
17
18
namespace ApacheSolrForTypo3\Solr\Event;
19
20
use ApacheSolrForTypo3\Solr\System\Configuration\UnifiedConfiguration;
21
22
/**
23
 * This event is is used to initialize the unified configurations.
24
 *
25
 * This is required since there are many places a configuration could be available threw all
26
 * available extensions.
27
 *
28
 * @author Lars Tode <[email protected]>
29
 * @copyright (c) 2020-2021 Lars Tode <[email protected]>
30
 */
31
class UnifiedConfigurationEvent
32
{
33
    /**
34
     * @var UnifiedConfiguration
35
     */
36
    protected $unifiedConfiguration;
37
38
    /**
39
     * Default constructor for this event
40
     *
41
     * @param UnifiedConfiguration $unifiedConfiguration
42
     */
43
    public function __construct(UnifiedConfiguration $unifiedConfiguration)
44
    {
45
        $this->unifiedConfiguration = $unifiedConfiguration;
46
    }
47
48
    /**
49
     * @return UnifiedConfiguration
50
     */
51
    public function getUnifiedConfiguration(): UnifiedConfiguration
52
    {
53
        return $this->unifiedConfiguration;
54
    }
55
}
56