public class BytesMethodReaderBuilder extends Object implements MethodReaderBuilder
BytesMethodReader instances. It allows configuration of
the lookup mechanism for method decoders (MethodEncoderLookup), the
handler for unknown method calls (BytesParselet) and logging
behaviour for unrecognised methods. Implements MethodReaderBuilder.| Constructor and Description |
|---|
BytesMethodReaderBuilder(BytesIn<?> in) |
| Modifier and Type | Method and Description |
|---|---|
BytesMethodReader |
build(Object... objects)
Constructs and returns a new
BytesMethodReader configured with the
settings from this builder and the provided handler objects. |
BytesParselet |
defaultParselet()
Returns the
BytesParselet to use when a message ID is encountered
for which no specific handler is registered. |
BytesMethodReaderBuilder |
defaultParselet(BytesParselet defaultParselet)
Sets the default BytesParselet for this builder.
|
MethodReaderBuilder |
exceptionHandlerOnUnknownMethod(net.openhft.chronicle.core.onoes.ExceptionHandler exceptionHandler)
Sets the ExceptionHandler instance to use when an unknown method is encountered.
|
MethodReaderBuilder |
metaDataHandler(Object... components)
This builder does not support metadata handlers.
|
MethodEncoderLookup |
methodEncoderLookup()
Returns the currently configured
MethodEncoderLookup strategy used
to find decoders for method calls. |
BytesMethodReaderBuilder |
methodEncoderLookup(MethodEncoderLookup methodEncoderLookup)
Sets the MethodEncoderLookup function for this builder.
|
MethodReaderBuilder |
methodReaderInterceptorReturns(MethodReaderInterceptorReturns methodReaderInterceptorReturns)
This builder does not support interceptors for method reader returns.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitpredicate, warnMissingpublic BytesMethodReaderBuilder(BytesIn<?> in)
in - the BytesIn stream from which serialised method calls
will be read. Must not be null.NullPointerException - if in is nullnet.openhft.chronicle.core.io.ClosedIllegalStateException - if in has been releasednet.openhft.chronicle.core.io.ThreadingIllegalStateException - if in is accessed by
multiple threads unsafelypublic MethodReaderBuilder exceptionHandlerOnUnknownMethod(net.openhft.chronicle.core.onoes.ExceptionHandler exceptionHandler)
exceptionHandlerOnUnknownMethod in interface MethodReaderBuilderexceptionHandler - the ExceptionHandler instancepublic MethodEncoderLookup methodEncoderLookup()
MethodEncoderLookup strategy used
to find decoders for method calls.public BytesMethodReaderBuilder methodEncoderLookup(MethodEncoderLookup methodEncoderLookup)
methodEncoderLookup - the MethodEncoderLookup functionpublic BytesParselet defaultParselet()
BytesParselet to use when a message ID is encountered
for which no specific handler is registered. If not explicitly set,
it is initialised based on the
exceptionHandlerOnUnknownMethod(ExceptionHandler) configuration.public BytesMethodReaderBuilder defaultParselet(BytesParselet defaultParselet)
defaultParselet - the default BytesParseletpublic MethodReaderBuilder methodReaderInterceptorReturns(MethodReaderInterceptorReturns methodReaderInterceptorReturns)
methodReaderInterceptorReturns in interface MethodReaderBuildermethodReaderInterceptorReturns - the interceptor instanceUnsupportedOperationException - alwayspublic MethodReaderBuilder metaDataHandler(Object... components)
metaDataHandler in interface MethodReaderBuildercomponents - the metadata handlersUnsupportedOperationException - alwayspublic BytesMethodReader build(Object... objects)
BytesMethodReader configured with the
settings from this builder and the provided handler objects.build in interface MethodReaderBuilderobjects - the target objects whose methods will be invokedBytesMethodReaderCopyright © 2026 Chronicle Software Ltd. All rights reserved.