From 820c937d468c99c96235d3c45162ce273c2fb975 Mon Sep 17 00:00:00 2001 From: Mark Sailes Date: Tue, 4 Jan 2022 13:15:21 +0000 Subject: [PATCH] Adding toString method to the S3EventNotification. --- .../events/models/s3/S3EventNotification.java | 67 +++++++++++++++++++ 1 file changed, 67 insertions(+) diff --git a/aws-lambda-java-events/src/main/java/com/amazonaws/services/lambda/runtime/events/models/s3/S3EventNotification.java b/aws-lambda-java-events/src/main/java/com/amazonaws/services/lambda/runtime/events/models/s3/S3EventNotification.java index 5df14ea2..17fa118a 100644 --- a/aws-lambda-java-events/src/main/java/com/amazonaws/services/lambda/runtime/events/models/s3/S3EventNotification.java +++ b/aws-lambda-java-events/src/main/java/com/amazonaws/services/lambda/runtime/events/models/s3/S3EventNotification.java @@ -49,6 +49,13 @@ public UserIdentityEntity(String principalId) { public String getPrincipalId() { return principalId; } + + @Override + public String toString() { + return "UserIdentityEntity{" + + "principalId='" + principalId + '\'' + + '}'; + } } public static class S3BucketEntity { @@ -74,6 +81,15 @@ public UserIdentityEntity getOwnerIdentity() { public String getArn() { return arn; } + + @Override + public String toString() { + return "S3BucketEntity{" + + "name='" + name + '\'' + + ", ownerIdentity=" + ownerIdentity + + ", arn='" + arn + '\'' + + '}'; + } } public static class S3ObjectEntity { @@ -173,6 +189,17 @@ public String getVersionId() { public String getSequencer() { return sequencer; } + + @Override + public String toString() { + return "S3ObjectEntity{" + + "key='" + key + '\'' + + ", size=" + size + + ", eTag='" + eTag + '\'' + + ", versionId='" + versionId + '\'' + + ", sequencer='" + sequencer + '\'' + + '}'; + } } public static class S3Entity { @@ -204,6 +231,16 @@ public S3ObjectEntity getObject() { public String getS3SchemaVersion() { return s3SchemaVersion; } + + @Override + public String toString() { + return "S3Entity{" + + "configurationId='" + configurationId + '\'' + + ", bucket=" + bucket + + ", object=" + object + + ", s3SchemaVersion='" + s3SchemaVersion + '\'' + + '}'; + } } public static class RequestParametersEntity { @@ -217,6 +254,13 @@ public RequestParametersEntity(String sourceIPAddress) { public String getSourceIPAddress() { return sourceIPAddress; } + + @Override + public String toString() { + return "RequestParametersEntity{" + + "sourceIPAddress='" + sourceIPAddress + '\'' + + '}'; + } } public static class ResponseElementsEntity { @@ -237,6 +281,14 @@ public String getxAmzId2() { public String getxAmzRequestId() { return xAmzRequestId; } + + @Override + public String toString() { + return "ResponseElementsEntity{" + + "xAmzId2='" + xAmzId2 + '\'' + + ", xAmzRequestId='" + xAmzRequestId + '\'' + + '}'; + } } public static class S3EventNotificationRecord { @@ -306,5 +358,20 @@ public S3Entity getS3() { public UserIdentityEntity getUserIdentity() { return userIdentity; } + + @Override + public String toString() { + return "S3EventNotificationRecord{" + + "awsRegion='" + awsRegion + '\'' + + ", eventName='" + eventName + '\'' + + ", eventSource='" + eventSource + '\'' + + ", eventTime=" + eventTime + + ", eventVersion='" + eventVersion + '\'' + + ", requestParameters=" + requestParameters + + ", responseElements=" + responseElements + + ", s3=" + s3 + + ", userIdentity=" + userIdentity + + '}'; + } } }