public class ConsoleLoggerImpl extends FormattedLoggerImpl<Object> implements ConsoleLogger
FormattedLoggerImpl for handling
RuntimeLogger's logs with ANSI Escape-Codes.FormattedLoggerImpl.OutputPrintStreamorg.refcodes.mixin.RowWidthAccessor.RowWidthBuilder<B extends org.refcodes.mixin.RowWidthAccessor.RowWidthBuilder<?>>, org.refcodes.mixin.RowWidthAccessor.RowWidthMutator, org.refcodes.mixin.RowWidthAccessor.RowWidthPropertyorg.refcodes.textual.TableStyleAccessor.TableStyleBuilder<B extends org.refcodes.textual.TableStyleAccessor.TableStyleBuilder<?>>, org.refcodes.textual.TableStyleAccessor.TableStyleMutator, org.refcodes.textual.TableStyleAccessor.TableStylePropertyorg.refcodes.mixin.StandardPrintStreamAccessor.StandardPrintStreamBuilder<B extends org.refcodes.mixin.StandardPrintStreamAccessor.StandardPrintStreamBuilder<?>>, org.refcodes.mixin.StandardPrintStreamAccessor.StandardPrintStreamMutator, org.refcodes.mixin.StandardPrintStreamAccessor.StandardPrintStreamPropertyorg.refcodes.mixin.ErrorPrintStreamAccessor.ErrorPrintStreamBuilder<B extends org.refcodes.mixin.ErrorPrintStreamAccessor.ErrorPrintStreamBuilder<?>>, org.refcodes.mixin.ErrorPrintStreamAccessor.ErrorPrintStreamMutator, org.refcodes.mixin.ErrorPrintStreamAccessor.ErrorPrintStreamPropertyorg.refcodes.logger.ColumnLayoutAccessor.ColumnLayoutBuilder<B extends org.refcodes.logger.ColumnLayoutAccessor.ColumnLayoutBuilder<B>>, org.refcodes.logger.ColumnLayoutAccessor.ColumnLayoutMutator, org.refcodes.logger.ColumnLayoutAccessor.ColumnLayoutProperty| Modifier and Type | Field and Description |
|---|---|
protected org.refcodes.textual.TableBuilder |
_errorBuilder |
protected org.refcodes.textual.TableBuilder |
_standardBuilder |
protected org.refcodes.tabular.FormattedHeader<Object> |
_standardHeader |
_errStream, _hasLeftBorder, _hasRightBorder, _header, _rowWidth, _stdStream, _tableBuilder, _tableStyle| Constructor and Description |
|---|
ConsoleLoggerImpl()
Instantiates a new console logger impl.
|
ConsoleLoggerImpl(org.refcodes.logger.ColumnLayout aLoggerLayout)
Instantiates a new console logger impl.
|
| Modifier and Type | Method and Description |
|---|---|
org.refcodes.logger.ColumnLayout |
getColumnLayout() |
protected void |
init()
Inits the.
|
void |
log(org.refcodes.tabular.Record<? extends Object> aRecord) |
protected void |
printException(Exception theException)
Prints the exception.
|
void |
printSeparator() |
void |
setColumnLayout(org.refcodes.logger.ColumnLayout aColumnLayout) |
protected static org.refcodes.logger.ColumnLayout |
toLoggerLayout()
To logger layout.
|
protected static org.refcodes.logger.ColumnLayout |
toLoggerLayout(org.refcodes.logger.ColumnLayout aLoggerLayout)
Determines the
ColumnLayout by evaluating the
SystemProperty.LOGGER_LAYOUT and the
EnvironmentProperty.LOGGER_LAYOUT (in this order). |
protected static org.refcodes.textual.TableStyle |
toLoggerStyle()
Determines the
TableStyle by evaluating the
SystemProperty.LOGGER_STYLE and the
EnvironmentProperty.LOGGER_STYLE (in this order). |
destroy, getErrorPrintStream, getRowWidth, getStandardPrintStream, getTableStyle, hasEscapeCodes, hasLeftBorder, hasRightBorder, log, setErrorPrintStream, setEscapeCodes, setLeftBorder, setLoggerStyle, setRightBorder, setRowWidth, setStandardPrintStream, setTableStyle, toPreConfiguredTableBuilderclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitsetLoggerLayout, withColumnLayout, withErrorPrintStream, withEscapeCodes, withLeftBorder, withRightBorder, withRowWidth, withStandardPrintStream, withTableStylehasEscapeCodes, hasLeftBorder, hasRightBorder, setEscapeCodes, setLeftBorder, setLoggerStyle, setRightBordersetTableStylegetStandardPrintStreamprotected org.refcodes.textual.TableBuilder _errorBuilder
protected org.refcodes.textual.TableBuilder _standardBuilder
protected org.refcodes.tabular.FormattedHeader<Object> _standardHeader
public ConsoleLoggerImpl()
public ConsoleLoggerImpl(org.refcodes.logger.ColumnLayout aLoggerLayout)
aLoggerLayout - the logger layoutpublic org.refcodes.logger.ColumnLayout getColumnLayout()
getColumnLayout in interface org.refcodes.logger.ColumnLayoutAccessorpublic void setColumnLayout(org.refcodes.logger.ColumnLayout aColumnLayout)
setColumnLayout in interface org.refcodes.logger.ColumnLayoutAccessor.ColumnLayoutMutatorpublic void log(org.refcodes.tabular.Record<? extends Object> aRecord) throws org.refcodes.logger.IllegalRecordRuntimeException, org.refcodes.logger.UnexpectedLogRuntimeException
log in interface org.refcodes.logger.Logger<Object>log in class FormattedLoggerImpl<Object>org.refcodes.logger.IllegalRecordRuntimeExceptionorg.refcodes.logger.UnexpectedLogRuntimeExceptionprotected void printException(Exception theException)
theException - the the exceptionpublic void printSeparator()
printSeparator in interface org.refcodes.logger.Logger<Object>protected static org.refcodes.logger.ColumnLayout toLoggerLayout(org.refcodes.logger.ColumnLayout aLoggerLayout)
ColumnLayout by evaluating the
SystemProperty.LOGGER_LAYOUT and the
EnvironmentProperty.LOGGER_LAYOUT (in this order). If none
(valid) layout was determinable, then the ColumnLayout.SUPERUSER
is returned.aLoggerLayout - the logger layoutColumnLayout to be used.protected static org.refcodes.logger.ColumnLayout toLoggerLayout()
protected static org.refcodes.textual.TableStyle toLoggerStyle()
TableStyle by evaluating the
SystemProperty.LOGGER_STYLE and the
EnvironmentProperty.LOGGER_STYLE (in this order). If none (valid)
style was determinable, then a proposed style is returned.TableStyle to be used.protected void init()
init in class FormattedLoggerImpl<Object>Copyright © 2018. All rights reserved.