void InternalRegister(IConfigVar var) { IConfigVar exists = FindVar(var.GetName().GetHashCode()); if (exists == null) { _configVars.Add(var.GetName().GetHashCode(), var); } }
void InternalSetValue(string name, string value) { IConfigVar var = FindVar(name.GetHashCode()); if (var != null) { object convertedVal = Convert.ChangeType(value, var.GetValueType(), CultureInfo.InvariantCulture); if (convertedVal != null) { var.SetValue(convertedVal); } } }
static public void Register(IConfigVar var) { Init(); _inst.InternalRegister(var); }