Skip to content

Commit

Permalink
Explicit nullable type
Browse files Browse the repository at this point in the history
  • Loading branch information
tvdijen committed Dec 2, 2024
1 parent f6db6b5 commit 68b2d7f
Show file tree
Hide file tree
Showing 170 changed files with 257 additions and 257 deletions.
12 changes: 6 additions & 6 deletions .github/workflows/php.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ jobs:
uses: shivammathur/setup-php@v2
with:
# Should be the higest supported version, so we can use the newest tools
php-version: '8.3'
php-version: '8.4'
tools: composer, composer-require-checker, composer-unused, phpcs
extensions: ctype, date, dom, filter, pcre, soap, spl, xml
coverage: none
Expand Down Expand Up @@ -142,7 +142,7 @@ jobs:
fail-fast: false
matrix:
operating-system: [ubuntu-latest]
php-versions: ['8.1', '8.2', '8.3']
php-versions: ['8.1', '8.2', '8.3', '8.4']

steps:
- name: Setup PHP, with composer and extensions
Expand Down Expand Up @@ -182,15 +182,15 @@ jobs:
run: composer install --no-progress --prefer-dist --optimize-autoloader

- name: Run unit tests with coverage
if: ${{ matrix.php-versions == '8.3' }}
if: ${{ matrix.php-versions == '8.4' }}
run: vendor/bin/phpunit

- name: Run unit tests (no coverage)
if: ${{ matrix.php-versions != '8.3' }}
if: ${{ matrix.php-versions != '8.4' }}
run: vendor/bin/phpunit --no-coverage

- name: Save coverage data
if: ${{ matrix.php-versions == '8.3' }}
if: ${{ matrix.php-versions == '8.4' }}
uses: actions/upload-artifact@v4
with:
name: coverage-data
Expand All @@ -204,7 +204,7 @@ jobs:
fail-fast: true
matrix:
operating-system: [windows-latest]
php-versions: ['8.1', '8.2', '8.3']
php-versions: ['8.1', '8.2', '8.3', '8.4']

