public class JacksonJSONContextServer extends JacksonJSONContext<ServerMessage.Mutable,ServerMessageImpl> implements JSONContextServer
JacksonJSONContext.ObjectMapperGenerator
JSONContext.AsyncParser, JSONContext.Client, JSONContext.Generator, JSONContext.Parser
Constructor and Description |
---|
JacksonJSONContextServer() |
Modifier and Type | Method and Description |
---|---|
String |
generate(ServerMessage.Mutable message)
Converts a single message to a JSON string.
|
JSONContext.Generator |
getGenerator() |
protected Class<ServerMessageImpl[]> |
rootArrayClass() |
generate, getObjectMapper, getParser, newAsyncParser, parse, parse, parse
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
generate, getParser, newAsyncParser, parse, parse, parse
protected Class<ServerMessageImpl[]> rootArrayClass()
rootArrayClass
in class JacksonJSONContext<ServerMessage.Mutable,ServerMessageImpl>
public String generate(ServerMessage.Mutable message)
JSONContext
Converts a single message to a JSON string.
generate
in interface JSONContext<ServerMessage.Mutable>
generate
in interface JSONContextServer
generate
in class JacksonJSONContext<ServerMessage.Mutable,ServerMessageImpl>
message
- the message to stringifypublic JSONContext.Generator getGenerator()
getGenerator
in interface JSONContext<ServerMessage.Mutable>
getGenerator
in class JacksonJSONContext<ServerMessage.Mutable,ServerMessageImpl>
Copyright © 2008–2024 The CometD Project. All rights reserved.