/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include namespace Aws { namespace Utils { namespace Json { class JsonValue; class JsonView; } // namespace Json } // namespace Utils namespace LocationService { namespace Model { /** *

An error corresponding to the calculation of a route between the * DeparturePosition and DestinationPosition.

The * error code can be one of the following:

  • * RouteNotFound - Unable to find a valid route with the given * parameters.

  • RouteTooLong - Route * calculation went beyond the maximum size of a route and was terminated before * completion.

  • PositionsNotFound - One * or more of the input positions were not found on the route network.

  • *
  • DestinationPositionNotFound - The destination * position was not found on the route network.

  • * DeparturePositionNotFound - The departure position was not found on * the route network.

  • * OtherValidationError - The given inputs were not valid or a route * was not found. More information is given in the error Message

    *

See Also:

AWS * API Reference

*/ class RouteMatrixEntryError { public: AWS_LOCATIONSERVICE_API RouteMatrixEntryError(); AWS_LOCATIONSERVICE_API RouteMatrixEntryError(Aws::Utils::Json::JsonView jsonValue); AWS_LOCATIONSERVICE_API RouteMatrixEntryError& operator=(Aws::Utils::Json::JsonView jsonValue); AWS_LOCATIONSERVICE_API Aws::Utils::Json::JsonValue Jsonize() const; /** *

The type of error which occurred for the route calculation.

*/ inline const RouteMatrixErrorCode& GetCode() const{ return m_code; } /** *

The type of error which occurred for the route calculation.

*/ inline bool CodeHasBeenSet() const { return m_codeHasBeenSet; } /** *

The type of error which occurred for the route calculation.

*/ inline void SetCode(const RouteMatrixErrorCode& value) { m_codeHasBeenSet = true; m_code = value; } /** *

The type of error which occurred for the route calculation.

*/ inline void SetCode(RouteMatrixErrorCode&& value) { m_codeHasBeenSet = true; m_code = std::move(value); } /** *

The type of error which occurred for the route calculation.

*/ inline RouteMatrixEntryError& WithCode(const RouteMatrixErrorCode& value) { SetCode(value); return *this;} /** *

The type of error which occurred for the route calculation.

*/ inline RouteMatrixEntryError& WithCode(RouteMatrixErrorCode&& value) { SetCode(std::move(value)); return *this;} /** *

A message about the error that occurred for the route calculation.

*/ inline const Aws::String& GetMessage() const{ return m_message; } /** *

A message about the error that occurred for the route calculation.

*/ inline bool MessageHasBeenSet() const { return m_messageHasBeenSet; } /** *

A message about the error that occurred for the route calculation.

*/ inline void SetMessage(const Aws::String& value) { m_messageHasBeenSet = true; m_message = value; } /** *

A message about the error that occurred for the route calculation.

*/ inline void SetMessage(Aws::String&& value) { m_messageHasBeenSet = true; m_message = std::move(value); } /** *

A message about the error that occurred for the route calculation.

*/ inline void SetMessage(const char* value) { m_messageHasBeenSet = true; m_message.assign(value); } /** *

A message about the error that occurred for the route calculation.

*/ inline RouteMatrixEntryError& WithMessage(const Aws::String& value) { SetMessage(value); return *this;} /** *

A message about the error that occurred for the route calculation.

*/ inline RouteMatrixEntryError& WithMessage(Aws::String&& value) { SetMessage(std::move(value)); return *this;} /** *

A message about the error that occurred for the route calculation.

*/ inline RouteMatrixEntryError& WithMessage(const char* value) { SetMessage(value); return *this;} private: RouteMatrixErrorCode m_code; bool m_codeHasBeenSet = false; Aws::String m_message; bool m_messageHasBeenSet = false; }; } // namespace Model } // namespace LocationService } // namespace Aws