Fix checkstyle violations in sdc/jtosca
[sdc/sdc-tosca.git] / src / main / java / org / onap / sdc / toscaparser / api / elements / ScalarUnitTime.java
index 45848af..8d2c13e 100644 (file)
@@ -7,9 +7,9 @@
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
  * You may obtain a copy of the License at
- * 
+ *
  *      http://www.apache.org/licenses/LICENSE-2.0
- * 
+ *
  * Unless required by applicable law or agreed to in writing, software
  * distributed under the License is distributed on an "AS IS" BASIS,
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -22,16 +22,16 @@ package org.onap.sdc.toscaparser.api.elements;
 
 public class ScalarUnitTime extends ScalarUnit {
 
-       public ScalarUnitTime(Object value) {
-               super(value);
-           SCALAR_UNIT_DEFAULT = "ms";
-           SCALAR_UNIT_DICT.put("d",86400L);
-           SCALAR_UNIT_DICT.put("h",3600L);
-           SCALAR_UNIT_DICT.put("m",60L);
-           SCALAR_UNIT_DICT.put("s",1L);
-           SCALAR_UNIT_DICT.put("ms",0.001);
-           SCALAR_UNIT_DICT.put("us",0.000001);
-           SCALAR_UNIT_DICT.put("ns",0.000000001);
-       }
+    public ScalarUnitTime(Object value) {
+        super(value);
+        setScalarUnitDefault("ms");
+        putToScalarUnitDict("d", 86400L);
+        putToScalarUnitDict("h", 3600L);
+        putToScalarUnitDict("m", 60L);
+        putToScalarUnitDict("s", 1L);
+        putToScalarUnitDict("ms", 0.001);
+        putToScalarUnitDict("us", 0.000001);
+        putToScalarUnitDict("ns", 0.000000001);
+    }
 
 }