Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion generator/ServiceClientGeneratorLib/ServiceModel.cs
Original file line number Diff line number Diff line change
Expand Up @@ -578,7 +578,12 @@ public List<Operation> S3AllowListOperations
new Operation(this, "DeleteBucketMetadataConfiguration", DocumentRoot[OperationsKey]["DeleteBucketMetadataConfiguration"]),
new Operation(this, "ListObjects", DocumentRoot[OperationsKey]["ListObjects"]),
new Operation(this,"UpdateBucketMetadataJournalTableConfiguration", DocumentRoot[OperationsKey]["UpdateBucketMetadataJournalTableConfiguration"]),
new Operation(this, "ListMultipartUploads", DocumentRoot[OperationsKey]["ListMultipartUploads"])
new Operation(this, "ListMultipartUploads", DocumentRoot[OperationsKey]["ListMultipartUploads"]),
new Operation(this, "CompleteMultipartUpload", DocumentRoot[OperationsKey]["CompleteMultipartUpload"]),
new Operation(this, "DeleteObject", DocumentRoot[OperationsKey]["DeleteObject"]),
new Operation(this, "DeleteObjects", DocumentRoot[OperationsKey]["DeleteObjects"]),
new Operation(this, "DeleteObjectTagging", DocumentRoot[OperationsKey]["DeleteObjectTagging"]),
new Operation(this, "GetBucketLogging", DocumentRoot[OperationsKey]["GetBucketLogging"])
};
}
return _s3AllowListOperations.Where(operation => operation.data != null).ToList();
Expand Down
232 changes: 232 additions & 0 deletions generator/ServiceModels/s3/s3.customizations.json
Original file line number Diff line number Diff line change
Expand Up @@ -1289,6 +1289,208 @@
"Uploads":{"emitPropertyName":"MultipartUploads"}


}
]
},
"RestoreObjectRequest":{
"modify":[
{
"Tier": {"emitPropertyName":"RetrievalTier"}
},
{
"ExpectedBucketOwner":{"injectXmlIsSet":["return !String.IsNullOrEmpty(this._expectedBucketOwner);"]}
},
{
"GlacierJobParameters":{
"emitPropertyName":"Tier"
}
},
{
"Type":{"emitPropertyName":"RestoreRequestType"}
}
]
},
"RestoreRequest":{
"modify":[
{
"GlacierJobParameters":{
"injectXmlMarshallCode":["TierCustomMarshall(xmlWriter, publicRequest);"]
}
},
{
"Type":{"emitPropertyName":"RestoreRequestType"}
},
{
"Tier": {"emitPropertyName":"RetrievalTier"}
}
]
},
"InputSerialization":{
"modify":[
{
"CompressionType":{
"injectXmlPrivateMemberAssignment" :["private CompressionType _compressionType = CompressionType.None;"]
}
}

]
},
"S3Location":{
"modify":[
{
"AccessControlList":{
"injectXmlPrivateMemberAssignment":["private S3AccessControlList _accessControlList;"],
"injectXmlIsSet":["return this._accessControlList != null;"],
"injectXmlMarshallCode":["AccessControlListCustomMarshall(xmlWriter, publicRequest);"]
}
},
{
"UserMetadata":{
"injectXmlPrivateMemberAssignment":["private MetadataCollection _userMetadata;"],
"injectXmlIsSet":["return this._userMetadata != null;"],
"injectXmlMarshallCode":["UserMetadataCustomMarshall(xmlWriter, publicRequest);"]
}
}
]
},
"JSONInput":{
"modify":[
{
"Type":{"emitPropertyName":"JsonType"}
}
]
},
"CompleteMultipartUploadOutput":{
"modify":[
{
"ServerSideEncryption":{"emitPropertyName":"ServerSideEncryptionMethod"}
},
{
"SSEKMSKeyId":{"emitPropertyName":"ServerSideEncryptionKeyManagementServiceKeyId"}
},
{
"Expiration":{"injectXmlUnmarshallCode":["ExpirationCustomUnmarshall(context, response);"]}
}
]
},
"CompletedMultipartUpload":{
"modify":[
{
"Parts": {"emitPropertyName":"PartETags"}
}
]
},
"DeleteObjectRequest":{
"modify":[
{
"ExpectedBucketOwner":{"injectXmlIsSet": ["return !String.IsNullOrEmpty(this._expectedBucketOwner);"]}
},
{
"IfMatch" : {"injectXmlIsSet":["return !string.IsNullOrEmpty(this._ifMatch);"]}
},
{
"MFA": {"emitPropertyName": "MfaCodes"}
},
{
"MfaCodes":{
"injectXmlIsSet": ["return CustomMfaCodesIsSet();"],
"injectXmlMarshallCode" : ["MfaCodesCustomMarshall(request, publicRequest);"]
}
}
]
},
"DeleteObjectOutput":{
"modify":[
{
"DeleteMarker":{"injectXmlUnmarshallCode": ["DeleteMarkerCustomUnmarshall(context, response);"]}
}
]
},
"DeleteObjectsRequest":{
"modify":[
{
"MFA":{"emitPropertyName" :"MfaCodes"}
},
{
"MfaCodes":{
"injectXmlIsSet": ["return CustomMfaCodesIsSet();"],
"injectXmlMarshallCode" : ["MfaCodesCustomMarshall(request, publicRequest);"]
}
},
{
"ExpectedBucketOwner":{
"injectXmlIsSet": ["return !String.IsNullOrEmpty(this._expectedBucketOwner);"]
}
}
]
},
"DeleteObjectsOutput":{
"modify":[
{
"Deleted":{"emitPropertyName":"DeletedObjects"}
},
{
"Errors":{"emitPropertyName":"DeleteErrors"}
}
]
},
"Delete":{
"modify":[
{
"Objects":{
"skipXmlIsSet": true
}
}
]
},
"KeyVersion" : {
"modify":[
{
"ETag":{"injectXmlIsSet":["return !String.IsNullOrEmpty(this._eTag);"]}
}
]
},
"DeleteObjectTaggingRequest":{
"modify":[
{
"ExpectedBucketOwner":{"injectXmlIsSet":["return !String.IsNullOrEmpty(this._expectedBucketOwner);"]}
},
{
"VersionId":{"injectXmlIsSet":["return !String.IsNullOrEmpty(this._versionId);"]}
}
]
},
"DeleteObjectTaggingOutput":{
"modify":[
{
"VersionId":{"injectXmlIsSet":["return !String.IsNullOrEmpty(this._versionId);"]}
}
]
},
"GetBucketLoggingRequest":{
"modify":[
{
"ExpectedBucketOwner":{"injectXmlIsSet":["return !String.IsNullOrEmpty(this._expectedBucketOwner);"]}
}
]
},
"GetBucketLoggingOutput":{
"modify":[
{
"LoggingEnabled": {"emitPropertyName":"BucketLoggingConfig"}
},
{
"BucketLoggingConfig":{"injectXmlPropertyGetter" : ["get {return BucketLoggingConfigCustomGetter();}"]}
}
]
},
"S3BucketLoggingConfig":{
"modify":[
{
"TargetBucket":{"emitPropertyName":"TargetBucketName"}
},
{
"TargetGrants":{"emitPropertyName":"Grants"}
}
]
}
Expand Down Expand Up @@ -1434,6 +1636,36 @@
},
"Type" :{
"renameShape":"GranteeType"
},
"Tier":{
"renameShape":"GlacierJobTier"
},
"Encryption":{
"renameShape":"S3Encryption"
},
"GlacierJobParameters":{
"renameShape":"GlacierJobTier"
},
"JSONType":{
"renameShape":"JsonType"
},
"CompletedPart":{
"renameShape":"PartETag"
},
"MFA":{
"renameShape": "MfaCodes"
},
"ObjectIdentifier":{
"renameShape": "KeyVersion"
},
"Error":{
"renameShape": "DeleteError"
},
"LoggingEnabled":{
"renameShape":"S3BucketLoggingConfig"
},
"TargetGrant":{
"renameShape": "S3Grant"
}
},
"overrideTreatEnumsAsString":{
Expand Down
19 changes: 5 additions & 14 deletions sdk/src/Services/S3/Custom/Model/GetBucketLoggingResponse.cs
Original file line number Diff line number Diff line change
Expand Up @@ -24,24 +24,15 @@ namespace Amazon.S3.Model
/// <summary>
/// Returns information about the GetBucketLogging response and response metadata.
/// </summary>
public class GetBucketLoggingResponse : AmazonWebServiceResponse
public partial class GetBucketLoggingResponse : AmazonWebServiceResponse
{
private S3BucketLoggingConfig bucketLoggingConfig;

/// <summary>
/// Gets and sets the LoggingConfig property.
/// </summary>
public S3BucketLoggingConfig BucketLoggingConfig
S3BucketLoggingConfig BucketLoggingConfigCustomGetter()
{
get
if (this._bucketLoggingConfig == null)
{
if (this.bucketLoggingConfig == null)
{
this.bucketLoggingConfig = new S3BucketLoggingConfig();
}
return this.bucketLoggingConfig;
this._bucketLoggingConfig = new S3BucketLoggingConfig();
}
set { this.bucketLoggingConfig = value; }
return this._bucketLoggingConfig;
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,49 +24,12 @@ namespace Amazon.S3.Model.Internal.MarshallTransformations
/// <summary>
/// Get Bucket Logging Request Marshaller
/// </summary>
public class GetBucketLoggingRequestMarshaller : IMarshaller<IRequest, GetBucketLoggingRequest> ,IMarshaller<IRequest,Amazon.Runtime.AmazonWebServiceRequest>
public partial class GetBucketLoggingRequestMarshaller : IMarshaller<IRequest, GetBucketLoggingRequest> ,IMarshaller<IRequest,Amazon.Runtime.AmazonWebServiceRequest>
{
public IRequest Marshall(Amazon.Runtime.AmazonWebServiceRequest input)
{
return this.Marshall((GetBucketLoggingRequest)input);
}

public IRequest Marshall(GetBucketLoggingRequest getBucketLoggingRequest)
partial void PreMarshallCustomization(DefaultRequest defaultRequest, GetBucketLoggingRequest publicRequest)
{
IRequest request = new DefaultRequest(getBucketLoggingRequest, "Amazon.S3");

request.Suppress404Exceptions = true;
request.HttpMethod = "GET";

if (getBucketLoggingRequest.IsSetExpectedBucketOwner())
request.Headers.Add(S3Constants.AmzHeaderExpectedBucketOwner, S3Transforms.ToStringValue(getBucketLoggingRequest.ExpectedBucketOwner));

if (string.IsNullOrEmpty(getBucketLoggingRequest.BucketName))
throw new System.ArgumentException("BucketName is a required property and must be set before making this call.", "GetBucketLoggingRequest.BucketName");

request.ResourcePath = "/";
request.AddSubResource("logging");
request.UseQueryString = true;

return request;
defaultRequest.Suppress404Exceptions = true;
}

private static GetBucketLoggingRequestMarshaller _instance;

/// <summary>
/// Singleton for marshaller
/// </summary>
public static GetBucketLoggingRequestMarshaller Instance
{
get
{
if (_instance == null)
{
_instance = new GetBucketLoggingRequestMarshaller();
}
return _instance;
}
}
}
}

Loading