diff --git a/.github/workflows/php.yml b/.github/workflows/php.yml index ec27b54..fc1f015 100644 --- a/.github/workflows/php.yml +++ b/.github/workflows/php.yml @@ -17,13 +17,8 @@ jobs: strategy: fail-fast: false matrix: - php: ['5.6', '7.0', '7.1', '7.2', '7.3', '7.4', '8.0'] + php: ['7.0', '7.1', '7.2', '7.3', '7.4', '8.0', '8.1'] os: ['ubuntu-latest'] - include: - - php: '5.6' - allow_failure: true - - php: '7.0' - allow_failure: true steps: - name: Checkout code base @@ -51,20 +46,18 @@ jobs: runs-on: ${{ matrix.os }} env: - phpunit-version: 8.5.15 + phpunit-version: 8.5 strategy: fail-fast: false matrix: - php: ['5.6', '7.0', '7.1', '7.2', '7.3', '7.4', '8.0'] + php: ['7.0', '7.1', '7.2', '7.3', '7.4', '8.0', '8.1'] os: ['ubuntu-latest'] include: - - php: '5.6' - phpunit-version: 5.7.27 - php: '7.0' - phpunit-version: 6.5.14 + phpunit-version: 6.5 - php: '7.1' - phpunit-version: 7.5.20 + phpunit-version: 7.5 steps: - name: Checkout code base diff --git a/README.md b/README.md index 5546770..e91a270 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # Icinga PHP Library - Standard Library -[![PHP Support](https://img.shields.io/badge/php-%3E%3D%205.6-777BB4?logo=PHP)](https://php.net/) +[![PHP Support](https://img.shields.io/badge/php-%3E%3D%207.0-777BB4?logo=PHP)](https://php.net/) ![Build Status](https://github.com/Icinga/ipl-stdlib/workflows/PHP%20Tests/badge.svg?branch=master) This is the Stdlib prototype for the Icinga PHP library ([ipl](https://github.com/Icinga/ipl)). diff --git a/composer.json b/composer.json index ebc12b6..8e6b304 100644 --- a/composer.json +++ b/composer.json @@ -4,7 +4,7 @@ "type": "library", "license": "MIT", "autoload": { - "files": ["src/functions_include.php", "src/polyfill-php71.php", "src/polyfill-php70.php"], + "files": ["src/functions_include.php", "src/polyfill-php71.php"], "psr-4": { "ipl\\Stdlib\\": "src" } @@ -15,7 +15,7 @@ } }, "require": { - "php": ">=5.6.0", + "php": ">=7.0", "ext-openssl": "*", "evenement/evenement": "^2" } diff --git a/src/BaseFilter.php b/src/BaseFilter.php new file mode 100644 index 0000000..267decb --- /dev/null +++ b/src/BaseFilter.php @@ -0,0 +1,45 @@ +baseFilter !== null; + } + + /** + * Get the base filter + * + * @return ?Rule + */ + public function getBaseFilter() + { + return $this->baseFilter; + } + + /** + * Set the base filter + * + * @param Rule $baseFilter + * + * @return $this + */ + public function setBaseFilter(Rule $baseFilter = null): self + { + $this->baseFilter = $baseFilter; + + return $this; + } +} diff --git a/src/polyfill-php70.php b/src/polyfill-php70.php deleted file mode 100644 index 54c1771..0000000 --- a/src/polyfill-php70.php +++ /dev/null @@ -1,22 +0,0 @@ -