Package org.elasticsearch.test.transport
Record Class CapturingTransport.CapturedRequest
java.lang.Object
java.lang.Record
org.elasticsearch.test.transport.CapturingTransport.CapturedRequest
- Enclosing class:
- CapturingTransport
public static record CapturingTransport.CapturedRequest(DiscoveryNode node, long requestId, String action, TransportRequest request)
extends Record
-
Constructor Summary
ConstructorDescriptionCapturedRequest
(DiscoveryNode node, long requestId, String action, TransportRequest request) Creates an instance of aCapturedRequest
record class. -
Method Summary
Modifier and TypeMethodDescriptionaction()
Returns the value of theaction
record component.final boolean
Indicates whether some other object is "equal to" this one.final int
hashCode()
Returns a hash code value for this object.node()
Returns the value of thenode
record component.request()
Returns the value of therequest
record component.long
Returns the value of therequestId
record component.final String
toString()
Returns a string representation of this record class.
-
Constructor Details
-
CapturedRequest
Creates an instance of aCapturedRequest
record class.- Parameters:
node
- the value for thenode
record componentrequestId
- the value for therequestId
record componentaction
- the value for theaction
record componentrequest
- the value for therequest
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 '=='. -
node
Returns the value of thenode
record component.- Returns:
- the value of the
node
record component
-
requestId
public long requestId()Returns the value of therequestId
record component.- Returns:
- the value of the
requestId
record component
-
action
Returns the value of theaction
record component.- Returns:
- the value of the
action
record component
-
request
Returns the value of therequest
record component.- Returns:
- the value of the
request
record component
-