public static class FormattedLogProvider.Builder extends Object
FormattedLogProviderpublic FormattedLogProvider.Builder withoutRenderingContext()
public FormattedLogProvider.Builder withUTCZoneId()
public FormattedLogProvider.Builder withZoneId(ZoneId zoneId)
zoneId - @Deprecated public FormattedLogProvider.Builder withTimeZone(TimeZone timezone)
withZoneId(ZoneId)timezone - public FormattedLogProvider.Builder withDefaultLogLevel(Level level)
level - the log level to use as a defaultpublic FormattedLogProvider.Builder withLogLevel(String context, Level level)
Level for any Logs that match the specified context. Any Log context that
starts with the specified string will have its level set. For example, setting the level for the context org.neo4j
would result in that level being applied to Logs with the context org.neo4j.Foo, org.neo4j.foo.Bar, etc.context - the context of the Logs to set the level of, matching any Log context starting with this stringlevel - the log level to applypublic FormattedLogProvider.Builder withLogLevels(Map<String,Level> levels)
withLogLevel(String, Level)
for every entry in the provided map.levels - a map containing paris of context and levelpublic FormattedLogProvider.Builder withoutAutoFlush()
public FormattedLogProvider toOutputStream(OutputStream out)
FormattedLogProvider instance that writes messages to an OutputStream.out - An OutputStream to write toFormattedLogProvider instance that writes to the specified OutputStreampublic FormattedLogProvider toOutputStream(Supplier<OutputStream> outSupplier)
FormattedLogProvider instance that writes messages to OutputStreams obtained from the specified
Supplier. The OutputStream is obtained from the Supplier before every log message is written.outSupplier - A supplier for an output stream to write toFormattedLogProvider instancepublic FormattedLogProvider toWriter(Writer writer)
FormattedLogProvider instance that writes messages to a Writer.writer - A Writer to write toFormattedLogProvider instance that writes to the specified Writerpublic FormattedLogProvider toPrintWriter(PrintWriter writer)
FormattedLogProvider instance that writes messages to a PrintWriter.writer - A PrintWriter to write toFormattedLogProvider instance that writes to the specified PrintWriterpublic FormattedLogProvider toPrintWriter(Supplier<PrintWriter> writerSupplier)
FormattedLogProvider instance that writes messages to PrintWriters obtained from the specified
Supplier. The PrintWriter is obtained from the Supplier before every log message is written.writerSupplier - A supplier for a PrintWriter to write toFormattedLogProvider instance that writes to the specified PrintWriterCopyright © 2002–2017 The Neo4j Graph Database Project. All rights reserved.