@NotThreadSafe public abstract class BaseOutputWriter extends java.lang.Object implements OutputWriter, OutputWriterFactory
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
BINARY_PATH |
static java.lang.String |
BOOLEAN_AS_NUMBER |
static java.lang.String |
DEBUG |
static java.lang.String |
HOST |
static java.lang.String |
OUTPUT_FILE |
static java.lang.String |
PORT |
static java.lang.String |
TEMPLATE_FILE |
static java.lang.String |
TYPE_NAMES |
| Constructor and Description |
|---|
BaseOutputWriter(com.google.common.collect.ImmutableList<java.lang.String> typeNames,
boolean booleanAsNumber,
java.lang.Boolean debugEnabled,
java.util.Map<java.lang.String,java.lang.Object> settings) |
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
OutputWriter |
create() |
void |
doWrite(Server server,
Query query,
java.lang.Iterable<Result> results) |
protected <T> T |
firstNonNull(T first,
T second,
T third) |
protected java.lang.String |
getConcatedTypeNameValues(java.lang.String typeNameStr)
Given a typeName string, get the first match from the typeNames setting.
|
java.util.Map<java.lang.String,java.lang.Object> |
getSettings()
Deprecated.
Don't use the settings Map, please extract necessary bits at construction time.
|
protected abstract void |
internalWrite(Server server,
Query query,
com.google.common.collect.ImmutableList<Result> results) |
void |
start() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitvalidateSetuppublic static final java.lang.String HOST
public static final java.lang.String PORT
public static final java.lang.String OUTPUT_FILE
public static final java.lang.String TEMPLATE_FILE
public static final java.lang.String BINARY_PATH
public static final java.lang.String DEBUG
public static final java.lang.String TYPE_NAMES
public static final java.lang.String BOOLEAN_AS_NUMBER
public BaseOutputWriter(com.google.common.collect.ImmutableList<java.lang.String> typeNames,
boolean booleanAsNumber,
java.lang.Boolean debugEnabled,
java.util.Map<java.lang.String,java.lang.Object> settings)
protected <T> T firstNonNull(@Nullable
T first,
@Nullable
T second,
@Nullable
T third)
@Deprecated public java.util.Map<java.lang.String,java.lang.Object> getSettings()
OutputWritergetSettings in interface OutputWriterprotected java.lang.String getConcatedTypeNameValues(java.lang.String typeNameStr)
public void start()
throws LifecycleException
start in interface OutputWriterLifecycleExceptionpublic void close()
throws LifecycleException
close in interface OutputWriterclose in interface java.lang.AutoCloseableLifecycleExceptionpublic final void doWrite(Server server, Query query, java.lang.Iterable<Result> results) throws java.lang.Exception
doWrite in interface OutputWriterjava.lang.Exceptionprotected abstract void internalWrite(Server server, Query query, com.google.common.collect.ImmutableList<Result> results) throws java.lang.Exception
java.lang.Exceptionpublic OutputWriter create()
create in interface OutputWriterFactoryCopyright © 2010-2018 JmxTrans team. All Rights Reserved.