InAppImageAttachment

Represents an image attachment.

Represents an image attachment and inherits from InAppFileAttachment.

Properties

PropertiesTypeDescription
id StringThe ID of the attachment.
open override var id: String
sizeLongThe size of the image attachment.
open override var size: Long
urlURLThe URL of the image attachment.
open override var url: URL?
previewBitmapThe preview of the image.
var preview: Bitmap?
contentType StringThe content type of the attachment.
open override var contentType: String

Functions

toJson

Converts the image attachment to a JSONObject.

Syntax: fun toJson(): JSONObject

Return Value: The JSONObject converted from the image attachment.

Companion Functions

fromJson

Converts a JSONObject to an image attachment.

Syntax: fun fromJson(jsonObject: JSONObject): InAppThread

Return Value The image attachment was converted from the JSONObject.

Parameters:

ParametersTypeDescription
jsonObjectJSONObjectThe JSONObject to convert.