xst_cwstring& CCfgFile::GetValue(xst_cwstring& strKey, xst_cwstring& strSection, xst_cwstring& strDefault)
	{
		CSection* pSec = _GetSection( strSection );
		if( pSec == xst_null )
		{
			return strDefault;
		}

		return pSec->GetValue( strKey, strDefault );
	}
Ejemplo n.º 2
0
string INIFile::GetValueString(const string section, const string key)
{
  CSection* pSection = GetSection(section);
  string val;

  if ( pSection )
  {
    val = pSection->GetValue(key);
  }

  return val;
}
Ejemplo n.º 3
0
short INIFile::GetValueShort(const string section, const string key)
{
  CSection* pSection = GetSection(section);
  short sRet = 0;
  string val;

  if ( pSection )
  {
    val = pSection->GetValue(key);
    sRet = (short)atoi(val.c_str());
  }

  return sRet;
}