Record Class PayloadMapping
java.lang.Object
java.lang.Record
io.axoniq.framework.workflow.dsl.api.PayloadMapping
- Record Components:
parameterPayloadReducer- reducer for step input payload.resultPayloadReducer- reducer for step result payload.
public record PayloadMapping(PayloadReducer parameterPayloadReducer, PayloadReducer resultPayloadReducer)
extends Record
Reusable payload mapping shared by primitive specs.
- Since:
- 5.4.0
- Author:
- Simon Zambrovski
-
Constructor Summary
ConstructorsConstructorDescriptionPayloadMapping(PayloadReducer parameterPayloadReducer, PayloadReducer resultPayloadReducer) Creates an instance of aPayloadMappingrecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.Returns the value of theparameterPayloadReducerrecord component.parameterPayloadReducer(PayloadReducer parameterPayloadReducer) Returns a copy of this mapping with the provided parameter payload reducer.Returns the value of theresultPayloadReducerrecord component.resultPayloadReducer(PayloadReducer resultPayloadReducer) Returns a copy of this mapping with the provided result payload reducer.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
PayloadMapping
Creates an instance of aPayloadMappingrecord class.- Parameters:
parameterPayloadReducer- the value for theparameterPayloadReducerrecord componentresultPayloadReducer- the value for theresultPayloadReducerrecord component
-
-
Method Details
-
parameterPayloadReducer
Returns a copy of this mapping with the provided parameter payload reducer.- Parameters:
parameterPayloadReducer- reducer used to prepare the step input payload- Returns:
- copied payload mapping with updated parameter reducer
-
resultPayloadReducer
Returns a copy of this mapping with the provided result payload reducer.- Parameters:
resultPayloadReducer- reducer used to update the workflow payload from the step result- Returns:
- copied payload mapping with updated result reducer
-
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). -
parameterPayloadReducer
Returns the value of theparameterPayloadReducerrecord component.- Returns:
- the value of the
parameterPayloadReducerrecord component
-
resultPayloadReducer
Returns the value of theresultPayloadReducerrecord component.- Returns:
- the value of the
resultPayloadReducerrecord component
-