Code Coverage |
||||||||||
Lines |
Functions and Methods |
Classes and Traits |
||||||||
Total | n/a |
0 / 0 |
n/a |
0 / 0 |
CRAP | n/a |
0 / 0 |
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) 2016 (original work) Open Assessment Technologies SA (under the project TAO-PRODUCT); |
19 | * |
20 | */ |
21 | |
22 | namespace oat\taoResultServer\models\classes; |
23 | |
24 | use oat\oatbox\PhpSerializable; |
25 | use oat\taoDelivery\model\execution\DeliveryExecution as DeliveryExecutionInterface; |
26 | |
27 | interface ResultService extends PhpSerializable |
28 | { |
29 | public const SERVICE_ID = 'taoResultServer/qtiResultsService'; |
30 | |
31 | public const CONFIG_ID = 'qtiResultsService'; |
32 | |
33 | public const DELIVERY_RESULT_CLASS_URI = 'http://www.tao.lu/Ontologies/TAOResult.rdf#DeliveryResult'; |
34 | |
35 | public const SUBJECT_CLASS_URI = 'http://www.tao.lu/Ontologies/TAOResult.rdf#resultOfSubject'; |
36 | |
37 | public const DELIVERY_CLASS_URI = 'http://www.tao.lu/Ontologies/TAOResult.rdf#resultOfDelivery'; |
38 | |
39 | /** |
40 | * Get last delivery execution from $delivery & $testtaker uri |
41 | * |
42 | * @param $delivery |
43 | * @param $testtaker |
44 | * @return mixed |
45 | * @throws |
46 | */ |
47 | public function getDeliveryExecutionByTestTakerAndDelivery($delivery, $testtaker); |
48 | |
49 | /** |
50 | * Get Delivery execution from resource |
51 | * |
52 | * @param $deliveryExecutionId |
53 | * @return mixed |
54 | * @throws \common_exception_NotFound |
55 | */ |
56 | public function getDeliveryExecutionById($deliveryExecutionId); |
57 | |
58 | /** |
59 | * Return delivery execution as xml of testtaker based on delivery |
60 | * |
61 | * @param DeliveryExecutionInterface $deliveryExecution |
62 | * @return string |
63 | */ |
64 | public function getDeliveryExecutionXml(DeliveryExecutionInterface $deliveryExecution); |
65 | |
66 | /** |
67 | * Get Qti Result depending on deliveryId & resultId |
68 | * |
69 | * @param $deliveryId |
70 | * @param $resultId |
71 | * @param bool $fetchOnlyLastAttemptResult |
72 | * @return mixed |
73 | */ |
74 | public function getQtiResultXml($deliveryId, $resultId, $fetchOnlyLastAttemptResult = false); |
75 | } |