Java ResourceBundle .getBundle (String baseName)
Syntax
ResourceBundle.getBundle(String baseName) has the following syntax.
public static final ResourceBundle getBundle(String baseName)
Example
In the following code shows how to use ResourceBundle.getBundle(String baseName) method.
/*from www. ja va2 s .com*/
import java.util.ResourceBundle;
public class Main {
public static void main(String[] args) {
ResourceBundle bundle = ResourceBundle.getBundle("hello");
System.out.println(bundle.getString("hello"));
}
}
Home »
Java Tutorial »
java.util »
Java Tutorial »
java.util »