NostrWebSocketsService class

A service that manages the relays web sockets connections

Constructors

NostrWebSocketsService({required NostrClientUtils utils})
A service that manages the relays web sockets connections

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
utils NostrClientUtils
final

Methods

connectRelay({required String relay, bool? shouldIgnoreConnectionException, void onConnectionSuccess(WebSocketChannel webSocket)?}) Future<void>
Connects to a relay web socket, and trigger the onConnectionSuccess callback if the connection is successful, or the onConnectionError callback if the connection fails.
getHttpUrlFromWebSocketUrl(String relayUrl) Uri
Changes the protocol of a websocket url to http.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
set(Duration newDur) → void
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited