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) 2018 (original work) Open Assessment Technologies SA (under the project TAO-PRODUCT); |
| 19 | * |
| 20 | */ |
| 21 | |
| 22 | namespace oat\taoDelivery\model; |
| 23 | |
| 24 | use oat\oatbox\user\User; |
| 25 | use oat\taoDelivery\model\execution\DeliveryExecutionInterface; |
| 26 | |
| 27 | /** |
| 28 | * Service to count the attempts to pass the test. |
| 29 | * |
| 30 | * @access public |
| 31 | * @author Aleh Hutnikau, <hutnikau@1pt.com> |
| 32 | * @package taoDelivery |
| 33 | */ |
| 34 | interface AttemptServiceInterface |
| 35 | { |
| 36 | public const SERVICE_ID = 'taoDelivery/AttemptService'; |
| 37 | |
| 38 | /** |
| 39 | * Get array of delivery finished delivery executions which should be considered as an attempt. |
| 40 | * |
| 41 | * @param string $deliveryId delivery identifier |
| 42 | * @param User $user |
| 43 | * @return DeliveryExecutionInterface[] |
| 44 | */ |
| 45 | public function getAttempts($deliveryId, User $user); |
| 46 | |
| 47 | /** |
| 48 | * Set array of states to be excluded (execution in this state will not be considered as an attempt) |
| 49 | * @param array $deliveryExecutionsStates |
| 50 | */ |
| 51 | public function setStatesToExclude(array $deliveryExecutionsStates); |
| 52 | |
| 53 | /** |
| 54 | * Get array of states to be excluded |
| 55 | */ |
| 56 | public function getStatesToExclude(); |
| 57 | } |