Mercurial > hg > isophonics-drupal-site
comparison vendor/symfony/translation/Catalogue/OperationInterface.php @ 0:4c8ae668cc8c
Initial import (non-working)
author | Chris Cannam |
---|---|
date | Wed, 29 Nov 2017 16:09:58 +0000 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
-1:000000000000 | 0:4c8ae668cc8c |
---|---|
1 <?php | |
2 | |
3 /* | |
4 * This file is part of the Symfony package. | |
5 * | |
6 * (c) Fabien Potencier <fabien@symfony.com> | |
7 * | |
8 * For the full copyright and license information, please view the LICENSE | |
9 * file that was distributed with this source code. | |
10 */ | |
11 | |
12 namespace Symfony\Component\Translation\Catalogue; | |
13 | |
14 use Symfony\Component\Translation\MessageCatalogueInterface; | |
15 | |
16 /** | |
17 * Represents an operation on catalogue(s). | |
18 * | |
19 * An instance of this interface performs an operation on one or more catalogues and | |
20 * stores intermediate and final results of the operation. | |
21 * | |
22 * The first catalogue in its argument(s) is called the 'source catalogue' or 'source' and | |
23 * the following results are stored: | |
24 * | |
25 * Messages: also called 'all', are valid messages for the given domain after the operation is performed. | |
26 * | |
27 * New Messages: also called 'new' (new = all ∖ source = {x: x ∈ all ∧ x ∉ source}). | |
28 * | |
29 * Obsolete Messages: also called 'obsolete' (obsolete = source ∖ all = {x: x ∈ source ∧ x ∉ all}). | |
30 * | |
31 * Result: also called 'result', is the resulting catalogue for the given domain that holds the same messages as 'all'. | |
32 * | |
33 * @author Jean-François Simon <jeanfrancois.simon@sensiolabs.com> | |
34 */ | |
35 interface OperationInterface | |
36 { | |
37 /** | |
38 * Returns domains affected by operation. | |
39 * | |
40 * @return array | |
41 */ | |
42 public function getDomains(); | |
43 | |
44 /** | |
45 * Returns all valid messages ('all') after operation. | |
46 * | |
47 * @param string $domain | |
48 * | |
49 * @return array | |
50 */ | |
51 public function getMessages($domain); | |
52 | |
53 /** | |
54 * Returns new messages ('new') after operation. | |
55 * | |
56 * @param string $domain | |
57 * | |
58 * @return array | |
59 */ | |
60 public function getNewMessages($domain); | |
61 | |
62 /** | |
63 * Returns obsolete messages ('obsolete') after operation. | |
64 * | |
65 * @param string $domain | |
66 * | |
67 * @return array | |
68 */ | |
69 public function getObsoleteMessages($domain); | |
70 | |
71 /** | |
72 * Returns resulting catalogue ('result'). | |
73 * | |
74 * @return MessageCatalogueInterface | |
75 */ | |
76 public function getResult(); | |
77 } |