Class LogGroupTargetInputOptions.Builder
java.lang.Object
software.amazon.awscdk.services.events.targets.LogGroupTargetInputOptions.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<LogGroupTargetInputOptions>
- Enclosing interface:
LogGroupTargetInputOptions
@Stability(Stable)
public static final class LogGroupTargetInputOptions.Builder
extends Object
implements software.amazon.jsii.Builder<LogGroupTargetInputOptions>
A builder for
LogGroupTargetInputOptions
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
Builds the configured instance.Sets the value ofLogGroupTargetInputOptions.getMessage()
Sets the value ofLogGroupTargetInputOptions.getTimestamp()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
message
Sets the value ofLogGroupTargetInputOptions.getMessage()
- Parameters:
message
- The value provided here will be used in the Log "message" field. This field must be a string. If an object is passed (e.g. JSON data) it will not throw an error, but the message that makes it to CloudWatch logs will be incorrect. This is a likely scenario if doing something like: EventField.fromPath('$.detail') since in most cases thedetail
field contains JSON data.- Returns:
this
-
timestamp
Sets the value ofLogGroupTargetInputOptions.getTimestamp()
- Parameters:
timestamp
- The timestamp that will appear in the CloudWatch Logs record.- Returns:
this
-
build
Builds the configured instance.- Specified by:
build
in interfacesoftware.amazon.jsii.Builder<LogGroupTargetInputOptions>
- Returns:
- a new instance of
LogGroupTargetInputOptions
- Throws:
NullPointerException
- if any required attribute was not provided
-