GNUnet 0.21.1
gnu_name_system_service_ports.h File Reference

Go to the source code of this file.

Data Structures

struct  GNUNET_GNS_ServicePort
 WARNING: This header is generated! In order to add GNS service ports, you must register them in GANA, and then use the header generation script to create an update of this file. More...
 

Functions

uint16_t GNUNET_GNS_service_port_name_to_number (const char *name)
 
const char * GNUNET_GNS_service_port_number_to_name (uint16_t port)
 

Variables

struct GNUNET_GNS_ServicePort GNUNET_GNS_ServicePorts []
 

Function Documentation

◆ GNUNET_GNS_service_port_name_to_number()

uint16_t GNUNET_GNS_service_port_name_to_number ( const char *  name)

Definition at line 70 of file gnu_name_system_service_ports.h.

71{
72 int i = 0;
73 while (NULL != GNUNET_GNS_ServicePorts[i].name)
74 {
75 if (0 == strcmp (name, GNUNET_GNS_ServicePorts[i].name))
77 i++;
78 }
79 return 0;
80}
static char * name
Name (label) of the records to list.
struct GNUNET_GNS_ServicePort GNUNET_GNS_ServicePorts[]

References GNUNET_GNS_ServicePorts, name, and GNUNET_GNS_ServicePort::port.

◆ GNUNET_GNS_service_port_number_to_name()

const char * GNUNET_GNS_service_port_number_to_name ( uint16_t  port)

Definition at line 84 of file gnu_name_system_service_ports.h.

85{
86 int i = 0;
87 while (NULL != GNUNET_GNS_ServicePorts[i].name)
88 {
91 i++;
92 }
93 return NULL;
94}
static uint16_t port
Port number.
Definition: gnunet-bcd.c:147

References GNUNET_GNS_ServicePorts, name, GNUNET_GNS_ServicePort::name, and port.

Variable Documentation

◆ GNUNET_GNS_ServicePorts

struct GNUNET_GNS_ServicePort GNUNET_GNS_ServicePorts[]
Initial value:
= {
{
.name = "scheme",
.port = 49152
},
{
.name = "translation",
.port = 49153
},
{
.name = NULL,
.port = 0
}
}

Definition at line 46 of file gnu_name_system_service_ports.h.