BUG 2596: Use base service name in service serialization.
[controller.git] / opendaylight / netconf / config-netconf-connector / src / main / java / org / opendaylight / controller / netconf / confignetconfconnector / mapping / attributes / mapping / ObjectMapper.java
index 463e98100c2578138932340df7470d9df27935d1..2608c57e000316e1cd2df3aa80d38a34b5c72890 100644 (file)
@@ -43,10 +43,8 @@ public class ObjectMapper extends AttributeIfcSwitchStatement<AttributeMappingSt
     public AttributeMappingStrategy<?, ? extends OpenType<?>> prepareStrategy(AttributeIfc attributeIfc) {
 
         if(attributeIfc instanceof DependencyAttribute) {
-            serviceNameOfDepAttr = ((DependencyAttribute)attributeIfc).getDependency().getSie().getQName().getLocalName();
             namespaceOfDepAttr = ((DependencyAttribute)attributeIfc).getDependency().getSie().getQName().getNamespace().toString();
         } else if (attributeIfc instanceof ListDependenciesAttribute) {
-            serviceNameOfDepAttr = ((ListDependenciesAttribute)attributeIfc).getDependency().getSie().getQName().getLocalName();
             namespaceOfDepAttr = ((ListDependenciesAttribute)attributeIfc).getDependency().getSie().getQName().getNamespace().toString();
         }
 
@@ -110,14 +108,12 @@ public class ObjectMapper extends AttributeIfcSwitchStatement<AttributeMappingSt
         return new UnionCompositeAttributeMappingStrategy(compositeType, innerStrategies, attributeMapping);
     }
 
-    private String serviceNameOfDepAttr;
     private String namespaceOfDepAttr;
 
     @Override
     protected AttributeMappingStrategy<?, ? extends OpenType<?>> caseDependencyAttribute(
             SimpleType<?> openType) {
-        return new ObjectNameAttributeMappingStrategy(openType,
-                serviceNameOfDepAttr, namespaceOfDepAttr);
+        return new ObjectNameAttributeMappingStrategy(openType, namespaceOfDepAttr);
     }
 
     @Override