/** * 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 Xml { class XmlNode; } // namespace Xml } // namespace Utils namespace IAM { namespace Model { /** *

Contains details about the most recent attempt to access an action within the * service.

This data type is used as a response element in the * GetServiceLastAccessedDetails operation.

See Also:

AWS * API Reference

*/ class TrackedActionLastAccessed { public: AWS_IAM_API TrackedActionLastAccessed(); AWS_IAM_API TrackedActionLastAccessed(const Aws::Utils::Xml::XmlNode& xmlNode); AWS_IAM_API TrackedActionLastAccessed& operator=(const Aws::Utils::Xml::XmlNode& xmlNode); AWS_IAM_API void OutputToStream(Aws::OStream& ostream, const char* location, unsigned index, const char* locationValue) const; AWS_IAM_API void OutputToStream(Aws::OStream& oStream, const char* location) const; /** *

The name of the tracked action to which access was attempted. Tracked actions * are actions that report activity to IAM.

*/ inline const Aws::String& GetActionName() const{ return m_actionName; } /** *

The name of the tracked action to which access was attempted. Tracked actions * are actions that report activity to IAM.

*/ inline bool ActionNameHasBeenSet() const { return m_actionNameHasBeenSet; } /** *

The name of the tracked action to which access was attempted. Tracked actions * are actions that report activity to IAM.

*/ inline void SetActionName(const Aws::String& value) { m_actionNameHasBeenSet = true; m_actionName = value; } /** *

The name of the tracked action to which access was attempted. Tracked actions * are actions that report activity to IAM.

*/ inline void SetActionName(Aws::String&& value) { m_actionNameHasBeenSet = true; m_actionName = std::move(value); } /** *

The name of the tracked action to which access was attempted. Tracked actions * are actions that report activity to IAM.

*/ inline void SetActionName(const char* value) { m_actionNameHasBeenSet = true; m_actionName.assign(value); } /** *

The name of the tracked action to which access was attempted. Tracked actions * are actions that report activity to IAM.

*/ inline TrackedActionLastAccessed& WithActionName(const Aws::String& value) { SetActionName(value); return *this;} /** *

The name of the tracked action to which access was attempted. Tracked actions * are actions that report activity to IAM.

*/ inline TrackedActionLastAccessed& WithActionName(Aws::String&& value) { SetActionName(std::move(value)); return *this;} /** *

The name of the tracked action to which access was attempted. Tracked actions * are actions that report activity to IAM.

*/ inline TrackedActionLastAccessed& WithActionName(const char* value) { SetActionName(value); return *this;} inline const Aws::String& GetLastAccessedEntity() const{ return m_lastAccessedEntity; } inline bool LastAccessedEntityHasBeenSet() const { return m_lastAccessedEntityHasBeenSet; } inline void SetLastAccessedEntity(const Aws::String& value) { m_lastAccessedEntityHasBeenSet = true; m_lastAccessedEntity = value; } inline void SetLastAccessedEntity(Aws::String&& value) { m_lastAccessedEntityHasBeenSet = true; m_lastAccessedEntity = std::move(value); } inline void SetLastAccessedEntity(const char* value) { m_lastAccessedEntityHasBeenSet = true; m_lastAccessedEntity.assign(value); } inline TrackedActionLastAccessed& WithLastAccessedEntity(const Aws::String& value) { SetLastAccessedEntity(value); return *this;} inline TrackedActionLastAccessed& WithLastAccessedEntity(Aws::String&& value) { SetLastAccessedEntity(std::move(value)); return *this;} inline TrackedActionLastAccessed& WithLastAccessedEntity(const char* value) { SetLastAccessedEntity(value); return *this;} /** *

The date and time, in ISO 8601 * date-time format, when an authenticated entity most recently attempted to * access the tracked service. Amazon Web Services does not report unauthenticated * requests.

This field is null if no IAM entities attempted to access the * service within the tracking * period.

*/ inline const Aws::Utils::DateTime& GetLastAccessedTime() const{ return m_lastAccessedTime; } /** *

The date and time, in ISO 8601 * date-time format, when an authenticated entity most recently attempted to * access the tracked service. Amazon Web Services does not report unauthenticated * requests.

This field is null if no IAM entities attempted to access the * service within the tracking * period.

*/ inline bool LastAccessedTimeHasBeenSet() const { return m_lastAccessedTimeHasBeenSet; } /** *

The date and time, in ISO 8601 * date-time format, when an authenticated entity most recently attempted to * access the tracked service. Amazon Web Services does not report unauthenticated * requests.

This field is null if no IAM entities attempted to access the * service within the tracking * period.

*/ inline void SetLastAccessedTime(const Aws::Utils::DateTime& value) { m_lastAccessedTimeHasBeenSet = true; m_lastAccessedTime = value; } /** *

The date and time, in ISO 8601 * date-time format, when an authenticated entity most recently attempted to * access the tracked service. Amazon Web Services does not report unauthenticated * requests.

This field is null if no IAM entities attempted to access the * service within the tracking * period.

*/ inline void SetLastAccessedTime(Aws::Utils::DateTime&& value) { m_lastAccessedTimeHasBeenSet = true; m_lastAccessedTime = std::move(value); } /** *

The date and time, in ISO 8601 * date-time format, when an authenticated entity most recently attempted to * access the tracked service. Amazon Web Services does not report unauthenticated * requests.

This field is null if no IAM entities attempted to access the * service within the tracking * period.

*/ inline TrackedActionLastAccessed& WithLastAccessedTime(const Aws::Utils::DateTime& value) { SetLastAccessedTime(value); return *this;} /** *

The date and time, in ISO 8601 * date-time format, when an authenticated entity most recently attempted to * access the tracked service. Amazon Web Services does not report unauthenticated * requests.

This field is null if no IAM entities attempted to access the * service within the tracking * period.

*/ inline TrackedActionLastAccessed& WithLastAccessedTime(Aws::Utils::DateTime&& value) { SetLastAccessedTime(std::move(value)); return *this;} /** *

The Region from which the authenticated entity (user or role) last attempted * to access the tracked action. Amazon Web Services does not report * unauthenticated requests.

This field is null if no IAM entities attempted * to access the service within the tracking * period.

*/ inline const Aws::String& GetLastAccessedRegion() const{ return m_lastAccessedRegion; } /** *

The Region from which the authenticated entity (user or role) last attempted * to access the tracked action. Amazon Web Services does not report * unauthenticated requests.

This field is null if no IAM entities attempted * to access the service within the tracking * period.

*/ inline bool LastAccessedRegionHasBeenSet() const { return m_lastAccessedRegionHasBeenSet; } /** *

The Region from which the authenticated entity (user or role) last attempted * to access the tracked action. Amazon Web Services does not report * unauthenticated requests.

This field is null if no IAM entities attempted * to access the service within the tracking * period.

*/ inline void SetLastAccessedRegion(const Aws::String& value) { m_lastAccessedRegionHasBeenSet = true; m_lastAccessedRegion = value; } /** *

The Region from which the authenticated entity (user or role) last attempted * to access the tracked action. Amazon Web Services does not report * unauthenticated requests.

This field is null if no IAM entities attempted * to access the service within the tracking * period.

*/ inline void SetLastAccessedRegion(Aws::String&& value) { m_lastAccessedRegionHasBeenSet = true; m_lastAccessedRegion = std::move(value); } /** *

The Region from which the authenticated entity (user or role) last attempted * to access the tracked action. Amazon Web Services does not report * unauthenticated requests.

This field is null if no IAM entities attempted * to access the service within the tracking * period.

*/ inline void SetLastAccessedRegion(const char* value) { m_lastAccessedRegionHasBeenSet = true; m_lastAccessedRegion.assign(value); } /** *

The Region from which the authenticated entity (user or role) last attempted * to access the tracked action. Amazon Web Services does not report * unauthenticated requests.

This field is null if no IAM entities attempted * to access the service within the tracking * period.

*/ inline TrackedActionLastAccessed& WithLastAccessedRegion(const Aws::String& value) { SetLastAccessedRegion(value); return *this;} /** *

The Region from which the authenticated entity (user or role) last attempted * to access the tracked action. Amazon Web Services does not report * unauthenticated requests.

This field is null if no IAM entities attempted * to access the service within the tracking * period.

*/ inline TrackedActionLastAccessed& WithLastAccessedRegion(Aws::String&& value) { SetLastAccessedRegion(std::move(value)); return *this;} /** *

The Region from which the authenticated entity (user or role) last attempted * to access the tracked action. Amazon Web Services does not report * unauthenticated requests.

This field is null if no IAM entities attempted * to access the service within the tracking * period.

*/ inline TrackedActionLastAccessed& WithLastAccessedRegion(const char* value) { SetLastAccessedRegion(value); return *this;} private: Aws::String m_actionName; bool m_actionNameHasBeenSet = false; Aws::String m_lastAccessedEntity; bool m_lastAccessedEntityHasBeenSet = false; Aws::Utils::DateTime m_lastAccessedTime; bool m_lastAccessedTimeHasBeenSet = false; Aws::String m_lastAccessedRegion; bool m_lastAccessedRegionHasBeenSet = false; }; } // namespace Model } // namespace IAM } // namespace Aws