Package org.opensearch
Class OpenSearchException.OpenSearchExceptionHandleRegistry
java.lang.Object
org.opensearch.OpenSearchException.OpenSearchExceptionHandleRegistry
- Enclosing class:
OpenSearchException
Registry of ExceptionHandlers
- Opensearch.internal:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic intgetId(Class<? extends OpenSearchException> exception) Gets the unique ordinal id of the Exception from the given classstatic Set<Class<? extends OpenSearchException>> returns a set of registered exception classesstatic org.opensearch.common.CheckedFunction<StreamInput, ? extends OpenSearchException, IOException> getSupplier(int id) returns the Exception constructor function from a given ordinalhandles()returns a collection of handlesids()returns a set of idsstatic booleanisRegistered(Class<? extends Throwable> exception, Version version) checks that the exception class is registeredstatic voidregisters the Exception handler
-
Constructor Details
-
OpenSearchExceptionHandleRegistry
public OpenSearchExceptionHandleRegistry()
-
-
Method Details
-
getSupplier
public static org.opensearch.common.CheckedFunction<StreamInput,? extends OpenSearchException, getSupplierIOException> (int id) returns the Exception constructor function from a given ordinal -
registerExceptionHandle
registers the Exception handler -
getId
Gets the unique ordinal id of the Exception from the given class -
ids
returns a set of ids -
handles
returns a collection of handles -
isRegistered
checks that the exception class is registered -
getRegisteredKeys
returns a set of registered exception classes
-