]> git.netwichtig.de Git - user/henk/code/inspircd.git/blob - include/typedefs.h
Get rid of a bunch of memory-wasting C-style strings
[user/henk/code/inspircd.git] / include / typedefs.h
1 /*       +------------------------------------+
2  *       | Inspire Internet Relay Chat Daemon |
3  *       +------------------------------------+
4  *
5  *  InspIRCd: (C) 2002-2009 InspIRCd Development Team
6  * See: http://wiki.inspircd.org/Credits
7  *
8  * This program is free but copyrighted software; see
9  *            the file COPYING for details.
10  *
11  * ---------------------------------------------------
12  */
13
14 #ifndef __TYPEDEF_H__
15 #define __TYPEDEF_H__
16
17 #if defined(WINDOWS) && !defined(HASHMAP_DEPRECATED)
18         typedef nspace::hash_map<std::string, User*, nspace::hash_compare<std::string, std::less<std::string> > > user_hash;
19         typedef nspace::hash_map<std::string, Channel*, nspace::hash_compare<std::string, std::less<std::string> > > chan_hash;
20 #else
21         #ifdef HASHMAP_DEPRECATED
22                 typedef nspace::hash_map<std::string, User*, nspace::insensitive, irc::StrHashComp> user_hash;
23                 typedef nspace::hash_map<std::string, Channel*, nspace::insensitive, irc::StrHashComp> chan_hash;
24         #else
25                 typedef nspace::hash_map<std::string, User*, nspace::hash<std::string>, irc::StrHashComp> user_hash;
26                 typedef nspace::hash_map<std::string, Channel*, nspace::hash<std::string>, irc::StrHashComp> chan_hash;
27         #endif
28 #endif
29
30 /** A cached text file stored line by line.
31  */
32 typedef std::deque<std::string> file_cache;
33
34 #endif
35