Bluz\Validator\Rule\IpRule
Check for IP
Strict mode disabled for this file, because function long2ip() was changed in PHP 7.1
Synopsis
- // members
- protected $options;
- protected $networkRange;
- // Inherited members from AbstractRule
- protected string $description;
- // methods
- public void __construct()
- protected array parseRange()
- protected void fillAddress()
- protected void parseRangeUsingWildcards()
- protected void parseRangeUsingCidr()
- public bool validate()
- protected bool verifyAddress()
- protected bool verifyNetwork()
- protected bool belongsToSubnet()
- public string getDescription()
- // Inherited methods from AbstractRule
- public void assert()
- public void __invoke()
- public void __toString()
- public void getDescription()
- public void setDescription()
Hierarchy
Extends
Members
protected
- $description
—
string
Message for error output - $networkRange — array
- $options — integer
Methods
protected
- belongsToSubnet() — Check subnet
- fillAddress() — Fill address
- parseRange() — Parse IP range
- parseRangeUsingCidr() — Parse range using Classless Inter-Domain Routing (CIDR)
- parseRangeUsingWildcards() — Parse range using wildcards
- verifyAddress() — Verify IP address
- verifyNetwork() — Verify Network by mask
public
- __construct() — Setup validation rule
- getDescription() — Get error template
- validate() — Check input data
Inherited from Bluz\Validator\Rule\AbstractRule
public
History
-
2017-08-02T10:22:44+00:00 (commit #ea84fc9)
Author: Yevgeniy Dyachenko (yevgeniy.dyachenko@flixbus.com) / Commiter: Yevgeniy Dyachenko (yevgeniy.dyachenko@flixbus.com)
replace pow function by arithmetic operator, merge if statement, remove function call in loop, replace substr function by array way to get character
-
2017-07-25T11:04:43+00:00 (commit #629da21)
Author: Anton Shevchuk (AntonShevchuk@gmail.com) / Commiter: Anton Shevchuk (AntonShevchuk@gmail.com)
Updated rules
-
2017-07-21T14:57:24+00:00 (commit #fe09826)
Author: Anton Shevchuk (AntonShevchuk@gmail.com) / Commiter: Anton Shevchuk (AntonShevchuk@gmail.com)
Updated validators
-
2017-06-30T08:36:40+00:00 (commit #2259ecf)
Author: Anton Shevchuk (AntonShevchuk@gmail.com) / Commiter: Anton Shevchuk (AntonShevchuk@gmail.com)
Fixed comments style
-
2017-04-21T13:24:35+00:00 (commit #3b25a3d)
Author: Anton Shevchuk (AntonShevchuk@gmail.com) / Commiter: Anton Shevchuk (AntonShevchuk@gmail.com)
Small update for codestyle
-
2017-02-15T16:09:44+00:00 (commit #0fc0c8b)
Author: Anton Shevchuk (AntonShevchuk@gmail.com) / Commiter: Anton Shevchuk (AntonShevchuk@gmail.com)
Updated coveralls config
-
2017-02-13T10:14:18+00:00 (commit #43dbf55)
Author: Anton Shevchuk (AntonShevchuk@gmail.com) / Commiter: Anton Shevchuk (AntonShevchuk@gmail.com)
Rollback to `getCount()` method
-
2017-01-30T13:15:49+00:00 (commit #fd5d943)
Author: Anton (AntonShevchuk@gmail.com) / Commiter: GitHub (AntonShevchuk@gmail.com)
Merge pull request #395 from AntonShevchuk/master Added `AttachmentResponse`
-
2017-01-30T12:38:53+00:00 (commit #0ab8691)
Author: Anton Shevchuk (AntonShevchuk@gmail.com) / Commiter: Anton Shevchuk (AntonShevchuk@gmail.com)
Added `AttachmentResponse` Added `attachment($file)` helper for `Controller`