ServerSentEvent

class ServerSentEvent(val data: String? = null, val event: String? = null, val id: String? = null, val retry: Long? = null, val comments: String? = null)

Server-sent event.

Constructors

Link copied to clipboard
constructor(data: String? = null, event: String? = null, id: String? = null, retry: Long? = null, comments: String? = null)

Properties

Link copied to clipboard
val comments: String? = null

comment lines starting with a ':' character.

Link copied to clipboard
val data: String? = null

data field of the event.

Link copied to clipboard
val event: String? = null

string identifying the type of event.

Link copied to clipboard
val id: String? = null

event ID.

Link copied to clipboard
val retry: Long? = null

reconnection time, in milliseconds to wait before reconnecting.

Functions

Link copied to clipboard
open override fun toString(): String