Class InvalidCrossAccountRoleException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.lang.RuntimeException
-
- com.amazonaws.AmazonClientException
-
- com.amazonaws.AmazonServiceException
-
- com.amazonaws.services.inspector.model.InvalidCrossAccountRoleException
-
- All Implemented Interfaces:
Serializable
public class InvalidCrossAccountRoleException extends AmazonServiceException
Amazon Inspector cannot assume the cross-account role that it needs to list your EC2 instances during the assessment run.
- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.amazonaws.AmazonServiceException
AmazonServiceException.ErrorType
-
-
Constructor Summary
Constructors Constructor Description InvalidCrossAccountRoleException(String message)
Constructs a new InvalidCrossAccountRoleException with the specified error message.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Boolean
getCanRetry()
You can immediately retry your request.String
getErrorCode()
Code that indicates the type of error that is generated.Boolean
isCanRetry()
You can immediately retry your request.void
setCanRetry(Boolean canRetry)
You can immediately retry your request.void
setErrorCode(InvalidCrossAccountRoleErrorCode errorCode)
Code that indicates the type of error that is generated.void
setErrorCode(String errorCode)
Code that indicates the type of error that is generated.InvalidCrossAccountRoleException
withCanRetry(Boolean canRetry)
You can immediately retry your request.InvalidCrossAccountRoleException
withErrorCode(InvalidCrossAccountRoleErrorCode errorCode)
Code that indicates the type of error that is generated.InvalidCrossAccountRoleException
withErrorCode(String errorCode)
Code that indicates the type of error that is generated.-
Methods inherited from class com.amazonaws.AmazonServiceException
getErrorMessage, getErrorType, getMessage, getRawResponse, getRawResponseContent, getRequestId, getServiceName, getStatusCode, setErrorMessage, setErrorType, setRawResponse, setRawResponseContent, setRequestId, setServiceName, setStatusCode
-
Methods inherited from class com.amazonaws.AmazonClientException
isRetryable
-
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
-
-
-
Constructor Detail
-
InvalidCrossAccountRoleException
public InvalidCrossAccountRoleException(String message)
Constructs a new InvalidCrossAccountRoleException with the specified error message.- Parameters:
message
- Describes the error encountered.
-
-
Method Detail
-
setErrorCode
public void setErrorCode(String errorCode)
Code that indicates the type of error that is generated.
- Overrides:
setErrorCode
in classAmazonServiceException
- Parameters:
errorCode
- Code that indicates the type of error that is generated.- See Also:
InvalidCrossAccountRoleErrorCode
-
getErrorCode
public String getErrorCode()
Code that indicates the type of error that is generated.
- Overrides:
getErrorCode
in classAmazonServiceException
- Returns:
- Code that indicates the type of error that is generated.
- See Also:
InvalidCrossAccountRoleErrorCode
-
withErrorCode
public InvalidCrossAccountRoleException withErrorCode(String errorCode)
Code that indicates the type of error that is generated.
- Parameters:
errorCode
- Code that indicates the type of error that is generated.- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
InvalidCrossAccountRoleErrorCode
-
setErrorCode
public void setErrorCode(InvalidCrossAccountRoleErrorCode errorCode)
Code that indicates the type of error that is generated.
- Parameters:
errorCode
- Code that indicates the type of error that is generated.- See Also:
InvalidCrossAccountRoleErrorCode
-
withErrorCode
public InvalidCrossAccountRoleException withErrorCode(InvalidCrossAccountRoleErrorCode errorCode)
Code that indicates the type of error that is generated.
- Parameters:
errorCode
- Code that indicates the type of error that is generated.- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
InvalidCrossAccountRoleErrorCode
-
setCanRetry
public void setCanRetry(Boolean canRetry)
You can immediately retry your request.
- Parameters:
canRetry
- You can immediately retry your request.
-
getCanRetry
public Boolean getCanRetry()
You can immediately retry your request.
- Returns:
- You can immediately retry your request.
-
withCanRetry
public InvalidCrossAccountRoleException withCanRetry(Boolean canRetry)
You can immediately retry your request.
- Parameters:
canRetry
- You can immediately retry your request.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
isCanRetry
public Boolean isCanRetry()
You can immediately retry your request.
- Returns:
- You can immediately retry your request.
-
-