|
Errai 3.0.1-SNAPSHOT | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: REQUIRED | OPTIONAL | DETAIL: ELEMENT |
@Documented @Target(value={TYPE,PARAMETER,FIELD}) @Retention(value=RUNTIME) public @interface Bundle
An annotation that provides a mechanism for the developer to specify the name of an i18n bundle to use when doing i18n replacements within an Errai UI Template. Note that multiple bundles can be used, but all bundles are ultimately aggregated together prior to translating any of the Errai UI Templates. In other words, developers are free to break up their bundles in whatever way makes sense, but at the end of the day all bundles will be merged and indexed by locale.
package org.example; @Dependent @Templated @Bundle("loginBundle.json") public class CustomComponent extends Composite { @Inject @DataField("username.label") private InlineLabel usernameLabel; @Inject private TextBox username; @Inject @DataField("password.label") private InlineLabel passwordLabel; @Inject private TextBox password; @Inject @DataField("login") private Button login; @Inject @DataField("cancel") private Button cancel; @EventHandler("login") private void doLogin(ClickEvent event) { // log in } }
Required Element Summary | |
---|---|
String |
value
Indicates the name of the Errai i18n bundle to use for i18n replacements for this class. |
Element Detail |
---|
public abstract String value
|
Errai 3.0.1-SNAPSHOT | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: REQUIRED | OPTIONAL | DETAIL: ELEMENT |