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

The charge details of a custom line item. It should contain only one of * Flat or Percentage.

See Also:

AWS * API Reference

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

A CustomLineItemFlatChargeDetails that describes the charge * details of a flat custom line item.

*/ inline const CustomLineItemFlatChargeDetails& GetFlat() const{ return m_flat; } /** *

A CustomLineItemFlatChargeDetails that describes the charge * details of a flat custom line item.

*/ inline bool FlatHasBeenSet() const { return m_flatHasBeenSet; } /** *

A CustomLineItemFlatChargeDetails that describes the charge * details of a flat custom line item.

*/ inline void SetFlat(const CustomLineItemFlatChargeDetails& value) { m_flatHasBeenSet = true; m_flat = value; } /** *

A CustomLineItemFlatChargeDetails that describes the charge * details of a flat custom line item.

*/ inline void SetFlat(CustomLineItemFlatChargeDetails&& value) { m_flatHasBeenSet = true; m_flat = std::move(value); } /** *

A CustomLineItemFlatChargeDetails that describes the charge * details of a flat custom line item.

*/ inline CustomLineItemChargeDetails& WithFlat(const CustomLineItemFlatChargeDetails& value) { SetFlat(value); return *this;} /** *

A CustomLineItemFlatChargeDetails that describes the charge * details of a flat custom line item.

*/ inline CustomLineItemChargeDetails& WithFlat(CustomLineItemFlatChargeDetails&& value) { SetFlat(std::move(value)); return *this;} /** *

A CustomLineItemPercentageChargeDetails that describes the * charge details of a percentage custom line item.

*/ inline const CustomLineItemPercentageChargeDetails& GetPercentage() const{ return m_percentage; } /** *

A CustomLineItemPercentageChargeDetails that describes the * charge details of a percentage custom line item.

*/ inline bool PercentageHasBeenSet() const { return m_percentageHasBeenSet; } /** *

A CustomLineItemPercentageChargeDetails that describes the * charge details of a percentage custom line item.

*/ inline void SetPercentage(const CustomLineItemPercentageChargeDetails& value) { m_percentageHasBeenSet = true; m_percentage = value; } /** *

A CustomLineItemPercentageChargeDetails that describes the * charge details of a percentage custom line item.

*/ inline void SetPercentage(CustomLineItemPercentageChargeDetails&& value) { m_percentageHasBeenSet = true; m_percentage = std::move(value); } /** *

A CustomLineItemPercentageChargeDetails that describes the * charge details of a percentage custom line item.

*/ inline CustomLineItemChargeDetails& WithPercentage(const CustomLineItemPercentageChargeDetails& value) { SetPercentage(value); return *this;} /** *

A CustomLineItemPercentageChargeDetails that describes the * charge details of a percentage custom line item.

*/ inline CustomLineItemChargeDetails& WithPercentage(CustomLineItemPercentageChargeDetails&& value) { SetPercentage(std::move(value)); return *this;} /** *

The type of the custom line item that indicates whether the charge is a fee * or credit.

*/ inline const CustomLineItemType& GetType() const{ return m_type; } /** *

The type of the custom line item that indicates whether the charge is a fee * or credit.

*/ inline bool TypeHasBeenSet() const { return m_typeHasBeenSet; } /** *

The type of the custom line item that indicates whether the charge is a fee * or credit.

*/ inline void SetType(const CustomLineItemType& value) { m_typeHasBeenSet = true; m_type = value; } /** *

The type of the custom line item that indicates whether the charge is a fee * or credit.

*/ inline void SetType(CustomLineItemType&& value) { m_typeHasBeenSet = true; m_type = std::move(value); } /** *

The type of the custom line item that indicates whether the charge is a fee * or credit.

*/ inline CustomLineItemChargeDetails& WithType(const CustomLineItemType& value) { SetType(value); return *this;} /** *

The type of the custom line item that indicates whether the charge is a fee * or credit.

*/ inline CustomLineItemChargeDetails& WithType(CustomLineItemType&& value) { SetType(std::move(value)); return *this;} private: CustomLineItemFlatChargeDetails m_flat; bool m_flatHasBeenSet = false; CustomLineItemPercentageChargeDetails m_percentage; bool m_percentageHasBeenSet = false; CustomLineItemType m_type; bool m_typeHasBeenSet = false; }; } // namespace Model } // namespace BillingConductor } // namespace Aws