X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=include%2Ftypedefs.h;h=8a7b591590b6a3949ef657b01e124eb16e603b27;hb=c05f81cac83e80c7727594e3929e0709eccca689;hp=85d86504f032af6d0a8fcd275e6e54da57006cbf;hpb=046da7da9bf57ac9254f76fd1c43eadf1673cdf5;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/include/typedefs.h b/include/typedefs.h index 85d86504f..8a7b59159 100644 --- a/include/typedefs.h +++ b/include/typedefs.h @@ -1,9 +1,12 @@ /* * InspIRCd -- Internet Relay Chat Daemon * - * Copyright (C) 2009 Daniel De Graaf - * Copyright (C) 2005, 2008 Craig Edwards + * Copyright (C) 2013, 2016, 2018, 2020 Sadie Powell + * Copyright (C) 2012-2014, 2016, 2018 Attila Molnar + * Copyright (C) 2012 Robby + * Copyright (C) 2009-2010 Daniel De Graaf * Copyright (C) 2007 Dennis Friis + * Copyright (C) 2005, 2010 Craig Edwards * * This file is part of InspIRCd. InspIRCd is free software: you can * redistribute it and/or modify it under the terms of the GNU General Public @@ -31,6 +34,7 @@ class Extensible; class FakeUser; class InspIRCd; class Invitation; +class IOHookProvider; class LocalUser; class Membership; class Module; @@ -46,7 +50,36 @@ class XLine; class XLineManager; class XLineFactory; struct ConnectClass; -struct ModResult; +class ModResult; + +namespace ClientProtocol +{ + class Event; + class EventProvider; + class Message; + class MessageTagEvent; + class MessageTagProvider; + class Serializer; + + typedef std::vector MessageList; + typedef std::vector ParamList; + typedef std::string SerializedMessage; + + struct MessageTagData + { + MessageTagProvider* tagprov; + std::string value; + void* provdata; + + MessageTagData(MessageTagProvider* prov, const std::string& val, void* data = NULL); + }; + + /** Map of message tag values and providers keyed by their name. + * Sorted in descending order to ensure tag names beginning with symbols (such as '+') come later when iterating + * the container than tags with a normal name. + */ + typedef insp::flat_map > TagMap; +} #include "hashcomp.h" #include "base.h" @@ -54,13 +87,6 @@ struct ModResult; typedef TR1NS::unordered_map user_hash; typedef TR1NS::unordered_map chan_hash; -/** A list holding local users, this is the type of UserManager::local_users - */ -typedef intrusive_list LocalUserList; - -/** A list of failed port bindings, used for informational purposes on startup */ -typedef std::vector > FailedPortList; - /** List of channels to consider when building the neighbor list of a user */ typedef std::vector IncludeChanList; @@ -69,32 +95,25 @@ typedef std::vector IncludeChanList; */ typedef std::vector file_cache; -/** A configuration key and value pair +/** A mapping of configuration keys to their assigned values. */ -typedef std::pair KeyVal; +typedef insp::flat_map ConfigItems; /** The entire configuration */ -typedef std::multimap > ConfigDataHash; +typedef std::multimap, irc::insensitive_swo> ConfigDataHash; /** Iterator of ConfigDataHash */ typedef ConfigDataHash::const_iterator ConfigIter; /** Iterator pair, used for tag-name ranges */ typedef std::pair ConfigTagList; -/** Index of valid oper blocks and types */ -typedef std::map > OperIndex; - /** Files read by the configuration */ typedef std::map ConfigFileCache; /** Generic user list, used for exceptions */ typedef std::set CUList; -/** A set of strings. - */ -typedef std::vector string_list; - /** Contains an ident and host split into two strings */ typedef std::pair IdentHostPair; @@ -105,7 +124,7 @@ typedef std::map XLineFactMap; /** A map of XLines indexed by string */ -typedef std::map XLineLookup; +typedef std::map XLineLookup; /** A map of XLineLookup maps indexed by string */ @@ -115,6 +134,11 @@ typedef std::map XLineContainer; */ typedef XLineContainer::iterator ContainerIter; -/** An interator in an XLineLookup +/** An iterator in an XLineLookup */ typedef XLineLookup::iterator LookupIter; + +namespace Stats +{ + class Context; +}