summaryrefslogtreecommitdiffstats
path: root/catalog-model/src
diff options
context:
space:
mode:
Diffstat (limited to 'catalog-model/src')
-rw-r--r--catalog-model/src/main/java/org/openecomp/sdc/be/model/tosca/ToscaType.java14
1 files changed, 5 insertions, 9 deletions
diff --git a/catalog-model/src/main/java/org/openecomp/sdc/be/model/tosca/ToscaType.java b/catalog-model/src/main/java/org/openecomp/sdc/be/model/tosca/ToscaType.java
index a880db0c14..98ca5d02ab 100644
--- a/catalog-model/src/main/java/org/openecomp/sdc/be/model/tosca/ToscaType.java
+++ b/catalog-model/src/main/java/org/openecomp/sdc/be/model/tosca/ToscaType.java
@@ -27,6 +27,8 @@ import java.text.SimpleDateFormat;
import java.util.List;
import java.util.Locale;
import java.util.Map;
+import lombok.AllArgsConstructor;
+import lombok.Getter;
import org.openecomp.sdc.be.model.tosca.constraints.ConstraintUtil;
import org.openecomp.sdc.be.model.tosca.constraints.exception.ConstraintValueDoNotMatchPropertyTypeException;
@@ -35,6 +37,7 @@ import org.openecomp.sdc.be.model.tosca.constraints.exception.ConstraintValueDoN
*
* @author mkv
*/
+@AllArgsConstructor
public enum ToscaType {
// @formatter:off
STRING("string"),
@@ -51,11 +54,8 @@ public enum ToscaType {
SCALAR_UNIT_FREQUENCY("scalar-unit.frequency");
// @formatter:on
- private String type;
-
- ToscaType(String type) {
- this.type = type;
- }
+ @Getter
+ private final String type;
public static ToscaType getToscaType(String typeName) {
if (typeName == null) {
@@ -92,10 +92,6 @@ public enum ToscaType {
return ToscaPropertyType.MAP.getType().equals(type) || ToscaPropertyType.LIST.getType().equals(type);
}
- public String getType() {
- return type;
- }
-
public boolean isValidValue(String value) {
switch (this) {
case BOOLEAN: