Code example for PropertyResourceBundle

0
        InputStream in = null;
        try { 
            in = getFileFromClasspath(propertiesDir + "/" +
                                      packageName + ".properties");
            if (in != null) {
                bundle = new PropertyResourceBundle(in);
                bundles.put(packageName, bundle);
                return bundle;
            } 
        } catch (Exception e) {
            e.printStackTrace();
        } 
 
        return null; 
    } 
     
    public static String getString(String packageName, String key) {
        ResourceBundle b = (ResourceBundle)bundles.get(packageName);
        if (b == null) {
            b = getBundle(packageName);