Code example for MissingResourceException

      catch (MissingResourceException e2)
        // Now we are really in trouble. 
        // very bad, definitely very bad...not going to get very far 
        throw new MissingResourceException(
          "Could not load any resource bundles.", className, "");
   * Return the resource file suffic for the indicated locale 
   * For most locales, this will be based the language code.  However 
   * for Chinese, we do distinguish between Taiwan and PRC 
   * @param locale the locale 
   * @return an String suffix which canbe appended to a resource name 
  private static final String getResourceSuffix(Locale locale)
Experience pair programming with AI  Get Codota for Java