ascii-chat 0.6.0
Real-time terminal-based video chat with ASCII art conversion
Loading...
Searching...
No Matches
discovery_result_t Struct Reference

Result from session discovery. More...

#include <lib/network/mdns/discovery.h>

Public Types

enum  { DISCOVERY_SOURCE_MDNS = 0 , DISCOVERY_SOURCE_ACDS = 1 }
 

Data Fields

bool success
 Discovery succeeded.
 
uint8_t host_pubkey [32]
 Ed25519 public key of discovered server.
 
char server_address [256]
 Server IP or hostname.
 
uint16_t server_port
 Server port (typically 27224)
 
enum discovery_result_t:: { ... }  source
 Which discovery method found the server.
 
char mdns_service_name [256]
 mDNS service instance name (e.g., "swift-river-mountain")
 
char mdns_hostname [256]
 mDNS hostname (e.g., "mycomputer.local")
 
uint8_t session_id [16]
 ACDS session UUID.
 
uint8_t participant_id [16]
 Assigned participant ID (from SESSION_JOIN)
 
asciichat_error_t error
 Error code if !success.
 
char error_message [256]
 Human-readable error (if !success)
 

Detailed Description

Result from session discovery.

Returned by discover_session_parallel() with connection info for the discovered server.

Definition at line 85 of file discovery.h.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
Enumerator
DISCOVERY_SOURCE_MDNS 

Found via mDNS (local LAN)

DISCOVERY_SOURCE_ACDS 

Found via ACDS (internet)

Definition at line 90 of file discovery.h.

90 {
93 } source;
@ DISCOVERY_SOURCE_ACDS
Found via ACDS (internet)
Definition discovery.h:92
@ DISCOVERY_SOURCE_MDNS
Found via mDNS (local LAN)
Definition discovery.h:91
enum discovery_result_t::@3 source
Which discovery method found the server.

Field Documentation

◆ error

asciichat_error_t discovery_result_t::error

Error code if !success.

Definition at line 104 of file discovery.h.

◆ error_message

char discovery_result_t::error_message[256]

Human-readable error (if !success)

Definition at line 105 of file discovery.h.

◆ host_pubkey

uint8_t discovery_result_t::host_pubkey[32]

Ed25519 public key of discovered server.

Definition at line 87 of file discovery.h.

◆ mdns_hostname

char discovery_result_t::mdns_hostname[256]

mDNS hostname (e.g., "mycomputer.local")

Definition at line 97 of file discovery.h.

◆ mdns_service_name

char discovery_result_t::mdns_service_name[256]

mDNS service instance name (e.g., "swift-river-mountain")

Definition at line 96 of file discovery.h.

◆ participant_id

uint8_t discovery_result_t::participant_id[16]

Assigned participant ID (from SESSION_JOIN)

Definition at line 101 of file discovery.h.

Referenced by client_main().

◆ server_address

char discovery_result_t::server_address[256]

Server IP or hostname.

Definition at line 88 of file discovery.h.

Referenced by client_main().

◆ server_port

uint16_t discovery_result_t::server_port

Server port (typically 27224)

Definition at line 89 of file discovery.h.

Referenced by client_main().

◆ session_id

uint8_t discovery_result_t::session_id[16]

ACDS session UUID.

Definition at line 100 of file discovery.h.

Referenced by client_main().

◆ []

enum { ... } discovery_result_t::source

Which discovery method found the server.

Referenced by client_main(), and discover_session_parallel().

◆ success

bool discovery_result_t::success

Discovery succeeded.

Definition at line 86 of file discovery.h.

Referenced by client_main(), and discover_session_parallel().


The documentation for this struct was generated from the following file: