Class StringBuilderEncoder
java.lang.Object
org.apache.logging.log4j.core.layout.StringBuilderEncoder
- All Implemented Interfaces:
Encoder<StringBuilder>
Encoder for StringBuilders that uses ThreadLocals to avoid locking as much as possible.
-
Constructor Summary
ConstructorsConstructorDescriptionStringBuilderEncoder(Charset charset) StringBuilderEncoder(Charset charset, int charBufferSize, int byteBufferSize) -
Method Summary
Modifier and TypeMethodDescriptionvoidencode(StringBuilder source, ByteBufferDestination destination) Encodes the specified source object to some binary representation and writes the result to the specified destination.
-
Constructor Details
-
StringBuilderEncoder
-
StringBuilderEncoder
-
-
Method Details
-
encode
Description copied from interface:EncoderEncodes the specified source object to some binary representation and writes the result to the specified destination.- Specified by:
encodein interfaceEncoder<StringBuilder>- Parameters:
source- the object to encode.destination- holds the ByteBuffer to write into.
-