Record Class PipelineStateStore.RunMetadata
java.lang.Object
java.lang.Record
com.tnsai.quality.security.harness.PipelineStateStore.RunMetadata
- Record Components:
stage- id of the stagestartedAt- when the stage beganfinishedAt- when it endedresult-StageResultproducederror- present if the stage failed
- Enclosing interface:
PipelineStateStore
public static record PipelineStateStore.RunMetadata(String stage, Instant startedAt, Instant finishedAt, StageResult result, Optional<String> error)
extends Record
Audit-trail entry for one stage execution.
-
Constructor Summary
ConstructorsConstructorDescriptionRunMetadata(String stage, Instant startedAt, Instant finishedAt, StageResult result, Optional<String> error) Creates an instance of aRunMetadatarecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.error()Returns the value of theerrorrecord component.Returns the value of thefinishedAtrecord component.final inthashCode()Returns a hash code value for this object.result()Returns the value of theresultrecord component.stage()Returns the value of thestagerecord component.Returns the value of thestartedAtrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
RunMetadata
public RunMetadata(String stage, Instant startedAt, Instant finishedAt, StageResult result, Optional<String> error) Creates an instance of aRunMetadatarecord class.- Parameters:
stage- the value for thestagerecord componentstartedAt- the value for thestartedAtrecord componentfinishedAt- the value for thefinishedAtrecord componentresult- the value for theresultrecord componenterror- the value for theerrorrecord component
-
-
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). -
stage
Returns the value of thestagerecord component.- Returns:
- the value of the
stagerecord component
-
startedAt
Returns the value of thestartedAtrecord component.- Returns:
- the value of the
startedAtrecord component
-
finishedAt
Returns the value of thefinishedAtrecord component.- Returns:
- the value of the
finishedAtrecord component
-
result
Returns the value of theresultrecord component.- Returns:
- the value of the
resultrecord component
-
error
Returns the value of theerrorrecord component.- Returns:
- the value of the
errorrecord component
-