简体   繁体   English

java.util.MissingResourceException:找不到基本名称为ResBundle的包,语言环境为en_GB

[英]java.util.MissingResourceException: Can't find bundle for base name ResBundle, locale en_GB

I am receiving following exception while I have created a ResBundle class in same package which extends ListResourceBundle class. 我在同一个包中创建了一个扩展ListResourceBundle类的ResBundle类时收到以下异常。

java.util.MissingResourceException: Can't find bundle for base name ResBundle, locale en_GB

My calling code 我的通话代码

Locale locale = Locale.getDefault();
ResourceBundle resourceBundle = ResourceBundle.getBundle("ResBundle", locale);
ResourceBundle.getBundle("ResBundle") 

tells the classloader to load a resource named "ResBundle" with default package (that is, no package). 告诉类加载器使用默认包(即没有包)加载名为“ResBundle”的资源。 It does NOT mean a resource in the current package that has the referencing class. 它并不意味着当前包中具有引用类的资源。

So try giving the package path and see if the issue gets resolved. 因此,请尝试提供包路径并查看问题是否得到解决。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 java.util.MissingResourceException:找不到基本名称消息的bundle,locale en_US - java.util.MissingResourceException: Can't find bundle for base name messages, locale en_US java.util.MissingResourceException:找不到基本名称视图,语言环境的捆绑包 - java.util.MissingResourceException: Can't find bundle for base name views, locale en 原因:java.util.MissingResourceException:找不到基本名称为LocalStrings,语言环境为en_US的捆绑软件 - Caused by: java.util.MissingResourceException: Can't find bundle for base name LocalStrings, locale en_US java.util.MissingResourceException:找不到基本名称配置,语言环境的捆绑包 - java.util.MissingResourceException: Can't find bundle for base name config, locale en java.util.MissingResourceException:找不到基本名称'property_file name'的捆绑包,语言环境en_US - java.util.MissingResourceException: Can't find bundle for base name 'property_file name', locale en_US java.util.MissingResourceException:找不到基本名称消息包,语言环境en_US Floreant POS - java.util.MissingResourceException: Can't find bundle for base name messages, locale en_US Floreant POS java.util.MissingResourceException:找不到基本名称的包 - java.util.MissingResourceException: Can't find bundle for base name java.util.MissingResourceException:找不到基本名称的包 - java.util.MissingResourceException: Can't find bundle for base name java.util.MissingResourceException:找不到基本名称为com.sun.org.apache.xerces.internal.impl.msg.SAXMessages的包,语言环境为en_US - java.util.MissingResourceException: Can't find bundle for base name com.sun.org.apache.xerces.internal.impl.msg.SAXMessages, locale en_US Spring MQTT:java.util.MissingResourceException:找不到基本名称 org.eclipse.paho.client.mqttv3.internal.nls.logcat,区域设置 en_US 的包 - Spring MQTT: java.util.MissingResourceException: Can't find bundle for base name org.eclipse.paho.client.mqttv3.internal.nls.logcat, locale en_US
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM