Class MementoMessage
- java.lang.Object
-
- org.apache.logging.log4j.core.impl.MementoMessage
-
- All Implemented Interfaces:
Serializable,Message,StringBuilderFormattable
public final class MementoMessage extends Object implements Message, StringBuilderFormattable
Consider this class private.MementoMessageis intended to be used when we need to make an immutable copy of aMessagewithout forgetting the originalMessage.getFormat()andMessage.getParameters()values.- Since:
- 3.0
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description MementoMessage(String formattedMessage, String format, Object[] parameters)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidformatTo(StringBuilder buffer)StringgetFormat()StringgetFormattedMessage()Object[]getParameters()ThrowablegetThrowable()Always returns null.StringtoString()
-
-
-
Method Detail
-
getFormattedMessage
public String getFormattedMessage()
- Specified by:
getFormattedMessagein interfaceMessage
-
getParameters
public Object[] getParameters()
- Specified by:
getParametersin interfaceMessage
-
getThrowable
public Throwable getThrowable()
Always returns null.- Specified by:
getThrowablein interfaceMessage- Returns:
- null
-
formatTo
public void formatTo(StringBuilder buffer)
- Specified by:
formatToin interfaceStringBuilderFormattable
-
-