Class EcsLayout

  • All Implemented Interfaces:
    org.apache.logging.log4j.core.impl.LocationAware, org.apache.logging.log4j.core.Layout<String>, org.apache.logging.log4j.core.layout.Encoder<org.apache.logging.log4j.core.LogEvent>, org.apache.logging.log4j.core.StringLayout

    @Plugin(name="EcsLayout",
            category="Core",
            elementType="layout")
    public class EcsLayout
    extends org.apache.logging.log4j.core.layout.AbstractStringLayout
    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
      static class  EcsLayout.Builder  
      • Nested classes/interfaces inherited from class org.apache.logging.log4j.core.layout.AbstractStringLayout

        org.apache.logging.log4j.core.layout.AbstractStringLayout.Serializer, org.apache.logging.log4j.core.layout.AbstractStringLayout.Serializer2
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static Charset UTF_8  
      • Fields inherited from class org.apache.logging.log4j.core.layout.AbstractLayout

        configuration, eventCount, footer, header, LOGGER
      • Fields inherited from class org.apache.logging.log4j.core.layout.AbstractStringLayout

        DEFAULT_STRING_BUILDER_SIZE, MAX_STRING_BUILDER_SIZE
      • Fields inherited from interface org.apache.logging.log4j.core.Layout

        ELEMENT_TYPE
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void encode​(org.apache.logging.log4j.core.LogEvent event, org.apache.logging.log4j.core.layout.ByteBufferDestination destination)  
      String getContentType()  
      static EcsLayout.Builder newBuilder()  
      String toSerializable​(org.apache.logging.log4j.core.LogEvent event)  
      • Methods inherited from class org.apache.logging.log4j.core.layout.AbstractLayout

        getConfiguration, getContentFormat, markEvent
      • Methods inherited from class org.apache.logging.log4j.core.layout.AbstractStringLayout

        getBytes, getCharset, getFooter, getFooterSerializer, getHeader, getHeaderSerializer, getStringBuilder, getStringBuilderEncoder, requiresLocation, serializeToBytes, serializeToString, toByteArray, trimToMaxSize
      • Methods inherited from interface org.apache.logging.log4j.core.Layout

        getContentFormat
    • Field Detail

      • UTF_8

        public static final Charset UTF_8
    • Method Detail

      • toSerializable

        public String toSerializable​(org.apache.logging.log4j.core.LogEvent event)
      • encode

        public void encode​(org.apache.logging.log4j.core.LogEvent event,
                           org.apache.logging.log4j.core.layout.ByteBufferDestination destination)
        Specified by:
        encode in interface org.apache.logging.log4j.core.layout.Encoder<org.apache.logging.log4j.core.LogEvent>
        Overrides:
        encode in class org.apache.logging.log4j.core.layout.AbstractLayout<String>
      • getContentType

        public String getContentType()
        Specified by:
        getContentType in interface org.apache.logging.log4j.core.Layout<String>
        Overrides:
        getContentType in class org.apache.logging.log4j.core.layout.AbstractStringLayout