Conditions | 1 |
Paths | 1 |
Total Lines | 45 |
Code Lines | 40 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
18 | public function getConfigTreeBuilder() |
||
19 | { |
||
20 | $treeBuilder = new TreeBuilder(); |
||
21 | $rootNode = $treeBuilder->root('decline_transformat'); |
||
22 | |||
23 | $rootNode |
||
24 | ->children() |
||
25 | ->scalarNode('directory') |
||
26 | ->info('The directory where the translation files are located.') |
||
27 | ->isRequired() |
||
28 | ->end() |
||
29 | ->arrayNode('xliff') |
||
30 | ->addDefaultsIfNotSet() |
||
31 | ->children() |
||
32 | ->enumNode('extension') |
||
33 | ->info('The extension of the translation files which should be formatted.') |
||
34 | ->defaultValue('xlf') |
||
35 | ->values(['xlf', 'xliff']) |
||
36 | ->end() |
||
37 | ->end() |
||
38 | ->children() |
||
39 | ->scalarNode('sourceLanguage') |
||
40 | ->info('The source language of the translation files.') |
||
41 | ->defaultValue('en') |
||
42 | ->end() |
||
43 | ->end() |
||
44 | ->children() |
||
45 | ->scalarNode('namespace') |
||
46 | ->info('The xml namespace translation files.') |
||
47 | ->defaultValue('urn:oasis:names:tc:xliff:document:1.2') |
||
48 | ->end() |
||
49 | ->end() |
||
50 | ->children() |
||
51 | ->enumNode('validation') |
||
52 | ->info('The type of validation that should be applied to the xliff files.') |
||
53 | ->defaultValue(false) |
||
54 | ->values([false, 'transitional', 'strict']) |
||
55 | ->end() |
||
56 | ->end() |
||
57 | ->end() |
||
58 | ->end() |
||
59 | ; |
||
60 | |||
61 | return $treeBuilder; |
||
62 | } |
||
63 | } |
||
64 |