OXIESEC PANEL
- Current Dir:
/
/
var
/
www
/
reader
/
aws-ses
/
vendor
/
aws
/
aws-sdk-php
/
src
/
EndpointV2
/
Rule
Server IP: 139.59.38.164
Upload:
Create Dir:
Name
Size
Modified
Perms
📁
..
-
08/14/2024 10:55:12 AM
rwxr-xr-x
📄
AbstractRule.php
1.47 KB
08/14/2024 10:55:12 AM
rw-r--r--
📄
EndpointRule.php
3.39 KB
08/14/2024 10:55:12 AM
rw-r--r--
📄
ErrorRule.php
1.1 KB
08/14/2024 10:55:12 AM
rw-r--r--
📄
RuleCreator.php
687 bytes
08/14/2024 10:55:12 AM
rw-r--r--
📄
TreeRule.php
1.59 KB
08/14/2024 10:55:12 AM
rw-r--r--
Editing: AbstractRule.php
Close
<?php namespace Aws\EndpointV2\Rule; use Aws\EndpointV2\Ruleset\RulesetStandardLibrary; /** * A rule within a rule set. All rules contain a conditions property, * which can be empty, and documentation about the rule. */ abstract class AbstractRule { private $conditions; private $documentation; public function __construct(array $definition) { $this->conditions = $definition['conditions']; $this->documentation = isset($definition['documentation']) ? $definition['documentation'] : null; } /** * @return array */ public function getConditions() { return $this->conditions; } /** * @return mixed */ public function getDocumentation() { return $this->documentation; } /** * Determines if all conditions for a given rule are met. * * @return boolean */ protected function evaluateConditions( array &$inputParameters, RulesetStandardLibrary $standardLibrary ) { foreach($this->getConditions() as $condition) { $result = $standardLibrary->callFunction($condition, $inputParameters); if (is_null($result) || $result === false) { return false; } } return true; } abstract public function evaluate( array $inputParameters, RulesetStandardLibrary $standardLibrary ); }