public class ContinualMessage extends Object implements io.continual.util.data.json.JsonSerialized
| Modifier and Type | Class and Description |
|---|---|
static class |
ContinualMessage.Builder |
static class |
ContinualMessage.MetadataSectionBuilder |
| Constructor and Description |
|---|
ContinualMessage(org.json.JSONObject data)
Construct a message from JSON data
|
ContinualMessage(org.json.JSONObject data,
org.json.JSONObject meta)
Construct a message from JSON data
|
| Modifier and Type | Method and Description |
|---|---|
static ContinualMessage.Builder |
builder()
Construct a builder for a message
|
boolean |
equals(Object that) |
static ContinualMessage |
fromSerializedString(String jsonString)
Instantiate a message from a serialized string (normally from toString())
|
org.json.JSONObject |
getMessagePayload()
return a copy of this message's data without the metadata structure
|
int |
hashCode() |
org.json.JSONObject |
toJson() |
String |
toString() |
public ContinualMessage(org.json.JSONObject data)
data - if null, an empty JSON document is used. If this contains our standard metadata tag, that part is overwrittenpublic ContinualMessage(org.json.JSONObject data,
org.json.JSONObject meta)
data - if null, an empty JSON document is used. If this contains our standard metadata tag, that part is overwrittenmeta - a metadata structure. If null, an empty JSON document is used.public static ContinualMessage.Builder builder()
public static ContinualMessage fromSerializedString(String jsonString)
jsonString - public org.json.JSONObject toJson()
toJson in interface io.continual.util.data.json.JsonSerializedpublic org.json.JSONObject getMessagePayload()
Copyright © 2023 continual.io. All rights reserved.