1. Project Clover database Tue Dec 20 2016 21:24:09 CET
  2. Package org.xwiki.localization.message

File TranslationMessageElement.java

 

Code metrics

0
0
0
1
46
9
0
-
-
0
-

Classes

Class Line # Actions
TranslationMessageElement 34 0 - 0 0
-1.0 -
 

Contributing tests

No tests hitting this source file were found.

Source view

1    /*
2    * See the NOTICE file distributed with this work for additional
3    * information regarding copyright ownership.
4    *
5    * This is free software; you can redistribute it and/or modify it
6    * under the terms of the GNU Lesser General Public License as
7    * published by the Free Software Foundation; either version 2.1 of
8    * the License, or (at your option) any later version.
9    *
10    * This software is distributed in the hope that it will be useful,
11    * but WITHOUT ANY WARRANTY; without even the implied warranty of
12    * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13    * Lesser General Public License for more details.
14    *
15    * You should have received a copy of the GNU Lesser General Public
16    * License along with this software; if not, write to the Free
17    * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
18    * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
19    */
20    package org.xwiki.localization.message;
21   
22    import java.util.Collection;
23    import java.util.Locale;
24   
25    import org.xwiki.localization.TranslationBundle;
26    import org.xwiki.rendering.block.Block;
27   
28    /**
29    * An element in a translation message.
30    *
31    * @version $Id: 0755fc298e7c1a1bd59986006aae6ef37e660b49 $
32    * @since 5.0M2
33    */
 
34    public interface TranslationMessageElement
35    {
36    /**
37    * Execute the transformation (resolve any variable or parameter in its content) and produce a Block to insert in an
38    * into a XDOM or to render as it is.
39    *
40    * @param locale the locale to used to resolve variables
41    * @param bundles the bundles to resolve variables with
42    * @param parameters the parameters
43    * @return the result translation
44    */
45    Block render(Locale locale, Collection<TranslationBundle> bundles, Object... parameters);
46    }