public abstract class StatementPrinterBase<S extends Statement<S>> extends Object implements StatementPrinter<S>
StatementPrinter implementations.
This class assumes a common formatting pattern comprised of the following sections:
NORMAL or higher;
EXTENDED;
| Constructor and Description |
|---|
StatementPrinterBase() |
| Modifier and Type | Method and Description |
|---|---|
protected List<String> |
collectStatementProperties(S statement,
StatementWriter out,
StatementFormatVerbosity verbosity) |
abstract Class<? extends S> |
getSupportedStatementClass()
The concrete
Statement subclass that this printer handles. |
void |
print(S statement,
StatementWriter out,
StatementFormatVerbosity verbosity)
|
protected void |
printBoundValues(S statement,
StatementWriter out,
StatementFormatVerbosity verbosity) |
protected void |
printHeader(S statement,
StatementWriter out,
StatementFormatVerbosity verbosity) |
protected void |
printQueryString(S statement,
StatementWriter out,
StatementFormatVerbosity verbosity) |
public abstract Class<? extends S> getSupportedStatementClass()
StatementPrinterStatement subclass that this printer handles.
In case of subtype polymorphism, if this printer handles more than one concrete subclass, the most specific common ancestor should be returned here.
getSupportedStatementClass in interface StatementPrinter<S extends Statement<S>>Statement subclass that this printer handles.public void print(S statement, StatementWriter out, StatementFormatVerbosity verbosity)
StatementPrinterprint in interface StatementPrinter<S extends Statement<S>>statement - the statement to printout - the writer to useverbosity - the verbosity to useprotected void printHeader(S statement, StatementWriter out, StatementFormatVerbosity verbosity)
protected List<String> collectStatementProperties(S statement, StatementWriter out, StatementFormatVerbosity verbosity)
protected void printQueryString(S statement, StatementWriter out, StatementFormatVerbosity verbosity)
protected void printBoundValues(S statement, StatementWriter out, StatementFormatVerbosity verbosity)
Copyright © 2017–2021 DataStax. All rights reserved.