Record Class InvocationResult
java.lang.Object
java.lang.Record
org.springframework.kafka.listener.adapter.InvocationResult
- Record Components:
result
- the result.messageReturnType
- the message return type.sendTo
- the expression about sends topic.
public record InvocationResult(Object result, Expression sendTo, boolean messageReturnType)
extends Record
The result of a method invocation.
- Since:
- 2.2
- Author:
- Gary Russell
-
Constructor Summary
ConstructorsConstructorDescriptionInvocationResult
(Object result, Expression sendTo, boolean messageReturnType) Creates an instance of aInvocationResult
record class. -
Method Summary
Modifier and TypeMethodDescriptionfinal boolean
Indicates whether some other object is "equal to" this one.final int
hashCode()
Returns a hash code value for this object.boolean
Returns the value of themessageReturnType
record component.result()
Returns the value of theresult
record component.sendTo()
Returns the value of thesendTo
record component.toString()
Returns a string representation of this record class.
-
Constructor Details
-
InvocationResult
public InvocationResult(@Nullable Object result, @Nullable Expression sendTo, boolean messageReturnType) Creates an instance of aInvocationResult
record class.- Parameters:
result
- the value for theresult
record componentsendTo
- the value for thesendTo
record componentmessageReturnType
- the value for themessageReturnType
record 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. Reference components are compared withObjects::equals(Object,Object)
; primitive components are compared with '=='. -
result
Returns the value of theresult
record component.- Returns:
- the value of the
result
record component
-
sendTo
Returns the value of thesendTo
record component.- Returns:
- the value of the
sendTo
record component
-
messageReturnType
public boolean messageReturnType()Returns the value of themessageReturnType
record component.- Returns:
- the value of the
messageReturnType
record component
-