Anope IRC Services  Version 2.0
Public Member Functions | Data Fields
ChannelModeParam Class Reference

#include <modes.h>

Inheritance diagram for ChannelModeParam:
Inheritance graph
Collaboration diagram for ChannelModeParam:
Collaboration graph

Public Member Functions

 ChannelModeParam (const Anope::string &name, char mc, bool minus_no_arg=false)
virtual bool IsValid (Anope::string &value) const
- Public Member Functions inherited from ChannelMode
 ChannelMode (const Anope::string &name, char mc)
bool CanSet (User *u) const anope_override
virtual ChannelModeWrap (Anope::string &param)
ChannelModeUnwrap (Anope::string &param)
virtual ChannelModeUnwrap (ChannelMode *, Anope::string &param)
- Public Member Functions inherited from Mode
 Mode (const Anope::string &mname, ModeClass mclass, char mc, ModeType type)
virtual ~Mode ()
- Public Member Functions inherited from Base
 Base ()
virtual ~Base ()
void AddReference (ReferenceBase *r)
void DelReference (ReferenceBase *r)

Data Fields

bool minus_no_arg
- Data Fields inherited from ChannelMode
std::vector< ChannelMode * > listeners
- Data Fields inherited from Mode
Anope::string name
ModeClass mclass
char mchar
ModeType type

Detailed Description

This is a mode with a paramater, eg +k/l. These modes should use/inherit from this

Definition at line 163 of file modes.h.

Constructor & Destructor Documentation

◆ ChannelModeParam()

ChannelModeParam::ChannelModeParam ( const Anope::string name,
char  mc,
bool  minus_no_arg = false 


nameThe mode name
mcThe mode char
minus_no_argtrue if this mode sends no arg when unsetting

Definition at line 185 of file modes.cpp.

References MODE_PARAM, and Mode::type.

Referenced by ProtoBahamut::AddModes().

Member Function Documentation

◆ IsValid()

virtual bool ChannelModeParam::IsValid ( Anope::string value) const

Is the param valid

valueThe param
true for yes, false for no

Reimplemented in ChannelModeFlood, ChannelModeRedirect, ChannelModeHistory, ChannelModeFlood, SimpleNumberParamMode, ChannelModeKey, ColonDelimitedParamMode, ChannelModeFlood, and ChannelModeFlood.

Definition at line 180 of file modes.h.

Referenced by ChannelModeKey::ChannelModeKey(), OSDefcon::ParseModeString(), and Channel::SetMode().

Field Documentation

◆ minus_no_arg

bool ChannelModeParam::minus_no_arg

Definition at line 174 of file modes.h.

Referenced by Channel::GetModes(), Channel::RemoveMode(), and Channel::SetModesInternal().

The documentation for this class was generated from the following files: