Code Coverage
 
Lines
Functions and Methods
Classes and Traits
Total
100.00% covered (success)
100.00%
6 / 6
100.00% covered (success)
100.00%
6 / 6
CRAP
100.00% covered (success)
100.00%
1 / 1
ExcludedOSService
100.00% covered (success)
100.00%
6 / 6
100.00% covered (success)
100.00%
6 / 6
6
100.00% covered (success)
100.00%
1 / 1
 getRootClass
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 getNameProperty
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 getNamePropertyUri
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 getVersionProperty
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 getVersionPropertyUri
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 getListClass
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
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) 2021-2023 (original work) Open Assessment Technologies SA.
19 */
20
21declare(strict_types=1);
22
23namespace oat\taoClientDiagnostic\model\exclusionList;
24
25use core_kernel_classes_Class;
26use core_kernel_classes_Property;
27
28class ExcludedOSService extends ExclusionListService
29{
30    public const SERVICE_ID = 'taoClientDiagnostic/ExcludedOSService';
31
32    public const ROOT_CLASS = 'http://www.tao.lu/Ontologies/TAODelivery.rdf#ExcludedOS';
33    public const LIST_CLASS = 'http://www.tao.lu/Ontologies/TAODelivery.rdf#OSList';
34    public const EXCLUDED_NAME = 'http://www.tao.lu/Ontologies/TAODelivery.rdf#ExcludedOSName';
35    public const EXCLUDED_VERSION = 'http://www.tao.lu/Ontologies/TAODelivery.rdf#ExcludedOSVersion';
36
37    /**
38     * Get the root class for excluded Operating system
39     *
40     * @return core_kernel_classes_Class
41     */
42    public function getRootClass()
43    {
44        return $this->getClass(self::ROOT_CLASS);
45    }
46
47    public function getNameProperty(): core_kernel_classes_Property
48    {
49        return $this->getProperty($this->getNamePropertyUri());
50    }
51
52    public function getNamePropertyUri(): string
53    {
54        return self::EXCLUDED_NAME;
55    }
56
57    public function getVersionProperty(): core_kernel_classes_Property
58    {
59        return $this->getProperty($this->getVersionPropertyUri());
60    }
61
62    public function getVersionPropertyUri(): string
63    {
64        return self::EXCLUDED_VERSION;
65    }
66
67    protected function getListClass(): core_kernel_classes_Class
68    {
69        return $this->getClass(self::LIST_CLASS);
70    }
71}