changed the header license to new license
[aai/sparky-be.git] / src / main / java / org / onap / aai / sparky / dal / elasticsearch / ElasticSearchEntityStatistics.java
index ba012bd..8226a25 100644 (file)
@@ -2,8 +2,8 @@
  * ============LICENSE_START=======================================================
  * org.onap.aai
  * ================================================================================
- * Copyright © 2017 AT&T Intellectual Property. All rights reserved.
- * Copyright © 2017 Amdocs
+ * Copyright © 2017-2018 AT&T Intellectual Property. All rights reserved.
+ * Copyright © 2017-2018 Amdocs
  * ================================================================================
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -17,8 +17,6 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  * ============LICENSE_END=========================================================
- *
- * ECOMP is a trademark and service mark of AT&T Intellectual Property.
  */
 package org.onap.aai.sparky.dal.elasticsearch;
 
@@ -47,7 +45,7 @@ public class ElasticSearchEntityStatistics {
   private static final String ERROR = "ERROR";
 
   private Map<String, HashMap<String, AtomicInteger>> entityStatistics;
-
+  
   /**
    * Creates the entity op stats.
    *
@@ -104,7 +102,8 @@ public class ElasticSearchEntityStatistics {
    *
    * @param descriptors the descriptors
    */
-  public void intializeEntityCounters(String... entityTypes) {
+  public void intializeEntityCounters(
+      String... entityTypes) {
 
     if (entityTypes != null && entityTypes.length > 0) {
       for (String entityType : entityTypes) {
@@ -112,17 +111,18 @@ public class ElasticSearchEntityStatistics {
       }
 
     }
-
+    
   }
-
-  public void intializeEntityCounters(Set<String> entityTypes) {
+  
+  public void intializeEntityCounters(
+      Set<String> entityTypes) {
 
     if (entityTypes != null && entityTypes.size() > 0) {
       for (String entityType : entityTypes) {
         entityStatistics.put(entityType, createEntityOpStats());
       }
     }
-
+    
   }
 
   /**
@@ -246,11 +246,12 @@ public class ElasticSearchEntityStatistics {
       int deletedValue = (deleted == null) ? 0 : deleted.get();
       int errorValue = (error == null) ? 0 : error.get();
 
-      sb.append("\n            ").append(String.format(
-          "%-30s TOTAL: %-12d CREATED: %-12d MODIFIED:"
+      sb.append("\n            ")
+          .append(String.format(
+              "%-30s TOTAL: %-12d CREATED: %-12d MODIFIED:"
               + " %-12d OTHER_2XX: %-12d DELETED: %-12d ERROR: %-12d",
-          counterEntityKey, totalValue, createdValue, modifiedValue, otherSuccessValue,
-          deletedValue, errorValue));
+              counterEntityKey, totalValue, createdValue, modifiedValue, otherSuccessValue,
+              deletedValue, errorValue));
     }
     return sb.toString();
   }