From: <pn...@hy...> - 2009-11-19 02:37:00
|
Author: pnguyen Date: 2009-11-18 18:36:46 -0800 (Wed, 18 Nov 2009) New Revision: 13962 URL: http://svn.hyperic.org/?view=rev&root=Hyperic+HQ&revision=13962 Modified: branches/HQ_4_2_0_PATCH/src/org/hyperic/hq/appdef/server/session/Service.java branches/HQ_4_2_0_PATCH/src/org/hyperic/hq/appdef/shared/ServiceValue.java Log: [HHQ-3513] Added resourceId to ServiceValue so HQApi does not need to do an additional lookup Modified: branches/HQ_4_2_0_PATCH/src/org/hyperic/hq/appdef/server/session/Service.java =================================================================== --- branches/HQ_4_2_0_PATCH/src/org/hyperic/hq/appdef/server/session/Service.java 2009-11-18 20:33:10 UTC (rev 13961) +++ branches/HQ_4_2_0_PATCH/src/org/hyperic/hq/appdef/server/session/Service.java 2009-11-19 02:36:46 UTC (rev 13962) @@ -178,6 +178,8 @@ _serviceValue.setName(getName()); _serviceValue.setDescription(getDescription()); _serviceValue.setId(getId()); + _serviceValue.setResourceId(getResource() != null ? + getResource().getId() : null); _serviceValue.setMTime(getMTime()); _serviceValue.setCTime(getCTime()); if (getServer() != null) { Modified: branches/HQ_4_2_0_PATCH/src/org/hyperic/hq/appdef/shared/ServiceValue.java =================================================================== --- branches/HQ_4_2_0_PATCH/src/org/hyperic/hq/appdef/shared/ServiceValue.java 2009-11-18 20:33:10 UTC (rev 13961) +++ branches/HQ_4_2_0_PATCH/src/org/hyperic/hq/appdef/shared/ServiceValue.java 2009-11-19 02:36:46 UTC (rev 13962) @@ -62,6 +62,8 @@ private boolean descriptionHasBeenSet = false; private Integer id; private boolean idHasBeenSet = false; + private Integer resourceId; + private boolean resourceIdHasBeenSet = false; private Long mTime; private boolean mTimeHasBeenSet = false; private Long cTime; @@ -131,6 +133,8 @@ configResponseIdHasBeenSet = true; this.parentId = otherValue.parentId; parentIdHasBeenSet = true; + this.resourceId = otherValue.resourceId; + resourceIdHasBeenSet = true; this.name = otherValue.name; nameHasBeenSet = true; this.description = otherValue.description; @@ -287,6 +291,20 @@ public boolean parentIdHasBeenSet(){ return parentIdHasBeenSet; } + + public Integer getResourceId() { + return this.resourceId; + } + + public void setResourceId(Integer resourceId) { + this.resourceId = resourceId; + resourceIdHasBeenSet = true; + } + + public boolean resourceIdHasBeenSet() { + return resourceIdHasBeenSet; + } + public String getName() { return this.name; |