Skip to content

Releases: linna/filter

v0.3.0

04 Oct 17:39
Compare
Choose a tag to compare

New on this version

Added

  • Linna\Filter\Result class, abstract, returned by Linna\Filter\Filter->filter() as anonymous class
  • Linna\Filter\Rules\CustomRule for declare user validation and sanitization custom rules
  • Linna\Filter\Rules\Ip check for valid ipv4 and ipv6 address
  • Linna\Filter\Rules\IPRange check if provided ipv4/ipv6 is in CIDR range
  • Linna\Filter\Rules\StringLenCompare new alias strlen
  • Namespace for tests

Changed

  • Linna\Filter\Filter->filterOne() and Linna\Filter\Filter->filterMulti() merged in Linna\Filter\Filter->filter()
  • Linna\Filter\Lexer class improved
  • Linna\Filter\Rules\Regex now throw an InvalidArgumentException if invalid regex is provided

Fixed

v0.2.0

28 Jul 11:21
26f2ebb
Compare
Choose a tag to compare

New on this version

Added

  • Rule aliases
  • New rule and more human readable message system
  • Linna\Filter->filterOne() and Linna\Filter->filterMulti() methods now return a results object
  • Linna\Filter\Rules\NumberIntervall check if a number is inside or outside a range with operators ><, <>, >=<, <=
  • Linna\Filter\Rules\NumberCompare check and compare numbers with operators <, >, >=, <=, =
  • Linna\Filter\Rules\Regex check if value match a regex
  • Linna\Filter\Rules\StringLenCompare check length of a string with operators <, >, >=, <=, =, !=
  • Linna\Filter\Rules\Str sanitize strings (convert data type to string)

Removed

  • Linna\Filter\Rules\Between
  • Linna\Filter\Rules\MaxLength
  • Linna\Filter\Rules\Max
  • Linna\Filter\Rules\Min
  • Linna\Filter\Rules\MinLength

v0.1.0

29 May 17:26
Compare
Choose a tag to compare

Initial Release

Added

  • Linna\Filter\Rules\Between validate numbers, between two values
  • Linna\Filter\Rules\Date validate a date
  • Linna\Filter\Rules\DateCompare validate dates with operators <, >, >=, <=, =
  • Linna\Filter\Rules\Email validate an email
  • Linna\Filter\Rules\Escape escape output
  • Linna\Filter\Rules\Max validate numbers, lower than
  • Linna\Filter\Rules\MaxLength validate strings length, lower than
  • Linna\Filter\Rules\Min validate numbers, higher than
  • Linna\Filter\Rules\MinLength validate strings length, higher than
  • Linna\Filter\Rules\Number sanitize numbers