org.formaria.langmgr
Class LanguageDatabaseResourceBundleLoader

java.lang.Object
  extended by org.formaria.langmgr.LanguageDatabaseResourceBundleLoader
All Implemented Interfaces:
ResourceBundleLoader

public class LanguageDatabaseResourceBundleLoader
extends java.lang.Object
implements ResourceBundleLoader

A resource bundle loader interface for a language resources. See the Localization chapter of the Aria User Guide for more detail.

Aria uses standard property files for localization. These localization files can be set for an individual page (by setting the 'resource' attribute of the Page element or for the component factory. The project's resource manager is used to identify the current locale and the name of the property file by default.

Copyright (c) Formaria Ltd., 2008, This software is licensed under the GNU Public License (GPL), please see license.txt for more details. If you make commercial use of this software you must purchase a commercial license from Formaria.

$Revision: 1.3 $


Field Summary
protected  Project currentProject
           
 
Constructor Summary
LanguageDatabaseResourceBundleLoader(Project project)
          Create a new resource bundle
 
Method Summary
 java.util.ResourceBundle getResourceBundle(java.lang.String name)
          Get the named resource bundle.
static void setKeyField(java.lang.String keyFieldName)
          Set the key field name.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

currentProject

protected Project currentProject
Constructor Detail

LanguageDatabaseResourceBundleLoader

public LanguageDatabaseResourceBundleLoader(Project project)
Create a new resource bundle

Method Detail

getResourceBundle

public java.util.ResourceBundle getResourceBundle(java.lang.String name)
Get the named resource bundle. The name may correspond to a context e.g. a page or part of an application.

Specified by:
getResourceBundle in interface ResourceBundleLoader
Parameters:
name - the language name
Returns:
the language resource bundle

setKeyField

public static void setKeyField(java.lang.String keyFieldName)
Set the key field name.

Parameters:
keyFieldName - the field name