Module methanol.adapter.jackson
Class JacksonSubscriber<T>
java.lang.Object
com.github.mizosoft.methanol.adapter.jackson.internal.JacksonSubscriber<T>
- All Implemented Interfaces:
HttpResponse.BodySubscriber<T>
,Flow.Subscriber<List<ByteBuffer>>
-
Constructor Summary
ConstructorDescriptionJacksonSubscriber
(com.fasterxml.jackson.databind.ObjectMapper mapper, TypeRef<T> type, ObjectReaderFactory readerFactory, com.fasterxml.jackson.core.JsonParser parser) -
Method Summary
Modifier and TypeMethodDescriptiongetBody()
void
void
void
onNext
(List<ByteBuffer> item) void
onSubscribe
(Flow.Subscription subscription)
-
Constructor Details
-
JacksonSubscriber
public JacksonSubscriber(com.fasterxml.jackson.databind.ObjectMapper mapper, TypeRef<T> type, ObjectReaderFactory readerFactory, com.fasterxml.jackson.core.JsonParser parser)
-
-
Method Details
-
getBody
- Specified by:
getBody
in interfaceHttpResponse.BodySubscriber<T>
-
onSubscribe
- Specified by:
onSubscribe
in interfaceFlow.Subscriber<T>
-
onNext
- Specified by:
onNext
in interfaceFlow.Subscriber<T>
-
onError
- Specified by:
onError
in interfaceFlow.Subscriber<T>
-
onComplete
public void onComplete()- Specified by:
onComplete
in interfaceFlow.Subscriber<T>
-