本文整理汇总了PHP中Match::__construct方法的典型用法代码示例。如果您正苦于以下问题:PHP Match::__construct方法的具体用法?PHP Match::__construct怎么用?PHP Match::__construct使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Match
的用法示例。
在下文中一共展示了Match::__construct方法的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: __construct
/**
* @param $password
* @param $begin
* @param $end
* @param $token
* @param $cardinality
*/
public function __construct($password, $begin, $end, $token, $cardinality = null)
{
parent::__construct($password, $begin, $end, $token);
$this->pattern = 'bruteforce';
// Cardinality can be injected to support full password cardinality instead of token.
$this->cardinality = $cardinality;
}
示例2: __construct
/**
* @param $password
* @param $begin
* @param $end
* @param $token
* @param array $params
* Array with keys: day, month, year, separator.
*/
public function __construct($password, $begin, $end, $token, $params)
{
parent::__construct($password, $begin, $end, $token);
$this->pattern = 'date';
$this->day = $params['day'];
$this->month = $params['month'];
$this->year = $params['year'];
$this->separator = $params['separator'];
}
示例3: __construct
/**
* @param $password
* @param $begin
* @param $end
* @param $token
* @param array $params
*/
public function __construct($password, $begin, $end, $token, $params = array())
{
parent::__construct($password, $begin, $end, $token);
$this->pattern = 'sequence';
if (!empty($params)) {
$this->sequenceName = isset($params['sequenceName']) ? $params['sequenceName'] : null;
$this->sequenceSpace = isset($params['sequenceSpace']) ? $params['sequenceSpace'] : null;
$this->ascending = isset($params['ascending']) ? $params['ascending'] : null;
}
}
示例4: __construct
/**
* @param $password
* @param $begin
* @param $end
* @param $token
* @param array $params
*/
public function __construct($password, $begin, $end, $token, $params = array())
{
parent::__construct($password, $begin, $end, $token);
$this->pattern = 'dictionary';
if (!empty($params)) {
$this->dictionaryName = isset($params['dictionary_name']) ? $params['dictionary_name'] : null;
$this->matchedWord = isset($params['matched_word']) ? $params['matched_word'] : null;
$this->rank = isset($params['rank']) ? $params['rank'] : null;
}
}
示例5: __construct
/**
* @param $password
* @param $begin
* @param $end
* @param $token
* @param array $params
*/
public function __construct($password, $begin, $end, $token, $params = array())
{
parent::__construct($password, $begin, $end, $token);
$this->pattern = 'spatial';
$this->graph = $params['graph'];
if (!empty($params)) {
$this->shiftedCount = isset($params['shifted_count']) ? $params['shifted_count'] : null;
$this->turns = isset($params['turns']) ? $params['turns'] : null;
}
// Preset properties since adjacency graph is constant for qwerty keyboard and keypad.
$this->keyboardStartingPos = 94;
$this->keypadStartingPos = 15;
$this->keyboardAvgDegree = 432 / 94;
$this->keypadAvgDegree = 76 / 15;
}
示例6: __construct
/**
* Construct the Exact rule.
*
* @param string $outputFormat The output format for the rule.
* @param mixed[] $match Exact match required from the media type.
* @param string[] $ignoredFields Fields to be ignored in the match.
*/
public function __construct(string $outputFormat, array $match, array $ignoredFields = ['q_factor'])
{
parent::__construct($outputFormat, $match);
$this->ignoredFields = $ignoredFields;
}
示例7: __construct
/**
* @param $password
* @param $begin
* @param $end
* @param $token
*/
public function __construct($password, $begin, $end, $token)
{
parent::__construct($password, $begin, $end, $token);
$this->pattern = 'digit';
}
示例8: __construct
public function __construct($mid)
{
parent::__construct($mid);
$this->hash_botocs = get_alt_col('leegmgr_matches', 'mid', $mid, 'hash');
}
示例9: __construct
/**
* @param $password
* @param $begin
* @param $end
* @param $token
*/
public function __construct($password, $begin, $end, $token, $char)
{
parent::__construct($password, $begin, $end, $token);
$this->pattern = 'repeat';
$this->repeatedChar = $char;
}