ScummVM API documentation
databases.h
1
/* ScummVM - Graphic Adventure Engine
2
*
3
* ScummVM is the legal property of its developers, whose names
4
* are too numerous to list here. Please refer to the COPYRIGHT
5
* file distributed with this source distribution.
6
*
7
* This program is free software: you can redistribute it and/or modify
8
* it under the terms of the GNU General Public License as published by
9
* the Free Software Foundation, either version 3 of the License, or
10
* (at your option) any later version.
11
*
12
* This program is distributed in the hope that it will be useful,
13
* but WITHOUT ANY WARRANTY; without even the implied warranty of
14
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15
* GNU General Public License for more details.
16
*
17
* You should have received a copy of the GNU General Public License
18
* along with this program. If not, see <http://www.gnu.org/licenses/>.
19
*
20
*
21
* This file is dual-licensed.
22
* In addition to the GPLv3 license mentioned above, this code is also
23
* licensed under LGPL 2.1. See LICENSES/COPYING.LGPL file for the
24
* full text of the license.
25
*
26
*/
27
28
#ifndef GOB_DATABASES_H
29
#define GOB_DATABASES_H
30
31
#include "common/str.h"
32
#include "common/hashmap.h"
33
#include "common/hash-str.h"
34
#include "common/language.h"
35
36
#include "gob/dbase.h"
37
38
namespace
Gob
{
39
40
class
Databases
{
41
public
:
42
Databases
();
43
~
Databases
();
44
45
void
setLanguage(
Common::Language
language);
46
47
bool
open(
const
Common::String
&
id
,
const
Common::Path
&file);
48
bool
close(
const
Common::String
&
id
);
49
50
bool
getString(
const
Common::String
&
id
,
Common::String
group,
51
Common::String
section,
Common::String
keyword,
Common::String
&result)
const
;
52
53
private
:
54
typedef
Common::HashMap<Common::String, Common::StringMap, Common::IgnoreCase_Hash, Common::IgnoreCase_EqualTo>
DBMap
;
55
56
DBMap _databases;
57
58
Common::String
_language;
59
60
int
findField(
const
dBase
&db,
const
Common::String
&field, dBase::Type type)
const
;
61
bool
buildMap(
const
dBase
&db,
Common::StringMap
&map)
const
;
62
};
63
64
}
// End of namespace Gob
65
66
#endif // GOB_DATABASES_H
Common::String
Definition:
str.h:59
Common::Path
Definition:
path.h:52
Gob::dBase
Definition:
dbase.h:46
Gob
Definition:
anifile.h:40
Common::HashMap< Common::String, Common::StringMap, Common::IgnoreCase_Hash, Common::IgnoreCase_EqualTo >
Gob::Databases
Definition:
databases.h:40
Common::Language
Language
Definition:
language.h:45
engines
gob
databases.h
Generated on Thu Dec 19 2024 09:11:02 for ScummVM API documentation by
1.8.13