/** * Constructs proxy with specified <code>delegate</code>. * * @param delegate Value which will be evaluated and cached. */ public ValueProxy(Value<T> delegate) { setDelegate(delegate); }
/** * Constructs proxy with specified <code>delegate</code>. * * @param delegate Value which will be evaluated and cached. */ public ValueProxy(Value<T> delegate) { setDelegate(delegate); }
@SuppressWarnings({ "rawtypes", "unchecked" }) private void parseValues() { for (Map.Entry<String, Object> entry : values.entrySet()) { Value<?> val = parse(entry.getKey(), entry.getValue()); ValueProxy proxy = proxyValues.get(entry.getKey()); proxy.setDelegate(val); entry.setValue(proxy); } }
@SuppressWarnings({ "rawtypes", "unchecked" }) private void parseValues() { for (Map.Entry<String, Object> entry : values.entrySet()) { Value<?> val = parse(entry.getKey(), entry.getValue()); ValueProxy proxy = proxyValues.get(entry.getKey()); proxy.setDelegate(val); entry.setValue(proxy); } }
@SuppressWarnings({ "rawtypes", "unchecked" }) private Value<?> parseCompositeValue(String parentName, Map<String, Object> def) { Map<String, Value<?>> values = new HashMap<>(); for (String property : def.keySet()) { String fullName = parentName + "." + property; Value<?> val = parse(fullName, def.get(property)); ValueProxy proxy = proxyValues.get(fullName); proxy.setDelegate(val); values.put(property, proxy); } return new CompositeValue(values); }
@SuppressWarnings({ "rawtypes", "unchecked" }) private Value<?> parseCompositeValue(String parentName, Map<String, Object> def) { Map<String, Value<?>> values = new HashMap<>(); for (String property : def.keySet()) { String fullName = parentName + "." + property; Value<?> val = parse(fullName, def.get(property)); ValueProxy proxy = proxyValues.get(fullName); proxy.setDelegate(val); values.put(property, proxy); } return new CompositeValue(values); }