summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authordanieldg <danieldg@e03df62e-2008-0410-955e-edbf42e46eb7>2009-09-02 00:44:59 +0000
committerdanieldg <danieldg@e03df62e-2008-0410-955e-edbf42e46eb7>2009-09-02 00:44:59 +0000
commitb5e220008782b2d538cb8e6e3b1923af0c13fb99 (patch)
treebc12a82756900877f417bc2234bc10a69c6fff96 /include
parent8cebe2878f3878afce6f643d93668155cb26801d (diff)
Allow commands to optionally route themselves using ENCAP
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11602 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'include')
-rw-r--r--include/ctables.h11
1 files changed, 10 insertions, 1 deletions
diff --git a/include/ctables.h b/include/ctables.h
index b07d3f4e0..a543b7e37 100644
--- a/include/ctables.h
+++ b/include/ctables.h
@@ -41,7 +41,9 @@ enum RouteType
{
ROUTE_TYPE_LOCALONLY,
ROUTE_TYPE_BROADCAST,
- ROUTE_TYPE_UNICAST
+ ROUTE_TYPE_UNICAST,
+ ROUTE_TYPE_OPT_BCAST,
+ ROUTE_TYPE_OPT_UCAST
};
struct RouteDescriptor
@@ -54,9 +56,16 @@ struct RouteDescriptor
: type(t), serverdest(d) { }
};
+/** Do not route this command */
#define ROUTE_LOCALONLY (RouteDescriptor(ROUTE_TYPE_LOCALONLY, ""))
+/** Route this command to all servers, fail if not understood */
#define ROUTE_BROADCAST (RouteDescriptor(ROUTE_TYPE_BROADCAST, ""))
+/** Route this command to a single server (do nothing if own server name specified) */
#define ROUTE_UNICAST(x) (RouteDescriptor(ROUTE_TYPE_UNICAST, x))
+/** Route this command to all servers, ignore if not understood */
+#define ROUTE_OPT_BCAST (RouteDescriptor(ROUTE_TYPE_OPT_BCAST, ""))
+/** Route this command to a single server, ignore if not understood */
+#define ROUTE_OPT_UCAST(x) (RouteDescriptor(ROUTE_TYPE_OPT_UCAST, x))
/** A structure that defines a command. Every command available
* in InspIRCd must be defined as derived from Command.