class UrlPathStartswith implements Rule, Bypass

A rule to match beginning of URL

Traits

Path aware trait for rules and bypasses

Methods

string
getPath()

Returns the path

from PathAware
$this
setPath(string $path)

Update the path

from PathAware
__construct(string $path)

Initialize the rule with the path

bool
checkRequestForBypass(HTTPRequest $request)

Check the request for whether we can bypass the confirmation

null|Item
getRequestConfirmationItem(HTTPRequest $request)

Check the request by the rule and return a confirmation item

Details

in PathAware at line 20
string getPath()

Returns the path

Return Value

string

in PathAware at line 32
$this setPath(string $path)

Update the path

Parameters

string $path

Return Value

$this

at line 20
__construct(string $path)

Initialize the rule with the path

Parameters

string $path

at line 68
bool checkRequestForBypass(HTTPRequest $request)

Check the request for whether we can bypass the confirmation

Parameters

HTTPRequest $request

Return Value

bool True if we can bypass, False if the confirmation is required

at line 73
null|Item getRequestConfirmationItem(HTTPRequest $request)

Check the request by the rule and return a confirmation item

Parameters

HTTPRequest $request

Return Value

null|Item Confirmation item if necessary to protect the request or null otherwise