public final class OpLoader extends Object
ServiceLoader
to load OpProcessor
instances into a cache.Constructor and Description |
---|
OpLoader() |
Modifier and Type | Method and Description |
---|---|
static Optional<OpProcessor> |
getProcessor(String name)
Gets an
OpProcessor by its name. |
static Map<String,OpProcessor> |
getProcessors()
Gets a read-only map of the processors where the key is the
OpProcessor name and the value is the
instance created by ServiceLoader . |
static void |
init(Settings settings)
Initialize the
OpLoader with server settings. |
public static void init(Settings settings)
OpLoader
with server settings. This method should only be called once at startup but is
designed to be idempotent.public static Optional<OpProcessor> getProcessor(String name)
OpProcessor
by its name. If it cannot be found an Optional.EMPTY
is returned.public static Map<String,OpProcessor> getProcessors()
OpProcessor
name and the value is the
instance created by ServiceLoader
.Copyright © 2013–2017 Apache Software Foundation. All rights reserved.