vmware: Annotate cisco related apis, remove IdentityMapper

Signed-off-by: Rohit Yadav <bhaisaab@apache.org>
This commit is contained in:
Rohit Yadav 2013-01-04 16:42:28 -08:00
parent a2f8f42575
commit 4cf0b05a0b
4 changed files with 11 additions and 7 deletions

View File

@ -21,12 +21,12 @@ import org.apache.log4j.Logger;
import org.apache.cloudstack.api.ApiConstants;
import org.apache.cloudstack.api.BaseAsyncCmd;
import org.apache.cloudstack.api.IdentityMapper;
import org.apache.cloudstack.api.APICommand;
import org.apache.cloudstack.api.Parameter;
import org.apache.cloudstack.api.PlugService;
import org.apache.cloudstack.api.ServerApiException;
import org.apache.cloudstack.api.response.SuccessResponse;
import com.cloud.api.response.CiscoNexusVSMResponse;
import com.cloud.event.EventTypes;
import com.cloud.exception.ConcurrentOperationException;
import com.cloud.exception.InsufficientCapacityException;
@ -46,8 +46,8 @@ public class DeleteCiscoNexusVSMCmd extends BaseAsyncCmd {
//////////////// API parameters /////////////////////
/////////////////////////////////////////////////////
@IdentityMapper(entityTableName="virtual_supervisor_module")
@Parameter(name=ApiConstants.ID, type=CommandType.LONG, required=true, description="Id of the Cisco Nexus 1000v VSM device to be deleted")
@Parameter(name=ApiConstants.ID, type=CommandType.UUID, entityType = CiscoNexusVSMResponse.class,
required=true, description="Id of the Cisco Nexus 1000v VSM device to be deleted")
private Long id;
/////////////////////////////////////////////////////

View File

@ -47,8 +47,8 @@ public class DisableCiscoNexusVSMCmd extends BaseAsyncCmd {
//////////////// API parameters /////////////////////
/////////////////////////////////////////////////////
@IdentityMapper(entityTableName="virtual_supervisor_module")
@Parameter(name=ApiConstants.ID, type=CommandType.LONG, required=true, description="Id of the Cisco Nexus 1000v VSM device to be deleted")
@Parameter(name=ApiConstants.ID, type=CommandType.UUID, entityType = CiscoNexusVSMResponse.class,
required=true, description="Id of the Cisco Nexus 1000v VSM device to be deleted")
private Long id;
/////////////////////////////////////////////////////

View File

@ -42,8 +42,8 @@ public class EnableCiscoNexusVSMCmd extends BaseAsyncCmd {
//////////////// API parameters /////////////////////
/////////////////////////////////////////////////////
@IdentityMapper(entityTableName="virtual_supervisor_module")
@Parameter(name=ApiConstants.ID, type=CommandType.LONG, required=true, description="Id of the Cisco Nexus 1000v VSM device to be enabled")
@Parameter(name=ApiConstants.ID, type=CommandType.UUID, entityType=CiscoNexusVSMResponse.class,
required=true, description="Id of the Cisco Nexus 1000v VSM device to be enabled")
private Long id;
/////////////////////////////////////////////////////

View File

@ -20,7 +20,11 @@ import org.apache.cloudstack.api.ApiConstants;
import com.cloud.serializer.Param;
import com.google.gson.annotations.SerializedName;
import org.apache.cloudstack.api.BaseResponse;
import org.apache.cloudstack.api.EntityReference;
import com.cloud.network.CiscoNexusVSMDevice;
@EntityReference(value=CiscoNexusVSMDevice.class)
public class CiscoNexusVSMResponse extends BaseResponse {
@SerializedName(ApiConstants.EXTERNAL_SWITCH_MGMT_DEVICE_ID) @Param(description="device id of the Cisco N1KV VSM device")