Constificiation.
[gemrb.git] / gemrb / core / SymbolMgr.h
blob08a0df2d0dd0bd634d69cce696ccfd75d8c3d5a9
1 /* GemRB - Infinity Engine Emulator
2 * Copyright (C) 2003 The GemRB Project
4 * This program is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU General Public License
6 * as published by the Free Software Foundation; either version 2
7 * of the License, or (at your option) any later version.
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
14 * You should have received a copy of the GNU General Public License
15 * along with this program; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
21 /**
22 * @file SymbolMgr.h
23 * Declares SymbolMgr class, abstract loader for symbol tables (.IDS files)
24 * @author The GemRB Project
28 #ifndef SYMBOLMGR_H
29 #define SYMBOLMGR_H
31 /** GetValue returns this if text is not found in arrays */
32 #define SYMBOL_VALUE_NOT_LOCATED -65535
34 #include "Plugin.h"
35 #include "DataStream.h"
37 /**
38 * @class SymbolMgr
39 * Abstract loader for symbol tables (.IDS files)
42 class GEM_EXPORT SymbolMgr : public Plugin {
43 public:
44 SymbolMgr(void);
45 virtual ~SymbolMgr(void);
46 virtual bool Open(DataStream* stream, bool autoFree = true) = 0;
47 virtual int GetValue(const char* text) const = 0;
48 virtual char* GetValue(int val) const = 0;
49 virtual char* GetStringIndex(unsigned int Index) const = 0;
50 virtual int GetValueIndex(unsigned int Index) const = 0;
51 virtual int FindValue(int val) const = 0;
52 virtual int FindString(char *str, int len) const = 0;
53 virtual int GetSize() const = 0;
56 #endif // ! SYMBOLMGR_H