/** * 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 CloudWatchEvidently { namespace Model { /** *

A structure that contains the configuration of which variation to use as the * "control" version. The "control" version is used for comparison with other * variations. This structure also specifies how much experiment traffic is * allocated to each variation.

See Also:

AWS * API Reference

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

The name of the variation that is to be the default variation that the other * variations are compared to.

*/ inline const Aws::String& GetControlTreatmentName() const{ return m_controlTreatmentName; } /** *

The name of the variation that is to be the default variation that the other * variations are compared to.

*/ inline bool ControlTreatmentNameHasBeenSet() const { return m_controlTreatmentNameHasBeenSet; } /** *

The name of the variation that is to be the default variation that the other * variations are compared to.

*/ inline void SetControlTreatmentName(const Aws::String& value) { m_controlTreatmentNameHasBeenSet = true; m_controlTreatmentName = value; } /** *

The name of the variation that is to be the default variation that the other * variations are compared to.

*/ inline void SetControlTreatmentName(Aws::String&& value) { m_controlTreatmentNameHasBeenSet = true; m_controlTreatmentName = std::move(value); } /** *

The name of the variation that is to be the default variation that the other * variations are compared to.

*/ inline void SetControlTreatmentName(const char* value) { m_controlTreatmentNameHasBeenSet = true; m_controlTreatmentName.assign(value); } /** *

The name of the variation that is to be the default variation that the other * variations are compared to.

*/ inline OnlineAbConfig& WithControlTreatmentName(const Aws::String& value) { SetControlTreatmentName(value); return *this;} /** *

The name of the variation that is to be the default variation that the other * variations are compared to.

*/ inline OnlineAbConfig& WithControlTreatmentName(Aws::String&& value) { SetControlTreatmentName(std::move(value)); return *this;} /** *

The name of the variation that is to be the default variation that the other * variations are compared to.

*/ inline OnlineAbConfig& WithControlTreatmentName(const char* value) { SetControlTreatmentName(value); return *this;} /** *

A set of key-value pairs. The keys are variation names, and the values are * the portion of experiment traffic to be assigned to that variation. Specify the * traffic portion in thousandths of a percent, so 20,000 for a variation would * allocate 20% of the experiment traffic to that variation.

*/ inline const Aws::Map& GetTreatmentWeights() const{ return m_treatmentWeights; } /** *

A set of key-value pairs. The keys are variation names, and the values are * the portion of experiment traffic to be assigned to that variation. Specify the * traffic portion in thousandths of a percent, so 20,000 for a variation would * allocate 20% of the experiment traffic to that variation.

*/ inline bool TreatmentWeightsHasBeenSet() const { return m_treatmentWeightsHasBeenSet; } /** *

A set of key-value pairs. The keys are variation names, and the values are * the portion of experiment traffic to be assigned to that variation. Specify the * traffic portion in thousandths of a percent, so 20,000 for a variation would * allocate 20% of the experiment traffic to that variation.

*/ inline void SetTreatmentWeights(const Aws::Map& value) { m_treatmentWeightsHasBeenSet = true; m_treatmentWeights = value; } /** *

A set of key-value pairs. The keys are variation names, and the values are * the portion of experiment traffic to be assigned to that variation. Specify the * traffic portion in thousandths of a percent, so 20,000 for a variation would * allocate 20% of the experiment traffic to that variation.

*/ inline void SetTreatmentWeights(Aws::Map&& value) { m_treatmentWeightsHasBeenSet = true; m_treatmentWeights = std::move(value); } /** *

A set of key-value pairs. The keys are variation names, and the values are * the portion of experiment traffic to be assigned to that variation. Specify the * traffic portion in thousandths of a percent, so 20,000 for a variation would * allocate 20% of the experiment traffic to that variation.

*/ inline OnlineAbConfig& WithTreatmentWeights(const Aws::Map& value) { SetTreatmentWeights(value); return *this;} /** *

A set of key-value pairs. The keys are variation names, and the values are * the portion of experiment traffic to be assigned to that variation. Specify the * traffic portion in thousandths of a percent, so 20,000 for a variation would * allocate 20% of the experiment traffic to that variation.

*/ inline OnlineAbConfig& WithTreatmentWeights(Aws::Map&& value) { SetTreatmentWeights(std::move(value)); return *this;} /** *

A set of key-value pairs. The keys are variation names, and the values are * the portion of experiment traffic to be assigned to that variation. Specify the * traffic portion in thousandths of a percent, so 20,000 for a variation would * allocate 20% of the experiment traffic to that variation.

*/ inline OnlineAbConfig& AddTreatmentWeights(const Aws::String& key, long long value) { m_treatmentWeightsHasBeenSet = true; m_treatmentWeights.emplace(key, value); return *this; } /** *

A set of key-value pairs. The keys are variation names, and the values are * the portion of experiment traffic to be assigned to that variation. Specify the * traffic portion in thousandths of a percent, so 20,000 for a variation would * allocate 20% of the experiment traffic to that variation.

*/ inline OnlineAbConfig& AddTreatmentWeights(Aws::String&& key, long long value) { m_treatmentWeightsHasBeenSet = true; m_treatmentWeights.emplace(std::move(key), value); return *this; } /** *

A set of key-value pairs. The keys are variation names, and the values are * the portion of experiment traffic to be assigned to that variation. Specify the * traffic portion in thousandths of a percent, so 20,000 for a variation would * allocate 20% of the experiment traffic to that variation.

*/ inline OnlineAbConfig& AddTreatmentWeights(const char* key, long long value) { m_treatmentWeightsHasBeenSet = true; m_treatmentWeights.emplace(key, value); return *this; } private: Aws::String m_controlTreatmentName; bool m_controlTreatmentNameHasBeenSet = false; Aws::Map m_treatmentWeights; bool m_treatmentWeightsHasBeenSet = false; }; } // namespace Model } // namespace CloudWatchEvidently } // namespace Aws