Fix the nonstandard coding.
[aai/esr-server.git] / esr-mgr / src / main / java / org / onap / aai / esr / util / ThirdpartySdncManagerUtil.java
index a2d1e1a..2a01ddc 100644 (file)
@@ -16,6 +16,7 @@
 package org.onap.aai.esr.util;
 
 import java.util.ArrayList;
+import java.util.List;
 
 import org.onap.aai.esr.common.SystemType;
 import org.onap.aai.esr.entity.aai.EsrSystemInfo;
@@ -24,10 +25,11 @@ import org.onap.aai.esr.entity.aai.EsrThirdpartySdncDetail;
 import org.onap.aai.esr.entity.rest.ThirdpartySdncRegisterInfo;
 
 public class ThirdpartySdncManagerUtil {
+  private static ExtsysUtil extsysUtil = new ExtsysUtil();
   
   public EsrThirdpartySdncDetail sdncRegisterInfo2EsrSdnc(ThirdpartySdncRegisterInfo sdncRegisterInfo) {
     EsrThirdpartySdncDetail esrThirdpartySdnc = new EsrThirdpartySdncDetail();
-    sdncRegisterInfo.setThirdpartySdncId(ExtsysUtil.generateId());
+    sdncRegisterInfo.setThirdpartySdncId(extsysUtil.generateId());
     esrThirdpartySdnc.setThirdpartySdncId(sdncRegisterInfo.getThirdpartySdncId());
     esrThirdpartySdnc.setLocation(sdncRegisterInfo.getLocation());
     esrThirdpartySdnc.setProductName(sdncRegisterInfo.getProductName());
@@ -37,9 +39,9 @@ public class ThirdpartySdncManagerUtil {
   
   private EsrSystemInfoList getEsrSystemInfoList(ThirdpartySdncRegisterInfo sdncRegisterInfo) {
     EsrSystemInfoList esrSystemInfoList = new EsrSystemInfoList();
-    ArrayList<EsrSystemInfo> esrSystemInfo = new ArrayList<EsrSystemInfo>();
+    List<EsrSystemInfo> esrSystemInfo = new ArrayList<>();
     EsrSystemInfo authInfo = new EsrSystemInfo();
-    authInfo.setEsrSystemInfoId(ExtsysUtil.generateId());
+    authInfo.setEsrSystemInfoId(extsysUtil.generateId());
     authInfo.setVersion(sdncRegisterInfo.getVersion());
     authInfo.setSystemName(sdncRegisterInfo.getName());
     authInfo.setServiceUrl(sdncRegisterInfo.getUrl());