protected static BaseHandlerException handleException()

in aws-ssmincidents-responseplan/src/main/java/software/amazon/ssmincidents/responseplan/Translator.java [125:140]


    protected static BaseHandlerException handleException(Exception e) {
        if (e instanceof ResourceNotFoundException) {
            return new CfnNotFoundException(e);
        } else if (e instanceof AccessDeniedException) {
            return new CfnAccessDeniedException(e);
        } else if (e instanceof ValidationException) {
            return new CfnInvalidRequestException(e);
        } else if (e instanceof ThrottlingException) {
            return new CfnThrottlingException(e);
        } else if (e instanceof ConflictException) {
            return new CfnAlreadyExistsException(e);
        } else if (e instanceof AwsServiceException) {
            return new CfnGeneralServiceException(ResourceModel.TYPE_NAME, e);
        }
        return new CfnGeneralServiceException(ResourceModel.TYPE_NAME, e);
    }