/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include
#include
#include
namespace Aws
{
namespace Utils
{
namespace Xml
{
class XmlNode;
} // namespace Xml
} // namespace Utils
namespace S3
{
namespace Model
{
/**
* Amazon S3 keys for log objects are partitioned in the following format:
*
* [DestinationPrefix][SourceAccountId]/[SourceRegion]/[SourceBucket]/[YYYY]/[MM]/[DD]/[YYYY]-[MM]-[DD]-[hh]-[mm]-[ss]-[UniqueString]
*
PartitionedPrefix defaults to EventTime delivery when server access logs
* are delivered.
See Also:
AWS
* API Reference
*/
class PartitionedPrefix
{
public:
AWS_S3_API PartitionedPrefix();
AWS_S3_API PartitionedPrefix(const Aws::Utils::Xml::XmlNode& xmlNode);
AWS_S3_API PartitionedPrefix& operator=(const Aws::Utils::Xml::XmlNode& xmlNode);
AWS_S3_API void AddToNode(Aws::Utils::Xml::XmlNode& parentNode) const;
///@{
/**
* Specifies the partition date source for the partitioned prefix.
* PartitionDateSource can be EventTime or
* DeliveryTime.
For DeliveryTime, the time in the
* log file names corresponds to the delivery time for the log files.
For
* EventTime, The logs delivered are for a specific day only. The
* year, month, and day correspond to the day on which the event occurred, and the
* hour, minutes and seconds are set to 00 in the key.
*/
inline const PartitionDateSource& GetPartitionDateSource() const{ return m_partitionDateSource; }
inline bool PartitionDateSourceHasBeenSet() const { return m_partitionDateSourceHasBeenSet; }
inline void SetPartitionDateSource(const PartitionDateSource& value) { m_partitionDateSourceHasBeenSet = true; m_partitionDateSource = value; }
inline void SetPartitionDateSource(PartitionDateSource&& value) { m_partitionDateSourceHasBeenSet = true; m_partitionDateSource = std::move(value); }
inline PartitionedPrefix& WithPartitionDateSource(const PartitionDateSource& value) { SetPartitionDateSource(value); return *this;}
inline PartitionedPrefix& WithPartitionDateSource(PartitionDateSource&& value) { SetPartitionDateSource(std::move(value)); return *this;}
///@}
private:
PartitionDateSource m_partitionDateSource;
bool m_partitionDateSourceHasBeenSet = false;
};
} // namespace Model
} // namespace S3
} // namespace Aws