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

The SIP rule details, including name, triggers, and target applications. An * AWS account can have multiple SIP rules.

See Also:

AWS API * Reference

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

The SIP rule ID.

*/ inline const Aws::String& GetSipRuleId() const{ return m_sipRuleId; } /** *

The SIP rule ID.

*/ inline bool SipRuleIdHasBeenSet() const { return m_sipRuleIdHasBeenSet; } /** *

The SIP rule ID.

*/ inline void SetSipRuleId(const Aws::String& value) { m_sipRuleIdHasBeenSet = true; m_sipRuleId = value; } /** *

The SIP rule ID.

*/ inline void SetSipRuleId(Aws::String&& value) { m_sipRuleIdHasBeenSet = true; m_sipRuleId = std::move(value); } /** *

The SIP rule ID.

*/ inline void SetSipRuleId(const char* value) { m_sipRuleIdHasBeenSet = true; m_sipRuleId.assign(value); } /** *

The SIP rule ID.

*/ inline SipRule& WithSipRuleId(const Aws::String& value) { SetSipRuleId(value); return *this;} /** *

The SIP rule ID.

*/ inline SipRule& WithSipRuleId(Aws::String&& value) { SetSipRuleId(std::move(value)); return *this;} /** *

The SIP rule ID.

*/ inline SipRule& WithSipRuleId(const char* value) { SetSipRuleId(value); return *this;} /** *

The name of the SIP rule.

*/ inline const Aws::String& GetName() const{ return m_name; } /** *

The name of the SIP rule.

*/ inline bool NameHasBeenSet() const { return m_nameHasBeenSet; } /** *

The name of the SIP rule.

*/ inline void SetName(const Aws::String& value) { m_nameHasBeenSet = true; m_name = value; } /** *

The name of the SIP rule.

*/ inline void SetName(Aws::String&& value) { m_nameHasBeenSet = true; m_name = std::move(value); } /** *

The name of the SIP rule.

*/ inline void SetName(const char* value) { m_nameHasBeenSet = true; m_name.assign(value); } /** *

The name of the SIP rule.

*/ inline SipRule& WithName(const Aws::String& value) { SetName(value); return *this;} /** *

The name of the SIP rule.

*/ inline SipRule& WithName(Aws::String&& value) { SetName(std::move(value)); return *this;} /** *

The name of the SIP rule.

*/ inline SipRule& WithName(const char* value) { SetName(value); return *this;} /** *

Indicates whether the SIP rule is enabled or disabled. You must disable a * rule before you can delete it.

*/ inline bool GetDisabled() const{ return m_disabled; } /** *

Indicates whether the SIP rule is enabled or disabled. You must disable a * rule before you can delete it.

*/ inline bool DisabledHasBeenSet() const { return m_disabledHasBeenSet; } /** *

Indicates whether the SIP rule is enabled or disabled. You must disable a * rule before you can delete it.

*/ inline void SetDisabled(bool value) { m_disabledHasBeenSet = true; m_disabled = value; } /** *

Indicates whether the SIP rule is enabled or disabled. You must disable a * rule before you can delete it.

*/ inline SipRule& WithDisabled(bool value) { SetDisabled(value); return *this;} /** *

The type of trigger assigned to the SIP rule in TriggerValue, * currently RequestUriHostname or ToPhoneNumber.

*/ inline const SipRuleTriggerType& GetTriggerType() const{ return m_triggerType; } /** *

The type of trigger assigned to the SIP rule in TriggerValue, * currently RequestUriHostname or ToPhoneNumber.

*/ inline bool TriggerTypeHasBeenSet() const { return m_triggerTypeHasBeenSet; } /** *

The type of trigger assigned to the SIP rule in TriggerValue, * currently RequestUriHostname or ToPhoneNumber.

*/ inline void SetTriggerType(const SipRuleTriggerType& value) { m_triggerTypeHasBeenSet = true; m_triggerType = value; } /** *

The type of trigger assigned to the SIP rule in TriggerValue, * currently RequestUriHostname or ToPhoneNumber.

*/ inline void SetTriggerType(SipRuleTriggerType&& value) { m_triggerTypeHasBeenSet = true; m_triggerType = std::move(value); } /** *

The type of trigger assigned to the SIP rule in TriggerValue, * currently RequestUriHostname or ToPhoneNumber.

*/ inline SipRule& WithTriggerType(const SipRuleTriggerType& value) { SetTriggerType(value); return *this;} /** *

The type of trigger assigned to the SIP rule in TriggerValue, * currently RequestUriHostname or ToPhoneNumber.

*/ inline SipRule& WithTriggerType(SipRuleTriggerType&& value) { SetTriggerType(std::move(value)); return *this;} /** *

If TriggerType is RequestUriHostname, then the * value can be the outbound host name of the Amazon Chime Voice Connector. If * TriggerType is ToPhoneNumber, then the value can be a * customer-owned phone number in E164 format. SipRule is triggered * when a SIP rule requests host name or ToPhoneNumber matches in the * incoming SIP request.

*/ inline const Aws::String& GetTriggerValue() const{ return m_triggerValue; } /** *

If TriggerType is RequestUriHostname, then the * value can be the outbound host name of the Amazon Chime Voice Connector. If * TriggerType is ToPhoneNumber, then the value can be a * customer-owned phone number in E164 format. SipRule is triggered * when a SIP rule requests host name or ToPhoneNumber matches in the * incoming SIP request.

*/ inline bool TriggerValueHasBeenSet() const { return m_triggerValueHasBeenSet; } /** *

If TriggerType is RequestUriHostname, then the * value can be the outbound host name of the Amazon Chime Voice Connector. If * TriggerType is ToPhoneNumber, then the value can be a * customer-owned phone number in E164 format. SipRule is triggered * when a SIP rule requests host name or ToPhoneNumber matches in the * incoming SIP request.

*/ inline void SetTriggerValue(const Aws::String& value) { m_triggerValueHasBeenSet = true; m_triggerValue = value; } /** *

If TriggerType is RequestUriHostname, then the * value can be the outbound host name of the Amazon Chime Voice Connector. If * TriggerType is ToPhoneNumber, then the value can be a * customer-owned phone number in E164 format. SipRule is triggered * when a SIP rule requests host name or ToPhoneNumber matches in the * incoming SIP request.

*/ inline void SetTriggerValue(Aws::String&& value) { m_triggerValueHasBeenSet = true; m_triggerValue = std::move(value); } /** *

If TriggerType is RequestUriHostname, then the * value can be the outbound host name of the Amazon Chime Voice Connector. If * TriggerType is ToPhoneNumber, then the value can be a * customer-owned phone number in E164 format. SipRule is triggered * when a SIP rule requests host name or ToPhoneNumber matches in the * incoming SIP request.

*/ inline void SetTriggerValue(const char* value) { m_triggerValueHasBeenSet = true; m_triggerValue.assign(value); } /** *

If TriggerType is RequestUriHostname, then the * value can be the outbound host name of the Amazon Chime Voice Connector. If * TriggerType is ToPhoneNumber, then the value can be a * customer-owned phone number in E164 format. SipRule is triggered * when a SIP rule requests host name or ToPhoneNumber matches in the * incoming SIP request.

*/ inline SipRule& WithTriggerValue(const Aws::String& value) { SetTriggerValue(value); return *this;} /** *

If TriggerType is RequestUriHostname, then the * value can be the outbound host name of the Amazon Chime Voice Connector. If * TriggerType is ToPhoneNumber, then the value can be a * customer-owned phone number in E164 format. SipRule is triggered * when a SIP rule requests host name or ToPhoneNumber matches in the * incoming SIP request.

*/ inline SipRule& WithTriggerValue(Aws::String&& value) { SetTriggerValue(std::move(value)); return *this;} /** *

If TriggerType is RequestUriHostname, then the * value can be the outbound host name of the Amazon Chime Voice Connector. If * TriggerType is ToPhoneNumber, then the value can be a * customer-owned phone number in E164 format. SipRule is triggered * when a SIP rule requests host name or ToPhoneNumber matches in the * incoming SIP request.

*/ inline SipRule& WithTriggerValue(const char* value) { SetTriggerValue(value); return *this;} /** *

Target SIP media application and other details, such as priority and AWS * Region, to be specified in the SIP rule. Only one SIP rule per AWS Region can be * provided.

*/ inline const Aws::Vector& GetTargetApplications() const{ return m_targetApplications; } /** *

Target SIP media application and other details, such as priority and AWS * Region, to be specified in the SIP rule. Only one SIP rule per AWS Region can be * provided.

*/ inline bool TargetApplicationsHasBeenSet() const { return m_targetApplicationsHasBeenSet; } /** *

Target SIP media application and other details, such as priority and AWS * Region, to be specified in the SIP rule. Only one SIP rule per AWS Region can be * provided.

*/ inline void SetTargetApplications(const Aws::Vector& value) { m_targetApplicationsHasBeenSet = true; m_targetApplications = value; } /** *

Target SIP media application and other details, such as priority and AWS * Region, to be specified in the SIP rule. Only one SIP rule per AWS Region can be * provided.

*/ inline void SetTargetApplications(Aws::Vector&& value) { m_targetApplicationsHasBeenSet = true; m_targetApplications = std::move(value); } /** *

Target SIP media application and other details, such as priority and AWS * Region, to be specified in the SIP rule. Only one SIP rule per AWS Region can be * provided.

*/ inline SipRule& WithTargetApplications(const Aws::Vector& value) { SetTargetApplications(value); return *this;} /** *

Target SIP media application and other details, such as priority and AWS * Region, to be specified in the SIP rule. Only one SIP rule per AWS Region can be * provided.

*/ inline SipRule& WithTargetApplications(Aws::Vector&& value) { SetTargetApplications(std::move(value)); return *this;} /** *

Target SIP media application and other details, such as priority and AWS * Region, to be specified in the SIP rule. Only one SIP rule per AWS Region can be * provided.

*/ inline SipRule& AddTargetApplications(const SipRuleTargetApplication& value) { m_targetApplicationsHasBeenSet = true; m_targetApplications.push_back(value); return *this; } /** *

Target SIP media application and other details, such as priority and AWS * Region, to be specified in the SIP rule. Only one SIP rule per AWS Region can be * provided.

*/ inline SipRule& AddTargetApplications(SipRuleTargetApplication&& value) { m_targetApplicationsHasBeenSet = true; m_targetApplications.push_back(std::move(value)); return *this; } /** *

The time at which the SIP rule was created, in ISO 8601 format.

*/ inline const Aws::Utils::DateTime& GetCreatedTimestamp() const{ return m_createdTimestamp; } /** *

The time at which the SIP rule was created, in ISO 8601 format.

*/ inline bool CreatedTimestampHasBeenSet() const { return m_createdTimestampHasBeenSet; } /** *

The time at which the SIP rule was created, in ISO 8601 format.

*/ inline void SetCreatedTimestamp(const Aws::Utils::DateTime& value) { m_createdTimestampHasBeenSet = true; m_createdTimestamp = value; } /** *

The time at which the SIP rule was created, in ISO 8601 format.

*/ inline void SetCreatedTimestamp(Aws::Utils::DateTime&& value) { m_createdTimestampHasBeenSet = true; m_createdTimestamp = std::move(value); } /** *

The time at which the SIP rule was created, in ISO 8601 format.

*/ inline SipRule& WithCreatedTimestamp(const Aws::Utils::DateTime& value) { SetCreatedTimestamp(value); return *this;} /** *

The time at which the SIP rule was created, in ISO 8601 format.

*/ inline SipRule& WithCreatedTimestamp(Aws::Utils::DateTime&& value) { SetCreatedTimestamp(std::move(value)); return *this;} /** *

The time at which the SIP rule was last updated, in ISO 8601 format.

*/ inline const Aws::Utils::DateTime& GetUpdatedTimestamp() const{ return m_updatedTimestamp; } /** *

The time at which the SIP rule was last updated, in ISO 8601 format.

*/ inline bool UpdatedTimestampHasBeenSet() const { return m_updatedTimestampHasBeenSet; } /** *

The time at which the SIP rule was last updated, in ISO 8601 format.

*/ inline void SetUpdatedTimestamp(const Aws::Utils::DateTime& value) { m_updatedTimestampHasBeenSet = true; m_updatedTimestamp = value; } /** *

The time at which the SIP rule was last updated, in ISO 8601 format.

*/ inline void SetUpdatedTimestamp(Aws::Utils::DateTime&& value) { m_updatedTimestampHasBeenSet = true; m_updatedTimestamp = std::move(value); } /** *

The time at which the SIP rule was last updated, in ISO 8601 format.

*/ inline SipRule& WithUpdatedTimestamp(const Aws::Utils::DateTime& value) { SetUpdatedTimestamp(value); return *this;} /** *

The time at which the SIP rule was last updated, in ISO 8601 format.

*/ inline SipRule& WithUpdatedTimestamp(Aws::Utils::DateTime&& value) { SetUpdatedTimestamp(std::move(value)); return *this;} private: Aws::String m_sipRuleId; bool m_sipRuleIdHasBeenSet = false; Aws::String m_name; bool m_nameHasBeenSet = false; bool m_disabled; bool m_disabledHasBeenSet = false; SipRuleTriggerType m_triggerType; bool m_triggerTypeHasBeenSet = false; Aws::String m_triggerValue; bool m_triggerValueHasBeenSet = false; Aws::Vector m_targetApplications; bool m_targetApplicationsHasBeenSet = false; Aws::Utils::DateTime m_createdTimestamp; bool m_createdTimestampHasBeenSet = false; Aws::Utils::DateTime m_updatedTimestamp; bool m_updatedTimestampHasBeenSet = false; }; } // namespace Model } // namespace Chime } // namespace Aws