API refactoring -- More parameter for counter group.

This commit is contained in:
Fang Wang 2012-12-14 11:31:05 -08:00 committed by Rohit Yadav
parent 44ef998cfc
commit 27482045ce
2 changed files with 6 additions and 1 deletions

View File

@ -26,6 +26,7 @@ import org.apache.cloudstack.api.IdentityMapper;
import org.apache.cloudstack.api.Implementation;
import org.apache.cloudstack.api.Parameter;
import org.apache.cloudstack.api.ServerApiException;
import org.apache.cloudstack.api.response.CounterResponse;
import org.apache.cloudstack.api.response.SuccessResponse;
import com.cloud.async.AsyncJob;
import com.cloud.event.EventTypes;
@ -42,7 +43,7 @@ public class DeleteCounterCmd extends BaseAsyncCmd {
// ///////////////////////////////////////////////////
@IdentityMapper(entityTableName = "counter")
@Parameter(name = ApiConstants.ID, type = CommandType.LONG, required = true, description = "the ID of the counter")
@Parameter(name = ApiConstants.ID, type = CommandType.LONG, required = true, description = "the ID of the counter", entityType=CounterResponse.class)
private Long id;
// ///////////////////////////////////////////////////

View File

@ -18,12 +18,16 @@
package org.apache.cloudstack.api.response;
import org.apache.cloudstack.api.ApiConstants;
import org.apache.cloudstack.api.Entity;
import com.cloud.network.as.Counter;
import com.cloud.serializer.Param;
import com.cloud.utils.IdentityProxy;
import com.google.gson.annotations.SerializedName;
import org.apache.cloudstack.api.BaseResponse;
@SuppressWarnings("unused")
@Entity(value=Counter.class)
public class CounterResponse extends BaseResponse {
@SerializedName("id")
@Param(description = "the id of the Counter")