public final class HttpsSingleMessage extends Object implements HttpsMessage
Modifier and Type | Field and Description |
---|---|
protected static String |
CONTENT_ENCODING_KEY |
protected static String |
CONTENT_TYPE_KEY |
protected static String |
CORRELATION_ID_KEY
The property names as they are saved in the system properties of this object
|
protected static String |
MESSAGE_ID_KEY |
protected static String |
TO_KEY |
protected static String |
USER_ID_KEY |
HTTPS_APP_PROPERTY_PREFIX, HTTPS_SYSTEM_PROPERTY_PREFIX
Modifier and Type | Method and Description |
---|---|
byte[] |
getBody()
Returns a copy of the message body.
|
String |
getBodyAsString()
Returns the message body as a string.
|
String |
getContentType()
Returns the message content-type.
|
MessageProperty[] |
getProperties()
Returns a copy of the message properties.
|
Map<String,String> |
getSystemProperties()
Returns a copy of the message system properties.
|
boolean |
isBase64Encoded()
Returns whether the message is Base64-encoded.
|
static HttpsSingleMessage |
parseHttpsJsonMessage(Message message)
Returns the HTTPS message represented by the service-bound message for
application json format.
|
static HttpsSingleMessage |
parseHttpsMessage(HttpsResponse response)
Returns the HTTPS message represented by the HTTPS response.
|
static HttpsSingleMessage |
parseHttpsMessage(Message message)
Returns the HTTPS message represented by the service-bound message for
binary octets.
|
Message |
toMessage()
Returns the Iot Hub message represented by the HTTPS message.
|
protected static final String CORRELATION_ID_KEY
protected static final String MESSAGE_ID_KEY
protected static final String TO_KEY
protected static final String USER_ID_KEY
protected static final String CONTENT_ENCODING_KEY
protected static final String CONTENT_TYPE_KEY
public static HttpsSingleMessage parseHttpsMessage(Message message)
message
- the service-bound message to be mapped to its HTTPS message
equivalent.public static HttpsSingleMessage parseHttpsJsonMessage(Message message)
message
- the service-bound message to be mapped to its HTTPS message
equivalent.public static HttpsSingleMessage parseHttpsMessage(HttpsResponse response)
response
- the HTTPS response.public Message toMessage()
public byte[] getBody()
getBody
in interface HttpsMessage
public String getBodyAsString()
public String getContentType()
getContentType
in interface HttpsMessage
public boolean isBase64Encoded()
public MessageProperty[] getProperties()
getProperties
in interface HttpsMessage
public Map<String,String> getSystemProperties()
getSystemProperties
in interface HttpsMessage
Copyright © 2020. All rights reserved.