|
Oracle Fusion Middleware Java API Reference for Oracle WebCenter 11g Release 1 (11.1.1.4.0) E15995-03 |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: REQUIRED | OPTIONAL | DETAIL: ELEMENT |
@Documented
@Retention(value=RUNTIME)
@Target(value={TYPE,FIELD,METHOD,PARAMETER})
public @interface L10n
Annotation used to specify (mark) the annotated element with a specific resource bundle.
Example code usage:
package test.l10n; import oracle.wcps.l10n.annotation.L10n; import oracle.wcps.l10n.annotation.L10nName; import oracle.wcps.l10n.annotation.L10nDesc; // No "bundle" set, so test.l10n.MyLocalizedClass.properties // will be used. @L10n() @L10nName(key="MyLocalizedClass.name") @L10nDesc(key="MyLocalizedClass.description") class MyLocalizedClass { // Retrieves "myValue.name" from // test.l10n.MyLocalizedClass.properties @L10nName(key="myValue.name") private String myValue; // Retrieves "getMyValue.description" from // test.l10n.CustomResources @L10n(bundle="test.l10n.CustomResources") @L10nName(key="getMyValue.description") public String getMyValue() { return myValue; } // Retrieves "doStuff.parameter" from // test.l10n.BundleResources public void doStuff(@L10nDesc(key="doStuff.parameter") String parameter) { // Do some stuff here... // . // . // . } }
Optional Element Summary | |
---|---|
java.lang.String |
bundle The resource bundle to use for localization. |
public abstract java.lang.String bundle
|
Oracle Fusion Middleware Java API Reference for Oracle WebCenter 11g Release 1 (11.1.1.4.0) E15995-03 |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: REQUIRED | OPTIONAL | DETAIL: ELEMENT |