Record Class LogStreamInfo
java.lang.Object
java.lang.Record
codes.grow.packages.cloudwatchlogs.LogStreamInfo
- Record Components:
name- log stream namearn- log stream ARNcreationTime- creation timefirstEventTime- time of the first eventlastEventTime- time of the last event (eventually consistent on AWS; do not rely on it)lastIngestionTime- last ingestion time
public record LogStreamInfo(String name, Optional<String> arn, Optional<Instant> creationTime, Optional<Instant> firstEventTime, Optional<Instant> lastEventTime, Optional<Instant> lastIngestionTime)
extends Record
A log stream (
DescribeLogStreams).-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionarn()Returns the value of thearnrecord component.Returns the value of thecreationTimerecord component.final booleanIndicates whether some other object is "equal to" this one.Returns the value of thefirstEventTimerecord component.final inthashCode()Returns a hash code value for this object.Returns the value of thelastEventTimerecord component.Returns the value of thelastIngestionTimerecord component.name()Returns the value of thenamerecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
LogStreamInfo
public LogStreamInfo(String name, Optional<String> arn, Optional<Instant> creationTime, Optional<Instant> firstEventTime, Optional<Instant> lastEventTime, Optional<Instant> lastIngestionTime) Normalises absent values (null lists become empty, null optionals empty).- Parameters:
name- log stream namearn- log stream ARNcreationTime- creation timefirstEventTime- time of the first eventlastEventTime- time of the last event (eventually consistent on AWS; do not rely on it)lastIngestionTime- last ingestion time
-
-
Method Details
-
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). -
name
Returns the value of thenamerecord component.- Returns:
- the value of the
namerecord component
-
arn
Returns the value of thearnrecord component.- Returns:
- the value of the
arnrecord component
-
creationTime
Returns the value of thecreationTimerecord component.- Returns:
- the value of the
creationTimerecord component
-
firstEventTime
Returns the value of thefirstEventTimerecord component.- Returns:
- the value of the
firstEventTimerecord component
-
lastEventTime
Returns the value of thelastEventTimerecord component.- Returns:
- the value of the
lastEventTimerecord component
-
lastIngestionTime
Returns the value of thelastIngestionTimerecord component.- Returns:
- the value of the
lastIngestionTimerecord component
-