@Override public Map<String, InternalKeyBindingProperty<? extends Serializable>> getCopyOfProperties() { final Map<String, InternalKeyBindingProperty<? extends Serializable>> ret = new HashMap<String, InternalKeyBindingProperty<? extends Serializable>>(); for (String key : propertyTemplates.keySet()) { InternalKeyBindingProperty<? extends Serializable> current = propertyTemplates.get(key); final InternalKeyBindingProperty<? extends Serializable> clone = current.clone(); clone.setValueGeneric(getProperty(clone.getName()).getValue()); ret.put(key, clone); } return ret; }
@Override public InternalKeyBindingProperty<? extends Serializable> getProperty(final String name) { final InternalKeyBindingProperty<? extends Serializable> property = propertyTemplates.get(name); property.setValueGeneric(getData(name, property.getDefaultValue())); return property; }
protected void addProperty(InternalKeyBindingProperty<? extends Serializable> property) { propertyTemplates.put(property.getName(), property); }