MultipleMatcher
in package
implements
RequestMatcherInterface, Countable
Combines several request matchers with AND semantics.
Tags
Table of Contents
Interfaces
- RequestMatcherInterface
- Contract for reusable request matching rules registered through PockBuilder::addMatcher().
- Countable
Properties
- $matchers : array<string|int, RequestMatcherInterface>
Methods
- __construct() : mixed
- MultipleMatcher constructor.
- addMatcher() : $this
- count() : int
- matches() : bool
- Return true when the request satisfies this rule.
Properties
$matchers
public
array<string|int, RequestMatcherInterface>
$matchers
Methods
__construct()
MultipleMatcher constructor.
public
__construct([array<string|int, RequestMatcherInterface> $matchers = [] ]) : mixed
Parameters
- $matchers : array<string|int, RequestMatcherInterface> = []
addMatcher()
public
addMatcher(RequestMatcherInterface $matcher) : $this
Parameters
- $matcher : RequestMatcherInterface
Return values
$thiscount()
public
count() : int
Return values
intmatches()
Return true when the request satisfies this rule.
public
matches(RequestInterface $request) : bool
Parameters
- $request : RequestInterface