Cuberite
A lightweight, fast and extensible game server for Minecraft
Classes | Macros | Functions
IniFile.h File Reference
#include "SettingsRepositoryInterface.h"
Include dependency graph for IniFile.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  cIniFile
 
struct  cIniFile::key
 

Macros

#define MAX_KEYNAME   128
 
#define MAX_VALUEDATA   2048
 
#define MAX_VALUENAME   128
 

Functions

AStringVector ReadUpgradeIniPorts (cSettingsRepositoryInterface &a_Settings, const AString &a_KeyName, const AString &a_PortsValueName, const AString &a_OldIPv4ValueName, const AString &a_OldIPv6ValueName, const AString &a_DefaultValue)
 Reads the list of ports from the INI file, possibly upgrading from IPv4 / IPv6-specific values into new version-agnostic value. More...
 

Macro Definition Documentation

◆ MAX_KEYNAME

#define MAX_KEYNAME   128

Definition at line 23 of file IniFile.h.

◆ MAX_VALUEDATA

#define MAX_VALUEDATA   2048

Definition at line 25 of file IniFile.h.

◆ MAX_VALUENAME

#define MAX_VALUENAME   128

Definition at line 24 of file IniFile.h.

Function Documentation

◆ ReadUpgradeIniPorts()

AStringVector ReadUpgradeIniPorts ( cSettingsRepositoryInterface a_Settings,
const AString a_KeyName,
const AString a_PortsValueName,
const AString a_OldIPv4ValueName,
const AString a_OldIPv6ValueName,
const AString a_DefaultValue 
)

Reads the list of ports from the INI file, possibly upgrading from IPv4 / IPv6-specific values into new version-agnostic value.

Reads the list of ports from a_PortsValueName. If that value doesn't exist or is empty, the list is combined from values in a_OldIPv4ValueName and a_OldIPv6ValueName; in this case the old values are removed from the INI file. If there is none of the three values or they are all empty, the default is used and stored in the Ports value.

Definition at line 923 of file IniFile.cpp.