/** * 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 #include namespace Aws { namespace Utils { namespace Json { class JsonValue; class JsonView; } // namespace Json } // namespace Utils namespace IoT { namespace Model { /** *

Information about an active Device Defender security profile behavior * violation.

See Also:

AWS * API Reference

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

The ID of the active violation.

*/ inline const Aws::String& GetViolationId() const{ return m_violationId; } /** *

The ID of the active violation.

*/ inline bool ViolationIdHasBeenSet() const { return m_violationIdHasBeenSet; } /** *

The ID of the active violation.

*/ inline void SetViolationId(const Aws::String& value) { m_violationIdHasBeenSet = true; m_violationId = value; } /** *

The ID of the active violation.

*/ inline void SetViolationId(Aws::String&& value) { m_violationIdHasBeenSet = true; m_violationId = std::move(value); } /** *

The ID of the active violation.

*/ inline void SetViolationId(const char* value) { m_violationIdHasBeenSet = true; m_violationId.assign(value); } /** *

The ID of the active violation.

*/ inline ActiveViolation& WithViolationId(const Aws::String& value) { SetViolationId(value); return *this;} /** *

The ID of the active violation.

*/ inline ActiveViolation& WithViolationId(Aws::String&& value) { SetViolationId(std::move(value)); return *this;} /** *

The ID of the active violation.

*/ inline ActiveViolation& WithViolationId(const char* value) { SetViolationId(value); return *this;} /** *

The name of the thing responsible for the active violation.

*/ inline const Aws::String& GetThingName() const{ return m_thingName; } /** *

The name of the thing responsible for the active violation.

*/ inline bool ThingNameHasBeenSet() const { return m_thingNameHasBeenSet; } /** *

The name of the thing responsible for the active violation.

*/ inline void SetThingName(const Aws::String& value) { m_thingNameHasBeenSet = true; m_thingName = value; } /** *

The name of the thing responsible for the active violation.

*/ inline void SetThingName(Aws::String&& value) { m_thingNameHasBeenSet = true; m_thingName = std::move(value); } /** *

The name of the thing responsible for the active violation.

*/ inline void SetThingName(const char* value) { m_thingNameHasBeenSet = true; m_thingName.assign(value); } /** *

The name of the thing responsible for the active violation.

*/ inline ActiveViolation& WithThingName(const Aws::String& value) { SetThingName(value); return *this;} /** *

The name of the thing responsible for the active violation.

*/ inline ActiveViolation& WithThingName(Aws::String&& value) { SetThingName(std::move(value)); return *this;} /** *

The name of the thing responsible for the active violation.

*/ inline ActiveViolation& WithThingName(const char* value) { SetThingName(value); return *this;} /** *

The security profile with the behavior is in violation.

*/ inline const Aws::String& GetSecurityProfileName() const{ return m_securityProfileName; } /** *

The security profile with the behavior is in violation.

*/ inline bool SecurityProfileNameHasBeenSet() const { return m_securityProfileNameHasBeenSet; } /** *

The security profile with the behavior is in violation.

*/ inline void SetSecurityProfileName(const Aws::String& value) { m_securityProfileNameHasBeenSet = true; m_securityProfileName = value; } /** *

The security profile with the behavior is in violation.

*/ inline void SetSecurityProfileName(Aws::String&& value) { m_securityProfileNameHasBeenSet = true; m_securityProfileName = std::move(value); } /** *

The security profile with the behavior is in violation.

*/ inline void SetSecurityProfileName(const char* value) { m_securityProfileNameHasBeenSet = true; m_securityProfileName.assign(value); } /** *

The security profile with the behavior is in violation.

*/ inline ActiveViolation& WithSecurityProfileName(const Aws::String& value) { SetSecurityProfileName(value); return *this;} /** *

The security profile with the behavior is in violation.

*/ inline ActiveViolation& WithSecurityProfileName(Aws::String&& value) { SetSecurityProfileName(std::move(value)); return *this;} /** *

The security profile with the behavior is in violation.

*/ inline ActiveViolation& WithSecurityProfileName(const char* value) { SetSecurityProfileName(value); return *this;} /** *

The behavior that is being violated.

*/ inline const Behavior& GetBehavior() const{ return m_behavior; } /** *

The behavior that is being violated.

*/ inline bool BehaviorHasBeenSet() const { return m_behaviorHasBeenSet; } /** *

The behavior that is being violated.

*/ inline void SetBehavior(const Behavior& value) { m_behaviorHasBeenSet = true; m_behavior = value; } /** *

The behavior that is being violated.

*/ inline void SetBehavior(Behavior&& value) { m_behaviorHasBeenSet = true; m_behavior = std::move(value); } /** *

The behavior that is being violated.

*/ inline ActiveViolation& WithBehavior(const Behavior& value) { SetBehavior(value); return *this;} /** *

The behavior that is being violated.

*/ inline ActiveViolation& WithBehavior(Behavior&& value) { SetBehavior(std::move(value)); return *this;} /** *

The value of the metric (the measurement) that caused the most recent * violation.

*/ inline const MetricValue& GetLastViolationValue() const{ return m_lastViolationValue; } /** *

The value of the metric (the measurement) that caused the most recent * violation.

*/ inline bool LastViolationValueHasBeenSet() const { return m_lastViolationValueHasBeenSet; } /** *

The value of the metric (the measurement) that caused the most recent * violation.

*/ inline void SetLastViolationValue(const MetricValue& value) { m_lastViolationValueHasBeenSet = true; m_lastViolationValue = value; } /** *

The value of the metric (the measurement) that caused the most recent * violation.

*/ inline void SetLastViolationValue(MetricValue&& value) { m_lastViolationValueHasBeenSet = true; m_lastViolationValue = std::move(value); } /** *

The value of the metric (the measurement) that caused the most recent * violation.

*/ inline ActiveViolation& WithLastViolationValue(const MetricValue& value) { SetLastViolationValue(value); return *this;} /** *

The value of the metric (the measurement) that caused the most recent * violation.

*/ inline ActiveViolation& WithLastViolationValue(MetricValue&& value) { SetLastViolationValue(std::move(value)); return *this;} /** *

The details of a violation event.

*/ inline const ViolationEventAdditionalInfo& GetViolationEventAdditionalInfo() const{ return m_violationEventAdditionalInfo; } /** *

The details of a violation event.

*/ inline bool ViolationEventAdditionalInfoHasBeenSet() const { return m_violationEventAdditionalInfoHasBeenSet; } /** *

The details of a violation event.

*/ inline void SetViolationEventAdditionalInfo(const ViolationEventAdditionalInfo& value) { m_violationEventAdditionalInfoHasBeenSet = true; m_violationEventAdditionalInfo = value; } /** *

The details of a violation event.

*/ inline void SetViolationEventAdditionalInfo(ViolationEventAdditionalInfo&& value) { m_violationEventAdditionalInfoHasBeenSet = true; m_violationEventAdditionalInfo = std::move(value); } /** *

The details of a violation event.

*/ inline ActiveViolation& WithViolationEventAdditionalInfo(const ViolationEventAdditionalInfo& value) { SetViolationEventAdditionalInfo(value); return *this;} /** *

The details of a violation event.

*/ inline ActiveViolation& WithViolationEventAdditionalInfo(ViolationEventAdditionalInfo&& value) { SetViolationEventAdditionalInfo(std::move(value)); return *this;} /** *

The verification state of the violation (detect alarm).

*/ inline const VerificationState& GetVerificationState() const{ return m_verificationState; } /** *

The verification state of the violation (detect alarm).

*/ inline bool VerificationStateHasBeenSet() const { return m_verificationStateHasBeenSet; } /** *

The verification state of the violation (detect alarm).

*/ inline void SetVerificationState(const VerificationState& value) { m_verificationStateHasBeenSet = true; m_verificationState = value; } /** *

The verification state of the violation (detect alarm).

*/ inline void SetVerificationState(VerificationState&& value) { m_verificationStateHasBeenSet = true; m_verificationState = std::move(value); } /** *

The verification state of the violation (detect alarm).

*/ inline ActiveViolation& WithVerificationState(const VerificationState& value) { SetVerificationState(value); return *this;} /** *

The verification state of the violation (detect alarm).

*/ inline ActiveViolation& WithVerificationState(VerificationState&& value) { SetVerificationState(std::move(value)); return *this;} /** *

The description of the verification state of the violation.

*/ inline const Aws::String& GetVerificationStateDescription() const{ return m_verificationStateDescription; } /** *

The description of the verification state of the violation.

*/ inline bool VerificationStateDescriptionHasBeenSet() const { return m_verificationStateDescriptionHasBeenSet; } /** *

The description of the verification state of the violation.

*/ inline void SetVerificationStateDescription(const Aws::String& value) { m_verificationStateDescriptionHasBeenSet = true; m_verificationStateDescription = value; } /** *

The description of the verification state of the violation.

*/ inline void SetVerificationStateDescription(Aws::String&& value) { m_verificationStateDescriptionHasBeenSet = true; m_verificationStateDescription = std::move(value); } /** *

The description of the verification state of the violation.

*/ inline void SetVerificationStateDescription(const char* value) { m_verificationStateDescriptionHasBeenSet = true; m_verificationStateDescription.assign(value); } /** *

The description of the verification state of the violation.

*/ inline ActiveViolation& WithVerificationStateDescription(const Aws::String& value) { SetVerificationStateDescription(value); return *this;} /** *

The description of the verification state of the violation.

*/ inline ActiveViolation& WithVerificationStateDescription(Aws::String&& value) { SetVerificationStateDescription(std::move(value)); return *this;} /** *

The description of the verification state of the violation.

*/ inline ActiveViolation& WithVerificationStateDescription(const char* value) { SetVerificationStateDescription(value); return *this;} /** *

The time the most recent violation occurred.

*/ inline const Aws::Utils::DateTime& GetLastViolationTime() const{ return m_lastViolationTime; } /** *

The time the most recent violation occurred.

*/ inline bool LastViolationTimeHasBeenSet() const { return m_lastViolationTimeHasBeenSet; } /** *

The time the most recent violation occurred.

*/ inline void SetLastViolationTime(const Aws::Utils::DateTime& value) { m_lastViolationTimeHasBeenSet = true; m_lastViolationTime = value; } /** *

The time the most recent violation occurred.

*/ inline void SetLastViolationTime(Aws::Utils::DateTime&& value) { m_lastViolationTimeHasBeenSet = true; m_lastViolationTime = std::move(value); } /** *

The time the most recent violation occurred.

*/ inline ActiveViolation& WithLastViolationTime(const Aws::Utils::DateTime& value) { SetLastViolationTime(value); return *this;} /** *

The time the most recent violation occurred.

*/ inline ActiveViolation& WithLastViolationTime(Aws::Utils::DateTime&& value) { SetLastViolationTime(std::move(value)); return *this;} /** *

The time the violation started.

*/ inline const Aws::Utils::DateTime& GetViolationStartTime() const{ return m_violationStartTime; } /** *

The time the violation started.

*/ inline bool ViolationStartTimeHasBeenSet() const { return m_violationStartTimeHasBeenSet; } /** *

The time the violation started.

*/ inline void SetViolationStartTime(const Aws::Utils::DateTime& value) { m_violationStartTimeHasBeenSet = true; m_violationStartTime = value; } /** *

The time the violation started.

*/ inline void SetViolationStartTime(Aws::Utils::DateTime&& value) { m_violationStartTimeHasBeenSet = true; m_violationStartTime = std::move(value); } /** *

The time the violation started.

*/ inline ActiveViolation& WithViolationStartTime(const Aws::Utils::DateTime& value) { SetViolationStartTime(value); return *this;} /** *

The time the violation started.

*/ inline ActiveViolation& WithViolationStartTime(Aws::Utils::DateTime&& value) { SetViolationStartTime(std::move(value)); return *this;} private: Aws::String m_violationId; bool m_violationIdHasBeenSet = false; Aws::String m_thingName; bool m_thingNameHasBeenSet = false; Aws::String m_securityProfileName; bool m_securityProfileNameHasBeenSet = false; Behavior m_behavior; bool m_behaviorHasBeenSet = false; MetricValue m_lastViolationValue; bool m_lastViolationValueHasBeenSet = false; ViolationEventAdditionalInfo m_violationEventAdditionalInfo; bool m_violationEventAdditionalInfoHasBeenSet = false; VerificationState m_verificationState; bool m_verificationStateHasBeenSet = false; Aws::String m_verificationStateDescription; bool m_verificationStateDescriptionHasBeenSet = false; Aws::Utils::DateTime m_lastViolationTime; bool m_lastViolationTimeHasBeenSet = false; Aws::Utils::DateTime m_violationStartTime; bool m_violationStartTimeHasBeenSet = false; }; } // namespace Model } // namespace IoT } // namespace Aws