String value = props.getString(key); if (value != null)
props = new Properties(key, ValueMap.EMPTY_MAP); props = new Properties(key, strings);
static JSONObject renderResources(final IExtObservable extObservable, Class<?> baseClass) throws JSONException { JSONObject resources = new JSONObject(); IPropertiesFactory propertiesFactory = Application.get().getResourceSettings().getPropertiesFactory(); Session session = Session.get(); String style = session.getStyle(); Locale locale = session.getLocale(); Class<?> clazz = extObservable.getClass(); while (clazz != baseClass) { String path = clazz.getName().replace('.', '/'); ResourceNameIterator iter = new ResourceNameIterator(path, style, null, locale, null, false); while (iter.hasNext()) { String newPath = iter.next(); final Properties props = propertiesFactory.load(clazz, newPath); if (props != null) { ValueMap all = props.getAll(); for (Map.Entry<String, Object> entry : all.entrySet()) { if (!resources.has(entry.getKey())) { resources.put(entry.getKey(), entry.getValue()); } } } } clazz = clazz.getSuperclass(); } return resources; }
String value = props.getString(key); if (value != null)
if (props != null) properties = new Properties(path, props);
String value = props.getString(key); if (value != null)
if (props != null) properties = new Properties(path, props);
String value = props.getString(key); if (value != null)
return new Properties(path, strings);
String value = props.getString(key); if (value != null)
String value = props.getString(key); if (value != null)
String value = props.getString(key); if (value != null)
@Override protected String load() { // Load the properties associated with the path IPropertiesFactory propertiesFactory = Application.get().getResourceSettings().getPropertiesFactory(); Locale locale = Session.get().getLocale(); String name = location.substring(location.lastIndexOf('/') + 1); ResourceNameIterator iterator = new ResourceNameIterator(location, null, variant, locale, null, false); while (iterator.hasNext()) { String path = iterator.next(); final Properties props = propertiesFactory.load(null, path); if (props != null) { if (variant != null) { // Lookup the value String value = props.getString(name + "_" + variant); if (value != null) { return value; } } String value = props.getString(name); if (value != null) { return value; } } } return name; }
String value = props.getString(key); if (value != null)
String value = props.getString(qualifiedKey); if (value != null) return value;
String value = props.getString(qualifiedKey); if (value != null) return value;