summaryrefslogtreecommitdiff
path: root/include/services.h
diff options
context:
space:
mode:
authorcyberbotx <cyberbotx@5417fbe8-f217-4b02-8779-1006273d7864>2008-11-16 19:31:31 +0000
committercyberbotx <cyberbotx@5417fbe8-f217-4b02-8779-1006273d7864>2008-11-16 19:31:31 +0000
commitffbcff160474cd45fbcbbadaff32f38e1d7fea71 (patch)
tree4155ce7bb17b63cc1bdf40a99a89c1b34a66aef2 /include/services.h
parent72a4c7e6c7a4187bfee58bdbf3c235f2b0ae44c7 (diff)
Added support for multiple uplink blocks in the new config.
Moved the type and id directives from the uplink block to the serverinfo block. Small config fixes. git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@1746 5417fbe8-f217-4b02-8779-1006273d7864
Diffstat (limited to 'include/services.h')
-rw-r--r--include/services.h28
1 files changed, 24 insertions, 4 deletions
diff --git a/include/services.h b/include/services.h
index ba04d873a..8ba6db085 100644
--- a/include/services.h
+++ b/include/services.h
@@ -229,6 +229,7 @@ extern int strncasecmp(const char *, const char *, size_t);
#include <string>
#include <map>
#include <exception>
+#include <list>
/** This class can be used on its own to represent an exception, or derived to represent a module-specific exception.
* When a module whishes to abort, e.g. within a constructor, it should throw an exception using ModuleException or
@@ -351,7 +352,7 @@ class Extensible
* @return Returns true on success.
*/
bool Shrink(const std::string &key);
-
+
/** Get an extension item.
*
* @param key The key parameter is an arbitary string which identifies the extension data
@@ -372,12 +373,12 @@ class Extensible
return false;
}
}
-
+
/** Get an extension item.
*
* @param key The key parameter is an arbitary string which identifies the extension data
* @return Returns true if the item was found and false if it was not.
- *
+ *
* This single-parameter version only checks if the key exists, it does nothing with
* the 'data' field and is probably only useful in conjunction with the single-parameter
* version of Extend().
@@ -1249,11 +1250,11 @@ struct capabinfo_ {
/*************************************************************************/
-
/*
* Forward declaration reqired, because the base IRCDProto class uses some crap from in here.
*/
class IRCDProto;
+struct Uplink;
#include "extern.h"
class IRCDProto {
@@ -1517,4 +1518,23 @@ class IRCDTS6Proto : public IRCDProto
/*************************************************************************/
+struct Uplink {
+ char *host;
+ int port;
+ char *password;
+ Uplink(const char *_host, int _port, const char *_password)
+ {
+ host = sstrdup(_host);
+ port = _port;
+ password = sstrdup(_password);
+ }
+ ~Uplink()
+ {
+ free(host);
+ free(password);
+ }
+};
+
+/*************************************************************************/
+
#endif /* SERVICES_H */