1/*
2* Copyright 2010-2017 Amazon.com, Inc. or its affiliates. All Rights Reserved.
3*
4* Licensed under the Apache License, Version 2.0 (the "License").
5* You may not use this file except in compliance with the License.
6* A copy of the License is located at
7*
8* http://aws.amazon.com/apache2.0
9*
10* or in the "license" file accompanying this file. This file is distributed
11* on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
12* express or implied. See the License for the specific language governing
13* permissions and limitations under the License.
14*/
15
16#pragma once
17#include <aws/s3/S3_EXPORTS.h>
18#include <aws/s3/model/OwnerOverride.h>
19#include <utility>
20
21namespace Aws
22{
23namespace Utils
24{
25namespace Xml
26{
27 class XmlNode;
28} // namespace Xml
29} // namespace Utils
30namespace S3
31{
32namespace Model
33{
34
35 /**
36 * <p>A container for information about access control for replicas.</p><p><h3>See
37 * Also:</h3> <a
38 * href="http://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/AccessControlTranslation">AWS
39 * API Reference</a></p>
40 */
41 class AWS_S3_API AccessControlTranslation
42 {
43 public:
44 AccessControlTranslation();
45 AccessControlTranslation(const Aws::Utils::Xml::XmlNode& xmlNode);
46 AccessControlTranslation& operator=(const Aws::Utils::Xml::XmlNode& xmlNode);
47
48 void AddToNode(Aws::Utils::Xml::XmlNode& parentNode) const;
49
50
51 /**
52 * <p>Specifies the replica ownership. For default and valid values, see <a
53 * href="https://docs.aws.amazon.com/AmazonS3/latest/API/RESTBucketPUTreplication.html">PUT
54 * bucket replication</a> in the <i>Amazon Simple Storage Service API
55 * Reference</i>.</p>
56 */
57 inline const OwnerOverride& GetOwner() const{ return m_owner; }
58
59 /**
60 * <p>Specifies the replica ownership. For default and valid values, see <a
61 * href="https://docs.aws.amazon.com/AmazonS3/latest/API/RESTBucketPUTreplication.html">PUT
62 * bucket replication</a> in the <i>Amazon Simple Storage Service API
63 * Reference</i>.</p>
64 */
65 inline bool OwnerHasBeenSet() const { return m_ownerHasBeenSet; }
66
67 /**
68 * <p>Specifies the replica ownership. For default and valid values, see <a
69 * href="https://docs.aws.amazon.com/AmazonS3/latest/API/RESTBucketPUTreplication.html">PUT
70 * bucket replication</a> in the <i>Amazon Simple Storage Service API
71 * Reference</i>.</p>
72 */
73 inline void SetOwner(const OwnerOverride& value) { m_ownerHasBeenSet = true; m_owner = value; }
74
75 /**
76 * <p>Specifies the replica ownership. For default and valid values, see <a
77 * href="https://docs.aws.amazon.com/AmazonS3/latest/API/RESTBucketPUTreplication.html">PUT
78 * bucket replication</a> in the <i>Amazon Simple Storage Service API
79 * Reference</i>.</p>
80 */
81 inline void SetOwner(OwnerOverride&& value) { m_ownerHasBeenSet = true; m_owner = std::move(value); }
82
83 /**
84 * <p>Specifies the replica ownership. For default and valid values, see <a
85 * href="https://docs.aws.amazon.com/AmazonS3/latest/API/RESTBucketPUTreplication.html">PUT
86 * bucket replication</a> in the <i>Amazon Simple Storage Service API
87 * Reference</i>.</p>
88 */
89 inline AccessControlTranslation& WithOwner(const OwnerOverride& value) { SetOwner(value); return *this;}
90
91 /**
92 * <p>Specifies the replica ownership. For default and valid values, see <a
93 * href="https://docs.aws.amazon.com/AmazonS3/latest/API/RESTBucketPUTreplication.html">PUT
94 * bucket replication</a> in the <i>Amazon Simple Storage Service API
95 * Reference</i>.</p>
96 */
97 inline AccessControlTranslation& WithOwner(OwnerOverride&& value) { SetOwner(std::move(value)); return *this;}
98
99 private:
100
101 OwnerOverride m_owner;
102 bool m_ownerHasBeenSet;
103 };
104
105} // namespace Model
106} // namespace S3
107} // namespace Aws
108