Class CountableMatcher
CountableMatcher a matcher is a matcher that matches numeric values, or reduces a countable value - like array, string, or Countable - to a single numeric value.
- Peridot\Leo\Matcher\AbstractMatcher implements Peridot\Leo\Matcher\MatcherInterface
- Extended by Peridot\Leo\Matcher\CountableMatcher
Direct known subclasses
Peridot\Leo\Matcher\GreaterThanMatcher, Peridot\Leo\Matcher\GreaterThanOrEqualMatcher, Peridot\Leo\Matcher\LessThanMatcher, Peridot\Leo\Matcher\LessThanOrEqualMatcher, Peridot\Leo\Matcher\RangeMatcherNamespace: Peridot\Leo\Matcher
Package: Peridot\Leo\Matcher
Located at Matcher/CountableMatcher.php
public
mixed
setCountable( mixed $countable )
Set the countable value used by the CountableMatcher.
Set the countable value used by the CountableMatcher.
Parameters
- $countable
Returns
mixed
$this
public
mixed
getCountable( )
Return the countable used by the CountableMatcher.
Return the countable used by the CountableMatcher.
Returns
mixed
public
integer
public
Peridot\Leo\Matcher\Template\TemplateInterface
getTemplate( )
Return the TemplateInterface being used by the matcher.
Return the TemplateInterface being used by the matcher.
Returns a default countable interface if the countable is set.
Returns
Overrides
protected
mixed
abstract public
Peridot\Leo\Matcher\Template\TemplateInterface
getDefaultCountableTemplate( )
Return a default template for when a countable has been set.
Return a default template for when a countable has been set.
Returns
abstract protected
boolean
matchNumeric( mixed $number )
Determine if a number matches a specified condition
Determine if a number matches a specified condition
Parameters
- $number
Returns
boolean