- public ConfigElementResolved(Map<String, Multimap<String, ModuleElementResolved>> retVal, Services serviceTracker) {
- this.resolvedModules = retVal;
- this.services = serviceTracker;
- }
+ for (XmlElement moduleElement : moduleElements) {
+ ResolvingStrategy<ModuleElementDefinition> resolvingStrategy = new ResolvingStrategy<ModuleElementDefinition>() {
+ @Override
+ public ModuleElementDefinition resolveElement(ModuleConfig moduleMapping, XmlElement moduleElement,
+ ServiceRegistryWrapper serviceTracker, String instanceName, String moduleNamespace,
+ EditStrategyType defaultStrategy) {
+ // TODO: add check for conflicts between global and local
+ // edit strategy
+ String perInstanceEditStrategy = moduleElement.getAttribute(XmlNetconfConstants.OPERATION_ATTR_KEY,
+ XmlNetconfConstants.URN_IETF_PARAMS_XML_NS_NETCONF_BASE_1_0);
+ return new ModuleElementDefinition(instanceName, perInstanceEditStrategy, defaultStrategy);
+ }
+ };