Code Coverage |
||||||||||
Lines |
Functions and Methods |
Classes and Traits |
||||||||
Total | |
100.00% |
15 / 15 |
|
100.00% |
1 / 1 |
CRAP | |
100.00% |
1 / 1 |
DefaultSearchSettingsService | |
100.00% |
15 / 15 |
|
100.00% |
1 / 1 |
1 | |
100.00% |
1 / 1 |
getSettingsByClassMetadataSearchRequest | |
100.00% |
15 / 15 |
|
100.00% |
1 / 1 |
1 |
1 | <?php |
2 | |
3 | /** |
4 | * This program is free software; you can redistribute it and/or |
5 | * modify it under the terms of the GNU General Public License |
6 | * as published by the Free Software Foundation; under version 2 |
7 | * of the License (non-upgradable). |
8 | * |
9 | * This program is distributed in the hope that it will be useful, |
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
12 | * GNU General Public License for more details. |
13 | * |
14 | * You should have received a copy of the GNU General Public License |
15 | * along with this program; if not, write to the Free Software |
16 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. |
17 | * |
18 | * Copyright (c) 2022 (original work) Open Assessment Technologies SA; |
19 | * |
20 | * @author Gabriel Felipe Soares <gabriel.felipe.soares@taotesting.com> |
21 | */ |
22 | |
23 | namespace oat\tao\model\search\Service; |
24 | |
25 | use oat\tao\model\Lists\Business\Domain\ClassMetadataSearchRequest; |
26 | use oat\tao\model\search\Contract\SearchSettingsServiceInterface; |
27 | use oat\tao\model\search\ResultColumn; |
28 | use oat\tao\model\search\SearchSettings; |
29 | |
30 | class DefaultSearchSettingsService implements SearchSettingsServiceInterface |
31 | { |
32 | public function getSettingsByClassMetadataSearchRequest( |
33 | ClassMetadataSearchRequest $classMetadataSearchRequest |
34 | ): SearchSettings { |
35 | return new SearchSettings( |
36 | [ |
37 | new ResultColumn( |
38 | 'label', |
39 | 'label', |
40 | __('Label'), |
41 | 'text', |
42 | null, |
43 | null, |
44 | false, |
45 | true, |
46 | false |
47 | ), |
48 | ] |
49 | ); |
50 | } |
51 | } |