summaryrefslogtreecommitdiffstats
path: root/src/modules/mask
diff options
context:
space:
mode:
Diffstat (limited to 'src/modules/mask')
-rw-r--r--src/modules/mask/libkvimask.cpp90
1 files changed, 45 insertions, 45 deletions
diff --git a/src/modules/mask/libkvimask.cpp b/src/modules/mask/libkvimask.cpp
index 0c75fc52..03d5c1a9 100644
--- a/src/modules/mask/libkvimask.cpp
+++ b/src/modules/mask/libkvimask.cpp
@@ -28,140 +28,140 @@
#include "kvi_ircmask.h"
/*
- @doc: tqmask.match
+ @doc: mask.match
@type:
function
@title:
- $tqmask.match
+ $mask.match
@short:
- Matches a tqmask agains a wildcarded one
+ Matches a mask agains a wildcarded one
@syntax:
- <boolean> $tqmask.match(<wildcard_tqmask:string>,<fixed_tqmask:string>)
+ <boolean> $mask.match(<wildcard_mask:string>,<fixed_mask:string>)
@description:
- Returns 1 if the <wildcard_tqmask> matches <fixed_tqmask> and 0 otherwise.
- <wildcard_tqmask> can obviously contain wildcards ('*' and '?').
+ Returns 1 if the <wildcard_mask> matches <fixed_mask> and 0 otherwise.
+ <wildcard_mask> can obviously contain wildcards ('*' and '?').
@example:
[example]
- [cmd]if[/cmd]($tqmask.match(*!*@*.linux.it,$0))
- [cmd]op[/cmd] [fnc]$tqmask.nick[/fnc]($0)
+ [cmd]if[/cmd]($mask.match(*!*@*.linux.it,$0))
+ [cmd]op[/cmd] [fnc]$mask.nick[/fnc]($0)
[/example]
*/
static bool mask_kvs_fnc_match(KviKvsModuleFunctionCall * c)
{
- TQString wildtqmask,fixedtqmask;
+ TQString wildmask,fixedmask;
KVSM_PARAMETERS_BEGIN(c)
- KVSM_PARAMETER("wildcard tqmask",KVS_PT_STRING,0,wildtqmask)
- KVSM_PARAMETER("fixed tqmask",KVS_PT_STRING,0,fixedtqmask)
+ KVSM_PARAMETER("wildcard mask",KVS_PT_STRING,0,wildmask)
+ KVSM_PARAMETER("fixed mask",KVS_PT_STRING,0,fixedmask)
KVSM_PARAMETERS_END(c)
- KviIrcMask mk1(wildtqmask);
- KviIrcMask mk2(fixedtqmask);
+ KviIrcMask mk1(wildmask);
+ KviIrcMask mk2(fixedmask);
c->returnValue()->setBoolean(mk1.matchesFixed(mk2.nick(),mk2.user(),mk2.host()));
return true;
}
/*
- @doc: tqmask.nick
+ @doc: mask.nick
@type:
function
@title:
- $tqmask.nick
+ $mask.nick
@short:
- Returns the nick part of an IRC tqmask
+ Returns the nick part of an IRC mask
@syntax:
- <string> $tqmask.nick(<tqmask:string>)
+ <string> $mask.nick(<mask:string>)
@description:
- Returns the nickname part of an IRC tqmask.
+ Returns the nickname part of an IRC mask.
*/
static bool mask_kvs_fnc_nick(KviKvsModuleFunctionCall * c)
{
- TQString tqmask;
+ TQString mask;
KVSM_PARAMETERS_BEGIN(c)
- KVSM_PARAMETER("tqmask",KVS_PT_STRING,0,tqmask)
+ KVSM_PARAMETER("mask",KVS_PT_STRING,0,mask)
KVSM_PARAMETERS_END(c)
- KviIrcMask mk(tqmask);
+ KviIrcMask mk(mask);
c->returnValue()->setString(mk.nick());
return true;
}
/*
- @doc: tqmask.user
+ @doc: mask.user
@type:
function
@title:
- $tqmask.user
+ $mask.user
@short:
- Returns the username part of an IRC tqmask
+ Returns the username part of an IRC mask
@syntax:
- <string> $tqmask.user(<tqmask:string>)
+ <string> $mask.user(<mask:string>)
@description:
- Returns the username part of an IRC tqmask.
+ Returns the username part of an IRC mask.
*/
static bool mask_kvs_fnc_user(KviKvsModuleFunctionCall * c)
{
- TQString tqmask;
+ TQString mask;
KVSM_PARAMETERS_BEGIN(c)
- KVSM_PARAMETER("tqmask",KVS_PT_STRING,0,tqmask)
+ KVSM_PARAMETER("mask",KVS_PT_STRING,0,mask)
KVSM_PARAMETERS_END(c)
- KviIrcMask mk(tqmask);
+ KviIrcMask mk(mask);
c->returnValue()->setString(mk.user());
return true;
}
/*
- @doc: tqmask.host
+ @doc: mask.host
@type:
function
@title:
- $tqmask.host
+ $mask.host
@short:
- Returns the hostname part of an IRC tqmask
+ Returns the hostname part of an IRC mask
@syntax:
- <string> $tqmask.host(<tqmask:string>)
+ <string> $mask.host(<mask:string>)
@description:
- Returns the hostname part of an IRC tqmask.
+ Returns the hostname part of an IRC mask.
*/
static bool mask_kvs_fnc_host(KviKvsModuleFunctionCall * c)
{
- TQString tqmask;
+ TQString mask;
KVSM_PARAMETERS_BEGIN(c)
- KVSM_PARAMETER("tqmask",KVS_PT_STRING,0,tqmask)
+ KVSM_PARAMETER("mask",KVS_PT_STRING,0,mask)
KVSM_PARAMETERS_END(c)
- KviIrcMask mk(tqmask);
+ KviIrcMask mk(mask);
c->returnValue()->setString(mk.host());
return true;
}
/*
- @doc: tqmask.hasnumerichost
+ @doc: mask.hasnumerichost
@type:
function
@title:
- $tqmask.hasNumericHost
+ $mask.hasNumericHost
@short:
- Checks if a host part of a tqmask is numeric
+ Checks if a host part of a mask is numeric
@syntax:
- <boolean> $tqmask.hasNumericHost(<tqmask: string>)
+ <boolean> $mask.hasNumericHost(<mask: string>)
@description:
- Returns 1 if the hostname part of the tqmask is numeric (e.g : unresolved IPV4 or IPV6 address)
+ Returns 1 if the hostname part of the mask is numeric (e.g : unresolved IPV4 or IPV6 address)
*/
static bool mask_kvs_fnc_hasnumerichost(KviKvsModuleFunctionCall * c)
{
- TQString tqmask;
+ TQString mask;
KVSM_PARAMETERS_BEGIN(c)
- KVSM_PARAMETER("tqmask",KVS_PT_STRING,0,tqmask)
+ KVSM_PARAMETER("mask",KVS_PT_STRING,0,mask)
KVSM_PARAMETERS_END(c)
- KviIrcMask mk(tqmask);
+ KviIrcMask mk(mask);
c->returnValue()->setBoolean(mk.hasNumericHost());
return true;
}