2 * InspIRCd -- Internet Relay Chat Daemon
4 * Copyright (C) 2014 Attila Molnar <attilamolnar@hush.com>
6 * This file is part of InspIRCd. InspIRCd is free software: you can
7 * redistribute it and/or modify it under the terms of the GNU General Public
8 * License as published by the Free Software Foundation, version 2.
10 * This program is distributed in the hope that it will be useful, but WITHOUT
11 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
12 * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
15 * You should have received a copy of the GNU General Public License
16 * along with this program. If not, see <http://www.gnu.org/licenses/>.
26 void ShowTopic(LocalUser* user, Channel* chan);
36 class CommandInvite : public Command
38 Invite::APIImpl& invapi;
41 /** Constructor for invite.
43 CommandInvite(Module* parent, Invite::APIImpl& invapiimpl);
46 * @param parameters The parameters to the command
47 * @param user The user issuing the command
48 * @return A value from CmdResult to indicate command success or failure.
50 CmdResult Handle(const std::vector<std::string>& parameters, User*user);
51 RouteDescriptor GetRouting(User* user, const std::vector<std::string>& parameters);
56 class CommandJoin : public SplitCommand
59 /** Constructor for join.
61 CommandJoin(Module* parent);
64 * @param parameters The parameters to the command
65 * @param user The user issuing the command
66 * @return A value from CmdResult to indicate command success or failure.
68 CmdResult HandleLocal(const std::vector<std::string>& parameters, LocalUser* user);
73 class CommandTopic : public SplitCommand
75 ChanModeReference secretmode;
76 ChanModeReference topiclockmode;
79 /** Constructor for topic.
81 CommandTopic(Module* parent);
84 * @param parameters The parameters to the command
85 * @param user The user issuing the command
86 * @return A value from CmdResult to indicate command success or failure.
88 CmdResult HandleLocal(const std::vector<std::string>& parameters, LocalUser* user);
93 class CommandNames : public SplitCommand
95 ChanModeReference secretmode;
96 ChanModeReference privatemode;
97 UserModeReference invisiblemode;
100 /** Constructor for names.
102 CommandNames(Module* parent);
105 * @param parameters The parameters to the command
106 * @param user The user issuing the command
107 * @return A value from CmdResult to indicate command success or failure.
109 CmdResult HandleLocal(const std::vector<std::string>& parameters, LocalUser* user);
111 /** Spool the NAMES list for a given channel to the given user
112 * @param user User to spool the NAMES list to
113 * @param chan Channel whose nicklist to send
114 * @param show_invisible True to show invisible (+i) members to the user, false to omit them from the list
116 void SendNames(LocalUser* user, Channel* chan, bool show_invisible);
121 class CommandKick : public Command
124 /** Constructor for kick.
126 CommandKick(Module* parent);
129 * @param parameters The parameters to the command
130 * @param user The user issuing the command
131 * @return A value from CmdResult to indicate command success or failure.
133 CmdResult Handle(const std::vector<std::string>& parameters, User *user);
134 RouteDescriptor GetRouting(User* user, const std::vector<std::string>& parameters);