public abstract class BackendFactory
extends java.lang.Object
Note that logging and calling arbitrary unknown code (which might log) are permitted inside the instance methods of this API, since they are not called during platform initialization. The easiest way to achieve this is to simply avoid having any non-trivial static fields or any instance fields at all in the implementation.
While this sounds onerous it's not difficult to achieve because this API is a singleton, and can delay any actual work until its methods are called. For example if any additional state is required in the implementation, it can be held via a "lazy holder" to defer initialization.
| Constructor and Description |
|---|
BackendFactory() |
| Modifier and Type | Method and Description |
|---|---|
abstract com.google.common.flogger.backend.LoggerBackend |
create(java.lang.String loggingClassName)
Creates a logger backend of the given class name for use by a Fluent Logger.
|
public abstract com.google.common.flogger.backend.LoggerBackend create(java.lang.String loggingClassName)
loggingClassName - the fully-qualified name of the Java class to which the logger is
associated. The logger name is derived from this string in a backend specific way.