* @param target Target string.
* @param text Privmsg text, will be copied.
* @param mt Message type.
+ * @param status Prefix character for status messages. If non-zero the message is a status message. Optional, defaults to 0.
*/
Privmsg(const std::string& source, const std::string& target, const std::string& text, MessageType mt = MSG_PRIVMSG, char status = 0)
: ClientProtocol::Message(CommandStrFromMsgType(mt), source)
* @param maxpara The maximum number of parameters that the command accepts.
*/
Command(Module* me, const std::string& cmd, unsigned int minpara = 0, unsigned int maxpara = 0);
-
+
public:
/** Unregisters this command from the command parser. */
~Command() CXX11_OVERRIDE;
SplitCommand(Module* me, const std::string& cmd, unsigned int minpara = 0, unsigned int maxpara = 0);
public:
- /** @copydoc Commmand::Handle */
+ /** @copydoc Command::Handle */
CmdResult Handle(User* user, const Params& parameters) CXX11_OVERRIDE;
/** Handle the command from a local user.
/** Initializes an instance of the ExtensionItem class.
* @param key The name of the extension item (e.g. ssl_cert).
* @param exttype The type of Extensible that this ExtensionItem applies to.
- * @param owner The module which created this ExtensionItem
+ * @param owner The module which created this ExtensionItem.
*/
ExtensionItem(const std::string& key, ExtensibleType exttype, Module* owner);
*/
void FreeAllExtItems();
- /** @copydoc Serializable::Deserialize. */
+ /** @copydoc Serializable::Deserialize */
bool Deserialize(Data& data) CXX11_OVERRIDE;
- /** @copydoc Serializable::Deserialize. */
+ /** @copydoc Serializable::Deserialize */
bool Serialize(Serializable::Data& data) CXX11_OVERRIDE;
};
/** Called before a server shuts down.
* @param reason The reason the server is shutting down.
- * @param restart Whether the server is restarting.
*/
virtual void OnShutdown(const std::string& reason);
};
* message, or MOD_RES_PASSTHRU to let another module handle the event.
*/
virtual ModResult OnUserPreTagMessage(User* user, const MessageTarget& target, TagMessageDetails& details) { return MOD_RES_PASSTHRU; }
-
+
/** Called immediately after a user sends a tag message to a channel, a user, or a server glob mask.
* @param user The user sending the message.
* @param target The target of the message. This can either be a channel, a user, or a server
/** Stores the serialised data against the specified key.
* @param key The key by which this serialised data should be stored against.
- * @param out The serialised data to store.
+ * @param value The serialised data to store.
*/
Data& Store(const std::string& key, const Data& value);
/** Stores the value against the specified key.
* @param key The key by which this value should be stored against.
- * @param out The value to store.
+ * @param value The value to store.
*/
Data& Store(const std::string& key, const std::string& value);
/** Stores the value against the specified key. The value will be converted to a string using ConvToStr.
* @param key The key by which this value should be stored against.
- * @param out The value to store.
+ * @param value The value to store.
*/
template <typename T>
Data& Store(const std::string& key, const T& value)
/** Represents information about a failed port binding. */
struct CoreExport FailedPort
{
-
/** The error which happened during binding. */
int error;
virtual ~User();
CullResult cull() CXX11_OVERRIDE;
- /** @copydoc Serializable::Deserialize. */
+ /** @copydoc Serializable::Deserialize */
bool Deserialize(Data& data) CXX11_OVERRIDE;
- /** @copydoc Serializable::Deserialize. */
+ /** @copydoc Serializable::Deserialize */
bool Serialize(Serializable::Data& data) CXX11_OVERRIDE;
};
*/
void Send(ClientProtocol::EventProvider& protoevprov, ClientProtocol::Message& msg);
- /** @copydoc Serializable::Deserialize. */
+ /** @copydoc Serializable::Deserialize */
bool Deserialize(Data& data) CXX11_OVERRIDE;
- /** @copydoc Serializable::Deserialize. */
+ /** @copydoc Serializable::Deserialize */
bool Serialize(Serializable::Data& data) CXX11_OVERRIDE;
};
std::string LocalStringExt::ToInternal(const Extensible* container, void* item) const
{
- return item ? *static_cast<std::string*>(item) : std::string();
+ return item ? *static_cast<std::string*>(item) : std::string();
}
void LocalStringExt::FromInternal(Extensible* container, const std::string& value)
if (!FileSystem::GetFileList(includedir, files, "*.conf"))
throw CoreException("Unable to read directory for include: " + includedir);
- std::sort(files.begin(), files.end());
+ std::sort(files.begin(), files.end());
for (std::vector<std::string>::const_iterator iter = files.begin(); iter != files.end(); ++iter)
{
const std::string path = includedir + '/' + *iter;
void OnGarbageCollect() CXX11_OVERRIDE
{
for (LocationMap::iterator iter = geoapi.locations.begin(); iter != geoapi.locations.end(); )
- {
+ {
Geolocation::Location* location = iter->second;
if (location->GetUseCount())
{
/// $PackageInfo: require_system("arch") pcre
/// $PackageInfo: require_system("centos") pcre-devel
-/// $PackageInfo: require_system("darwin") pcre
+/// $PackageInfo: require_system("darwin") pcre
/// $PackageInfo: require_system("debian") libpcre3-dev
/// $PackageInfo: require_system("ubuntu") libpcre3-dev
unsigned char begin = tag->getUInt("begin", tag->getUInt("index", 0), 1, UCHAR_MAX);
if (!begin)
throw ModuleException("<cpchars> tag without index or begin specified at " + tag->getTagLocation());
-
+
unsigned char end = tag->getUInt("end", begin, 1, UCHAR_MAX);
if (begin > end)
throw ModuleException("<cpchars:begin> must be lower than <cpchars:end> at " + tag->getTagLocation());
}
-class ModuleDelayJoin
+class ModuleDelayJoin
: public Module
, public CTCTags::EventListener
, public Names::EventListener
// Check that they haven't been prefixed already.
if (user->ident[0] == '~')
return;
-
+
// All invalid usernames are prefixed with a tilde.
std::string newident(user->ident);
newident.insert(newident.begin(), '~');
{
LocalUser* luser = IS_LOCAL(iter->first);
- // Don't send to remote users or the user who is the source.
+ // Don't send to remote users or the user who is the source.
if (!luser || luser == source)
continue;
// If this fails then the IP sa will be AF_UNSPEC.
irc::sockets::aptosa(x->IPAddr, x->Port, sa);
}
-
+
/* Do we already have an IP? If so, no need to resolve it. */
if (sa.family() != AF_UNSPEC)
{
ServerInstance->Logs->Log("USERS", LOG_DEBUG, "New UUID for user: %s", uuid.c_str());
if (srv->IsULine())
- ServerInstance->Users.all_ulines.push_back(this);
+ ServerInstance->Users.all_ulines.push_back(this);
// Do not insert FakeUsers into the uuidlist so FindUUID() won't return them which is the desired behavior
if (type != USERTYPE_SERVER)