[TASK] Re-work/simplify copyright header in PHP files - Part 9
[Packages/TYPO3.CMS.git] / typo3 / sysext / scheduler / Classes / AdditionalFieldProviderInterface.php
1 <?php
2 namespace TYPO3\CMS\Scheduler;
3
4 /**
5 * This file is part of the TYPO3 CMS project.
6 *
7 * It is free software; you can redistribute it and/or modify it under
8 * the terms of the GNU General Public License, either version 2
9 * of the License, or any later version.
10 *
11 * For the full copyright and license information, please read the
12 * LICENSE.txt file that was distributed with this source code.
13 *
14 * The TYPO3 project - inspiring people to share!
15 */
16 /**
17 * Interface for classes who want to provide additional fields when adding a task
18 *
19 * @author Ingo Renner <ingo@typo3.org>
20 */
21 interface AdditionalFieldProviderInterface
22 {
23 /**
24 * Gets additional fields to render in the form to add/edit a task
25 *
26 * @param array $taskInfo Values of the fields from the add/edit task form
27 * @param \TYPO3\CMS\Scheduler\Task\AbstractTask $task The task object being edited. Null when adding a task!
28 * @param \TYPO3\CMS\Scheduler\Controller\SchedulerModuleController $schedulerModule Reference to the scheduler backend module
29 * @return array A two dimensional array, array('Identifier' => array('fieldId' => array('code' => '', 'label' => '', 'cshKey' => '', 'cshLabel' => ''))
30 */
31 public function getAdditionalFields(array &$taskInfo, $task, \TYPO3\CMS\Scheduler\Controller\SchedulerModuleController $schedulerModule);
32
33 /**
34 * Validates the additional fields' values
35 *
36 * @param array $submittedData An array containing the data submitted by the add/edit task form
37 * @param \TYPO3\CMS\Scheduler\Controller\SchedulerModuleController $schedulerModule Reference to the scheduler backend module
38 * @return boolean TRUE if validation was ok (or selected class is not relevant), FALSE otherwise
39 */
40 public function validateAdditionalFields(array &$submittedData, \TYPO3\CMS\Scheduler\Controller\SchedulerModuleController $schedulerModule);
41
42 /**
43 * Takes care of saving the additional fields' values in the task's object
44 *
45 * @param array $submittedData An array containing the data submitted by the add/edit task form
46 * @param \TYPO3\CMS\Scheduler\Task\AbstractTask $task Reference to the scheduler backend module
47 * @return void
48 */
49 public function saveAdditionalFields(array $submittedData, \TYPO3\CMS\Scheduler\Task\AbstractTask $task);
50
51 }