cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bhais...@apache.org
Subject [31/34] git commit: updated refs/heads/master to 7a57ce3
Date Mon, 15 Jun 2015 09:15:04 GMT
Fix 2 findbugs warnings in ApiResponseHelper.java ints were being boxed just to call .toString()

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>

This closes #438


Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/1bd32862
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/1bd32862
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/1bd32862

Branch: refs/heads/master
Commit: 1bd3286263f973380d3f411fc9d667ecc974b385
Parents: ea7f4bd
Author: Rafael da Fonseca <rsafonseca@gmail.com>
Authored: Sun Jun 14 17:48:48 2015 +0200
Committer: Rohit Yadav <rohit.yadav@shapeblue.com>
Committed: Mon Jun 15 12:10:04 2015 +0300

----------------------------------------------------------------------
 server/src/com/cloud/api/ApiResponseHelper.java | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/1bd32862/server/src/com/cloud/api/ApiResponseHelper.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/api/ApiResponseHelper.java b/server/src/com/cloud/api/ApiResponseHelper.java
index d904e73..99a80f8 100644
--- a/server/src/com/cloud/api/ApiResponseHelper.java
+++ b/server/src/com/cloud/api/ApiResponseHelper.java
@@ -408,7 +408,7 @@ public class ApiResponseHelper implements ResponseGenerator {
             populateAccount(resourceLimitResponse, limit.getOwnerId());
             populateDomain(resourceLimitResponse, accountTemp.getDomainId());
         }
-        resourceLimitResponse.setResourceType(Integer.valueOf(limit.getType().getOrdinal()).toString());
+        resourceLimitResponse.setResourceType(Integer.toString(limit.getType().getOrdinal()));
 
         if ((limit.getType() == ResourceType.primary_storage || limit.getType() == ResourceType.secondary_storage)
&& limit.getMax() >= 0) {
             resourceLimitResponse.setMax((long)Math.ceil((double)limit.getMax() / ResourceType.bytesToGiB));
@@ -434,7 +434,7 @@ public class ApiResponseHelper implements ResponseGenerator {
             populateDomain(resourceCountResponse, resourceCount.getOwnerId());
         }
 
-        resourceCountResponse.setResourceType(Integer.valueOf(resourceCount.getType().getOrdinal()).toString());
+        resourceCountResponse.setResourceType(Integer.toString(resourceCount.getType().getOrdinal()));
         resourceCountResponse.setResourceCount(resourceCount.getCount());
         resourceCountResponse.setObjectName("resourcecount");
         return resourceCountResponse;


Mime
View raw message