steps:
- name: Setup PHP, with composer and extensions
Expand Down
2 changes: 1 addition & 1 deletion src/XML/auth/AbstractAdditionalContextType.php
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ public static function fromXML(DOMElement $xml): static
* @param \DOMElement $parent The element we should append this username token to.
* @return \DOMElement
*/
public function toXML(DOMElement $parent = null): DOMElement
public function toXML(?DOMElement $parent = null): DOMElement
{
$e = $this->instantiateParentElement($parent);

Expand Down
2 changes: 1 addition & 1 deletion src/XML/auth/AbstractClaimType.php
Original file line number Diff line number Diff line change
Expand Up @@ -216,7 +216,7 @@ public static function fromXML(DOMElement $xml): static
* @param \DOMElement $parent The element we should append this username token to.
* @return \DOMElement
*/
public function toXML(DOMElement $parent = null): DOMElement
public function toXML(?DOMElement $parent = null): DOMElement
{
$e = $this->instantiateParentElement($parent);

Expand Down
2 changes: 1 addition & 1 deletion src/XML/auth/AbstractConstrainedManyValueType.php
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ public static function fromXML(DOMElement $xml): static
* @param \DOMElement|null $parent The element we should append this element to.
* @return \DOMElement
*/
public function toXML(DOMElement $parent = null): DOMElement
public function toXML(?DOMElement $parent = null): DOMElement
{
$e = $this->instantiateParentElement($parent);

Expand Down
2 changes: 1 addition & 1 deletion src/XML/auth/AbstractConstrainedSingleValueType.php
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ public static function fromXML(DOMElement $xml): static
* @param \DOMElement|null $parent The element we should append this element to.
* @return \DOMElement
*/
public function toXML(DOMElement $parent = null): DOMElement
public function toXML(?DOMElement $parent = null): DOMElement
{
$e = $this->instantiateParentElement($parent);

Expand Down
2 changes: 1 addition & 1 deletion src/XML/auth/AbstractConstrainedValueType.php
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ public static function fromXML(DOMElement $xml): static
* @param \DOMElement $parent The element we should append this username token to.
* @return \DOMElement
*/
public function toXML(DOMElement $parent = null): DOMElement
public function toXML(?DOMElement $parent = null): DOMElement
{
$e = $this->instantiateParentElement($parent);

Expand Down
2 changes: 1 addition & 1 deletion src/XML/auth/AbstractContextItemType.php
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ public static function fromXML(DOMElement $xml): static
* @param \DOMElement $parent The element we should append this username token to.
* @return \DOMElement
*/
public function toXML(DOMElement $parent = null): DOMElement
public function toXML(?DOMElement $parent = null): DOMElement
{
$e = $this->instantiateParentElement($parent);

Expand Down
2 changes: 1 addition & 1 deletion src/XML/auth/AbstractDescriptionType.php
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ public static function fromXML(DOMElement $xml): static
* @param \DOMElement|null $parent The element we should append this element to.
* @return \DOMElement
*/
public function toXML(DOMElement $parent = null): DOMElement
public function toXML(?DOMElement $parent = null): DOMElement
{
$e = $this->instantiateParentElement($parent);
$e->textContent = $this->getContent();
Expand Down
2 changes: 1 addition & 1 deletion src/XML/auth/AbstractDisplayNameType.php
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ public static function fromXML(DOMElement $xml): static
* @param \DOMElement|null $parent The element we should append this element to.
* @return \DOMElement
*/
public function toXML(DOMElement $parent = null): DOMElement
public function toXML(?DOMElement $parent = null): DOMElement
{
$e = $this->instantiateParentElement($parent);
$e->textContent = $this->getContent();
Expand Down
2 changes: 1 addition & 1 deletion src/XML/auth/AbstractDisplayValueType.php
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ public static function fromXML(DOMElement $xml): static
* @param \DOMElement|null $parent The element we should append this element to.
* @return \DOMElement
*/
public function toXML(DOMElement $parent = null): DOMElement
public function toXML(?DOMElement $parent = null): DOMElement
{
$e = $this->instantiateParentElement($parent);
$e->textContent = $this->getContent();
Expand Down
2 changes: 1 addition & 1 deletion src/XML/auth/AbstractEncryptedValueType.php
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ public static function fromXML(DOMElement $xml): static
* @param \DOMElement|null $parent The element we should append this element to.
* @return \DOMElement
*/
public function toXML(DOMElement $parent = null): DOMElement
public function toXML(?DOMElement $parent = null): DOMElement
{
$e = $this->instantiateParentElement($parent);
$e->setAttribute('DescriptionCondition', $this->getDescriptionCondition());
Expand Down
2 changes: 1 addition & 1 deletion src/XML/auth/AbstractStructuredValueType.php
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ public static function fromXML(DOMElement $xml): static
* @param \DOMElement $parent The element we should append this username token to.
* @return \DOMElement
*/
public function toXML(DOMElement $parent = null): DOMElement
public function toXML(?DOMElement $parent = null): DOMElement
{
$e = parent::instantiateParentElement($parent);

Expand Down
4 changes: 2 additions & 2 deletions src/XML/auth/AbstractValueInRangeType.php
Original file line number Diff line number Diff line change
Expand Up @@ -79,10 +79,10 @@ public function getValueLowerBound(): ValueLowerBound
/**
* Add this ValueInRangeType to an XML element.
*
* @param \DOMElement $parent The element we should append this username token to.
* @param \DOMElement|null $parent The element we should append this username token to.
* @return \DOMElement
*/
public function toXML(DOMElement $parent = null): DOMElement
public function toXML(?DOMElement $parent = null): DOMElement
{
$e = parent::instantiateParentElement($parent);

Expand Down
4 changes: 2 additions & 2 deletions src/XML/fed/AbstractAssertionType.php
Original file line number Diff line number Diff line change
Expand Up @@ -79,10 +79,10 @@ public static function fromXML(DOMElement $xml): static
/**
* Add this AssertionType to an XML element.
*
* @param \DOMElement $parent The element we should append this AssertionType to.
* @param \DOMElement|null $parent The element we should append this AssertionType to.
* @return \DOMElement
*/
public function toXML(DOMElement $parent = null): DOMElement
public function toXML(?DOMElement $parent = null): DOMElement
{
$e = parent::instantiateParentElement($parent);

Expand Down
2 changes: 1 addition & 1 deletion src/XML/fed/AbstractAttributeExtensibleString.php
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ public static function fromXML(DOMElement $xml): static
* @param \DOMElement|null $parent
* @return \DOMElement
*/
public function toXML(DOMElement $parent = null): DOMElement
public function toXML(?DOMElement $parent = null): DOMElement
{
$e = $this->instantiateParentElement($parent);
$e->textContent = $this->getContent();
Expand Down
2 changes: 1 addition & 1 deletion src/XML/fed/AbstractAttributeExtensibleURI.php
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ public static function fromXML(DOMElement $xml): static
* @param \DOMElement|null $parent
* @return \DOMElement
*/
public function toXML(DOMElement $parent = null): DOMElement
public function toXML(?DOMElement $parent = null): DOMElement
{
$e = $this->instantiateParentElement($parent);
$e->textContent = $this->getContent();
Expand Down
4 changes: 2 additions & 2 deletions src/XML/fed/AbstractClaimDialectType.php
Original file line number Diff line number Diff line change
Expand Up @@ -84,10 +84,10 @@ public static function fromXML(DOMElement $xml): static
/**
* Add this ClaimDialectType to an XML element.
*
* @param \DOMElement $parent The element we should append this username token to.
* @param \DOMElement|null $parent The element we should append this username token to.
* @return \DOMElement
*/
public function toXML(DOMElement $parent = null): DOMElement
public function toXML(?DOMElement $parent = null): DOMElement
{
$e = parent::instantiateParentElement($parent);

Expand Down
4 changes: 2 additions & 2 deletions src/XML/fed/AbstractClaimDialectsOfferedType.php
Original file line number Diff line number Diff line change
Expand Up @@ -84,10 +84,10 @@ public static function fromXML(DOMElement $xml): static
/**
* Add this ClaimDialectsOfferedType to an XML element.
*
* @param \DOMElement $parent The element we should append this ClaimDialectsOfferedType to.
* @param \DOMElement|null $parent The element we should append this ClaimDialectsOfferedType to.
* @return \DOMElement
*/
public function toXML(DOMElement $parent = null): DOMElement
public function toXML(?DOMElement $parent = null): DOMElement
{
$e = parent::instantiateParentElement($parent);

Expand Down
4 changes: 2 additions & 2 deletions src/XML/fed/AbstractClaimTypesOfferedType.php
Original file line number Diff line number Diff line change
Expand Up @@ -83,10 +83,10 @@ public static function fromXML(DOMElement $xml): static
/**
* Add this ClaimTypesOfferedType to an XML element.
*
* @param \DOMElement $parent The element we should append this ClaimTypesOfferedType to.
* @param \DOMElement|null $parent The element we should append this ClaimTypesOfferedType to.
* @return \DOMElement
*/
public function toXML(DOMElement $parent = null): DOMElement
public function toXML(?DOMElement $parent = null): DOMElement
{
$e = parent::instantiateParentElement($parent);

Expand Down
4 changes: 2 additions & 2 deletions src/XML/fed/AbstractClaimTypesRequestedType.php
Original file line number Diff line number Diff line change
Expand Up @@ -83,10 +83,10 @@ public static function fromXML(DOMElement $xml): static
/**
* Add this ClaimTypesRequestedType to an XML element.
*
* @param \DOMElement $parent The element we should append this ClaimTypesRequestedType to.
* @param \DOMElement|null $parent The element we should append this ClaimTypesRequestedType to.
* @return \DOMElement
*/
public function toXML(DOMElement $parent = null): DOMElement
public function toXML(?DOMElement $parent = null): DOMElement
{
$e = parent::instantiateParentElement($parent);

Expand Down
4 changes: 2 additions & 2 deletions src/XML/fed/AbstractClientPseudonymType.php
Original file line number Diff line number Diff line change
Expand Up @@ -130,10 +130,10 @@ public static function fromXML(DOMElement $xml): static
/**
* Add this ClientPseudonymType to an XML element.
*
* @param \DOMElement $parent The element we should append this FederationMetadataType to.
* @param \DOMElement|null $parent The element we should append this FederationMetadataType to.
* @return \DOMElement
*/
public function toXML(DOMElement $parent = null): DOMElement
public function toXML(?DOMElement $parent = null): DOMElement
{
$e = parent::instantiateParentElement($parent);

Expand Down
2 changes: 1 addition & 1 deletion src/XML/fed/AbstractEndpointType.php
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ public static function fromXML(DOMElement $xml): static
* @param \DOMElement|null $parent The element we should append this element to.
* @return \DOMElement
*/
public function toXML(DOMElement $parent = null): DOMElement
public function toXML(?DOMElement $parent = null): DOMElement
{
$e = $this->instantiateParentElement($parent);

Expand Down
4 changes: 2 additions & 2 deletions src/XML/fed/AbstractFederationMetadataHandlerType.php
Original file line number Diff line number Diff line change
Expand Up @@ -69,10 +69,10 @@ public static function fromXML(DOMElement $xml): static
/**
* Add this FederationMetadataHandlerType to an XML element.
*
* @param \DOMElement $parent The element we should append this FederationMetadataHandlerType to.
* @param \DOMElement|null $parent The element we should append this FederationMetadataHandlerType to.
* @return \DOMElement
*/
public function toXML(DOMElement $parent = null): DOMElement
public function toXML(?DOMElement $parent = null): DOMElement
{
$e = parent::instantiateParentElement($parent);

Expand Down
4 changes: 2 additions & 2 deletions src/XML/fed/AbstractFederationMetadataType.php
Original file line number Diff line number Diff line change
Expand Up @@ -79,10 +79,10 @@ public static function fromXML(DOMElement $xml): static
/**
* Add this FederationMetadataType to an XML element.
*
* @param \DOMElement $parent The element we should append this FederationMetadataType to.
* @param \DOMElement|null $parent The element we should append this FederationMetadataType to.
* @return \DOMElement
*/
public function toXML(DOMElement $parent = null): DOMElement
public function toXML(?DOMElement $parent = null): DOMElement
{
$e = parent::instantiateParentElement($parent);

Expand Down
4 changes: 2 additions & 2 deletions src/XML/fed/AbstractFederationType.php
Original file line number Diff line number Diff line change
Expand Up @@ -95,10 +95,10 @@ public static function fromXML(DOMElement $xml): static
/**
* Add this FederationType to an XML element.
*
* @param \DOMElement $parent The element we should append this FederationType to.
* @param \DOMElement|null $parent The element we should append this FederationType to.
* @return \DOMElement
*/
public function toXML(DOMElement $parent = null): DOMElement
public function toXML(?DOMElement $parent = null): DOMElement
{
$e = parent::instantiateParentElement($parent);

Expand Down
4 changes: 2 additions & 2 deletions src/XML/fed/AbstractFilterPseudonymsType.php
Original file line number Diff line number Diff line change
Expand Up @@ -116,10 +116,10 @@ public static function fromXML(DOMElement $xml): static
/**
* Add this FilterPseudonymsType to an XML element.
*
* @param \DOMElement $parent The element we should append this username token to.
* @param \DOMElement|null $parent The element we should append this username token to.
* @return \DOMElement
*/
public function toXML(DOMElement $parent = null): DOMElement
public function toXML(?DOMElement $parent = null): DOMElement
{
$e = parent::instantiateParentElement($parent);

Expand Down
4 changes: 2 additions & 2 deletions src/XML/fed/AbstractFreshnessType.php
Original file line number Diff line number Diff line change
Expand Up @@ -104,10 +104,10 @@ public static function fromXML(DOMElement $xml): static
/**
* Add this IssuerNameType to an XML element.
*
* @param \DOMElement $parent The element we should append this issuer name to.
* @param \DOMElement|null $parent The element we should append this issuer name to.
* @return \DOMElement
*/
public function toXML(DOMElement $parent = null): DOMElement
public function toXML(?DOMElement $parent = null): DOMElement
{
$e = parent::instantiateParentElement($parent);
$e->textContent = $this->getContent();
Expand Down
4 changes: 2 additions & 2 deletions src/XML/fed/AbstractIssuerNameType.php
Original file line number Diff line number Diff line change
Expand Up @@ -73,10 +73,10 @@ public static function fromXML(DOMElement $xml): static
/**
* Add this IssuerNameType to an XML element.
*
* @param \DOMElement $parent The element we should append this issuer name to.
* @param \DOMElement|null $parent The element we should append this issuer name to.
* @return \DOMElement
*/
public function toXML(DOMElement $parent = null): DOMElement
public function toXML(?DOMElement $parent = null): DOMElement
{
$e = parent::instantiateParentElement($parent);
$e->setAttribute('Uri', $this->getUri());
Expand Down
4 changes: 2 additions & 2 deletions src/XML/fed/AbstractLogicalServiceNamesOfferedType.php
Original file line number Diff line number Diff line change
Expand Up @@ -84,10 +84,10 @@ public static function fromXML(DOMElement $xml): static
/**
* Add this LogicalServiceNamesOfferedType to an XML element.
*
* @param \DOMElement $parent The element we should append this LogicalServiceNamesOfferedType to.
* @param \DOMElement|null $parent The element we should append this LogicalServiceNamesOfferedType to.
* @return \DOMElement
*/
public function toXML(DOMElement $parent = null): DOMElement
public function toXML(?DOMElement $parent = null): DOMElement
{
$e = parent::instantiateParentElement($parent);

Expand Down
4 changes: 2 additions & 2 deletions src/XML/fed/AbstractProofTokenType.php
Original file line number Diff line number Diff line change
Expand Up @@ -73,10 +73,10 @@ public static function fromXML(DOMElement $xml): static
/**
* Add this AbstractProofTokenType to an XML element.
*
* @param \DOMElement $parent The element we should append this username token to.
* @param \DOMElement|null $parent The element we should append this username token to.
* @return \DOMElement
*/
public function toXML(DOMElement $parent = null): DOMElement
public function toXML(?DOMElement $parent = null): DOMElement
{
$e = parent::instantiateParentElement($parent);

Expand Down
4 changes: 2 additions & 2 deletions src/XML/fed/AbstractPseudonymBasisType.php
Original file line number Diff line number Diff line change
Expand Up @@ -76,10 +76,10 @@ public static function fromXML(DOMElement $xml): static
/**
* Add this AbstractPseudonymBasisType to an XML element.
*
* @param \DOMElement $parent The element we should append this username token to.
* @param \DOMElement|null $parent The element we should append this username token to.
* @return \DOMElement
*/
public function toXML(DOMElement $parent = null): DOMElement
public function toXML(?DOMElement $parent = null): DOMElement
{
$e = parent::instantiateParentElement($parent);

Expand Down
4 changes: 2 additions & 2 deletions src/XML/fed/AbstractPseudonymType.php
Original file line number Diff line number Diff line change
Expand Up @@ -110,10 +110,10 @@ public static function fromXML(DOMElement $xml): static
/**
* Add this PseudonymType to an XML element.
*
* @param \DOMElement $parent The element we should append this username token to.
* @param \DOMElement|null $parent The element we should append this username token to.
* @return \DOMElement
*/
public function toXML(DOMElement $parent = null): DOMElement
public function toXML(?DOMElement $parent = null): DOMElement
{
$e = parent::instantiateParentElement($parent);

Expand Down
Loading

0 comments on commit 68b2d7f

Please sign in to comment.