From da83f54606c9c1d2786d87074ee17ed972d2e1b2 Mon Sep 17 00:00:00 2001 From: jwijenbergh Date: Wed, 14 Sep 2022 13:56:49 +0200 Subject: Refactor: Return without json --- exports/c/servers.h | 43 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) create mode 100644 exports/c/servers.h (limited to 'exports/c/servers.h') diff --git a/exports/c/servers.h b/exports/c/servers.h new file mode 100644 index 0000000..39e52a2 --- /dev/null +++ b/exports/c/servers.h @@ -0,0 +1,43 @@ +// for size_t +#include + +// The struct for a single server profile +typedef struct serverProfile { + const char* id; + const char* display_name; + //const char* proto_list; + int default_gateway; +} serverProfile; + +// The struct for all server profiles +typedef struct serverProfiles { + int current; + serverProfile** profiles; + size_t total_profiles; +} serverProfiles; + +// The struct for server locations +typedef struct serverLocations { + const char** locations; + size_t total_locations; +} serverLocations; + +// The struct for a single server +typedef struct server { + const char* identifier; + const char* display_name; + const char* country_code; + const char** support_contact; + size_t total_support_contact; + serverProfiles* profiles; + unsigned long long int expire_time; +} server; + +// The struct for all servers +typedef struct servers { + server** custom_servers; + size_t total_custom; + server** institute_servers; + size_t total_institute; + server* secure_internet_server; +} servers; -- cgit v1.2.3