class

PlaceOS::Edge::Transport

Inherits Reference < Object

WebSocket Transport

Constants

Log = ::Log.for(self)

Constructors

new(sequence_id : UInt64 = 0, on_disconnect : IO::Error | HTTP::WebSocket::CloseCode -> | Nil = nil, on_connect : Proc(Nil) | Nil = nil, &on_request : Tuple(UInt64, PlaceOS::Edge::Protocol::Request) -> )
Source

Instance methods

closed?
Source
connect(uri : URI, socket : HTTP::WebSocket | Nil)
Source
disconnect
Source
listen(socket : HTTP::WebSocket)
Source
ping(interval : Time::Span = 10.seconds)

Periodically send a ping frame

Source
sequence_id
Source