Record Class EnsureLogGroupOptions
java.lang.Object
java.lang.Record
codes.grow.packages.cloudwatchlogs.EnsureLogGroupOptions
- Record Components:
retentionDays- retention in days (one ofRETENTION_DAYS); 0 = never expire; null = leave as iskmsKeyId- KMS key for a new group; an existing group with a different key raisesConflictException- tags to add (existing tags are kept; values of the same keys are overwritten)
public record EnsureLogGroupOptions(Integer retentionDays, String kmsKeyId, Map<String,String> tags)
extends Record
Options of
ensureLogGroup.
Build with builder(); unset values are null and take the documented default.
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuilder()Starts a builder.static EnsureLogGroupOptionsdefaults()Options with every default.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.kmsKeyId()Returns the value of thekmsKeyIdrecord component.Returns the value of theretentionDaysrecord component.tags()Returns the value of thetagsrecord component.Returns a builder holding these values.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
EnsureLogGroupOptions
Applies defaults.- Parameters:
retentionDays- retention in days (one ofRETENTION_DAYS); 0 = never expire; null = leave as iskmsKeyId- KMS key for a new group; an existing group with a different key raisesConflictExceptiontags- tags to add (existing tags are kept; values of the same keys are overwritten)
-
-
Method Details
-
defaults
Options with every default.- Returns:
- the options
-
builder
Starts a builder.- Returns:
- a new builder
-
toBuilder
Returns a builder holding these values.- Returns:
- a new builder
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
retentionDays
Returns the value of theretentionDaysrecord component.- Returns:
- the value of the
retentionDaysrecord component
-
kmsKeyId
Returns the value of thekmsKeyIdrecord component.- Returns:
- the value of the
kmsKeyIdrecord component
-
tags
Returns the value of thetagsrecord component.- Returns:
- the value of the
tagsrecord component
-