Antispam_Controller
extends Core_Servant_Properties
in package
Antispam controller
Tags
Table of Contents
Properties
- $_aAntispam_Stopwords : null|array<string|int, mixed>
- Antispam_Stopwords Cache
- $_allowedProperties : array<string|int, mixed>
- Allowed object properties
- $_antispam_GeoIP_Controller : Antispam_GeoIP_Controller
- GeoIP controller
- $_geoip : object|null
- GeoIP
- $_propertiesValues : array<string|int, mixed>
- Properties values
- $_text : array<string|int, mixed>
- Text
- $_unlimitedProperties : bool
- Object has unlimited number of properties
Methods
- __construct() : mixed
- Constructor.
- __destruct() : mixed
- Destructor
- addAllowedProperties() : self
- Add additional allowed properties
- addAllowedProperty() : self
- Add additional allowed property
- addText() : self
- Add text
- closeGeoIp() : self
- Close GeoIP
- execute() : bool
- Execute business logic.
- getAntispamStopword() : array<string|int, mixed>
- Get Antispam_Stopwords
- getCountryCode() : string
- Get country code
- set() : self
- Run when writing data to inaccessible properties
- setUnlimitedProperties() : self
- Set unlimitedProperties
- text() : self
- Set text
Properties
$_aAntispam_Stopwords
Antispam_Stopwords Cache
protected
null|array<string|int, mixed>
$_aAntispam_Stopwords
= \NULL
$_allowedProperties
Allowed object properties
protected
array<string|int, mixed>
$_allowedProperties
= array('log', 'ip', 'userAgent')
$_antispam_GeoIP_Controller
GeoIP controller
protected
Antispam_GeoIP_Controller
$_antispam_GeoIP_Controller
= \NULL
$_geoip
GeoIP
protected
object|null
$_geoip
= \NULL
$_propertiesValues
Properties values
protected
array<string|int, mixed>
$_propertiesValues
= array()
$_text
Text
protected
array<string|int, mixed>
$_text
= array()
$_unlimitedProperties
Object has unlimited number of properties
protected
bool
$_unlimitedProperties
= \FALSE
Methods
__construct()
Constructor.
public
__construct() : mixed
__destruct()
Destructor
public
__destruct() : mixed
addAllowedProperties()
Add additional allowed properties
public
addAllowedProperties(array<string|int, mixed> $array) : self
Parameters
- $array : array<string|int, mixed>
-
array of properties' names
Return values
selfaddAllowedProperty()
Add additional allowed property
public
addAllowedProperty(string $property) : self
Parameters
- $property : string
-
property name
Return values
selfaddText()
Add text
public
addText(string $text[, string|null $fieldName = NULL ]) : self
Parameters
- $text : string
-
text
- $fieldName : string|null = NULL
-
field name, default NULL
Return values
selfcloseGeoIp()
Close GeoIP
public
closeGeoIp() : self
Return values
selfexecute()
Execute business logic.
public
execute() : bool
Tags
Return values
bool —FALSE - SPAM, TRUE - regular request
getAntispamStopword()
Get Antispam_Stopwords
public
getAntispamStopword() : array<string|int, mixed>
Return values
array<string|int, mixed>getCountryCode()
Get country code
public
getCountryCode(string $ip) : string
Parameters
- $ip : string
Return values
stringset()
Run when writing data to inaccessible properties
public
set(string $property, string $value) : self
Parameters
- $property : string
-
property name
- $value : string
-
property value
Return values
selfsetUnlimitedProperties()
Set unlimitedProperties
public
setUnlimitedProperties([bool $value = TRUE ]) : self
Parameters
- $value : bool = TRUE
-
default TRUR
Return values
selftext()
Set text
public
text(string $text) : self
Parameters
- $text : string
-
text