Original committer: Venkata Siva Vijayendra Bhamidipati
This commit is contained in:
Alena Prokharchyk 2012-08-30 10:18:31 -07:00
parent 3429c55e55
commit 7272b8d56b

View File

@ -16,15 +16,17 @@
// under the License.
package com.cloud.api.response;
import com.cloud.utils.IdentityProxy;
import com.cloud.serializer.Param;
import com.google.gson.annotations.SerializedName;
import java.util.ArrayList;
import com.cloud.serializer.Param;
import com.cloud.utils.IdentityProxy;
import com.google.gson.annotations.SerializedName;
public class ExceptionResponse extends BaseResponse {
@SerializedName("uuidList") @Param(description="List of uuids associated with this error")
private ArrayList<IdentityProxy> idList = new ArrayList<IdentityProxy>();
@SerializedName("uuidList") @Param(description="List of uuids associated with this error")
private ArrayList<IdentityProxy> idList = new ArrayList<IdentityProxy>();
@SerializedName("errorcode") @Param(description="numeric code associated with this error")
private Integer errorCode;
@ -49,17 +51,22 @@ public class ExceptionResponse extends BaseResponse {
public void setErrorText(String errorText) {
this.errorText = errorText;
}
public void addProxyObject(String tableName, Long id, String idFieldName) {
idList.add(new IdentityProxy(tableName, id, idFieldName));
return;
}
public ArrayList<IdentityProxy> getIdProxyList() {
return idList;
}
public void setCSErrorCode(int cserrcode) {
this.csErrorCode = cserrcode;
}
public void addProxyObject(String tableName, Long id, String idFieldName) {
idList.add(new IdentityProxy(tableName, id, idFieldName));
return;
}
public ArrayList<IdentityProxy> getIdProxyList() {
return idList;
}
public void setCSErrorCode(int cserrcode) {
this.csErrorCode = cserrcode;
}
@Override
public String toString() {
return ("Error Code: " + errorCode + " Error text: " + errorText);
}
}