DittoConnection

data class DittoConnection

Represents a connection between two peers in a Ditto mesh network.

Constructors

Link copied to clipboard
constructor(id: String, peer1: DittoPeerKey, peer2: DittoPeerKey, connectionType: DittoConnectionType, approximateDistanceInMeters: Double?)
constructor(id: String, peerKeyString1: String, peerKeyString2: String, connectionType: DittoConnectionType, approximateDistanceInMeters: Double?)

Properties

Link copied to clipboard

Gets an estimate of distance to the remote peer. This value is inaccurate. The environment, hardware, and several other factors can greatly affect this value. It is currently derived from RSSI.

Link copied to clipboard

Type of transport enabling this connection.

Link copied to clipboard

This ID is deterministic for any two peers and a given connection type.

Link copied to clipboard

The peer key of one end of the connection.

Link copied to clipboard

The peer key of the other end of the connection.

Link copied to clipboard

The peer key of the peer at one end of the connection, as a string.

Link copied to clipboard

The peer key of the peer at the other end of the connection, as a string.

Functions

Link copied to clipboard
open operator override fun equals(other: Any?): Boolean
Link copied to clipboard
open override fun hashCode(): Int