ResourceBundle.getBundle(String baseName) has the following syntax.
public static final ResourceBundle getBundle(String baseName)
In the following code shows how to use ResourceBundle.getBundle(String baseName) method.
/* w w w . j a v a 2s . c o m*/ import java.util.ResourceBundle; public class Main { public static void main(String[] args) { ResourceBundle bundle = ResourceBundle.getBundle("hello"); System.out.println(bundle.getString("hello")); } }