Package io.sentry.protocol
Class Message
java.lang.Object
io.sentry.protocol.Message
- All Implemented Interfaces:
JsonSerializable,JsonUnknown
A log entry message.
A log message is similar to the `message` attribute on the event itself but can additionally hold optional parameters.
```json { "message": { "message": "My raw message with interpreted strings like %s", "params": ["this"] } } ```
```json { "message": { "message": "My raw message with interpreted strings like {foo}", "params": {"foo": "this"} } } ```
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classstatic final class -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription@Nullable String@Nullable Stringvoidserialize(@NotNull ObjectWriter writer, @NotNull ILogger logger) voidsetFormatted(@Nullable String formatted) Sets a formatted StringvoidsetMessage(@Nullable String message) voidvoidsetUnknown(@Nullable Map<String, Object> unknown)
-
Constructor Details
-
Message
public Message()
-
-
Method Details
-
getFormatted
-
setFormatted
Sets a formatted String- Parameters:
formatted- a formatted String
-
getMessage
-
setMessage
-
getParams
-
setParams
-
serialize
public void serialize(@NotNull @NotNull ObjectWriter writer, @NotNull @NotNull ILogger logger) throws IOException - Specified by:
serializein interfaceJsonSerializable- Throws:
IOException
-
getUnknown
- Specified by:
getUnknownin interfaceJsonUnknown
-
setUnknown
- Specified by:
setUnknownin interfaceJsonUnknown
-