Module software.sava.rpc
Record Class KeepJsonResponseController<R>
java.lang.Object
java.lang.Record
software.sava.rpc.json.http.client.KeepJsonResponseController<R>
- All Implemented Interfaces:
Function<HttpResponse<byte[]>,R>
public record KeepJsonResponseController<R>(BiFunction<byte[],systems.comodal.jsoniter.JsonIterator,R> parser)
extends Record
implements Function<HttpResponse<byte[]>,R>
-
Constructor Summary
ConstructorsConstructorDescriptionKeepJsonResponseController(BiFunction<byte[], systems.comodal.jsoniter.JsonIterator, R> parser) Creates an instance of aKeepJsonResponseControllerrecord class. -
Method Summary
Modifier and TypeMethodDescriptionapply(HttpResponse<byte[]> response) final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.BiFunction<byte[], systems.comodal.jsoniter.JsonIterator, R> parser()Returns the value of theparserrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
KeepJsonResponseController
public KeepJsonResponseController(BiFunction<byte[], systems.comodal.jsoniter.JsonIterator, R> parser) Creates an instance of aKeepJsonResponseControllerrecord class.- Parameters:
parser- the value for theparserrecord component
-
-
Method Details
-
apply
- Specified by:
applyin interfaceFunction<HttpResponse<byte[]>,R>
-
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). -
parser
Returns the value of theparserrecord component.- Returns:
- the value of the
parserrecord component
-