com.amazonaws.services.finspacedata.model.ChangesetErrorInfo Maven / Gradle / Ivy
/*
* Copyright 2019-2024 Amazon.com, Inc. or its affiliates. All Rights Reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance with
* the License. A copy of the License is located at
*
* http://aws.amazon.com/apache2.0
*
* or in the "license" file accompanying this file. This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
* CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions
* and limitations under the License.
*/
package com.amazonaws.services.finspacedata.model;
import java.io.Serializable;
import javax.annotation.Generated;
import com.amazonaws.protocol.StructuredPojo;
import com.amazonaws.protocol.ProtocolMarshaller;
/**
*
* The structure with error messages.
*
*
* @see AWS API
* Documentation
*/
@Generated("com.amazonaws:aws-java-sdk-code-generator")
public class ChangesetErrorInfo implements Serializable, Cloneable, StructuredPojo {
/**
*
* The text of the error message.
*
*/
private String errorMessage;
/**
*
* The category of the error.
*
*
* -
*
* VALIDATION
– The inputs to this request are invalid.
*
*
* -
*
* SERVICE_QUOTA_EXCEEDED
– Service quotas have been exceeded. Please contact AWS support to increase
* quotas.
*
*
* -
*
* ACCESS_DENIED
– Missing required permission to perform this request.
*
*
* -
*
* RESOURCE_NOT_FOUND
– One or more inputs to this request were not found.
*
*
* -
*
* THROTTLING
– The system temporarily lacks sufficient resources to process the request.
*
*
* -
*
* INTERNAL_SERVICE_EXCEPTION
– An internal service error has occurred.
*
*
* -
*
* CANCELLED
– Cancelled.
*
*
* -
*
* USER_RECOVERABLE
– A user recoverable error has occurred.
*
*
*
*/
private String errorCategory;
/**
*
* The text of the error message.
*
*
* @param errorMessage
* The text of the error message.
*/
public void setErrorMessage(String errorMessage) {
this.errorMessage = errorMessage;
}
/**
*
* The text of the error message.
*
*
* @return The text of the error message.
*/
public String getErrorMessage() {
return this.errorMessage;
}
/**
*
* The text of the error message.
*
*
* @param errorMessage
* The text of the error message.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public ChangesetErrorInfo withErrorMessage(String errorMessage) {
setErrorMessage(errorMessage);
return this;
}
/**
*
* The category of the error.
*
*
* -
*
* VALIDATION
– The inputs to this request are invalid.
*
*
* -
*
* SERVICE_QUOTA_EXCEEDED
– Service quotas have been exceeded. Please contact AWS support to increase
* quotas.
*
*
* -
*
* ACCESS_DENIED
– Missing required permission to perform this request.
*
*
* -
*
* RESOURCE_NOT_FOUND
– One or more inputs to this request were not found.
*
*
* -
*
* THROTTLING
– The system temporarily lacks sufficient resources to process the request.
*
*
* -
*
* INTERNAL_SERVICE_EXCEPTION
– An internal service error has occurred.
*
*
* -
*
* CANCELLED
– Cancelled.
*
*
* -
*
* USER_RECOVERABLE
– A user recoverable error has occurred.
*
*
*
*
* @param errorCategory
* The category of the error.
*
* -
*
* VALIDATION
– The inputs to this request are invalid.
*
*
* -
*
* SERVICE_QUOTA_EXCEEDED
– Service quotas have been exceeded. Please contact AWS support to
* increase quotas.
*
*
* -
*
* ACCESS_DENIED
– Missing required permission to perform this request.
*
*
* -
*
* RESOURCE_NOT_FOUND
– One or more inputs to this request were not found.
*
*
* -
*
* THROTTLING
– The system temporarily lacks sufficient resources to process the request.
*
*
* -
*
* INTERNAL_SERVICE_EXCEPTION
– An internal service error has occurred.
*
*
* -
*
* CANCELLED
– Cancelled.
*
*
* -
*
* USER_RECOVERABLE
– A user recoverable error has occurred.
*
*
* @see ErrorCategory
*/
public void setErrorCategory(String errorCategory) {
this.errorCategory = errorCategory;
}
/**
*
* The category of the error.
*
*
* -
*
* VALIDATION
– The inputs to this request are invalid.
*
*
* -
*
* SERVICE_QUOTA_EXCEEDED
– Service quotas have been exceeded. Please contact AWS support to increase
* quotas.
*
*
* -
*
* ACCESS_DENIED
– Missing required permission to perform this request.
*
*
* -
*
* RESOURCE_NOT_FOUND
– One or more inputs to this request were not found.
*
*
* -
*
* THROTTLING
– The system temporarily lacks sufficient resources to process the request.
*
*
* -
*
* INTERNAL_SERVICE_EXCEPTION
– An internal service error has occurred.
*
*
* -
*
* CANCELLED
– Cancelled.
*
*
* -
*
* USER_RECOVERABLE
– A user recoverable error has occurred.
*
*
*
*
* @return The category of the error.
*
* -
*
* VALIDATION
– The inputs to this request are invalid.
*
*
* -
*
* SERVICE_QUOTA_EXCEEDED
– Service quotas have been exceeded. Please contact AWS support to
* increase quotas.
*
*
* -
*
* ACCESS_DENIED
– Missing required permission to perform this request.
*
*
* -
*
* RESOURCE_NOT_FOUND
– One or more inputs to this request were not found.
*
*
* -
*
* THROTTLING
– The system temporarily lacks sufficient resources to process the request.
*
*
* -
*
* INTERNAL_SERVICE_EXCEPTION
– An internal service error has occurred.
*
*
* -
*
* CANCELLED
– Cancelled.
*
*
* -
*
* USER_RECOVERABLE
– A user recoverable error has occurred.
*
*
* @see ErrorCategory
*/
public String getErrorCategory() {
return this.errorCategory;
}
/**
*
* The category of the error.
*
*
* -
*
* VALIDATION
– The inputs to this request are invalid.
*
*
* -
*
* SERVICE_QUOTA_EXCEEDED
– Service quotas have been exceeded. Please contact AWS support to increase
* quotas.
*
*
* -
*
* ACCESS_DENIED
– Missing required permission to perform this request.
*
*
* -
*
* RESOURCE_NOT_FOUND
– One or more inputs to this request were not found.
*
*
* -
*
* THROTTLING
– The system temporarily lacks sufficient resources to process the request.
*
*
* -
*
* INTERNAL_SERVICE_EXCEPTION
– An internal service error has occurred.
*
*
* -
*
* CANCELLED
– Cancelled.
*
*
* -
*
* USER_RECOVERABLE
– A user recoverable error has occurred.
*
*
*
*
* @param errorCategory
* The category of the error.
*
* -
*
* VALIDATION
– The inputs to this request are invalid.
*
*
* -
*
* SERVICE_QUOTA_EXCEEDED
– Service quotas have been exceeded. Please contact AWS support to
* increase quotas.
*
*
* -
*
* ACCESS_DENIED
– Missing required permission to perform this request.
*
*
* -
*
* RESOURCE_NOT_FOUND
– One or more inputs to this request were not found.
*
*
* -
*
* THROTTLING
– The system temporarily lacks sufficient resources to process the request.
*
*
* -
*
* INTERNAL_SERVICE_EXCEPTION
– An internal service error has occurred.
*
*
* -
*
* CANCELLED
– Cancelled.
*
*
* -
*
* USER_RECOVERABLE
– A user recoverable error has occurred.
*
*
* @return Returns a reference to this object so that method calls can be chained together.
* @see ErrorCategory
*/
public ChangesetErrorInfo withErrorCategory(String errorCategory) {
setErrorCategory(errorCategory);
return this;
}
/**
*
* The category of the error.
*
*
* -
*
* VALIDATION
– The inputs to this request are invalid.
*
*
* -
*
* SERVICE_QUOTA_EXCEEDED
– Service quotas have been exceeded. Please contact AWS support to increase
* quotas.
*
*
* -
*
* ACCESS_DENIED
– Missing required permission to perform this request.
*
*
* -
*
* RESOURCE_NOT_FOUND
– One or more inputs to this request were not found.
*
*
* -
*
* THROTTLING
– The system temporarily lacks sufficient resources to process the request.
*
*
* -
*
* INTERNAL_SERVICE_EXCEPTION
– An internal service error has occurred.
*
*
* -
*
* CANCELLED
– Cancelled.
*
*
* -
*
* USER_RECOVERABLE
– A user recoverable error has occurred.
*
*
*
*
* @param errorCategory
* The category of the error.
*
* -
*
* VALIDATION
– The inputs to this request are invalid.
*
*
* -
*
* SERVICE_QUOTA_EXCEEDED
– Service quotas have been exceeded. Please contact AWS support to
* increase quotas.
*
*
* -
*
* ACCESS_DENIED
– Missing required permission to perform this request.
*
*
* -
*
* RESOURCE_NOT_FOUND
– One or more inputs to this request were not found.
*
*
* -
*
* THROTTLING
– The system temporarily lacks sufficient resources to process the request.
*
*
* -
*
* INTERNAL_SERVICE_EXCEPTION
– An internal service error has occurred.
*
*
* -
*
* CANCELLED
– Cancelled.
*
*
* -
*
* USER_RECOVERABLE
– A user recoverable error has occurred.
*
*
* @return Returns a reference to this object so that method calls can be chained together.
* @see ErrorCategory
*/
public ChangesetErrorInfo withErrorCategory(ErrorCategory errorCategory) {
this.errorCategory = errorCategory.toString();
return this;
}
/**
* Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be
* redacted from this string using a placeholder value.
*
* @return A string representation of this object.
*
* @see java.lang.Object#toString()
*/
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("{");
if (getErrorMessage() != null)
sb.append("ErrorMessage: ").append(getErrorMessage()).append(",");
if (getErrorCategory() != null)
sb.append("ErrorCategory: ").append(getErrorCategory());
sb.append("}");
return sb.toString();
}
@Override
public boolean equals(Object obj) {
if (this == obj)
return true;
if (obj == null)
return false;
if (obj instanceof ChangesetErrorInfo == false)
return false;
ChangesetErrorInfo other = (ChangesetErrorInfo) obj;
if (other.getErrorMessage() == null ^ this.getErrorMessage() == null)
return false;
if (other.getErrorMessage() != null && other.getErrorMessage().equals(this.getErrorMessage()) == false)
return false;
if (other.getErrorCategory() == null ^ this.getErrorCategory() == null)
return false;
if (other.getErrorCategory() != null && other.getErrorCategory().equals(this.getErrorCategory()) == false)
return false;
return true;
}
@Override
public int hashCode() {
final int prime = 31;
int hashCode = 1;
hashCode = prime * hashCode + ((getErrorMessage() == null) ? 0 : getErrorMessage().hashCode());
hashCode = prime * hashCode + ((getErrorCategory() == null) ? 0 : getErrorCategory().hashCode());
return hashCode;
}
@Override
public ChangesetErrorInfo clone() {
try {
return (ChangesetErrorInfo) super.clone();
} catch (CloneNotSupportedException e) {
throw new IllegalStateException("Got a CloneNotSupportedException from Object.clone() " + "even though we're Cloneable!", e);
}
}
@com.amazonaws.annotation.SdkInternalApi
@Override
public void marshall(ProtocolMarshaller protocolMarshaller) {
com.amazonaws.services.finspacedata.model.transform.ChangesetErrorInfoMarshaller.getInstance().marshall(this, protocolMarshaller);
}
}