Class AbstractJacksonLayout.Builder<B extends AbstractJacksonLayout.Builder<B>>

Direct Known Subclasses:
JsonLayout.Builder, XmlLayout.Builder, YamlLayout.Builder
Enclosing class:
AbstractJacksonLayout

public abstract static class AbstractJacksonLayout.Builder<B extends AbstractJacksonLayout.Builder<B>> extends AbstractStringLayout.Builder<B>
  • Field Details

  • Constructor Details

    • Builder

      public Builder()
  • Method Details

    • toStringOrNull

      protected String toStringOrNull(byte[] header)
    • getEventEol

      public boolean getEventEol()
    • getEndOfLine

      public String getEndOfLine()
    • isCompact

      public boolean isCompact()
    • isComplete

      public boolean isComplete()
    • isLocationInfo

      public boolean isLocationInfo()
    • isProperties

      public boolean isProperties()
    • isIncludeStacktrace

      public boolean isIncludeStacktrace()
      If "true", includes the stacktrace of any Throwable in the generated data, defaults to "true".
      Returns:
      If "true", includes the stacktrace of any Throwable in the generated data, defaults to "true".
    • isStacktraceAsString

      public boolean isStacktraceAsString()
    • isIncludeNullDelimiter

      public boolean isIncludeNullDelimiter()
    • isIncludeTimeMillis

      public boolean isIncludeTimeMillis()
    • getAdditionalFields

      public KeyValuePair[] getAdditionalFields()
    • setEventEol

      public B setEventEol(boolean eventEol)
    • setEndOfLine

      public B setEndOfLine(String endOfLine)
    • setCompact

      public B setCompact(boolean compact)
    • setComplete

      public B setComplete(boolean complete)
    • setLocationInfo

      public B setLocationInfo(boolean locationInfo)
    • setProperties

      public B setProperties(boolean properties)
    • setIncludeStacktrace

      public B setIncludeStacktrace(boolean includeStacktrace)
      If "true", includes the stacktrace of any Throwable in the generated JSON, defaults to "true".
      Parameters:
      includeStacktrace - If "true", includes the stacktrace of any Throwable in the generated JSON, defaults to "true".
      Returns:
      this builder
    • setStacktraceAsString

      public B setStacktraceAsString(boolean stacktraceAsString)
      Whether to format the stacktrace as a string, and not a nested object (optional, defaults to false).
      Returns:
      this builder
    • setIncludeNullDelimiter

      public B setIncludeNullDelimiter(boolean includeNullDelimiter)
      Whether to include NULL byte as delimiter after each event (optional, default to false).
      Returns:
      this builder
    • setIncludeTimeMillis

      public B setIncludeTimeMillis(boolean includeTimeMillis)
      Whether to include the timestamp (in addition to the Instant) (optional, default to false).
      Returns:
      this builder
    • setAdditionalFields

      public B setAdditionalFields(KeyValuePair[] additionalFields)
      Additional fields to set on each log event.
      Returns:
      this builder