From 601c7f2800a7da2c182ad02b0d76eda03758c47d Mon Sep 17 00:00:00 2001 From: Bharat saraswal Date: Fri, 22 Sep 2017 19:22:11 +0530 Subject: Resolved below sonar issues. removed redundant code. rename variable to follow camelCase. removed tab char and changed them with spaces. Issue-ID:SO-98 Change-Id: I1b56af476ea587640adb2c6d601ac589d2726e11 Signed-off-by: Bharat saraswal --- .../openstack/heat/model/CreateStackParam.java | 41 +++++++++++++--------- 1 file changed, 25 insertions(+), 16 deletions(-) (limited to 'heat-model') diff --git a/heat-model/src/main/java/com/woorea/openstack/heat/model/CreateStackParam.java b/heat-model/src/main/java/com/woorea/openstack/heat/model/CreateStackParam.java index 9ef0198..19808e3 100644 --- a/heat-model/src/main/java/com/woorea/openstack/heat/model/CreateStackParam.java +++ b/heat-model/src/main/java/com/woorea/openstack/heat/model/CreateStackParam.java @@ -20,11 +20,11 @@ package com.woorea.openstack.heat.model; * Modifications copyright (c) 2017 AT&T Intellectual Property */ -import org.codehaus.jackson.annotate.JsonProperty; - import java.util.Map; +import org.codehaus.jackson.annotate.JsonProperty; public class CreateStackParam { + @JsonProperty("stack_name") private String stackName; @@ -45,7 +45,7 @@ public class CreateStackParam { @JsonProperty("disable_rollback") private boolean disableRollback = true; - + @JsonProperty("files") private Map files; @@ -119,25 +119,34 @@ public class CreateStackParam { public void setDisableRollback(boolean disableRollback) { this.disableRollback = disableRollback; } - + public void setFiles(Map files) { - this.files = files; + this.files = files; } + public Map getFiles() { - return this.files; + return files; } @Override public String toString() { - return "CreateStackParam{" + - "stackName='" + stackName + '\'' + - ", templateUrl='" + templateUrl + '\'' + - ", template='" + template + '\'' + - ", parameters=" + parameters + - ", timeoutMinutes=" + timeoutMinutes + - ", environment='" + environment + '\'' + - ", disableRollback='" + disableRollback + '\'' + - ", files=" + files + - '}'; + return String.format("CreateStackParam{" + + "stackName='%s'," + + " templateUrl='%s'," + + " template='%s'," + + " parameters=%s," + + " timeoutMinutes=%d," + + " environment='%s'," + + " disableRollback='%s'," + + " files=%s" + + "}", + stackName, + templateUrl, + template, + parameters, + timeoutMinutes, + environment, + disableRollback, + files); } } -- cgit 1.2.3-korg